Skip to content

flow: Add the lowest-VT-only flow and repair_power knobs - #4822

Draft
jhkim-pii wants to merge 2 commits into
The-OpenROAD-Project:masterfrom
The-OpenROAD-Project-staging:secure-lowest-vt-only
Draft

jhkim-pii wants to merge 2 commits into
The-OpenROAD-Project:masterfrom
The-OpenROAD-Project-staging:secure-lowest-vt-only

Conversation

@jhkim-pii

Copy link
Copy Markdown
Contributor

Summary

  • Adds flow knobs for a lowest-VT-only flow (LOWEST_VT_ONLY) and for power recovery with repair_power (REPAIR_POWER, REPAIR_POWER_VT_BUDGET).

Why this PR is needed

  • Use case: A design team wants the best timing first, so the flow should build and repair the design with the lowest (fastest) VT only, and then move the cells that have slack back to the higher VTs to save power.
  • Today: This takes a hand-written dont use list in the design config and a Tcl hook that lifts the list before the power recovery and restores it after.
  • With this PR: The platform lists the cells of the other VTs once, and a design turns the flow on with one variable.

Problem

  • No flow variable selects the VTs a design may use, and repair_power is not called by the flow.
# Before: per design, by hand
export DONT_USE_CELLS += <every cell of the other VTs>
export POST_GLOBAL_ROUTE_TCL = <hook: reset_dont_use, set_dont_use, repair_power, restore>

Changes

Area Before After
Dont use list DONT_USE_CELLS only dont_use_cells in util.tcl: DONT_USE_CELLS plus NON_LOWEST_VT_CELLS when LOWEST_VT_ONLY=1; used by the seven set_dont_use and ABC -dont_use sites
Power recovery after the global route repair RECOVER_POWER (repair_timing -recover_power) Also REPAIR_POWER=1: repair_power inside an incremental global route; with LOWEST_VT_ONLY the higher VTs are lifted before it and restored after
VT budget None REPAIR_POWER_VT_BUDGET is passed as repair_power -vt_budget
Platforms No VT cell list NON_LOWEST_VT_CELLS ?= in asap7 (from ASAP7_USE_VT) and gt2n (from GT2N_USE_VT); empty on single-VT platforms
flowchart LR
  A[Synthesis] --> B[Floorplan, place, CTS] --> C[Global route + timing repair] --> D[repair_power] --> E[Detailed route]
  A -. lowest VT only .- C
  D -. every VT usable .- D
Loading

UI Changes

# design config.mk
export LOWEST_VT_ONLY = 1
export REPAIR_POWER = 1
export REPAIR_POWER_VT_BUDGET = *_ASAP7_75t_SL 50   # optional
Variable Default Meaning
LOWEST_VT_ONLY 0 Add NON_LOWEST_VT_CELLS to the dont use cells from synthesis to the global route timing repair
NON_LOWEST_VT_CELLS empty Cell patterns of every VT but the lowest; set by the platform
REPAIR_POWER 0 Run repair_power after the global route timing repair
REPAIR_POWER_VT_BUDGET unset -vt_budget of repair_power: pairs of cell patterns and a percent

Impact

  • All knobs are off by default; flows that do not set them run the same commands as before.
  • On a single-VT platform LOWEST_VT_ONLY=1 changes nothing, since NON_LOWEST_VT_CELLS is empty.
  • Dependency: repair_power and the VT swap fixes for dont use changes are OpenROAD changes that are not in tools/OpenROAD yet. This PR does not bump the submodule, so REPAIR_POWER = 1 fails until they land. The default flow is not affected.
Details

Flow

  • Synthesis: Both the Yosys/ABC path and the OpenROAD synthesis path take the same list from dont_use_cells.
  • Floorplan to global route repair: set_dont_use [dont_use_cells].
  • Power recovery: repair_power_helper runs reset_dont_use, set_dont_use with DONT_USE_CELLS only, repair_power -verbose [-setup_margin] [-vt_budget], then restores the full list. SETUP_SLACK_MARGIN is passed when it is not 0.
  • Clock buffers: CTS_BUF_LIST is not changed by the knobs.

Testing

  • Run locally with an OpenROAD build that has repair_power and the VT swap fixes.
  • asap7 gcd with ASAP7_USE_VT = RVT LVT SLVT, LOWEST_VT_ONLY = 1, REPAIR_POWER = 1 (local config, not in this PR): Completes; the synthesized netlist is SLVT only (304 cells, 0 RVT, 0 LVT); repair_power brings SLVT from 100% to 4.3% of the logic cells (budget 50%) and total power from 711 to 603 uW; final setup WS +5.4 ps, no slew or capacitance violation.
  • Knobs through a private multi-VT platform: The four combinations (off, REPAIR_POWER, LOWEST_VT_ONLY + REPAIR_POWER, plus a VT budget) give the same final metrics as the hand-written hook flow.
  • Knobs off: The same design gives identical final metrics on this branch and on master.
  • tclfmt, tclint, yamlfix and generate-variables-docs.py pass.

vvbandeira and others added 2 commits November 9, 2026 15:35
…t-private/upload-design-outcomes

Report how each design's flow run ended in the metadata upload
What:
- LOWEST_VT_ONLY=1 synthesizes, places and repairs timing with the lowest
  VT only: the cells in NON_LOWEST_VT_CELLS join the dont use cells from
  synthesis to the global route timing repair.
- REPAIR_POWER=1 runs repair_power after the global route timing repair,
  and REPAIR_POWER_VT_BUDGET is passed as its -vt_budget. With
  LOWEST_VT_ONLY the power recovery may use every VT.
- NON_LOWEST_VT_CELLS is a platform default: asap7 and gt2n derive it
  from the loaded VTs; a platform with a single VT leaves it empty and
  LOWEST_VT_ONLY changes nothing there.

Why: a lowest-VT-only flow closes timing with the fastest cells and then
recovers power with the higher VTs. It took a hand-written dont use list
and a Tcl hook that lifts and restores it around the power recovery.

How:
- util.tcl: dont_use_cells returns DONT_USE_CELLS plus
  NON_LOWEST_VT_CELLS when LOWEST_VT_ONLY is set; the seven set_dont_use
  and ABC -dont_use sites use it. repair_power_helper lifts the higher
  VTs, runs repair_power and restores the list.
- global_route.tcl calls repair_power_helper inside an incremental
  global route when REPAIR_POWER is set.
- variables.yaml and FlowVariables.md list the four variables.
- repair_power and the VT swap fixes it relies on are OpenROAD changes
  that are not in tools/OpenROAD yet; the knobs are off by default.

Signed-off-by: Jaehyun Kim <jhkim@precisioninno.com>
@jhkim-pii jhkim-pii self-assigned this Nov 11, 2026

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces support for a lowest-VT-only flow (LOWEST_VT_ONLY) in OpenROAD-flow-scripts, allowing synthesis, placement, and timing repair using only the fastest VT cells, followed by power recovery (REPAIR_POWER) after global routing. It also updates the metadata upload script (uploadMetadata.py) and its tests to parse and report detailed flow outcomes (such as timeouts, crashes, and errors) from stage logs. All provided review comments were filtered out as they suggested one-off encoding cleanups, which is discouraged by the repository's style guide. Consequently, there is no additional feedback to provide.

@jhkim-pii
jhkim-pii marked this pull request as draft November 11, 2026 04:52
@openroad-ci

Copy link
Copy Markdown
Member

🔍 QoR check

Metrics reflect the PR merge build — i.e. what will land on the target branch.

Commit b353340 · Jenkins build #1 · Baseline: build · View build on dashboard

62 design(s) checked — 0 with regression(s), 0 without a comparable baseline.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants