Page 134 - DCAP108_DIGITAL_CIRCUITS_AND_LOGIC_DESIGNS
P. 134
Unit 8: Memory
instructions with corresponding data. If the instructions and data of a program being executed Notes
by a CPU were to reside in secondary storage like a disk, and fetched and loaded one by one
into CPU registers as the program execution proceeded, this would lead to the CPU being idle
most of the time. This is because there is a large speed mismatch between the rate at which CPU
can process data and the rate at which data can be transferred from disk to CPU registers. For
example, a CPU can process data at a rate of about 5 nanosecond/byte and a disk reader can
read data at a speed of about 5 microseconds/byte. Hence, within the time in which a disk can
supply one byte of data a CPU can process 1000 bytes. This would lead to a very slow overall
performance even if a computer used a very fast CPU. To overcome this problem, there is a need
to have a reasonably large storage space that can hold the instructions and data of the program(s)
on which CPU is currently working time to fetch and load data from this storage space into CPU
registers must also be very small as compared to that space from disk storage to reduce the speed
mismatch problem with CPU speed. Every computer has such a storage space known as primary
storage, main memory, or simply memory. It is a temporary storage area built into the computer
hardware. Instructions and data of a program reside mainly in this area when CPU is executing
the program. Physically, this memory consists of some integrated circuit (IC) chips either on the
motherboard or on a small circuit board attached to the motherboard of a computer system. This
built-in memory allows CPU to store and retrieve data very quickly. The rate of fetching data
from this memory is of the order of 50 nanoseconds/byte. Hence, the rate of data fetching from
main memory is about 100 times faster than that from a high speed secondary storage like disk.
8.1 Random Access Memory (RAM)
While memory can refer to any medium of data storage, it usually refers to RAM, or random
access memory. When your computer boots up, it loads the operating system into its memory, or
RAM. This allows your computer to access system functions, such as handling mouse clicks and
keystrokes, since the event handlers are all loaded into RAM. Whenever you open a program,
the interface and functions used by that program are also loaded into RAM.
RAM is a very high-speed type of memory, which makes it ideal for storing active programs and
system processes. It is different than hard disk space in that RAM is made up of physical memory
chips, while hard disks are magnetic disks that spin inside a hard drive. Accessing RAM is much
faster than accessing the hard disk because RAM access is based on electric charges, while the
hard drive needs to seek to the correct part of the disk before accessing data. However, all the
information stored in RAM is erased when the computer’s power is turned off. The hard disk, on
the other hand, stores data magnetically without requiring any electrical power.
To summarize, memory is a vital part of the way computers and many electronic devices function.
While memory and RAM can often be used synonymously, it is good to know about other types
of memory as well. Hopefully you will be able to store the information you have learned in your
own memory.
The RAM (random access memory) is the place in a computer where the operating system,
application programs and data in current use are kept so that they can be quickly reached by
the computer’s processor. RAM is much faster to read from and write to than the other kinds of
storage in a computer, the hard disk, floppy disk and CD-ROM. However, the data in RAM stays
there only as long as your computer is running. When you turn the computer off, RAM loses its
data. When you turn your computer on again, your operating system and other files are once
again loaded into RAM, usually from your hard disk.
The RAM can be compared to a person’s short-term memory and the hard disk to the long-term
memory. The short-term memory focuses on work at hand, but can only keep so many facts in
view at one time. If short-term memory fills up your brain sometimes is able to refresh it from
facts stored in long-term memory. A computer also works this way. If RAM fills up, the processor
LOVELY PROFESSIONAL UNIVERSITY 129