[Fix] Decoder uses vtype.vill to decide if instruction is legal - #122
Open
ilmessere wants to merge 1 commit into
Open
[Fix] Decoder uses vtype.vill to decide if instruction is legal#122ilmessere wants to merge 1 commit into
ilmessere wants to merge 1 commit into
Conversation
This change will make decoder_rsp_o.instr_illegal=1 for instructions that depend on vtype when vtype_q.vill=1 According to the spec, if vill is set, any vector instructions that depends on vtype, must be considered an illegal instructions. (See RISCV unpriv. 30.1.3.4.4. Vector Type Illegal (vill)) In these cases the decoder_rsp_o.instr_illegal remained '0. This causes spatz_req_valid to be set and the request to be sent to the execution units. This means that an illegal instruction may generate a valid request that could result in memory requests or updates of the register file.
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.
According to the spec, if vill is set, any vector instructions that depends on vtype, must be considered an illegal instructions.
See RISCV unpriv. 30.1.3.4.4. Vector Type Illegal (vill)
In these cases the
decoder_rsp_o.instr_illegalremained'0.This made the
spatz_controllersetspatz_req_valid, and made it send the request the execution units.This means that an illegal instruction could generate a valid spatz request, that could result in memory accesses or updates of the register file.
This change will make
decoder_rsp_o.instr_illegal=1for instructions that depend on vtype whenvtype_q.vill=1.