Skip to content

Commit d48987e

Browse files
authored
Merge pull request The-OpenROAD-Project#5400 from The-OpenROAD-Project-staging/secure-bufrem-p4
enable 100% setup fixing by default
2 parents 417ee6e + 3ca94ab commit d48987e

19 files changed

Lines changed: 263 additions & 224 deletions

src/rsz/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,7 @@ repair_timing
298298
| `-skip_gate_cloning` | Flag to skip gate cloning. The default value is `False`, and the allowed values are bools. |
299299
| `-skip_buffering` | Flag to skip rebuffering and load splitting. The default value is `False`, and the allowed values are bools. |
300300
| `-enable_buffer_removal` | Flag to enable buffer removal during setup fixing. The default value is `False`, and the allowed values are bools. |
301-
| `-repair_tns` | Percentage of violating endpoints to repair (0-100). When `tns_end_percent` is zero (the default), only the worst endpoint is repaired. When `tns_end_percent` is 100, all violating endpoints are repaired. |
301+
| `-repair_tns` | Percentage of violating endpoints to repair (0-100). When `tns_end_percent` is zero, only the worst endpoint is repaired. When `tns_end_percent` is 100 (default), all violating endpoints are repaired. |
302302
| `-max_utilization` | Defines the percentage of core area used. |
303303
| `-max_buffer_percent` | Specify a maximum number of buffers to insert to repair hold violations as a percentage of the number of instances in the design. The default value is `20`, and the allowed values are integers `[0, 100]`. |
304304
| `-verbose` | Enable verbose logging of the repair progress. |

src/rsz/src/RepairSetup.cc

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,12 @@ void RepairSetup::repairSetup(const float setup_slack_margin,
150150
// Always repair the worst endpoint, even if tns percent is zero.
151151
max_end_count = max(max_end_count, 1);
152152
swap_pin_inst_set_.clear(); // Make sure we do not swap the same pin twice.
153+
logger_->info(RSZ,
154+
99,
155+
"Repairing {} out of {} ({:0.2f}%) violating endpoints...",
156+
max_end_count,
157+
violating_ends.size(),
158+
repair_tns_end_percent * 100.0);
153159

154160
// Ensure that max cap and max fanout violations don't get worse
155161
sta_->checkCapacitanceLimitPreamble();

src/rsz/src/Resizer.tcl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -571,7 +571,7 @@ proc repair_timing { args } {
571571
}
572572
set max_buffer_percent [expr $max_buffer_percent / 100.0]
573573

574-
set repair_tns_end_percent 0.0
574+
set repair_tns_end_percent 1.0
575575
if { [info exists keys(-repair_tns)] } {
576576
set repair_tns_end_percent $keys(-repair_tns)
577577
sta::check_percent "-repair_tns" $repair_tns_end_percent

src/rsz/test/buffer_varying_lengths.defok

Lines changed: 200 additions & 200 deletions
Large diffs are not rendered by default.

src/rsz/test/buffer_varying_lengths.ok

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,13 @@
33
[INFO RSZ-0037] Found 118 long wires.
44
[INFO RSZ-0038] Inserted 162 buffers in 118 nets.
55
[INFO RSZ-0039] Resized 183 instances.
6-
worst slack -0.27
6+
worst slack -0.266
7+
tns -28.587
78
[INFO RSZ-0094] Found 200 endpoints with setup violations.
8-
[INFO RSZ-0041] Resized 2 instances.
9+
[INFO RSZ-0099] Repairing 200 out of 200 (100.00%) violating endpoints...
10+
[INFO RSZ-0041] Resized 895 instances.
911
[WARNING RSZ-0062] Unable to repair all setup violations.
1012
[INFO RSZ-0033] No hold violations found.
11-
worst slack -0.27
13+
worst slack -0.266
14+
tns -27.381
1215
No differences found.

src/rsz/test/buffer_varying_lengths.tcl

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,11 @@ set_output_delay -clock clk 0.0 [all_outputs]
5050
set_wire_rc -layer metal2
5151
estimate_parasitics -placement
5252
repair_design
53-
report_worst_slack -max
53+
report_worst_slack -max -digits 3
54+
report_tns -digits 3
5455
repair_timing
55-
report_worst_slack -max
56+
report_worst_slack -max -digits 3
57+
report_tns -digits 3
5658
set def_file [make_result_file buffer_varying_lengths.def]
5759
write_def $def_file
5860
diff_files buffer_varying_lengths.defok $def_file

src/rsz/test/repair_fanout6.ok

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ Pin Limit Fanout Slack
1515
fanout1/X 20 20 0 (MET)
1616

1717
[INFO RSZ-0094] Found 6400 endpoints with setup violations.
18+
[INFO RSZ-0099] Repairing 1 out of 6400 (0.00%) violating endpoints...
1819
[INFO RSZ-0045] Inserted 17 buffers, 1 to split loads.
1920
[INFO RSZ-0041] Resized 150 instances.
2021
[WARNING RSZ-0062] Unable to repair all setup violations.

src/rsz/test/repair_fanout7.ok

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ load DFF_X1 CK D 300000 metal3 1000
88
[INFO ODB-0133] Created 155 nets and 459 connections.
99
worst slack -23.63
1010
[INFO RSZ-0094] Found 150 endpoints with setup violations.
11+
[INFO RSZ-0099] Repairing 150 out of 150 (100.00%) violating endpoints...
1112
Iteration | Removed | Resized | Inserted | Cloned Gates | Pin Swaps | WNS | TNS | Endpoint
1213
| Buffers | | Buffers | | | | |
1314
-------------------------------------------------------------------------------------------------

src/rsz/test/repair_fanout8.ok

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ load DFF_X1 CK D 300000 metal3 1000
88
[INFO ODB-0133] Created 155 nets and 459 connections.
99
worst slack -23.63
1010
[INFO RSZ-0094] Found 150 endpoints with setup violations.
11+
[INFO RSZ-0099] Repairing 150 out of 150 (100.00%) violating endpoints...
1112
Iteration | Removed | Resized | Inserted | Cloned Gates | Pin Swaps | WNS | TNS | Endpoint
1213
| Buffers | | Buffers | | | | |
1314
-------------------------------------------------------------------------------------------------

src/rsz/test/repair_setup1.ok

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ Path Type: max
4242

4343

4444
[INFO RSZ-0094] Found 4 endpoints with setup violations.
45+
[INFO RSZ-0099] Repairing 4 out of 4 (100.00%) violating endpoints...
4546
[INFO RSZ-0040] Inserted 3 buffers.
4647
[INFO RSZ-0041] Resized 18 instances.
4748
[WARNING RSZ-0062] Unable to repair all setup violations.

0 commit comments

Comments
 (0)