CENG 4480 L09 Memory 3 Bei Yu Chapter 11 Memories Reference: CMOS VLSI Design A Circuits and Systems Perspective by H.E.Weste and D.M.Harris 1
Memory Arrays Memory Arrays Random Access Memory Serial Access Memory Content Addressable Memory (CAM) Read/Write Memory (RAM) (Volatile) Read Only Memory (ROM) (Nonvolatile) Shift Registers Queues Static RAM (SRAM) Dynamic RAM (DRAM) Serial In Parallel Out (SIPO) Parallel In Serial Out (PISO) First In First Out (FIFO) Last In First Out (LIFO) Mask ROM Programmable ROM (PROM) Erasable Programmable ROM (EPROM) Electrically Erasable Programmable ROM (EEPROM) Flash ROM 2
Read-Only Memories Read-Only Memories are nonvolatile Retain their contents when power is removed Mask-programmed ROMs use one transistor per bit Presence or absence determines 1 or 0 3
NOR ROM 4-word x 6-bit NOR-ROM Selected word-line high Represented with dot diagram A1 A0 weak pseudo-nmos pullups Word 0: 010101 Word 1: 011001 Word 2: 100101 Word 3: 101010 2:4 DEC ROM Array Y5 Y4 Y3 Y2 Y1 Y0 Looks like 6 4-input pseudo-nmos NORs 4
EX: NOR ROM Draw 4-word 4-bit NOR-ROM structure and dot diagram Word 0: 0100 Word 1: 1001 Word 2: 0101 Word 3: 0000 A1 A0 weak pseudo-nmos pullups 2:4 DEC ROM Array Y5 Y4 Y3 Y2 Y1 Y0 5
NAND ROM 4-word x 4-bit NAND-ROM All word-lines high with exception of selected row 6
EX. NAND ROM What s it function? WL[0]=0: WL[1]=0: WL[2]=0: WL[3]=0: 7
NOR ROM v.s. NAND ROM NOR ROM: (+) Faster (-) Larger Area (VDD lines) A1 A0 2:4 DEC weak pseudo-nmos pullups ROM Array Y5 Y4 Y3 Y2 Y1 Y0 NAND ROM: (+) High density, small area (-) Slower delay grows quadratically with the number of series transistors discharging the bitline. 8
NOR ROM Array Layout* Unit cell is 12 x 8 λ (about 1/10 size of SRAM) word3 word2 word1 word0 bit5 bit4 bit3 bit2 bit1 bit0 9
Row Decoders* ROM row decoders must pitch-match with ROM Only a single track per word! A0 A0 A1 A1 A0 A0 A1 A1 word3 word2 word1 word0 10
Complete ROM Layout* 11
PROMs and EPROMs* Programmable ROMs Build array with transistors at every site Burn out fuses to disable unwanted transistors Electrically Programmable ROMs Use floating gate to turn off unwanted transistors EPROM, EEPROM, Flash Source Gate Drain Polysilicon Floating Gate Thin Gate Oxide (SiO 2) n+ n+ p bulk Si 12
NOR / NAND Flash Memory* NOR flash: Intel 1988 NAND flash: Toshiba 1989 NOR: faster, more expensive [Toshiba 08] NAND: higher density 13
Building Logic with ROMs ROM as lookup table containing truth table n inputs, k outputs requires 2 n words x k bits Changing function is easy reprogram ROM Finite State Machine n inputs, k outputs, s bits of state Build with 2 n+s x (k+s) bit ROM and (k+s) bit reg inputs n DEC 2 n wordlines ROM Array inputs n ROM k s state outputs k s k outputs 14
Example: RoboAnt Let s build an Ant Sensors: Antennae (L,R) 1 when in contact Actuators: Legs Forward step F Ten degree turns TL, TR Goal: make our ant smart enough to get out of a maze Strategy: keep right antenna on wall L R (RoboAnt adapted from MIT 6.004 2002 OpenCourseWare by Ward and Terman) 15
16
Lost in space Action: go forward until we hit something Initial state 17
Bonk!!! Action: turn left (rotate counterclockwise) Until we don t touch anymore 18
A little to the right Action: step forward and turn right a little Looking for wall 19
Then a little to the right Action: step and turn left a little, until not touching 20
Whoops a corner! Action: step and turn right until hitting next wall 21
Simplification Merge equivalent states where possible 22
State Transition Table Current state Inputs Next state Output values S 1:0 L R S 1:0 TR TL F 00 0 0 00 0 0 1 Lost RCCW Wall1 Wall2 00 1 X 01 0 0 1 00 0 1 01 0 0 1 01 1 X 01 0 1 0 01 0 1 01 0 1 0 01 0 0 10 0 1 0 10 X 0 10 1 0 1 10 X 1 11 1 0 1 11 1 X 01 0 1 1 11 0 0 10 0 1 1 11 0 1 11 0 1 1 23
ROM Implementation 16-word x 5 bit ROM S 1 S 0 L R 4:16 DEC 0000 0001 0010 0011 0100 0101 0110 0111 1000 1001 1010 1011 1100 1101 1110 1111 L, R ROM S' 1:0 S 1:0 TL, TR, F S 1 ' S 0 ' TR'TL' F' 24
PLAs A Programmable Logic Array performs any function in sum-of-products form. Literals: inputs & complements Products / Minterms: AND of literals Outputs: OR of Minterms Example: Full Adder s = abc + abc + abc + abc AND Plane OR Plane bc ac ab abc abc abc abc Minterms c = ab + bc + ac out a b c s cout Inputs Outputs 25
NOR-NOR PLAs ANDs and ORs not very efficient in CMOS Dynamic or Pseudo-nMOS NORs very efficient Use DeMorgan s Law to convert to all NORs AND Plane OR Plane AND Plane OR Plane bc ac ab abc abc abc abc bc ac ab abc abc abc abc a b c s c out a b c s c out 26
PLA Schematic & Layout AND Plane OR Plane bc ac ab abc abc abc abc a b c s c out 27
PLAs vs. ROMs The OR plane of the PLA is like the ROM array The AND plane of the PLA is like the ROM decoder PLAs are more flexible than ROMs No need to have 2 n rows for n inputs Only generate the minterms that are needed Take advantage of logic simplification 28
RoboAnt PLA Convert state transition table to logic Karnaugh map S 1:0 L R S 1:0 TR TL F 00 0 0 00 0 0 1 00 1 X 01 0 0 1 00 0 1 01 0 0 1 01 1 01 0 1 0 01 0 1 01 0 1 0 01 0 0 10 0 1 0 10 X 0 10 1 0 1 10 X 1 11 1 0 1 11 1 X 01 0 1 1 11 0 0 10 0 1 1 11 0 1 11 0 1 1 29 TR TL = = S S S 1 0 0 F = S + S 1 0
EX. RoboAnt Dot Diagram S1' = S S + LS + LRS 1 0 1 0 S0' = R + LS + LS TR = TL = S S S 1 0 0 F = S + S 1 0 1 0 30
Memory Arrays* Memory Arrays Random Access Memory Serial Access Memory Content Addressable Memory (CAM) Read/Write Memory (RAM) (Volatile) Read Only Memory (ROM) (Nonvolatile) Shift Registers Queues Static RAM (SRAM) Dynamic RAM (DRAM) Serial In Parallel Out (SIPO) Parallel In Serial Out (PISO) First In First Out (FIFO) Last In First Out (LIFO) Mask ROM Programmable ROM (PROM) Erasable Programmable ROM (EPROM) Electrically Erasable Programmable ROM (EEPROM) Flash ROM 31
CAMs* Extension of ordinary memory (e.g. SRAM) Read and write memory as usual Also match to see which words contain a key adr data/key read write CAM match 32
10T CAM Cell* Add four match transistors to 6T SRAM 56 x 43 λ unit cell word bit bit_b match cell cell_b 33
CAM Cell Operation* Read and write like ordinary SRAM For matching: CAM cell Leave wordline low Precharge matchlines Place key on bitlines Matchlines evaluate Miss line address read/write row decoder column circuitry data clk weak miss match0 match1 match2 match3 Pseudo-nMOS NOR of match lines Goes high if no words match 34