Skip to content

Commit

Permalink
scripts: Add REPAIR_TIMING_MAX_PASSES_PER_ITER parameters
Browse files Browse the repository at this point in the history
Signed-off-by: Eryk Szpotanski <[email protected]>
  • Loading branch information
eszpotanski committed Nov 25, 2024
1 parent 3cf48df commit f69b905
Show file tree
Hide file tree
Showing 5 changed files with 32 additions and 6 deletions.
2 changes: 1 addition & 1 deletion flow/scripts/cts.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ if {![env_var_equals SKIP_CTS_REPAIR_TIMING 1]} {
write_eqy_verilog 4_before_rsz.v
}

repair_timing_helper
repair_timing_helper "cts"

if {$::env(EQUIVALENCE_CHECK)} {
run_equivalence_test
Expand Down
6 changes: 3 additions & 3 deletions flow/scripts/floorplan.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -108,13 +108,13 @@ if { [env_var_equals REMOVE_ABC_BUFFERS 1] } {
# remove buffers inserted by yosys/abc
remove_buffers
} else {
repair_timing_helper 0
repair_timing_helper "floorplan" 0
}

##### Restructure for timing #########
if { [env_var_equals RESYNTH_TIMING_RECOVER 1] } {
repair_design_helper
repair_timing_helper
repair_timing_helper "floorplan"
# pre restructure area/timing report (ideal clocks)
puts "Post synth-opt area"
report_design_area
Expand All @@ -134,7 +134,7 @@ if { [env_var_equals RESYNTH_TIMING_RECOVER 1] } {
# post restructure area/timing report (ideal clocks)
remove_buffers
repair_design_helper
repair_timing_helper
repair_timing_helper "floorplan"

puts "Post restructure-opt wns"
report_worst_slack -max -digits 3
Expand Down
2 changes: 1 addition & 1 deletion flow/scripts/global_route.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ proc global_route_helper {} {
puts "Repair setup and hold violations..."
estimate_parasitics -global_routing

repair_timing_helper
repair_timing_helper "grt"

if { $::env(DETAILED_METRICS) } {
report_metrics 5 "global route post repair timing"
Expand Down
10 changes: 9 additions & 1 deletion flow/scripts/util.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ proc fast_route {} {
}
}

proc repair_timing_helper { {hold_margin 1} } {
proc repair_timing_helper { stage {hold_margin 1} } {
set additional_args "-verbose"
append_env_var additional_args SETUP_SLACK_MARGIN -setup_margin 1
if {$hold_margin || $::env(HOLD_SLACK_MARGIN) < 0} {
Expand All @@ -27,6 +27,14 @@ proc repair_timing_helper { {hold_margin 1} } {
append_env_var additional_args SKIP_BUFFER_REMOVAL -skip_buffer_removal 0
append_env_var additional_args SKIP_LAST_GASP -skip_last_gasp 0
append_env_var additional_args MATCH_CELL_FOOTPRINT -match_cell_footprint 0
if { $stage == "floorplan"} {
set max_passes_prefix "FP_"
} elseif { $stage == "cts" } {
set max_passes_prefix "CTS_"
} elseif { $stage == "grt"} {
set max_passes_prefix "GRT_"
}
append_env_var additional_args "${max_passes_prefix}REPAIR_TIMING_MAX_PASSES_PER_ITER" -max_passes_per_iter 1
puts "repair_timing [join $additional_args " "]"
repair_timing {*}$additional_args
}
Expand Down
18 changes: 18 additions & 0 deletions flow/scripts/variables.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,12 @@ IO_PLACER_V:
stages:
- floorplan
- place
FP_REPAIR_TIMING_MAX_PASSES_PER_ITER:
description: >
Maximum number of repairs per iteration during repair_timing, called from floorplan.
default: 20
stages:
- floorplan
GUI_TIMING:
description: >
Load timing information when opening GUI. For large designs, this can
Expand Down Expand Up @@ -609,6 +615,12 @@ CTS_CLUSTER_SIZE:
default: 50
stages:
- cts
CTS_REPAIR_TIMING_MAX_PASSES_PER_ITER:
description: >
Maximum number of repairs per iteration during repair_timing, called from CTS.
default: 20
stages:
- cts
CTS_SNAPSHOT:
description: >
Creates ODB/SDC files prior to clock net and setup/hold repair.
Expand Down Expand Up @@ -640,6 +652,12 @@ GLOBAL_ROUTE_ARGS:
stages:
- grt
default: -congestion_iterations 30 -congestion_report_iter_step 5 -verbose
GRT_REPAIR_TIMING_MAX_PASSES_PER_ITER:
description: >
Maximum number of repairs per iteration during repair_timing, called from GRT.
default: 20
stages:
- grt
MATCH_CELL_FOOTPRINT:
description: >
Enforce sizing operations to only swap cells that have the same layout boundary.
Expand Down

0 comments on commit f69b905

Please sign in to comment.