STA checks every path in the netlist. That is its strength, but it also means that it checks paths that your design never uses, or that do not need a check. If you leave them in, the report is full of violations that mean nothing. Timing exceptions are the commands that tell STA how to treat such paths, and each of them can also hide a real problem if you use it wrongly. This chapter covers each exception with its risks.
A false path is a path that exists in the netlist but that is not a real timing path. The data on it is never captured in a way that matters, or the path can never be active. set_false_path tells STA to ignore such a path. This article shows how to write it, when it is correct, and what it removes from the reports.
8 min read | Intermediate
What You'll Learn
- Explain what a false path is and give examples of real false paths
- Write
set_false_pathwith-from,-toand-through - Limit a false path to setup or to hold
- Check that a false path did not remove more than you intended
What Makes a Path False
STA looks at the structure of the circuit. It does not know how the circuit is used. Some paths are legal in the netlist but are never a problem in practice:
- A configuration register that is written once after reset and then does not change. The data path from it to the rest of the logic is only used while the chip is stable, so it has no timing requirement.
- Two parts of a multiplexer that are never selected together, so that a path through one of them to the other can never be active.
- A path in the test logic that is only used in a test mode, and that is analyzed on its own.
- A crossing between two unrelated clocks that is handled by a synchronizer and by a separate check. (For whole clocks, the clock groups of the clocks chapter are a better tool than false paths.)
Before writing a false path, you must be able to explain why the path cannot cause a failure. "It violates timing" is not a reason.
The Command
The command takes up to three kinds of points. All three are optional, and you can combine them:
set_false_path -from [get_ports d] -to [get_ports z]
set_false_path -through [get_pins _4_/X]
set_false_path -setup -from [get_ports c] -to [get_pins _6_/D]
-fromgives the startpoints of the paths: ports, flip-flop clock pins, or clocks.-togives the endpoints: ports, flip-flop data pins, or clocks.-throughgives a pin that the path must pass. It removes every path that goes through it, whatever its start and end.-setupor-holdlimits the false path to one of the two checks. Without them, it removes both.
A Careful False Path
Take the data pin of the flip-flop _6_. Two paths end there: one from the input c and one from the flip-flop _7_, both through the XOR gate. Suppose the input c is a static configuration pin, and you do not want it checked for setup:
set_false_path -setup -from [get_ports c] -to [get_pins _6_/D]
The path from c disappears from the setup report. The worst setup path that ends at _6_/D is now the one from _7_, and the endpoint slack changes from 1.3650 ns to 1.4502 ns. The hold check is unchanged, 0.4241 ns, because only -setup was given. This is the right size for a false path: it names the start, the end and the check.
A Too-Wide False Path
Now try the command with a -through and no other option:
set_false_path -through [get_pins _4_/X]
The XOR gate _4_ is on both paths that end at _6_/D, so both are removed, for setup and for hold. The flip-flop _6_ now has no checked path at all. The setup report no longer lists it. The only sign is a warning from check_setup:
Warning: There is 1 unconstrained endpoint. _6_/D
Nothing in the slack report reveals this. The design looks cleaner and is less verified. This is the main risk of false paths: a command that is a little too wide removes checks that you need.
False Path or Clock Groups
You can also make a false path from one clock to another, with -from [get_clocks clka] -to [get_clocks clkb]. It works like an asynchronous clock group for the paths in one direction. The group command is easier to read, applies to both directions, and is better for clocks that are unrelated. Use a false path when the exception is about specific points, not about whole clocks.
Keeping False Paths Under Control
- Write the narrowest command that does the job. Name both the start and the end, and use
-setupor-holdwhen only one check is meant. - Add a comment with the reason on the line above every false path.
- After adding one, run
check_setup -verboseand look for new unconstrained endpoints. - Review all false paths at sign-off. They are a list of promises that someone made about the design.
- If the data is really captured a known number of cycles later, use a multicycle path and not a false path. A multicycle path keeps the path constrained, so the tools still optimize it.
Common Mistakes
Mistake #1: Using a false path to remove a violation you do not understand
A path that fails timing may be a real problem. A false path makes the report clean, and the chip can still fail. Always find the reason why the path cannot matter first.
Mistake #2: Forgetting that a false path removes hold as well
Without -setup or -hold, the hold check of the path is removed too. A path that is false for setup may still need its hold check.
Quick Check: A false path with only -through on a gate removes how many paths?
Every path that passes through that gate, whatever its start and end, for both setup and hold.
Practice Exercise
Challenge: Find What the False Path Removed
Use the sta_demo design. Add the false path through the XOR gate, and run check_setup -verbose and a setup summary:
set_false_path -through [get_pins _4_/X]
Find the endpoint that has lost its paths. Then replace the command with the narrow one that removes only the path from c for setup, and compare the setup slack of the endpoint.
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.
Hint
Count the endpoints in the setup summary before and after. Look at the warning of check_setup for the name.
Solution
The wide command removes the data pin of the second flip-flop (_6_/D in our run) from the summary, and check_setup reports one unconstrained endpoint. With the narrow command, the endpoint stays in the summary and its setup slack changes from 1.3650 to 1.4502 ns, because the worst remaining path is the one from the first flip-flop. The names of the cells can differ in the lab, but the difference between the two commands will be the same.
Summary
- A false path is a path in the netlist that is not a real timing requirement.
set_false_pathremoves it from the checks. - It must be justified: the path can never be active, or the data on it is never captured in a way that matters.
-from,-toand-throughselect the paths.-setupand-holdlimit it to one check.- A
-throughcommand without other options can remove every path that goes through a point. - Check the result with
check_setup -verbosefor new unconstrained endpoints. - Write the narrowest false path possible, and comment the reason.