Memory Operations
Memory Operations
Memory Operations
ARCHITECTURE
UNIT – I
BASIC STRUCTURE OF
COMPUTERS
Memory operations
Memory operations - Objective
• On completion of this session, you would be
able to…
• Know the basic operations on memory
• Understand the different steps involved in
those memory operations
Memory Unit
• One of the main components of a digital computer.
• It is used to store data and programs.
• A collection of storage cells and its associated
circuits.
• Each cell can store one bit(either 0 or 1) of
information
• The cells are organized into groups called “Words”.
• The word size is in multiples of 8. Ex,8,16 or 24 etc.,
• Each word can be moved in and out of memory as a
unit.
• Each word in memory is assigned an identification
number, called an address
Basic Memory Operations
• CPU needs to access the memory in order to get the instructions and
data for execution
• The contents of the memory locations needed to be altered to store
the results.
• The two basic operations that can be performed on memory to get
data/instructions from memory and store the result are:
What are the requirements to perform memory read operation?
• Address of the memory location from where data/Instruction is to be
retrieved
• System Bus which contains address, data and control buses as part of it.
• Address bus carries the address of the specified location from which data to be
retrieved.
• Data bus carries the data/instruction after reading from memory.
• A Read control signal by the control unit to instruct the memory to place the data onto
the data bus from the specified location.
What are the requirements to perform memory write
operation?
• Address of the memory location into which the data to be stored.
• Data / Result to be stored in case of memory write operation.
• System Bus which contains address, data and control buses as part of it.
• Address bus carries the address of the location into which data to be saved.
• Data bus carries the data to be saved into memory.
• A Write control line by the control unit to instruct the memory unit to save the data
from the data bus to the specified location.
Basic Memory Operations
• So, Data / Instructions are transferred between CPU and memory using
Address bus(carries address), Data bus(carries data) and control bus
lines(carries Read/Write control signals).
• Two CPU registers are used to interface the CPU to the main memory. These
are the memory address register (MAR) and the memory data register (MDR)
• The MDR is used to hold the data to be stored and / or retrieved in/from the
memory location whose address is held in the MAR.
Memory Read Operation
• Place the address of the location to
be read on the address bus from
MAR.
• Activate the memory read control
signal on the control bus.
• Wait for the memory to retrieve the
data from the addressed memory
location and to place it on the data
bus.
• Read the data from the data bus and
store it in MDR.
• Drop the memory read control signal
to terminate the
Memory Read Operation
• Place the address of the location
to be written on the address bus
from MAR.
• Place the data to be written on
the data bus from MDR.
• Activate the memory write
control signal on the control bus.
• Wait for the memory to store the
data at the addressed location.
• Drop the memory write control
signal to terminate the write
cycle.
Thank you…