Skip to content

snitch_cluster: rename SRAM macros to platform-neutral fakeram_* prefix - #248

Merged
mguthaus merged 2 commits into
mainfrom
snitch-fakeram-rename
Oct 20, 2026
Merged

mguthaus merged 2 commits into
mainfrom
snitch-fakeram-rename

Conversation

@mguthaus

@mguthaus mguthaus commented Oct 20, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Renames snitch_cluster's SRAM macros from the asap7-style fakeram7_* to the platform-neutral fakeram_* prefix, suite-wide (shared tc_sram.sv mapping + cfgs + regenerated LEF/LIB on asap7 and nangate45). Prompted by gt2n: port snitch_cluster #240, where the gt2n port inherited the misleading 7.
  • Same cleanup for ternip (all three platforms): fakeram7_512x16 → fakeram_512x16, and the shared memory wrapper moves to its platform-neutral home designs/src/ternip/ternip_pipelined_mem_fakeram.v (nangate45/sky130hd were referencing it under designs/asap7/).
  • Normalizes snitch-asap7 to the standard macro layout: cfg at dev/generated/fakeram_asap7.cfg, committed LEF/LIB at designs/asap7/snitch_cluster/sram/{lef,lib}/, local filegroups like the other platforms; the tracked dev/generated/sram/ tree is removed and tools/regenerate_sram.sh now works for both designs on every platform.
  • Fixes the snitch + ternip asap7 cfgs' snake_case snap-grid keys (snap_width_nm → snapWidth_nm, the known silently-ignored-snap bsg_fakeram bug): macros now land exactly on the 0.190/1.400 µm site grid.

Verification

  • snitch nangate45 LEF/LIB: byte-identical except the names. ternip nangate45/sky130hd: identical sizes/pins; internal PG-strap offsets shift ~1.1 µm because the committed LEFs predated the current bsg_fakeram pin (2db2c32).
  • asap7 macros regenerated on-grid; size deltas negligible (<0.5 % per side).
  • All wd_in pins DIRECTION INPUT (post-c83ecb4 generator); only rd_out is OUTPUT.
  • bazel build --nobuild analysis passes for all five _synth targets; no fakeram7 references remain under designs/.

Fallout

  • Macro names are bazel inputs, so snitch (asap7/nangate45) and ternip (all three) cached results invalidate and rebuild — accepted cost. snitch re-validation k8s jobs are running on this branch; ternip rebuilds go on k8s after merge.
  • gt2n: port snitch_cluster #240 (gt2n port) regenerates its macros with the new names once this lands; the gt2n cfg rename is mechanical.

The shared tc_sram.sv mapping hardcoded asap7-style fakeram7_* macro
names on every platform (nangate45 shipped fakeram7_* LEFs, and the gt2n
port in PR #240 inherited the misleading '7'). Rename suite-wide to the
platform-neutral fakeram_* prefix used by the other gt2n designs.

- tc_sram.sv + fakeram cfgs: fakeram7_* -> fakeram_*
- asap7 normalized to the standard macro layout: cfg at
  dev/generated/fakeram_asap7.cfg, committed LEF/LIB at
  designs/asap7/snitch_cluster/sram/{lef,lib}/ (replaces the tracked
  dev/generated/sram/ tree and the src-level sram_lefs/sram_libs
  filegroups); tools/regenerate_sram.sh now works for both platforms
- asap7 cfg snap keys fixed snake_case -> camelCase (the known
  silently-ignored-snap bug): macros now land exactly on the
  0.190/1.400 um site grid, size deltas +0.06-0.5% per side
- nangate45 LEF/LIB regenerated: byte-identical except the names

Both platforms' cached results invalidate; rebuild required
(nangate45 ~14 h). gt2n (PR #240) regenerates with the new names.
Same cleanup as the snitch_cluster rename: the fakeram7_* prefix was
asap7 naming carried onto nangate45/sky130hd.

- Shared memory wrapper moved to its platform-neutral home:
  designs/asap7/ternip/ternip_pipelined_mem_fakeram7.v ->
  designs/src/ternip/ternip_pipelined_mem_fakeram.v (nangate45/sky130hd
  were already referencing it cross-platform)
- All three cfgs + LEF/LIB renamed and regenerated
- asap7 cfg snap keys fixed snake_case -> camelCase (the known
  silently-ignored-snap bug): macro now on the 0.190/1.400 um site grid
  (34.560x43.200 -> 34.580x43.400)
- nangate45/sky130hd sizes identical; internal PG-strap offsets shift
  ~1.1 um because the committed LEFs predated the current bsg_fakeram
  pin (2db2c32) -- pins and size unchanged

All three platforms' cached ternip results invalidate and rebuild.
@mguthaus
mguthaus merged commit c26059a into main Oct 20, 2026
1 check passed
dhgaddy added a commit to dhgaddy/HighTide that referenced this pull request Oct 21, 2026
Follow-through on VLSIDA#248, which renamed the shared tc_sram.sv mapping and
the asap7/nangate45 macros from fakeram7_* to the platform-neutral
fakeram_* prefix.

Rename the 4 macros in fakeram_gt2n.cfg and regenerate the gt2n LEF/LIB
with tools/regenerate_sram.sh snitch_cluster gt2n. Name changes only,
identical otherwise.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant