summaryrefslogtreecommitdiff
path: root/gdb/sparc-tdep.c
diff options
context:
space:
mode:
authorAndrew Cagney <cagney@redhat.com>2003-09-09 03:58:18 +0000
committerAndrew Cagney <cagney@redhat.com>2003-09-09 03:58:18 +0000
commitd4019662a586dbf4da3e237c6874033b91f36099 (patch)
tree0469b498e20a1659b12d11ae77ea21f3a3d7fcba /gdb/sparc-tdep.c
parent9dd95543f402606e40ad473d03245f40e08bc58d (diff)
downloadgdb-d4019662a586dbf4da3e237c6874033b91f36099.tar.gz
2003-09-08 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_CALL_DUMMY_ADDRESS): Rename CALL_DUMMY_ADDRESS, change to a predicate. * gdbarch.h, gdbarch.c: Re-generate. * blockframe.c (deprecated_pc_in_call_dummy_at_entry_point): Use either DEPRECATED_CALL_DUMMY_ADDRESS or entry_point_address. * infcall.c (call_function_by_hand): Ditto. * sparc-tdep.c (sparc_push_return_address): Ditto. (sparc_gdbarch_init): Set deprecated_call_dummy_address. * xstormy16-tdep.c (xstormy16_push_return_address): Replace CALL_DUMMY_ADDRESS with entry_point_address. * v850-tdep.c (v850_push_return_address): Ditto. * s390-tdep.c (s390_push_return_address): Ditto. * rs6000-tdep.c (ppc_push_return_address): Ditto. * mn10300-tdep.c (mn10300_push_return_address): Ditto. * mcore-tdep.c (mcore_push_return_address): Ditto. * cris-tdep.c (cris_push_return_address): Ditto. * arm-tdep.c (arm_push_return_address): Ditto.
Diffstat (limited to 'gdb/sparc-tdep.c')
-rw-r--r--gdb/sparc-tdep.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/gdb/sparc-tdep.c b/gdb/sparc-tdep.c
index 970d9536bab..c516efd024a 100644
--- a/gdb/sparc-tdep.c
+++ b/gdb/sparc-tdep.c
@@ -2967,8 +2967,10 @@ sparc_push_return_address (CORE_ADDR pc_unused, CORE_ADDR sp)
This address will actually be the program's entry point.
There will be a special call_dummy breakpoint there. */
- write_register (O7_REGNUM,
- CALL_DUMMY_ADDRESS () - 8);
+ if (DEPRECATED_CALL_DUMMY_ADDRESS_P ())
+ write_register (O7_REGNUM, DEPRECATED_CALL_DUMMY_ADDRESS () - 8);
+ else
+ write_register (O7_REGNUM, entry_point_address () - 8);
}
return sp;
@@ -3136,7 +3138,8 @@ sparc_gdbarch_fix_call_dummy (char *dummy,
sparc_fix_call_dummy (dummy, pc, fun, type, gcc_p);
}
-/* CALL_DUMMY_ADDRESS: fetch the breakpoint address for a call dummy. */
+/* DEPRECATED_CALL_DUMMY_ADDRESS: fetch the breakpoint address for a
+ call dummy. */
static CORE_ADDR
sparc_call_dummy_address (void)
@@ -3314,7 +3317,7 @@ sparc_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
#ifdef SPARC32_CALL_DUMMY_ON_STACK
set_gdbarch_deprecated_pc_in_call_dummy (gdbarch, deprecated_pc_in_call_dummy_on_stack);
- set_gdbarch_call_dummy_address (gdbarch, sparc_call_dummy_address);
+ set_gdbarch_deprecated_call_dummy_address (gdbarch, sparc_call_dummy_address);
set_gdbarch_deprecated_call_dummy_breakpoint_offset (gdbarch, 0x30);
set_gdbarch_deprecated_call_dummy_length (gdbarch, 0x38);
@@ -3414,7 +3417,7 @@ sparc_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
#ifdef SPARC64_CALL_DUMMY_ON_STACK
set_gdbarch_deprecated_pc_in_call_dummy (gdbarch, deprecated_pc_in_call_dummy_on_stack);
- set_gdbarch_call_dummy_address (gdbarch, sparc_call_dummy_address);
+ set_gdbarch_deprecated_call_dummy_address (gdbarch, sparc_call_dummy_address);
set_gdbarch_deprecated_call_dummy_breakpoint_offset (gdbarch, 8 * 4);
set_gdbarch_deprecated_call_dummy_length (gdbarch, 192);
set_gdbarch_call_dummy_location (gdbarch, ON_STACK);