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

Exception from QEMU side is not ever checked #48

Open
BugraEryilmaz opened this issue Aug 13, 2024 · 5 comments
Open

Exception from QEMU side is not ever checked #48

BugraEryilmaz opened this issue Aug 13, 2024 · 5 comments
Assignees

Comments

@BugraEryilmaz
Copy link
Contributor

Description
The return value of qflex_step is wrong and also not ever used by flexus. The raised variable in the commit function (in CoreImpl.cpp) is always 0.

Steps to Reproduce
Run the timing model with any workload.

Expected Behavior
THe simulation proceeds normally.

Actual Behavior
QEMU cannot inform flexus about any exception it encounters.

Fix
When QEMU experiences an exception or an interrupt, the qflex_step function should return the correct exception code to flexus without further trying to execute any instruction, complying with the flow of flexus. Otherwise, qflex_step should return no exception. The return value should then be used to compare against the exception code calculated by flexus.
Flexus fix commit: 9f80df88, QEMU fix commit: 5a0e88ff.

@BugraEryilmaz BugraEryilmaz self-assigned this Aug 13, 2024
@BugraEryilmaz
Copy link
Contributor Author

93bac2cba361bd430d52029653285814a38e2d62 Should fix the issue

@branylagaffe
Copy link
Collaborator

The commit does not look like it actually process the exception, merely checking that QEMU and Flexus agreed.

@branylagaffe
Copy link
Collaborator

Worth checking RISC-V version

eExceptionType interrupt =

Interrupt may not be handled correctly

@ayanchak1508
Copy link

96acf10e466d632e310830c6b42279123c341247 handles exceptions/interrupts in QEMU the same way its done for RISCV

@branylagaffe
Copy link
Collaborator

Use microbench to test the behaviour and coverage of the proposed modification

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

4 participants