diff options
author | Jason Thorpe <thorpej@netbsd.org> | 2002-04-21 16:52:39 +0000 |
---|---|---|
committer | Jason Thorpe <thorpej@netbsd.org> | 2002-04-21 16:52:39 +0000 |
commit | 1dd102ea1a5cfab904c417bc57677ff7ed824d2c (patch) | |
tree | b45f7e5a3e86e5ea3e6a8e371ce9ee07e8272517 /gdb/alpha-nat.c | |
parent | 4644b9c7650364d883dfa503f77d43aea1b23f5e (diff) | |
download | gdb-1dd102ea1a5cfab904c417bc57677ff7ed824d2c.tar.gz |
* alpha-tdep.h: New file. Includes several Alpha target constants
taken from...
* config/alpha/tm-alpha.h: ...here. Remove macros that we now
let gdbarch deal with.
(GDB_MULTI_ARCH): Define as GDB_MULTI_ARCH_PARTIAL.
* Makefile.in (alpha-nat.o): Add alpha-tdep.h and $(BFD_SRC)/elf-bfd
to dependency list.
* alpha-nat.c: Include alpha-tdep.h. Update for adjusted
Alpha target register names.
* alphabsd-nat.c: Likewise.
* alpha-tdep.c: Include alpha-tdep.h. Update for adjusted
Alpha target register names. Make serveral routines static.
(alpha_get_saved_register): New function.
(alpha_abi_names): New.
(process_note_abi_tag_sections): New function.
(get_elfosabi): New function.
(alpha_gdbarch_init): New function.
(alpha_dump_tdep): New function.
(_initialize_alpha_tdep): Register alpha_gdbarch_init.
Diffstat (limited to 'gdb/alpha-nat.c')
-rw-r--r-- | gdb/alpha-nat.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/gdb/alpha-nat.c b/gdb/alpha-nat.c index f7e565b3003..fbf8155d68e 100644 --- a/gdb/alpha-nat.c +++ b/gdb/alpha-nat.c @@ -24,6 +24,9 @@ #include "gdbcore.h" #include "target.h" #include "regcache.h" + +#include "alpha-tdep.h" + #include <sys/ptrace.h> #ifdef __linux__ #include <asm/reg.h> @@ -62,7 +65,7 @@ get_longjmp_target (CORE_ADDR *pc) CORE_ADDR jb_addr; char raw_buffer[MAX_REGISTER_RAW_SIZE]; - jb_addr = read_register (A0_REGNUM); + jb_addr = read_register (ALPHA_A0_REGNUM); if (target_read_memory (jb_addr + JB_PC * JB_ELEMENT_SIZE, raw_buffer, sizeof (CORE_ADDR))) @@ -171,10 +174,11 @@ fetch_elf_core_registers (char *core_reg_sect, unsigned core_reg_size, else { /* The General Registers. */ - memcpy (®isters[REGISTER_BYTE (V0_REGNUM)], core_reg_sect, 31 * 8); + memcpy (®isters[REGISTER_BYTE (ALPHA_V0_REGNUM)], core_reg_sect, + 31 * 8); memcpy (®isters[REGISTER_BYTE (PC_REGNUM)], core_reg_sect + 31 * 8, 8); - memset (®isters[REGISTER_BYTE (ZERO_REGNUM)], 0, 8); - memset (®ister_valid[V0_REGNUM], 1, 32); + memset (®isters[REGISTER_BYTE (ALPHA_ZERO_REGNUM)], 0, 8); + memset (®ister_valid[ALPHA_V0_REGNUM], 1, 32); register_valid[PC_REGNUM] = 1; } } @@ -227,7 +231,7 @@ supply_gregset (gdb_gregset_t *gregsetp) supply_register (PC_REGNUM, (char *) (regp + 31)); /* Fill inaccessible registers with zero. */ - supply_register (ZERO_REGNUM, zerobuf); + supply_register (ALPHA_ZERO_REGNUM, zerobuf); supply_register (FP_REGNUM, zerobuf); } |