ci: guard the shared-datapath invariant + report area across topologies - #1875
Merged
Conversation
The gate proved bit-exactness and synthesizability but did not guard the core architectural claim -- one shared GftSmul + one shared GftSadd regardless of topology. A change that accidentally parallelized the datapath would instantiate N multipliers (area explosion) yet still pass the sim + synth gates. datapath_check now asserts exactly 1 GftSmul + 1 GftSadd in the emitted RTL for every topology (2-layer, multi-output, deep) -- version-independent (a text check, no toolchain); verified it catches a 2-multiplier violation. The synth phase now prints a per-topology area report (cells/FF/LUT); counts are yosys-version-specific so it is framed as a trend to watch across PRs, not an absolute gate. The numbers make the depth ~ constant-area claim visible (deep [2,4,3,1] ~ 2-layer (2,4,2)). This is the area-regression guard done version-robustly: guard the invariant that prevents blowup (one multiplier), surface raw numbers for human review, rather than a fragile absolute baseline (CI yosys != local yosys). Refs #1764 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Contributor
|
📓 NotebookLM Notebook linked to this PR
This notebook contains session context, decisions, and artifacts for this work. |
Contributor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The gate proved bit-exactness and synthesizability but did not guard the core architectural claim — one shared GftSmul + one shared GftSadd regardless of topology. A change that accidentally parallelized the datapath would instantiate N multipliers (area explosion) yet still pass the sim + synth gates.
datapath_checknow asserts exactly 1 GftSmul + 1 GftSadd in the emitted RTL for every topology (2-layer, multi-output, deep) — version-independent (text check, no toolchain); verified it catches a 2-multiplier violation. The synth phase now prints a per-topology area report (cells/FF/LUT), framed as a trend to watch across PRs (counts are yosys-version-specific), making the 'depth ~ constant area' claim visible (deep [2,4,3,1] ~ 2-layer (2,4,2)). Version-robust area-regression guard: guard the invariant that prevents blowup, surface raw numbers for review. Refs #1764