aboutsummaryrefslogtreecommitdiff
path: root/gdb/s12z-tdep.c
diff options
context:
space:
mode:
authorAndrew Burgess <andrew.burgess@embecosm.com>2019-01-10 20:38:42 +0000
committerAndrew Burgess <andrew.burgess@embecosm.com>2019-04-23 23:06:54 +0100
commitf872fdbb5b83f39f359bc1cd016dcc0456cb0c0a (patch)
tree9da4dc27fbbe31dab8f55c1863821871ef5542fc /gdb/s12z-tdep.c
parentb614e6f3f820fe08d407b57821456f672d4d1a6f (diff)
downloadgdb-f872fdbb5b83f39f359bc1cd016dcc0456cb0c0a.zip
gdb-f872fdbb5b83f39f359bc1cd016dcc0456cb0c0a.tar.gz
gdb-f872fdbb5b83f39f359bc1cd016dcc0456cb0c0a.tar.bz2
gdb/s12z: Use default gdbarch methods where possible
Make use of the default gdbarch methods for gdbarch_unwind_pc, and gdbarch_unwind_sp where possible. I have not tested this change but, by inspecting the code, I believe the default methods are equivalent to the code being deleted. gdb/ChangeLog: * s12z-tdep.c (s12z_unwind_pc): Delete. (s12z_unwind_sp): Delete. (s12z_gdbarch_init): Don't register deleted functions with gdbarch.
Diffstat (limited to 'gdb/s12z-tdep.c')
-rw-r--r--gdb/s12z-tdep.c18
1 files changed, 0 insertions, 18 deletions
diff --git a/gdb/s12z-tdep.c b/gdb/s12z-tdep.c
index ea14992..cef92d8 100644
--- a/gdb/s12z-tdep.c
+++ b/gdb/s12z-tdep.c
@@ -95,20 +95,6 @@ s12z_skip_prologue (struct gdbarch *gdbarch, CORE_ADDR pc)
return pc;
}
-/* Implement the unwind_pc gdbarch method. */
-static CORE_ADDR
-s12z_unwind_pc (struct gdbarch *gdbarch, struct frame_info *next_frame)
-{
- return frame_unwind_register_unsigned (next_frame, REG_P);
-}
-
-/* Implement the unwind_sp gdbarch method. */
-static CORE_ADDR
-s12z_unwind_sp (struct gdbarch *gdbarch, struct frame_info *next_frame)
-{
- return frame_unwind_register_unsigned (next_frame, REG_S);
-}
-
static struct type *
s12z_register_type (struct gdbarch *gdbarch, int reg_nr)
{
@@ -581,10 +567,6 @@ s12z_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_register_type (gdbarch, s12z_register_type);
- /* Functions to access frame data. */
- set_gdbarch_unwind_pc (gdbarch, s12z_unwind_pc);
- set_gdbarch_unwind_sp (gdbarch, s12z_unwind_sp);
-
frame_unwind_append_unwinder (gdbarch, &s12z_frame_unwind);
/* Currently, the only known producer for this archtecture, produces buggy
dwarf CFI. So don't append a dwarf unwinder until the situation is