read target register to decide breakpoint size
Yao Qi
qiyaoltc@gmail.com
Wed Dec 14 09:18:00 GMT 2016
On 16-12-13 13:30:02, Tim Newsome wrote:
> Actually, this seems to work inside breakpoint_kind_from_pc():
> ```
> struct frame_info *frame = get_current_frame ();
> uint32_t misa = get_frame_register_unsigned (frame, RISCV_CSR_MISA_REGNUM);
> ```
>
> Is that kosher? If so, is there any reason for me to implement
> breakpoint_kind_from_current_state?
I'd like not to do so. Can't you decode the instruction to see whether
it is compressed or uncompressed? I also think it is a good idea to
make a decision based on ELF info, as you mentioned in the first email.
--
Yao (é½å°§)
More information about the Gdb
mailing list