Subject: bin/30756: gdb not usable for live debugging of threaded programs
To: None <gnats-admin@netbsd.org, netbsd-bugs@netbsd.org>
From: Thomas Klausner <wiz@NetBSD.org>
List: netbsd-bugs
Date: 07/15/2005 22:22:00
>Number: 30756
>Category: bin
>Synopsis: gdb not usable for live debugging of threaded programs
>Confidential: no
>Severity: critical
>Priority: medium
>Responsible: bin-bug-people
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Fri Jul 15 22:22:00 +0000 2005
>Originator: Thomas Klausner
>Release: NetBSD 3.99.7
>Organization:
>Environment:
Architecture: i386
Machine: i386
>Description:
Debugging threaded programs currently looks like this:
# gdb /usr/pkg/bin/amarokapp
GNU gdb 5.3nb1
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 "i386--netbsdelf"...(no debugging symbols found)...
(gdb) r
Starting program: /usr/pkg/bin/amarokapp
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...thread_resume_suspend_cb: td_thr_suspend(0xa3bc2c0): generic error.
[Switching to LWP 1]
Stopped due to shared library event
(gdb) c
Continuing.
thread_resume_suspend_cb: td_thr_suspend(0xa3bc2c0): generic error.
0xbdbf7444 in _rtld_debug_state () from /usr/libexec/ld.elf_so
(gdb) c
Continuing.
thread_resume_suspend_cb: td_thr_suspend(0xa3bc2c0): generic error.
0xbdbf7444 in _rtld_debug_state () from /usr/libexec/ld.elf_so
(gdb)
In the thread starting at
http://mail-index.netbsd.org/current-users/2005/06/23/0017.html
Nathan J. Williams suggests reverting 1.15 of
src/gnu/dist/gdb/gdb/nbsd-thread.c
which fixes this particular problem.
However, 1.15 was a fix for another real problem, and reverting it
is not a good solution. So we need another one :)
>How-To-Repeat:
See above.
>Fix:
Sorry, above my head.
>Unformatted: