[hardware] 🐛 Raise illegal_insn for reserved VWXUNARY0 encodings - #476
Open
emiliengnr wants to merge 1 commit into
Open
[hardware] 🐛 Raise illegal_insn for reserved VWXUNARY0 encodings#476emiliengnr wants to merge 1 commit into
emiliengnr wants to merge 1 commit into
Conversation
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.
Hello, here is a pull request for a bug I found.
Problem
Ara's VWXUNARY0 decoder tells the three defined sub-ops apart by the rs1 field:
RVV 1.0 §16.1 marks any other rs1 value as reserved. Because the default arm does
nothing, the instruction still runs the rest of the OPMVV header with
ara_req_validasserted and reaches the lanes as a malformed request (opdefaults to
VADD,vfu = VFU_Alu). The lanes accept it but never produce thescalar response, so the cva6 host stalls on the accelerator handshake until reset.
An unprivileged reserved encoding wedges the accelerator.
Fix
Raise
illegal_insnin the default arm, as the spec requires. Valid code isunaffected.
Related to the VWXUNARY0 handling in #467, but a distinct fix (that PR addresses
use_vs1; this one traps the reserved encodings).Changelog
Fixed
Checklist