]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit - gdb/s390-linux-nat.c
S390: Add guarded-storage register support to GDB
authorAndreas Arnez <arnez@linux.vnet.ibm.com>
Mon, 25 Sep 2017 14:02:23 +0000 (16:02 +0200)
committerAndreas Arnez <arnez@linux.vnet.ibm.com>
Mon, 25 Sep 2017 14:02:23 +0000 (16:02 +0200)
commit1b63490c9173f8c9770b7885def720516aa9b9f8
treebc2ed565982d5036e04aeeac744c9ff83d5c04e8
parent96235dc1ac3730c4e490d19db2e8287c0a40f307
S390: Add guarded-storage register support to GDB

Recognize targets with the new guarded-storage feature and then present
the guarded-storage registers and the Linux-specific guarded-storage
broadcast control block appropriately.

gdb/ChangeLog:

* s390-linux-nat.c (have_regset_gs): New static variable.
(s390_linux_fetch_inferior_registers): Handle guarded-storage
control block and guarded-storage broadcast control regsets.
(s390_read_description): Detect whether the target has
guarded-storage support, return appropriate tdesc.
* s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
(features/s390x-gs-linux64.c): Likewise.
(struct gdbarch_tdep) <have_gs>: New field.
(s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
(s390_gsbc_regset): New variables.
(s390_iterate_over_regset_sections): Iterate over s390_gs_regset
and s390_gsbc_regset, if applicable.
(s390_core_read_description): Check whether core file was from a
target with guarded-storage support; include appropriate regsets.
(s390_gdbarch_init): Add registers for guarded-storage support.
(_initialize_s390_tdep): Initialize new target descriptions that
include registers for guarded-storage support.
* s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
(S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
(S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
(S390_NUM_REGS): Adjust macro definition.
(s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
(tdesc_s390x_gs_linux64): New declarations.
gdb/ChangeLog
gdb/s390-linux-nat.c
gdb/s390-linux-tdep.c
gdb/s390-linux-tdep.h