[Lldb-commits] [lldb] r227910 - llgs: fixed a bug in deferred signal thread id; added coordinator enqueue logging.
Chaoren Lin
chaorenl at google.com
Mon Feb 2 17:50:44 PST 2015
Author: chaoren
Date: Mon Feb 2 19:50:44 2015
New Revision: 227910
URL: http://llvm.org/viewvc/llvm-project?rev=227910&view=rev
Log:
llgs: fixed a bug in deferred signal thread id; added coordinator enqueue logging.
The deferred signal thread id was being set with the process id
unintentionally in NativeProcessLinux::CallAfterRunningThreadsStop().
Modified:
lldb/trunk/source/Plugins/Process/Linux/NativeProcessLinux.cpp
lldb/trunk/source/Plugins/Process/Linux/ThreadStateCoordinator.cpp
Modified: lldb/trunk/source/Plugins/Process/Linux/NativeProcessLinux.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/Process/Linux/NativeProcessLinux.cpp?rev=227910&r1=227909&r2=227910&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/Process/Linux/NativeProcessLinux.cpp (original)
+++ lldb/trunk/source/Plugins/Process/Linux/NativeProcessLinux.cpp Mon Feb 2 19:50:44 2015
@@ -3894,7 +3894,7 @@ NativeProcessLinux::CallAfterRunningThre
const std::function<void (lldb::tid_t tid)> &call_after_function)
{
const lldb::pid_t pid = GetID ();
- m_coordinator_up->CallAfterRunningThreadsStop (pid,
+ m_coordinator_up->CallAfterRunningThreadsStop (tid,
[=](lldb::tid_t request_stop_tid)
{
tgkill (pid, request_stop_tid, SIGSTOP);
Modified: lldb/trunk/source/Plugins/Process/Linux/ThreadStateCoordinator.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/Process/Linux/ThreadStateCoordinator.cpp?rev=227910&r1=227909&r2=227910&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/Process/Linux/ThreadStateCoordinator.cpp (original)
+++ lldb/trunk/source/Plugins/Process/Linux/ThreadStateCoordinator.cpp Mon Feb 2 19:50:44 2015
@@ -528,7 +528,11 @@ void
ThreadStateCoordinator::EnqueueEvent (EventBaseSP event_sp)
{
std::lock_guard<std::mutex> lock (m_queue_mutex);
+
m_event_queue.push (event_sp);
+ if (m_log_event_processing)
+ Log ("ThreadStateCoordinator::%s enqueued event: %s", __FUNCTION__, event_sp->GetDescription ().c_str ());
+
m_queue_condition.notify_one ();
}
More information about the lldb-commits
mailing list