[Converted from Gnats 1650] manythreads.exp makes gdb cough up an internal error. berman/fsf/_today_/source/gdb/HEAD/src/gdb/lin-lwp.c:645: internal-error: wait_lwp: Assertion `lp->status == 0' failed.^M A problem internal to GDB has been detected,^M further debugging may prove unreliable.^M FAIL: gdb.threads/manythreads.exp: stop threads 1 (GDB internal error) Release: gdb HEAD 2004-05-10 00:22:49 UTC Environment: native i686-pc-linux-gnu, red hat 8.0 gdb HEAD 2004-05-10 00:22:49 UTC gcc 3.3.3, binutils 2.14.92, dwarf-2 glibc 2.2.93-5-rh kernel 2.4.18-14 How-To-Repeat: Run manythreads.exp 5 to 10 times.
From: mec.gnu@mindspring.com (Michael Elizabeth Chastain) To: gdb-gnats@sources.redhat.com Cc: Subject: Re: threads/1650 Date: Fri, 14 May 2004 15:20:06 -0400 (EDT) Here is a gdb.log section. This bug is a regression from gdb 6.1. gdb 6.1 and gdb gdb_6_1-branch run these tests fine. gdb HEAD and gdb drow_intercu-20040221-branch produce a lot of internal errors like this. Running /berman/fsf/_today_/source/gdb/HEAD/src/gdb/testsuite/gdb.threads/manythreads.exp ... Executing on host: gcc /berman/fsf/_today_/source/gdb/HEAD/src/gdb/testsuite/gdb.threads/manythreads.c -I/tmp/migbat-testgdb-2jzpc97q/test -gdwarf-2 -g2 -lpthreads -lm -o /tmp/migbat-testgdb-2jzpc97q/test/gdb.threads/manythreads (timeout = 300) /berman/migchain/install/target/native/binutils-2.14.92/bin/ld: cannot find -lpthreads collect2: ld returned 1 exit status compiler exited with status 1 output is: /berman/migchain/install/target/native/binutils-2.14.92/bin/ld: cannot find -lpthreads collect2: ld returned 1 exit status Executing on host: gcc /berman/fsf/_today_/source/gdb/HEAD/src/gdb/testsuite/gdb.threads/manythreads.c -I/tmp/migbat-testgdb-2jzpc97q/test -gdwarf-2 -g2 -lpthread -lm -o /tmp/migbat-testgdb-2jzpc97q/test/gdb.threads/manythreads (timeout = 300) PASS: gdb.threads/manythreads.exp: successfully compiled posix threads test case GNU gdb 2004-04-17-cvs 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 "i686-pc-linux-gnu". (gdb) set height 0 (gdb) set width 0 (gdb) dir Reinitialize source path to empty? (y or n) y Source directories searched: $cdir:$cwd (gdb) dir /berman/fsf/_today_/source/gdb/HEAD/src/gdb/testsuite/gdb.threads Source directories searched: /berman/fsf/_today_/source/gdb/HEAD/src/gdb/testsuite/gdb.threads:$cdir:$cwd (gdb) file /tmp/migbat-testgdb-2jzpc97q/test/gdb.threads/manythreads Reading symbols from /tmp/migbat-testgdb-2jzpc97q/test/gdb.threads/manythreads...done. Using host libthread_db library "/lib/libthread_db.so.1". (gdb) set print sevenbit-strings (gdb) PASS: gdb.threads/manythreads.exp: set print sevenbit-strings delete breakpoints (gdb) info breakpoints No breakpoints or watchpoints. (gdb) break main Breakpoint 1 at 0x804855d: file /berman/fsf/_today_/source/gdb/HEAD/src/gdb/testsuite/gdb.threads/manythreads.c, line 46. (gdb) run Starting program: /tmp/migbat-testgdb-2jzpc97q/test/gdb.threads/manythreads [Thread debugging using libthread_db enabled] [New Thread 8192 (LWP 17746)] [Switching to Thread 8192 (LWP 17746)] Breakpoint 1, main (argc=1, argv=0xbffff7c4) at /berman/fsf/_today_/source/gdb/HEAD/src/gdb/testsuite/gdb.threads/manythreads.c:46 46 pthread_attr_init (&attr); (gdb) shell stty intr '^C' (gdb) PASS: gdb.threads/manythreads.exp: shell stty intr '^C' continue Continuing. PASS: gdb.threads/manythreads.exp: first continue [New Thread 16385 (LWP 17749)] [New Thread 8194 (LWP 17750)] Thread <0> executing [New Thread 16387 (LWP 17751)] Thread <1> executing [Thread 8194 (LWP 17750) exited] [New Thread 24580 (LWP 17752)] [Thread 16387 (LWP 17751) exited] Thread <2> executing [New Thread 32773 (LWP 17753)] [Thread 24580 (LWP 17752) exited] Thread <3> executing [New Thread 40966 (LWP 17754)] [Thread 32773 (LWP 17753) exited] Thread <4> executing [New Thread 49159 (LWP 17755)] [Thread 40966 (LWP 17754) exited] Thread <5> executing [New Thread 57352 (LWP 17756)] [Thread 49159 (LWP 17755) exited] Thread <6> executing [New Thread 65545 (LWP 17757)] [Thread 57352 (LWP 17756) exited] Thread <7> executing [New Thread 73738 (LWP 17758)] [Thread 65545 (LWP 17757) exited] Thread <8> executing [New Thread 81931 (LWP 17759)] [Thread 73738 (LWP 17758) exited] Thread <9> executing [New Thread 90124 (LWP 17760)] Thread <10> executing [Thread 81931 (LWP 17759) exited] [New Thread 98317 (LWP 17761)] [Thread 90124 (LWP 17760) exited] Thread <11> executing [New Thread 106510 (LWP 17762)] Thread <12> executing [Thread 98317 (LWP 17761) exited] [New Thread 114703 (LWP 17763)] [Thread 106510 (LWP 17762) exited] Thread <13> executing [New Thread 122896 (LWP 17764)] Thread <14> executing [Thread 114703 (LWP 17763) exited] [New Thread 131089 (LWP 17765)] [Thread 122896 (LWP 17764) exited] Thread <15> executing [New Thread 139282 (LWP 17766)] Thread <16> executing [Thread 131089 (LWP 17765) exited] [New Thread 147475 (LWP 17767)] [Thread 139282 (LWP 17766) exited] Thread <17> executing [New Thread 155668 (LWP 17768)] [Thread 147475 (LWP 17767) exited] Thread <18> executing [New Thread 163861 (LWP 17769)] [Thread 155668 (LWP 17768) exited] Thread <19> executing [New Thread 172054 (LWP 17770)] [Thread 163861 (LWP 17769) exited] Thread <20> executing [New Thread 180247 (LWP 17771)] [Thread 172054 (LWP 17770) exited] Thread <21> executing [New Thread 188440 (LWP 17772)] Thread <22> executing [Thread 180247 (LWP 17771) exited] [New Thread 196633 (LWP 17773)] [Thread 188440 (LWP 17772) exited] Thread <23> executing [New Thread 204826 (LWP 17774)] [Thread 196633 (LWP 17773) exited] Thread <24> executing [New Thread 213019 (LWP 17775)] Thread <25> executing [Thread 204826 (LWP 17774) exited] [New Thread 221212 (LWP 17776)] [Thread 213019 (LWP 17775) exited] Thread <26> executing [New Thread 229405 (LWP 17777)] Thread <27> executing [Thread 229405 (LWP 17777) exited] [Thread 221212 (LWP 17776) exited] [New Thread 237598 (LWP 17778)] Thread <28> executing [Thread 237598 (LWP 17778) exited] [New Thread 245791 (LWP 17779)] Thread <29> executing [Thread 245791 (LWP 17779) exited] [New Thread 253984 (LWP 17780)] Thread <30> executing [Thread 253984 (LWP 17780) exited] [New Thread 262177 (LWP 17781)] Thread <31> executing [Thread 262177 (LWP 17781) exited] [New Thread 270370 (LWP 17782)] Thread <32> executing [Thread 270370 (LWP 17782) exited] [New Thread 278563 (LWP 17783)] Thread <33> executing [Thread 278563 (LWP 17783) exited] /berman/fsf/_today_/source/gdb/HEAD/src/gdb/lin-lwp.c:645: internal-error: wait_lwp: Assertion `lp->status == 0' failed. A problem internal to GDB has been detected, further debugging may prove unreliable. FAIL: gdb.threads/manythreads.exp: stop threads 1 (GDB internal error) Quit this debugging session? (y or n) n /berman/fsf/_today_/source/gdb/HEAD/src/gdb/lin-lwp.c:645: internal-error: wait_lwp: Assertion `lp->status == 0' failed. A problem internal to GDB has been detected, further debugging may prove unreliable. Create a core file of GDB? (y or n) n (gdb) info threads * 36 Thread 278563 (LWP 17783) 0x4002a090 in __linuxthreads_death_event () from /lib/i686/libpthread.so.0 2 Thread 16385 (LWP 17749) 0x420d224b in poll () from /lib/i686/libc.so.6 1 Thread 8192 (LWP 17746) 0x42028d69 in sigsuspend () from /lib/i686/libc.so.6 (gdb) PASS: gdb.threads/manythreads.exp: info threads continue Continuing. PASS: gdb.threads/manythreads.exp: second continue /berman/fsf/_today_/source/gdb/HEAD/src/gdb/lin-lwp.c:744: internal-error: stop_callback: Assertion `lp->status == 0' failed. A problem internal to GDB has been detected, further debugging may prove unreliable. FAIL: gdb.threads/manythreads.exp: stop threads 2 (GDB internal error) Quit this debugging session? (y or n) n /berman/fsf/_today_/source/gdb/HEAD/src/gdb/lin-lwp.c:744: internal-error: stop_callback: Assertion `lp->status == 0' failed. A problem internal to GDB has been detected, further debugging may prove unreliable. Create a core file of GDB? (y or n) n (gdb) quit The program is running. Exit anyway? (y or n) y PASS: gdb.threads/manythreads.exp: GDB exits after stopping multithreaded program testcase /berman/fsf/_today_/source/gdb/HEAD/src/gdb/testsuite/gdb.threads/manythreads.exp completed in 2 seconds
From: mec.gnu@mindspring.com (Michael Elizabeth Chastain) To: gdb-gnats@sources.redhat.com Cc: Subject: Re: threads/1650: manythreads.exp Date: Wed, 9 Jun 2004 23:00:42 -0400 (EDT) Between gdb HEAD 2004-06-03 17:47:54 UTC and gdb HEAD 2004-06-06 19:02:08 UTC, a new regression happened in manythreads.exp: (gdb) info threads * 39 Thread 303142 (LWP 26912) 0x4002a090 in __linuxthreads_death_event () from /lib/i686/libpthread.so.0 2 Thread 16385 (LWP 26875) 0x420d224b in poll () from /lib/i686/libc.so.6 1 Thread 8192 (LWP 26872) 0x42028d69 in sigsuspend () from /lib/i686/libc.so.6 (gdb) PASS: gdb.threads/manythreads.exp: info threads continue Continuing. PASS: gdb.threads/manythreads.exp: second continue FAIL: gdb.threads/manythreads.exp: stop threads 2 (timeout) quit Please answer y or n. /berman/fsf/_today_/source/gdb/HEAD/src/gdb/lin-lwp.c:744: internal-error: stop_callback: Assertion `lp->status == 0' failed. A problem internal to GDB has been detected, further debugging may prove unreliable. Quit this debugging session? (y or n) FAIL: gdb.threads/manythreads.exp: GDB exits after stopping multithreaded program (GDB internal error) n /berman/fsf/_today_/source/gdb/HEAD/src/gdb/lin-lwp.c:744: internal-error: stop_callback: Assertion `lp->status == 0' failed. A problem internal to GDB has been detected, further debugging may prove unreliable. Create a core file of GDB? (y or n) n (gdb) testcase /berman/fsf/_today_/source/gdb/HEAD/src/gdb/testsuite/gdb.threads/manythreads.exp completed in 33 seconds That makes four "GDB internal error" and "timeout" results with this script: gdb.threads/manythreads.exp: stop threads 1 (GDB internal error) gdb.threads/manythreads.exp: stop threads 2 (GDB internal error) gdb.threads/manythreads.exp: stop threads 2 (timeout) gdb.threads/manythreads.exp: GDB exits after stopping multithreaded program (GDB internal error) I am testing on native i686-pc-linux-gnu, red hat 8.0 glibc 2.2.93-5-rh. These are regression bugs in gdb. When I run manythreads.exp with gdb 6.1 or gdb gdb_6_1-branch, all tests PASS.
From: mec.gnu@mindspring.com (Michael Elizabeth Chastain) To: dan@debian.org, gdb-gnats@sources.redhat.com Cc: Subject: Re: threads/1650: manythreads.exp Date: Mon, 21 Jun 2004 12:30:16 -0400 (EDT) I narrowed the problem down to this patch: http://sources.redhat.com/ml/gdb-patches/2004-03/msg00672.html [patch] Use TD_DEATH and PTRACE_EVENT_CLONE when available I put some test tables at http://www.shout.net/~mec/sunday/pr-1650/index.html Daniel, can you take a look at this? This is with LinuxThreads (native i686-pc-linux-gnu, red hat 8.0, kernel 2.4.18-14 #1, glibc 2.2.93-5-rh). The disturbing part is that gdb 6.1 worked fine, but now gdb HEAD has intermittent failures. So it's a regression. Michael C
State-Changed-From-To: open->suspended State-Changed-Why: This is a linuxthreads problem. The same test on NPTL failed with 6.1 but works now.
From: chastain@sourceware.org To: gdb-gnats@sourceware.org Cc: Subject: threads/1650 Date: 27 Jul 2004 00:01:17 -0000 CVSROOT: /cvs/src Module name: src Changes by: chastain@sourceware.org 2004-07-27 00:01:17 Modified files: gdb : ChangeLog PROBLEMS Log message: 2004-07-26 Michael Chastain <mec.gnu@mindspring.com> Document PR threads/1650. * PROBLEMS (Threads): Document problem with many threads Patches: http://sources.redhat.com/cgi-bin/cvsweb.cgi/src/gdb/ChangeLog.diff?cvsroot=src&r1=1.6134&r2=1.6135 http://sources.redhat.com/cgi-bin/cvsweb.cgi/src/gdb/PROBLEMS.diff?cvsroot=src&r1=1.34&r2=1.35
From: Michael Chastain <mec.gnu@mindspring.com> To: gdb-gnats@sources.redhat.com Cc: Subject: Re: threads/1650: manythreads.exp Date: Mon, 26 Jul 2004 20:34:16 -0400 Some evidence gleaned from gdb-testers@, June and July: native alphaev67-dec-osf5.1 couldn't compile the thread tests, so no evidence either way native hppa??-??-linux-gnu manythreads.exp is okay native hppa2.0w-hp-hpux11.00 manythreads.exp reports these FAILs native i686-pc-cygwin manythreads.exp is okay native ia64-unknown-linux gnu gdb HEAD crashes several times timeouts in the threads tests; can't even tell if manythreads.exp is running because gdb.sum has plenty of "ERROR: internal buffer is full" nearby. native powerpc-ibm-aix4.3.3.0 couldn't compile the thread tests, so no evidence either way native powerpc-ibm-aix5.1.0.0 manythreads.exp reports these FAILS. native sparc-sun-solaris 2.8 couldn't compile this particular test, so no evidence either way native x86_64-unknown-linux-gnu couldn't compile this particular test, so no evidence either way
LinuxThreads support was removed. Also, even with NPTL, native Linux support no longer uses libthread_db's thread events.