A flip-flop is a small circuit with internal nodes that must be charged and discharged. If the clock pulse is too short, the internal nodes do not reach their values and the flip-flop can fail, whatever the data does. The minimum pulse width check protects against this. It looks at the clock waveform and the library, and no data is involved. This article explains the check, shows the numbers of a real flip-flop, and shows how the minimum period of a clock and of a whole design can be read from the reports.

7 min read | Intermediate

What You'll Learn

  • Explain what the minimum pulse width check protects
  • Read the high and low pulse limits of a library cell and the slack of the check
  • Say how the clock waveform and the clock tree change the pulse width
  • Find the minimum period of a design from the worst setup slack

The Check

The library gives two numbers for the clock pin of a flip-flop: the shortest high pulse and the shortest low pulse for which the cell is characterized. They are min_pulse_width tables in the Liberty file. STA compares the real pulses of the clock at that pin with them:

Min pulse width

For the flip-flop dfxtp_1, the limits in our runs are 0.1551 ns for the high pulse and 0.1955 ns for the low pulse. For the clock of the demo circuit, with a period of 2.0 ns and a duty cycle of 50 percent, both pulses are 1.0 ns long, and the check has a lot of margin. The command report_check_types -min_pulse_width prints the pin with the smallest slack:

Output
                                      Required    Actual
Pin                                      Width     Width     Slack
------------------------------------------------------------------
_6_/CLK (low)                           0.1955    1.0000    0.8045 (MET)

The pin _6_/CLK, low pulse, has the smallest slack of 0.8045 ns. The high pulse has a larger one, because its limit is smaller and the pulse is as long.

What Changes the Pulse Width

  • The period and the duty cycle in create_clock. A clock of 2.0 ns with -waveform {0 0.5} has a high pulse of 0.5 ns, and the slack of the high pulse check is 0.5 - 0.1551 = 0.3449 ns.
  • A faster clock. With a period of 0.5 ns and 50 percent duty, each pulse is 0.25 ns long, and the low pulse has a slack of 0.25 - 0.1955 = 0.0545 ns. At a period below about 0.39 ns the low pulse of this flip-flop would violate the check.
  • The clock tree. A buffer or a gate can make the rising edge slower than the falling edge or the other way round, and a pulse gets shorter or longer on its way. With propagated clocks, STA includes this. The check matters most after the clock tree is built.

The check is applied at every clock pin of every cell that has a pulse width limit in the library: flip-flops, latches and memories. It also covers the pins of a clock gate. A clock that is generated by a divider has a pulse width that follows from the master clock.

Quick Check

Q: A flip-flop needs at least 0.2 ns of low pulse. At which period does a clock with 50 percent duty violate the check?

Show Answer

When the low pulse, which is half of the period, is shorter than 0.2 ns, so for periods below 0.4 ns.

The Minimum Period

There are two ways to speak of a minimum period. The first is a limit of a cell: some cells, such as memories, have a minimum clock period in the library, and the check compares the period of the clock with it. The library of the flip-flops in this tutorial has no such limit, and the command report_check_types -min_period prints nothing for the demo circuit.

The second is the minimum period of the design, which follows from the setup paths. The setup slack grows with the period in a simple way: each time you lengthen the period by some amount, the slack of every path that starts and ends at the same clock edges grows by the same amount. The smallest period at which the worst path just meets setup is:

Minimum period = current period - worst setup slack

In the demo circuit, the worst setup slack at 2.0 ns is 1.0326 ns, on the path from the input to the output. The minimum period is 2.0 - 1.0326 = 0.9674 ns, which is what the article about feedthrough paths found. In a design where the worst path is limited by something that does not change with the period, such as a max delay constraint, this simple rule does not apply.

Quick Check

Q: A design has a worst setup slack of 0.25 ns at a 3.0 ns clock, on a path between two flip-flops. About what is its minimum period?

Show Answer

3.0 - 0.25 = 2.75 ns, as long as the same path stays the worst one when the period changes.

Common Mistakes

Mistake #1: Checking only setup and hold when the clock is made faster

A faster clock shortens both pulses. At some period the pulse width check fails, even though all the setup paths are still met. Include the pulse width check in the sign-off.

Mistake #2: Assuming the duty cycle is always 50 percent

Clock gates, dividers and long clock buffers can change the duty cycle. A 50 percent assumption in the constraints that does not match the real clock hides a violation.

Practice Exercise

Challenge: Shrink the Pulse

Use the sta_demo design and print the pulse width check. Then change the clock to a period of 0.5 ns, and then to a period of 0.4 ns:


create_clock -name clk -period 0.4 [get_ports clk]

Predict the slack of the low pulse check for each period. The limit is 0.1955 ns.

Hint

For a 50 percent duty cycle, the low pulse is half of the period.

Solution

At 0.5 ns the low pulse is 0.25 ns and the slack is 0.25 - 0.1955 = 0.0545 ns, which is met. At 0.4 ns the low pulse is 0.2 ns and the slack is 0.2 - 0.1955 = 0.0045 ns, still met but with almost no margin. Below 0.391 ns the check fails. The setup checks of the demo circuit fail long before that, at a period below 0.9674 ns.

Open the ready-made example in the lab, run synthesis, and then run STA. Editing constraints.sdc and re-running only STA, and choosing another library or corner, are PRO features.

Summary

  • The minimum pulse width check makes sure that the clock stays high and low long enough for the cell.
  • The limits are in the library per clock pin: 0.1551 ns high and 0.1955 ns low for the flip-flop dfxtp_1.
  • The pulse widths follow from the period, the duty cycle and, after the clock tree, the real clock path.
  • Some cells have a minimum clock period in the library. The flip-flop used here does not.
  • The minimum period of the design is the current period minus the worst setup slack, if that path scales with the period.
Did you find what you were looking for?

Quiz

Test Your Knowledge

1 of 5 Score: 0 / 5
Cron Job Starts