Skip to content

Commit

Permalink
sweep: cleanup
Browse files Browse the repository at this point in the history
- BoomTile_base is excluded from sweep, it is only used to
generate macro placement
- BoomTile_1_grt is run with default grt arguments instead of
BoomTile_grt
- BoomTile has pathological resource usage when not flattened
regardless of MAX_UNGROUP_SIZE, so non-flattened synthesis
is not interesting to examine in grt.

Signed-off-by: Øyvind Harboe <[email protected]>
  • Loading branch information
oharboe committed Nov 17, 2024
1 parent 5cf5f57 commit c78e448
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 30 deletions.
46 changes: 17 additions & 29 deletions BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -349,11 +349,12 @@ FAST_BUILD_SETTINGS = {
"TAPCELL_TCL": "",
}

SWEEP = {
# This is used as inputs to other BoomTile configurations in the sweep,
# but is not part of the sweep itself
OTHER_CONFIGS = {
"base": {
"description": "Base settings, provides macro placement from hierarchical synthesis",
"variables": {
"GLOBAL_ROUTE_ARGS": "-congestion_iterations 30 -congestion_report_iter_step 5 -verbose",
},
},
"naja": {
Expand All @@ -364,28 +365,18 @@ SWEEP = {
"floorplan": "BoomTile_synth",
},
},
}

SWEEP = {
"1": {
"description": "Flattend, timing driven placement, CTS timing repair enabled",
"variables": {
"SYNTH_HIERARCHICAL": "0",
"GPL_TIMING_DRIVEN": "1",
"SKIP_CTS_REPAIR_TIMING": "0",
"MACRO_PLACEMENT_TCL": "$(location write_macro_placement)",
},
"stage_sources": {"floorplan": ["write_macro_placement"]},
},
"2": {
"description": "Flattend, timing driven placement, CTS timing repair enabled, last gasp timing repair",
"description": "Flattend, timing driven placement",
"variables": {
"SYNTH_HIERARCHICAL": "0",
"GPL_TIMING_DRIVEN": "1",
"SKIP_CTS_REPAIR_TIMING": "0",
"MACRO_PLACEMENT_TCL": "$(location write_macro_placement)",
"SKIP_LAST_GASP": "0",
},
"previous_stage": {
"floorplan": "BoomTile_1_synth",
},
"stage_sources": {"floorplan": ["write_macro_placement"]},
},
}
Expand All @@ -411,7 +402,7 @@ BOOMTILE_VARIABLES = SKIP_REPORT_METRICS | FAST_BUILD_SETTINGS | {
"HOLD_SLACK_MARGIN": "-200",
}

WNS_REPORT_SWEEP = [variant for variant in SWEEP if "naja" not in variant]
WNS_REPORT_SWEEP = [variant for variant in SWEEP]

SWEEP_JSON = {
"base": BOOMTILE_VARIABLES,
Expand Down Expand Up @@ -439,39 +430,36 @@ BOOMTILE_SOURCES = {

boomtile_all_rams = boom_regfile_rams.keys() + all_srams.keys()

ALL_VARIANTS = SWEEP | OTHER_CONFIGS

[orfs_flow(
name = "BoomTile",
arguments = BOOMTILE_VARIABLES | SWEEP[variant].get("variables", {}),
arguments = BOOMTILE_VARIABLES | ALL_VARIANTS[variant].get("variables", {}),
macros = [
":" + m + "_generate_abstract"
for m in boomtile_all_rams
if m not in SWEEP[variant].get("dissolve", [])
if m not in ALL_VARIANTS[variant].get("dissolve", [])
],
previous_stage = SWEEP[variant].get("previous_stage", {}),
renamed_inputs = SWEEP[variant].get("renamed_inputs", {}),
previous_stage = ALL_VARIANTS[variant].get("previous_stage", {}),
renamed_inputs = ALL_VARIANTS[variant].get("renamed_inputs", {}),
# Explictily set arguments for a stage when stages are not listed in
# variables.yaml or we want to explicitly set a multi-stage argument
# for a specific stage, e.g. SETUP_SLACK_MARGIN could be useful to
# have a different value for floorplan, cts and grt.
stage_arguments = {
"grt": {
# global route is futile for now, so do a few iterations to
# get a global route artifact with .odb and .rpt file
"GLOBAL_ROUTE_ARGS": "-congestion_iterations 5 -congestion_report_iter_step 5 -verbose",
},
},
# Starlark does not have sets, nor can we define functions in BUILD files
# Use a dict to get a set of keys
stage_sources = {
key: (SWEEP[variant].get("stage_sources", {}).get(key, []) + BOOMTILE_SOURCES.get(key, []))
key: (ALL_VARIANTS[variant].get("stage_sources", {}).get(key, []) + BOOMTILE_SOURCES.get(key, []))
for key in {
key: "dummy"
for key in (BOOMTILE_SOURCES.keys() + SWEEP[variant].get("stage_sources", {}).keys())
for key in (BOOMTILE_SOURCES.keys() + ALL_VARIANTS[variant].get("stage_sources", {}).keys())
}.keys()
},
variant = variant,
verilog_files = all_source_files,
) for variant in SWEEP]
) for variant in SWEEP | OTHER_CONFIGS]

[filegroup(
name = "BoomTile_" + variant + "_odb",
Expand Down
2 changes: 1 addition & 1 deletion etc/BuildMegaboom.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ exec 2>&1
# Check GCP service account entitlements first
test/cred_helper_test.py

bazel build wns_report BoomTile_grt --keep_going
bazel build wns_report BoomTile_1_grt --keep_going
cat bazel-bin/BoomTile_wns_report.md

0 comments on commit c78e448

Please sign in to comment.