#984706 libunwind8: SIGSEGV in _ULarm_step on RPI 3B+

Package:
libunwind8
Source:
libunwind
Description:
library to determine the call-chain of a program - runtime
Submitter:
Tobias Diedrich
Date:
2021-03-07 13:42:04 UTC
Severity:
normal
#984706#5
Date:
2021-03-07 13:38:24 UTC
From:
To:
Dear Maintainer,

While trying to use heaptrack to debug a memory leak in lxpanel I found that libunwind8 which heaptrack is using seems to segfault on armhf.
In case it helps I've rebuilt libunwind8 manually with --enable-debug to get extra debug output below.

$ UNW_DEBUG_LEVEL=1 heaptrack --debug /usr/bin/lxpanel --profile ranma-test
heaptrack output will be written to "/home/pi/heaptrack.lxpanel.11000.gz"
starting application in GDB, this might take some time...
Reading symbols from /usr/bin/lxpanel...Reading symbols from /usr/lib/debug/.build-id/71/5b0db86f91aa93d2e1249a5232bebe16cfbf55.debug...done.
done.
Starting program: /usr/bin/lxpanel --profile ranma-test
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1".
[New Thread 0x7559c1f0 (LWP 11032)]
 >_ULarm_init_local: (cursor=0x7eff6f68)
 >_ULarm_tdep_trace: begin ip 0x762d26d4 cfa 0x7eff6f20
 >_ULarm_step: (cursor=0x7eff6f68)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_tdep_trace: returning -5, depth 0
 >_ULarm_init_local: (cursor=0x7effaf68)
 >_ULarm_step: (cursor=0x7effaf68)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf68)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf68)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf68)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_init_local: (cursor=0x7eff6f20)
 >_ULarm_tdep_trace: begin ip 0x762d26d4 cfa 0x7eff6ed8
 >_ULarm_tdep_trace: returning -5, depth 0
 >_ULarm_init_local: (cursor=0x7effaf20)
 >_ULarm_step: (cursor=0x7effaf20)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf20)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf20)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf20)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_init_local: (cursor=0x7eff6f28)
 >_ULarm_tdep_trace: begin ip 0x762d26d4 cfa 0x7eff6ee0
 >_ULarm_tdep_trace: returning -5, depth 0
 >_ULarm_init_local: (cursor=0x7effaf28)
 >_ULarm_step: (cursor=0x7effaf28)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf28)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf28)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf28)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_init_local: (cursor=0x7eff6f28)
 >_ULarm_tdep_trace: begin ip 0x762d26d4 cfa 0x7eff6ee0
 >_ULarm_tdep_trace: returning -5, depth 0
 >_ULarm_init_local: (cursor=0x7effaf28)
 >_ULarm_step: (cursor=0x7effaf28)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf28)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf28)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf28)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_init_local: (cursor=0x7eff6f68)
 >_ULarm_tdep_trace: begin ip 0x762d26d4 cfa 0x7eff6f20
 >_ULarm_tdep_trace: returning -5, depth 0
 >_ULarm_init_local: (cursor=0x7effaf68)
 >_ULarm_step: (cursor=0x7effaf68)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf68)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf68)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf68)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_init_local: (cursor=0x7eff6f68)
 >_ULarm_tdep_trace: begin ip 0x762d26d4 cfa 0x7eff6f20
 >_ULarm_tdep_trace: returning -5, depth 0
 >_ULarm_init_local: (cursor=0x7effaf68)
 >_ULarm_step: (cursor=0x7effaf68)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf68)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf68)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf68)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_init_local: (cursor=0x7eff6f80)
 >_ULarm_tdep_trace: begin ip 0x762d26d4 cfa 0x7eff6f38
 >_ULarm_tdep_trace: returning -5, depth 0
 >_ULarm_init_local: (cursor=0x7effaf80)
 >_ULarm_step: (cursor=0x7effaf80)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf80)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf80)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf80)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_init_local: (cursor=0x7eff6f20)
 >_ULarm_tdep_trace: begin ip 0x762d26d4 cfa 0x7eff6ed8
 >_ULarm_tdep_trace: returning -5, depth 0
 >_ULarm_init_local: (cursor=0x7effaf20)
 >_ULarm_step: (cursor=0x7effaf20)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf20)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf20)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf20)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf20)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_init_local: (cursor=0x7eff6f10)
 >_ULarm_tdep_trace: begin ip 0x762d26d4 cfa 0x7eff6ec8
 >_ULarm_tdep_trace: returning -5, depth 0
 >_ULarm_init_local: (cursor=0x7effaf10)
 >_ULarm_step: (cursor=0x7effaf10)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf10)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf10)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf10)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf10)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_init_local: (cursor=0x7eff6e50)
 >_ULarm_tdep_trace: begin ip 0x762d26d4 cfa 0x7eff6e08
 >_ULarm_tdep_trace: returning -5, depth 0
 >_ULarm_init_local: (cursor=0x7effae50)
 >_ULarm_step: (cursor=0x7effae50)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effae50)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effae50)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effae50)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_init_local: (cursor=0x7eff6f78)
 >_ULarm_tdep_trace: begin ip 0x762d26d4 cfa 0x7eff6f30
 >_ULarm_tdep_trace: returning -5, depth 0
 >_ULarm_init_local: (cursor=0x7effaf78)
 >_ULarm_step: (cursor=0x7effaf78)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf78)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf78)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf78)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_init_local: (cursor=0x7eff6f80)
 >_ULarm_tdep_trace: begin ip 0x762d26d4 cfa 0x7eff6f38
 >_ULarm_tdep_trace: returning -5, depth 0
 >_ULarm_init_local: (cursor=0x7effaf80)
 >_ULarm_step: (cursor=0x7effaf80)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf80)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf80)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf80)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_init_local: (cursor=0x7eff6f70)
 >_ULarm_tdep_trace: begin ip 0x762d26d4 cfa 0x7eff6f28
 >_ULarm_tdep_trace: returning -5, depth 0
 >_ULarm_init_local: (cursor=0x7effaf70)
 >_ULarm_step: (cursor=0x7effaf70)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf70)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf70)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf70)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_init_local: (cursor=0x7eff6f80)
 >_ULarm_tdep_trace: begin ip 0x762d26d4 cfa 0x7eff6f38
 >_ULarm_tdep_trace: returning -5, depth 0
 >_ULarm_init_local: (cursor=0x7effaf80)
 >_ULarm_step: (cursor=0x7effaf80)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf80)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf80)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf80)
 >_ULarm_init_local: (cursor=0x7eff6f80)
 >_ULarm_tdep_trace: begin ip 0x762d26d4 cfa 0x7eff6f38
 >_ULarm_tdep_trace: returning -5, depth 0
 >_ULarm_init_local: (cursor=0x7effaf80)
 >_ULarm_step: (cursor=0x7effaf80)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf80)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf80)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf80)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_init_local: (cursor=0x7eff6f28)
 >_ULarm_tdep_trace: begin ip 0x762d26d4 cfa 0x7eff6ee0
 >_ULarm_tdep_trace: returning -5, depth 0
 >_ULarm_init_local: (cursor=0x7effaf28)
 >_ULarm_step: (cursor=0x7effaf28)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf28)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf28)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaf28)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_init_local: (cursor=0x7eff6eb0)
 >_ULarm_tdep_trace: begin ip 0x762d26d4 cfa 0x7eff6e68
 >_ULarm_tdep_trace: returning -5, depth 0
 >_ULarm_init_local: (cursor=0x7effaeb0)
 >_ULarm_step: (cursor=0x7effaeb0)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaeb0)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaeb0)
 >_ULarm_step: dwarf_step()=-10
 >_ULarm_step: (cursor=0x7effaeb0)
 >_ULarm_step: dwarf_step()=-10

Thread 1 "lxpanel" received signal SIGSEGV, Segmentation fault.
_ULarm_step (cursor=cursor@entry=0x7effaeb0) at arm/Gstep.c:244
244     arm/Gstep.c: No such file or directory.
(gdb)

242           if (frame)
243             {
244 -->           if (dwarf_get(&c->dwarf, DWARF_LOC(frame, 0), &instr) < 0)
245                 {
246                   return 0;
247                 }
248               instr -= 8;

I also tried the bullseye version, it seems to have the same issue.