remove unused functions in net RC script and renaming for concision#4378
Conversation
Signed-off-by: Arthur Koucher <arthurkoucher@precisioninno.com>
There was a problem hiding this comment.
Code Review
This pull request refactors flow/util/write_net_rc.tcl and its calling script by removing several unused procedures and renaming write_rc_csv to write_nets_rc_csv and record_wire_rc to fetch_nets_rc. The review feedback suggests optimizing fetch_nets_rc to only process CLOCK and SIGNAL nets, which would avoid unnecessary and expensive parasitic computations on power and ground nets in large designs.
| } | ||
|
|
||
| proc record_wire_rc { var_name } { | ||
| proc fetch_nets_rc { var_name } { |
There was a problem hiding this comment.
In the current implementation, fetch_nets_rc iterates over all nets in the design using get_nets * and computes their wire resistance and capacitance. However, write_nets_rc_csv only processes and writes out nets of type CLOCK or SIGNAL.
For large designs, power and ground (supply) nets can have extremely large and complex parasitic networks. Computing parasitics for these nets is highly inefficient and unnecessary since they are filtered out later.
Consider filtering the nets in fetch_nets_rc to only include CLOCK and SIGNAL types to significantly improve performance:
proc fetch_nets_rc { var_name } {
upvar 1 $var_name var
foreach net [get_nets *] {
set db_net [sta::sta_to_db_net $net]
set type [$db_net getSigType]
if {[string equal $type "CLOCK"] || [string equal $type "SIGNAL"]} {
set net_name [get_full_name $net]
set wire_res [net_wire_res $net]
set wire_cap [net_wire_cap $net]
set var($net_name) [list $wire_res $wire_cap]
}
}
}There was a problem hiding this comment.
I don't think this is relevant enough to be addressed in this PR. I can tackle it subsequently when bundling write_net_rc_script.tcl and write_segment_rc_script.tcl.
10d4ff7
into
The-OpenROAD-Project:master
No description provided.