diff options
author | Walfred Tedeschi <walfred.tedeschi@intel.com> | 2013-11-20 13:02:37 +0100 |
---|---|---|
committer | Walfred Tedeschi <walfred.tedeschi@intel.com> | 2013-11-20 14:42:51 +0100 |
commit | e43e105e0d3a6cf324b19adc10d4952b553f43ee (patch) | |
tree | 0ab371baffaaf9fe978b4b032b55a1e9b8989518 /gdb/amd64-tdep.c | |
parent | 1dbcd68cf12168c359df2da36b5b612100310a30 (diff) | |
download | fsf-binutils-gdb-e43e105e0d3a6cf324b19adc10d4952b553f43ee.zip fsf-binutils-gdb-e43e105e0d3a6cf324b19adc10d4952b553f43ee.tar.gz fsf-binutils-gdb-e43e105e0d3a6cf324b19adc10d4952b553f43ee.tar.bz2 |
MPX for amd64
2013-06-24 Walfred Tedeschi <walfred.tedeschi@intel.com>
* amd64-linux-nat.c (amd64_linux_gregset32_reg_offset):
Add MPX registers.
(amd64_linux_read_description): Add initialization for MPX and
AVX independently.
* amd64-linux-tdep.c: Includes features/i386/amd64-mpx-linux.c.
(amd64_linux_gregset_reg_offset): Add MPX registers.
(amd64_linux_core_read_description): Add initialization for MPX
registers.
(_initialize_amd64_linux_tdep): Initialize MPX targets.
* amd64-linux-tdep.h (AMD64_LINUX_RAX_REGNUM): Set it to the last
register on the list.
(tdesc_amd64_mpx_linux) Add new target for MPX.
* amd64-tdep.c: Includes features/i386/amd64-mpx.c.
(amd64_mpx_names): MPX register names.
(amd64_init_abi): Add MPX register while initializing the ABI.
(_initialize_amd64_tdep): Initialize MPX targets.
* amd64-tdep.h (amd64_regnum): Add MPX registers.
(AMD64_NUM_REGS): Set number of registers taking MPX into account.
Change-Id: I4a785c181e2fb45e4086650b2f87426caeb2f800
Signed-off-by: Walfred Tedeschi <walfred.tedeschi@intel.com>
Conflicts:
gdb/ChangeLog
Diffstat (limited to 'gdb/amd64-tdep.c')
-rw-r--r-- | gdb/amd64-tdep.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/gdb/amd64-tdep.c b/gdb/amd64-tdep.c index 4d6b325..1bb72ca 100644 --- a/gdb/amd64-tdep.c +++ b/gdb/amd64-tdep.c @@ -43,6 +43,7 @@ #include "features/i386/amd64.c" #include "features/i386/amd64-avx.c" +#include "features/i386/amd64-mpx.c" #include "features/i386/x32.c" #include "features/i386/x32-avx.c" @@ -92,6 +93,11 @@ static const char *amd64_ymmh_names[] = "ymm12h", "ymm13h", "ymm14h", "ymm15h" }; +static const char *amd64_mpx_names[] = +{ + "bnd0raw", "bnd1raw", "bnd2raw", "bnd3raw", "bndcfgu", "bndstatus" +}; + /* DWARF Register Number Mapping as defined in the System V psABI, section 3.6. */ @@ -2845,6 +2851,13 @@ amd64_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch) tdep->ymm0h_regnum = AMD64_YMM0H_REGNUM; } + if (tdesc_find_feature (tdesc, "org.gnu.gdb.i386.mpx") != NULL) + { + tdep->mpx_register_names = amd64_mpx_names; + tdep->bndcfgu_regnum = AMD64_BNDCFGU_REGNUM; + tdep->bnd0r_regnum = AMD64_BND0R_REGNUM; + } + tdep->num_byte_regs = 20; tdep->num_word_regs = 16; tdep->num_dword_regs = 16; @@ -2986,6 +2999,7 @@ _initialize_amd64_tdep (void) { initialize_tdesc_amd64 (); initialize_tdesc_amd64_avx (); + initialize_tdesc_amd64_mpx (); initialize_tdesc_x32 (); initialize_tdesc_x32_avx (); } |