Project Home
Project Home
Documents
Documents
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - btl_get_backtrace () crash: (2 Items)
   
btl_get_backtrace () crash  
Hi, 

I use malloc_g library, and try to catch the memory corruptions in our application. Sometimes, application crashed when 
doing btl_get_backtrace. Here is the back trace from core file:

Program terminated with signal 11, Segmentation fault.
#0  0xfe3ad9e4 in _malloc_error (fn=0xfe3b1bd4 "mprobe", lno=4265214988, msg=0xfe3b1b94 "underrun") at /home/builder/src
/lib/c/alloc/util.c:68
68      /home/builder/src/lib/c/alloc/util.c: No such file or directory.
        in /home/builder/src/lib/c/alloc/util.c
(gdb) bt
#0  0xfe3ad9e4 in _malloc_error (fn=0xfe3b1bd4 "mprobe", lno=4265214988, msg=0xfe3b1b94 "underrun") at /home/builder/src
/lib/c/alloc/util.c:68
#1  0xfe3ada6c in malloc_abort (status=MCHECK_HEAD) at /home/builder/src/lib/c/alloc/util.c:90
#2  0xfe3a260c in malloc_err_handler (level=1) at /home/builder/src/lib/malloc/dbg/malloc_g.c:1872
#3  0xfe3a040c in malloc_fatal (funcname=0xfe37ad6c "segmentation violation", file=0x0, line=-29695288, link=0x0) at /
home/builder/src/lib/malloc/dbg/malloc_g.c:1387
#4  0xfe39484c in malloc_signal_catcher (signo=11, info=0x4803f1e0, other=0x4803f248) at /home/builder/src/lib/malloc/
dbg/m_init.c:270
#5  <signal handler called>
#6  0xfe3ae2c8 in _btl_gather () from libmalloc.so.2
#7  0xfe3adc5c in btl_get_backtrace () from libmalloc.so.2
#8  0xfe38bc78 in backtrace (buffer=0xfe3ba510, size=5, caller_addr=1211391752) at /home/builder/src/lib/malloc/dbg/bt.c
:44
#9  0xfe39e3d4 in debug_malloc (file=0x0, line=1211391752, size=5344) at /home/builder/src/lib/malloc/dbg/malloc_g.c:848

#10 0xfe39dc74 in malloc (size=5344) at /home/builder/src/lib/malloc/dbg/malloc_g.c:645
#11 0x48345f0c in getifaddrs ()
#12 0x4833a91c in if_nametoindex ()
#13 0x4830047c in DAPI_init (init_mask=1280) at /home/p4admin/workspace/ne_rel2.1/ne/drivers/drv/lib/dapi.c:196
#14 0x480493d8 in nodemgr_init_hw () at /home/p4admin/workspace/ne_rel2.1/ne/apps/nodeMgr/bin/nodemgr_hw.c:44
#15 0x4804a7dc in main (argc=1, argv=0x4803fa44) at /home/p4admin/workspace/ne_rel2.1/ne/apps/nodeMgr/bin/nodemgr_main.c
:84

The line where it generates the sig 11,
0xfe3ae2c4 <_btl_gather+276>:   lwz     r0,0(r10)
0xfe3ae2c8 <_btl_gather+280>:   lwz     r9,4(r31)
0xfe3ae2cc <_btl_gather+284>:   and     r9,r0,r9

and why?
(gdb) info reg r31
r31            0xfffffffc       4294967292


Is this a known issue?

I also attached the core file, execute file and symbols.
Attachment: Text nodemgr.core1 5.24 MB
Re: btl_get_backtrace () crash  
yes.