ci: RTL testbenches and zero-multiplier check in CI (M4 Task 7 step 2) - #21
Conversation
📝 WalkthroughWalkthroughThe CI test job now installs Verilator and Yosys. It runs linting, RTL tests, and synthesis checks after the existing Python test suite. ChangesCI validation
Estimated code review effort: 2 (Simple) | ~10 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In @.github/workflows/ci.yml:
- Line 15: Update the Makefile:synth_check recipe invoked by the CI run to
ensure Yosys failures propagate through its tee pipeline, either by enabling
pipefail for the recipe shell or by removing the pipeline; keep synth_check
failing whenever Yosys fails.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro Plus
Run ID: ab563f6c-b898-48ca-9456-d60de3ce9c08
📒 Files selected for processing (1)
.github/workflows/ci.yml
| - run: .venv/bin/pip install torch --index-url https://download.pytorch.org/whl/cpu --quiet | ||
| - run: make test | ||
| - run: make lint rtl_test | ||
| - run: make synth_check |
There was a problem hiding this comment.
🎯 Functional Correctness | 🟠 Major | ⚡ Quick win
Make synth_check propagate Yosys failures.
Line 15 relies on Makefile:synth_check, which runs Yosys through tee without enabling pipefail. In shells without pipefail, the pipeline status is the last command’s status, so a successful tee can hide a failed Yosys process. (pubs.opengroup.org)
Update synth_check to use a shell with pipefail, or avoid the pipeline, before relying on this step as a synthesis gate.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In @.github/workflows/ci.yml at line 15, Update the Makefile:synth_check recipe
invoked by the CI run to ensure Yosys failures propagate through its tee
pipeline, either by enabling pipefail for the recipe shell or by removing the
pipeline; keep synth_check failing whenever Yosys fails.
Per docs/plans/2026-08-07-phase4-m4-rtl.md Task 7 step 2: CI now installs verilator+yosys and runs make lint rtl_test synth_check after the existing make test. rtl_test includes the export64 case (needs the cpu torch already installed for pytest); nothing depends on data/v1. Expect the job to lengthen by roughly the synth_xilinx runtime. Merging only after this PR's own workflow run is green.
Summary by CodeRabbit