gdb/riscv: add ability to decode dwarf CSR numbers
authorAndrew Burgess <andrew.burgess@embecosm.com>
Wed, 11 Nov 2020 11:55:08 +0000 (11:55 +0000)
committerAndrew Burgess <andrew.burgess@embecosm.com>
Wed, 11 Nov 2020 11:55:08 +0000 (11:55 +0000)
commit550820e16d0a1f44ee63086b1a2d931e04839ffa
tree8cab9812e2a3868d92c1b5cce445ee0dc8299344
parent81fdd7acec68476bc23dd1ed4b2c6288aebe4343
gdb/riscv: add ability to decode dwarf CSR numbers

Extends riscv_dwarf_reg_to_regnum to add the ability to convert the
DWARF register numbers for CSRs into GDB's internal numbers.

gdb/ChangeLog:

* riscv-tdep.c (riscv_dwarf_reg_to_regnum): Decode DWARF CSR
numbers.
* riscv-tdep.h (RISCV_DWARF_FIRST_CSR, RISCV_DWARF_LAST_CSR): New
enum values.
gdb/ChangeLog
gdb/riscv-tdep.c
gdb/riscv-tdep.h