diff options
author | Ulrich Weigand <uweigand@de.ibm.com> | 2013-09-13 14:11:15 +0000 |
---|---|---|
committer | Ulrich Weigand <uweigand@de.ibm.com> | 2013-09-13 14:11:15 +0000 |
commit | 2ccd146855365598ad2644ef8139f2f2a6747b90 (patch) | |
tree | 86b1e6d35f6faaf3ce178fb4c040647d7ba2e6e1 /gdb/s390-tdep.h | |
parent | b3d3b4bda18d970a8983f06975d707fc130a1ae1 (diff) | |
download | gdb-2ccd146855365598ad2644ef8139f2f2a6747b90.zip gdb-2ccd146855365598ad2644ef8139f2f2a6747b90.tar.gz gdb-2ccd146855365598ad2644ef8139f2f2a6747b90.tar.bz2 |
2013-09-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
* s390-tdep.h (S390_IS_GREGSET_REGNUM): New macro.
(S390_IS_FPREGSET_REGNUM): New macro.
* s390-tdep.c (s390_dwarf_regmap): Make const.
(regnum_is_gpr_full): New function for replacing repeated code.
(s390_pseudo_register_name): Use it.
(s390_pseudo_register_type): Likewise.
(s390_pseudo_register_read): Likewise.
(s390_pseudo_register_write): Likewise.
(s390_unwind_pseudo_register): Likewise.
(s390_regmap_gregset): New format for regmap.
(s390x_regmap_gregset): Likewise.
(s390_regmap_fpregset): Likewise.
(s390_regmap_upper): Likewise.
(s390_regmap_last_break): Likewise.
(s390_regmap_system_call): Likewise.
(s390_supply_regset): Adjust to new regmap format.
(s390_collect_regset): Likewise.
* s390-nat.c (s390_native_supply): Adjust to new regmap format.
(s390_native_collect): Likewise.
(supply_gregset): Likewise.
(fill_gregset): Likewise.
(supply_fpregset): Likewise.
(fill_fpregset): Likewise.
(fetch_regset): Likewise.
(store_regset): Likewise.
(s390_linux_fetch_inferior_registers): Likewise.
(s390_linux_fetch_inferior_registers): Likewise.
Diffstat (limited to 'gdb/s390-tdep.h')
-rw-r--r-- | gdb/s390-tdep.h | 20 |
1 files changed, 14 insertions, 6 deletions
diff --git a/gdb/s390-tdep.h b/gdb/s390-tdep.h index b5e59a1..a262b64 100644 --- a/gdb/s390-tdep.h +++ b/gdb/s390-tdep.h @@ -106,16 +106,24 @@ #define S390_RETADDR_REGNUM S390_R14_REGNUM #define S390_FRAME_REGNUM S390_R11_REGNUM +#define S390_IS_GREGSET_REGNUM(i) \ + (((i) >= S390_PSWM_REGNUM && (i) <= S390_A15_REGNUM) \ + || ((i) >= S390_R0_UPPER_REGNUM && (i) <= S390_R15_UPPER_REGNUM) \ + || (i) == S390_ORIG_R2_REGNUM) + +#define S390_IS_FPREGSET_REGNUM(i) \ + ((i) >= S390_FPC_REGNUM && (i) <= S390_F15_REGNUM) + /* Core file register sets, defined in s390-tdep.c. */ #define s390_sizeof_gregset 0x90 -extern int s390_regmap_gregset[S390_NUM_REGS]; +extern const short s390_regmap_gregset[]; #define s390x_sizeof_gregset 0xd8 -extern int s390x_regmap_gregset[S390_NUM_REGS]; +extern const short s390x_regmap_gregset[]; #define s390_sizeof_fpregset 0x88 -extern int s390_regmap_fpregset[S390_NUM_REGS]; -extern int s390_regmap_last_break[S390_NUM_REGS]; -extern int s390x_regmap_last_break[S390_NUM_REGS]; -extern int s390_regmap_system_call[S390_NUM_REGS]; +extern const short s390_regmap_fpregset[]; +extern const short s390_regmap_last_break[]; +extern const short s390x_regmap_last_break[]; +extern const short s390_regmap_system_call[]; /* GNU/Linux target descriptions. */ extern struct target_desc *tdesc_s390_linux32; |