Repository navigation
Conversation
The macro placer snaps a macro's pins to the routing tracks only, so the standard cells inside a hardened block land off the 27 nm fin and 54 nm gate grids of the rows around it. snap_macros_to_fin_grid.tcl, run as POST_MACRO_PLACE_TCL, moves each placed macro to the nearest origin that puts its cells on those grids and keeps its pins on the tracks of every layer they use, mirrored placements included. On aes-block, which now uses it, the 21 macros move by at most 0.192 um, each a whole number of tracks, and the DRM's FIN.S.1/GATE.S.1 markers go from 11940 to 0 (gdscheck asap7). Detailed routing has no DRC errors and VDD/VSS stay connected. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: jeffhsu3 <jeffhsu3@gmail.com>
There was a problem hiding this comment.
Code Review
This pull request introduces a new Tcl script, snap_macros_to_fin_grid.tcl, and integrates it into the ASAP7 AES block configuration to ensure that hardened macros are snapped to the fin and gate grids, as well as routing tracks. The review feedback suggests two key improvements: first, handling the fallback snapping logic for the X and Y axes independently so that one axis can still align to routing tracks even if the other fails; second, optimizing the asap7_snap_axis procedure by pre-calculating target offsets and halving the search range based on constraint periodicity.
Fall back to the gate or fin grid only on the axis with incompatible track constraints. Preserve a valid solution on the other axis and identify the failing axis in the warning. Precompute constraint residues and limit the nearest-origin search to half the repeating grid period. Validation: 5,008 Tcl axis cases match an independent exhaustive solver; nine mocked-database scenarios cover all supported orientations and fallback combinations, including four regressions that fail before this change. tclint 0.7.0, tclfmt, and git diff --check pass. The full physical-design flow was not rerun. Signed-off-by: jeffhsu3 <jeffhsu3@gmail.com>
🔍 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. |
|
This might be something that goes into OR rather than ORFS because I don't think OR should allow placing instances off the fin grid. |
|
Thanks @rovinski, agreed. I moved this into OpenROAD: The-OpenROAD-Project/OpenROAD#11760 makes the macro snapper keep macros on the core rows' site grid, which on ASAP7 means the fin and gate grids, while still aligning their pins with the tracks. On aes-block with no ORFS-side script, FIN.S.1/GATE.S.1 go from 11,940 to 0 and detailed routing stays clean. Closing this in favor of that PR. |
Snapping hardened macro pins to routing tracks can leave the standard cells inside those macros off ASAP7's 27 nm fin and 54 nm gate grids. On
aes-block, this produces FIN.S.1/GATE.S.1 violations at the top level.Add
snap_macros_to_fin_grid.tclas an opt-inPOST_MACRO_PLACE_TCLhelper and enable it foraes-block. The helper moves each placed macro to the nearest origin that satisfies the fin/gate grids and the routing-track constraints of its pin layers, accounting forR0,MX,MY, andR180orientations and preserving its placement status.If the grid constraints are incompatible, the helper warns and falls back to fin/gate alignment. It also warns about unsupported orientations, macros moved outside the core, and overlaps after snapping.
Validation recorded in commit
e8f97ee0foraes-block(the full flow was not rerun when preparing this draft):gdscheck asap7FIN.S.1/GATE.S.1 markers decrease from 11,940 to 0.Draft preparation also passed
git diff --checkfor the functional change.