0

In my application, when i run a job it completes and does not give any core dump or segmentation fault message on console . But when i go to the core directory i can see core dump file is created related to the job performed . I tried to debug that with mdb and what i got is the following .

 ::stack
 0x538548(190c, c1cf0, bffd8, 1800, be6cc, c1b7c)
 __SUNW_fini_iostreams+0xc(fe1f15e0, 0, 0, ff, 0, 0)
 libCrun.so.1`__1cH__CimplKcplus_fini6F_v_+0x74(4ee1c, 0, fe1ed4c4, 1, bfa70, fe352a00)
 libCrun.so.1`_init+0x54(1, 1cc4, fcc35980, fcc37300, fe352a00, 1c00)
 libc.so.1`_exithandle+0x40(fcc37580, fcc35980, 1c00, 19f8b4, 19f8b4, 2137cf)
 libc.so.1`exit+4(32, ffbddc24, 19f848, bec00, 19f848, 0)
 _start+0x110(0, 0, 0, 0, 0, 0)
 > ::dem __1cH__CimplKcplus_fini6F_v_+0x74
 __1cH__CimplKcplus_fini6F_v_+0x74 == void __Cimpl::cplus_fini
> ::dem __SUNW_fini_iostreams+0xc
__SUNW_fini_iostreams+0xc == __SUNW_fini_iostreams+0xc 

When i tried to print register and their values What i got was this :-

$? no process SIGILL: Illegal Instruction

%g5 = 0xfe744774 libcap_pdb.so.5`__1cRCAP_PDB_file_pathFcount_ %l5 = 0x00000fdc
%o1 = 0x00000001                 %i1 = 0x000c1cf0 
cna_adjust`__1cDstdIios_baseEInitJ__initcnt_
%o2 = 0x00038748                 %i2 = 0x000bffd8
%o3 = 0x00002c00                 %i3 = 0x00001800
%o4 = 0x000c1d58 jobtype`__1cDstdGlocaleU__the_classic_locale_ %i4 = 0x000be6cc
%o5 = 0x0000368c                 %i5 = 0x000c1b7c 
jobtype`__1cDstdQ__stderr_filebuf_+0x3c
%o6 = 0xffbdd978                 %i6 = 0xffbdd9d8
%o7 = 0x00055d50 __1cDstdGlocaleNfinal_cleanup6M_v_+0x64 %i7 = 0x0004ee28  
__SUNW_fini_iostreams+0xc

%psr = 0xfe001005 impl=0xf ver=0xe icc=nzvc
               ec=0 ef=4096 pil=0 s=0 ps=0 et=0 cwp=0x5
%y = 0x00000000
%pc = 0x00538548
%npc = 0x0053854c
%sp = 0xffbdd978
%fp = 0xffbdd9d8
%wim = 0x00000000
%tbr = 0x00000000
> ::dem __1cDstdGlocaleNfinal_cleanup6M_v_+0x64 %i7
__1cDstdGlocaleNfinal_cleanup6M_v_+0x64 == void std::locale::final_cleanup
%i7 == %i7
> ::dem __1cDstdGlocaleU__the_classic_locale_ %i4
__1cDstdGlocaleU__the_classic_locale_ == std::locale::__the_classic_locale
%i4 == %i4
> ::dem __1cFile_pathFcount_ %l5
__1cfile_pathFcount_ == file_path::count
%l5 == %l5

I believe that job run on my application has already finished successfully and the error was an issue while cleaning up the memory which was not freed in code as my application exit.This is my assumption on the basis of what i read about std::locale::final_cleanup from limited resources. I know its almost impossible for anyone to exactly point out what is happening here but I would like to know if my assumption is right from your experience . Also we had a change of compiler some time ago and we are facing this issue only after that. I saw this issue recently. Please also let me know about behavior of std::locale::final_cleanup and std::locale::__the_classic_locale functions

3
  • Anything with two underscores at the beginning (like __this) or an underscore and a capital letter (like _This) should never interest you, it's implementation specific.
    – Xeo
    May 7, 2012 at 17:42
  • 1
    The locale class has a static member classic() that returns a reference to the "classic" C locale. __the_classic_locale is likely what it returns a reference to.
    – Bo Persson
    May 7, 2012 at 18:24
  • @BoPersson what is the use of the function std::locale::final_cleanup . Is it used for cleaning up memories not freed by application during the exit process ?
    – Invictus
    May 7, 2012 at 18:26

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.