Authenticating...

Verifying course access credentials.

CDC Course / Module 9: CDC Verification & Simulation
Lesson 9.2

Gate-Level X-Propagation Issues

Why your synchronizers output 'X' in Netlist Simulations and how it ruins verification.

During RTL simulation, synchronizers behave predictably. But when you transition to Gate-Level Simulation (GLS) with Standard Delay Format (SDF) timing annotation, CDC boundaries suddenly become a nightmare of unknown X values cascading through your design. Let's examine why this happens and why it is physically impossible to avoid timing violations at CDC boundaries.

1 The Setup/Hold Reality

In a synchronous domain, static timing analysis (STA) guarantees that signals arrive at flip-flops outside the setup and hold windows. At a CDC boundary, the transmitting clock is completely asynchronous to the receiving clock.

Because the clocks have no fixed phase relationship, data edges will eventually drift into the setup/hold window of the receiving flip-flop. Timing violations at CDC boundaries are not bugs; they are physical inevitabilities.

P(violation) = (T_setup + T_hold) / T_clk_rx

This formula states that the probability of a signal transitioning during the timing window is simply the width of that window divided by the clock period of the receiving domain.

2 Why Gate-Level Simulators Generate X

A gate-level simulator executing an SDF-annotated netlist uses primitives that strictly enforce timing checks (via Verilog system tasks like $setup and $hold). When a transition violates these checks, the simulator's standard behavior is to flag the violation and force the output of the primitive to X (Unknown).

In physical silicon, the flip-flop might go metastable, but it will eventually resolve to a valid logic 0 or 1. It never drives an indeterminate voltage level indefinitely. The simulator's X is pessimistic—it denotes a state it cannot predict, not a state the hardware will actually maintain.

TX_CLK RX_CLK TX_DATA Setup/Hold Window SYNC1_Q X Violation Triggers X Output

3 The Cascade Problem

The real issue isn't the first synchronizer flip-flop outputting X. The catastrophe happens on the next clock cycle. The second flip-flop in the synchronizer chain captures the X and outputs X.

From there, the X enters your control logic. If an X hits the select line of a multiplexer, the simulator propagates X to the output (since it doesn't know which path to select). If it hits a state machine, the FSM transitions to state X. Within a few clock cycles, your entire receiving clock domain is poisoned with Xs, rendering the simulation useless.

Log Output: The X Contagion

A typical gate-level simulation log showing the exact moment a timing violation poisons the pipeline:

Time (ps) Event Log Signal State
45200 "Warning: $setup violation on tb.dut.sync_chain.ff1" tx_data transitions
45250 Simulator evaluates primitive sync1_q = 1'bx
55200 Next RX clock edge sync2_q = 1'bx
65200 Downstream logic evaluation fifo_empty = 1'bx

4 Why You Can't Just Ignore It

X-Pessimism Masks True Bugs

You might be tempted to ignore X-propagation during GLS if you "know" it's just a synchronizer. But doing so blinds you to actual logic bugs. If your simulation is filled with Xs, how do you verify that your reset sequence works? How do you know if a complex FIFO pointer crosses correctly? You can't. X-propagation destroys observability.

5 Solutions Overview

To run successful gate-level simulations, we must artificially prevent the simulator from generating X on the first stage of CDC synchronizers, while preserving accurate timing checks on the rest of the design.

We will dive deep into implementing these specific solutions in the next lesson.

Key Takeaway

Timing violations at CDC boundaries in gate-level simulation are expected and physically correct. The simulator's response—generating an X—is overly pessimistic and will rapidly poison the entire downstream clock domain logic. You must explicitly disable timing checks on the first stage of synchronizers to achieve a functional GLS.

Advertisement