Chapter 3 – Memory Organisation

Computer organisation is the way in which the components are built in computers whereas Computer architecture is the science of integrating those components to achieve a level of functionality and performance this chapter we shall study a high level view of computer architecture  that may be concerned with how the central processing unit (CPU) acts and how it uses computer memory.

Computer Architecture is the field of study of selecting and interconnecting hardware components to create computers that satisfy functional performance and cost goals. It refers to those attributes of the computer system that are visible to a programmer and have a direct effect on the execution of a program.

Computer Architecture concerns with machine Organization, interfaces, application, technology, measurement & simulation that Includes:

  • Instruction set
  • Data formats
  • Principle of Operation
  • Features   (organization of programmable storage, registers used, interrupts mechanism, etc.)

In short, it is the combination of Instruction Set Architecture, Machine Organization and the related hardware.

Inter Connection of Units

CPU sends data, instructions and information to the components inside the computer as well as to the peripherals and devices attached to it. Bus is a set of electronic signal pathways that allows information and signals to travel between components inside or outside of a computer.

The features and functionality of a bus are as follows

  • A bus is a set of wires used for interconnection, where each wire can carry one bit of data.
  • A computer bus can be divided into two types; internal bus and external bus.
  • The internal bus connects components inside the motherboard like, CPU and system memory. It is also called the system bus.
  • The external bus connects the different external devices; peripherals, expansion slots, I/O ports and drive connections to the rest of computer. It is also referred to as the expansion bus.
  • The command to access the memory or the I/O device is carried by the control bus.
  • The address of I/O device or memory is carried by the address bus. The data to be transferred is carried by the data bus.
Instruction Cycle

The instruction cycle represents the sequence of events that takes place as an instruction is read from memory and executed.

memory cycle 1

A simple instruction cycle consists of the following steps

  • Fetching the instruction from the memory.
  • Decoding the instruction for operation.
  • Executing the instruction.
  • Storing in memory.
Instructions Format

Computer understand instructions only in terms of 0s and 1s, which is called the machine language.  A computer program is a set of instruction that describe the steps to be performed for carrying out a computational task.  The processor must have two inputs; instructions and data.

The instruction tell the processor what actions are needed to be performed on the data.  An instruction is divided into two parts; operation (op-code) and operand.

The op-code represents action that the processor must execute and the operand defines the parameters of the action and depends on the operation.

Memory Hierarchy

The hierarchical arrangement of storage in current computer architectures is called the memory hierarchy. It is designed to take advantage of memory locality in computer programs.  Each level of the hierarchy is of higher speed and lower latency, and is of smaller size, than lower levels.

Following diagram shows memory hierarchy in a modern computer system

memory hirechy 2

Memory Organisation

Computer memory is the storage space in computer where data is to be processed and instructions required for processing are stored. The memory is divided into large number of small parts. Each part is called Cell.  Each location or cell has a unique address, which varies from zero to memory size minus one.



A CPU contains a number of register to store data temporarily during the execution of a program. The number differ from processor to processor. Registers are classified as follows :

GENERAL PURPOSE REGISTERS : These registers store data and intermediate results during the execution of a program.

ACCUMULATORS : It is most efficient in data movement, arithmetic and logical operation. It has some special features that the other general purpose registers do not have.  After the execution of arithmetic and logical instructions, the result is placed in the accumulator.  All data transfer between the CPU and device/port are performed through the accumulator.

Special Purpose Registers : A CPU contains a number of special purpose registers for different purpose.

These are

(i) PROGRAM COUNTER (PC) : The program counter keeps track of the address of the instruction which is to be executed next. So it holds the address of the memory location, which contains the next instruction to be fetched from the memory. Its contents is automatically incremented after an instruction has been fetched.

(ii) STACK POINTER (SP) : The stack is a sequence of memory location defined by the user.  It is used to save the contents of a register if it is required during the execution of a program.  the stack pointer holds the address of the last occupied memory location of the stack.

(iii) INSTRUCTION REGISTER : It holds an instruction until it is decoded. Some computers have two types of instruction registers, and so they can fetch and save the next instruction while the execution of the previous instruction is going on.

(iv) MEMORY ADDRESS REGISTER : The memory address register holds the address of the next memory location where the next instruction is to be executed. While the first instruction is being executed, the address of the next memory location is held by it.  The computer’s CPU uses the address bus to communicate which memory address it wants to access, and the memory controller reads the address and then puts the data stored in that memory address back onto the address bus for the CPU to use.

Memory- Memory is made up of large number of cells.

(v) MEMORY DATA ADDRESS : The memory data register (MDR) is the register of a computer’s control unit that contains the data to be stored in the computer storage (e.g. RAM), or the data after a fetch from the computer storage. It acts like a buffer and holds anything that is copied from the memory ready for the processor to use it.

Memory is primarily of three types:

  1. Cache Memory
  2. Primary Memory/Main Memory
  3. Secondary Memory

1. Cache Memory

CPU is much faster than memory.  The problem comes when the CPU issues a memory request, it will not get the data it need for many CPU cycles.  The slower the memory the more cycles the CPU will have to wait.  This problem can be overcome by introducing a small and very fast memory near the CPU. The small, fast memory is called. Cache memory is a very high speed semiconductor memory, which can speed up CPU. It acts as a buffer between the CPU and main memory.

It is used to hold those parts of data and program which are most frequently used by CPU. The parts of data and programs are transferred from disk to cache memory by operating system, from where CPU can access them.

Advantage :

  • Cache memory is faster than main memory.
  • It consumes less access time as compared to main memory.
  • It stores the program that can be executed within a short period of time.• It stores data for temporary use.

Disadvantage :

  • Cache memory has limited capacity.
  • It is very expensive
Buffer : It is a temporary physical storage used to hold data during execution of process from one place to another.

2. Primary Memory (Main Memory)

Primary memory holds only those data and instructions on which computer is currently working. It has limited capacity and data gets lost when power is switched off.

It is generally made up of semiconductor device. These memories are not as fast as registers. The data and instructions required to be processed earlier reside in main memory.

It is divided into two subcategories: RAM and ROM.

Characteristic of Primary Main Memory

These are semiconductor memories.

  • It is known as main memory.
  • Usually volatile memory.
  • Data is lost in case power is switched off
  • It is working memory of the computer.
  • Faster than secondary memories.
  • A computer cannot run without primary memory.


difference between rom and rammemoryorganizationram1

B. Erasable Programmable Read-Only Memory (EPROM) : This type of ROM can have its contents erased by ultraviolet light and then reprogrammed by user/manufacturer. This procedure can be carried out many times; however, the constant erasing and rewriting will eventually render the chip useless.

C. Electrically Erasable Programmable Read-Only Memory (EEPROM) : This type of ROM works in a similar way to Flash memory in that it can its contents can be ‘flashed’ for erasure ad then written to without having to remove the chip from its environment. EEPROMs are used to store a computer system’s BIOS, and can be updated without returning the unit to the factory. In many cases, BIOS updates can be carried out by computer users wishing a BIOS update.


Flash memory is an example of quite a recent type of storage technology known as solid state devices. This type of portable storage has become very popular because of its low price and high storage capacity compared to its rivals, e.g. Floppy disk.

Solid state devices are regarded as being robust and reliable because they have no moving parts with the data stored in semiconductor chips. This technology already exists in the form of Flash memory used to store the Basic Input/Output System (BIOS) of a motherboard.

Unlike ROM, flash memory can be read form and written to and unlike RAM does not require power to retain its data. Although these devices typically cannot hold as much data as hard disks, CD – ROMs and DVDs, the storage capacity is continually increasing.


Virtual memory is a technique that allows the execution of processes which are not completely available in memory. The main visible advantage of this scheme is that programs can be larger than physical memory. Virtual memory is the separation of user logical memory from physical memory.

This separation allows an extremely large virtual memory to be provided for programmers when only a smaller physical memory is available. Following are the situations, when entire program is not required to be loaded fully in main memory. User written error handling routines are used only when an error occured in the data or computation. Certain options and features of a program may be used rarely. Many tables are assigned a fixed amount of address space even though only a small amount of the table is actually used.

3. Secondary Memory (Auxiliary Memory)

The size of the main memory is very small if large data need to be stored in it. Further,the main memory is volatile in nature i.e. the contents are lost when power supply is stopped. To overcome these another memory is used in a computer system called secondary memory or the auxiliary memory. This is large as well as non-volatile in nature. This type of memory is also known as external memory or non-volatile. It is slower than main memory. These are used for storing Data/Information permanently.

CPU directly does not access these memories, instead they are accessed via input-output routines. Contents of secondary memories are first transferred to main memory and then CPU can access it. For example, disk, CD-ROM, DVD, etc.

Characteristics of Secondary Memory

  • These are magnetic and optical memories.
  • It is known as backup memory.
  • It is non-volatile memory.
  • Data is permanently stored even if power is switched off.
  • It is used for storage of the data in the computer.
  • Computer may run without secondary memory.
  • Slower than primary memories.

Storage Devices

Storage devices are also called storage media. It is a hardware device that can hold information.Two main storage devices are used in computers. The primary storage device also known as RAM and the secondary storage device such as a computer hard drive. Secondary storage can be either internal or external storage.

Storage device is required by the computer to save any settings or additional information.

Following are the different types of computer Storage Devices/Secondary memories –

Secondary Memory devices includes :

A. Magnetic Disks : Magnetic disks play two roles in computer systems :

  • Long-term, nonvolatile storage for files, even when no programs are running
  • A level of the memory hierarchy below main memory used as a backing store for virtual memory during program execution

A magnetic disk consists of a collection of platters (generally 1 to 12), rotating on a spindle at 3,600 to 15,000 revolutions per minute (RPM). These platters are metal or glass disks covered with magnetic recording material on both sides, so 10 platters have 20 recording surfaces. The disk surface is divided into concentric circles, called tracks. Each track in turn is divided into sectors.  A sector is the smallest unit that can be read or written.

B. Optical Disks : Optical disks are another type of secondary memory. Many types of optical disks are available in the market like CD (Compact disks), DVD (Digital versatile disks) etc. CD-R are write once CDs i.e. data can be written to them only once. CD-RW on the other hand are rewritable CDs i.e. data can be written and erased many times. Similar variations DVD – R and DVD – RW are also available in the market.

C. Magnetic Tape : Magnetic tape is a long and narrow strip of plastic that thin magnetic material is coated on. Nearly all recording tape is of this type, whether used for recording audio or video or computer data storage.

Magnetic tape recording uses magnetic tape which moves on a recording head. Electrical signals are fed to the recording head, inducing a pattern of magnetization similar to the signal. A playback head can then pick up the changes in magnetic field from the tape and convert it into an electrical signal.

D. Floppy diskette :  A Floppy Disk Drive is a computer disk drive that helps a user to save data to removable diskettes.  8 inch disk drives were first made available in 1971, which were later replaced with 3½ inch floppy disk drives. Due to the limited capacity and reliability of floppy diskettes in many computers they are no longer used with floppy disk drives . They are being replaced with CD-R, other writable discs, and flash drives.

E. CD-ROM disc : Compact Disc-Read Only Memory, CD-ROM drives or optical drives are CD players inside computers that can have speeds in the range from 1x and beyond, and have the capability of playing audio CDs and computer data CDs.

F. CD-R and CD-RW disc : It is also called as a CD writer, CD – WO (Write once), WORM (Write Once Read Many) drive. CD-R is used for CD-Recordable and is a writable disc and drive that is capable of having information written to the disc once and then having that disc read many times after that. If the data is not written to the disc properly, has errors, or has the incorrect information that disc or portions of that disc cannot be erased and is often jokingly referred to as a coaster.

G. Recordable DVD (Digital video Disk)drives : These DVD drives are alternatively referred to as a DVD writer, recordable DVD drives. The recordable DVD drives are  capable of creating DVD discs. They are different from recordable CD drives as they have  many different competing standards for creating DVD discs. For example, DVD – R, DVD – RW, DVD + R, DVD + RW, DVD + R DL (DVD + R9), and DVD-RAM are all different competing standards.

(i) DVD-R DVD-R is called as Digital Versatile Disc – Recordable. DVD-R has features similar to CD-R, where the drive is capable or recording once to a disc and then read many times after it has been created. DVD-R is an approved standard by DVD Forum and the drives are capable of recording to DVD-R discs. These discs are also known as DVD-5 and DVD -10. DVD-R discs are compatible with most stand alone DVD players and computer DVD-ROM drives.

(ii) DVD-RW(DVD-R/W) These are called as Digital Versatile Disc-Read/Write. DVD-RW is an approved standard by DVD Forum. It is based on a technology that enables a user to read and write to a DVD-RW or DVD-R disc several times. DVD-RW discs are compatible with most stand-alone DVD players and computer DVD-ROM drives.

H. Jump drive and USB flash drive : USB flash drive is a portable drive that is as small as the size of your thumb. Other such portable drives include data stick, pen drive, key chain drive ,thumb drive .It connects to the computer USB port. Flash drives are available in different sizes such as 256MB, 512MB, 1GB, 5GB, and 16GB . They can easily store and transfer information.

A flash drive is used by inserting it onto the front or back of USB port or hub. After inserting the flash drive , open the My Computer , you can see as “Removeable Disk”, “Flash drive”, or as the manufacturer’s name. When the drive has been identified , data can be copied onto the flash drive by a simple copy paste or just dragging and dropping onto the flash drive icon.

I. Hard Drive : It is called as the hard disk drive. It is represented sometimes by its short name as HD or HDD. It is the computer’s main storage area that permanently stores the data on to the computer. It consists of one or more hard drive platters inside of air sealed casing. The hard drives are contained in an internal drive bay at the front of the computer. They connect to the mother board using ATA, SCSI or a SATA cable .

J. Memory card : These are referred to as a flash memory card or a memory card . The  memory card type of storage media is used in digital cameras, digital camcorders, handheld computers,printers , MP3 players and cell phones. They can store a huge number of pictures, videos, music, and other data. MicroSD flash memory card is one such example of a memory card . There are a number of different types of memory cards in the market that vary in size, compatibility, and storage capacity.

K. Memory stick : Sony Memory Stick was first invented by Sony in October 1998 . It is a flash memory card used with Sony digital cameras . This flash memory card is used with other Sony products also. The capacity of the Memory Sticks range from sizes of 4MB to 256GB . They can have maximum capacity of 2TB, although till now the sticks of this capacity have not been produced .

Tape cassette

A tape cassette is magnetically thin coated piece that is wrapped with plastic around wheels. These are capable of storing data. Tape is far cheaper than other storage mediums but is much slower than the jump drives , memory sticks etc . Tapes are not much in use these days for faster and more reliable solutions like disc drives, hard drives, and flash drives.

L. Zip Diskette : Zip Diskette are made out of a much harder plastic and are much bigger than the standard floppy diskette. Zip drive is a medium capacity removable floppy disk storage system. Zip drives are not much in use because of need of mass portable storage .

M. Blue ray disk : Blu-ray (not Blue-ray) also known as Blu-ray Disc (BD), is the name of a new optical disc format jointly developed by the Blu-ray Disc Association (BDA), a group of the world’s leading consumer electronics, personal computer and media manufacturers (including Apple, Dell, Hitachi, HP, JVC, LG, Mitsubishi, Panasonic, Pioneer, Philips, Samsung, Sharp, Sony, TDK and Thomson). The format was developed to enable recording, rewriting and playback of high-definition video (HD), as well as storing large amounts of data. The format offers more than five times the storage capacity of traditional DVDs and can hold up to 25GB on a single-layer disc and 50GB on a dual-layer disc. This extra capacity combined with the use of advanced video and audio codecs will offer consumers an unprecedented HD experience.

Secondary Memory Device and their storage Method and capacity.

memory organization


1 Bit = Binary digit

The term ‘Bit’ is short for Binary digit.

1 Nibble = 4 Bits

8 bits =1 Byte = 2 Nibble