diff options
Diffstat (limited to 'gdb/frame.c')
-rw-r--r-- | gdb/frame.c | 26 |
1 files changed, 10 insertions, 16 deletions
diff --git a/gdb/frame.c b/gdb/frame.c index 73895e2..9b95e9c 100644 --- a/gdb/frame.c +++ b/gdb/frame.c @@ -229,8 +229,7 @@ get_frame_id (struct frame_info *fi) /* Find the unwinder. */ if (fi->unwind == NULL) { - fi->unwind = frame_unwind_find_by_pc (current_gdbarch, - get_frame_pc (fi)); + fi->unwind = frame_unwind_find_by_frame (fi->next); /* FIXME: cagney/2003-04-02: Rather than storing the frame's type in the frame, the unwinder's type should be returned directly. Unfortunatly, legacy code, called by @@ -517,8 +516,7 @@ frame_register_unwind (struct frame_info *frame, int regnum, /* Find the unwinder. */ if (frame->unwind == NULL) { - frame->unwind = frame_unwind_find_by_pc (current_gdbarch, - get_frame_pc (frame)); + frame->unwind = frame_unwind_find_by_frame (frame->next); /* FIXME: cagney/2003-04-02: Rather than storing the frame's type in the frame, the unwinder's type should be returned directly. Unfortunatly, legacy code, called by @@ -1206,7 +1204,7 @@ create_new_frame (CORE_ADDR addr, CORE_ADDR pc) /* Select/initialize both the unwind function and the frame's type based on the PC. */ - fi->unwind = frame_unwind_find_by_pc (current_gdbarch, pc); + fi->unwind = frame_unwind_find_by_frame (fi->next); if (fi->unwind->type != UNKNOWN_FRAME) fi->type = fi->unwind->type; else @@ -1365,8 +1363,7 @@ legacy_get_prev_frame (struct frame_info *this_frame) /* Set the unwind functions based on that identified PC. Ditto for the "type" but strongly prefer the unwinder's frame type. */ - prev->unwind = frame_unwind_find_by_pc (current_gdbarch, - get_frame_pc (prev)); + prev->unwind = frame_unwind_find_by_frame (prev->next); if (prev->unwind->type == UNKNOWN_FRAME) prev->type = frame_type_from_pc (get_frame_pc (prev)); else @@ -1514,8 +1511,7 @@ legacy_get_prev_frame (struct frame_info *this_frame) to the new frame code. Implement FRAME_CHAIN the way the new frame will. */ /* Find PREV frame's unwinder. */ - prev->unwind = frame_unwind_find_by_pc (current_gdbarch, - frame_pc_unwind (this_frame)); + prev->unwind = frame_unwind_find_by_frame (this_frame->next); /* FIXME: cagney/2003-04-02: Rather than storing the frame's type in the frame, the unwinder's type should be returned directly. Unfortunatly, legacy code, called by @@ -1676,8 +1672,7 @@ legacy_get_prev_frame (struct frame_info *this_frame) If there isn't a FRAME_CHAIN, the code above will have already done this. */ if (prev->unwind == NULL) - prev->unwind = frame_unwind_find_by_pc (current_gdbarch, - get_frame_pc (prev)); + prev->unwind = frame_unwind_find_by_frame (prev->next); /* If the unwinder provides a frame type, use it. Otherwize continue on to that heuristic mess. */ @@ -2090,7 +2085,7 @@ get_frame_base_address (struct frame_info *fi) if (get_frame_type (fi) != NORMAL_FRAME) return 0; if (fi->base == NULL) - fi->base = frame_base_find_by_pc (current_gdbarch, get_frame_pc (fi)); + fi->base = frame_base_find_by_frame (fi->next); /* Sneaky: If the low-level unwind and high-level base code share a common unwinder, let them share the prologue cache. */ if (fi->base->unwind == fi->unwind) @@ -2106,7 +2101,7 @@ get_frame_locals_address (struct frame_info *fi) return 0; /* If there isn't a frame address method, find it. */ if (fi->base == NULL) - fi->base = frame_base_find_by_pc (current_gdbarch, get_frame_pc (fi)); + fi->base = frame_base_find_by_frame (fi->next); /* Sneaky: If the low-level unwind and high-level base code share a common unwinder, let them share the prologue cache. */ if (fi->base->unwind == fi->unwind) @@ -2124,7 +2119,7 @@ get_frame_args_address (struct frame_info *fi) return 0; /* If there isn't a frame address method, find it. */ if (fi->base == NULL) - fi->base = frame_base_find_by_pc (current_gdbarch, get_frame_pc (fi)); + fi->base = frame_base_find_by_frame (fi->next); /* Sneaky: If the low-level unwind and high-level base code share a common unwinder, let them share the prologue cache. */ if (fi->base->unwind == fi->unwind) @@ -2163,8 +2158,7 @@ get_frame_type (struct frame_info *frame) { /* Initialize the frame's unwinder because it is that which provides the frame's type. */ - frame->unwind = frame_unwind_find_by_pc (current_gdbarch, - get_frame_pc (frame)); + frame->unwind = frame_unwind_find_by_frame (frame->next); /* FIXME: cagney/2003-04-02: Rather than storing the frame's type in the frame, the unwinder's type should be returned directly. Unfortunatly, legacy code, called by |