Skip to content

ci(dupe): turn duplicate-bodies green -- share gen_w tree helpers, record STEP copies (Closes #9633) - #9970

Merged
gHashTag merged 4 commits into
masterfrom
fix/dupe-bodies-9633
Oct 17, 2026
Merged

gHashTag merged 4 commits into
masterfrom
fix/dupe-bodies-9633

Conversation

@gHashTag

Copy link
Copy Markdown
Owner

Closes #9633. Refs #9631, #8769. Supersedes draft #9636; its two commits are carried here unchanged, with authorship preserved.

Why

duplicate-bodies has been red on every master push since about 2026-10-15, and every open PR inherits it. The gate lists 12 groups that recent specs/port/** ports introduced. They split into two families, and each family gets a different fix.

gen_w family: real dedupe (flat_index, is_ascii, indent, build_level)

STEP1/STEP2 family: recorded on purpose (8 groups)

weight_sign, led_state_next, led_counter_next, debug_state_bits, bit_at, uart_tx_bit_at, build_report_frame and on_comb.

In trinity_block_step{1,2}_top.t27, on_comb is the module's data port: gen-verilog emits assign result = on_comb(...), and the body calls led_pin, led_state_next, debug_state_bits and tx_ready. gen-verilog does not emit a function brought in by use (#8769, open). A shared module would therefore leave both tops' RTL calling functions it never defines, and gen-verilog would still exit 0. #8769 itself names copying as the only workaround. Both specs now say this in their header. The ledger records the copies, and #9631 stays open to share them once #8769 is fixed.

The bless was run with tools/dupe_scan.py --bless on the Railway lab, and the full ledger diff was inspected. The diff is exactly these 8 groups: seven new 2 lines, plus on_comb 3,2 -> 3,2,2. No other line moved.

Checks (Railway lab, release t27c built at this base)

  • python3 tools/dupe_scan.py --self-test: ok, 11 shapes.
  • python3 tools/dupe_scan.py: ok: no new duplicate body, and none of the known groups grew. (722 of 10495 bodies, 217 groups). On master the same command fails with the 12 errors.
  • t27c parse exits 0 for all 11 touched specs.
  • t27c test-report exits 0 with 0 vacuous for every touched spec: gen_w_tree 7/7, each gen_w port 13/13, step1 17/17, step2 19/19.
  • python3 tools/check_duplicate_declarations.py exits 0.

Only .t27 is written by hand; the ledger and expectation are tool or data files. No seal is touched, because none of these specs is sealed.

🤖 Generated with Claude Code

dmitrii-f-t27 and others added 4 commits October 17, 2026 21:44
(cherry picked from commit f9945cbfa7890196c9406dc359f836e6ea13bcdb)
…8769)

on_comb is each top's data port in gen-verilog, and gen-verilog does not
emit a function brought in by use (#8769), so the shared helpers stay in
both tops until that is fixed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
tools/dupe_scan.py --bless on the Railway lab. The diff is exactly the
STEP groups: bit_at, build_report_frame, debug_state_bits,
led_counter_next, led_state_next, uart_tx_bit_at and weight_sign at 2,
on_comb 3,2 -> 3,2,2. Nothing else moved. They stay copied until
gen-verilog emits functions brought in by use (#8769).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-10-17 14:52:57 UTC

Summary

Status Count
Total Open PRs 50
PRs with Failing Checks 50
PRs with All Checks Green 0
READY 0
FAILING 50
PENDING 0
NO CHECKS YET 0

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=e769ef021713 != manifest seal=87e5cbd3ad94.
    The committed NMSE numbers were certified against an older compiler.rs.
    Run scripts/reseal-check.sh locally for the two-step reseal command (advisory; not a merge gate).

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.

duplicate-bodies: share tree helpers across eight gen_w bench ports

2 participants