7
The Memory System
This chapter introduces the memory system adopted for computers and some of its salient
features. After completion of this chapter, the reader would know about
R General structure of memory system adopted for computers.
R Different types of memory and their applications.
R Essential features of memory management techniques including DMA.
C HAPTER OBJECTIVES
7.1 INTRODUCTION
In Chapters 1 and 2, we have outlined the importance of memory modules for any computer system.
Over a span of several decades the type and size, application techniques and operating speci cations of
these memory units have taken new shapes, features and characteristics. In this chapter, we shall take
a closer look into these memory modules used in different computer systems. We start our discussions
with classi cation of computer-memory.
7.2 MEMORY CLASSIFICATION
If we would like to broadly classify memory devices used in computers ( Figure 7.1 for computer mem-
ory tree), then there would be only two categories, namely
R Primary memory
R Secondary memory
M07_GHOS1557_01_SE_C07.indd 198M07_GHOS1557_01_SE_C07.indd 198 4/29/11 5:11 PM4/29/11 5:11 PM
The Memory System 199
The primary memory may be further classi ed as
R Read Only Memory (ROM) or non-volatile memory
R Read/Write Memory or RAM or volatile memory.
The fundamental difference between these two is their capabilities to retain stored information during
power-off condition. As we know, in such a case, data stored within a RAM would be lost but not the data
stored within a ROM. As far as computers are concerned, ROM plays a small but very critical role of boot-
strap ROM, essential just after power-on, to boot the system. Note that just after power-on, it is only the
non-volatile memory that may help the system in booting, not the volatile memory, as they contain random
data patterns, and program segments are yet to be loaded within it. The reader may ask that why some
other non-volatile memory, like hard disc, cannot replace boot-strap ROM? The answer is, no processor
can directly execute any program stored in any type of discs. From any type of disc, rst it must be loaded
in RAM to be executed. In other words, a processor can execute a program if it is residing in either RAM
or ROM. Therefore, just after power-on, the boot-strap ROM copies a small le from disc into the system
RAM or main memory and then transfers the control to that memory. Thereafter, the control takes care of
the remaining operations, and then, the duty of boot-strap ROM is complete.
Therefore, for any computer system, we are more interested in the RAM, and a major portion of our
forthcoming discussions would be centred on the implementation of static and dynamic RAM. How-
ever, for the purpose of comprehensiveness, we shall quickly discuss about some major types of storage
techniques used in modern memory devices.
Sometimes, one asks about the constituents of a minimum working system of microprocessors.
In other words, can a processor work with only RAM or only ROM or only disc? Theoretically,
no processor can work with only RAM or only disc. A processor and a ROM make a minimum
working system. However, this must be designed to work without system stack (no RAM,
therefore, no subroutine call possible) and for data storage it must depend on the internal
registers of the processor. However, for all practical purposes, a minimum system must
contain both ROM as well as RAM.
F
O
O
D
F
O
R
T
H
O
U
G
H
T
Figure 7.1 Computer memory tree
M07_GHOS1557_01_SE_C07.indd 199M07_GHOS1557_01_SE_C07.indd 199 4/29/11 5:12 PM4/29/11 5:12 PM
200 Computer Architecture and Organization
7.2.1 Read Only Memory (ROM)
The non-volatile type memory devices are generally categorized by the method in which it may be
implemented to erase these devices. As they must retain the information within them even if the power
is switched off, a special programming procedure is necessary to write data in these memories and also
a special wiping procedure to erase the data within it. Common types of read-only memories are ROM,
PROM, EPROM, EEPROM and FLASH.
ROM is the type where erasing is not possible at all. They are factory fabricated, which means the
program that they have to retain, forms the basic structure of their silicon wafer. This makes these ROM
very cheap. However, once they are fabricated, no change is possible, and generally to be produced in
bulk, some extra time is needed for fabrication. Generally, they are ideal for a nished and well-tested
product ready for mass production.
PROM or Programmable Read-Only Memory allows only one time programming (OTP) after which
the device holds the data forever, without giving any chance to erase it. However, they offer more ex-
ibility than the mask-programmable factory-prepared ROM and, hence, more expensive than ROMs.
EPROM or Erasable Programmable Read Only Memory allows erasure as well as reprogramming
facilities, suitable for any prototype development stage. They are more expensive than PROM and
are to be completely erased by exposing to UV radiation for more than 15 minutes. For this erasure, a
small transplant quartz window is provided at the top of its package, by which EPROMs may be easily
distinguished from other ICs.
EEPROM or Electrically Erasable Programmable Read Only Memory (also designated as E
2
PROM
in some cases) does not require UV exposure for erasure and may be electrically erased. The time
required to erase is in milliseconds, much less than EPROMs, making it more suitable for software
development and testing. As both programming and erasure are possible electrically, by generally using
5V DC, they are sometimes referred as a special variety of read/write memory.
FLASH is very much similar to EEPROM, with some marginal difference. EEPROM is byte-wise
erasable, whereas ash is not. Otherwise, they function in almost an identical way.
7.2.2 Read/Write Memory (RAM)
Memory devices described above are non-volatile type, i.e., even if the power is switched off, they
would retain their contents (data or information). This is not so for the following three types of memory
devices, which are used for read-write purpose. In this case, if the power is switched off, they are unable
to retain information within them.
DRAM or Dynamic RAM is the most widely adopted variety of read/write memory in computer sys-
tems. As only one transistor or a FET along with a small capacitor is enough to retain one bit of infor-
mation, a large number of storage cells may be accommodated within these memories. However, data
stored as electrical charge within its capacitors tend to drain out and as a method of preservation, these
cells must be refreshed periodically. Due to these demands of its inherent structure, DRAMs are com-
paratively slower devices. These DRAMs are used in the main memory of the majority of computer
systems. Refer Section 7.5.1 for more information about DRAM.
SRAM or Static RAM offers fastest speed for communication out of all these three read/write memory
types. However, they are more expensive as more number of transistors is necessary to retain each bit
M07_GHOS1557_01_SE_C07.indd 200M07_GHOS1557_01_SE_C07.indd 200 4/29/11 5:12 PM4/29/11 5:12 PM
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.139.83.151