IntermediateQuestion 147 of 162Source: Synopsys ICC2 Implementation User Guide: Routing

How do soft and hard net layer constraints differ?

From PDVerse PnR Interview Handbook · pdVerse Mentor Guide

Short Answer

A hard layer constraint is never broken: the router will not use a layer outside it. A soft one can be broken at a cost if that helps routing. For net-specific constraints set with set_routing_rule, the default is min layer soft and max layer hard, and you can change either default or set the mode per constraint.

Technical Reference DiagramHow do soft and hard net layer constraints differ?
A layer band for one net with the soft minimum layer allowing a short dip below it near a pin, and the hard maximum layer drawn as a red wall the route cannot cross.

Technical Explanation

  • Net-specific layer constraints are set with set_routing_rule and its -min_routing_layer and -max_routing_layer options. They are separate from the block-wide limits set with set_ignored_layers.
  • By default the minimum layer is soft and the maximum layer is hard. That means a net can drop below its min layer when it helps, for example near a pin, but it can never go above its max layer.
  • The mode can be soft, allow_pin_connection or hard. allow_pin_connection lets the net break the limit to connect to pins (and, per the command reference, to fix DRCs in very congested areas), which is often the right choice for a min layer.
  • The defaults for all nets are changed with route.common.net_min_layer_mode and route.common.net_max_layer_mode. A single constraint can be changed with -min_layer_mode or -max_layer_mode on set_routing_rule.
  • The cost of breaking a soft constraint is low, medium (the default) or high, set globally with route.common.net_min_layer_mode_soft_cost and route.common.net_max_layer_mode_soft_cost, or per constraint.
  • Global min and max layers have their own mode options (route.common.global_min_layer_mode and route.common.global_max_layer_mode); clock layer constraints follow the net mode options. check_routability treats these limits as hard only when those application options, or route.common.net_min_layer_mode and route.common.net_max_layer_mode, are set to hard.
  • set_routing_rule -clear removes net-specific layer constraints and also any NDR assigned to those nets, so use it carefully.

What To Check

  • The layer constraints on critical nets and their modes.
  • After routing, the length of each net that sits outside its min layer.
  • Whether any net violates a hard constraint, which check_routes reports as a min or max layer violation.
  • Blocked-port results from check_routability for nets with hard constraints.

Command Checks & Actions

ICC2set_routing_rule [get_nets n1] -min_routing_layer M3 -max_routing_layer M6 -min_layer_mode hard

Keeps net n1 between M3 and M6, with the min layer made hard.

ICC2set_app_options -name route.common.net_min_layer_mode -value allow_pin_connection

Changes the default min layer mode for all nets so they may only go lower to reach pins.

ICC2check_routes

Reports minimum layer and maximum layer violations after routing.

ICC2report_wirelength -nets [get_nets n1]

Shows wire length per layer for the net, so you can see how much ran below its min layer.

Healthy, Suspicious & Hard-stop Results

  • Healthy (illustrative): Critical nets stay in their band except short pin connections, and check_routes shows no layer violations.
  • Suspicious (illustrative): A net spending a large share of its length below a soft min layer, usually a sign of congestion on its preferred layers.
  • Hard stop: A hard constraint on a net whose pins sit only on layers outside it. It cannot be routed.

Common Mistake

The Trap: Making the min layer hard on a net whose driver pin is on M1. With a hard M3 minimum, the router has no legal way to reach the pin, so the net stays open or collects DRCs at the pin. allow_pin_connection would have kept the net high while still letting it reach its pins.

What The Interviewer Is Testing

  • Whether you know the default modes for net-specific constraints.
  • Can you choose between soft, pin-connection and hard for a given net?
  • A strong answer shows you connect hard constraints to pin access.

Follow-up Question & Model Response

"Why is the default max layer hard and the min layer soft?"

Candidate Model Response: Going above a max layer usually means using layers reserved for something else, such as power or top-level routing, which can break the whole design plan. Going below a min layer usually happens near pins, which live on low layers, and blocking that would leave nets unroutable. So the defaults protect what is reserved above and stay practical about reaching pins below.

Practical Example

Tapeout Scenario: A timing-critical net should run on M5 and M6 for low resistance (illustrative). The engineer sets -min_routing_layer M5 -max_routing_layer M6 with the default soft minimum. After routing, 40% of its 600 um sits on M3 because M5 and M6 are congested along its path, and its delay is 9 ps worse than planned. Making the min layer hard fails at the pins, which are on M1. Setting -min_layer_mode allow_pin_connection gives the right result: 94% of the length on M5 and M6, with only the pin connections below, and the net recovers 7 ps.

PnR Flow Mentor Guide

Read the complete 8-chapter PnR Flow Mentor Guide free on the web — library setup through placement, clock tree synthesis, routing, chip finishing, hierarchical implementation, and ECO, all the way to stream-out.

PnR Flow Physical Design Mentor Guide — eight chaptersPnR Flow Mentor GuideEight chapters, library setup through to stream-out. →