fix(riscv): decode segment fault-only-first loads (vlseg*nf*e*ff) - #293
Closed
carlosqwqqwq wants to merge 1 commit into
Closed
fix(riscv): decode segment fault-only-first loads (vlseg*nf*e*ff)#293carlosqwqqwq wants to merge 1 commit into
carlosqwqqwq wants to merge 1 commit into
Conversation
Member
|
Thanks for the report and patch. I independently validated the segment fault-only-first encodings and implemented the complete behavior in #296: first-element faults remain precise, later faults trim |
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.
Allow segment fault-only-first loads
vlseg<nf>e<eew>ffto decode.decode_load_fpcurrently accepts lumop0b10000only whennf == 0(single-register
vle<eew>ff) and rejects everynf != 0segment form asillegal, although the V extension defines them as legal instructions
(riscv-v-spec vector-common.adoc norm:vector_ls__seg_ff_unit-stride_op).
QEMU executes the canonical encoding (
vlseg2e8ff.v v0, (a0)=0x23050007)normally; RAX reports
Op::Illegalin both the unit decoder and therax-isa-oracleCLI.Validation
riscv64-linux-gnu-as -march=rv64gcvemits0x23050007for
vlseg2e8ff.v v0, (a0), confirming the encoding is legal.-cpu maxruns the witness ELF to completion (exit 0); a control ELFwith
0xffffffffdies with SIGILL (132).decode(0x23050007, Xlen::Rv64, &Isa::rv64gc())returnsOp::Illegalbefore the fix, and the decode arm is reachable after thefix with the same
Opused by the non-fault-only-first segment loads.nf=1..3with e8/e16/e32/e64 and bothunit-stride and strided forms.
Closes #288