aboutsummaryrefslogtreecommitdiff
path: root/gdb/hppa-tdep.c
diff options
context:
space:
mode:
authorAndrew Cagney <cagney@redhat.com>2003-04-29 01:49:49 +0000
committerAndrew Cagney <cagney@redhat.com>2003-04-29 01:49:49 +0000
commit0ba6dca974b6df1fc1ac67608815cf5a2603856d (patch)
treedbcece7b70356e620a0ba46bf2ca570f3fdb9843 /gdb/hppa-tdep.c
parent3c9dc02ab9da3692af0315608b064a635b974159 (diff)
downloadgdb-0ba6dca974b6df1fc1ac67608815cf5a2603856d.zip
gdb-0ba6dca974b6df1fc1ac67608815cf5a2603856d.tar.gz
gdb-0ba6dca974b6df1fc1ac67608815cf5a2603856d.tar.bz2
2003-04-28 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_TARGET_READ_FP): Replace TARGET_READ_FP. (DEPRECATED_FP_REGNUM): Replace FP_REGNUM. * gdbarch.h, gdbarch.c: Re-generate. * infcall.c (call_function_by_hand): Use DEPRECATED_FP_REGNUM, DEPRECATED_TARGET_READ_FP, or "sp" to create the dummy frame ID. * inferior.h (deprecated_read_fp): Rename read_fp. (generic_target_read_fp): Delete declaration. * regcache.c (generic_target_read_fp): Delete function. (deprecated_read_fp): Replace read_fp, use DEPRECATED_TARGET_READ_FP or DEPRECATED_FP_REGNUM. * d10v-tdep.c (d10v_read_fp): Delete function. (d10v_gdbarch_init): Do not set deprecated_read_fp. * sparc-tdep.c (sparc_gdbarch_init): Do not set deprecated_target_read_fp to generic_target_read_fp. * sh-tdep.c (sh_gdbarch_init): Ditto. * rs6000-tdep.c (rs6000_gdbarch_init): Ditto. * m68hc11-tdep.c (m68hc11_gdbarch_init): Ditto. * frv-tdep.c (frv_gdbarch_init): Ditto. * xstormy16-tdep.c (xstormy16_gdbarch_init): Set deprecated_fp_regnum. * x86-64-tdep.c (x86_64_init_abi): Ditto. * vax-tdep.c (vax_gdbarch_init): Ditto. * v850-tdep.c (v850_gdbarch_init): Ditto. * sparc-tdep.c (sparc_gdbarch_init): Ditto. * sh-tdep.c (sh_gdbarch_init): Ditto. * s390-tdep.c (s390_gdbarch_init): Ditto. * rs6000-tdep.c (rs6000_gdbarch_init): Ditto. * mn10300-tdep.c (mn10300_gdbarch_init): Ditto. * mcore-tdep.c (mcore_gdbarch_init): Ditto. * m68k-tdep.c (m68k_gdbarch_init): Ditto. * m68hc11-tdep.c (m68hc11_gdbarch_init): Ditto. * ia64-tdep.c (ia64_gdbarch_init): Ditto. * i386-tdep.c (i386_gdbarch_init): Ditto. * hppa-tdep.c (hppa_gdbarch_init): Ditto. * h8300-tdep.c (h8300_gdbarch_init): Ditto. * frv-tdep.c (frv_gdbarch_init): Ditto. * cris-tdep.c (cris_gdbarch_init): Ditto. * avr-tdep.c (avr_gdbarch_init): Ditto. * arm-tdep.c (arm_gdbarch_init): Ditto. * alpha-tdep.c (alpha_gdbarch_init): Ditto. * x86-64-tdep.c (x86_64_init_abi): Set deprecated_target_read_fp. * v850-tdep.c (v850_gdbarch_init): Ditto. * sparc-tdep.c (sparc_gdbarch_init): Ditto. * sh-tdep.c (sh_gdbarch_init): Ditto. * s390-tdep.c (s390_gdbarch_init): Ditto. * rs6000-tdep.c (rs6000_gdbarch_init): Ditto. * mn10300-tdep.c (mn10300_gdbarch_init): Ditto. * mips-tdep.c (mips_gdbarch_init): Ditto. * m68hc11-tdep.c (m68hc11_gdbarch_init): Ditto. * ia64-tdep.c (ia64_gdbarch_init): Ditto. * hppa-tdep.c (hppa_gdbarch_init): Ditto. * frv-tdep.c (frv_gdbarch_init): Ditto. * avr-tdep.c (avr_gdbarch_init): Ditto. * arm-tdep.c (arm_gdbarch_init): Ditto. * vax-tdep.c (vax_frame_init_saved_regs): Replace FP_REGNUM with DEPRECATED_FP_REGNUM. (vax_push_dummy_frame, vax_pop_frame): Ditto. * std-regs.c (value_of_builtin_frame_fp_reg): Ditto. * sparc-tdep.c (sparc_init_extra_frame_info): Ditto. (sparc_push_dummy_frame, sparc64_read_fp): Ditto. (sparc32_register_virtual_type): Ditto. * sh-tdep.c (sh64_frame_chain): Ditto. (sh64_get_saved_register, sh64_pop_frame): Ditto. (sh_nofp_frame_init_saved_regs): Ditto. (sh64_nofp_frame_init_saved_regs): Ditto. (sh_fp_frame_init_saved_regs): Ditto. * remote-mips.c (mips_wait, mips_fetch_registers): Ditto. * remote-e7000.c (fetch_regs_from_dump): Ditto. * procfs.c (procfs_fetch_registers): Ditto. (procfs_store_registers): Ditto. * ns32knbsd-nat.c (fetch_inferior_registers): Ditto. (store_inferior_registers, fetch_core_registers): Ditto. (fetch_kcore_registers, clear_regs): Ditto. * ns32k-tdep.c (ns32k_frame_init_saved_regs): Ditto. (ns32k_push_dummy_frame, ns32k_pop_frame): Ditto. * nlm/i386.h (DEPRECATED_FP_REGNUM): Ditto. * nlm/i386.c (do_status): Ditto. * mipsv4-nat.c (supply_gregset): Ditto. * mips-tdep.c: Ditto for comments. * mips-nat.c (fetch_inferior_registers): Ditto. (store_inferior_registers, fetch_core_registers): Ditto. * m68k-tdep.c (m68k_push_dummy_frame): Ditto. (m68k_pop_frame, m68k_frame_init_saved_regs): Ditto. * i386-tdep.c (i386_frame_init_saved_regs): Ditto. (i386_do_pop_frame, i386_register_type): Ditto. * hppa-tdep.c (hppa_frame_chain): Ditto. (hppa_push_dummy_frame, find_dummy_frame_regs): Ditto. (hppa_pop_frame, hppa_read_fp): Ditto. (skip_prologue_hard_way, hppa_frame_find_saved_regs): Ditto. * cris-tdep.c (cris_examine, cris_pop_frame): Ditto. * config/vax/nm-vax.h (REGISTER_U_ADDR): Ditto. * config/sparc/tm-sparc.h (DEPRECATED_FP_REGNUM): Ditto. * config/sparc/tm-sp64.h (DEPRECATED_FP_REGNUM): Ditto. * config/s390/tm-s390.h (DEPRECATED_FP_REGNUM): Ditto. * config/pa/tm-hppa64.h (DEPRECATED_FP_REGNUM): Ditto. * config/ia64/tm-ia64.h (DEPRECATED_FP_REGNUM): Ditto. * blockframe.c: Ditto for comments. * arch-utils.h: Ditto for comments. * arch-utils.c (legacy_virtual_frame_pointer): Ditto. * alphanbsd-tdep.c (fetch_core_registers): Ditto. * alphabsd-nat.c (fetch_inferior_registers): Ditto. * alpha-tdep.h: Ditto for comments. * alpha-tdep.c (alpha_cannot_fetch_register): Ditto. (alpha_cannot_store_register): Ditto. (alpha_push_dummy_frame): Ditto. * alpha-nat.c (supply_gregset): Ditto. * config/sparc/tm-sp64.h (DEPRECATED_TARGET_READ_FP): Update. * config/pa/tm-hppa64.h (DEPRECATED_TARGET_READ_FP): Update. * config/sparc/tm-sparc.h: Update comment. * hppa-tdep.c (hppa_init_extra_frame_info): Use deprecated_read_fp instead of TARGET_READ_FP. (hppa_init_extra_frame_info, hppa_frame_chain): Ditto. (hppa_push_dummy_frame, hppa_read_fp): Ditto. * sparc-tdep.c (sparc_init_extra_frame_info): Use deprecated_read_fp instead of read_fp. * s390-tdep.c (s390_push_arguments): Ditto. * ia64-tdep.c (ia64_gdbarch_init): Ditto. * frame.h: Ditto in comments. * frame.c (legacy_get_prev_frame): Ditto. * dummy-frame.c (dummy_frame_this_id): Ditto. * arm-tdep.c (arm_init_extra_frame_info): Ditto. 2003-04-28 Andrew Cagney <cagney@redhat.com> * gdbint.texinfo (Target Architecture Definition): Replace read_fp, TARGET_READ_FP and FP_REGNUM, with deprecated_read_fp, DEPRECATED_TARGET_READ_FP and DEPRECATED_REGNUM.
Diffstat (limited to 'gdb/hppa-tdep.c')
-rw-r--r--gdb/hppa-tdep.c42
1 files changed, 21 insertions, 21 deletions
diff --git a/gdb/hppa-tdep.c b/gdb/hppa-tdep.c
index 4c60c24..db761ac 100644
--- a/gdb/hppa-tdep.c
+++ b/gdb/hppa-tdep.c
@@ -1085,7 +1085,7 @@ hppa_init_extra_frame_info (int fromleaf, struct frame_info *frame)
frame. (we always want frame->frame to point at the lowest address
in the frame). */
if (framesize == -1)
- deprecated_update_frame_base_hack (frame, TARGET_READ_FP ());
+ deprecated_update_frame_base_hack (frame, deprecated_read_fp ());
else
deprecated_update_frame_base_hack (frame, get_frame_base (frame) - framesize);
return;
@@ -1106,7 +1106,7 @@ hppa_init_extra_frame_info (int fromleaf, struct frame_info *frame)
sorts, and its base is the high address in its parent's frame. */
framesize = find_proc_framesize (get_frame_pc (frame));
if (framesize == -1)
- deprecated_update_frame_base_hack (frame, TARGET_READ_FP ());
+ deprecated_update_frame_base_hack (frame, deprecated_read_fp ());
else
deprecated_update_frame_base_hack (frame, read_register (SP_REGNUM) - framesize);
}
@@ -1264,7 +1264,7 @@ hppa_frame_chain (struct frame_info *frame)
saved_regs_frame = tmp_frame;
/* If we have an address for r3, that's good. */
- if (saved_regs[FP_REGNUM])
+ if (saved_regs[DEPRECATED_FP_REGNUM])
break;
}
}
@@ -1326,7 +1326,7 @@ hppa_frame_chain (struct frame_info *frame)
u = find_unwind_entry (DEPRECATED_FRAME_SAVED_PC (frame));
if (!u)
{
- return read_memory_integer (saved_regs[FP_REGNUM],
+ return read_memory_integer (saved_regs[DEPRECATED_FP_REGNUM],
TARGET_PTR_BIT / 8);
}
else
@@ -1335,7 +1335,7 @@ hppa_frame_chain (struct frame_info *frame)
}
}
- return read_memory_integer (saved_regs[FP_REGNUM],
+ return read_memory_integer (saved_regs[DEPRECATED_FP_REGNUM],
TARGET_PTR_BIT / 8);
}
}
@@ -1364,7 +1364,7 @@ hppa_frame_chain (struct frame_info *frame)
u = find_unwind_entry (DEPRECATED_FRAME_SAVED_PC (frame));
if (!u)
{
- return read_memory_integer (saved_regs[FP_REGNUM],
+ return read_memory_integer (saved_regs[DEPRECATED_FP_REGNUM],
TARGET_PTR_BIT / 8);
}
else
@@ -1375,7 +1375,7 @@ hppa_frame_chain (struct frame_info *frame)
/* The value in %r3 was never saved into the stack (thus %r3 still
holds the value of the previous frame pointer). */
- return TARGET_READ_FP ();
+ return deprecated_read_fp ();
}
}
@@ -1472,15 +1472,15 @@ hppa_push_dummy_frame (void)
else
write_memory (sp - 20, (char *) &int_buffer, REGISTER_SIZE);
- int_buffer = TARGET_READ_FP ();
+ int_buffer = deprecated_read_fp ();
write_memory (sp, (char *) &int_buffer, REGISTER_SIZE);
- write_register (FP_REGNUM, sp);
+ write_register (DEPRECATED_FP_REGNUM, sp);
sp += 2 * REGISTER_SIZE;
for (regnum = 1; regnum < 32; regnum++)
- if (regnum != RP_REGNUM && regnum != FP_REGNUM)
+ if (regnum != RP_REGNUM && regnum != DEPRECATED_FP_REGNUM)
sp = push_word (sp, read_register (regnum));
/* This is not necessary for the 64bit ABI. In fact it is dangerous. */
@@ -1515,13 +1515,13 @@ find_dummy_frame_regs (struct frame_info *frame,
else
frame_saved_regs[RP_REGNUM] = (fp - 20) & ~0x3;
- frame_saved_regs[FP_REGNUM] = fp;
+ frame_saved_regs[DEPRECATED_FP_REGNUM] = fp;
frame_saved_regs[1] = fp + (2 * REGISTER_SIZE);
for (fp += 3 * REGISTER_SIZE, i = 3; i < 32; i++)
{
- if (i != FP_REGNUM)
+ if (i != DEPRECATED_FP_REGNUM)
{
frame_saved_regs[i] = fp;
fp += REGISTER_SIZE;
@@ -1598,7 +1598,7 @@ hppa_pop_frame (void)
write_pc (npc);
}
- write_register (FP_REGNUM, read_memory_integer (fp, REGISTER_SIZE));
+ write_register (DEPRECATED_FP_REGNUM, read_memory_integer (fp, REGISTER_SIZE));
if (fsr[IPSW_REGNUM]) /* call dummy */
write_register (SP_REGNUM, fp - 48);
@@ -2442,8 +2442,8 @@ hppa_read_fp (int pid)
}
/* This is the only site that may directly read_register () the FP
- register. All others must use TARGET_READ_FP (). */
- return read_register (FP_REGNUM);
+ register. All others must use deprecated_read_fp (). */
+ return read_register (DEPRECATED_FP_REGNUM);
}
CORE_ADDR
@@ -3590,7 +3590,7 @@ restart:
for (i = 3; i < u->Entry_GR + 3; i++)
{
/* Frame pointer gets saved into a special location. */
- if (u->Save_SP && i == FP_REGNUM)
+ if (u->Save_SP && i == DEPRECATED_FP_REGNUM)
continue;
save_gr |= (1 << i);
@@ -3941,7 +3941,7 @@ hppa_frame_find_saved_regs (struct frame_info *frame_info,
for (i = 3; i < u->Entry_GR + 3; i++)
{
/* Frame pointer gets saved into a special location. */
- if (u->Save_SP && i == FP_REGNUM)
+ if (u->Save_SP && i == DEPRECATED_FP_REGNUM)
continue;
save_gr |= (1 << i);
@@ -4003,14 +4003,14 @@ hppa_frame_find_saved_regs (struct frame_info *frame_info,
if ( (inst & 0xffffc000) == 0x6fc10000 /* stw,ma r1,N(sr0,sp) */
|| (inst & 0xffffc00c) == 0x73c10008) /* std,ma r1,N(sr0,sp) */
{
- frame_saved_regs[FP_REGNUM] = get_frame_base (frame_info);
+ frame_saved_regs[DEPRECATED_FP_REGNUM] = get_frame_base (frame_info);
save_sp = 0;
}
/* Account for general and floating-point register saves. */
reg = inst_saves_gr (inst);
if (reg >= 3 && reg <= 18
- && (!u->Save_SP || reg != FP_REGNUM))
+ && (!u->Save_SP || reg != DEPRECATED_FP_REGNUM))
{
save_gr &= ~(1 << reg);
@@ -4991,7 +4991,7 @@ hppa_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_decr_pc_after_break (gdbarch, 0);
set_gdbarch_register_size (gdbarch, 4);
set_gdbarch_num_regs (gdbarch, hppa_num_regs);
- set_gdbarch_fp_regnum (gdbarch, 3);
+ set_gdbarch_deprecated_fp_regnum (gdbarch, 3);
set_gdbarch_sp_regnum (gdbarch, 30);
set_gdbarch_fp0_regnum (gdbarch, 64);
set_gdbarch_pc_regnum (gdbarch, PCOQ_HEAD_REGNUM);
@@ -5030,7 +5030,7 @@ hppa_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_believe_pcc_promotion (gdbarch, 1);
set_gdbarch_read_pc (gdbarch, hppa_target_read_pc);
set_gdbarch_write_pc (gdbarch, hppa_target_write_pc);
- set_gdbarch_read_fp (gdbarch, hppa_target_read_fp);
+ set_gdbarch_deprecated_target_read_fp (gdbarch, hppa_target_read_fp);
return gdbarch;
}