[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#414606: marked as done (Stacktraces and deadlocked threads.)

Your message dated Thu, 12 Apr 2007 11:47:56 +0200
with message-id <461E004C.8080207@aurel32.net>
and subject line Closing bugs fixed in unreleased version 2.4-1 of the glibc
has caused the attached Bug report to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what I am
talking about this indicates a serious mail system misconfiguration
somewhere.  Please contact me immediately.)

Debian bug tracking system administrator
(administrator, Debian Bugs database)

--- Begin Message ---
Package: libc6
Version: 2.3.6.ds1-11

If a thread is involved in a deadlock, gdb reports a corrupt stack trace
for that thread.  This problem has been fixed in 2.5-0exp6, but it
sounds like 2.5 won't make it into etch.  Until then, libc6-dbg can be
used as a workaround since debugging versions of 2.3.6 use an older
pthreads implementation.

Can debugging in libc6 2.3.6 be fixed in time for etch?  If not,
libc6-dbg's package description probably should document the problem.
Doing so also would also (partially) address bug #399035 in time for
etch.  Replace:

Most people will not need this package.


This package also contains a older, less efficient, version of pthreads
with better debugging support.

Example session:

$ cat deadlock.c
#include <pthread.h>

int main(int argc, char** argv) {
   pthread_mutex_t lock = PTHREAD_MUTEX_INITIALIZER;

$ gcc -g -O0 deadlock.c -o deadlock -lpthread
$ gdb ./deadlock
(gdb) run
Starting program: /home/sears/deadlock/deadlock
Failed to read a valid object file image from memory.
[Thread debugging using libthread_db enabled]
[New Thread -1209542976 (LWP 9659)]

// program hangs as expected, hit ^C

Program received signal SIGINT, Interrupt.
[Switching to Thread -1209542976 (LWP 9659)]
0xb7fd5410 in ?? ()
(gdb) where
#0  0xb7fd5410 in ?? ()
#1  0xbfee9698 in ?? ()
#2  0x00000002 in ?? ()
#3  0x00000000 in ?? ()

libc6-dbg fixes the problem:

$ export LD_LIBRARY_PATH=/usr/lib/debug/
$ gdb ./deadlock
(gdb) run
Program received signal SIGINT, Interrupt.
[Switching to Thread 16384 (LWP 10826)]
0xb7f63b64 in __pthread_sigsuspend (set=0xbfa040f8) at
54      ../linuxthreads/sysdeps/unix/sysv/linux/pt-sigsuspend.c: No such
file or directory.
        in ../linuxthreads/sysdeps/unix/sysv/linux/pt-sigsuspend.c
(gdb) where
#0  0xb7f63b64 in __pthread_sigsuspend (set=0xbfa040f8)
    at ../linuxthreads/sysdeps/unix/sysv/linux/pt-sigsuspend.c:54
#1  0xb7f62728 in __pthread_wait_for_restart_signal (self=0x804a8c0) at
#2  0xb7f64fe6 in __pthread_alt_lock (lock=0xbfa04204, self=0x804a8c0)
at restart.h:34
#3  0xb7f621dc in *__GI___pthread_mutex_lock (mutex=0xbfa041f4) at
#4  0x080483ff in main () at deadlock.c:6

--- End Message ---
--- Begin Message ---
Version: 2.5-1

  .''`.  Aurelien Jarno	            | GPG: 1024D/F1BCDB73
 : :' :  Debian developer           | Electrical Engineer
 `. `'   aurel32@debian.org         | aurelien@aurel32.net
   `-    people.debian.org/~aurel32 | www.aurel32.net

--- End Message ---

Reply to: