1
0
Fork 0
mirror of https://github.com/tobast/libunwind-eh_elf.git synced 2024-06-28 12:11:45 +02:00
libunwind-eh_elf/src
Paul Pluzhnikov 297d9cd07d Fix for failing test-setjmp
On Mon, Nov 14, 2011 at 5:02 PM, Paul Pluzhnikov <ppluzhnikov@google.com> wrote:

> P.S. test-setjmp is failing for me (before or after the patch).
> When I enable assertions (to confirm my new assertions are correct), I see:
>
>  lt-test-setjmp: ../../src/dwarf/Gparser.c:754: apply_reg_state: \
>    Assertion `rs->reg[17].where == DWARF_WHERE_EXPR' failed.
>
> which likely explains that failure.

The problem is actually two-fold:

First, the loops in {sig,}longjmp.c are "do { ... } while (unw_step() >= 0);"

But unw_step() returns 0 on reaching the end of the chain (_start),
and the loop should stop there.

The second problem is that with this commit:
  c67da0b50e
glibc obfuscates value of SP in jmp_buf, so we might as well just give up.

Patch attached.

Thanks,
--
Paul Pluzhnikov
2011-11-19 15:37:35 -08:00
..
arm Call dwarf_step only if CONFIG_DEBUG_FRAME is defined 2011-11-19 15:37:23 -08:00
dwarf Remove unused variable segbase 2011-11-12 10:02:09 -08:00
hppa Fix incorrect calls to memset. 2011-10-02 22:43:28 -07:00
ia64 Fix incorrect calls to memset. 2011-10-02 22:43:28 -07:00
mi Performance optimisations for fast trace. 2011-04-17 20:34:38 -07:00
mips Fix incorrect calls to memset. 2011-10-02 22:43:28 -07:00
ppc During the stack unwinding process, the return address points to 2010-04-24 19:16:09 -07:00
ppc32 Fast back-trace for x86_64 for only collecting the call stack. 2011-03-24 22:33:17 -07:00
ppc64 Fast back-trace for x86_64 for only collecting the call stack. 2011-03-24 22:33:17 -07:00
ptrace Prevent the use of struct dl_phdr_info outside of dl_iterate_phdr 2011-10-29 17:12:43 -07:00
setjmp Fix for failing test-setjmp 2011-11-19 15:37:35 -08:00
unwind GCC compatibility on x86 for C++ exception handling 2010-04-12 12:08:43 -07:00
x86 Fix incorrect calls to memset. 2011-10-02 22:43:28 -07:00
x86_64 Fix TLS destructor ordering problems 2011-10-29 17:12:36 -07:00
elf32.c Do nothing of UNW_REMOTE_ONLY is defined. 2003-02-15 03:10:30 +00:00
elf32.h Silence warning about symbol redefinition. 2010-03-07 17:27:41 +02:00
elf64.c Do nothing of UNW_REMOTE_ONLY is defined. 2003-02-15 03:10:30 +00:00
elf64.h Silence warning about symbol redefinition. 2010-03-07 17:27:41 +02:00
elfxx.c Improve ELF valid_object() helper 2011-01-23 17:21:04 -08:00
elfxx.h Add module for parsing ARM-specific unwind tables 2011-03-22 08:14:51 -07:00
Makefile.am Bump up the library version 2011-09-10 19:57:59 -07:00
os-freebsd.c Have tdep_get_elf_image available in case of UNW_REMOTE_ONLY 2011-10-15 23:10:28 -07:00
os-hpux.c Have tdep_get_elf_image available in case of UNW_REMOTE_ONLY 2011-10-15 23:10:28 -07:00
os-linux.c Have tdep_get_elf_image available in case of UNW_REMOTE_ONLY 2011-10-15 23:10:28 -07:00
os-linux.h Fix some compiler warnings 2011-10-29 17:18:49 -07:00