aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite/gdb.threads/tls.exp
diff options
context:
space:
mode:
authorTom de Vries <tdevries@suse.de>2020-10-29 07:55:46 +0100
committerTom de Vries <tdevries@suse.de>2020-10-29 07:55:46 +0100
commit0ad0e70c73205da6daeb27d2cc1eeae3e54bd3d0 (patch)
tree88412f2e551899a21704ea865e9ff2b5a10e6d3e /gdb/testsuite/gdb.threads/tls.exp
parentf06c0d01f15b629fdc17096b3a33899108b9fbb1 (diff)
downloadbinutils-0ad0e70c73205da6daeb27d2cc1eeae3e54bd3d0.zip
binutils-0ad0e70c73205da6daeb27d2cc1eeae3e54bd3d0.tar.gz
binutils-0ad0e70c73205da6daeb27d2cc1eeae3e54bd3d0.tar.bz2
[gdb/testsuite] Fix DUPLICATEs in gdb.threads/tls.exp
With test-case gdb.threads/tls.exp, we get these: ... DUPLICATE: gdb.threads/tls.exp: selected thread: 4 DUPLICATE: gdb.threads/tls.exp: selected thread: 2 DUPLICATE: gdb.threads/tls.exp: selected thread: 3 ... Fix these using with_test_prefix. Tested on x86_64-linux. gdb/testsuite/ChangeLog: 2020-10-29 Tom de Vries <tdevries@suse.de> * gdb.threads/tls.exp: Fix DUPLICATEs.
Diffstat (limited to 'gdb/testsuite/gdb.threads/tls.exp')
-rw-r--r--gdb/testsuite/gdb.threads/tls.exp9
1 files changed, 7 insertions, 2 deletions
diff --git a/gdb/testsuite/gdb.threads/tls.exp b/gdb/testsuite/gdb.threads/tls.exp
index 8147a6c..77916e7 100644
--- a/gdb/testsuite/gdb.threads/tls.exp
+++ b/gdb/testsuite/gdb.threads/tls.exp
@@ -127,7 +127,9 @@ proc check_thread_stack {number spin_threads spin_threads_level} {
upvar $spin_threads tarr
upvar $spin_threads_level tarrl
- select_thread $number
+ with_test_prefix "thread stack" {
+ select_thread $number
+ }
send_gdb "where\n"
gdb_expect {
-re ".*(\[0-9\]+)\[ \t\]+$hex in spin \\(vp=(0x\[0-9a-f\]+).*\r\n$gdb_prompt $" {
@@ -257,7 +259,10 @@ set thrs_in_spin 0
foreach i [array names spin_threads] {
if {$spin_threads($i) == 1} {
incr thrs_in_spin
- select_thread $i
+
+ with_test_prefix "spin_threads" {
+ select_thread $i
+ }
set level $spin_threads_level($i)
# We expect to be in sem_wait, but if the thread has not yet
# been scheduled, we might be in sem_post still. We could be at