@@ -974,20 +974,6 @@ struct frame_base aarch64_normal_base =
aarch64_normal_frame_base
};
-/* Assuming THIS_FRAME is a dummy, return the frame ID of that
- dummy frame. The frame ID's base needs to match the TOS value
- saved by save_dummy_frame_tos () and returned from
- aarch64_push_dummy_call, and the PC needs to match the dummy
- frame's breakpoint. */
-
-static struct frame_id
-aarch64_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- return frame_id_build (get_frame_register_unsigned (this_frame,
- AARCH64_SP_REGNUM),
- get_frame_pc (this_frame));
-}
-
/* Implement the "unwind_sp" gdbarch method. */
static CORE_ADDR
@@ -2928,7 +2914,6 @@ aarch64_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_frame_align (gdbarch, aarch64_frame_align);
/* Frame handling. */
- set_gdbarch_dummy_id (gdbarch, aarch64_dummy_id);
set_gdbarch_unwind_sp (gdbarch, aarch64_unwind_sp);
/* Advance PC across function entry code. */
@@ -1464,21 +1464,6 @@ reinit_frame_cache_sfunc (const char *args,
{
reinit_frame_cache ();
}
-
-
-/* Assuming NEXT_FRAME->prev is a dummy, return the frame ID of that
- dummy frame. The frame ID's base needs to match the TOS value
- saved by save_dummy_frame_tos(), and the PC match the dummy frame's
- breakpoint. */
-
-static struct frame_id
-alpha_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- ULONGEST base;
- base = get_frame_register_unsigned (this_frame, ALPHA_SP_REGNUM);
- return frame_id_build (base, get_frame_pc (this_frame));
-}
-
/* Helper routines for alpha*-nat.c files to move register sets to and
from core files. The UNIQUE pointer is allowed to be NULL, as most
@@ -1802,9 +1787,6 @@ alpha_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
/* Settings for calling functions in the inferior. */
set_gdbarch_push_dummy_call (gdbarch, alpha_push_dummy_call);
- /* Methods for saving / extracting a dummy frame's ID. */
- set_gdbarch_dummy_id (gdbarch, alpha_dummy_id);
-
set_gdbarch_inner_than (gdbarch, core_addr_lessthan);
set_gdbarch_skip_trampoline_code (gdbarch, find_solib_trampoline_target);
@@ -509,19 +509,6 @@ arc_virtual_frame_pointer (struct gdbarch *gdbarch, CORE_ADDR pc,
*offset_ptr = 0;
}
-/* Implement the "dummy_id" gdbarch method.
-
- Tear down a dummy frame created by arc_push_dummy_call (). This data has
- to be constructed manually from the data in our hand. The stack pointer
- and program counter can be obtained from the frame info. */
-
-static struct frame_id
-arc_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- return frame_id_build (get_frame_sp (this_frame),
- get_frame_pc (this_frame));
-}
-
/* Implement the "push_dummy_call" gdbarch method.
Stack Frame Layout
@@ -2005,7 +1992,6 @@ arc_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_ps_regnum (gdbarch, ARC_STATUS32_REGNUM);
set_gdbarch_fp0_regnum (gdbarch, -1); /* No FPU registers. */
- set_gdbarch_dummy_id (gdbarch, arc_dummy_id);
set_gdbarch_push_dummy_call (gdbarch, arc_push_dummy_call);
set_gdbarch_push_dummy_code (gdbarch, arc_push_dummy_code);
@@ -3055,20 +3055,6 @@ struct frame_base arm_normal_base = {
arm_normal_frame_base
};
-/* Assuming THIS_FRAME is a dummy, return the frame ID of that
- dummy frame. The frame ID's base needs to match the TOS value
- saved by save_dummy_frame_tos() and returned from
- arm_push_dummy_call, and the PC needs to match the dummy frame's
- breakpoint. */
-
-static struct frame_id
-arm_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- return frame_id_build (get_frame_register_unsigned (this_frame,
- ARM_SP_REGNUM),
- get_frame_pc (this_frame));
-}
-
static CORE_ADDR
arm_unwind_sp (struct gdbarch *gdbarch, struct frame_info *this_frame)
{
@@ -9351,7 +9337,6 @@ arm_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_write_pc (gdbarch, arm_write_pc);
/* Frame handling. */
- set_gdbarch_dummy_id (gdbarch, arm_dummy_id);
set_gdbarch_unwind_sp (gdbarch, arm_unwind_sp);
frame_base_set_default (gdbarch, &arm_normal_base);
@@ -756,16 +756,6 @@ static const struct frame_base bfin_frame_base =
bfin_frame_args_address
};
-static struct frame_id
-bfin_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- CORE_ADDR sp;
-
- sp = get_frame_register_unsigned (this_frame, BFIN_SP_REGNUM);
-
- return frame_id_build (sp, get_frame_pc (this_frame));
-}
-
static CORE_ADDR
bfin_frame_align (struct gdbarch *gdbarch, CORE_ADDR address)
{
@@ -820,7 +810,6 @@ bfin_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_dwarf2_reg_to_regnum (gdbarch, bfin_reg_to_regnum);
set_gdbarch_register_name (gdbarch, bfin_register_name);
set_gdbarch_register_type (gdbarch, bfin_register_type);
- set_gdbarch_dummy_id (gdbarch, bfin_dummy_id);
set_gdbarch_push_dummy_call (gdbarch, bfin_push_dummy_call);
set_gdbarch_believe_pcc_promotion (gdbarch, 1);
set_gdbarch_return_value (gdbarch, bfin_return_value);
@@ -764,18 +764,6 @@ cris_frame_prev_register (struct frame_info *this_frame,
return trad_frame_get_prev_register (this_frame, info->saved_regs, regnum);
}
-/* Assuming THIS_FRAME is a dummy, return the frame ID of that dummy
- frame. The frame ID's base needs to match the TOS value saved by
- save_dummy_frame_tos(), and the PC match the dummy frame's breakpoint. */
-
-static struct frame_id
-cris_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- CORE_ADDR sp;
- sp = get_frame_register_unsigned (this_frame, gdbarch_sp_regnum (gdbarch));
- return frame_id_build (sp, get_frame_pc (this_frame));
-}
-
static CORE_ADDR
cris_frame_align (struct gdbarch *gdbarch, CORE_ADDR sp)
{
@@ -4085,7 +4073,6 @@ cris_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_sw_breakpoint_from_kind (gdbarch, cris_sw_breakpoint_from_kind);
set_gdbarch_unwind_sp (gdbarch, cris_unwind_sp);
- set_gdbarch_dummy_id (gdbarch, cris_dummy_id);
if (tdep->cris_dwarf2_cfi == 1)
{
@@ -385,6 +385,22 @@ const struct frame_unwind dummy_frame_unwind =
dummy_frame_sniffer,
};
+/* Default implementation of gdbarch_dummy_id. Generate frame_id for
+ THIS_FRAME assuming that it is a dummy frame. A dummy frame is created
+ before an inferior call, the frame_id returned here must match the base
+ address returned by gdbarch_push_dummy_call and the frame's pc must
+ match the dummy frames breakpoint address. */
+
+struct frame_id
+default_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
+{
+ CORE_ADDR sp, pc;
+
+ sp = get_frame_sp (this_frame);
+ pc = get_frame_pc (this_frame);
+ return frame_id_build (sp, pc);
+}
+
static void
fprint_dummy_frames (struct ui_file *file)
{
@@ -71,4 +71,10 @@ extern void register_dummy_frame_dtor (struct frame_id dummy_id, ptid_t ptid,
extern int find_dummy_frame_dtor (dummy_frame_dtor_ftype *dtor,
void *dtor_data);
+/* Default implementation of gdbarch_dummy_id. Generate a dummy frame_id
+ for THIS_FRAME assuming that the frame is a dummy frame. */
+
+extern struct frame_id default_dummy_id (struct gdbarch *gdbarch,
+ struct frame_info *this_frame);
+
#endif /* !defined (DUMMY_FRAME_H) */
@@ -1438,18 +1438,6 @@ frv_unwind_sp (struct gdbarch *gdbarch, struct frame_info *next_frame)
return frame_unwind_register_unsigned (next_frame, sp_regnum);
}
-
-/* Assuming THIS_FRAME is a dummy, return the frame ID of that dummy
- frame. The frame ID's base needs to match the TOS value saved by
- save_dummy_frame_tos(), and the PC match the dummy frame's breakpoint. */
-
-static struct frame_id
-frv_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- CORE_ADDR sp = get_frame_register_unsigned (this_frame, sp_regnum);
- return frame_id_build (sp, get_frame_pc (this_frame));
-}
-
static struct gdbarch *
frv_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
{
@@ -1541,7 +1529,6 @@ frv_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
/* Settings for calling functions in the inferior. */
set_gdbarch_push_dummy_call (gdbarch, frv_push_dummy_call);
- set_gdbarch_dummy_id (gdbarch, frv_dummy_id);
/* Settings that should be unnecessary. */
set_gdbarch_inner_than (gdbarch, core_addr_lessthan);
@@ -559,14 +559,6 @@ static const struct frame_base ft32_frame_base =
ft32_frame_base_address
};
-static struct frame_id
-ft32_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- CORE_ADDR sp = get_frame_register_unsigned (this_frame, FT32_SP_REGNUM);
-
- return frame_id_build (sp, get_frame_pc (this_frame));
-}
-
/* Allocate and initialize the ft32 gdbarch object. */
static struct gdbarch *
@@ -614,11 +606,6 @@ ft32_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
frame_base_set_default (gdbarch, &ft32_frame_base);
- /* Methods for saving / extracting a dummy frame's ID. The ID's
- stack address must match the SP value returned by
- PUSH_DUMMY_CALL, and saved by generic_save_dummy_frame_tos. */
- set_gdbarch_dummy_id (gdbarch, ft32_dummy_id);
-
/* Hook in ABI-specific overrides, if they have been registered. */
gdbarch_init_osabi (info, gdbarch);
@@ -49,6 +49,7 @@
#include "objfiles.h"
#include "auxv.h"
#include "frame-unwind.h"
+#include "dummy-frame.h"
/* Static function declarations */
@@ -408,6 +409,7 @@ gdbarch_alloc (const struct gdbarch_info *info,
gdbarch->ecoff_reg_to_regnum = no_op_reg_to_regnum;
gdbarch->sdb_reg_to_regnum = no_op_reg_to_regnum;
gdbarch->dwarf2_reg_to_regnum = no_op_reg_to_regnum;
+ gdbarch->dummy_id = default_dummy_id;
gdbarch->deprecated_fp_regnum = -1;
gdbarch->call_dummy_location = AT_ENTRY_POINT;
gdbarch->code_of_frame_writable = default_code_of_frame_writable;
@@ -575,7 +577,7 @@ verify_gdbarch (struct gdbarch *gdbarch)
if (gdbarch->register_name == 0)
log.puts ("\n\tregister_name");
/* Skip verify of register_type, has predicate. */
- /* Skip verify of dummy_id, has predicate. */
+ /* Skip verify of dummy_id, invalid_p == 0 */
/* Skip verify of deprecated_fp_regnum, invalid_p == 0 */
/* Skip verify of push_dummy_call, has predicate. */
/* Skip verify of call_dummy_location, invalid_p == 0 */
@@ -954,9 +956,6 @@ gdbarch_dump (struct gdbarch *gdbarch, struct ui_file *file)
fprintf_unfiltered (file,
"gdbarch_dump: dtrace_probe_is_enabled = <%s>\n",
host_address_to_string (gdbarch->dtrace_probe_is_enabled));
- fprintf_unfiltered (file,
- "gdbarch_dump: gdbarch_dummy_id_p() = %d\n",
- gdbarch_dummy_id_p (gdbarch));
fprintf_unfiltered (file,
"gdbarch_dump: dummy_id = <%s>\n",
host_address_to_string (gdbarch->dummy_id));
@@ -2318,13 +2317,6 @@ set_gdbarch_register_type (struct gdbarch *gdbarch,
gdbarch->register_type = register_type;
}
-int
-gdbarch_dummy_id_p (struct gdbarch *gdbarch)
-{
- gdb_assert (gdbarch != NULL);
- return gdbarch->dummy_id != NULL;
-}
-
struct frame_id
gdbarch_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
{
@@ -383,8 +383,6 @@ typedef struct type * (gdbarch_register_type_ftype) (struct gdbarch *gdbarch, in
extern struct type * gdbarch_register_type (struct gdbarch *gdbarch, int reg_nr);
extern void set_gdbarch_register_type (struct gdbarch *gdbarch, gdbarch_register_type_ftype *register_type);
-extern int gdbarch_dummy_id_p (struct gdbarch *gdbarch);
-
typedef struct frame_id (gdbarch_dummy_id_ftype) (struct gdbarch *gdbarch, struct frame_info *this_frame);
extern struct frame_id gdbarch_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame);
extern void set_gdbarch_dummy_id (struct gdbarch *gdbarch, gdbarch_dummy_id_ftype *dummy_id);
@@ -483,7 +483,7 @@ m;const char *;register_name;int regnr;regnr;;0
# use "register_type".
M;struct type *;register_type;int reg_nr;reg_nr
-M;struct frame_id;dummy_id;struct frame_info *this_frame;this_frame
+m;struct frame_id;dummy_id;struct frame_info *this_frame;this_frame;;default_dummy_id;;0
# Implement DUMMY_ID and PUSH_DUMMY_CALL, then delete
# deprecated_fp_regnum.
v;int;deprecated_fp_regnum;;;-1;-1;;0
@@ -1649,6 +1649,7 @@ cat <<EOF
#include "objfiles.h"
#include "auxv.h"
#include "frame-unwind.h"
+#include "dummy-frame.h"
/* Static function declarations */
@@ -98,13 +98,6 @@ h8300_unwind_sp (struct gdbarch *gdbarch, struct frame_info *next_frame)
return frame_unwind_register_unsigned (next_frame, E_SP_REGNUM);
}
-static struct frame_id
-h8300_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- CORE_ADDR sp = get_frame_register_unsigned (this_frame, E_SP_REGNUM);
- return frame_id_build (sp, get_frame_pc (this_frame));
-}
-
/* Normal frames. */
/* Allocate and initialize a frame cache. */
@@ -1348,7 +1341,6 @@ h8300_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
/* Frame unwinder. */
set_gdbarch_unwind_sp (gdbarch, h8300_unwind_sp);
- set_gdbarch_dummy_id (gdbarch, h8300_dummy_id);
frame_base_set_default (gdbarch, &h8300_frame_base);
/*
@@ -2513,14 +2513,6 @@ static const struct frame_unwind hppa_stub_frame_unwind = {
hppa_stub_unwind_sniffer
};
-static struct frame_id
-hppa_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- return frame_id_build (get_frame_register_unsigned (this_frame,
- HPPA_SP_REGNUM),
- get_frame_pc (this_frame));
-}
-
CORE_ADDR
hppa_unwind_pc (struct gdbarch *gdbarch, struct frame_info *next_frame)
{
@@ -3163,7 +3155,6 @@ hppa_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_pseudo_register_read (gdbarch, hppa_pseudo_register_read);
/* Frame unwind methods. */
- set_gdbarch_dummy_id (gdbarch, hppa_dummy_id);
set_gdbarch_unwind_pc (gdbarch, hppa_unwind_pc);
/* Hook in ABI-specific overrides, if they have been registered. */
@@ -440,13 +440,6 @@ iq2000_unwind_sp (struct gdbarch *gdbarch, struct frame_info *next_frame)
return frame_unwind_register_unsigned (next_frame, E_SP_REGNUM);
}
-static struct frame_id
-iq2000_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- CORE_ADDR sp = get_frame_register_unsigned (this_frame, E_SP_REGNUM);
- return frame_id_build (sp, get_frame_pc (this_frame));
-}
-
static CORE_ADDR
iq2000_frame_base_address (struct frame_info *this_frame, void **this_cache)
{
@@ -835,7 +828,6 @@ iq2000_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_register_type (gdbarch, iq2000_register_type);
set_gdbarch_frame_align (gdbarch, iq2000_frame_align);
set_gdbarch_unwind_sp (gdbarch, iq2000_unwind_sp);
- set_gdbarch_dummy_id (gdbarch, iq2000_dummy_id);
frame_base_set_default (gdbarch, &iq2000_frame_base);
set_gdbarch_push_dummy_call (gdbarch, iq2000_push_dummy_call);
@@ -388,14 +388,6 @@ lm32_unwind_sp (struct gdbarch *gdbarch, struct frame_info *next_frame)
return frame_unwind_register_unsigned (next_frame, SIM_LM32_SP_REGNUM);
}
-static struct frame_id
-lm32_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- CORE_ADDR sp = get_frame_register_unsigned (this_frame, SIM_LM32_SP_REGNUM);
-
- return frame_id_build (sp, get_frame_pc (this_frame));
-}
-
/* Put here the code to store, into fi->saved_regs, the addresses of
the saved registers of frame described by FRAME_INFO. This
includes special registers such as pc and fp saved in special ways
@@ -546,7 +538,6 @@ lm32_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_frame_align (gdbarch, lm32_frame_align);
frame_base_set_default (gdbarch, &lm32_frame_base);
set_gdbarch_unwind_sp (gdbarch, lm32_unwind_sp);
- set_gdbarch_dummy_id (gdbarch, lm32_dummy_id);
frame_unwind_append_unwinder (gdbarch, &lm32_frame_unwind);
/* Breakpoints. */
@@ -864,18 +864,6 @@ static const struct frame_base m32r_frame_base = {
m32r_frame_base_address
};
-/* Assuming THIS_FRAME is a dummy, return the frame ID of that dummy
- frame. The frame ID's base needs to match the TOS value saved by
- save_dummy_frame_tos(), and the PC match the dummy frame's breakpoint. */
-
-static struct frame_id
-m32r_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- CORE_ADDR sp = get_frame_register_unsigned (this_frame, M32R_SP_REGNUM);
- return frame_id_build (sp, get_frame_pc (this_frame));
-}
-
-
static gdbarch_init_ftype m32r_gdbarch_init;
static struct gdbarch *
@@ -920,11 +908,6 @@ m32r_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
frame_base_set_default (gdbarch, &m32r_frame_base);
- /* Methods for saving / extracting a dummy frame's ID. The ID's
- stack address must match the SP value returned by
- PUSH_DUMMY_CALL, and saved by generic_save_dummy_frame_tos. */
- set_gdbarch_dummy_id (gdbarch, m32r_dummy_id);
-
/* Hook in ABI-specific overrides, if they have been registered. */
gdbarch_init_osabi (info, gdbarch);
@@ -350,15 +350,6 @@ m88k_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
/* Return the stack pointer. */
return sp;
}
-
-static struct frame_id
-m88k_dummy_id (struct gdbarch *arch, struct frame_info *this_frame)
-{
- CORE_ADDR sp;
-
- sp = get_frame_register_unsigned (this_frame, M88K_R31_REGNUM);
- return frame_id_build (sp, get_frame_pc (this_frame));
-}
/* Determine, for architecture GDBARCH, how a return value of TYPE
@@ -835,7 +826,6 @@ m88k_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
/* Call dummy code. */
set_gdbarch_push_dummy_call (gdbarch, m88k_push_dummy_call);
- set_gdbarch_dummy_id (gdbarch, m88k_dummy_id);
/* Return value info. */
set_gdbarch_return_value (gdbarch, m88k_return_value);
@@ -2333,15 +2333,6 @@ mep_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
return sp;
}
-
-static struct frame_id
-mep_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- CORE_ADDR sp = get_frame_register_unsigned (this_frame, MEP_SP_REGNUM);
- return frame_id_build (sp, get_frame_pc (this_frame));
-}
-
-
/* Initialization. */
@@ -2470,7 +2461,6 @@ mep_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
/* Inferior function calls. */
set_gdbarch_frame_align (gdbarch, mep_frame_align);
set_gdbarch_push_dummy_call (gdbarch, mep_push_dummy_call);
- set_gdbarch_dummy_id (gdbarch, mep_dummy_id);
return gdbarch;
}
@@ -1099,15 +1099,6 @@ mn10300_frame_base (struct frame_info *this_frame, void **this_prologue_cache)
}
}
-/* Here is a dummy implementation. */
-static struct frame_id
-mn10300_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- CORE_ADDR sp = get_frame_register_unsigned (this_frame, E_SP_REGNUM);
- CORE_ADDR pc = get_frame_register_unsigned (this_frame, E_PC_REGNUM);
- return frame_id_build (sp, pc);
-}
-
static void
mn10300_frame_this_id (struct frame_info *this_frame,
void **this_prologue_cache,
@@ -1164,7 +1155,6 @@ mn10300_frame_unwind_init (struct gdbarch *gdbarch)
{
dwarf2_append_unwinders (gdbarch);
frame_unwind_append_unwinder (gdbarch, &mn10300_frame_unwind);
- set_gdbarch_dummy_id (gdbarch, mn10300_dummy_id);
set_gdbarch_unwind_sp (gdbarch, mn10300_unwind_sp);
}
@@ -622,14 +622,6 @@ static const struct frame_base moxie_frame_base = {
moxie_frame_base_address
};
-static struct frame_id
-moxie_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- CORE_ADDR sp = get_frame_register_unsigned (this_frame, MOXIE_SP_REGNUM);
-
- return frame_id_build (sp, get_frame_pc (this_frame));
-}
-
/* Parse the current instruction and record the values of the registers and
memory that will be changed in current instruction to "record_arch_list".
Return -1 if something wrong. */
@@ -1102,11 +1094,6 @@ moxie_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
frame_base_set_default (gdbarch, &moxie_frame_base);
- /* Methods for saving / extracting a dummy frame's ID. The ID's
- stack address must match the SP value returned by
- PUSH_DUMMY_CALL, and saved by generic_save_dummy_frame_tos. */
- set_gdbarch_dummy_id (gdbarch, moxie_dummy_id);
-
/* Hook in ABI-specific overrides, if they have been registered. */
gdbarch_init_osabi (info, gdbarch);
@@ -643,18 +643,6 @@ msp430_frame_align (struct gdbarch *gdbarch, CORE_ADDR sp)
}
-/* Implement the "dummy_id" gdbarch method. */
-
-static struct frame_id
-msp430_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- return
- frame_id_build (get_frame_register_unsigned
- (this_frame, MSP430_SP_REGNUM),
- get_frame_pc (this_frame));
-}
-
-
/* Implement the "push_dummy_call" gdbarch method. */
static CORE_ADDR
@@ -993,7 +981,6 @@ msp430_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
frame_unwind_append_unwinder (gdbarch, &msp430_unwind);
/* Dummy frames, return values. */
- set_gdbarch_dummy_id (gdbarch, msp430_dummy_id);
set_gdbarch_push_dummy_call (gdbarch, msp430_push_dummy_call);
set_gdbarch_return_value (gdbarch, msp430_return_value);
@@ -1388,16 +1388,6 @@ static const struct frame_unwind nds32_epilogue_frame_unwind =
nds32_epilogue_frame_sniffer
};
-/* Implement the "dummy_id" gdbarch method. */
-
-static struct frame_id
-nds32_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- CORE_ADDR sp = get_frame_register_unsigned (this_frame, NDS32_SP_REGNUM);
-
- return frame_id_build (sp, get_frame_pc (this_frame));
-}
-
/* Implement the "unwind_sp" gdbarch method. */
static CORE_ADDR
@@ -2138,7 +2128,6 @@ nds32_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_push_dummy_call (gdbarch, nds32_push_dummy_call);
set_gdbarch_return_value (gdbarch, nds32_return_value);
- set_gdbarch_dummy_id (gdbarch, nds32_dummy_id);
set_gdbarch_skip_prologue (gdbarch, nds32_skip_prologue);
set_gdbarch_inner_than (gdbarch, core_addr_lessthan);
@@ -1798,16 +1798,6 @@ nios2_return_value (struct gdbarch *gdbarch, struct value *function,
return RETURN_VALUE_REGISTER_CONVENTION;
}
-/* Implement the dummy_id gdbarch method. */
-
-static struct frame_id
-nios2_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- return frame_id_build
- (get_frame_register_unsigned (this_frame, NIOS2_SP_REGNUM),
- get_frame_pc (this_frame));
-}
-
/* Implement the push_dummy_call gdbarch method. */
static CORE_ADDR
@@ -2310,7 +2300,6 @@ nios2_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_breakpoint_kind_from_pc (gdbarch, nios2_breakpoint_kind_from_pc);
set_gdbarch_sw_breakpoint_from_kind (gdbarch, nios2_sw_breakpoint_from_kind);
- set_gdbarch_dummy_id (gdbarch, nios2_dummy_id);
set_gdbarch_unwind_sp (gdbarch, nios2_unwind_sp);
/* The dwarf2 unwinder will normally produce the best results if
@@ -788,15 +788,6 @@ or1k_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
return sp;
}
-
-/* Implement the dummy_id gdbarch method. */
-
-static struct frame_id
-or1k_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- return frame_id_build (get_frame_sp (this_frame),
- get_frame_pc (this_frame));
-}
/* Support functions for frame handling. */
@@ -1184,7 +1175,6 @@ or1k_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_call_dummy_location (gdbarch, ON_STACK);
set_gdbarch_push_dummy_code (gdbarch, or1k_push_dummy_code);
set_gdbarch_push_dummy_call (gdbarch, or1k_push_dummy_call);
- set_gdbarch_dummy_id (gdbarch, or1k_dummy_id);
/* Frame unwinders. Use DWARF debug info if available, otherwise use our
own unwinder. */
@@ -2333,15 +2333,6 @@ riscv_unwind_sp (struct gdbarch *gdbarch, struct frame_info *next_frame)
return frame_unwind_register_unsigned (next_frame, RISCV_SP_REGNUM);
}
-/* Implement the dummy_id gdbarch method. */
-
-static struct frame_id
-riscv_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- return frame_id_build (get_frame_register_signed (this_frame, RISCV_SP_REGNUM),
- get_frame_pc (this_frame));
-}
-
/* Generate, or return the cached frame cache for the RiscV frame
unwinder. */
@@ -2545,7 +2536,6 @@ riscv_gdbarch_init (struct gdbarch_info info,
set_gdbarch_call_dummy_location (gdbarch, ON_STACK);
set_gdbarch_push_dummy_code (gdbarch, riscv_push_dummy_code);
set_gdbarch_push_dummy_call (gdbarch, riscv_push_dummy_call);
- set_gdbarch_dummy_id (gdbarch, riscv_dummy_id);
/* Frame unwinders. Use DWARF debug info if available, otherwise use our own
unwinder. */
@@ -3255,14 +3255,6 @@ find_variant_by_arch (enum bfd_architecture arch, unsigned long mach)
}
-static struct frame_id
-rs6000_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- return frame_id_build (get_frame_register_unsigned
- (this_frame, gdbarch_sp_regnum (gdbarch)),
- get_frame_pc (this_frame));
-}
-
struct rs6000_frame_cache
{
CORE_ADDR base;
@@ -6573,7 +6565,6 @@ rs6000_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
case GDB_OSABI_UNKNOWN:
frame_unwind_append_unwinder (gdbarch, &rs6000_epilogue_frame_unwind);
frame_unwind_append_unwinder (gdbarch, &rs6000_frame_unwind);
- set_gdbarch_dummy_id (gdbarch, rs6000_dummy_id);
frame_base_append_sniffer (gdbarch, rs6000_frame_base_sniffer);
break;
default:
@@ -6581,7 +6572,6 @@ rs6000_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
frame_unwind_append_unwinder (gdbarch, &rs6000_epilogue_frame_unwind);
frame_unwind_append_unwinder (gdbarch, &rs6000_frame_unwind);
- set_gdbarch_dummy_id (gdbarch, rs6000_dummy_id);
frame_base_append_sniffer (gdbarch, rs6000_frame_base_sniffer);
}
@@ -761,15 +761,6 @@ rx_unwind_sp (struct gdbarch *gdbarch, struct frame_info *this_frame)
return sp;
}
-/* Implement the "dummy_id" gdbarch method. */
-static struct frame_id
-rx_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- return
- frame_id_build (get_frame_register_unsigned (this_frame, RX_SP_REGNUM),
- get_frame_pc (this_frame));
-}
-
/* Implement the "push_dummy_call" gdbarch method. */
static CORE_ADDR
rx_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
@@ -1137,7 +1128,6 @@ rx_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
/* Methods for saving / extracting a dummy frame's ID.
The ID's stack address must match the SP value returned by
PUSH_DUMMY_CALL, and saved by generic_save_dummy_frame_tos. */
- set_gdbarch_dummy_id (gdbarch, rx_dummy_id);
set_gdbarch_push_dummy_call (gdbarch, rx_push_dummy_call);
set_gdbarch_return_value (gdbarch, rx_return_value);
@@ -472,14 +472,6 @@ score_return_value (struct gdbarch *gdbarch, struct value *function,
}
}
-static struct frame_id
-score_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- return frame_id_build (get_frame_register_unsigned (this_frame,
- SCORE_SP_REGNUM),
- get_frame_pc (this_frame));
-}
-
static int
score_type_needs_double_align (struct type *type)
{
@@ -1512,7 +1504,6 @@ score_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
/* Dummy frame hooks. */
set_gdbarch_return_value (gdbarch, score_return_value);
set_gdbarch_call_dummy_location (gdbarch, AT_ENTRY_POINT);
- set_gdbarch_dummy_id (gdbarch, score_dummy_id);
set_gdbarch_push_dummy_call (gdbarch, score_push_dummy_call);
/* Normal frame hooks. */
@@ -1983,14 +1983,6 @@ sh_unwind_sp (struct gdbarch *gdbarch, struct frame_info *next_frame)
gdbarch_sp_regnum (gdbarch));
}
-static struct frame_id
-sh_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- CORE_ADDR sp = get_frame_register_unsigned (this_frame,
- gdbarch_sp_regnum (gdbarch));
- return frame_id_build (sp, get_frame_pc (this_frame));
-}
-
static CORE_ADDR
sh_frame_base_address (struct frame_info *this_frame, void **this_cache)
{
@@ -2304,7 +2296,6 @@ sh_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_frame_align (gdbarch, sh_frame_align);
set_gdbarch_unwind_sp (gdbarch, sh_unwind_sp);
- set_gdbarch_dummy_id (gdbarch, sh_dummy_id);
frame_base_set_default (gdbarch, &sh_frame_base);
set_gdbarch_stack_frame_destroyed_p (gdbarch, sh_stack_frame_destroyed_p);
@@ -2319,14 +2319,6 @@ sh64_unwind_sp (struct gdbarch *gdbarch, struct frame_info *next_frame)
gdbarch_sp_regnum (gdbarch));
}
-static struct frame_id
-sh64_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- CORE_ADDR sp = get_frame_register_unsigned (this_frame,
- gdbarch_sp_regnum (gdbarch));
- return frame_id_build (sp, get_frame_pc (this_frame));
-}
-
static CORE_ADDR
sh64_frame_base_address (struct frame_info *this_frame, void **this_cache)
{
@@ -2414,7 +2406,6 @@ sh64_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_frame_align (gdbarch, sh64_frame_align);
set_gdbarch_unwind_sp (gdbarch, sh64_unwind_sp);
- set_gdbarch_dummy_id (gdbarch, sh64_dummy_id);
frame_base_set_default (gdbarch, &sh64_frame_base);
set_gdbarch_print_registers_info (gdbarch, sh64_print_registers_info);
@@ -803,16 +803,6 @@ tic6x_return_value (struct gdbarch *gdbarch, struct value *function,
return RETURN_VALUE_REGISTER_CONVENTION;
}
-/* This is the implementation of gdbarch method dummy_id. */
-
-static struct frame_id
-tic6x_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- return frame_id_build
- (get_frame_register_unsigned (this_frame, TIC6X_SP_REGNUM),
- get_frame_pc (this_frame));
-}
-
/* Get the alignment requirement of TYPE. */
static int
@@ -1298,8 +1288,6 @@ tic6x_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_return_value (gdbarch, tic6x_return_value);
- set_gdbarch_dummy_id (gdbarch, tic6x_dummy_id);
-
/* Enable inferior call support. */
set_gdbarch_push_dummy_call (gdbarch, tic6x_push_dummy_call);
@@ -936,17 +936,6 @@ tilegx_unwind_sp (struct gdbarch *gdbarch, struct frame_info *next_frame)
return frame_unwind_register_unsigned (next_frame, TILEGX_SP_REGNUM);
}
-static struct frame_id
-tilegx_unwind_dummy_id (struct gdbarch *gdbarch,
- struct frame_info *this_frame)
-{
- CORE_ADDR sp;
-
- sp = get_frame_register_unsigned (this_frame, TILEGX_SP_REGNUM);
- return frame_id_build (sp, get_frame_pc (this_frame));
-}
-
-
/* We cannot read/write the "special" registers. */
static int
@@ -1022,7 +1011,6 @@ tilegx_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
/* Frame Info. */
set_gdbarch_unwind_sp (gdbarch, tilegx_unwind_sp);
- set_gdbarch_dummy_id (gdbarch, tilegx_unwind_dummy_id);
set_gdbarch_frame_align (gdbarch, tilegx_frame_align);
frame_base_set_default (gdbarch, &tilegx_frame_base);
@@ -1333,14 +1333,6 @@ v850_unwind_sp (struct gdbarch *gdbarch, struct frame_info *next_frame)
gdbarch_sp_regnum (gdbarch));
}
-static struct frame_id
-v850_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- CORE_ADDR sp = get_frame_register_unsigned (this_frame,
- gdbarch_sp_regnum (gdbarch));
- return frame_id_build (sp, get_frame_pc (this_frame));
-}
-
static CORE_ADDR
v850_frame_base_address (struct frame_info *this_frame, void **this_cache)
{
@@ -1458,7 +1450,6 @@ v850_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_frame_align (gdbarch, v850_frame_align);
set_gdbarch_unwind_sp (gdbarch, v850_unwind_sp);
- set_gdbarch_dummy_id (gdbarch, v850_dummy_id);
frame_base_set_default (gdbarch, &v850_frame_base);
/* Hook in ABI-specific overrides, if they have been registered. */
@@ -757,14 +757,6 @@ xstormy16_unwind_sp (struct gdbarch *gdbarch, struct frame_info *next_frame)
return frame_unwind_register_unsigned (next_frame, E_SP_REGNUM);
}
-static struct frame_id
-xstormy16_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame)
-{
- CORE_ADDR sp = get_frame_register_unsigned (this_frame, E_SP_REGNUM);
- return frame_id_build (sp, get_frame_pc (this_frame));
-}
-
-
/* Function: xstormy16_gdbarch_init
Initializer function for the xstormy16 gdbarch vector.
Called by gdbarch. Sets up the gdbarch vector(s) for this target. */
@@ -819,7 +811,6 @@ xstormy16_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
* Frame Info
*/
set_gdbarch_unwind_sp (gdbarch, xstormy16_unwind_sp);
- set_gdbarch_dummy_id (gdbarch, xstormy16_dummy_id);
set_gdbarch_frame_align (gdbarch, xstormy16_frame_align);
frame_base_set_default (gdbarch, &xstormy16_frame_base);