Repository navigation
AUTO_MEMORIES: the generated macros reach the GDS merge - #4660
Conversation
The GDS merge reads the final DEF through a KLayout technology built from the tech, standard-cell and ADDITIONAL_LEFS LEFs. The LEFs AUTO_MEMORIES generates were not among them, so the merge stopped at the first generated macro: Macro not found in LEF file: mbtb_entry_sram And a generated macro has no GDS, while a platform's GDS_ALLOW_EMPTY pattern (asap7: fakeram.*) only matches the platform's own memories, so with the LEF found, every generated macro would have been reported as an empty cell. With AUTO_MEMORIES=1, klayout.lyt now takes the generated LEFs, the ones load.tcl reads, and is rebuilt when they change; def2stream.py allows the modules listed in memories/blackboxes.txt to be empty, taking the first column of each line. Found with asap7/tage_update (The-OpenROAD-Project#4595), which now writes 6_final.gds. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
There was a problem hiding this comment.
Code Review
This pull request integrates automatically generated memories into the KLayout layout merging process by allowing specified cells to be empty without triggering errors. It updates the Makefile to include the generated LEFs as dependencies and introduces a helper function 'auto_memories_cells' to parse these cell names from 'blackboxes.txt'. The review feedback recommends handling missing environment variables or files gracefully in 'auto_memories_cells' to prevent potential crashes, along with updating the corresponding unit tests.
Review asked for a missing RESULTS_DIR or blackboxes.txt to mean no generated macros. It does not: do-auto-memories always writes the list, empty when nothing was converted, so a missing one is a broken flow, and passing over it would turn into "has no matching GDS/OAS cell" errors for the generated macros further on. It stays a stop, now with a message naming what is missing instead of a KeyError or FileNotFoundError; under klayout -r the merge exits 1 with it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.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. |
The GDS merge reads the final DEF through a KLayout technology built from the tech, standard-cell and
ADDITIONAL_LEFSLEFs. The LEFs AUTO_MEMORIES generates were not among them, so the merge stopped at the first generated macro:A generated macro also has no GDS, and a platform's
GDS_ALLOW_EMPTYpattern (asap7:fakeram.*) only matches the platform's own memories, so with the LEF found every generated macro would have been reported as an empty cell.With
AUTO_MEMORIES=1,klayout.lytnow takes the generated LEFs, the onesload.tclreads, and is rebuilt when they change;def2stream.pyallows the modules listed inmemories/blackboxes.txtto be empty, taking the first column of each line. Found with asap7/tage_update (#4595), which now writes6_final.gds.🤖 Generated with Claude Code