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

⚠️ Constrain/optimize MTVAL and MCOUNTEREN CSRs #671

Merged
merged 6 commits into from
Aug 14, 2023
Merged

Conversation

stnolting
Copy link
Owner

@stnolting stnolting commented Aug 13, 2023

  • ⚠️ mtval: The hardware sets mtval to all-zero if a BREAKPOINT exception is encountered. This is explicitly permitted by the RISC-V priv. spec. and removes some redundancy (and logic): mepc already points to the trap-causing instruction.
  • ⚠️ mcounteren: The CSRs is now implemented as a single flip-flop. Hence, user-mode access can only be granted for all counter CSRs or denied for all counter CSRs.

@stnolting stnolting added HW hardware-related optimization Make things faster, smaller and more efficient labels Aug 13, 2023
@stnolting stnolting self-assigned this Aug 13, 2023
@stnolting stnolting marked this pull request as ready for review August 14, 2023 14:39
@stnolting stnolting merged commit 8a633f7 into main Aug 14, 2023
8 checks passed
@stnolting stnolting deleted the csr_optimization branch August 14, 2023 15:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
HW hardware-related optimization Make things faster, smaller and more efficient
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant