Adjust gdb.thread/pthreads.exp for Cygwin
authorPedro Alves <pedro@palves.net>
Tue, 19 Sep 2023 11:26:26 +0000 (12:26 +0100)
committerPedro Alves <pedro@palves.net>
Wed, 27 Sep 2023 14:28:40 +0000 (15:28 +0100)
commitaeb889f580a270520d04d69a5fd72dd7fe11c61c
tree0eb8ab696a0be23536dc2a7c8fab6ef115b0df5a
parentb57264372264ebe6a8115028aa15c81af4fd98f1
Adjust gdb.thread/pthreads.exp for Cygwin

The Cygwin runtime spawns a few extra threads, so using hardcoded
thread numbers in tests rarely works correctly.  Thankfully, this
testcase already records the ids of the important threads in globals.
It just so happens that they are not used in a few tests.  This commit
fixes that.

With this, the test passes cleanly on Cygwin [1].  Still passes cleanly on
x86-64 GNU/Linux.

[1] - with system GDB.  Upstream GDB is missing a couple patches
Cygwin carries downstream.

Approved-By: Tom Tromey <tom@tromey.com>
Change-Id: I01bf71fcb44ceddea8bd16b933b10b964749a6af
gdb/testsuite/gdb.threads/pthreads.exp