https://github.com/ashgti updated
https://github.com/llvm/llvm-project/pull/144153
>From e54b23052c17efd61297db619c355749d51e34c6 Mon Sep 17 00:00:00 2001
From: John Harrison
Date: Fri, 13 Jun 2025 11:58:27 -0700
Subject: [PATCH 1/2] [lldb-dap] Creating protocol types for
setExceptionBreakpoin
https://github.com/ashgti commented:
Would it be worth it to include a file in lldb/docs/resources about running
this? For folks wanting to get started trying this out?
Maybe in a follow up PR.
https://github.com/llvm/llvm-project/pull/143628
___
lld
@@ -0,0 +1,72 @@
+//===- Tool.cpp
---===//
+//
+// 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: Apa
@@ -0,0 +1,131 @@
+//===- Protocol.h
-===//
+//
+// 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: Ap
@@ -0,0 +1,280 @@
+//===- ProtocolServerMCP.cpp
--===//
+//
+// 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: Ap
@@ -0,0 +1,131 @@
+//===- Protocol.h
-===//
+//
+// 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: Ap
@@ -0,0 +1,280 @@
+//===- ProtocolServerMCP.cpp
--===//
+//
+// 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: Ap
@@ -0,0 +1,280 @@
+//===- ProtocolServerMCP.cpp
--===//
+//
+// 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: Ap
@@ -0,0 +1,13 @@
+add_lldb_library(lldbPluginProtocolServerMCP PLUGIN
ashgti wrote:
Should this be behind a build flag?
I could see some distributions disabling this feature for security reasons.
Once an MCP server is running, it can run arbitrary commands in t
https://github.com/ashgti edited
https://github.com/llvm/llvm-project/pull/143628
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
https://github.com/ashgti edited
https://github.com/llvm/llvm-project/pull/143628
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
https://github.com/ashgti edited
https://github.com/llvm/llvm-project/pull/143628
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
ashgti wrote:
Reading more about this in the VSCode docs and on the MCP website I think I
understand the flow of logic a bit more.
I think this is definitely helpful for allowing an agent to help control a
debug session.
However, I'm still not sure how we should handle the MCP client and debu
@@ -39,6 +41,8 @@ class ExceptionBreakpoint {
std::string m_filter;
std::string m_label;
lldb::LanguageType m_language;
+ bool m_is_throw;
+ bool m_is_catch;
ashgti wrote:
Sure, created an enum. Thats hopefully more clear than the set of bools.
https:
https://github.com/ashgti created
https://github.com/llvm/llvm-project/pull/144153
This adds new types for setExceptionBreakpoints and adds support for
`supportsExceptionFilterOptions`, which allows exception breakpoints to set a
condition.
While testing this, I noticed that obj-c exception c
ashgti wrote:
Ah, ok, if is already like this in other places, SGTM
https://github.com/llvm/llvm-project/pull/144070
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
https://github.com/ashgti approved this pull request.
https://github.com/llvm/llvm-project/pull/144070
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
https://github.com/ashgti updated
https://github.com/llvm/llvm-project/pull/143818
>From ab4b987aec591491d3805af41c7127ff6698fe0e Mon Sep 17 00:00:00 2001
From: John Harrison
Date: Wed, 11 Jun 2025 15:57:16 -0700
Subject: [PATCH 1/4] [lldb-dap] Refactring DebugCommunication to improve test
con
@@ -10,17 +10,117 @@
import subprocess
import signal
import sys
+from dataclasses import dataclass
import threading
import time
-from typing import Any, Optional, Union, BinaryIO, TextIO
+from typing import (
+IO,
+Any,
+Callable,
+Dict,
+List,
+Option
@@ -10,17 +10,117 @@
import subprocess
import signal
import sys
+from dataclasses import dataclass
import threading
import time
-from typing import Any, Optional, Union, BinaryIO, TextIO
+from typing import (
+IO,
+Any,
+Callable,
+Dict,
+List,
+Option
@@ -189,262 +298,322 @@ def _read_packet_thread(self):
while not done:
packet = read_packet(self.recv, trace_file=self.trace_file)
# `packet` will be `None` on EOF. We want to pass it down to
-# handle_recv_packet anyw
https://github.com/ashgti updated
https://github.com/llvm/llvm-project/pull/143818
>From ab4b987aec591491d3805af41c7127ff6698fe0e Mon Sep 17 00:00:00 2001
From: John Harrison
Date: Wed, 11 Jun 2025 15:57:16 -0700
Subject: [PATCH 1/5] [lldb-dap] Refactring DebugCommunication to improve test
con
@@ -71,31 +173,27 @@ def read_packet(f, verbose=False, trace_file=None):
if line.startswith(prefix):
# Decode length of JSON bytes
if verbose:
-print('content: "%s"' % (line))
+print(f"content: {line}")
ashgti wrote:
@@ -189,262 +298,322 @@ def _read_packet_thread(self):
while not done:
packet = read_packet(self.recv, trace_file=self.trace_file)
# `packet` will be `None` on EOF. We want to pass it down to
-# handle_recv_packet anyw
https://github.com/ashgti updated
https://github.com/llvm/llvm-project/pull/143818
>From ab4b987aec591491d3805af41c7127ff6698fe0e Mon Sep 17 00:00:00 2001
From: John Harrison
Date: Wed, 11 Jun 2025 15:57:16 -0700
Subject: [PATCH 1/3] [lldb-dap] Refactring DebugCommunication to improve test
con
@@ -582,6 +582,28 @@ llvm::json::Value toJSON(const SteppingGranularity &SG) {
llvm_unreachable("unhandled stepping granularity.");
}
+bool fromJSON(const json::Value &Params, StepInTarget &SIT, json::Path P) {
+ json::ObjectMapper O(Params, P);
+ return O && O.map("id", S
https://github.com/ashgti approved this pull request.
https://github.com/llvm/llvm-project/pull/144072
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
@@ -189,262 +298,322 @@ def _read_packet_thread(self):
while not done:
packet = read_packet(self.recv, trace_file=self.trace_file)
# `packet` will be `None` on EOF. We want to pass it down to
-# handle_recv_packet anyw
https://github.com/ashgti approved this pull request.
LGTM!
I look forward to trying this out and iterating on this.
https://github.com/llvm/llvm-project/pull/143628
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-
@@ -510,6 +510,25 @@ DAP::SendFormattedOutput(OutputType o, const char *format,
...) {
o, llvm::StringRef(buffer, std::min(actual_length,
sizeof(buffer;
}
+int32_t DAP::CreateSourceReference(lldb::addr_t address) {
+ auto iter = llvm::find(source_references, addre
@@ -510,6 +510,25 @@ DAP::SendFormattedOutput(OutputType o, const char *format,
...) {
o, llvm::StringRef(buffer, std::min(actual_length,
sizeof(buffer;
}
+int32_t DAP::CreateSourceReference(lldb::addr_t address) {
+ auto iter = llvm::find(source_references, addre
@@ -37,10 +37,15 @@ protocol::Source CreateSource(const lldb::SBFileSpec &file);
/// \param[in] target
/// The target that has the address.
///
+/// \param[in] create_reference
+/// function used to create a source_reference
+///
/// \return
-/// A "Source" JSON ob
https://github.com/ashgti updated
https://github.com/llvm/llvm-project/pull/144153
>From e54b23052c17efd61297db619c355749d51e34c6 Mon Sep 17 00:00:00 2001
From: John Harrison
Date: Fri, 13 Jun 2025 11:58:27 -0700
Subject: [PATCH 1/3] [lldb-dap] Creating protocol types for
setExceptionBreakpoin
1101 - 1133 of 1133 matches
Mail list logo