[PATCH] Fix watchpoints with multiple threads on Windows

Tom Tromey tromey@adacore.com
Wed Oct 27 20:15:23 GMT 2021


>>>>> "Tom" == Tom Tromey via Gdb-patches <gdb-patches@sourceware.org> writes:

Tom> A recent internal change pointed out that watchpoints were not working
Tom> on Windows when the inferior was multi-threaded.  This happened
Tom> because the debug registers were only updated for certain threads --
Tom> in particular, those that were being resumed and that were not marked
Tom> as suspended.  In the case of single-stepping, the need to update the
Tom> debug registers in other threads could also be "forgotten".

Tom> This patch changes windows-nat.c to mark all threads needing a debug
Tom> register update.  This brings the code closer to what gdbserver does
Tom> (though, unfortunately, it still seems more complicated than needed).

I'm going to check this in now.

Tom


More information about the Gdb-patches mailing list