diff options
author | Chaoren Lin <chaorenl@google.com> | 2015-02-03 01:51:02 +0000 |
---|---|---|
committer | Chaoren Lin <chaorenl@google.com> | 2015-02-03 01:51:02 +0000 |
commit | 911a6dcaa980034659498af658cb1c1884055d0e (patch) | |
tree | e7efddf2e293ef4a0274fb1e74ea982604b07684 /lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp | |
parent | e9547b80522c32a95ec7fc57392a8db6f7770081 (diff) | |
download | bcm5719-llvm-911a6dcaa980034659498af658cb1c1884055d0e.tar.gz bcm5719-llvm-911a6dcaa980034659498af658cb1c1884055d0e.zip |
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.
llvm-svn: 227918
Diffstat (limited to 'lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp')
-rw-r--r-- | lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp | 21 |
1 files changed, 1 insertions, 20 deletions
diff --git a/lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp b/lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp index 2a1690eae8f..1c9a27638f1 100644 --- a/lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp +++ b/lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp @@ -2578,6 +2578,7 @@ NativeProcessLinux::MonitorSignal(const siginfo_t *info, lldb::pid_t pid, bool e case SIGILL: case SIGFPE: case SIGBUS: + default: { // This thread is stopped. NotifyThreadStop (pid); @@ -2646,26 +2647,6 @@ NativeProcessLinux::MonitorSignal(const siginfo_t *info, lldb::pid_t pid, bool e 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; } |