From 9e81e9efee5e2e3e295b9bfd1c9f0718a244d926 Mon Sep 17 00:00:00 2001 From: Yichao Yu Date: Tue, 31 Oct 2017 11:52:22 -0400 Subject: [PATCH] arm: Handle non-signal frame unwind info lookup in ARM exidx unwinder (#55) --- src/arm/Gstep.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/arm/Gstep.c b/src/arm/Gstep.c index 6679455e..ae2f10f0 100644 --- a/src/arm/Gstep.c +++ b/src/arm/Gstep.c @@ -44,13 +44,16 @@ arm_exidx_step (struct cursor *c) /* mark PC unsaved */ c->dwarf.loc[UNW_ARM_R15] = DWARF_NULL_LOC; + unw_word_t ip = c->dwarf.ip; + if (c->dwarf.use_prev_instr) + --ip; /* check dynamic info first --- it overrides everything else */ - ret = unwi_find_dynamic_proc_info (c->dwarf.as, c->dwarf.ip, &c->dwarf.pi, 1, + ret = unwi_find_dynamic_proc_info (c->dwarf.as, ip, &c->dwarf.pi, 1, c->dwarf.as_arg); if (ret == -UNW_ENOINFO) { - if ((ret = tdep_find_proc_info (&c->dwarf, c->dwarf.ip, 1)) < 0) + if ((ret = tdep_find_proc_info (&c->dwarf, ip, 1)) < 0) return ret; }