-
Notifications
You must be signed in to change notification settings - Fork 361
target/riscv/riscv.c: support auto-selection of software breakpoint size #1273
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
target/riscv/riscv.c: support auto-selection of software breakpoint size #1273
Conversation
427b9ee
to
3cf367c
Compare
Add auto-selection of breakpoint size for RISC-V targets. The new length depends on C extension. If the C extension is used, the auto-selected length is 2 bytes. Otherwise, the default length is 4 bytes. Change-Id: Ie3473514beace15b76714aa6d5441122cd3262aa Signed-off-by: Kulyatskaya Alexandra <[email protected]>
3cf367c
to
e307df1
Compare
@AlexandraKulyatskaya, I'd suggest avoiding modifying the length of the breakpoint. Consider instead introducing a new Please, note that in general |
I don't think this will work anyway as support of c.ebreak isn't guaranteed when "C" extension is supported #908 (comment) |
Hi @MarekVCodasip - I think that my comment that you linked to may have been based on incomplete or inaccurate information at the time (similar to previous comments linked from there etc.). If you look at the latest ratified RISC-V Instruction Set Manual Volume I: Unprivileged ISA then page 171 of chapter 27 has this as part of the ![]() So it seems that ![]() |
Thanks for the info, I just remember that this was an issue back then as I tried to implement code to reject software breakpoints of size |
I think that some of the confusion may have arisen from the |
Reopened as #1288 |
Add auto-selection of breakpoint size for RISC-V targets. The new length depends on C extension. If the C extension is used, the auto-selected length is 2 bytes. Otherwise, the default length is 4 bytes.
Change-Id: Ie3473514beace15b76714aa6d5441122cd3262aa