Computer Memory Notes

Definition of Computer Memory

The unit that is used to store data, information, programs, and instruction either temporarily or permanently is called memory. Computer memory refers to devices that are used to store data or programs (sequences of instructions) on a temporary or permanent basis for use in an electronic digital computer. Computers represent information in binary code, written as sequences of 0’s and 1’s. For example RAM, ROM, Hard Disk, CD/DVD, etc.

 

Computer Memory Representation

In computing, a memory address is a reference to a specific memory location used at various levels by software and hardware. Memory addresses are fixed-length sequences of digits. Computer data storage, often called storage or memory, is a technology consisting of computer components and recording media that are used to retain digital data. It is a core function and fundamental component of computers.

A modern digital computer represents data using the binary numeral system. Text, numbers, pictures, audio, and nearly any other form of information can be converted into a string of bits, or binary digits, each of which has a value of 1 or 0. The most common unit of storage is the byte, equal to 8 bits. A piece of information can be handled by any computer or device whose storage space is large enough to accommodate the binary representation of the piece of information, or simply data.

Physical addresses

A digital computer’s memory, more specifically main memory, consists of many memory locations, each having a physical address, and a code, which the CPU (or other device) can use to access it. Generally, only system software, i.e. the BIOS, operating systems, and some specialized utility programs (e.g., memory testers), address physical memory using machine code operands or processor registers, instructing the CPU to direct a hardware device, called the memory controller, to use the memory bus or system bus, or separate control, address and data busses, to execute the program’s commands. The memory controllers’ bus consists of several parallel lines, each represented by a binary digit (bit).

The width of the bus, and thus the number of addressable storage units, and the number of bits in each unit, varies among computers.

A computer program uses memory addresses to execute machine code, and store and retrieve data. In early computers, logical and physical addresses corresponded, but since the introduction of virtual memory, most application programs do not know physical addresses.

The most fundamental unit of computer memory is the bit. A bit can be a tiny magnetic region on a hard disk, a tiny dent in the reflective material on a CD or DVD, or a tiny transistor on a memory stick. Whatever the physical implementation, the important thing to know about a bit is that, like a switch, it can only take one of two values: it is either “on” or “off”.

 

A collection of 8 bits is called a byte and (on the majority of computers today) a collection of 4 bytes, or 32 bits, is called a word.

For example, the text “hello” would take up 5 bytes of storage, one per character. The text “12345” would also require 5 bytes

 

Memory Structure

  1. Primary Memory

The memory unit which stores data and instructions to run a computer system is called main memory. Refers to physical memory that is internal to the computer. Primary storage, or internal memory, is computer memory that is accessible to the central processing unit of a computer without the use of the computer’s input/output channels. Primary storage is used to store data that is likely to be in active use.

The computer can manipulate only data that is in the main memory. Therefore, every program you execute and every file you access must be copied from a storage device into main memory. The amount of main memory on a computer is crucial because it determines how many programs can be executed at one time and how much data can be readily available to a program. Thus these memory units store data and instruction temporarily. Primary storage is typically very fast, as in the case of RAM. RAM is also volatile, losing the stored information in the event of power loss, and quite expensive.

Types of Main Memory

  1. RAM (Random access Memory)

RAM is called volatile memory, which means that it stores data and instructions that the computer is using at the present moment when the power is on and it loses its contents when the power is off. The RAM is called read/write memory where any data or instructions can be read or written randomly.

The primary functions of RAM:

  1. It stores data or programs and other information that can be quickly accessed by the CPU at the time of execution at a consistent rate.
  2. It stores a copy of the main software program that controls the general operations of the computer. This copy is loaded into the main memory when the computer power is on.
  3. It stores data that has been input from the keyboard or other input devices until instructions call for the data to be transferred into the CPU for processing.

Note: The disadvantage of RAM over physically moving media is cost and the loss of data when power is turned off. For these reasons, nearly all PCs have disc storage as “secondary storage. and its storage capacity ranges from MB to GB.

Types of RAM:

  1. SRAM (static Random Access memory):

The word “static” indicates that the memory retains its contents as long as power remains applied, unlike dynamic RAM (DRAM) which needs to be periodically refreshed whereas SRAM does not need to refresh (i.e. recharging the memory circuit chips) and SRAM is a little more expensive, but faster more reliable than DRAM. SRAM is also easier to control.

  1. DRAM (Dynamic Random Access Memory):

DRAM is slower, cheaper, and popular than SRAM. DRAM is called dynamic because it must constantly be refreshed or it will lose the data that it is supposed to be storing. Refreshing DRAM consists of reading the contents from the DRAM and immediately writing them back to the DRAM.

These memory cells need to be constantly refreshed.

Types of DRAM:

  1. A) SDRAM (Synchronous DRAM): Synchronous dynamic random access memory (SDRAM) is dynamic random access memory (DRAM) that has a synchronous interface which means it is directly dependent on the clock speed of the entire system. The SDRAM can handle higher bus speeds. The SDRAM is faster than DRAM i.e. the SDRAM could operate at up to 100MHz.
  2. B) RDRAM (Rambus DRAM):

Stands for “Rambus Dynamic Random Access Memory.” It is a type of RAM made by Rambus (big surprise) and is the fastest type of computer memory available. Typical SDRAM can transfer data at speeds up to 133 MHz, while standard RDRAM can crank it up over 1 GHz. Though some motherboards can use RDRAM as system memory, it is so fast, that most boards cannot fully benefit from the speed. Because of this, RDRAM is typically used for video memory on graphics accelerator cards, for cache memory (located on the CPU), and for system memory in high-performance workstations and servers.

  1. C) VRAM(video-DRAM): 

It is another type of DRAM that is used in PCs to handle graphical data and display images on the screen. it is called display or graphic memory. This memory chip is mounted on display cards, quite fast, as it needs to respond quickly to the CPU’s instructions and constantly refresh and update the screen image so that there is no flicker.

  1. Cache memory

There is a small amount of high-speed memory that lies between the CPU and the main memory which is used to improve the processing speed of CPUs by storing frequently used data and instruction is called cache memory. Cache memory is random access memory (RAM) that a computer microprocessor can access more quickly than it can access regular RAM. As the microprocessor processes data, it looks first in the cache memory and if it finds the data there (from a previous reading of data), it does not have to do the more time-consuming reading of data from larger memory. The speed of the CPU is extremely high compared to the access time of the main memory. Therefore, the performance of the CPU decreases due to the slow speed of the main memory so to decrease the mismatch in operating speed a small memory chip is attached between CPU and main memory which is called cache memory. These memories are very expensive as have a bigger size of cache memory hence their size is normally kept small. Modern computers have two types of cache: Level 1 (L1): Which is called primary cache or internal cache is directly built into CPU chips which have very small capacity ranges from 8KB to 64KB. For example: Pentium II uses an L1 cache LEVEL2: Which is not part of the processor chip or external chip and consists of a high-speed SRAM chip. The L2 cache is slightly slower than the L1 cache but larger capacity of up to 2MB.

  1. Non-volatile memory-ROM

NVM or non-volatile storage, is computer memory that can retain the stored information even when not powered. Examples of non-volatile memory include read-only memory, flash memory, most types of magnetic computer storage devices (e.g. hard disks, floppy disk drives, and magnetic tape), and optical disc drives. Non-volatile memory is typically used for the task of secondary storage, or long-term persistent storage. The ROM that type of memory chip that stores data that can be Read only. That is the data stored in ROM cannot be modified hence named Read only. Thus ROM consists of data and a set of program instructions to load the computer system when you first turn on the computer. These sequences of instructions are stored permanently in ROM chips often by chip manufacturing companies which is called firmware. Note: most digital devices such as calculators, mobile, and laser printer uses ROM.

Types of ROM:

  1. PROM (Programmable Read-only memory):

A PROM is a blank memory chip on which data can be written only once and can be read many times but cannot changed data. Once the program has been written onto PROM, it remains there permanently. The difference between ROM and PROM is that ROM is programmed during the manufacturing process whereas PROM is manufactured as a blank memory. To write data on PROM you need special components PROM burner. The process of programming a PROM is called burning the PROM.

  1. EPROM (Erasable Programmable Read-only memory):

EPROM chips are developed as an improvement over PROM chips. It works as PROM except that data written can be erased. so to erase data it uses special ultraviolet light and then new data can be written. To change instructions on the EPROM chip, the chip must be taken out from the machine. In EPROM, we cannot make changes in the data individually that have already been written. To write new data or delete existing data, we have to erase all the data from the EEPROM.

  1. EEPROM (Electrically Erasable Read-only memory):

EEPROM chip avoids the inconvenience of having to take chips out of the computer to change data and instructions. instead, changes are made under software control. Unlike EPROM we can make changes to the existing data without erasing the entire data EEPROM requires data written and erased one bit at a time. But EEPROM is more expensive than other ROMs.

  1. Flash Memory:

Flash Memory is a special type of EEPROM that can be programmed and erased in blocks instead of one bit at a time. These memories are popular in the world and are commonly used in pen drives, Digital cameras, mobile phones, etc. The modern PC uses flash memory to store instructions which makes it easy to update. Flash memory gets its name because the microchip is organized so that a section of memory cells is erased in a single action or “flash.” Flash memory is non-volatile computer memory that can be electrically erased and reprogrammed.

Secondary memory (Auxiliary memory)

Secondary memory is where programs and data are kept on a long-term basis. Common secondary storage devices are the hard disk and floppy disks. Secondary memory (or secondary storage) is the slowest and cheapest form of memory. It cannot be processed directly by the CPU. It must first be copied into primary storage (also known as RAM). Secondary memory devices include magnetic disks like hard drives and floppy disks; optical disks such as CDs and CDROMs; and magnetic tapes, which were the first forms of secondary memory.

  1. A) Magnetic Tape:

Magnetic tape is the most popular storage medium for large data, which are sequentially accessed and processed. the magnetic tape medium is a plastic ribbon, which is ½” or ¼” wide and 50 to 2400 feet long. It is coated with a magnetic recording material, such as iron oxide. This type of device is still used for large data backup because these are cheaper than other devices. Like audio or videotape, the magnetic tape used in computer systems can also erased and reused indefinitely. old data on a tape are automatically erased, as new data are recorded in the same area. Tapes for computers are similar to the tapes used to store music. Accessing data on tapes, however, is much slower than accessing data on disk.

  1. B) Magnetic Disk:

A magnetic disk is a circular disk which is coated with magnetic material. the disk rotates at a very high speed inside the computer drive. Data is stored on both the surface of the disk. magnetic disks are most popular for direct access storage devices. Each disk consists of several indivisible concentric circles called tracks. The information is recorded on tracks of a disk surface in the form of magnetic spots. A good example of a magnetic disk is the hard disk.

  • Hard Disk The hard disk is a direct-access storage medium with a rigid magnetic disk. The disk is divided into the number of tracks and each tracks are divided into sectors. A hard disk uses round, flat disks called platters, coated on both sides with a special media material designed to store information in the form of magnetic patterns. The platters are mounted by cutting a hole in the center and stacking them onto a spindle. The platters are rotated at very high speed, driven by a special spindle motor connected to the spindle. Each platter consists of a READ/WRITE head to read and write data. The disks are rotated at very high speed (usually around 7200 RPM-revolution per minute.)
  • Floppy Disk Floppy disk is a round, flat piece of flexible plastic coated with magnetic oxide. These are small removal and media storage devices. The data is recorded on thin plastic film. A floppy disk is a soft magnetic disk and it is a thin piece of flexible plastic called a floppy disk, also called floppy Diskette. They are removable disks. A floppy disk is inserted inside the computer the floppy drive when needed. These are different sizes of floppy disks 5.25” or 3.5” having capacity 1.2MB and 1,44MB respectively.
  1. C) Optical Disk

An optical disk is a random access storage medium. It is made up of glass. Optical disks use light technology where a laser beam is projected and reflected light is observed. As compared to magnetic tape and disk, the optical disk is a relatively new secondary storage medium. An optical disk storage system consists of a rotating disk that is coated with a thin metal or some highly reflective material. This type of disk uses laser beam technology for READ/WRITE data. Due to the use of laser beam technology, optical disks are also known as laser disks or optical laser disks. Unlike magnetic disks, which have several concentric tracks, an optical disk has one long track, which starts at the outer edge and spirals inwards to the center. The optical disk has no mechanical R/W arm movements.

Advantages of optical disks:

  1. The cost-per-bit of storage for optical disks is very low, because of their low cost.
  2. The use of a single spiral track makes optical disks an ideal storage medium for reading large blocks of sequential data such as music.
  3. Optical disks have no mechanical read/write, which makes optical disks a more reliable storage medium than magnetic tapes or disks.
  4. Due to their compact size and lightweight, optical disks are easy to handle, store, and port from one place to another.

Limitation:

  1. The data access speed for optical disks is slower than for magnetic disks.
  2. Optical disk requires a more complicated drive mechanism than magnetic disks.

Types of optical disks:

  1. CD-ROM (compact-disk read-only memory): it is a music CD technology and works much like the music CDs used in the music system. The CD-ROM disk is a shiny, silver color metal disk. it has a storage capacity of about 650MB or more and it is a read-only storage medium that cannot be modified.
  2. CD-RW (compact disk read/write): CD-RW is a CD-Rewritable disc and this is a new type of CD that enables us to write onto it in multiple sessions. Thus we can treat the optical disk just like a floppy disk or hard disk writing onto multiple times.
  3. DVD (Digital Versatile Disc): It is a family of optical discs that are the same overall dimension of a CD, but have significantly higher capacity. DVDs are double-sided, whereas CD’s are single-sided. it needs a DVD drive and its capacity ranges from 4.5 GB to 17GB.

 

Leave a Reply

Your email address will not be published. Required fields are marked *