]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
Adjust gdb.base/memops-watchpoint.exp for Cygwin/Windows
authorPedro Alves <pedro@palves.net>
Tue, 11 Feb 2025 14:43:39 +0000 (14:43 +0000)
committerPedro Alves <pedro@palves.net>
Mon, 9 Jun 2025 17:09:21 +0000 (18:09 +0100)
commit7a3ca126fe6b43a04a7a47930b0f6dac41e9f299
tree2271802937a8691a1402f39c212690f3c31aa5f9
parent9634d445ad93e696c2447618e8a8cab3d59f4973
Adjust gdb.base/memops-watchpoint.exp for Cygwin/Windows

When testing gdb.base/memops-watchpoint.exp on Cygwin, I see:

 ...
 continue
 Continuing.

 Thread 1 "memops-watchpoint" hit Hardware watchpoint 2: -location a[28]

 Old value = 104 'h'
 New value = 0 '\000'
 memset () at /usr/src/debug/cygwin-3.5.4-1/winsup/cygwin/x86_64/memset.S:68
 68              rep     stosq
 (gdb) FAIL: gdb.base/memops-watchpoint.exp: continue until memset watchpoint hits

Etc.

This fails on Windows because there all inferiors are multi-threaded
(because both Windows and the Cygwin runtime spawn helper threads), so
we always see the

  'Thread N "foo" hit'

prefix, which the testcase isn't expecting.

Fix it by optionally expecting such the "Thread ... hit" prefix bit.

Change-Id: Ia06eaf1e152f512f39324d04298e6784eca3e537
gdb/testsuite/gdb.base/memops-watchpoint.exp