Make the "synchronous" mode actually work without race conditions.
authorGreg Clayton <gclayton@apple.com>
Tue, 21 Oct 2014 01:00:42 +0000 (01:00 +0000)
committerGreg Clayton <gclayton@apple.com>
Tue, 21 Oct 2014 01:00:42 +0000 (01:00 +0000)
commitdc6224e0a3ce2b097f0a631de9ae1960f175dfe6
tree7364aee6be1c2bddee56bcabeab0ca59de7fb2c5
parentf16a66973c04f56eb5068fe407ad75a3e09ee00a
Make the "synchronous" mode actually work without race conditions.

There were many issues with synchronous mode that we discovered when started to try and add a "batch" mode. There was a race condition where the event handling thread might consume events when in sync mode and other times the Process::WaitForProcessToStop() would consume them. This also led to places where the Process IO handler might or might not get popped when it needed to be.

llvm-svn: 220254
13 files changed:
lldb/include/lldb/Target/Process.h
lldb/include/lldb/Target/Target.h
lldb/source/API/SBProcess.cpp
lldb/source/API/SBTarget.cpp
lldb/source/API/SBThread.cpp
lldb/source/Commands/CommandObjectProcess.cpp
lldb/source/Commands/CommandObjectThread.cpp
lldb/source/Core/Debugger.cpp
lldb/source/Interpreter/CommandInterpreter.cpp
lldb/source/Target/Process.cpp
lldb/source/Target/StopInfo.cpp
lldb/source/Target/Target.cpp
lldb/test/api/multithreaded/test_breakpoint_callback.cpp