aboutsummaryrefslogtreecommitdiff
path: root/gdb/arm-tdep.c
diff options
context:
space:
mode:
authorJerome Guitton <guitton@adacore.com>2003-09-29 13:27:39 +0000
committerJerome Guitton <guitton@adacore.com>2003-09-29 13:27:39 +0000
commite28a332c04863887b841fdd1a9042f78ea7a8264 (patch)
treea807b824f9dc721bd4aa7cf9b763b5baa04dd0cf /gdb/arm-tdep.c
parent1c0915057e6cb2285f23111ac2f638833a645900 (diff)
downloadbinutils-e28a332c04863887b841fdd1a9042f78ea7a8264.zip
binutils-e28a332c04863887b841fdd1a9042f78ea7a8264.tar.gz
binutils-e28a332c04863887b841fdd1a9042f78ea7a8264.tar.bz2
2003-09-29 Jerome Guitton <guitton@act-europe.fr>
* arm-tdep.c (arm_make_prologue_cache): Use trad_frame_addr_p to test if the register has been saved on the stack. (arm_scan_prologue_cache): When analysing the instruction "str lr, [sp, #-4]", save the address where lr has been stored.
Diffstat (limited to 'gdb/arm-tdep.c')
-rw-r--r--gdb/arm-tdep.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/gdb/arm-tdep.c b/gdb/arm-tdep.c
index 85e8258..102c4ba 100644
--- a/gdb/arm-tdep.c
+++ b/gdb/arm-tdep.c
@@ -845,7 +845,8 @@ arm_scan_prologue (struct frame_info *next_frame, struct arm_prologue_cache *cac
}
else if (insn == 0xe52de004) /* str lr, [sp, #-4]! */
{
- /* Function is frameless: extra_info defaults OK? */
+ sp_offset -= 4;
+ cache->saved_regs[ARM_LR_REGNUM].addr = sp_offset;
continue;
}
else if ((insn & 0xffff0000) == 0xe92d0000)
@@ -967,7 +968,7 @@ arm_make_prologue_cache (struct frame_info *next_frame)
/* Calculate actual addresses of saved registers using offsets
determined by arm_scan_prologue. */
for (reg = 0; reg < NUM_REGS; reg++)
- if (cache->saved_regs[reg].addr != 0)
+ if (trad_frame_addr_p (cache->saved_regs, reg))
cache->saved_regs[reg].addr += cache->prev_sp;
return cache;