Skip to content

Commit b55f06b

Browse files
committed
flow: move netlist transforms from floorplan.tcl into synth_odb.tcl
replace_arith_modules (under SWAP_ARITH_OPERATORS), remove_buffers and repair_timing_helper (under REMOVE_ABC_BUFFERS) are netlist-level transforms that do not depend on having a floorplan. Move them into synth_odb.tcl, before source_step_tcl POST SYNTH, so the synthesized netlist hand-off (1_synth.odb) reflects what the synthesis stage actually produced. This also drops the stale ordering comment on repair_tie_fanout that warned about preceding remove_buffers — repair_tie_fanout now runs in a later stage where the constraint is no longer relevant. Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
1 parent e5477f1 commit b55f06b

5 files changed

Lines changed: 20 additions & 22 deletions

File tree

‎docs/user/FlowVariables.md‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,7 @@ configuration file.
239239
| <a name="PWR_NETS_VOLTAGES"></a>PWR_NETS_VOLTAGES| Used for IR Drop calculation.| |
240240
| <a name="RCX_RULES"></a>RCX_RULES| RC Extraction rules file path.| |
241241
| <a name="RECOVER_POWER"></a>RECOVER_POWER| Specifies how many percent of paths with positive slacks can be slowed for power savings [0-100].| 0|
242-
| <a name="REMOVE_ABC_BUFFERS"></a>REMOVE_ABC_BUFFERS (deprecated)| Remove abc buffers from the netlist. If timing repair in floorplanning is taking too long, use a SETUP/HOLD_SLACK_MARGIN to terminate timing repair early instead of using REMOVE_ABC_BUFFERS or set SKIP_LAST_GASP=1.| 0|
242+
| <a name="REMOVE_ABC_BUFFERS"></a>REMOVE_ABC_BUFFERS (deprecated)| Remove abc buffers from the netlist. If post-synth timing repair is taking too long, use a SETUP/HOLD_SLACK_MARGIN to terminate timing repair early instead of using REMOVE_ABC_BUFFERS or set SKIP_LAST_GASP=1.| 0|
243243
| <a name="REMOVE_CELLS_FOR_LEC"></a>REMOVE_CELLS_FOR_LEC| String patterns directly passed to write_verilog -remove_cells <> for lec checks.| |
244244
| <a name="REPAIR_PDN_VIA_LAYER"></a>REPAIR_PDN_VIA_LAYER| Remove power grid vias which generate DRC violations after detailed routing.| |
245245
| <a name="REPORT_CLOCK_SKEW"></a>REPORT_CLOCK_SKEW| Report clock skew as part of reporting metrics, starting at CTS, before which there is no clock skew. This metric can be quite time-consuming, so it can be useful to disable.| 1|
@@ -345,6 +345,7 @@ configuration file.
345345
- [MIN_BUF_CELL_AND_PORTS](#MIN_BUF_CELL_AND_PORTS)
346346
- [POST_SYNTH_TCL](#POST_SYNTH_TCL)
347347
- [PRE_SYNTH_TCL](#PRE_SYNTH_TCL)
348+
- [REMOVE_ABC_BUFFERS](#REMOVE_ABC_BUFFERS)
348349
- [SDC_FILE](#SDC_FILE)
349350
- [SDC_GUT](#SDC_GUT)
350351
- [SLANG_PLUGIN_PATH](#SLANG_PLUGIN_PATH)
@@ -417,7 +418,6 @@ configuration file.
417418
- [PRE_MACRO_PLACE_TCL](#PRE_MACRO_PLACE_TCL)
418419
- [PRE_PDN_TCL](#PRE_PDN_TCL)
419420
- [PRE_TAPCELL_TCL](#PRE_TAPCELL_TCL)
420-
- [REMOVE_ABC_BUFFERS](#REMOVE_ABC_BUFFERS)
421421
- [ROUTING_LAYER_ADJUSTMENT](#ROUTING_LAYER_ADJUSTMENT)
422422
- [RTLMP_AREA_WT](#RTLMP_AREA_WT)
423423
- [RTLMP_ARGS](#RTLMP_ARGS)

‎flow/scripts/floorplan.tcl‎

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -76,8 +76,6 @@ if { [env_var_exists_and_non_empty FASTROUTE_TCL] } {
7676
source_env_var_if_exists FOOTPRINT_TCL
7777

7878
if { !$::env(SKIP_REPAIR_TIE_FANOUT) } {
79-
# This needs to come before any call to remove_buffers. You could have one
80-
# tie driving multiple buffers that drive multiple outputs.
8179
# Repair tie lo fanout
8280
puts "Repair tie lo fanout..."
8381
set tielo_cell_name [lindex $::env(TIELO_CELL_AND_PORT) 0]
@@ -93,20 +91,6 @@ if { !$::env(SKIP_REPAIR_TIE_FANOUT) } {
9391
repair_tie_fanout -separation $::env(TIE_SEPARATION) $tiehi_pin
9492
}
9593

96-
if { [env_var_exists_and_non_empty SWAP_ARITH_OPERATORS] } {
97-
# Enable sanity checker until replace_arith_modules becomes stable
98-
set_debug_level ODB replace_design_check_sanity 1
99-
replace_arith_modules
100-
}
101-
102-
if { $::env(REMOVE_ABC_BUFFERS) } {
103-
# remove buffers inserted by yosys/abc
104-
remove_buffers
105-
} else {
106-
# Skip clone & split
107-
repair_timing_helper -setup -skip_last_gasp -sequence "unbuffer,sizeup,swap,vt_swap"
108-
}
109-
11094
puts "Default units for flow"
11195
report_units
11296
report_units_metric

‎flow/scripts/synth_odb.tcl‎

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,20 @@ check_setup
5151
set num_instances [llength [get_cells -hier *]]
5252
puts "number instances in verilog is $num_instances"
5353

54+
if { [env_var_exists_and_non_empty SWAP_ARITH_OPERATORS] } {
55+
# Enable sanity checker until replace_arith_modules becomes stable
56+
set_debug_level ODB replace_design_check_sanity 1
57+
replace_arith_modules
58+
}
59+
60+
if { $::env(REMOVE_ABC_BUFFERS) } {
61+
# remove buffers inserted by yosys/abc
62+
remove_buffers
63+
} else {
64+
# Skip clone & split
65+
repair_timing_helper -setup -skip_last_gasp -sequence "unbuffer,sizeup,swap,vt_swap"
66+
}
67+
5468
source_step_tcl POST SYNTH
5569
orfs_write_db $::env(RESULTS_DIR)/1_synth.odb
5670
# Canonicalize 1_synth.sdc. The original SDC_FILE provided by

‎flow/scripts/variables.json‎

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎flow/scripts/variables.yaml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -450,11 +450,11 @@ BUFFER_PORTS_ARGS:
450450
- place
451451
REMOVE_ABC_BUFFERS:
452452
description: >
453-
Remove abc buffers from the netlist. If timing repair in floorplanning is
453+
Remove abc buffers from the netlist. If post-synth timing repair is
454454
taking too long, use a SETUP/HOLD_SLACK_MARGIN to terminate timing repair early
455455
instead of using REMOVE_ABC_BUFFERS or set SKIP_LAST_GASP=1.
456456
stages:
457-
- floorplan
457+
- synth
458458
deprecated: 1
459459
default: 0
460460
BALANCE_ROWS:

0 commit comments

Comments
 (0)