Operating System - HP-UX
1752728 Members
5787 Online
108789 Solutions
New Discussion юеВ

Re: coredump at pthread_exit

 
SOLVED
Go to solution
Naveen Chandika
Occasional Advisor

coredump at pthread_exit

Hi,

I was getting coredump at pthread_exit. the following is the stack trace.

(gdb) thread 5
[Switching to thread 5 (system thread 1152548)]
#0 0x20000000614aa0f0:0 in real_free+0x7f0 () from /usr/lib/hpux32/libc.so.1
(gdb) bt
#0 0x20000000614aa0f0:0 in real_free+0x7f0 () from /usr/lib/hpux32/libc.so.1
#1 0x20000000614b6540:0 in free+0x180 () from /usr/lib/hpux32/libc.so.1
#2 0x2000000061388680:0 in __res_retrans_key_free+0xa0 ()
from /usr/lib/hpux32/libc.so.1
#3 0x20000000619b8be0:0 in __specific_data_thread_exit+0x4e0 ()
from /usr/lib/hpux32/libpthread.so.1
#4 0x20000000619dccb0:0 in pthread_exit+0x290 ()
from /usr/lib/hpux32/libpthread.so.1
#5 0x2000000061ace710:0 in PThread::Wrapper (ptrThis=0x4006a45c)
at /home03/users/pin102/testenv/exec/vpftst/G00R00C07/vpf/include/vpf_pthread.h:204
#6 0x20000000619da560:0 in __pthread_bound_body+0x190 ()
from /usr/lib/hpux32/libpthread.so.1

Can any one please tell me how to debug this further using gdb to know what its trying to free and failing?
4 REPLIES 4
Dennis Handly
Acclaimed Contributor

Re: coredump at pthread_exit

pthread_exit is just the victim here. Someone has corrupted the heap. You should use gdb's heap corruption detecting tools and rerun:
set heap-check on
Naveen Chandika
Occasional Advisor

Re: coredump at pthread_exit

Thank you.

Can you please let me know how to set heap corruption debug in gdb?
It would be great if you can send me some link for heap corruption debug in gdb.

Dennis Handly
Acclaimed Contributor
Solution

Re: coredump at pthread_exit

>Can you please let me know how to set heap corruption debug in gdb?

This is the basic command: set heap-check on
Download the latest wdb a and documentation at:
http://www.hp.com/go/wdb

Off of the documentation link are whitepapers:
Debugging dynamic memory usage errors using HP WDB
http://h21007.www2.hp.com/portal/download/files/unprot/devresource/Tools/wdb/doc/011310/memdebug-updated.pdf
Naveen Chandika
Occasional Advisor

Re: coredump at pthread_exit

Thank you very much