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

CSR MSTATUS for RISCV architecture doens't work -> add it to the VirtualStruct #121

Closed
lasseUrban opened this issue Sep 10, 2022 · 1 comment
Assignees

Comments

@lasseUrban
Copy link

lasseUrban commented Sep 10, 2022

In etiss/ArchImpl/RISCV/RISCVArchSpecificImp.h are only the following CSRs added to the VirtualStruct:

addCSR(CSR_MISA);
addCSR(CSR_MIE);
addCSR(CSR_MTVEC);
addCSR(CSR_MEPC);
addCSR(CSR_MCAUSE);
addCSR(CSR_MTVAL);

I use Etiss is the fault injection virtual platform FIVP and added all the missing CSRs myself. All the CSRs work and I can read and write them except the mstatus register CSR768 at address 0x300.

Why is this important register not added to the virtualStruct by default?
Additionally, can you check why it is not working? The register is zero during the complete simulation although it should not. I ensured that my test program sets the mstatus register, but when I read it through the virtualStruct, it is always zero.

@lasseUrban
Copy link
Author

I solved this issue myself in add missing CSRs to RISCV arch spec #122
Nothing to do for you here except merging. Thank you!

@PhilippvK PhilippvK self-assigned this May 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants