From 34f75cc19f3ab1dfb345b07e19fe298d26124396 Mon Sep 17 00:00:00 2001 From: Randolph Chung Date: Fri, 7 May 2004 05:48:50 +0000 Subject: 2004-05-06 Randolph Chung * config/pa/tm-hppa.h (RO_REGNUM, FLAGS_REGNUM, RP_REGNUM) (HPPA_FP_REGNUM, HPPA_SP_REGNUM, SAR_REGNUM, IPSW_REGNUM) (PCOQ_HEAD_REGNUM, PCSQ_HEAD_REGNUM, PCOQ_TAIL_REGNUM, PCSQ_TAIL_REGNUM) (EIEM_REGNUM, IIR_REGNUM, ISR_REGNUM, IOR_REGNUM, SR4_REGNUM) (RCR_REGNUM, PID0_REGNUM, PID1_REGNUM, PID2_REGNUM, PID3_REGNUM) (CCR_REGNUM, TR0_REGNUM, CR27_REGNUM, HPPA_FP0_REGNUM, FP4_REGNUM) (ARG0_REGNUM, ARG1_REGNUM, ARG2_REGNUM, ARG3_REGNUM): Move *_REGNUM definitions ... * hppa-tdep.h: ... to here, with HPPA_ prefix. * Makefile.in (hppah-nat.o): Add $(hppa_tdep_h) * hppa-hpux-tdep.c (hppa32_hpux_frame_find_saved_regs_in_sig) (hppa64_hpux_frame_find_saved_regs_in_sig) (child_get_current_exception_event): Add HPPA_ prefix to *_REGNUM usage. * hppa-linux-nat.c (GR_REGNUM, TR_REGNUM, greg_map): Likewise. * hppa-linux-tdep.c (hppa_dwarf_reg_to_regnum) (hppa_linux_target_write_pc, hppa_linux_sigtramp_frame_unwind_cache) (hppa_linux_sigtramp_frame_prev_register): Likewise. * hppa-tdep.c (hppa32_return_value, hppa64_return_value) (hppa32_push_dummy_call, hppa64_push_dummy_call, hppa64_frame_align) (hppa_target_read_pc, hppa_target_write_pc, hppa_frame_cache) (hppa_frame_prev_register, hppa_stub_frame_unwind_cache) (hppa_stub_frame_prev_register, hppa_unwind_dummy_id) (hppa_skip_permanent_breakpoint, hppa_instruction_nullified) (hppa32_register_type, hppa_cannot_store_register) (hppa_fetch_pointer_argument, hppa_pseudo_register_read): Likewise. * hppah-nat.c (store_inferior_registers, fetch_register): Likewise. * hpread.c (hpread_process_one_debug_symbol): Likewise. * pa64solib.c (pa64_solib_have_load_event) (pa64_solib_have_unload_event, pa64_solib_loaded_library_pathname) (pa64_solib_unloaded_library_pathname): Likewise. * somsolib.c (som_solib_have_load_event, som_solib_have_unload_event) (som_solib_library_pathname): Likewise. --- gdb/hppah-nat.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) (limited to 'gdb/hppah-nat.c') diff --git a/gdb/hppah-nat.c b/gdb/hppah-nat.c index 98ea60d..6b361eb 100644 --- a/gdb/hppah-nat.c +++ b/gdb/hppah-nat.c @@ -35,6 +35,7 @@ #include "infttrace.h" #include +#include "hppa-tdep.h" static CORE_ADDR text_end; @@ -113,9 +114,9 @@ store_inferior_registers (int regno) } /* Floating-point registers come from the ss_fpblock area. */ - else if (regno >= FP0_REGNUM) + else if (regno >= HPPA_FP0_REGNUM) addr = (HPPAH_OFFSETOF (save_state_t, ss_fpblock) - + (DEPRECATED_REGISTER_BYTE (regno) - DEPRECATED_REGISTER_BYTE (FP0_REGNUM))); + + (DEPRECATED_REGISTER_BYTE (regno) - DEPRECATED_REGISTER_BYTE (HPPA_FP0_REGNUM))); /* Wide registers come from the ss_wide area. I think it's more PC to test (ss_flags & SS_WIDEREGS) to select @@ -141,7 +142,7 @@ store_inferior_registers (int regno) layering will not allow us to perform a 64bit register store. What a crock. */ - if (regno == PCOQ_HEAD_REGNUM || regno == PCOQ_TAIL_REGNUM && len == 8) + if (regno == HPPA_PCOQ_HEAD_REGNUM || regno == HPPA_PCOQ_TAIL_REGNUM && len == 8) { CORE_ADDR temp; @@ -169,7 +170,7 @@ store_inferior_registers (int regno) /* Another crock. HPUX complains if you write a nonzero value to the high part of IPSW. What will it take for HP to catch a clue about building sensible interfaces? */ - if (regno == IPSW_REGNUM && len == 8) + if (regno == HPPA_IPSW_REGNUM && len == 8) *(int *)&deprecated_registers[DEPRECATED_REGISTER_BYTE (regno)] = 0; #endif @@ -189,7 +190,7 @@ store_inferior_registers (int regno) REGISTER_NAME (regno), err); /* If we fail to write the PC, give a true error instead of just a warning. */ - if (regno == PCOQ_HEAD_REGNUM || regno == PCOQ_TAIL_REGNUM) + if (regno == HPPA_PCOQ_HEAD_REGNUM || regno == HPPA_PCOQ_TAIL_REGNUM) perror_with_name (msg); else warning (msg); @@ -231,9 +232,9 @@ fetch_register (int regno) } /* Floating-point registers come from the ss_fpblock area. */ - else if (regno >= FP0_REGNUM) + else if (regno >= HPPA_FP0_REGNUM) addr = (HPPAH_OFFSETOF (save_state_t, ss_fpblock) - + (DEPRECATED_REGISTER_BYTE (regno) - DEPRECATED_REGISTER_BYTE (FP0_REGNUM))); + + (DEPRECATED_REGISTER_BYTE (regno) - DEPRECATED_REGISTER_BYTE (HPPA_FP0_REGNUM))); /* Wide registers come from the ss_wide area. I think it's more PC to test (ss_flags & SS_WIDEREGS) to select @@ -278,7 +279,7 @@ fetch_register (int regno) /* If we're reading an address from the instruction address queue, mask out the bottom two bits --- they contain the privilege level. */ - if (regno == PCOQ_HEAD_REGNUM || regno == PCOQ_TAIL_REGNUM) + if (regno == HPPA_PCOQ_HEAD_REGNUM || regno == HPPA_PCOQ_TAIL_REGNUM) buf[len - 1] &= ~0x3; supply_register (regno, buf); -- cgit v1.1