aboutsummaryrefslogtreecommitdiff
path: root/gdb/gdbarch.h
diff options
context:
space:
mode:
authorAndrew Cagney <cagney@redhat.com>2000-05-15 06:27:18 +0000
committerAndrew Cagney <cagney@redhat.com>2000-05-15 06:27:18 +0000
commitd1e3cf49987161b72dd638ff94a5fc3e1f684484 (patch)
treefb3689f10eea0c4158d27e4296c4b96792b61a8d /gdb/gdbarch.h
parentf23d52e0a54905bc88c1a5ea25168227356d6f37 (diff)
downloadgdb-d1e3cf49987161b72dd638ff94a5fc3e1f684484.zip
gdb-d1e3cf49987161b72dd638ff94a5fc3e1f684484.tar.gz
gdb-d1e3cf49987161b72dd638ff94a5fc3e1f684484.tar.bz2
Convert SAVE_DUMMY_FRAME_TOS to multi-arch.
Diffstat (limited to 'gdb/gdbarch.h')
-rw-r--r--gdb/gdbarch.h29
1 files changed, 29 insertions, 0 deletions
diff --git a/gdb/gdbarch.h b/gdb/gdbarch.h
index dde7c51..7121a22 100644
--- a/gdb/gdbarch.h
+++ b/gdb/gdbarch.h
@@ -1062,6 +1062,35 @@ extern void set_gdbarch_reg_struct_has_addr (struct gdbarch *gdbarch, gdbarch_re
#endif
#endif
+#if defined (SAVE_DUMMY_FRAME_TOS)
+/* Legacy for systems yet to multi-arch SAVE_DUMMY_FRAME_TOS */
+#define SAVE_DUMMY_FRAME_TOS_P() (1)
+#endif
+
+/* Default predicate for non- multi-arch targets. */
+#if (GDB_MULTI_ARCH == 0) && !defined (SAVE_DUMMY_FRAME_TOS_P)
+#define SAVE_DUMMY_FRAME_TOS_P() (0)
+#endif
+
+extern int gdbarch_save_dummy_frame_tos_p (struct gdbarch *gdbarch);
+#if (GDB_MULTI_ARCH > 1) || !defined (SAVE_DUMMY_FRAME_TOS_P)
+#define SAVE_DUMMY_FRAME_TOS_P() (gdbarch_save_dummy_frame_tos_p (current_gdbarch))
+#endif
+
+/* Default (function) for non- multi-arch platforms. */
+#if (GDB_MULTI_ARCH == 0) && !defined (SAVE_DUMMY_FRAME_TOS)
+#define SAVE_DUMMY_FRAME_TOS(sp) (internal_error ("SAVE_DUMMY_FRAME_TOS"), 0)
+#endif
+
+typedef void (gdbarch_save_dummy_frame_tos_ftype) (CORE_ADDR sp);
+extern void gdbarch_save_dummy_frame_tos (struct gdbarch *gdbarch, CORE_ADDR sp);
+extern void set_gdbarch_save_dummy_frame_tos (struct gdbarch *gdbarch, gdbarch_save_dummy_frame_tos_ftype *save_dummy_frame_tos);
+#if GDB_MULTI_ARCH
+#if (GDB_MULTI_ARCH > 1) || !defined (SAVE_DUMMY_FRAME_TOS)
+#define SAVE_DUMMY_FRAME_TOS(sp) (gdbarch_save_dummy_frame_tos (current_gdbarch, sp))
+#endif
+#endif
+
extern struct gdbarch_tdep *gdbarch_tdep (struct gdbarch *gdbarch);