Clock Domain Crossing (CDC)
Clock Domain Crossing (CDC)
Agenda
Introduction to Clock Domain
Crossing (CDC)
Basic Synchronizers
Datapaths and Reconvergence
Handshake Synchronization
Checking CDCs With Conformal
Agenda
Introduction to Clock Domain
Crossing (CDC)
Basic Synchronizers
Datapaths and Reconvergence
Handshake Synchronization
Checking CDCs With Conformal
Problems At Asynchronous
Clock Domain Crossings
When does new value arrive?
Source clk not coordinated with dest clk
Chance of arriving in setup/hold window
What does this mean?
Possibility of metastable (halfway) state
Value may settle either way
Multiple fanouts may detect different values
Agenda
Introduction to Clock Domain
Crossing (CDC)
Basic Synchronizers
Datapaths and Reconvergence
Handshake Synchronization
Checking CDCs With Conformal
Functional:
Assert signal held long enough
Due to uncertainty of capture time
Hold for 2+ receiver cycles: create assert
May need longer depending on relative freq
More detailed discussion in TOV lecture
Alternate-mode signals
Valid in only some operating modes, includes clk
Scan and other ultra-slow interfaces
Agenda
Introduction to Clock Domain
Crossing (CDC)
Basic Synchronizers
Datapaths and Reconvergence
Handshake Synchronization
Checking CDCs With Conformal
Datapath Problem
Each synchronizer may be off by a
cycle
All are independent
So during transition from 000 to 111, may
sense 001, 010, 011,
value!
or any other
Reconvergence Problem
More general view of datapath issue
Problem: reconvergence of synced bits
CDC checks can flag cases
Is there a better way to synchronize?
Such that grey codes arent needed
Yes!
Have control signal coordinate data with mux
Mux-Based Sync
Agenda
Introduction to Clock Domain
Crossing (CDC)
Basic Synchronizers
Datapaths and Reconvergence
Handshake Synchronization
Checking CDCs With Conformal
Handshake/FIFO Protocols
Clock freq maybe configurable /
unknown
Hard to design previous syncs for all cases
Hard to properly check for all cases
Maybe sometimes overconservative
Solution: handshake protocols
Sender stores data in FIFO
Explicit request/response for data
More logic & harder to check, but powerful
Agenda
Introduction to Clock Domain
Crossing (CDC)
Basic Synchronizers
Datapaths and Reconvergence
Handshake Synchronization
Checking CDCs With Conformal
Diagnosing A Convergence
Issue