-
Notifications
You must be signed in to change notification settings - Fork 233
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
ISS mismatch on exception trigger debug entry #1516
Comments
@silabs-oysteink It looks like this is no longer being used, so please let me know how to pass options to the reference model in the imperas control (.ic) file |
I tried running the basic debug_test, and this fails on a csr read of TINFO
This would imply that the TINFO is powering up in an illegal state, as this should be readonly |
@silabs-mateilga do you know how to pass these options to the ISS? |
@eroom1966 Are you using the RTL hash specified in the issue description? The value of the tinfo CSR was updated to reflect the new trigger types in that commit. |
Also, I note that the following registers are still ignored
When I enable these, I get immediate errors
https://docs.openhwgroup.org/projects/cv32e40x-user-manual/en/0.6.0/control_status_registers.html#debug-control-and-status-dcsr https://docs.openhwgroup.org/projects/cv32e40x-user-manual/en/0.6.0/control_status_registers.html#trigger-info-tinfo |
I missed that, I had presumed it was in the ExternalRepos.mk trying again |
Yes, there are some features from UM 0.6.0 that are not yet implemented in RTL. Therefore, the DCSR checks should be disabled until we get the mprven properly tied to 1. Tdata1 and tinfo should be ok to include though. |
Hi Oystein, I will upload a copy of the modified ImperasDV for you to evaluate. |
Perfect! It is likely due to the test itself that it reports failed, as I just quickly made a smaller test than debug_test_trigger to expose the mismatch. |
@silabs-oysteink sent you an email |
any update on this issue ? |
Hi @eroom1966 I have now used the ISS version with the fix and the test now runs to completion without errors. I will close this issue. Thanks for the fix! |
ISS mismatch on exception trigger debug entry
Type
Indicate whether the type of problem you found:
Steps to Reproduce
After running, the following ISS mismatch can be seen:

The cv32e40x goes to debug and executes the first debug handler instruction when an exception is encountered (PC = 0x1a110800 is the start of the debug code) while the ISS executes the first exception handler instruction (PC = 0x0 aligns with mtvec).
According to the debug spec V1.0.0, the debug entry should happen just before the first instruction of the trap handler is executed, but after all CSR updates for the exception.
From the test is seems like the ISS is first executing the first exception handler instruction before it enters debug mode.
The text was updated successfully, but these errors were encountered: