From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13545 invoked by alias); 27 May 2002 01:43:01 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 13510 invoked from network); 27 May 2002 01:42:59 -0000 Received: from unknown (HELO mail.alinoe.com) (24.132.80.10) by sources.redhat.com with SMTP; 27 May 2002 01:42:59 -0000 Received: (qmail 8075 invoked by uid 500); 27 May 2002 01:42:55 -0000 Date: Sun, 26 May 2002 18:43:00 -0000 From: Carlo Wood To: liams@redhat.com, gdb@sources.redhat.com Subject: Re: gdb bugs showing while working on libcwd Message-ID: <20020527034255.A25457@alinoe.com> References: <20020522115242.C28512@redhat.com> <20020523153816.A4454@alinoe.com> <20020524114149.A2793@redhat.com> <20020524184234.A22858@alinoe.com> <20020525033302.A20587@alinoe.com> <20020525014055.GA27211@branoic.them.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20020525014055.GA27211@branoic.them.org>; from drow@mvista.com on Fri, May 24, 2002 at 09:40:55PM -0400 X-SW-Source: 2002-05/txt/msg00284.txt.bz2 Ok, got a new one. $ cd libcwd $ cvs update -r gdbbug02 $ ./bootstrap $ CXX="g++-3.1" CC="gcc-3.1" ./configure --enable-maintainer-mode --enable-debug --enable-debugt --enable-debugm --disable-debug-output $ make $ cd testsuite $ make module_r.so $ make threads_threads_shared $ ./threads_threads_shared Then I get: ~/c++/libcwd/testsuite>gdb threads_threads_shared core* GNU gdb 2002-05-25-cvs Copyright 2002 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 "i686-pc-linux-gnu"... warning: core file may not match specified executable file. Core was generated by `threads_threads_shared'. Program terminated with signal 11, Segmentation fault. Reading symbols from /home/carlo/c++/libcwd/.libs/libcwd_r.so.0...done. Loaded symbols for /home/carlo/c++/libcwd/.libs/libcwd_r.so.0 Reading symbols from /lib/libdl.so.2...done. Loaded symbols for /lib/libdl.so.2 Reading symbols from /usr/local/gcc-3.1/lib/libstdc++.so.4...done. Loaded symbols for /usr/local/gcc-3.1/lib/libstdc++.so.4 Reading symbols from /lib/libm.so.6...done. Loaded symbols for /lib/libm.so.6 Reading symbols from /usr/local/gcc-3.1/lib/libgcc_s.so.1...done. Loaded symbols for /usr/local/gcc-3.1/lib/libgcc_s.so.1 Reading symbols from /lib/libpthread.so.0...done. Loaded symbols for /lib/libpthread.so.0 Reading symbols from /lib/libc.so.6...done. Loaded symbols for /lib/libc.so.6 Reading symbols from /lib/ld-linux.so.2...done. Loaded symbols for /lib/ld-linux.so.2 #0 0x40078d3f in libcw::debug::debug_tsd_st::start(libcw::debug::debug_ct&, libcw::debug::channel_set_data_st&, libcw::debug::_private_::TSD_st&) (this=0x0, debug_object=@0x8074be8, channel_set=@0xbf7ff82c, __libcwd_tsd=@0x8075968) at debug.cc:801 801 LIBCWD_ASSERT( tsd_initialized ); (gdb) up #1 0x4007bdd0 in libcw::debug::_private_::assert_fail(char const*, char const*, int, char const*) ( expr=0x400bd160 "!__libcwd_tsd.internal || __libcwd_tsd.cancel_explicitely_disabled || __libcwd_tsd.cancel_explicitely_deferred", file=0x400bcdb5 "debugmalloc.cc", line=1894, function=0x400be980 "void* libcw::debug::_private_::new_memblk_map()") at debug.cc:1603 1603 DoutFatal(dc::core, file << ':' << line << ": " << function << ": Assertion `" << expr << "' failed.\n"); (gdb) p __libcwd_tsd $1 = (TSD_st &) @0x8075968: {internal = 1, library_call = 0, inside_malloc_or_free = 0, memblk_map = 0x0, marker = 0, recursive_fatal = false, recursive_assert = true, cancel_explicitely_deferred = 0, cancel_explicitely_disabled = 0, inside_critical_area = 0, cleanup_handler_installed = 0, internal_debugging_code = 1, tid = 1026, do_off_array = {0, 0, 0, 0, 0, 0, 0, 0}, do_array = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, off_cnt_array = {0 }, static S_exit_key = Internal: global symbol `_ZN5libcw5debug9_private_6TSD_st10S_exit_keyE' found in threading.cc psymtab but not in symtab. _ZN5libcw5debug9_private_6TSD_st10S_exit_keyE may be an inlined function, or may be a template function (if a template, try specifying an instantiation: _ZN5libcw5debug9_private_6TSD_st10S_exit_keyE). (gdb) _ZN5libcw5debug9_private_6TSD_st10S_exit_keyE is libcw::debug::_private_::TSD_st::S_exit_key A static member of struct TSD_st (in namespace libcw::debug::_private_) of type pthread_key_t. Hence, it is NOT a inlined function (or a function at all), nor is it a template. It is also very surely instantiated ;). Don't tell me this is related to namespaces too :/ -- Carlo Wood