diff options
author | Elena Zannoni <ezannoni@kwikemart.cygnus.com> | 2001-12-09 21:39:53 +0000 |
---|---|---|
committer | Elena Zannoni <ezannoni@kwikemart.cygnus.com> | 2001-12-09 21:39:53 +0000 |
commit | 22d86365d7450230aad6e3fd4745133a59041632 (patch) | |
tree | e277051316e311c818d591fa2cd6442b1aca7fb7 /gdb/ppcnbsd-nat.c | |
parent | fc3b534a176ed7566332e592dd454a9345d47c22 (diff) | |
download | gdb-22d86365d7450230aad6e3fd4745133a59041632.tar.gz |
2001-12-09 Elena Zannoni <ezannoni@redhat.com>
* config/rs6000/tm-rs6000.h (STAB_REG_TO_REGNUM): Remove
definition, it is now multiarched.
* ppc-tdep.h (struct gdbarch_tdep): Move from rs6000-tdep.c. Add
fields for special register numbers.
* rs6000-tdep.c (rs6000_gdbarch_init): Initialize new tdep special
regnum fields.
(rs6000_saved_pc_after_call): Use gdbarch_tdep registers fields
instead of hardcoded macros.
(branch_dest, rs6000_pop_frame, rs6000_fix_call_dummy,
ppc_push_return_address, rs6000_frame_saved_pc,
frame_get_saved_regs, rs6000_frame_chain,
rs6000_store_return_value): Ditto.
(rs6000_stab_reg_to_regnum): New function.
* ppcnbsd-nat.c (fetch_inferior_registers,
store_inferior_registers, fetch_core_registers): Ditto.
* ppc-linux-tdep.c (ppc_linux_in_sigtramp,
ppc_linux_frame_init_saved_regs): Ditto.
* ppc-linux-nat.c (ppc_register_u_addr, supply_gregset,
fill_gregset): Ditto.
* ppc-bdm.c (bdm_ppc_fetch_registers, bdm_ppc_store_registers):
Ditto.
Diffstat (limited to 'gdb/ppcnbsd-nat.c')
-rw-r--r-- | gdb/ppcnbsd-nat.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/gdb/ppcnbsd-nat.c b/gdb/ppcnbsd-nat.c index b206110fc49..55acf95fb21 100644 --- a/gdb/ppcnbsd-nat.c +++ b/gdb/ppcnbsd-nat.c @@ -49,10 +49,10 @@ fetch_inferior_registers (int regno) (PTRACE_ARG3_TYPE) & inferior_registers, 0); for (i = 0; i < 32; i++) RF (i, inferior_registers.fixreg[i]); - RF (PPC_LR_REGNUM, inferior_registers.lr); - RF (PPC_CR_REGNUM, inferior_registers.cr); - RF (PPC_XER_REGNUM, inferior_registers.xer); - RF (PPC_CTR_REGNUM, inferior_registers.ctr); + RF (gdbarch_tdep (current_gdbarch)->ppc_lr_regnum, inferior_registers.lr); + RF (gdbarch_tdep (current_gdbarch)->ppc_cr_regnum, inferior_registers.cr); + RF (gdbarch_tdep (current_gdbarch)->ppc_xer_regnum, inferior_registers.xer); + RF (gdbarch_tdep (current_gdbarch)->ppc_ctr_regnum, inferior_registers.ctr); RF (PC_REGNUM, inferior_registers.pc); #ifdef PT_GETFPREGS @@ -76,10 +76,10 @@ store_inferior_registers (int regno) for (i = 0; i < 32; i++) RS (i, inferior_registers.fixreg[i]); - RS (PPC_LR_REGNUM, inferior_registers.lr); - RS (PPC_CR_REGNUM, inferior_registers.cr); - RS (PPC_XER_REGNUM, inferior_registers.xer); - RS (PPC_CTR_REGNUM, inferior_registers.ctr); + RS (gdbarch_tdep (current_gdbarch)->ppc_lr_regnum, inferior_registers.lr); + RS (gdbarch_tdep (current_gdbarch)->ppc_cr_regnum, inferior_registers.cr); + RS (gdbarch_tdep (current_gdbarch)->ppc_xer_regnum, inferior_registers.xer); + RS (gdbarch_tdep (current_gdbarch)->ppc_ctr_regnum, inferior_registers.ctr); RS (PC_REGNUM, inferior_registers.pc); ptrace (PT_SETREGS, PIDGET (inferior_ptid), @@ -111,10 +111,10 @@ fetch_core_registers (char *core_reg_sect, unsigned core_reg_size, int which, /* Integer registers */ for (i = 0; i < 32; i++) RF (i, core_reg->intreg.fixreg[i]); - RF (PPC_LR_REGNUM, core_reg->intreg.lr); - RF (PPC_CR_REGNUM, core_reg->intreg.cr); - RF (PPC_XER_REGNUM, core_reg->intreg.xer); - RF (PPC_CTR_REGNUM, core_reg->intreg.ctr); + RF (gdbarch_tdep (current_gdbarch)->ppc_lr_regnum, core_reg->intreg.lr); + RF (gdbarch_tdep (current_gdbarch)->ppc_cr_regnum, core_reg->intreg.cr); + RF (gdbarch_tdep (current_gdbarch)->ppc_xer_regnum, core_reg->intreg.xer); + RF (gdbarch_tdep (current_gdbarch)->ppc_ctr_regnum, core_reg->intreg.ctr); RF (PC_REGNUM, core_reg->intreg.pc); #ifdef PT_FPGETREGS |