Repository navigation
Conversation
A generated macro's power pins are horizontal M4 rails; the platform's macro grid connects them to the core's vertical M5 straps, one per net every 5.4 um (grid_strategy-M1-M2-M5-M6.tcl). The asap7 backend sized a macro from its bit cells, with a floor on height and none on width, so a narrow memory could come out narrower than the strap pitch. Such a macro can land between two straps of a net: its macro grid gets no shapes and pdngen fails the whole design (PDN-0233). The process gets a min_width_um floor beside the existing height floor, and the asap7 backend sets it to one pitch plus one strap plus the rails' inset at both edges, 5.616 um: a strap of each net then crosses the rails wherever the macro is placed. Wider macros are unchanged. A unit test covers both cases. The change is to patches/fakeram/0001-Add-ORFS-ASAP7-backend.patch, where the backend lives; the patch is regenerated against the vendored tools/FakeRAM2.0, so its offsets are exact. Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
There was a problem hiding this comment.
Code Review
This pull request introduces a minimum width constraint (min_width_um) for the ORFS ASAP7 backend to prevent pdngen failures on narrow macros. It updates the Process class to parse and enforce this minimum width constraint and adds a corresponding unit test. Feedback is provided regarding a potential TypeError if min_width_um is explicitly set to null in the JSON configuration, suggesting a safer fallback using json_data.get("min_width_um") or 0.0.
🔍 QoR checkMetrics reflect the PR merge build — i.e. what will land on the target branch. Commit 62 design(s) checked — 0 with regression(s), 0 without a comparable baseline. |
|
You didn't upstream the last patch. I'm not going to continue this with diffs to your patches. |
Ooops... a working accident there, I'll file the cleanup PRs. |
What
The FakeRAM asap7 backend that
AUTO_MEMORIESuses sized a macro from its bit cells. It had a minimum height but no minimum width, so a narrow memory could come out narrower than the platform's power-strap pitch:flow/platforms/asap7/openRoad/pdn/grid_strategy-M1-M2-M5-M6.tcl).This change adds
min_width_um, a width floor next to the existing height floor. The asap7 backend sets it to one strap pitch, plus one strap, plus the rails' 0.048 µm inset at both edges: 5.616 µm. A strap of each net then crosses the rails wherever the macro is placed. Wider macros are unchanged.Where
The asap7 backend lives in
patches/fakeram/0001-Add-ORFS-ASAP7-backend.patch, so the change is to that file. The patch is regenerated against the vendoredtools/FakeRAM2.0, so its offsets are now exact (therun.pyhunks moved by two lines). The unit test is inside the patch too, because the vendoredclass_process.pyonly gets the floor from it.Testing
test/macro_dim_test.py::test_macro_dim_min_width): a 5.054 µm macro is widened to the floor, and a 20.2 µm one is left alone. With the patch applied to the vendored tree,macro_dim_test.pyandprocess_test.pypass, 10 of 10.asap7/tage_update(asap7/tage_update: gather, decide, scatter across distributed SRAMs #4595) has 4, 32 and 128 such macros across its three variants. Every variant failed PDN-0233 at floorplan without the fix. With it, all three run through final. This was tested in bazel-orfs, which applies this backend patch to the vendored FakeRAM.Nothing in ORFS's own make flow applies
patches/fakeram/0001today, soAUTO_MEMORIESin the make flow does not reach this backend yet. Hooking it up is a separate change, and this PR does not depend on it.🤖 Generated with Claude Code