https://github.com/JDevlieghere updated 
https://github.com/llvm/llvm-project/pull/90913

>From 7ed4008b32d6ec7809a9cea0eb4462d1b90f4e52 Mon Sep 17 00:00:00 2001
From: Jonas Devlieghere <jo...@devlieghere.com>
Date: Thu, 2 May 2024 15:47:46 -0700
Subject: [PATCH] [lldb] Always emit diagnostic events to the system log

Always emit diagnostic events to the system log so that they end up in
the sysdiagnose on Darwin.
---
 lldb/source/Core/Debugger.cpp | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/lldb/source/Core/Debugger.cpp b/lldb/source/Core/Debugger.cpp
index 065f70c3880aaa..976420a4344394 100644
--- a/lldb/source/Core/Debugger.cpp
+++ b/lldb/source/Core/Debugger.cpp
@@ -1512,6 +1512,9 @@ void Debugger::ReportDiagnosticImpl(Severity severity, 
std::string message,
                                     std::optional<lldb::user_id_t> debugger_id,
                                     std::once_flag *once) {
   auto ReportDiagnosticLambda = [&]() {
+    // Always log diagnostics to the system log.
+    Host::SystemLog(severity, message);
+
     // The diagnostic subsystem is optional but we still want to broadcast
     // events when it's disabled.
     if (Diagnostics::Enabled())

_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to