Download as ppt, pdf, or txt
Download as ppt, pdf, or txt
You are on page 1of 18

Computer Architecture

Memory Access Methods


Computer Architecture

Group members
Rizwan Hafeez
Naeem Rustam
Mohsin Ali
42, 18, 04
Computer Architecture

Rizwan Hafeez
Memory Access Methods
Ways of locating data stored in main
memory
Three types
Addressed memory
Associative memory
Sequential memory
Addressed Memory
Nearly all memories are of this type,
both ROM and RAM
Uses addresses to select the cells
being read from or written to
Device needs to supply the address in
memory and the transfer direction
(read or write)
Associative Memory
Also called content-addressable memories
(CAM)
Uses the contents of part of the memory
words to select the cells being written or
read
Used mainly in cache memory
Example of an access request:
Search for all words whose highest order 8 bits
contain the value 1101 1110, and return the
value in the first word that matches
Components of Associative Memory

Argument Register

Mask Register

Match Register

Array of memory
locations

Memory Buffer
Any-match Bit
Register
Components of Associative Memory
Argument Register
Holds the argument for an associative search
In previous example: 1101 1110 XXXX
Mask Register
Specifies the field of each word that the memory
should match
In previous example : highest-order 8 bits
Match Register/Match Bits
Indicates which words match the search criterion
Components of Associative Memory
Any Match Bit
Indicates whether any match bits are set
Memory Buffer Register
Holds the value to be stored or the value
just recalled
Computer Architecture

Naeem Rustam
Sequential Access
Data is acquired based on its offset
from the current position of the
read/write head (e.g. next word,
previous word, hundredth word
forward, etc.)
Usually found in magnetic tapes
Memory Management
Information will reside in slowest
memory when it is not in use; then
brought to faster memories when it is
needed
How? Needs a scheme to ensure
required data is in memory when it is
to be read or altered by the processor
These are called memory
management schemes
How much memory do you have?
Total memory = MM + Secondary
memory
MM: high speed; programs reside here
for CPU to access
A cache can be inserted between MM
and processor
Secondary memory: often refers to
magnetic disk memory (e.g. hard disk)
but also includes other types like
floppy, CD-R, Zip, etc.
Definitions
Virtual memory = MM + disk cache
Real Address
Physical memory address
Virtual Address
Program generated address; has
corresponding address in physical
memory (either primary or secondary)
Pages
Blocks of words in memory (64b to 4 KB)
Computer Architecture

Mohsin Ali
Definitions
Addresses consists of
Page field - which page in memory the
data is located
Line field - which part of the page the
data is located
Address Translation
Processor generates virtual address
used to determine where to read from
or write to in physical memory
Virtual address must be translated to a
physical address
Three methods
Direct Mapping
Associative Mapping
Set-Associative Mapping
Computer Architecture

Thank you for Ur Attention


Any Questions?

You might also like