🐛⚠️ CPU bug-fixes, major cleanups and optimizations #586
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.
🐛 fix bug in behavior of
wfi
instruction: CPU has to wake up from sleep mode if any enabled interrupt source becomes pending; #583, thx @biosbob!🐛 fix bug in XIRQ controller that was introduced with the latest update (rtl typo error); #584, thx @matty0005!
🚀 RISC-V compatibility: add all PMP registers that are defined by the RISC-V spec; i.e. access to
pmpaddr63
must not trap and just return zero if that specific PMP region is not implemented; riscv/riscv-isa-manual#1011mtval
CSR: do not put program counter value on instruction misaligned / instruction access fault exceptions into this CSR (redundant; already available inmepc
);mtval
will now also show the faulting instruction word on an illegal instruction exception to simplify emulation - if the illegal instruction trap is caused by a compressed instructionmtval
will show the according zero-extended compressed instruction word; furthermore,mtval
is now read-only (again)✨ massive RTL code cleanup and (area) optimization of CPU control unit
✨ minor RTE edits; default debug handlers now show additional trap information
(Sorry for putting all this into a single commit/pr 🙈)