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

mtvec_handler aligment #495

Open
MarekPesta opened this issue Jul 19, 2023 · 0 comments
Open

mtvec_handler aligment #495

MarekPesta opened this issue Jul 19, 2023 · 0 comments

Comments

@MarekPesta
Copy link

In riscv_test.h there is a weak mtvec_handler declaration aligned to 6.
https://github.com/riscv/riscv-test-env/blob/4fabfb4e0d3eacc1dc791da70e342e4b68ea7e46/p/riscv_test.h#L170

However, in illegal.S test, mtvec_handler is aligned to 8. Shouldn't this be consistent?

This difference in .align values determines that for the illegal.S test the _start symbol has a value of .align 8, while for tests that do not implement mtvec_handler the same symbol has a value of .align 6. This can lead to problems in simpler systems with a fixed starting point value.

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

1 participant