1748021 Members
5002 Online
108757 Solutions
New Discussion юеВ

Re: exception coredump

 
jackie_siu
Advisor

exception coredump

Dear all,
Following is my trouble:
OS:HP-UX 11.23 v2
Compiler:HP aC++ Compiler (S800) C.11.23.03
Key word: multi-thread
Description: we meet coredump when running our application,and it cores at the same position. but we can't understand,because the coredump position is a new clause,as follows:

auto_ptr pUsrAccumNode ( new UsrAccumInfo );

in class UsrAccumInfo instructor code is:

UsrAccumInfo::UsrAccumInfo(){
_AccumFee = 0;
}

as _AccumFee is an integer.

and when we put much cout message in our application, as we think it slows the application, the coredump disappears.

at the same time ,we all confirm that our application has nothing with the sequence of our input data,but when we change the sequence of the data in our application, the coredump also disappears.
So unimaginable! and I ned your help!
7 REPLIES 7
Dennis Handly
Acclaimed Contributor

Re: exception coredump

HP-UX 11.23 v2, HP aC++ Compiler (S800) C.11.23.03

This info isn't that useful. What is the version of your compiler? aCC -V
The secret decoder ring indicates it is A.03.60.
http://h21007.www2.hp.com/dspp/tech/tech_TechSoftwareDetailPage_IDX/1,1703,1743,00.html

>but we can't understand, because the coredump position is a new clause, as follows:
auto_ptr pUsrAccumNode(new UsrAccumInfo);

You could be failing because of out of space? You need to use gdb and get a stack trace.

>Key word: multi-thread

Have you compiled your application with -mt?
jackie_siu
Advisor

Re: exception coredump

Hi Dennis,
I haven't got the core information for some days. but now I caught it again.
HP-UX 11.23 v2, HP aC++ Compiler (S800) C.11.23.03

This info isn't that useful. What is the version of your compiler? aCC -V
The secret decoder ring indicates it is A.03.60.
http://h21007.www2.hp.com/dspp/tech/tech_TechSoftwareDetailPage_IDX/1,1703,174
3,00.html

---The following is my aC++ version info
---aCC: HP aC++/ANSI C B3910B A.06.00 [Aug 25 2004]

---I can't access the link you provide for me,can you give me a new link?

>but we can't understand, because the coredump position is a new clause, as follows:
auto_ptr pUsrAccumNode(new UsrAccumInfo);

You could be failing because of out of space? You need to use gdb and get a stack trace.

--As the coredump didn't appear when the program just startup, I can't use gdb to get the stack trace. Actually,
I got coredump after I have handled many files. But it cored at different files it handled,even though i have
removed the file when the coredump appeared, it cored at the other file position. For the application,it cored
still at the position when the desturctor invoked.

>Key word: multi-thread

Have you compiled your application with -mt?
--Yes, I have use -mt option.
jackie_siu
Advisor

Re: exception coredump

the following is the gdb result when the core occurs:
#0 0xc000000000233bf0:0 in free+0x1d0 () from /usr/lib/hpux64/libc.so.1
(gdb) where
#0 0xc000000000233bf0:0 in free+0x1d0 () from /usr/lib/hpux64/libc.so.1
#1 0xc000000002ab1550:0 in operator delete+0x50 ()
from /usr/lib/hpux64/libCsup.so.1
#2 0xc000000004ec8020:0 in DC_UsrAccumInfo::~DC_UsrAccumInfo+0x100 ()
from /billing/wangxm/apps/dll/libDCFavor.sl
#3 0xc0000000029a5b30:0 in DC_DataCarrier::~DC_DataCarrier (this=0x0,
No.Identifier=0x0) at DataCarrier.cpp:55
#4 0xc0000000029a64d0:0 in DC_DataCarrier::~DC_DataCarrier+0x30 ()
at DataCarrier.cpp:0
#5 0x400000000021d540:0 in DC_FlowScheduler::dataDispatch (this=0x0,
workFlow=0x600000006b39cba0, taskSeq=1610612736, data=0x600000006b39cba0)
at /opt/aCC/include_std/rw/stdmutex.h:491
#6 0x4000000000216940:0 in DC_SingleWork::dataDispatch (this=0x0, data=0x0)
at SingleTask.cpp:268
#7 0x4000000000216890:0 in DC_SingleWorkActions::DataDispatch (task=0x0,
data=0x0) at SingleTask.cpp:40
#8 0xc0000000053a93a0:0 in DC_WriteFile::process (this=0x0, dataCarrier=0x0,
task=0x0) at SoWriteCdrFile.cpp:819
#9 0x4000000000213780:0 in DC_SingleWork::run (this=0x0) at SingleTask.cpp:233
#10 0xc000000002a63750:0 in OpenThreads::DC_ThreadPrivateActions::StartThread (
data=0x9fffffffbf70f500) at Thread.cpp:115
#11 0xc0000000000b83c0:0 in __pthread_bound_body+0x190 () at DataCarrier.cpp:8
Dennis Handly
Acclaimed Contributor

Re: exception coredump

>The following is my aC++ version info
>aCC: HP aC++/ANSI C A.06.00 [Aug 25 2004]

This is very old and no longer supported, you should at least patch up to A.06.01, PHSS_31857. The latest compiler is A.06.14.

>I can't access the link you provide for me, can you give me a new link?

Sorry, the links were changed just last week:
http://h21007.www2.hp.com/portal/site/dspp/menuitem.863c3e4cbcdc3f3515b49c108973a801/?ciid=8b080f1bace021100f1bace02110275d6e10RCRD

>I can't use gdb to get the stack trace. I got coredump after I have handled many files.

As you found, you can use gdb on a core file.

>But it cored at different files it handled, even though i have removed the file when the coredump appeared, it cored at the other file position. For the application, it cored
still at the position when the destructor invoked.

Anything in common?

If you get a signal in free, you have corrupted the heap. Or have a thread stack overflow.

You have several frames where it indicates that the "this" pointer is 0, that should never happen.

#0 0xc000000000233bf0:0 in free+0x1d0 /usr/lib/hpux64/libc.so.1
#1 0xc000000002ab1550:0 in operator delete+0x50 libCsup.so.1
#2 0xc000000004ec8020:0 in DC_UsrAccumInfo::~DC_UsrAccumInfo+0x100
libDCFavor.sl
#3 0xc0000000029a5b30:0 in DC_DataCarrier::~DC_DataCarrier(this=0x0,)
#5 0x400000000021d540:0 in DC_FlowScheduler::dataDispatch(this=0x0,
#6 0x4000000000216940:0 in DC_SingleWork::dataDispatch(this=0x0,
#8 0xc0000000053a93a0:0 in DC_WriteFile::process(this=0x0,
#9 0x4000000000213780:0 in DC_SingleWork::run (this=0x0)
jackie_siu
Advisor

Re: exception coredump

I have got the reason why my application sometimes coredump. It's because some configuration I have set is fault.
But I still thanks a lot for your help.
jackie_siu
Advisor

Re: exception coredump

thanks a lot
Dennis Handly
Acclaimed Contributor

Re: exception coredump

>It's because some configuration I have set is fault.

You might want to mention what it was so everyone will know for next time. Was it a thread stack overflow?