aboutsummaryrefslogtreecommitdiff
path: root/gdb/frame.h
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/frame.h')
-rw-r--r--gdb/frame.h26
1 files changed, 23 insertions, 3 deletions
diff --git a/gdb/frame.h b/gdb/frame.h
index 70d85f1..a371a58 100644
--- a/gdb/frame.h
+++ b/gdb/frame.h
@@ -139,6 +139,12 @@ extern void frame_read_unsigned_register (struct frame_info *frame,
extern int frame_map_name_to_regnum (const char *name, int strlen);
extern const char *frame_map_regnum_to_name (int regnum);
+/* Unwind the PC. Strictly speaking return the resume address of the
+ calling frame. For GDB, `pc' is the resume address and not a
+ specific register. */
+
+extern CORE_ADDR frame_pc_unwind (struct frame_info *frame);
+
/* Return the location (and possibly value) of REGNUM for the previous
(older, up) frame. All parameters except VALUEP can be assumed to
@@ -163,6 +169,12 @@ typedef void (frame_register_unwind_ftype) (struct frame_info *frame,
int *realnump,
void *valuep);
+/* Same as for registers above, but return the address at which the
+ calling frame would resume. */
+
+typedef CORE_ADDR (frame_pc_unwind_ftype) (struct frame_info *frame,
+ void **unwind_cache);
+
/* Describe the saved registers of a frame. */
#if defined (EXTRA_FRAME_INFO) || defined (FRAME_FIND_SAVED_REGS)
@@ -252,10 +264,18 @@ struct frame_info
related unwind data. */
struct context *context;
- /* See description above. Return the register value for the
- previous frame. */
+ /* Unwind cache shared between the unwind functions - they had
+ better all agree as to the contents. */
+ void *unwind_cache;
+
+ /* See description above. The previous frame's registers. */
frame_register_unwind_ftype *register_unwind;
- void *register_unwind_cache;
+
+ /* See description above. The previous frame's resume address.
+ Save the previous PC in a local cache. */
+ frame_pc_unwind_ftype *pc_unwind;
+ int pc_unwind_cache_p;
+ CORE_ADDR pc_unwind_cache;
/* Pointers to the next (down, inner, younger) and previous (up,
outer, older) frame_info's in the frame cache. */