Clock Domain Crossing

Clock domain crossing is the transfer of a signal from a circuit block running on one clock to a circuit block running on a different, asynchronous clock, a situation that requires special synchronization circuitry to avoid unpredictable capture errors called metastability.

Signal originates in a block running on one clock
destination block runs on a different, unrelated clock
Synchronizer bridges the two asynchronous clock domains
Multi-stage flip-flop chain lets metastability settle safely
prevents an unstable value from propagating further
Signal safely captured in the destination clock domain
reliable transfer despite the clocks being unrelated

Clock domain crossing requires special handling because a signal changing at essentially any moment relative to a receiving flip-flop's clock edge can occasionally arrive so close to that edge that the flip-flop can't resolve a clean logical value in time, entering a temporarily unstable state called metastability. Since two clock domains running independently, with no fixed timing relationship between their edges, mean a signal crossing between them can violate the receiving flip-flop's setup and hold requirements at essentially any moment, without deliberate synchronization such a metastable capture can propagate an invalid, unpredictable value into the receiving clock domain's logic.

Clock Domain Crossing: The Moving Parts a simplified look at the pieces involved and how they connect Signal from one clock domain destination clock is unrelated Synchronizer bridges the domains Multi-stage chain lets metastability settle unstable value contained Signal safely captured reliable despite unrelated clocks
Synchronizer Chain Bridges Two Asynchronous Clocks two flip-flop stages let a metastable value settle before use Domain A clock A FF1 may be metastable FF2 now stable Domain B clock B
AspectSignal within one clock domainSignal crossing clock domains
Timing relationship between source and destinationFixed and knownUnrelated, asynchronous
Risk of metastabilityNonePresent without synchronization
Standard mitigationNot neededMulti-stage synchronizer
Common useOrdinary internal signal pathsInterfaces between independent clock regions

A common synchronizer for a single-bit signal uses two or more flip-flop stages in series clocked by the destination domain, giving any metastable value time to resolve into a stable logic level before it's used by downstream logic. Because a metastable flip-flop output generally does eventually settle to a valid logic level, just not necessarily within a single clock cycle, adding extra flip-flop stages between the crossing signal and the logic that uses it gives that settling process more time to complete, dramatically reducing the practical risk that an unresolved metastable value reaches downstream logic.

Multi-bit signals crossing clock domains need more careful handling than a simple synchronizer chain, since different bits could be captured on different clock cycles, producing a combination of old and new bit values that was never actually a valid signal state. Because a straightforward per-bit synchronizer applied independently to each bit of a multi-bit value doesn't guarantee all bits get captured together, designers typically use techniques such as gray coding or handshake protocols specifically designed to ensure a multi-bit value crosses the clock domain as a single, internally consistent unit.

Clock domain crossing verification has become a specialized area of chip design, since metastability-related bugs are often intermittent and timing-dependent, making them notoriously difficult to catch through ordinary functional simulation alone. Because a clock domain crossing bug might only manifest under specific, rare timing alignments between two independent clocks, rather than showing up reliably in typical simulation runs, chip design teams commonly use dedicated clock domain crossing analysis tools that specifically check every crossing in a design for proper synchronization, catching issues that conventional verification approaches could easily miss.

Read clock domain crossing through a relay-handoff lens: much like a relay race baton handoff requires a careful, deliberate exchange between two runners moving at their own independent paces to avoid a dropped baton, transferring a signal between two independently clocked domains requires a careful, deliberate synchronizer to avoid a corrupted value.

Take clock domain crossing further

Ask the copilot about this term, or have our engineers assess it against your process.