Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛⚠️ CPU bug-fixes, major cleanups and optimizations #586

Merged
merged 10 commits into from
Apr 16, 2023
Merged

Conversation

stnolting
Copy link
Owner

@stnolting stnolting commented Apr 15, 2023

🐛 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#1011

⚠️ rework mtval CSR: do not put program counter value on instruction misaligned / instruction access fault exceptions into this CSR (redundant; already available in mepc); 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 instruction mtval 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 🙈)

@stnolting stnolting added bug Something isn't working risc-v compliance Modification to comply with official RISC-V specs. HW hardware-related optimization Make things faster, smaller and more efficient coding-style Related to the HW/SW coding style labels Apr 15, 2023
@stnolting stnolting self-assigned this Apr 15, 2023
@stnolting stnolting added the SW software-related label Apr 15, 2023
@stnolting stnolting mentioned this pull request Apr 15, 2023
@stnolting stnolting marked this pull request as ready for review April 15, 2023 18:20
@stnolting stnolting changed the title 🐛 CPU bug-fixes, cleanups and optimizations 🐛⚠️ CPU bug-fixes, cleanups and optimizations Apr 15, 2023
@stnolting stnolting marked this pull request as draft April 15, 2023 21:12
@stnolting stnolting changed the title 🐛⚠️ CPU bug-fixes, cleanups and optimizations 🐛⚠️ CPU bug-fixes, major cleanups and optimizations Apr 15, 2023
@stnolting stnolting marked this pull request as ready for review April 16, 2023 09:57
@stnolting stnolting merged commit 4b2a724 into main Apr 16, 2023
@stnolting stnolting deleted the dev150423 branch April 16, 2023 16:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working coding-style Related to the HW/SW coding style HW hardware-related optimization Make things faster, smaller and more efficient risc-v compliance Modification to comply with official RISC-V specs. SW software-related
Projects
None yet
Development

Successfully merging this pull request may close these issues.

🐛 Potential rtl error in xirq 🐛 WFI instruction with global interrupts disabled
1 participant