Skip to content

Commit 4dd166b

Browse files
committed
Merge remote-tracking branch 'origin/master' into HEAD
2 parents 7678d55 + 0b6de66 commit 4dd166b

File tree

7 files changed

+22
-33
lines changed

7 files changed

+22
-33
lines changed

flow/MODULE.bazel

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -15,17 +15,6 @@ git_override(
1515
remote = "https://github.com/The-OpenROAD-Project/bazel-orfs.git",
1616
)
1717

18-
# Read: https://github.com/The-OpenROAD-Project/bazel-orfs?tab=readme-ov-file#usage
19-
#
20-
# TL;DR
21-
#
22-
# 1. uncomment below
23-
# 2. comment git_override() above
24-
#
25-
#local_path_override(
26-
# module_name = "bazel-orfs", path = "../bazel-orfs"
27-
#)
28-
2918
bazel_dep(name = "rules_python", version = "0.31.0")
3019

3120
python = use_extension("@rules_python//python/extensions:python.bzl", "python")

flow/designs/sky130hd/microwatt/rules-base.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
"compare": "<="
4141
},
4242
"detailedroute__antenna__violating__nets": {
43-
"value": 0,
43+
"value": 1,
4444
"compare": "<="
4545
},
4646
"detailedroute__antenna_diodes_count": {

flow/platforms/ihp-sg13g2/config.mk

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -139,3 +139,11 @@ export CDL_FILE ?= $(PLATFORM_DIR)/cdl/sg13g2_stdcell.cdl
139139

140140
#Temporary: skip post-DRT repair antennas
141141
export SKIP_ANTENNA_REPAIR_POST_DRT = 1
142+
143+
# ---------------------------------------------------------
144+
# Final
145+
# ---------------------------------------------------------
146+
147+
# SRAM macros have empty placeholder cells included. Just ignore them to not
148+
# thrown an error.
149+
export GDS_ALLOW_EMPTY = RM_IHPSG13_1P_BITKIT_16x2_(CORNER|EDGE_TB|LE_con_corner|LE_con_edge_lr|LE_con_tap_lr|POWER_ramtap|TAP|TAP_LR)

flow/scripts/open.tcl

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ 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-
if { [grt::have_routes] } {
44+
if { [log_cmd grt::have_routes] } {
4545
log_cmd estimate_parasitics -global_routing
4646
} else {
4747
puts "No global routing results available, skipping estimate_parasitics"
@@ -51,10 +51,8 @@ proc read_timing {input_file} {
5151
log_cmd estimate_parasitics -placement
5252
}
5353

54-
puts -nonewline "Populating timing paths..."
5554
# Warm up OpenSTA, so clicking on timing related buttons reacts faster
56-
set _tmp [find_timing_paths]
57-
puts "OK"
55+
set _tmp [log_cmd find_timing_paths]
5856
}
5957

6058
if {[ord::openroad_gui_compiled]} {

flow/scripts/util.tcl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,14 @@ proc log_cmd {cmd args} {
33
set log_cmd "$cmd[join [lmap arg $args {format " %s" [expr {[string match {* *} $arg] ? "\"$arg\"" : "$arg"}]}] ""]"
44
puts $log_cmd
55
set start [clock seconds]
6-
$cmd {*}$args
6+
set result [uplevel 1 [list $cmd {*}$args]]
77
set time [expr {[clock seconds] - $start}]
88
if {$time >= 5} {
99
# Ideally we'd use a single line, but the command can output text
1010
# and we don't want to mix it with the log, so output the time it took afterwards.
1111
puts "Took $time seconds: $log_cmd"
1212
}
13+
return $result
1314
}
1415

1516
proc fast_route {} {

flow/scripts/write_ref_sdc.tcl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ if { [llength $clks] == 0 } {
2525
create_clock -name $clk_name -period $ref_period $sources
2626
# Undo the set_propagated_clock so SDC at beginning of flow uses ideal clocks.
2727
unset_propagated_clock [all_clocks]
28-
write_sdc -no_timestamp [file join $env(RESULTS_DIR) "updated_clks.sdc"]
28+
write_sdc -no_timestamp [file join $::env(RESULTS_DIR) "updated_clks.sdc"]
2929
# Reset
3030
create_clock -name $clk_name -period $period $sources
3131
set_propagated_clock [all_clocks]

flow/util/def2stream.py

Lines changed: 8 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -20,43 +20,40 @@
2020
for i in main_layout.each_cell():
2121
print("[INFO] '{0}'".format(i.name))
2222

23-
print("[INFO] Reading DEF ...")
2423
main_layout.read(in_def, layoutOptions)
2524

2625
# Clear cells
2726
top_cell_index = main_layout.cell(design_name).cell_index()
2827

2928
# remove orphan cell BUT preserve cell with VIA_
3029
# - KLayout is prepending VIA_ when reading DEF that instantiates LEF's via
31-
print("[INFO] Clearing cells...")
3230
for i in main_layout.each_cell():
3331
if i.cell_index() != top_cell_index:
3432
if not i.name.startswith("VIA_") and not i.name.endswith("_DEF_FILL"):
3533
i.clear()
3634

3735
# Load in the gds to merge
38-
print("[INFO] Merging GDS/OAS files...")
3936
for fil in in_files.split():
4037
print("\t{0}".format(fil))
4138
main_layout.read(fil)
4239

4340
# Copy the top level only to a new layout
44-
print("[INFO] Copying toplevel cell '{0}'".format(design_name))
4541
top_only_layout = pya.Layout()
4642
top_only_layout.dbu = main_layout.dbu
4743
top = top_only_layout.create_cell(design_name)
4844
top.copy_tree(main_layout.cell(design_name))
4945

50-
print("[INFO] Checking for missing cell from GDS/OAS...")
5146
missing_cell = False
52-
regex = None
53-
if "GDS_ALLOW_EMPTY" in os.environ:
54-
print("[INFO] Found GDS_ALLOW_EMPTY variable.")
55-
regex = os.getenv("GDS_ALLOW_EMPTY")
47+
allow_empty = os.environ.get("GDS_ALLOW_EMPTY", "")
48+
regex = re.compile(allow_empty) if allow_empty else None
49+
50+
if allow_empty:
51+
print(f"[INFO] GDS_ALLOW_EMPTY={allow_empty}")
52+
5653
for i in top_only_layout.each_cell():
5754
if i.is_empty():
5855
missing_cell = True
59-
if regex is not None and re.match(regex, i.name):
56+
if regex is not None and regex.match(i.name):
6057
print(
6158
"[WARNING] LEF Cell '{0}' ignored. Matches GDS_ALLOW_EMPTY.".format(
6259
i.name
@@ -72,7 +69,6 @@
7269
if not missing_cell:
7370
print("[INFO] All LEF cells have matching GDS/OAS cells")
7471

75-
print("[INFO] Checking for orphan cell in the final layout...")
7672
orphan_cell = False
7773
for i in top_only_layout.each_cell():
7874
if i.name != design_name and i.parent_cells() == 0:
@@ -81,14 +77,12 @@
8177
errors += 1
8278

8379
if not orphan_cell:
84-
print("[INFO] No orphan cells")
80+
print("[INFO] No orphan cells in the final layout")
8581

8682

8783
if seal_file:
8884
top_cell = top_only_layout.top_cell()
8985

90-
print("[INFO] Reading seal GDS/OAS file...")
91-
print("\t{0}".format(seal_file))
9286
top_only_layout.read(seal_file)
9387

9488
for cell in top_only_layout.top_cells():
@@ -101,7 +95,6 @@
10195
top.insert(pya.CellInstArray(cell.cell_index(), pya.Trans()))
10296

10397
# Write out the GDS
104-
print("[INFO] Writing out GDS/OAS '{0}'".format(out_file))
10598
top_only_layout.write(out_file)
10699

107100
sys.exit(errors)

0 commit comments

Comments
 (0)