42
Digital Circuit Design and Language Memory and Programmable Logic Chang, Ik Joon Kyunghee University

Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

  • Upload
    ngonhi

  • View
    239

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Digital Circuit Design and Language

Memory and Programmable Logic

Chang, Ik JoonKyunghee University

Page 2: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Memory Classification based on functionality ROM : Read-Only Memory RWM : Read-Write Memory

RWM NVRWM ROM

Random Access Memory (RAM)

Non-Random Access

EPROMEEPROMFLASH

PROMSRAMDRAM

FIFOLIFO

RegisterCAM

Page 3: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Memory Hierarchy

Register in CPU L1 / L2 Cache : SRAM Mass Storage: HDD, Non-volatile memory

Page 4: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

How to Make Programmable Logic? Fuse / Anti-Fuse

SRAM-based Wiring

Flash-based Wiring

Page 5: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Memory Classification based on functionality ROM : Read-Only Memory RWM : Read-Write Memory

RWM NVRWM ROM

Random Access Memory (RAM)

Non-Random Access

EPROMEEPROMFLASH

PROMSRAMDRAM

FIFOLIFO

RegisterCAM

Page 6: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Storage Cell (SRAM vs. DRAM)

6T SRAM 1T DRAM

SRAM : Large Size, but fast speed (compared to DRAM), no refresh operation

DRAM: Small Size, but low speed (compared to SRAM), refresh operation is indispensable

WL: Word-line, BL: Bit-line

Page 7: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Random Access Memory: Architecture

Word 0Word 1Word 2 Storage

cell

M bits M bits

S0

A0

K = log2N

Word 0Word 1Word 2 Storage

cell

S0

Input-Output(M bits)

Input-Output(M bits)

S1

S2

SN-2

SN-1Word N-2Word N-1

A1●

N W

ords

AKWord N-2Word N-1

We need a row decoder to reduce # of address pin But, Height >> Width

Page 8: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Random Access Memory: Architecture (Cont.)

Row Decoder + Column Decoder

Page 9: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Random Access Memory: Hierarchical Architecture

Hierarchical architecture reduces wiring Only one block is activated → low power dissipation

Globalamplifier/driver

Controlcircuitry

Global data busBlock selector

Block 0

Rowaddress

Columnaddress

Blockaddress

Block i Block P 2 1

I/O

Page 10: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Random Access Memory: read and write operation

Timing Diagram

Write operation1.Transfer the binary address of the desired word to the address lines.

2.Transfer the data bits that must be stored in memory to the data input lines.

3.Activate the write input Read operation1.Transfer the binary address of the desired word to the address lines.

2. Activate the read input.

Page 11: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Random Access Memory: Address Multiplexing

Addressbus

RAS

RAS-CAS timing

Row Address

Column Address

CAS

Address Multiplexing in 64K DRAM

DRAM: Timing Multiplexed Addressing

AddressBus

Address transitioninitiates memory operation

Address

SRAM: Timing Self-timed

To reduce # of address pin, DRAM uses timing multiplexed addressing

Page 12: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Memory Yield and Reliability Degradation

In scaled technologies, it is challenging to deliver good yield and reliability in memory

Page 13: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

What Degrades Yield and Reliability? (PVT Variation)

Page 14: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

What Degrades Yield and Reliability? (Many Noise Source)

SA

Ccross

BL 9

BLBL

BL 99

Coupling Noise (Cross-talk)

Soft-Error Noise

Page 15: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Solution: Redundancy

Row / Column replacement improves memory yield

Page 16: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Solution: Hamming Code

Parity Generation Rule

1 2 3 4 5 6 7 8 9 10 11 12P1 P2 1 P4 1 0 0 P8 0 1 0 0

Bit positionEx) 8-bit data = 11000100

P1=XOR of bits(3,5,7,9,11)=0, P2=XOR of bits(3,6,7,10,11)=0P4=XOR of bits(5,6,7,12)=1, P8=XOR of bits(9,10,11,12)=1

C1=XOR of bits (1,3,5,7,9,11) C2=XOR of bits (2,3,6,7,10,11)C4=XOR of bits (4,5,6,7,12) C8=XOR of bits (8,9,10,11,12)

Page 17: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

1 2 3 4 5 6 7 8 9 10 11 120 0 1 1 1 0 0 1 0 1 0 01 0 1 1 1 0 0 1 0 1 0 00 0 1 1 0 0 0 1 0 1 0 00 0 1 1 1 1 0 1 0 1 0 01 0 1 1 0 0 0 1 0 1 0 0

Bit positionNo Error

Error in bit 1Error in bit 5

Error in bit 1, 5C8 C4 C2 C1

0 0 0 00 0 0 10 1 0 10 1 1 00 1 0 0

No ErrorError in bit 1Error in bit 5

Error in bit 1, 5

Error Detect (O), Correction (O)Error Detect (O), Correction (O)Error Detect (O), Correction (O)

Hamming Code enables single-bit error detection and correction

Error in bit 6

Error in bit 6Error Detect (X), Correction (X)

Solution: Hamming Code (Cont.)

Page 18: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

1 2 3 4 5 6 7 8 9 10 11 12 130 0 1 1 1 0 0 1 0 1 0 0 P13

Bit position

Solution: SECDED (Single Error Cor., Double Error Det.)

P13 = XOR of bits (1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12)

C1=XOR of bits (1,3,5,7,9,11) C2=XOR of bits (2,3,6,7,10,11)C4=XOR of bits (4,5,6,7,12) C8=XOR of bits (8,9,10,11,12)

C = C8+C4+C2+C1, P = XOR of bits (1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13)

If C=0 and P=0, No error occurredIf C=1 and P=1, A single error occurred, which can be correctedIf C=1 and P=0, A double error occurred, which is detected but cannot be correctedIf C=0 and P=1 An error occurred in the P13 bit

Page 19: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Memory Classification based on functionality ROM : Read-Only Memory RWM : Read-Write Memory

RWM NVRWM ROM

Random Access Memory (RAM)

Non-Random Access

EPROMEEPROMFLASH

PROMSRAMDRAM

FIFOLIFO

RegisterCAM

Page 20: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

ROM (Read-Only Memory)

k = 5,n = 8

Page 21: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Programming Rom According to Table

‘1’ ‘0’

Page 22: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Read-Only Memory Cells

WL

BL

WL

BL

1WL

BL

WL

BL

WL

BL

0

VDD

WL

BL

GND

Diode ROM MOS ROM 1 MOS ROM 2

Page 23: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Read-Only Memory: MOS-NOR ROM

WL[0]

GND

BL [0]

WL [1]

WL [2]

WL [3]

VDD

BL [1]

Pull-up devices

BL [2] BL [3]

GND

Page 24: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Read-Only Memory: Mask Programming

Programming using theActive Layer Only

Polysilicon

Metal1

GND Line

Metal1 on Diffusion

Cell (9.5λ x 7λ)

Vender should prepare customized mask (expensive)

Page 25: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Read-Only Memory: Contact Programming (PROM)

‘Inact fuse’ will be removed by high field

Polysilicon

Metal1

GND Line

Metal1 on Diffusion

Cell (11λ x 7λ)

Programmming usingthe Contact Layer Only

Page 26: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Memory Classification based on functionality ROM : Read-Only Memory RWM : Read-Write Memory

RWM NVRWM ROM

Random Access Memory (RAM)

Non-Random Access

EPROMEEPROMFLASH

PROMSRAMDRAM

FIFOLIFO

RegisterCAM

Page 27: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

27

Flash MemoryFloating gate

Source

Substrate

GateDrain

n+ n+_p

tox

tox

Device cross-section Schematic symbol

G

S

D

0 V

-5 V 0 V

DS

Removing programming voltage leaves charge trapped

5 V

-2.5 V 5 V

DS

Programming results inhigher VT.

20 V

10 V 5 V 20 V

DS

Tunneling injection

Page 28: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Programmable Logic Device (PLD)

Page 29: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Programmable Logic Array

Programmable AND array

Programmable OR array

F1=AB’ + AC + A’BC’F2= (AC + BC)’

Page 30: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Programmable Array Logic

PAL-With a fixed OR array and a programmable AND array. Not as flexible as the PLA (Only the AND gate are programmable.)

Page 31: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Programmable Array Logic: Example

( , , , ) (2,12,13)

( , , , ) (7,8,9,10,11,12,12,14,15)

( , , , ) (0, 2,3, 4,5,6,7,8,10,11,15)

( , , , ) (1, 2,8,12,13, )

w A B C D

x A B C D

y A B C D

z A B C D

=

=

=

=

∑∑∑∑

' ' ' '

' ' '' ' ' ' ' ' ' ' '' ' ' ' '

w ABC A B CDx A BCDy A B CD B Dz ABC A B CD AC D A B C D

w AC D A B C D

= += += + += + + +

= + +

K-Map

Page 32: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Programmable Array Logic: Example (Cont.)

Page 33: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Sequential Programmable Devices

Sequential (or simple) Programmable Logic Device (SPLD)

Complex Programmable Logic Device (CPLD)

Field Programmable Gate Array (FPGA)

+ Unlike combinational PLD’s, includes both gates and flip-flops

Page 34: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Sequential Programmable Logic Device

Sequential Programmable Logic Device (SPLD)

Basic Macro-cell Logic of SPLD

Page 35: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Complex Programmable Logic Device

Multiple PLD’s are interconnected through a programmable switch matrix

Page 36: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Field Programmable Gate Array Look up table A truth table stored in SRAM, which provides the combinational

circuit functions

Multiplexers / Gates / Flip-flops

Example: Xilinx, Altera

Page 37: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Xilinx Spartan : Basic Architecture

The loop up table of CLB can be utilized as block memory

Page 38: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Xilinx Spartan : Programmable Interconnect Point

PIP = transmission gate whose is controlled by SRAM cell

Page 39: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Xilinx Spartan : I/O Blocks (IOB)

IOB’s are bi-directional The output buffer should be implemented as tri-gates

Page 40: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Xilinx Spartan : Distributed RAM

Single-Port RAM

dual-Port RAM

CLB is able to form single-port / dual-port RAM

Page 41: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Xilinx Spartan ΙΙ Architecture

Page 42: Memory and Programmable Logic - Tong In Oh · Memory and Programmable Logic Chang, Ik Joon Kyunghee University. ... Control circuitry Global data bus Block selector Block 0 Row address

Xilinx FPGA