Parameterize PDK specific variables in common_pdn.tcl
diff --git a/sky130/openlane/common_pdn.tcl b/sky130/openlane/common_pdn.tcl index 3982b7f..a608757 100644 --- a/sky130/openlane/common_pdn.tcl +++ b/sky130/openlane/common_pdn.tcl
@@ -13,10 +13,12 @@ if { [info exists ::env(FP_PDN_ENABLE_GLOBAL_CONNECTIONS)] } { if { $::env(FP_PDN_ENABLE_GLOBAL_CONNECTIONS) == 1 } { - add_global_connection -net $::env(VDD_NET) -inst_pattern .* -pin_pattern {VPWR} -power - add_global_connection -net $::env(VDD_NET) -inst_pattern .* -pin_pattern {VPB} -power - add_global_connection -net $::env(GND_NET) -inst_pattern .* -pin_pattern {VGND} -ground - add_global_connection -net $::env(GND_NET) -inst_pattern .* -pin_pattern {VNB} -ground + foreach power_pin $::env(STD_CELL_POWER_PINS) { + add_global_connection -net $::env(VDD_NET) -inst_pattern .* -pin_pattern $power_pin -power + } + foreach ground_pin $::env(STD_CELL_GROUND_PINS) { + add_global_connection -net $::env(GND_NET) -inst_pattern .* -pin_pattern $ground_pin -ground + } } } @@ -58,7 +60,7 @@ orient {R0 R180 MX MY R90 R270 MXR90 MYR90} power_pins $::env(VDD_NET) ground_pins $::env(GND_NET) - blockages "li1 met1 met2 met3 met4" + blockages $::env(MACRO_BLOCKAGES_LAYER) straps { } connect {{$::env(FP_PDN_LOWER_LAYER)_PIN_ver $::env(FP_PDN_UPPER_LAYER)}}
diff --git a/sky130/openlane/config.tcl b/sky130/openlane/config.tcl index 310a82b..c16fee3 100755 --- a/sky130/openlane/config.tcl +++ b/sky130/openlane/config.tcl
@@ -8,6 +8,9 @@ set ::env(VDD_PIN) "VPWR" set ::env(GND_PIN) "VGND" +set ::env(STD_CELL_POWER_PINS) "VPWR VPB" +set ::env(STD_CELL_GROUND_PINS) "VGND VNB" + # Technology LEF #ifdef EF_FORMAT set ::env(TECH_LEF) "$::env(PDK_ROOT)/$::env(PDK)/libs.ref/techLEF/$::env(STD_CELL_LIBRARY)/$::env(STD_CELL_LIBRARY).tlef" @@ -160,6 +163,9 @@ set ::env(FP_PDN_CORE_RING_VOFFSET) 6 set ::env(FP_PDN_CORE_RING_HOFFSET) 6 +# PDN Macro blockages list +set ::env(MACRO_BLOCKAGES_LAYER) "li1 met1 met2 met3 met4" + # Used for parasitics estimation, IR drop analysis, etc set ::env(WIRE_RC_LAYER) "met1" set ::env(DATA_WIRE_RC_LAYER) "met2"