PT - group cmd

PT groups paths into different groups. There are PT that can group paths as per our choice.

Timing Paths:

Whenever we use a timing tool to report timing for all paths in design, the tool internally builds a graph of all paths. For purpose of STA, one path is defined as one that starts from a start_point and ends at a end_point. Start point is usually  i/p port or clk pin(of seq cell) and end point is usually o/p port or data pin(of seq cell). There may be other types of start/end points too, that we;ll discuss later. Once all such paths are identified, delays from combinatorial cells in b/w the path are put in the graph, and delays calculated for each path.

As discussed above, clk/data paths are most common paths that PT analyzes. These paths start at i/p port or clk pin(of seq cell) and end at o/p port or data pin(of seq cell). There are other kinds of paths too besides these clk/data paths. Pt analyzes 4 types of paths:

  • data path, 
  • clk path (thru Clk tree),
  • clk gating paths,
  • Async paths (on async set/reset pins of flops as recovery/removal checks).

NOTE: clk and data paths are combined for data setup/hold checks. So, in essence we have only 3 kind of paths when analyzing.

PT automatically creates path groups for these paths (each of these path groups have 2 path types: setup(max) and hold(min)):

  1. clk/data path (path group has the name of the clk associated with capture flop/latch, if there are multiple "create_clock" or "create_generated_clock" cmds, then separate path group created for each created/generated clock). Latch may be normal or SR latch. When considering check b/w set/reset pins (non-seq arc), the path group is assigned to the clk, which drives the end_point set/reset pin. Clk/data paths also have other path groups as flop_to_io, io_to_io and io_to_flop.
  2. clkgating paths (clk_gating_default for paths that end on combinational element used for clk gating, EN pin wrt clk)
  3. async paths (async_default for paths that end on asyn set/clr i/p of FF, checks for recovery/removal checks wrt clk). set/clr pins may be driven by o/p of flops, but they are still async wrt capturing clk.
  4. default paths (default) that don't fall into any category.
  5. none (unconstrained paths). => These paths do not have any timing requirement to meet (may be because they do not have any clocks at the end point). We should not have any unconstrained paths in design, except ones that we explicitly set as false path, etc. These are not really a path group.

PT group cmds:

1. path groups: These groups clk/data paths into different groups

group_path ( cmd added in sdc 1.7, cmd is named group_path and NOT path_group, keep that in mind) => As we saw above, there are 4 path groups created by default. These are "default", "clock_gating_default", "async_default" and then 1 path group for each separate clk. We can also have user defined path groups. These are created using group_path cmd. It's used in both synthesis tool and timing tool. In DC, these path groups affect design opt, as they affect max delay cost calculation. We can assign diff weights to each path groups to prioritize opt of one path group over another. In PT, we use it for reporting purpose. By default, PT report_timing reports worst path from each group, so this cmd gives us control over how we want these paths reported (report_timing -group allows us to report worst paths for only the group specified). We may use same sdc file from synthesis, but it's usually beneficial to create new path groups in PT solely for better reporting. Most of the times default path groups are good enough for reporting, so we don't use this cmd in PT (unless we have custom paths that we wan't to report separately).

NOTE: In PT, this cmd has no effect on paths and timing arcs, it's purely for reporting purposes.

syntax: group_path -name <group-name> -default <-options> => -name specifies name for the group and adds paths to that group (if group with that name doesn't exist, it creates a new group). If instead of providing -name, we provide -default, then the specified set of paths is removed from current group and moved to default group.  other options are:

-weight assigns a cost func weight to prioritize opt. Value can range from 0 to 100 (1.0 is the default). 0 implies no weight or equiv to removing the path from cost calc func. Useful only when used in Synthesis tool. This has no meaning in PT, but left in there, since usually same sdc file from synthesis gets used in PT.

-from, -through, -to with rise/fall options are allowed. These specify the paths passing thru these objects. (i.e -from A1 -through {B1 B2} -rise_throghh C1 -fall_to D1 => specifies path starting from A1, passing thru B1 or B2, -then rising thru C1 and fall ending at D1). If clocks are specified as -from objects then all paths with startpoint clocked by that clock are included in group. Similarly for clocks specified as -to objects,  all paths with endpoint clocked by that clock are included in group.

ex: group_path -name "grp1" -to {clk1 clk2} => groups all endpoints clocked by clk1 and clk2 into new grp called "grp1". These paths are removed from their default group of clk1 and clk2.

ex: group_path -from {I1 I2} -through {mod1/Y} -to {O1 O2} => groups all paths starting from I1,I2, going thru Y pin, and ending at O1,O2 into default path group (since name of group not provided, they are removed from existing group and put into default group}

NOTE: sometimes we may see that a path put in 1 path group, shows up in other path group. This may happen due to paths being put in multiple path groups, and some parts of the paths may overlap in multiple groups. In this case, PT cmd precedence criteria figures out to which path group that particular path should belong to. Look under "PT CMD PRECEDENCE" in "PT cmds" section.

report_path_group: report_path_group <pattern> -nosplit => reports all path groups with "weight, from, through and to" info for each path group. We will note following path groups: 1 clock_gating_default path group, 1 async_default path group, 1 default path group and then bunch of clk/data path groups associated with diff clks. These clk/data path groups have all paths in 1 group which have -to to that clk (i.e paths with capture clk named clk1 will be in path group clk1). There are also flop_to_io, io_to_flop and io_to_io paths which comprise of all remaining paths which either originate or end at IO ports. As with most synopsys cmds, we can provide an optional pattern and an optional -nosplit option (which prevents lines from spliting, so it's all in 1 line, makes it easy to be parsed by other scripts).

remove_path_group: remove_path_group <list>=> removes path groups specified in list. Each element in list is either  collection of path groups or a pattern matching path group names. ex: remove_path_group in2out => removes path group in2out and assigns it to default path group. NOTE: removed path group doesn't go back to where it came from, it just goes into the "default" bucket.

2. clock groups:

set_clock_groups (added in sdc 1.7):This cmd has real effect on timing, as it's a timing exception cmd. It's used heavily in PT to mass FP paths b/w multiple clocks. See in "primetime clock commands" section for details.