|
From: Alejandro C. <ac...@ig...> - 2004-10-22 12:56:29
|
Hi, I've been testing a CORBA program with valgrind, the program works well without valgrind but when I run the program using it I get a crash with the log I've attached to this mail. Does anyone know if this is a problem of valgrind? The warning messages look no good. An important point is that I've done the same test without threading support of the CORBA POA and everything seems to work well, valgrind doesn't find any problem in that case. Thank you in advance. -- Alejandro García Castro mailto: ac...@ig... http://www.igalia.com valgrind --db-attach=yes --alignment=8 --num-c ==24706== Memcheck, a memory error detector for x86-linux. ==24706== Copyright (C) 2002-2004, and GNU GPL'd, by Julian Seward et al. ==24706== Using valgrind-2.2.0, a program supervision framework for x86-linux. ==24706== Copyright (C) 2000-2004, and GNU GPL'd, by Julian Seward et al. ==24706== For more details, rerun with: -v ==24706== ==24706== warning: Valgrind's pthread_getschedparam is incomplete ==24706== your program may misbehave as a result ==24706== warning: Valgrind's pthread_attr_getschedparam is incomplete ==24706== your program may misbehave as a result ==24706== warning: Valgrind's pthread_attr_setschedparam does nothing ==24706== (scheduling not changeable) ==24706== your program may misbehave as a result ==24706== warning: Valgrind's pthread_attr_destroy does nothing ==24706== your program may misbehave as a result IOR:010000000d00000049444c3a4563686f3a312e3000000000040000000054424f580000000101020005000000554e4958000000000e00000061737572616e636574757269780000002a0000002f746d702f6f726269742d616c65782f6c696e632d363038322d302d3431623866346439383639376300000000000000000000003c000000010102000e00000061737572616e6365747572697800ec871c0000000100000075581804235bd49a2861b7db3c1ccd2401000000f19848e800000000caaedfba54000000010102002a0000002f746d702f6f726269742d616c65782f6c696e632d363038322d302d343162386634643938363937630000001c0000000100000075581804235bd49a2861b7db3c1ccd2401000000f19848e801000000480000000100000002000000050000001c0000000100000075581804235bd49a2861b7db3c1ccd2401000000f19848e801000000140000000100000001000105000000000901010000000000 ==24706== warning: Valgrind's pthread_attr_getschedparam is incomplete ==24706== your program may misbehave as a result ==24706== warning: Valgrind's pthread_attr_setschedparam does nothing ==24706== (scheduling not changeable) ==24706== your program may misbehave as a result ==24706== warning: Valgrind's pthread_attr_destroy does nothing ==24706== your program may misbehave as a result ==24706== warning: Valgrind's pthread_cond_destroy is incomplete ==24706== (it doesn't check if the cond is waited on) ==24706== your program may misbehave as a result ==24706== Thread 3: ==24706== Invalid read of size 1 ==24706== at 0x1BA746B9: _IO_vfprintf (in /lib/tls/libc-2.3.2.so) ==24706== by 0x1BA96262: vasprintf (in /lib/tls/libc-2.3.2.so) ==24706== by 0x1BBED61F: ??? ==24706== Address 0xBED5590C is not stack'd, malloc'd or (recently) free'd ==24706== ==24706== ---- Attach to debugger ? --- [Return/N/n/Y/y/C/c] ---- y starting debugger ==24706== starting debugger with cmd: /usr/bin/gdb -nw /proc/24714/fd/821 24714 GNU gdb 6.1-debian Copyright 2004 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "i386-linux"...Warning: /usr/local/src/jhbuild_installation: No existe el fichero o el directorio. Using host libthread_db library "/lib/tls/libthread_db.so.1". Attaching to program: /proc/24714/fd/821, process 24714 0x1ba746b9 in vfprintf () from /lib/tls/libc.so.6 (gdb) bt #0 0x1ba746b9 in vfprintf () from /lib/tls/libc.so.6 #1 0x1ba96263 in vasprintf () from /lib/tls/libc.so.6 #2 0x00000000 in ?? () #3 0x00000000 in ?? () #4 0x00000000 in ?? () #5 0x1ba003e0 in get_or_allocate_specifics_ptr (thread=3201653004) at vg_libpthread.c:1708 Previous frame inner to this frame (corrupt stack?) (gdb) q The program is running. Quit anyway (and detach it)? (y or n) y Detaching from program: /proc/24714/fd/821, process 24714 ==24706== ==24706== Debugger has detached. Valgrind regains control. We continue. ==24706== ==24706== Process terminating with default action of signal 11 (SIGSEGV) ==24706== Access not within mapped region at address 0xBED5590C ==24706== at 0x1BA746B9: _IO_vfprintf (in /lib/tls/libc-2.3.2.so) ==24706== by 0x1BA96262: vasprintf (in /lib/tls/libc-2.3.2.so) ==24706== by 0x1BBED61F: ??? ==24706== ==24706== ---- Attach to debugger ? --- [Return/N/n/Y/y/C/c] ---- y ==24706== starting debugger with cmd: /usr/bin/gdb -nw /proc/24718/fd/821 24718 GNU gdb 6.1-debian Copyright 2004 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "i386-linux"...Warning: /usr/local/src/jhbuild_installation: No existe el fichero o el directorio. Using host libthread_db library "/lib/tls/libthread_db.so.1". Attaching to program: /proc/24718/fd/821, process 24718 0x1ba746b9 in vfprintf () from /lib/tls/libc.so.6 (gdb) bt #0 0x1ba746b9 in vfprintf () from /lib/tls/libc.so.6 #1 0x1ba96263 in vasprintf () from /lib/tls/libc.so.6 #2 0x00000000 in ?? () #3 0x00000000 in ?? () #4 0x00000000 in ?? () #5 0x1ba003e0 in get_or_allocate_specifics_ptr (thread=3201653004) at vg_libpthread.c:1708 Previous frame inner to this frame (corrupt stack?) (gdb) q The program is running. Quit anyway (and detach it)? (y or n) y Detaching from program: /proc/24718/fd/821, process 24718 ==24706== ==24706== Debugger has detached. Valgrind regains control. We continue. ==24706== ==24706== ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 27 from 1) ==24706== malloc/free: in use at exit: 41083 bytes in 506 blocks. ==24706== malloc/free: 776 allocs, 270 frees, 225547 bytes allocated. ==24706== For a detailed leak analysis, rerun with: --leak-check=yes ==24706== For counts of detected errors, rerun with: -v Segmentation fault |
|
From: Nicholas N. <nj...@ca...> - 2004-10-22 13:44:24
|
On Fri, 22 Oct 2004, Alejandro Garc=EDa Castro wrote: > I've been testing a CORBA program with valgrind, the program works well > without valgrind but when I run the program using it I get a crash with t= he > log I've attached to this mail. Does anyone know if this is a problem of > valgrind? The warning messages look no good. An important point is that I= 've > done the same test without threading support of the CORBA POA and everyth= ing > seems to work well, valgrind doesn't find any problem in that case. The warnings probably aren't that important; Valgrind's pthreads=20 implementation doesn't implement some obscure functions fully, but usually= =20 this doesn't cause problems. As for the seg fault, it shouldn't happen (it would be great if you could= =20 post a bug to our bug database, see valgrind.kde.org/bugs.html) but it=20 takes place once your program has finished, just as Valgrind is finishing= =20 up, so it shouldn't affect the accuracy of the results. In other words, it looks like Valgrind has no complaints about your=20 program. N |
|
From: Alejandro C. <ac...@ig...> - 2004-10-22 14:28:49
|
El viernes 22 de octubre de 2004 a las 14:06:36 Nicholas Nethercote escribió: > > [...] > > As for the seg fault, it shouldn't happen (it would be great if you could > post a bug to our bug database, see valgrind.kde.org/bugs.html) but it > takes place once your program has finished, just as Valgrind is finishing > up, so it shouldn't affect the accuracy of the results. > > In other words, it looks like Valgrind has no complaints about your > program. > Ok, thanks. I've posted a bug, I've also uploaded a tar.gz file with a basic test and the steps to compile and execute it. http://bugs.kde.org/show_bug.cgi?id=91905 Greetings. -- Alejandro García Castro mailto: ac...@ig... http://www.igalia.com |