Added the ability to detect which vCont packets (using the "vCont?") packet
are supported by the remote GDB target. We can also now deal with the lack of
vCont support and send packets that the remote GDB stub can use. We also error
out of the continue if LLDB tries to do something too complex when vCont isn't
supported.
git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@125433 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.h b/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.h
index 3ebabeb..1499ba9 100644
--- a/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.h
+++ b/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.h
@@ -97,23 +97,8 @@
CalculcateChecksum (const char *payload,
size_t payload_length);
- void
- SetAckMode (bool enabled)
- {
- m_send_acks = enabled;
- }
-
bool
- GetThreadSuffixSupported () const
- {
- return m_thread_suffix_supported;
- }
-
- void
- SetThreadSuffixSupported (bool enabled)
- {
- m_thread_suffix_supported = enabled;
- }
+ GetThreadSuffixSupported ();
bool
SendAsyncSignal (int signo);
@@ -229,12 +214,6 @@
bool
GetHostInfo (uint32_t timeout_seconds);
- bool
- HostInfoIsValid () const
- {
- return m_pointer_byte_size != 0;
- }
-
const lldb_private::ArchSpec &
GetHostArchitecture ();
@@ -250,6 +229,33 @@
uint32_t
GetAddressByteSize ();
+ bool
+ GetVContSupported (char flavor);
+
+ void
+ ResetDiscoverableSettings();
+
+ bool
+ GetHostInfo ();
+
+ bool
+ GetSendAcks ();
+
+ bool
+ GetSupportsThreadSuffix ();
+
+ bool
+ HasFullVContSupport ()
+ {
+ return GetVContSupported ('A');
+ }
+
+ bool
+ HasAnyVContSupport ()
+ {
+ return GetVContSupported ('a');
+ }
+
protected:
typedef std::list<std::string> packet_collection;
@@ -264,11 +270,24 @@
bool
WaitForNotRunningPrivate (const lldb_private::TimeValue *timeout_ptr);
+ bool
+ HostInfoIsValid () const
+ {
+ return m_supports_qHostInfo != lldb::eLazyBoolCalculate;
+ }
+
//------------------------------------------------------------------
// Classes that inherit from GDBRemoteCommunication can see and modify these
//------------------------------------------------------------------
- bool m_send_acks:1,
- m_thread_suffix_supported:1;
+ lldb::LazyBool m_supports_not_sending_acks;
+ lldb::LazyBool m_supports_thread_suffix;
+ lldb::LazyBool m_supports_qHostInfo;
+ lldb::LazyBool m_supports_vCont_all;
+ lldb::LazyBool m_supports_vCont_any;
+ lldb::LazyBool m_supports_vCont_c;
+ lldb::LazyBool m_supports_vCont_C;
+ lldb::LazyBool m_supports_vCont_s;
+ lldb::LazyBool m_supports_vCont_S;
lldb_private::Listener m_rx_packet_listener;
lldb_private::Mutex m_sequence_mutex; // Restrict access to sending/receiving packets to a single thread at a time
lldb_private::Predicate<bool> m_public_is_running;