diff options
author | Pavel Labath <pavel@labath.sk> | 2022-01-31 15:57:48 +0100 |
---|---|---|
committer | Pavel Labath <pavel@labath.sk> | 2022-02-02 14:13:08 +0100 |
commit | a007a6d84471bb956abe10974cac3066799f583f (patch) | |
tree | bfa09e71cc1ce894d3a1e7cab572c21eeaaf4117 /lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp | |
parent | 574ad2a84626ffb0e7a64559e9862f20aadc013a (diff) | |
download | llvm-a007a6d84471bb956abe10974cac3066799f583f.zip llvm-a007a6d84471bb956abe10974cac3066799f583f.tar.gz llvm-a007a6d84471bb956abe10974cac3066799f583f.tar.bz2 |
[lldb] Convert "LLDB" log channel to the new API
Diffstat (limited to 'lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp')
-rw-r--r-- | lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp b/lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp index e4dec0e..3e2b453 100644 --- a/lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp +++ b/lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp @@ -429,7 +429,7 @@ Status NativeProcessLinux::SetDefaultPtraceOpts(lldb::pid_t pid) { // Handles all waitpid events from the inferior process. void NativeProcessLinux::MonitorCallback(NativeThreadLinux &thread, WaitStatus status) { - Log *log(GetLogIfAnyCategoriesSet(LIBLLDB_LOG_PROCESS)); + Log *log = GetLog(LLDBLog::Process); // Certain activities differ based on whether the pid is the tid of the main // thread. @@ -714,8 +714,7 @@ void NativeProcessLinux::MonitorTrace(NativeThreadLinux &thread) { } void NativeProcessLinux::MonitorBreakpoint(NativeThreadLinux &thread) { - Log *log( - GetLogIfAnyCategoriesSet(LIBLLDB_LOG_PROCESS | LIBLLDB_LOG_BREAKPOINTS)); + Log *log = GetLog(LLDBLog::Process | LLDBLog::Breakpoints); LLDB_LOG(log, "received breakpoint event, pid = {0}", thread.GetID()); // Mark the thread as stopped at breakpoint. @@ -731,8 +730,7 @@ void NativeProcessLinux::MonitorBreakpoint(NativeThreadLinux &thread) { void NativeProcessLinux::MonitorWatchpoint(NativeThreadLinux &thread, uint32_t wp_index) { - Log *log( - GetLogIfAnyCategoriesSet(LIBLLDB_LOG_PROCESS | LIBLLDB_LOG_WATCHPOINTS)); + Log *log = GetLog(LLDBLog::Process | LLDBLog::Watchpoints); LLDB_LOG(log, "received watchpoint event, pid = {0}, wp_index = {1}", thread.GetID(), wp_index); @@ -1828,8 +1826,7 @@ void NativeProcessLinux::SignalIfAllThreadsStopped() { } // We have a pending notification and all threads have stopped. - Log *log( - GetLogIfAnyCategoriesSet(LIBLLDB_LOG_PROCESS | LIBLLDB_LOG_BREAKPOINTS)); + Log *log = GetLog(LLDBLog::Process | LLDBLog::Breakpoints); // Clear any temporary breakpoints we used to implement software single // stepping. |