ee241 - spring 2007bwrcs.eecs.berkeley.edu/classes/.../lectures/lecture23-flip-flops.pdflatch vs....

23
1 EE241 - Spring 2007 Advanced Digital Integrated Circuits Lecture 23: Latches and Flip-Flops 2 Announcements Final exam on May 8 in class Project presentations on May 3, 1-5pm

Upload: tranque

Post on 20-Mar-2018

216 views

Category:

Documents


3 download

TRANSCRIPT

Page 1: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

1

EE241 - Spring 2007Advanced Digital Integrated Circuits

Lecture 23: Latches and Flip-Flops

2

Announcements

Final exam on May 8 in classProject presentations on May 3, 1-5pm

Page 2: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

2

3

Class MaterialLast lecture

SRAMToday’s lecture

Latches and flip-flops

4

Latches: ReadingRabaey et al, Chapters 7 and 10Chapter 10 in Chandrakasan et al, by PartoviStojanovic, Oklobdzija, JSSC 4/99

Page 3: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

3

5

Latch vs. Flip-FlopLatchstores data when clock is low

D

Clk

Q D

Clk

Q

Flip-Flop (register)stores data when clock rises

Clk Clk

D D

Q Q

6

Latch vs. Flip-Flop

Courtesy of IEEE Press, New York. © 2000

Page 4: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

4

7

Latch Pair vs. Flip-FlopPerformance metricsDelay metrics

Delay penaltyClock skew penaltyInclusion of logicInherent race immunity

Power/Energy MetricsPower/energyPDP, EDP

Design robustness

8

Latches

Negative latch(transparent when CLK= 0)

Positive latch(transparent when CLK= 1)

Page 5: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

5

9

Latches

D

Clk

Clk

Q

Clk

D

Clk

Q

Transmission-Gate Latch C2MOS Latch

10

Latches

Courtesy of IEEE Press, New York. © 2000

Page 6: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

6

11

TSPC - True Single Phase Clock Logic

M1

M2

M3

VDD

In

Outφ

φ

M1

M2

M3

VDD

InOut

φ

φ M1

M2

M3

VDD

In

Out

φ

M1

M2

M3

VDD

InOut

φ

Precharged N Precharged P Non-precharged N Non-precharged P

12

TSPC - True Single Phase Clock Logic

φ

VDD

Outφ

VDD

φ

VDD

φ

VDD

InStaticLogic

PUN

PDN

Including logic intothe latch

Inserting logic betweenlatches

Page 7: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

7

13

Doubled TSPC Latches

φ

VDD

Out

φ

VDD

Doubled n-TSPC latch

Inφ

VDD

Outφ

VDD

Doubled p-TSPC latch

14

DEC Alpha 21064

Dobberpuhl, JSSC 11/92

Page 8: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

8

15

DEC Alpha 21064

L1: L2:

16

DEC Alpha 21064

Integrating logic into latches• Reducing effective overhead

Page 9: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

9

17

DEC Alpha 21164

L1 Latch L2 Latch

L1 Latch with logic

18

Latch Pair as a Flip-Flop

Page 10: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

10

19

Requirements for the Flip-Flop Design• High speed of operation:

• Small Clk-Output delay• Small setup time• Small hold time→Inherent race immunity

• Low power• Small clock load• High driving capability• Integration of logic into flip-flop• Multiplexed or clock scan• Robustness• Crosstalk insensitivity

- dynamic/high impedance nodes are affected

20

Sources of Noise

Courtesy of IEEE Press, New York. © 2000

Page 11: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

11

21

Gate Isolation

Courtesy of IEEE Press, New York. © 2000

22

Flip-Flop RobustnessRobustness of the storage nodeInput isolationData stored statically, max resistance limitMin capacitance limitPreventing storage node exposure

Page 12: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

12

23

Types of Flip-Flops

Latch Pair(Master-Slave)

D

Clk

Q D

Clk

Q

Clk

DataD

Clk

Q

Clk

Data

Pulse-Triggered Latch

L1 L2 L

24

Flip-Flop Delay

Sum of setup time and Clk-output delay is the true measure of the performance with respect to the system speedT = TClk-Q + TLogic + Tsetup+ Tskew

D Q

Clk

D Q

Clk

LogicN

TLogicTClk-Q TSetup

Page 13: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

13

25

Delay vs. Setup/Hold Times

0

50

100

150

200

250

300

350

-200 -150 -100 -50 0 50 100 150 200

Data-Clk [ps]

Clk

-Out

put [

ps]

Setup Hold

Minimum Data-Output

26

Master-Slave Latch Pairs

Positive setup timesTwo clock phases:» distributed globally» generated locally

Small penalty in delay for incorporating MUXSome circuit tricks needed to reduce the overall delay

Page 14: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

14

27

Master-Slave Latch Pairs

Case 1: PowerPC 603 (Gerosa, JSSC 12/94)

Vdd Vdd

Clk

QClk Clkb

Clkb

D

28

T-G Master-Slave Latch

•Feedback added for static operation•Unbuffered input

input capacitance depends on the phase of the clockover-shoot and under-shoot with long routeswirelength must be restricted at the input

•Clock load is high•Low power•Small clk-output delay, but positive setup

Page 15: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

15

29

Master-Slave Latches

Case 2: C2MOS

VddVdd Vdd

Vdd

Vdd Vdd

Vdd

VddClk Ck

Ck

Ck

Ck

CkCkb

Ckb

Ckb

CkbQD

Feedback added for static operationLocally generated clockPoor driving capability

30

Master-Slave TSPC Flip-flops

φ

VDD

D

VDD

φ

VDD

D

φ

VDD

φ

VDD

D

VDD

φ

φ

VDD

φ

VDD

D

VDD

φ

φD

(a) Positive edge-triggered D flip-flop (b) Negative edge-triggered D flip-flop

(c) Positive edge-triggered D flip-flopusing split-output latches

XY

Page 16: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

16

31

Pulse-Triggered Latches

•First stage is a pulse generatorgenerates a pulse (glitch) on a rising edge of the clock

•Second stage is a latchcaptures the pulse generated in the first stage

•Pulse generation results in a negative setup time•Frequently exhibit a soft edge property

•Note: power is always consumed in the pulse generator

32

Pulsed Latch

Kozu, ISSCC’96

Simple pulsed latch

Page 17: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

17

33

Intel/HP Itanium 2

Naffziger, ISSCC’02

34

Pulse-Triggered Latches

Hybrid Latch Flip-Flop, AMD K-6Partovi, ISSCC’96

Vdd

D

Clk

Q

Q

Page 18: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

18

35

HLFF Operation

1-0 and 0-1 transitions at the input with 0ps setup time

36

Hybrid Latch Flip-Flop

Partovi et al, ISSCC’96

Skew absorption

Page 19: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

19

37

Pulse-Triggered Latches

AMD K-7

Courtesy of IEEE Press, New York. © 2000

38

Pulse-Triggered LatchesSemi-Dynamic Flip-Flop (SDFF), Sun UltraSparc III, Klass, VLSI Circuits’98

Clk

D

Vdd Vdd

Q

Q

Pulse generator is dynamic, cross-coupled latch is added for robustness. Loses soft edge on rising transitionLatch has one transistor less in stack - faster than HLFF, but 1-1 glitch existsSmall penalty for adding logic

Page 20: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

20

39

Pulse-Triggered Latches

7474, from early 1960’s

Clk

D

Q

Q

S

R

40

Pulse-Triggered Latches

First stage is a sense amplifier, precharged to high, when Clk = 0After rising edge of the clock sense amplifier generates the pulse on S or RThe pulse is captured in S-R latchCross-coupled NAND has different propagation delays of rising and falling edges

Case 4: Sense-amplifier-based flip-flop, Matsui 1992.DEC Alpha 21264, StrongARM 110

Page 21: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

21

41

Sense Amplifier-Based Flip-Flop

Courtesy of IEEE Press, New York. © 2000

42

Flip-Flop Performance Comparison

Total power consumedinternal powerdata power clock powerMeasured for four casesno activity (0000… and 1111…)maximum activity (0101010..)average activity (random sequence)

Test bench

Delay is (minimum D-Q)Clk-Q + setup time

Clk

Data

Clock

50fF

200fF

200fFD Q

Q

Stojanovic, Oklobdzija JSSC 4/99

Page 22: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

22

43

Flip-Flop Performance Comparison

0

10

20

30

40

50

60

70

100 150 200 250 300 350 400 450 500

Delay [ps]

Tota

l pow

er [u

W]

mSAFFSDFF

HLFF

C2 MOS

TG M-SOriginal SAFF

44

Sampling Window Comparison

Naffziger, JSSC 11/02

Page 23: EE241 - Spring 2007bwrcs.eecs.berkeley.edu/Classes/.../Lectures/Lecture23-Flip-Flops.pdfLatch vs. Flip-Flop zLatch stores data when clock is low D Clk Q D Clk Q Flip-Flop (register)

23

45

Local Clock Gating

D

QCKI

CKIB

0.85 0.85

2

0.850.5 0.5

0.5

1.2

CP

0.50.85 0.50.85

XNOR

CKIB

CKI

CKIB 0.5

0.5

0.85

0.5

PulseGenerator

Data-TransitionLook-Ahead

DI

‘Clock on demand’Flip-flop

46

Next LectureTiming