diff options
author | mga-sc <mark.goncharov@syntacore.com> | 2022-08-08 16:01:47 +0300 |
---|---|---|
committer | Andrew Burgess <aburgess@redhat.com> | 2022-08-10 16:09:37 +0100 |
commit | f8053219836de69ceb8ff0e3e311b0585b1187b3 (patch) | |
tree | ead5bce762c456ce876d9ed31ec0a2791960dfe1 /gdbsupport/errors.h | |
parent | e5f2f7d901ee735224b3a657c193f88c7ad79a07 (diff) | |
download | binutils-f8053219836de69ceb8ff0e3e311b0585b1187b3.zip binutils-f8053219836de69ceb8ff0e3e311b0585b1187b3.tar.gz binutils-f8053219836de69ceb8ff0e3e311b0585b1187b3.tar.bz2 |
gdb/riscv: implement cannot_store_register gdbarch method
The x0 (zero) register is read-only on RISC-V. Implement the
cannot_store_register gdbarch method to tell GDB this.
Without this method GDB will try to write to x0, and relies on the
target to ignore such writes. If you are using a target that
complains (or throws an error) when writing to x0, this change will
prevent this from happening.
The gdb.arch/riscv-reg-aliases.exp test exercises writing to x0, and
will show the errors when using a suitable target.
Diffstat (limited to 'gdbsupport/errors.h')
0 files changed, 0 insertions, 0 deletions