Repository navigation
Zacas follow-up: fix amocas.q store and gate Zacas-only logic - #1915
Merged
rosethompson merged 2 commits intoOct 6, 2026
Merged
Conversation
Default synthesis does no boundary optimization, so Zacas control signals that cross module boundaries leave their logic behind even when Zacas is not supported. Gate the amocas select in the AMO ALU, the LSU's use of AMOCASPairM, and the datapath's rs2-port borrow and compare/swap registers with P.ZACAS_SUPPORTED. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Signed-off-by: David Harris <David_Harris@hmc.edu>
w64 treated any funct3 whose low bits were not 11 as narrower than 64 bits, so amocas.q (funct3 100) sign-extended bit 31 across the low doubleword it stores after a successful compare. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Signed-off-by: David Harris <David_Harris@hmc.edu>
rosethompson
approved these changes
Oct 6, 2026
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.
#1880 merged before two changes landed. On RV64,
amoalutreatedamocas.q(funct3 100) as a narrow access and sign-extended bit 31 across the low doubleword it stores, which ImperasDV lockstep caught on the read-back. The second commit gates the Zacas logic that other modules keep without Zacas, since default synthesis does no boundary optimization, as discussed on #1880. With both, all 72 Zacas, ZacasZabha, Zabha, and Zaamo ACT tests pass on rv64gc and rv32gc andamocas.qis lockstep-clean; those tests need the ACT cvwsail.jsonmain-memoryatomic_supportraised toAMOCASQ(rv64gc) orAMOCASD(rv32gc), or Sail traps every amocas.🤖 Generated with Claude Code