Skip to content

Commit 306ef25

Browse files
committed
openroad: single invocation flow has more knobs
erasing variables or not and saving sdc/odb after each stage are now different variables Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
1 parent b7a8ba7 commit 306ef25

4 files changed

Lines changed: 19 additions & 11 deletions

File tree

‎docs/user/FlowVariables.md‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,7 @@ configuration file.
157157
| <a name="IO_PLACER_H"></a>IO_PLACER_H| A list of metal layers on which the I/O pins are placed horizontally (top and bottom of the die).| |
158158
| <a name="IO_PLACER_V"></a>IO_PLACER_V| A list of metal layers on which the I/O pins are placed vertically (sides of the die).| |
159159
| <a name="IR_DROP_LAYER"></a>IR_DROP_LAYER| Default metal layer to report IR drop.| |
160+
| <a name="KEEP_VARS"></a>KEEP_VARS| Feature toggle to keep intermediate variables during the flow. This is useful for the single-run flow, where all stages of the flow are run in a single OpenROAD instance.| 0|
160161
| <a name="KLAYOUT_TECH_FILE"></a>KLAYOUT_TECH_FILE| A mapping from LEF/DEF to GDS using the KLayout tool.| |
161162
| <a name="LATCH_MAP_FILE"></a>LATCH_MAP_FILE| Optional mapping file supplied to Yosys to map latches| |
162163
| <a name="LAYER_PARASITICS_FILE"></a>LAYER_PARASITICS_FILE| Path to per layer parasitics file. Defaults to $(PLATFORM_DIR)/setRC.tcl.| |
@@ -224,7 +225,6 @@ configuration file.
224225
| <a name="SETUP_REPAIR_SEQUENCE"></a>SETUP_REPAIR_SEQUENCE| Specifies the sequence of moves to do in repair_timing -setup. This should be a string of move keywords separated by commas such as the default when not used: "unbuffer,sizedown,sizeup,swap,buffer,clone,split".| |
225226
| <a name="SETUP_SLACK_MARGIN"></a>SETUP_SLACK_MARGIN| Specifies a time margin for the slack when fixing setup violations. This option allows you to overfix or underfix(negative value, terminate retiming before 0 or positive slack). See HOLD_SLACK_MARGIN for more details.| 0|
226227
| <a name="SET_RC_TCL"></a>SET_RC_TCL| Metal & Via RC definition file path.| |
227-
| <a name="SINGLE_OPENROAD_INVOCATION_FLOW"></a>SINGLE_OPENROAD_INVOCATION_FLOW| Instead of invoking OpenROAD once per stage and saving out the .odb and .sdc file at each stage, invoke OpenROAD once and run through all stages in a single OpenROAD instance.| 0|
228228
| <a name="SKIP_ANTENNA_REPAIR"></a>SKIP_ANTENNA_REPAIR| Skips antenna repair entirely.| 0|
229229
| <a name="SKIP_ANTENNA_REPAIR_POST_DRT"></a>SKIP_ANTENNA_REPAIR_POST_DRT| Skips antenna repair post-detailed routing.| 0|
230230
| <a name="SKIP_ANTENNA_REPAIR_PRE_GRT"></a>SKIP_ANTENNA_REPAIR_PRE_GRT| Skips antenna repair pre-global routing.| 0|
@@ -271,6 +271,7 @@ configuration file.
271271
| <a name="VERILOG_FILES"></a>VERILOG_FILES| The path to the design Verilog/SystemVerilog files providing a description of modules.| |
272272
| <a name="VERILOG_INCLUDE_DIRS"></a>VERILOG_INCLUDE_DIRS| Specifies the include directories for the Verilog input files.| |
273273
| <a name="VERILOG_TOP_PARAMS"></a>VERILOG_TOP_PARAMS| Apply toplevel params (if exist). Passed in as a list of key value pairs in tcl syntax; separated by spaces: PARAM1 VALUE1 PARAM2 VALUE2 stages: - synth| |
274+
| <a name="WRITE_ODB_AND_SDC_EACH_STAGE"></a>WRITE_ODB_AND_SDC_EACH_STAGE| Save out .sdc and .odb file after each stage, useful to disable when using a single OpenROAD instance to run all stages of the flow.| 1|
274275
| <a name="YOSYS_FLAGS"></a>YOSYS_FLAGS| Flags to pass to yosys.| -v 3|
275276
## synth variables
276277

@@ -484,9 +485,9 @@ configuration file.
484485

485486
- [NUM_CORES](#NUM_CORES)
486487
- [OPENROAD_HIERARCHICAL](#OPENROAD_HIERARCHICAL)
487-
- [SINGLE_OPENROAD_INVOCATION_FLOW](#SINGLE_OPENROAD_INVOCATION_FLOW)
488488
- [SWAP_ARITH_OPERATORS](#SWAP_ARITH_OPERATORS)
489489
- [SYNTH_WRAPPED_OPERATORS](#SYNTH_WRAPPED_OPERATORS)
490+
- [WRITE_ODB_AND_SDC_EACH_STAGE](#WRITE_ODB_AND_SDC_EACH_STAGE)
490491

491492
## generate_abstract variables
492493

@@ -519,6 +520,7 @@ configuration file.
519520
- [GLOBAL_PLACEMENT_ARGS](#GLOBAL_PLACEMENT_ARGS)
520521
- [GUI_TIMING](#GUI_TIMING)
521522
- [IR_DROP_LAYER](#IR_DROP_LAYER)
523+
- [KEEP_VARS](#KEEP_VARS)
522524
- [KLAYOUT_TECH_FILE](#KLAYOUT_TECH_FILE)
523525
- [LAYER_PARASITICS_FILE](#LAYER_PARASITICS_FILE)
524526
- [LIB_FILES](#LIB_FILES)

‎flow/scripts/floorplan_to_place.tcl‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
# Enable keeping variables between stages
2-
set ::env(SINGLE_OPENROAD_INVOCATION_FLOW) 1
2+
set ::env(KEEP_VARS) 1
3+
set ::env(WRITE_ODB_AND_SDC_EACH_STAGE) 0
34

45
# Floorplan
56
source $::env(SCRIPTS_DIR)/floorplan.tcl

‎flow/scripts/util.tcl‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ proc find_macros { } {
145145
}
146146

147147
proc erase_non_stage_variables { stage_name } {
148-
if { $::env(SINGLE_OPENROAD_INVOCATION_FLOW) } {
148+
if { $::env(KEEP_VARS) } {
149149
return
150150
}
151151
# "$::env(SCRIPTS_DIR)/stage_variables.py stage_name" returns list of
@@ -243,14 +243,14 @@ proc find_physical_only_masters { } {
243243
}
244244

245245
proc orfs_write_db { output_file } {
246-
if { $::env(SINGLE_OPENROAD_INVOCATION_FLOW) } {
246+
if { !$::env(WRITE_ODB_AND_SDC_EACH_STAGE) } {
247247
return
248248
}
249249
log_cmd write_db $output_file
250250
}
251251

252252
proc orfs_write_sdc { output_file } {
253-
if { $::env(SINGLE_OPENROAD_INVOCATION_FLOW) } {
253+
if { !$::env(WRITE_ODB_AND_SDC_EACH_STAGE) } {
254254
return
255255
}
256256
log_cmd write_sdc -no_timestamp $output_file

‎flow/scripts/variables.yaml‎

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1232,11 +1232,16 @@ NUM_CORES:
12321232
routing, or place jobs running at the same time.
12331233
stages:
12341234
- All stages
1235-
SINGLE_OPENROAD_INVOCATION_FLOW:
1235+
KEEP_VARS:
12361236
description: >
1237-
Instead of invoking OpenROAD once per stage and saving out the
1238-
.odb and .sdc file at each stage, invoke OpenROAD once and run
1239-
through all stages in a single OpenROAD instance.
1237+
Feature toggle to keep intermediate variables during the flow.
1238+
This is useful for the single-run flow, where all stages of the flow
1239+
are run in a single OpenROAD instance.
1240+
default: 0
1241+
WRITE_ODB_AND_SDC_EACH_STAGE:
1242+
description: >
1243+
Save out .sdc and .odb file after each stage, useful to disable
1244+
when using a single OpenROAD instance to run all stages of the flow.
12401245
stages:
12411246
- All stages
1242-
default: 0
1247+
default: 1

0 commit comments

Comments
 (0)