[Lldb-commits] [lldb] [llvm] [lldb-dap] Add multi-session support with shared debugger instances (PR #163653)

2025-11-10 Thread Janet Yang via lldb-commits
qxy11 wrote: @ashgti Thanks for the suggestion! Do you have recommendations for what to include if we were to implement Initialize/Terminate? I was trying to think of what we'd do, but DAPSessionManager's just a coordinator/registry that keeps some maps that

[Lldb-commits] [lldb] [llvm] [lldb-dap] Add multi-session support with shared debugger instances (PR #163653)

2025-11-10 Thread Janet Yang via lldb-commits
qxy11 wrote: This didn't end up working here and we may need to keep this intentional leak due to issues w/ the destructor chain. It seemed to cause DAP to hang since the ManagedStatic seemed to try to destroy the DAPSessionManager and some resources may have

[Lldb-commits] [lldb] [llvm] [lldb-dap] Add multi-session support with shared debugger instances (PR #163653)

2025-11-10 Thread Janet Yang via lldb-commits
@@ -295,4 +307,267 @@ void SendMemoryEvent(DAP &dap, lldb::SBValue variable) { dap.Send(protocol::Event{"memory", std::move(body)}); } +// Note: EventThread() is architecturally different from the other functions in +// this file. While the functions above are event helpers

[Lldb-commits] [lldb] [llvm] [lldb-dap] Add multi-session support with shared debugger instances (PR #163653)

2025-10-22 Thread Janet Yang via lldb-commits
@@ -1289,13 +1293,92 @@ protocol::Capabilities DAP::GetCustomCapabilities() { } void DAP::StartEventThread() { - event_thread = std::thread(&DAP::EventThread, this); + // Get event thread for this debugger (creates it if it doesn't exist). + event_thread_sp = DAPSessionMana

[Lldb-commits] [lldb] [llvm] [lldb-dap] Add multi-session support with shared debugger instances (PR #163653)

2025-10-22 Thread Janet Yang via lldb-commits
@@ -1390,104 +1481,151 @@ void DAP::EventThread() { // Only report a stopped event if the process was not // automatically restarted. if (!lldb::SBProcess::GetRestartedFromEvent(event)) { - SendStdOutStdErr(*this, process); -

[Lldb-commits] [lldb] [llvm] [lldb-dap] Add multi-session support with shared debugger instances (PR #163653)

2025-10-18 Thread Janet Yang via lldb-commits
@@ -0,0 +1,119 @@ +//===-- DAPSessionManager.h *- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apac

[Lldb-commits] [lldb] [llvm] [lldb-dap] Add multi-session support with shared debugger instances (PR #163653)

2025-10-18 Thread Janet Yang via lldb-commits
https://github.com/qxy11 updated https://github.com/llvm/llvm-project/pull/163653 >From 5b94fa5412e8a56ee1ea1fe7e1cd8d9efddcaffb Mon Sep 17 00:00:00 2001 From: qxy11 Date: Wed, 15 Oct 2025 15:47:23 -0700 Subject: [PATCH 1/3] [lldb-dap] Add multi-session support with shared debugger instances

[Lldb-commits] [lldb] [lldb] Add support for unique target ids (PR #160736)

2025-10-18 Thread Janet Yang via lldb-commits
https://github.com/qxy11 updated https://github.com/llvm/llvm-project/pull/160736 >From c155381f49915fa98bd6e3ea14eb77b1dfcd7dbd Mon Sep 17 00:00:00 2001 From: qxy11 Date: Thu, 25 Sep 2025 09:54:50 -0700 Subject: [PATCH 1/5] Add support for unique target ids --- lldb/include/lldb/API/SBDebugg

[Lldb-commits] [lldb] [lldb] Add support for unique target ids (PR #160736)

2025-10-18 Thread Janet Yang via lldb-commits
https://github.com/qxy11 updated https://github.com/llvm/llvm-project/pull/160736 >From c155381f49915fa98bd6e3ea14eb77b1dfcd7dbd Mon Sep 17 00:00:00 2001 From: qxy11 Date: Thu, 25 Sep 2025 09:54:50 -0700 Subject: [PATCH 1/4] Add support for unique target ids --- lldb/include/lldb/API/SBDebugg

[Lldb-commits] [lldb] [lldb] Add support for unique target ids (PR #160736)

2025-10-17 Thread Janet Yang via lldb-commits
https://github.com/qxy11 updated https://github.com/llvm/llvm-project/pull/160736 >From c155381f49915fa98bd6e3ea14eb77b1dfcd7dbd Mon Sep 17 00:00:00 2001 From: qxy11 Date: Thu, 25 Sep 2025 09:54:50 -0700 Subject: [PATCH 1/2] Add support for unique target ids --- lldb/include/lldb/API/SBDebugg

[Lldb-commits] [lldb] [lldb] Add support for unique target ids (PR #160736)

2025-10-17 Thread Janet Yang via lldb-commits
https://github.com/qxy11 updated https://github.com/llvm/llvm-project/pull/160736 >From c155381f49915fa98bd6e3ea14eb77b1dfcd7dbd Mon Sep 17 00:00:00 2001 From: qxy11 Date: Thu, 25 Sep 2025 09:54:50 -0700 Subject: [PATCH 1/3] Add support for unique target ids --- lldb/include/lldb/API/SBDebugg

[Lldb-commits] [lldb] [llvm] [lldb-dap] Add multi-session support with shared debugger instances (PR #163653)

2025-10-17 Thread Janet Yang via lldb-commits
@@ -0,0 +1,119 @@ +//===-- DAPSessionManager.h *- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apac

[Lldb-commits] [lldb] [llvm] [lldb-dap] Add multi-session support with shared debugger instances (PR #163653)

2025-10-16 Thread Janet Yang via lldb-commits
@@ -0,0 +1,119 @@ +//===-- DAPSessionManager.h *- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apac

[Lldb-commits] [lldb] [llvm] [lldb-dap] Add multi-session support with shared debugger instances (PR #163653)

2025-10-16 Thread Janet Yang via lldb-commits
@@ -556,6 +557,11 @@ class Target : public std::enable_shared_from_this, TargetEventData(const lldb::TargetSP &target_sp, const ModuleList &module_list); +TargetEventData(const lldb::TargetSP &target_sp, std::string session_name); + +TargetEvent

[Lldb-commits] [lldb] [llvm] [lldb-dap] Add multi-session support with shared debugger instances (PR #163653)

2025-10-15 Thread Janet Yang via lldb-commits
https://github.com/qxy11 created https://github.com/llvm/llvm-project/pull/163653 ## Summary: This change introduces a DAPSessionManager to enable multiple DAP sessions to share debugger instances when needed, for things like child process debugging and some scripting hooks that create dynamic

[Lldb-commits] [lldb] [lldb] Add support for unique target ids (PR #160736)

2025-10-02 Thread Janet Yang via lldb-commits
https://github.com/qxy11 updated https://github.com/llvm/llvm-project/pull/160736 >From c155381f49915fa98bd6e3ea14eb77b1dfcd7dbd Mon Sep 17 00:00:00 2001 From: qxy11 Date: Thu, 25 Sep 2025 09:54:50 -0700 Subject: [PATCH 1/8] Add support for unique target ids --- lldb/include/lldb/API/SBDebugg

[Lldb-commits] [lldb] [lldb] Add support for unique target ids (PR #160736)

2025-10-02 Thread Janet Yang via lldb-commits
https://github.com/qxy11 updated https://github.com/llvm/llvm-project/pull/160736 >From c155381f49915fa98bd6e3ea14eb77b1dfcd7dbd Mon Sep 17 00:00:00 2001 From: qxy11 Date: Thu, 25 Sep 2025 09:54:50 -0700 Subject: [PATCH 1/6] Add support for unique target ids --- lldb/include/lldb/API/SBDebugg

[Lldb-commits] [lldb] [lldb] Add support for unique target ids (PR #160736)

2025-10-02 Thread Janet Yang via lldb-commits
https://github.com/qxy11 updated https://github.com/llvm/llvm-project/pull/160736 >From c155381f49915fa98bd6e3ea14eb77b1dfcd7dbd Mon Sep 17 00:00:00 2001 From: qxy11 Date: Thu, 25 Sep 2025 09:54:50 -0700 Subject: [PATCH 1/7] Add support for unique target ids --- lldb/include/lldb/API/SBDebugg

[Lldb-commits] [lldb] [lldb] Add support for unique target ids (PR #160736)

2025-09-25 Thread Janet Yang via lldb-commits
https://github.com/qxy11 updated https://github.com/llvm/llvm-project/pull/160736 >From c155381f49915fa98bd6e3ea14eb77b1dfcd7dbd Mon Sep 17 00:00:00 2001 From: qxy11 Date: Thu, 25 Sep 2025 09:54:50 -0700 Subject: [PATCH] Add support for unique target ids --- lldb/include/lldb/API/SBDebugger.h

[Lldb-commits] [lldb] [lldb] Add support for unique target ids (PR #160736)

2025-09-25 Thread Janet Yang via lldb-commits
https://github.com/qxy11 created https://github.com/llvm/llvm-project/pull/160736 ### Summary Add support for unique target ids per Target instance. This is needed for upcoming changes to allow debugger instances to be shared across separate DAP instances for child process/gpu debugging. Each