| Thank you very much for answering fast and sorry for the delay on answering
back.
If have been offsite for a few days and could not get your replay till this
monday.
The only thing required to get the daemon instrumented was to make it exit.
The -taso is required by the library lipcicsepico.so and using the parameter
"-heapbase taso" produces an instrumented application which runs fine.
However I do not find the third output very explicit about memory leaks. Most
of the entries are related with pthead calls and two relate to functions I do
not explicitly call: _gethostbyname and setlocale
All other messages seem to be unrelated with the explicit code and related to
pthread operations. Most of the leaked memory seems to be in pthread
operations.
Do they indicate undestroyed pthread objects ?
Is it possible that this messages show threads not properly
detached or some misoperation on them ?
Is there some other information on using third in a multithreaded program ?
The following is the application .3log file as obtained from the compile
command.
The heap history is also available in case it can make clearer the meaning of
this file.
Thanks in advance
Ricardo Lopez Cencerrado
>>>
cd /usr/users/ricardo/cicsepi/
make -f test2.mk hstcom_c.third
cc -c -taso -std1 -threads -I/usr/opt/cics/include -g2 cicserver.child-fork.c
ld /usr/ccs/lib/crt0.o -taso -call_shared -L/usr/opt/cics/lib -o hstcom_c
cicserver.child-fork.o -lcicsepico -L/us
r/opt/dce/usr/shlib/dce -lpthreads -lmach -lc_r -lc
atom hstcom_c -tool third -env threads -L/usr/opt/cics/lib
-L/usr/opt/dce/usr/shlib -heapbase taso
atom: Warning: Shared library '/usr/opt/dce/usr/shlib/libdce.so' has very old
relocations, ignored.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc254, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc260, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc264, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc26c, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc270, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc274, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc2b8, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc2c8, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc2d4, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc2d8, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc2dc, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc2e8, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc318, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc31c, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc320, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc330, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc334, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc338, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc33c, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc340, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc344, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc348, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc34c, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc350, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc354, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc358, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc35c, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc360, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc364, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc368, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc36c, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc388, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc408, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc40c, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc414, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc418, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc41c, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc420, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc434, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc43c, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc444, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc46c, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc490, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc494, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc4a0, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc4a4, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc4b0, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc4b4, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc4d4, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc4e0, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc4e4, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc4f4, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc4e4, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc4f4, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc508, treating as data.
atom: Warning: Object '/usr/opt/cics/lib/libcicsco.so' has invalid instruction
at 0x6fefc50c, treating as data.
Compilation finished at Tue Jan 28 17:58:08
<<<<
The daemon has been modified to stop accepting client conections after the
fith.
Each conection is served by a thread. The daemon cancels, joins and detachs
all
threads on end. The 3log file corresponding to this test is:
<<<
Third Degree version 4.2
hstcom_c.third run by ricardo on dc227.sqo.dec.com, Tue Jan 28 18:08:55 1997
////////////// begin /usr/users/ricardo/.third ///////////////////
-----------------------------------------------
heap_history yes
-----------------------------------------------
////////////// end /usr/users/ricardo/.third ///////////////////
---------------------------------------------------------------- fon -- 0 --
calling free(0)
free libpthreads.so
setlocale libc_r.so
----- -----
----- -----
----- -----
------------------------------------------------------------------------
------------------------------------------------------------------------
Searching for new leaks in heap after program exit
A total of 75929 bytes in 107 leaks were found:
59820 bytes in 70 leaks (including 37 super leaks) created at:
malloc libpthreads.so
----- -----
----- -----
----- -----
8193 bytes in 1 leak (including 1 super leak) created at:
malloc libpthreads.so
pc = 0x2418424c libc.so
pc = 0x24183c38 libc.so
__gethostbyname libc.so
----- -----
----- -----
----- -----
3232 bytes in 1 leak (including 1 super leak) created at:
malloc libpthreads.so
cma__alloc_mem libpthreads.so
cma_key_create libpthreads.so
pthread_keycreate libpthreads.so
----- -----
----- -----
----- -----
1008 bytes in 7 leaks created at:
malloc libpthreads.so
cma__alloc_mem libpthreads.so
cma__vp_create libpthreads.so
cma__int_make_thread libpthreads.so
pthread_create libpthreads.so
----- -----
----- -----
----- -----
864 bytes in 6 leaks (including 2 super leaks) created at:
malloc libpthreads.so
cma__alloc_mem libpthreads.so
cma__get_stack libpthreads.so
pc = 0x2404b854 libpthreads.so
cma__get_tcb libpthreads.so
pthread_create libpthreads.so
----- -----
----- -----
----- -----
576 bytes in 4 leaks (including 3 super leaks) created at:
malloc libpthreads.so
cma__alloc_mem libpthreads.so
cma__vp_create libpthreads.so
cma__int_make_thread libpthreads.so
pthread_create libpthreads.so
AddTerminal hstcom_c, cicserver.child-fork.c, line 1793
doEPIecho hstcom_c, cicserver.child-fork.c, line 1891
ParentThreadMain hstcom_c, cicserver.child-fork.c, line 2523
cma__thread_base libpthreads.so
576 bytes in 4 leaks created at:
malloc libpthreads.so
cma__alloc_mem libpthreads.so
cma__vp_create libpthreads.so
cma__int_make_thread libpthreads.so
pthread_create libpthreads.so
main hstcom_c, cicserver.child-fork.c, line 831
__start hstcom_c
432 bytes in 3 leaks (including 3 super leaks) created at:
malloc libpthreads.so
cma__alloc_mem libpthreads.so
cma__get_stack libpthreads.so
pc = 0x2404b854 libpthreads.so
cma__get_tcb libpthreads.so
pthread_create libpthreads.so
AddTerminal hstcom_c, cicserver.child-fork.c, line 1793
doEPIecho hstcom_c, cicserver.child-fork.c, line 1891
ParentThreadMain hstcom_c, cicserver.child-fork.c, line 2523
cma__thread_base libpthreads.so
432 bytes in 3 leaks created at:
malloc libpthreads.so
cma__alloc_mem libpthreads.so
cma__get_stack libpthreads.so
pc = 0x2404b854 libpthreads.so
cma__get_tcb libpthreads.so
pthread_create libpthreads.so
main hstcom_c, cicserver.child-fork.c, line 831
__start hstcom_c
432 bytes in 3 leaks (including 1 super leak) created at:
malloc libpthreads.so
cma__alloc_mem libpthreads.so
cma__get_attr libpthreads.so
pthread_attr_create libpthreads.so
----- -----
----- -----
----- -----
364 bytes in 5 leaks (including 4 super leaks) below threshold of 1.0%
------------------------------------------------------------------------
------------------------------------------------------------------------
[Posted by WWW Notes gateway]
|