ch06 PDF
ch06 PDF
ch06 PDF
Jin-Fu Li
Department of Electrical Engineering
National Central University
Jungli, Taiwan
Outline
¾ Basic Concepts
¾ Semiconductor Random Access Memories
¾ Read Only Memories
¾ Speed, Size, and Cost
¾ Cache Memories
¾ Performance Considerations
¾ Virtual Memories
Address Data/Instruction
Control Unit
Input/Output System
Processor Memory
k-bit address bus
MAR
A0
A1 Row Decoder
Ak-1
CS Sn-1
Wordni-1
A0
Aj-1 Column Decoder
Sense Amplifier
R/W Read/Write Circuit
m-bit Input/Output
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 8
Organization of Bit Cells in a Memory
RAM Cell
n-1:k
word line
bit - bit
precharge
bit, -bit
word
data
- bit bit
data
N5 N6
write data
word
write
N3 N4
word
bit, -bit
- bit bit
N1 N2
write
cell, -cell
write data
word line
bit
WL=1 WL=0
on + off +
+ Cs Vs Cs Vs
- -
-
V s = V max = V DD − V tn
Q max = C s (V DD − V tn )
The refresh cycle must be performed on every cell in the array with a
minimum refresh frequency of about
1
f refresh ≈
2th
A20-9 /A8-0
..
.
Sense/Write CS
circuits R/W
..
.
Column
address Column decoder
latch
..
.
CAS
D7 D6 D0
Row
Row .. Cell array
address
Row/Column decoder .
latch
address
Column Read/Write
Column ..
address circuits & latches
decoder .
counter
Clock
RAS Mode register Data input Data output
and timing register register
CAS
R/W control
CS Data
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 20
Burst Read Operation in an SDRAM
¾ SDRAMs have several different modes of
operation, which can be selected by writing
control information into a mode register
¾ The burst operations use the block transfer
capability described above as the fast page mode
feature
¾ In SDRAMs, it is not necessary to provide
externally generated pulses on the CAS line to
select successive columns. The necessary control
signals are provided internally using a column
counter and the clock signal
2-bit
decoder
Data
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 25
Refresh Overhead
¾ All DRAMs have to be refreshed
¾ Consider an SDRAM whose cells are arranged in
8K (8192) rows. Suppose that it takes four clock
cycles to access (read) each row. Then it takes
8192x4=32768 cycles to refresh all rows
¾ At a clock rate of 133MHz, the time needed to
refresh all rows is 32768/(133x106)=246x10-6
seconds
¾ Thus, the refreshing process occupies 0.246ms in
each 64-ms time interval. The refresh overhead is
0.246/64=0.0038.
R1 R2 R3 R4 C1 C2 C3 C4
R1 0 1 0 1
1 0 0 0
0 1 0 0 0 0 1 1
R2
0 0 1 0 1 0 0 1
R3 0 0 0 1 0 1 1 0
R4
C1 C2 C3 C4
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 27
Read Only Memory (ROM)
¾ A 4x 4-bit NAND-based ROM array
C1 C2 C3 C4
R1 R1 R2 R3 R4 C1 C2 C3 C4
0 1 1 1 0 1 0 1
R2
1 0 1 1 0 0 1 1
R3
1 1 0 1 1 0 0 1
1 1 1 0 0 1 1 0
R4
Primary cache L1
Secondary cache L1
Main memory
Magnetic disk
Secondary memory
Main
Processor Cache memory
.
.
tag block word .
5 7 Main memory
4
address Block 4095
.
.
tag word .
12 4 Main memory
address Block 4095
.
.
tag set word .
Main memory
6 6 4
address Block 4095
1 0
Vdd
P
Mi
10 0
1
comparison logic
Advanced Reliable Systems (ARES) Lab. Jin-Fu Li, EE, NCU 41
Comparison of Different Mapping Scheme
¾ Direct-mapped cache
Cost: low
Flexibility: low
¾ Associative-mapped cache
Cost: high
Flexibility: high
¾ Set-associative-mapped cache
Cost: medium
Flexibility: medium
PAGE TABLE
…
…
No …
…
=?
Yes