Skip to content

Commit 00eabea

Browse files
authored
Merge pull request #2466 from Pinata-Consulting/global-route-advertise-congestion-report
open/gui: when loading a failed global route, advertise congestion report
2 parents f61d7a1 + f848eb9 commit 00eabea

File tree

4 files changed

+15
-10
lines changed

4 files changed

+15
-10
lines changed

flow/scripts/detail_route.tcl

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
1-
if {[expr [file exists $::env(REPORTS_DIR)/congestion.rpt] && \
2-
[file size $::env(REPORTS_DIR)/congestion.rpt] != 0]} {
3-
error "Global routing failed, run `make gui_grt` and load $::env(REPORTS_DIR)/congestion.rpt \
4-
in DRC viewer to view congestion"
5-
}
6-
71
utl::set_metrics_stage "detailedroute__{}"
82
source $::env(SCRIPTS_DIR)/load.tcl
3+
if {[expr [file exists $::global_route_congestion_report] && \
4+
[file size $::global_route_congestion_report] != 0]} {
5+
error "Global routing failed, run `make gui_grt` and load $::global_route_congestion_report \
6+
in DRC viewer to view congestion"
7+
}
98
load_design 5_1_grt.odb 4_cts.sdc
109
erase_non_stage_variables route
1110
set_propagated_clock [all_clocks]

flow/scripts/global_route.tcl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ proc global_route_helper {} {
1818
# If GLOBAL_ROUTE_ARGS is specified, then we do only what the
1919
# GLOBAL_ROUTE_ARGS specifies.
2020
proc do_global_route {} {
21-
set all_args [concat [list -congestion_report_file $::env(REPORTS_DIR)/congestion.rpt] \
21+
set all_args [concat [list -congestion_report_file $::global_route_congestion_report] \
2222
[expr {[env_var_exists_and_non_empty GLOBAL_ROUTE_ARGS] ? $::env(GLOBAL_ROUTE_ARGS) : \
2323
{-congestion_iterations 30 -congestion_report_iter_step 5 -verbose}}]]
2424

@@ -29,8 +29,8 @@ proc global_route_helper {} {
2929

3030
if {$result != 0} {
3131
if {[expr !$::env(GENERATE_ARTIFACTS_ON_FAILURE) || \
32-
![file exists $::env(REPORTS_DIR)/congestion.rpt] || \
33-
[file size $::env(REPORTS_DIR)/congestion.rpt] == 0]} {
32+
![file exists $::global_route_congestion_report] || \
33+
[file size $::global_route_congestion_report] == 0]} {
3434
write_db $::env(RESULTS_DIR)/5_1_grt-failed.odb
3535
error $errMsg
3636
}

flow/scripts/open.tcl

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,12 @@ proc read_timing {input_file} {
4141
if {$design_stage >= 6 && [file exist $::env(RESULTS_DIR)/6_final.spef]} {
4242
log_cmd read_spef $::env(RESULTS_DIR)/6_final.spef
4343
} elseif {$design_stage >= 5} {
44-
log_cmd estimate_parasitics -global_routing
44+
if { [grt::have_routes] } {
45+
log_cmd estimate_parasitics -global_routing
46+
} else {
47+
puts "No global routing results available, skipping estimate_parasitics"
48+
puts "Load $::global_route_congestion_report for details"
49+
}
4550
} elseif {$design_stage >= 3} {
4651
log_cmd estimate_parasitics -placement
4752
}

flow/scripts/util.tcl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,3 +115,4 @@ proc erase_non_stage_variables {stage_name} {
115115
}
116116
}
117117

118+
set global_route_congestion_report $::env(REPORTS_DIR)/congestion.rpt

0 commit comments

Comments
 (0)