[Lldb-commits] [lldb] r238893 - Fixed a deadlock that was slowing down processes when they shut down. A 3 second delay could occur sometimes when a process exits, now that delay is gone.

Greg Clayton gclayton at apple.com
Tue Jun 2 17:34:01 PDT 2015


Author: gclayton
Date: Tue Jun  2 19:34:01 2015
New Revision: 238893

URL: http://llvm.org/viewvc/llvm-project?rev=238893&view=rev
Log:
Fixed a deadlock that was slowing down processes when they shut down. A 3 second delay could occur sometimes when a process exits, now that delay is gone.


Modified:
    lldb/trunk/source/Target/Process.cpp

Modified: lldb/trunk/source/Target/Process.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Target/Process.cpp?rev=238893&r1=238892&r2=238893&view=diff
==============================================================================
--- lldb/trunk/source/Target/Process.cpp (original)
+++ lldb/trunk/source/Target/Process.cpp Tue Jun  2 19:34:01 2015
@@ -1455,8 +1455,8 @@ Process::SetExitStatus (int status, cons
         m_exit_string.clear();
 
     // When we exit, we no longer need to the communication channel
-    m_stdio_communication.StopReadThread();
     m_stdio_communication.Disconnect();
+    m_stdio_communication.StopReadThread();
     m_stdin_forward = false;
 
     // And we don't need the input reader anymore as well
@@ -4036,8 +4036,8 @@ Process::Destroy (bool force_kill)
             DidDestroy();
             StopPrivateStateThread();
         }
-        m_stdio_communication.StopReadThread();
         m_stdio_communication.Disconnect();
+        m_stdio_communication.StopReadThread();
         m_stdin_forward = false;
 
         if (m_process_input_reader)





More information about the lldb-commits mailing list