Test attaching to a program that constantly spawns short-lived threads
authorPedro Alves <palves@redhat.com>
Wed, 17 Dec 2014 20:40:05 +0000 (20:40 +0000)
committerPedro Alves <palves@redhat.com>
Fri, 9 Jan 2015 11:44:04 +0000 (11:44 +0000)
commitc945a99f01941ccb3e73586d5e6f8d45ffa91f77
tree07a2cd4b196d1272a0deefe6fe08e2810624e4b6
parentc1a747c10948e2298083179f4e8aeed8b962e2af
Test attaching to a program that constantly spawns short-lived threads

Before the previous fixes, on Linux, this would trigger several
different problems, like:

 [New LWP 27106]
 [New LWP 27047]
 warning: unable to open /proc file '/proc/-1/status'
 [New LWP 27813]
 [New LWP 27869]
 warning: Can't attach LWP 11962: No child processes
 Warning: couldn't activate thread debugging using libthread_db: Cannot find new threads: debugger service failed
 warning: Unable to find libthread_db matching inferior's thread library, thread debugging will not be available.

gdb/testsuite/
2015-01-09  Pedro Alves  <palves@redhat.com>

* gdb.threads/attach-many-short-lived-threads.c: New file.
* gdb.threads/attach-many-short-lived-threads.exp: New file.
gdb/testsuite/ChangeLog
gdb/testsuite/gdb.threads/attach-many-short-lived-threads.c [new file with mode: 0644]
gdb/testsuite/gdb.threads/attach-many-short-lived-threads.exp [new file with mode: 0644]