No functionality changes, mostly cleanup.

Cleaned up the Mutex::Locker and the ReadWriteLock classes a bit.

Also cleaned up the GDBRemoteCommunication class to not have so many packet functions. Used the "NoLock" versions of send/receive packet functions when possible for a bit of performance.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@154458 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.h b/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.h
index d7986d5..ef0c198 100644
--- a/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.h
+++ b/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.h
@@ -45,21 +45,6 @@
     virtual
     ~GDBRemoteCommunication();
 
-    size_t
-    SendPacket (const char *payload);
-
-    size_t
-    SendPacket (const char *payload,
-                size_t payload_length);
-
-    size_t
-    SendPacket (lldb_private::StreamString &response);
-
-    // Wait for a packet within 'nsec' seconds
-    size_t
-    WaitForPacketWithTimeoutMicroSeconds (StringExtractorGDBRemote &response,
-                                          uint32_t usec);
-
     char
     GetAck ();
 
@@ -74,7 +59,7 @@
                         size_t payload_length);
 
     bool
-    TryLockSequenceMutex(lldb_private::Mutex::Locker& locker);
+    GetSequenceMutex (lldb_private::Mutex::Locker& locker, uint32_t usec_timeout);
 
     bool
     CheckForPacket (const uint8_t *src, 
@@ -260,6 +245,10 @@
     };
 
     size_t
+    SendPacket (const char *payload,
+                size_t payload_length);
+
+    size_t
     SendPacketNoLock (const char *payload, 
                       size_t payload_length);