Author: chaoren
Date: Mon Feb 2 19:51:02 2015
New Revision: 227918
URL: http://llvm.org/viewvc/llvm-project?rev=227918&view=rev
Log:
LLGS local - signal stops inferior in debugger
NativeProcessLinux::MonitorSignal was automatically resuming threads
that stopped due to a signal. This is inconsistent with the
behavior of lldb and gdb. This change removes the automatic resume.
Fixes
TestSendSignal.py
TestSignalsAPI.py
if PLATFORM_LINUX_FORCE_LLGS_LOCAL is in the environment vars.
Modified:
lldb/trunk/source/Plugins/Process/Linux/NativeProcessLinux.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=227918&r1=227917&r2=227918&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/Process/Linux/NativeProcessLinux.cpp (original)
+++ lldb/trunk/source/Plugins/Process/Linux/NativeProcessLinux.cpp Mon Feb 2
19:51:02 2015
@@ -2578,6 +2578,7 @@ NativeProcessLinux::MonitorSignal(const
case SIGILL:
case SIGFPE:
case SIGBUS:
+ default:
{
// This thread is stopped.
NotifyThreadStop (pid);
@@ -2646,26 +2647,6 @@ NativeProcessLinux::MonitorSignal(const
SetCurrentThreadID
(signaling_tid);
SetState
(StateType::eStateStopped, true);
});
- break;
- }
-
- default:
- {
- // This thread is stopped.
- NotifyThreadStop (pid);
-
- if (log)
- log->Printf ("NativeProcessLinux::%s pid = %" PRIu64 " tid %"
PRIu64 " resuming thread with signal %s (%d)", __FUNCTION__, GetID (), pid,
GetUnixSignals().GetSignalAsCString (signo), signo);
-
- // Pass the signal on to the inferior.
- m_coordinator_up->RequestThreadResume (pid,
- [=](lldb::tid_t
tid_to_resume)
- {
-
reinterpret_cast<NativeThreadLinux*> (thread_sp.get ())->SetRunning ();
- // Pass this signal
number on to the inferior to handle.
- Resume (tid_to_resume,
signo);
- },
- CoordinatorErrorHandler);
}
break;
}
_______________________________________________
lldb-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits