54
Introduction to CMOS VLSI Design Lecture 10: Sequential Circuits David Harris Harvey Mudd College Spring 2004

Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

  • Upload
    others

  • View
    8

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

Introduction toCMOS VLSI

Design

Lecture 10: Sequential Circuits

David Harris

Harvey Mudd CollegeSpring 2004

Page 2: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 2CMOS VLSI Design

Outlineq Floorplanningq Sequencingq Sequencing Element Designq Max and Min-Delayq Clock Skewq Time Borrowingq Two-Phase Clocking

Page 3: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 3CMOS VLSI Design

Project Strategyq Proposal

– Specifies inputs, outputs, relation between themq Floorplan

– Begins with block diagram– Annotate dimensions and location of each block– Requires detailed paper design

q Schematic– Make paper design simulate correctly

q Layout– Physical design, DRC, NCC, ERC

Page 4: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 4CMOS VLSI Design

Floorplanq How do you estimate block areas?

– Begin with block diagram– Each block has

• Inputs• Outputs• Function (draw schematic)• Type: array, datapath, random logic

q Estimation depends on type of logic

Page 5: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 5CMOS VLSI Design

MIPS Floorplan

datapath2700 λ x 1050 λ

(2.8 Mλ2)

alucontrol200 λ x 100 λ

(20 kλ2)

zipper 2700 λ x 250 λ

2700 λ

1690 λ

wiring channel: 30 tracks = 240 λ

mips(4.6 Mλ2)

bitslice 2700 λ x 100 λ

control1500 λ x 400 λ

(0.6 Mλ2)

3500 λ

3500 λ

5000λ

5000 λ

10 I/O pads

10 I/O pads

10 I/O pads

10 I/O pads

Page 6: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 6CMOS VLSI Design

Area Estimationq Arrays:

– Layout basic cell– Calculate core area from # of cells– Allow area for decoders, column circuitry

q Datapaths– Sketch slice plan– Count area of cells from cell library– Ensure wiring is possible

q Random logic– Compare complexity do a design you have done

Page 7: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 7CMOS VLSI Design

MIPS Slice Plan

mux2

inv

flop

flop

flop

flop

mux2

inv

writedriver

dualsram

dualsram

dualsram

dualsrambit0

srampullup

readmux

flop

mux4

flop

mux2

inv

flop

mux4

and2

flop

and2

inv

mux2

and2

or2

fulladder

mux4

register fileramslice

ALU

adrmux

flop

MD

R

IR3...0

writem

ux

srcB srcA aluout

zerodetect

PC

memdatawritedata

adr

pcimmediate

aluout

aluresult

srcBsrcAbitlines

44 24 93 93 93 93 93 44 24 52 48 48 48 48 16 86 93 93 93 9344 24 4424131 131 13139 39 39 39 160

Page 8: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 8CMOS VLSI Design

Typical Layout Densitiesq Typical numbers of high-quality layoutq Derate by 2 for class projects to allow routing and

some sloppy layout.q Allocate space for big wiring channels

100 λ2 / bitROM

100 λ2 / bitDRAM

1000 λ2 / bitSRAM

250 – 750 λ2 / transistorOr 6 WL + 360 λ2 / transistor

Datapath

1000-1500 λ2 / transistorRandom logic (2 metal layers)

AreaElement

Page 9: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 9CMOS VLSI Design

Sequencingq Combinational logic

– output depends on current inputsq Sequential logic

– output depends on current and previous inputs– Requires separating previous, current, future– Called state or tokens– Ex: FSM, pipeline

CL

clk

in out

clk clk clk

CL CL

PipelineFinite State Machine

Page 10: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 10CMOS VLSI Design

Sequencing Cont.q If tokens moved through pipeline at constant speed,

no sequencing elements would be necessaryq Ex: fiber-optic cable

– Light pulses (tokens) are sent down cable– Next pulse sent before first reaches end of cable– No need for hardware to separate pulses– But dispersion sets min time between pulses

q This is called wave pipelining in circuitsq In most circuits, dispersion is high

– Delay fast tokens so they don’t catch slow ones.

Page 11: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 11CMOS VLSI Design

Sequencing Overheadq Use flip-flops to delay fast tokens so they move

through exactly one stage each cycle.q Inevitably adds some delay to the slow tokensq Makes circuit slower than just the logic delay

– Called sequencing overheadq Some people call this clocking overhead

– But it applies to asynchronous circuits too– Inevitable side effect of maintaining sequence

Page 12: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 12CMOS VLSI Design

Sequencing Elementsq Latch: Level sensitive

– a.k.a. transparent latch, D latchq Flip-flop: edge triggered

– A.k.a. master-slave flip-flop, D flip-flop, D registerq Timing Diagrams

– Transparent– Opaque– Edge-trigger

D

Flop

Latc

h

Q

clk clk

D Q

clk

D

Q (latch)

Q (flop)

Page 13: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 13CMOS VLSI Design

Sequencing Elementsq Latch: Level sensitive

– a.k.a. transparent latch, D latchq Flip-flop: edge triggered

– A.k.a. master-slave flip-flop, D flip-flop, D registerq Timing Diagrams

– Transparent– Opaque– Edge-trigger

D

Flop

Latc

h

Q

clk clk

D Q

clk

D

Q (latch)

Q (flop)

Page 14: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 14CMOS VLSI Design

Latch Designq Pass Transistor Latchq Pros

++

q Cons––––––

D Q

φ

Page 15: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 15CMOS VLSI Design

Latch Designq Pass Transistor Latchq Pros

+ Tiny+ Low clock load

q Cons– Vt drop– nonrestoring– backdriving– output noise sensitivity– dynamic– diffusion input

D Q

φ

Used in 1970’s

Page 16: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 16CMOS VLSI Design

Latch Designq Transmission gate

+- D Q

φ

φ

Page 17: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 17CMOS VLSI Design

Latch Designq Transmission gate

+ No Vt drop- Requires inverted clock D Q

φ

φ

Page 18: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 18CMOS VLSI Design

Latch Designq Inverting buffer

+++ Fixes either

••

D

φ

φ

X Q

D Q

φ

φ

Page 19: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 19CMOS VLSI Design

Latch Designq Inverting buffer

+ Restoring+ No backdriving+ Fixes either

• Output noise sensitivity• Or diffusion input

– Inverted output

D

φ

φ

X Q

D Q

φ

φ

Page 20: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 20CMOS VLSI Design

Latch Designq Tristate feedback

+–

φ

φ φ

φ

QD X

Page 21: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 21CMOS VLSI Design

Latch Designq Tristate feedback

+ Static– Backdriving risk

q Static latches are now essential

φ

φ φ

φ

QD X

Page 22: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 22CMOS VLSI Design

Latch Designq Buffered input

++

φ

φ

QD X

φ

φ

Page 23: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 23CMOS VLSI Design

Latch Designq Buffered input

+ Fixes diffusion input+ Noninverting

φ

φ

QD X

φ

φ

Page 24: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 24CMOS VLSI Design

Latch Designq Buffered output

+

φ

φ

Q

D X

φ

φ

Page 25: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 25CMOS VLSI Design

Latch Designq Buffered output

+ No backdriving

q Widely used in standard cells+ Very robust (most important)- Rather large- Rather slow (1.5 – 2 FO4 delays)- High clock loading

φ

φ

Q

D X

φ

φ

Page 26: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 26CMOS VLSI Design

Latch Designq Datapath latch

+-

φ

φ φ

φ

Q

D X

Page 27: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 27CMOS VLSI Design

Latch Designq Datapath latch

+ Smaller, faster- unbuffered input

φ

φ φ

φ

Q

D X

Page 28: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 28CMOS VLSI Design

Flip-Flop Designq Flip-flop is built as pair of back-to-back latches

D Q

φ

φ

φ

φ

X

D

φ

φ

φ

φ

X

Q

φ

φ

φ

Page 29: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 29CMOS VLSI Design

Enableq Enable: ignore clock when en = 0

– Mux: increase latch D-Q delay– Clock Gating: increase en setup time, skew

D Q

Latc

h

D Q

en

en

φ

φ

Latc

hDQ

φ

0

1

en

Latc

h

D Q

φ en

DQ

φ

0

1

enD Q

φ en

Flo

p

Flop

Flo

p

Symbol Multiplexer Design Clock Gating Design

Page 30: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 30CMOS VLSI Design

Resetq Force output low when reset assertedq Synchronous vs. asynchronous

D

φ

φ

φ

φ

Q

φ

φ

φ

reset

D

φ

φφ

φ

φ

φ

φ

Dreset

φ

φ

φ

Dreset

reset

φ

φ

reset

Synchronous R

esetA

synchronous Reset

Sym

bol Flo

p

D Q

Latc

h

D Q

reset reset

φ φ

φ

φ

Q

reset

Page 31: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 31CMOS VLSI Design

Set / Resetq Set forces output high when enabled

q Flip-flop with asynchronous set and reset

D

φ

φ

φ

φφ

φ

Q

φ

φ

reset

set reset

set

Page 32: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 32CMOS VLSI Design

Sequencing Methodsq Flip-flopsq 2-Phase Latchesq Pulsed Latches

Flip-F

lopsF

lop

Latc

h

Flo

p

clk

φ1

φ2

φp

clk clk

Latc

h

Latc

h

φp φp

φ1 φ1φ2

2-Phase T

ransparent LatchesP

ulsed Latches

Combinational Logic

CombinationalLogic

CombinationalLogic

Combinational Logic

Latc

h

Latc

h

Tc

Tc/2

tnonoverlap tnonoverlap

tpw

Half-Cycle 1 Half-Cycle 1

Page 33: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 33CMOS VLSI Design

Timing Diagrams

Flo

p

A

Y

tpdCombinational

LogicA Y

D Q

clk clk

D

Q

Latc

h

D Q

clk clk

D

Q

tcd

tsetup thold

tccq

tpcq

tccq

tsetup tholdtpcq

tpdqtcdqLatch/Flop Hold Timethold

Latch/Flop Setup Timetsetup

Latch D-Q Cont. Delaytpcq

Latch D-Q Prop Delaytpdq

Latch/Flop Clk-Q Cont. Delaytccq

Latch/Flop Clk-Q Prop Delaytpcq

Logic Cont. Delaytcd

Logic Prop. Delaytpd

Contamination and Propagation Delays

Page 34: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 34CMOS VLSI Design

Max-Delay: Flip-Flops

F1

F2

clk

clk clk

Combinational Logic

Tc

Q1 D2

Q1

D2

tpd

tsetuptpcq

( )sequencing overhead

pd ct T≤ − 1442443

Page 35: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 35CMOS VLSI Design

Max-Delay: Flip-Flops

F1

F2

clk

clk clk

Combinational Logic

Tc

Q1 D2

Q1

D2

tpd

tsetuptpcq

( )setup

sequencing overhead

pd c pcqt T t t≤ − +14243

Page 36: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 36CMOS VLSI Design

Max Delay: 2-Phase Latches

Tc

Q1

L1

φ1

φ2

L2 L3

φ1 φ1φ2

CombinationalLogic 1

CombinationalLogic 2

Q2 Q3D1 D2 D3

Q1

D2

Q2

D3

D1

tpd1

tpdq1

tpd2

tpdq2

( )1 2

sequencing overhead

pd pd pd ct t t T= + ≤ − 1442443

Page 37: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 37CMOS VLSI Design

Max Delay: 2-Phase Latches

Tc

Q1

L1

φ1

φ2

L2 L3

φ1 φ1φ2

CombinationalLogic 1

CombinationalLogic 2

Q2 Q3D1 D2 D3

Q1

D2

Q2

D3

D1

tpd1

tpdq1

tpd2

tpdq2

( )1 2

sequencing overhead

2pd pd pd c pdqt t t T t= + ≤ − 123

Page 38: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 38CMOS VLSI Design

Max Delay: Pulsed Latches

Tc

Q1 Q2D1 D2

Q1

D2

D1

φp

φp φp

Combinational LogicL1 L2

tpw

(a) tpw > tsetup

Q1

D2

(b) tpw < tsetup

Tc

tpd

tpdq

tpcq

tpd tsetup

( )sequencing overhead

max pd ct T≤ − 14444244443

Page 39: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 39CMOS VLSI Design

Max Delay: Pulsed Latches

Tc

Q1 Q2D1 D2

Q1

D2

D1

φp

φp φp

Combinational LogicL1 L2

tpw

(a) tpw > tsetup

Q1

D2

(b) tpw < tsetup

Tc

tpd

tpdq

tpcq

tpd tsetup

( )setup

sequencing overhead

max ,pd c pdq pcq pwt T t t t t≤ − + −14444244443

Page 40: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 40CMOS VLSI Design

Min-Delay: Flip-Flops

cdt ≥ CL

clk

Q1

D2

F1

clk

Q1

F2

clk

D2

tcd

thold

tccq

Page 41: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 41CMOS VLSI Design

Min-Delay: Flip-Flops

holdcd ccqt t t≥ − CL

clk

Q1

D2

F1

clk

Q1

F2

clk

D2

tcd

thold

tccq

Page 42: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 42CMOS VLSI Design

Min-Delay: 2-Phase Latches

1, 2 cd cdt t ≥CL

Q1

D2

D2

Q1

φ1

L1

φ2

L2

φ1

φ2

tnonoverlap

tcd

thold

tccq

Hold time reduced by nonoverlap

Paradox: hold applies twice each cycle, vs. only once for flops.

But a flop is made of two latches!

Page 43: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 43CMOS VLSI Design

Min-Delay: 2-Phase Latches

1, 2 hold nonoverlapcd cd ccqt t t t t≥ − −CL

Q1

D2

D2

Q1

φ1

L1

φ2

L2

φ1

φ2

tnonoverlap

tcd

thold

tccq

Hold time reduced by nonoverlap

Paradox: hold applies twice each cycle, vs. only once for flops.

But a flop is made of two latches!

Page 44: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 44CMOS VLSI Design

Min-Delay: Pulsed Latches

cdt ≥CL

Q1

D2

Q1

D2

φp tpw

φp

L1

φp

L2tcd

thold

tccq

Hold time increased by pulse width

Page 45: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 45CMOS VLSI Design

Min-Delay: Pulsed Latches

holdcd ccq pwt t t t≥ − +CL

Q1

D2

Q1

D2

φp tpw

φp

L1

φp

L2tcd

thold

tccq

Hold time increased by pulse width

Page 46: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 46CMOS VLSI Design

Time Borrowingq In a flop-based system:

– Data launches on one rising edge– Must setup before next rising edge– If it arrives late, system fails– If it arrives early, time is wasted– Flops have hard edges

q In a latch-based system– Data can pass through latch while transparent– Long cycle of logic can borrow time into next– As long as each loop completes in one cycle

Page 47: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 47CMOS VLSI Design

Time Borrowing Example

Latc

h

Latc

h

Latc

h

Combinational Logic CombinationalLogic

Borrowing time acrosshalf-cycle boundary

Borrowing time acrosspipeline stage boundary

(a)

(b)

Latc

h

Latc

hCombinational Logic Combinational

Logic

Loops may borrow time internally but must complete within the cycle

φ1

φ2

φ1 φ1

φ1

φ2

φ2

Page 48: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 48CMOS VLSI Design

How Much Borrowing?

Q1

L1

φ1

φ2

L2

φ1 φ2

Combinational Logic 1Q2D1 D2

D2

Tc

Tc/2 Nominal Half-Cycle 1 Delay

tborrow

tnonoverlap

tsetup

( )borrow setup nonoverlap2cT

t t t≤ − +

2-Phase Latches

borrow setuppwt t t≤ −

Pulsed Latches

Page 49: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 49CMOS VLSI Design

Clock Skewq We have assumed zero clock skewq Clocks really have uncertainty in arrival time

– Decreases maximum propagation delay– Increases minimum contamination delay– Decreases time borrowing

Page 50: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 50CMOS VLSI Design

Skew: Flip-Flops

F1 F2

clk

clk clk

Combinational Logic

Tc

Q1 D2

Q1

D2

tskew

CL

Q1

D2

F1

clk

Q1

F2

clk

D2

clk

tskew

tsetup

tpcq

tpdq

tcd

thold

tccq

( )setup skew

sequencing overhead

hold skew

pd c pcq

cd ccq

t T t t t

t t t t

≤ − + +

≥ − +

144424443

Page 51: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 51CMOS VLSI Design

Skew: Latches

Q1

L1

φ1

φ2

L2 L3

φ1 φ1φ2

CombinationalLogic 1

CombinationalLogic 2

Q2 Q3D1 D2 D3

( )

( )

sequencing overhead

1 2 hold nonoverlap skew

borrow setup nonoverlap skew

2

,

2

pd c pdq

cd cd ccq

c

t T t

t t t t t t

Tt t t t

≤ −

≥ − − +

≤ − + +

123

2-Phase Latches

( )

( )

setup skew

sequencing overhead

hold skew

borrow setup skew

max ,pd c pdq pcq pw

cd pw ccq

pw

t T t t t t t

t t t t t

t t t t

≤ − + − +

≥ + − +

≤ − +

1444442444443Pulsed Latches

Page 52: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 52CMOS VLSI Design

Two-Phase Clockingq If setup times are violated, reduce clock speedq If hold times are violated, chip fails at any speedq In this class, working chips are most important

– No tools to analyze clock skewq An easy way to guarantee hold times is to use 2-

phase latches with big nonoverlap timesq Call these clocks φ1, φ2 (ph1, ph2)

Page 53: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 53CMOS VLSI Design

Safe Flip-Flopq In class, use flip-flop with nonoverlapping clocks

– Very slow – nonoverlap adds to setup time– But no hold times

q In industry, use a better timing analyzer– Add buffers to slow signals if hold time is at risk

D

φ2

X

Q

Q

φ1

φ2

φ1

φ1φ1

φ2

φ2

Page 54: Lecture 10: Sequential Circuits - Harvey Mudd Collegepages.hmc.edu/harris/class/e158/04/lect10.pdf10: Sequential Circuits CMOS VLSI Design Slide 4 Floorplan qHow do you estimate block

10: Sequential Circuits Slide 54CMOS VLSI Design

Summaryq Flip-Flops:

– Very easy to use, supported by all toolsq 2-Phase Transparent Latches:

– Lots of skew tolerance and time borrowingq Pulsed Latches:

– Fast, some skew tol & borrow, hold time risk