aboutsummaryrefslogtreecommitdiff
path: root/gdb/nat
diff options
context:
space:
mode:
authorPedro Alves <pedro@palves.net>2023-05-08 21:36:28 +0100
committerPedro Alves <pedro@palves.net>2024-05-08 00:39:55 +0100
commitc151e663fad2297d1cf21ce4e4143dc5a3eb0f96 (patch)
treedadd9b181c6628f30e0a3da2937de90cd6ec84e1 /gdb/nat
parent78ef7c48d1d0c8199cb55e8c6f6a3e6ff09ee59f (diff)
downloadgdb-c151e663fad2297d1cf21ce4e4143dc5a3eb0f96.zip
gdb-c151e663fad2297d1cf21ce4e4143dc5a3eb0f96.tar.gz
gdb-c151e663fad2297d1cf21ce4e4143dc5a3eb0f96.tar.bz2
Windows gdb+gdbserver: Eliminate thread_rec(INVALIDATE_CONTEXT) calls
Replace thread_rec(INVALIDATE_CONTEXT) calls with find_thread, and invalidate_context / suspend calls in the spots that might need those. I don't know why does the INVALIDATE_CONTEXT implementation in GDB avoid suspending the event thread: case INVALIDATE_CONTEXT: if (ptid.lwp () != current_event.dwThreadId) th->suspend (); Checks for a global "current_event" get in the way of non-stop support later in the series, as each thread will have its own "last debug event". Regardless, it should be fine to suspend the event thread. As a data point, the GDBserver implementation always suspends. So this patch does not try to avoid suspending the event thread on the native side either. Change-Id: I8d2f0a749d23329956e62362a7007189902dddb5
Diffstat (limited to 'gdb/nat')
-rw-r--r--gdb/nat/windows-nat.h2
1 files changed, 0 insertions, 2 deletions
diff --git a/gdb/nat/windows-nat.h b/gdb/nat/windows-nat.h
index 41921aa..0e2093e 100644
--- a/gdb/nat/windows-nat.h
+++ b/gdb/nat/windows-nat.h
@@ -103,8 +103,6 @@ enum thread_disposition_type
{
/* Invalidate the context, but do not suspend the thread. */
DONT_SUSPEND,
- /* Invalidate the context and suspend the thread. */
- INVALIDATE_CONTEXT
};
/* A single pending stop. See "pending_stops" for more