Clock period improvements left on the table due to SYNTH_MINIMUM_KEEP_SIZE counting macros
Maintainer thường phản hồi trong vòng 1 ngày
@joaomai đang làm issue này rồi.
Từ ngày 22/10/2026.
Đánh giá
Issue này chưa được đánh giá.
Mô tả
Description
SYNTH_MINIMUM_KEEP_SIZE decides which modules hierarchical synthesis keeps. The expectation is that it measures the logic yosys works on: since @povik's #2552 the decision is keep_hierarchy -min_cost on yosys's cost estimate of each module, in NAND2 equivalents.
A macro is no work for yosys, but it counts. keep_hierarchy -min_cost needs a cost for every instanced blackbox, and convert_liberty_areas gives each Liberty cell, SRAM macros included, the gate equivalent of its area; since #4650 an AUTO_MEMORIES macro gets its generated view's area the same way. A small wrapper around macros therefore looks like a large module of logic and is kept, and its boundary stays wherever a path runs through it.
Example, asap7/riscv32i (SYNTH_MINIMUM_KEEP_SIZE=10000): the only module kept is dmem, four fakeram7_256x32 instances (1,376 µm² of Liberty area) and 56 µm² of address decode. Its boundary sits on the worst path, between the ALU's address adder and the SRAMs' enable decode, which synthesis then optimises apart. Through global route at 780 ps:
| min reg2reg period | reg2reg endpoints within 10 % of it: faster / slower | |
|---|---|---|
today: dmem kept |
835.6 ps | – |
dmem flattened, which is what the rule decides with macro cost 0 |
791.8 ps | 995 / 3 |
Details and the measurement in #4713 (closed, FYI only).
Suggested Solution
Make the rule measure what it is for: a blackbox macro, Liberty or AUTO_MEMORIES, costs 0 (or 1) gate equivalents towards its parent's size. keep_hierarchy -min_cost still has a cost for every blackbox, so the error that made a cost necessary does not come back.
The designs this can change are those that synthesise hierarchically with a keep threshold and have macros (make print-* on master; the gf12 designs not checked): asap7/coralnpu, asap7/riscv32i; nangate45/ariane133, ariane136, black_parrot, bp_be_top, bp_fe_top, bp_multi_top, bp_quad, mempool_group, tinyRocket. Their keep decisions change only where a macro sits under a module the rule would otherwise flatten, and their QoR may move either way.
Additional Context
variables.yaml describes the threshold as an area in NAND2 units. Stating there which is intended, the logic yosys works on or area including macros, would make the behaviour less surprising either way.
- Ngôn ngữ chính
- Verilog
- Star
- 777
- Fork
- 549
- Merge trung bình
- 2 ngày 10 giờ
- Pull request đã merge (30 ngày)
- 96
Chuẩn bị môi trường
- Có Dockerfile hoặc tệp Docker Compose
- Không có mẫu pull request
- Không có hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của The-OpenROAD-Project/OpenROAD-flow-scripts
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 90/100
The-OpenROAD-Project/OpenROAD-flow-scripts#4717 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Make SYNTH_HDL_FRONTEND=slang defaultCó thể làm lại được @jeffng-or đã nhận 32 ngày trước và không có pull request nào đang mở. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
The-OpenROAD-Project/OpenROAD-flow-scripts#4548 · 1 bình luận · 1 người được giao ·
Maintainer thường phản hồi trong vòng 1 ngày
-
PDN/TAP: rows kept at the edge of a macro halo get followpins PDN can't connect (PDN-0179 on asap7/swerv_wrapper)Có thể đã có người làm @gadfort đã nhận 1 ngày trước. Đang mởpdn
The-OpenROAD-Project/OpenROAD-flow-scripts#4724 · 4 bình luận · 1 người được giao ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Use percent of minimum clock periodCó thể đã có người làm @migueldalberto đã nhận 24 ngày trước. Đang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 55/100
The-OpenROAD-Project/OpenROAD-flow-scripts#4583 · 7 bình luận · 1 người được giao ·
Maintainer thường phản hồi trong vòng 1 ngày
-
asap7 cva6 fails in PSM with demo constraint fileCó thể đã có người làm @gadfort đã nhận 39 ngày trước. Đang mởpsm
The-OpenROAD-Project/OpenROAD-flow-scripts#4539 · 3 bình luận · 1 người được giao ·
Maintainer thường phản hồi trong vòng 1 ngày