aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp
diff options
context:
space:
mode:
authorJim Ingham <jingham@apple.com>2021-05-06 14:14:35 -0700
committerJim Ingham <jingham@apple.com>2021-05-11 11:57:08 -0700
commit9558b602b22cb7d681757c5f56d941e39a9d9d19 (patch)
treec809fffa7f196e50c95e001c1deab085d06b577d /lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp
parent384dd9ddaf616a1563ee1c1a8a1347b7658e7a70 (diff)
downloadllvm-9558b602b22cb7d681757c5f56d941e39a9d9d19.zip
llvm-9558b602b22cb7d681757c5f56d941e39a9d9d19.tar.gz
llvm-9558b602b22cb7d681757c5f56d941e39a9d9d19.tar.bz2
Add an "interrupt timeout" to Process, and pipe that through the
ProcessGDBRemote plugin layers. Also fix a bug where if we tried to interrupt, but the ReadPacket wakeup timer woke us up just after the timeout, we would break out the switch, but then since we immediately check if the response is empty & fail if it is, we could end up actually only giving a small interval to the interrupt. Differential Revision: https://reviews.llvm.org/D102085
Diffstat (limited to 'lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp')
-rw-r--r--lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp
index 1f50194..56a3a16 100644
--- a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp
+++ b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp
@@ -364,7 +364,7 @@ bool GDBRemoteRegisterContext::WriteRegisterBytes(const RegisterInfo *reg_info,
reg_info->byte_size, // dst length
m_reg_data.GetByteOrder())) // dst byte order
{
- GDBRemoteClientBase::Lock lock(gdb_comm, false);
+ GDBRemoteClientBase::Lock lock(gdb_comm);
if (lock) {
if (m_write_all_at_once) {
// Invalidate all register values
@@ -508,7 +508,7 @@ bool GDBRemoteRegisterContext::ReadAllRegisterValues(
const bool use_g_packet =
!gdb_comm.AvoidGPackets((ProcessGDBRemote *)process);
- GDBRemoteClientBase::Lock lock(gdb_comm, false);
+ GDBRemoteClientBase::Lock lock(gdb_comm);
if (lock) {
if (gdb_comm.SyncThreadState(m_thread.GetProtocolID()))
InvalidateAllRegisters();
@@ -574,7 +574,7 @@ bool GDBRemoteRegisterContext::WriteAllRegisterValues(
const bool use_g_packet =
!gdb_comm.AvoidGPackets((ProcessGDBRemote *)process);
- GDBRemoteClientBase::Lock lock(gdb_comm, false);
+ GDBRemoteClientBase::Lock lock(gdb_comm);
if (lock) {
// The data_sp contains the G response packet.
if (use_g_packet) {