ashgti wrote:
This builds on #130090 and #130026
https://github.com/llvm/llvm-project/pull/130104
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
https://github.com/jasonmolenda updated
https://github.com/llvm/llvm-project/pull/129967
>From 6e258eb09b13776fc393a161225438baa92e5f87 Mon Sep 17 00:00:00 2001
From: Jason Molenda
Date: Wed, 5 Mar 2025 17:27:20 -0800
Subject: [PATCH 1/3] [lldb][Mach-O] Don't read symbol table of specially
mar
dmpots wrote:
Thanks for all the suggestions. I'll close the PR and try to make some progress
internally on this.
https://github.com/llvm/llvm-project/pull/129817
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin
https://github.com/mpark updated
https://github.com/llvm/llvm-project/pull/129982
>From 39b845fd64c2ce173b95ddcafbbab2d5116aa68e Mon Sep 17 00:00:00 2001
From: Michael Park
Date: Wed, 5 Mar 2025 18:46:10 -0800
Subject: [PATCH 1/3] [clang][modules] Add a unit test for the assertion
failure in b
https://github.com/mpark edited https://github.com/llvm/llvm-project/pull/129982
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
https://github.com/vogelsgesang commented:
Why is this still marked as draft? It looks almost ready to be merged to me 🙂
https://github.com/llvm/llvm-project/pull/130026
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/
@@ -0,0 +1,56 @@
+//===-- Transport.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: Apa
@@ -65,7 +66,7 @@ DAP::DAP(std::string name, llvm::StringRef path,
std::ofstream *log,
lldb::IOObjectSP input, lldb::IOObjectSP output, ReplMode repl_mode,
std::vector pre_init_commands)
: name(std::move(name)), debug_adapter_path(path), log(log),
-
@@ -1526,7 +1526,8 @@ static void addStatistic(lldb::SBTarget &target,
llvm::json::Object &event) {
const char *key = keys.GetStringAtIndex(i);
FilterAndGetValueForKey(statistics, key, stats_body);
}
- event.try_emplace("statistics", std::move(stats_body));
+ llvm:
@@ -0,0 +1,56 @@
+//===-- Transport.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: Apa
https://github.com/vogelsgesang edited
https://github.com/llvm/llvm-project/pull/130026
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
@@ -0,0 +1,152 @@
+//===-- Transport.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,152 @@
+//===-- Transport.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
JDevlieghere wrote:
Thanks, I've confirmed this fixes the issue for me. Ironically, it's my
MemoryMonitor patch that triggered it, I guess it caused something to get
written to stdout/stderr.
https://github.com/llvm/llvm-project/pull/129964
___
lldb
@@ -0,0 +1,15 @@
+import { LinuxProcessTree } from "./linux-process-tree";
+
+function fill(prefix: string, suffix: string, length: number): string {
+ return prefix + suffix.repeat(length - prefix.length);
+}
+
+export class DarwinProcessTree extends LinuxProcessTree {
+ protec
@@ -0,0 +1,15 @@
+import { LinuxProcessTree } from "./linux-process-tree";
+
+function fill(prefix: string, suffix: string, length: number): string {
+ return prefix + suffix.repeat(length - prefix.length);
+}
+
+export class DarwinProcessTree extends LinuxProcessTree {
+ protec
@@ -57,235 +68,288 @@ class RequestHandler {
DAP &dap;
};
-class AttachRequestHandler : public RequestHandler {
-public:
- using RequestHandler::RequestHandler;
+/// Base class for handling DAP requests. Handlers should declare their
+/// arguments and response body types l
@@ -240,6 +240,137 @@ using Message = std::variant;
bool fromJSON(const llvm::json::Value &, Message &, llvm::json::Path);
llvm::json::Value toJSON(const Message &);
+// MARK: Types
+
+// "Source": {
+// "type": "object",
+// "description": "A `Source` is a descriptor for
@@ -240,6 +240,137 @@ using Message = std::variant;
bool fromJSON(const llvm::json::Value &, Message &, llvm::json::Path);
llvm::json::Value toJSON(const Message &);
+// MARK: Types
+
+// "Source": {
+// "type": "object",
+// "description": "A `Source` is a descriptor for
https://github.com/vogelsgesang commented:
👍 I like the overall direction this is going
https://github.com/llvm/llvm-project/pull/130090
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-com
https://github.com/matthewbastien updated
https://github.com/llvm/llvm-project/pull/128943
>From b9083ea16c7b1dba70cc04acf78f5001f0fb86c6 Mon Sep 17 00:00:00 2001
From: Matthew Bastien
Date: Wed, 26 Feb 2025 11:18:21 -0500
Subject: [PATCH 01/10] add a process picker for attaching by PID
---
l
@@ -0,0 +1,52 @@
+import * as path from "path";
+import { BaseProcessTree, ProcessTreeParser } from "../base-process-tree";
+import { ChildProcessWithoutNullStreams, spawn } from "child_process";
+
+export class WindowsProcessTree extends BaseProcessTree {
+ protected override sp
Author: John Harrison
Date: 2025-03-06T13:57:06-08:00
New Revision: 27c788de759472316169795fa06d592221ac602e
URL:
https://github.com/llvm/llvm-project/commit/27c788de759472316169795fa06d592221ac602e
DIFF:
https://github.com/llvm/llvm-project/commit/27c788de759472316169795fa06d592221ac602e.diff
@@ -345,6 +356,10 @@ struct DAP {
request_handlers[Handler::getCommand()] = std::make_unique(*this);
}
+ /// Registeres an event handler for sending Debug Adapter Protocol events.
+ template
+ OutgoingEvent RegisterEvent(llvm::StringLiteral Event);
v
@@ -123,21 +126,21 @@ struct Variables {
struct StartDebuggingRequestHandler : public lldb::SBCommandPluginInterface {
DAP &dap;
- explicit StartDebuggingRequestHandler(DAP &d) : dap(d) {};
+ explicit StartDebuggingRequestHandler(DAP &d) : dap(d){};
vogels
llvm-ci wrote:
LLVM Buildbot has detected a new failure on builder `lldb-x86_64-debian`
running on `lldb-x86_64-debian` while building `lldb` at step 4 "build".
Full details are available at:
https://lab.llvm.org/buildbot/#/builders/162/builds/17524
Here is the relevant piece of the build lo
https://github.com/vogelsgesang edited
https://github.com/llvm/llvm-project/pull/130026
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
https://github.com/JDevlieghere approved this pull request.
Ship it
https://github.com/llvm/llvm-project/pull/129354
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
DavidSpickett wrote:
Yes, that fixed it.
https://github.com/llvm/llvm-project/pull/89765
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
@@ -240,6 +240,137 @@ using Message = std::variant;
bool fromJSON(const llvm::json::Value &, Message &, llvm::json::Path);
llvm::json::Value toJSON(const Message &);
+// MARK: Types
+
+// "Source": {
+// "type": "object",
+// "description": "A `Source` is a descriptor for
https://github.com/matthewbastien updated
https://github.com/llvm/llvm-project/pull/128943
>From b9083ea16c7b1dba70cc04acf78f5001f0fb86c6 Mon Sep 17 00:00:00 2001
From: Matthew Bastien
Date: Wed, 26 Feb 2025 11:18:21 -0500
Subject: [PATCH 01/11] add a process picker for attaching by PID
---
l
https://github.com/matthewbastien edited
https://github.com/llvm/llvm-project/pull/128943
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
ashgti wrote:
I didn't realize the suggestion only updated the variable name in the
parameter, sorry!
https://github.com/llvm/llvm-project/pull/130186
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/lis
llvmbot wrote:
@llvm/pr-subscribers-lldb
Author: John Harrison (ashgti)
Changes
---
Full diff: https://github.com/llvm/llvm-project/pull/130186.diff
1 Files Affected:
- (modified) lldb/tools/lldb-dap/OutputRedirector.cpp (+3-3)
``diff
diff --git a/lldb/tools/lldb-dap/Output
https://github.com/ashgti ready_for_review
https://github.com/llvm/llvm-project/pull/130186
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
@@ -57,235 +68,288 @@ class RequestHandler {
DAP &dap;
};
-class AttachRequestHandler : public RequestHandler {
-public:
- using RequestHandler::RequestHandler;
+/// Base class for handling DAP requests. Handlers should declare their
+/// arguments and response body types l
https://github.com/clayborg commented:
Is there a way we can use the LLDB platform layer to pick processes? This code,
IIUC is just running a local command to pick the process from the current host.
But people might be debugging remotely by connecting to a remote platform. The
equivalent of do
https://github.com/ashgti created
https://github.com/llvm/llvm-project/pull/130186
None
>From ab48e2c1ee83ed9068f080d2f072f4fb957e1bb7 Mon Sep 17 00:00:00 2001
From: John Harrison
Date: Thu, 6 Mar 2025 23:06:20 +0100
Subject: [PATCH] [lldb-dap] Correct the variable name from a half finished
m
Author: John Harrison
Date: 2025-03-06T14:15:30-08:00
New Revision: e4157218584bd7f02a3345a4473c9e5937f068e8
URL:
https://github.com/llvm/llvm-project/commit/e4157218584bd7f02a3345a4473c9e5937f068e8
DIFF:
https://github.com/llvm/llvm-project/commit/e4157218584bd7f02a3345a4473c9e5937f068e8.diff
@@ -146,6 +146,9 @@
"windows": {
"program": "./bin/lldb-dap.exe"
},
+"variables": {
+ "PickProcess": "lldb-dap.pickProcess"
matthewbastien wrote:
Done.
https://github.com/llvm/llvm-project/pull/128943
___
https://github.com/jasonmolenda updated
https://github.com/llvm/llvm-project/pull/129967
>From 6e258eb09b13776fc393a161225438baa92e5f87 Mon Sep 17 00:00:00 2001
From: Jason Molenda
Date: Wed, 5 Mar 2025 17:27:20 -0800
Subject: [PATCH 1/6] [lldb][Mach-O] Don't read symbol table of specially
mar
@@ -38,7 +38,7 @@ Expected OutputRedirector::GetWriteFileDescriptor() {
return m_fd;
}
-Error OutputRedirector::RedirectTo(std::FILE *file_override,
+Error OutputRedirector::RedirectTo(std::FILE *fileOverride,
JDevlieghere wrote:
But now this doesn't confor
https://github.com/dmpots closed
https://github.com/llvm/llvm-project/pull/129817
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
@@ -65,6 +65,18 @@ This will attach to a process `a.out` whose process ID is
123:
}
```
+You can also use the variable substituion `${command:pickProcess}` to select a
+process at the start of the debug session instead of setting the pid manually:
+
+```javascript
+{
+ "type
@@ -65,6 +65,18 @@ This will attach to a process `a.out` whose process ID is
123:
}
```
+You can also use the variable substituion `${command:pickProcess}` to select a
vogelsgesang wrote:
```suggestion
You can also use the variable substitution `${command:pi
https://github.com/ashgti closed
https://github.com/llvm/llvm-project/pull/130186
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
@@ -0,0 +1,81 @@
+"""
+Test that we read don't read the nlist symbols for a specially marked dylib
+when read from memory.
+"""
+
+import lldb
+from lldbsuite.test.decorators import *
+from lldbsuite.test.lldbtest import *
+from lldbsuite.test import lldbutil
+from time import sle
https://github.com/ashgti updated
https://github.com/llvm/llvm-project/pull/130026
>From a9ae73407acad86c49099f4c7eba914e639f0850 Mon Sep 17 00:00:00 2001
From: John Harrison
Date: Thu, 6 Mar 2025 10:18:36 +0100
Subject: [PATCH] [lldb-dap] Refactoring IOStream into Transport handler.
Instead o
llvmbot wrote:
@llvm/pr-subscribers-lldb
Author: John Harrison (ashgti)
Changes
Instead of having two discrete InputStream and OutputStream helpers, this
merges the two into a unifed 'Transport' handler.
This handler is responsible for reading the DAP message headers, parsing the
result
@@ -722,40 +683,9 @@ void DAP::SetTarget(const lldb::SBTarget target) {
}
}
-PacketStatus DAP::GetNextObject(llvm::json::Object &object) {
- std::string json = ReadJSON();
- if (json.empty())
-return PacketStatus::EndOfFile;
-
- llvm::StringRef json_sref(json);
- llv
@@ -0,0 +1,56 @@
+//===-- Transport.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: Apa
@@ -1526,7 +1526,8 @@ static void addStatistic(lldb::SBTarget &target,
llvm::json::Object &event) {
const char *key = keys.GetStringAtIndex(i);
FilterAndGetValueForKey(statistics, key, stats_body);
}
- event.try_emplace("statistics", std::move(stats_body));
+ llvm:
@@ -237,65 +238,25 @@ void DAP::StopEventHandlers() {
}
}
-// Send the JSON in "json_str" to the "out" stream. Correctly send the
-// "Content-Length:" field followed by the length, followed by the raw
-// JSON bytes.
-void DAP::SendJSON(const std::string &json_str) {
- out
https://github.com/ashgti ready_for_review
https://github.com/llvm/llvm-project/pull/130026
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
@@ -0,0 +1,152 @@
+//===-- Transport.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
https://github.com/jasonmolenda updated
https://github.com/llvm/llvm-project/pull/129967
>From 6e258eb09b13776fc393a161225438baa92e5f87 Mon Sep 17 00:00:00 2001
From: Jason Molenda
Date: Wed, 5 Mar 2025 17:27:20 -0800
Subject: [PATCH 1/7] [lldb][Mach-O] Don't read symbol table of specially
mar
@@ -256,7 +257,27 @@ void DAP::SendJSON(const llvm::json::Value &json) {
}
return;
}
- auto status = transport.Write(log, M);
+ Send(M);
+}
+
+void DAP::Send(const protocol::Message &M) {
+ lldb_private::Status status;
+ // If the debugger was interrupted while ha
@@ -0,0 +1,56 @@
+//===-- SourceRequestHandler.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
https://github.com/vogelsgesang edited
https://github.com/llvm/llvm-project/pull/130169
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
https://github.com/anjenner updated
https://github.com/llvm/llvm-project/pull/115331
>From 3fdba46d41ad9668a114766fe892af497f121cd5 Mon Sep 17 00:00:00 2001
From: Andrew Jenner
Date: Thu, 7 Nov 2024 10:47:42 -0500
Subject: [PATCH 1/7] Modify the localCache API to require an explicit commit
on
https://github.com/jasonmolenda updated
https://github.com/llvm/llvm-project/pull/129967
>From 6e258eb09b13776fc393a161225438baa92e5f87 Mon Sep 17 00:00:00 2001
From: Jason Molenda
Date: Wed, 5 Mar 2025 17:27:20 -0800
Subject: [PATCH 1/4] [lldb][Mach-O] Don't read symbol table of specially
mar
https://github.com/anjenner updated
https://github.com/llvm/llvm-project/pull/115331
>From 3fdba46d41ad9668a114766fe892af497f121cd5 Mon Sep 17 00:00:00 2001
From: Andrew Jenner
Date: Thu, 7 Nov 2024 10:47:42 -0500
Subject: [PATCH 1/7] Modify the localCache API to require an explicit commit
on
https://github.com/anjenner updated
https://github.com/llvm/llvm-project/pull/115331
>From 3fdba46d41ad9668a114766fe892af497f121cd5 Mon Sep 17 00:00:00 2001
From: Andrew Jenner
Date: Thu, 7 Nov 2024 10:47:42 -0500
Subject: [PATCH 1/8] Modify the localCache API to require an explicit commit
on
JDevlieghere wrote:
The two commits that change `GetSigned` and `GetUnsigned` are no longer
necessary after #129823. The commit that updates `GetString` looks fine.
Thinking out loud: I see a handful of cases where we can check the optional
(like should we pass "--launch-target" if there's no
@@ -0,0 +1,81 @@
+"""
+Test that we read don't read the nlist symbols for a specially marked dylib
+when read from memory.
+"""
+
+import lldb
+from lldbsuite.test.decorators import *
+from lldbsuite.test.lldbtest import *
+from lldbsuite.test import lldbutil
+from time import sle
@@ -36,7 +38,8 @@ Expected OutputRedirector::GetWriteFileDescriptor() {
return m_fd;
}
-Error OutputRedirector::RedirectTo(std::function callback) {
+Error OutputRedirector::RedirectTo(std::FILE *override,
JDevlieghere wrote:
Let's avoid using a keyword.
``
oontvoo wrote:
@JDevlieghere Hi, do you have any other comment for this PR? :pray:
https://github.com/llvm/llvm-project/pull/129354
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
https://github.com/Michael137 closed
https://github.com/llvm/llvm-project/pull/129733
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
Author: Michael Buch
Date: 2025-03-06T21:07:22Z
New Revision: 542d52b1e8a0a7e04538f608487603124c70e1ab
URL:
https://github.com/llvm/llvm-project/commit/542d52b1e8a0a7e04538f608487603124c70e1ab
DIFF:
https://github.com/llvm/llvm-project/commit/542d52b1e8a0a7e04538f608487603124c70e1ab.diff
LOG:
https://github.com/JDevlieghere edited
https://github.com/llvm/llvm-project/pull/129354
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
@@ -66,6 +80,52 @@ struct LLDBBaseTelemetryInfo : public
llvm::telemetry::TelemetryInfo {
void serialize(llvm::telemetry::Serializer &serializer) const override;
};
+struct CommandInfo : public LLDBBaseTelemetryInfo {
+ /// If the command is/can be associated with a target
https://github.com/ashgti updated
https://github.com/llvm/llvm-project/pull/129964
>From bcecf0c2aa0d398478734f24a9913cb398167e66 Mon Sep 17 00:00:00 2001
From: John Harrison
Date: Thu, 6 Mar 2025 02:05:46 +0100
Subject: [PATCH 1/2] [lldb-dap] Restore the override FD used by the output
redirec
ashgti wrote:
> Why is this still marked as draft? It looks almost ready to be merged to me 🙂
I was going to wait for #129964 first so I didn't have to many PRs on top of
PRs (github PRs don't stack well, at least IMO).
https://github.com/llvm/llvm-project/pull/130026
_
https://github.com/JDevlieghere approved this pull request.
https://github.com/llvm/llvm-project/pull/129605
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
JDevlieghere wrote:
+1 on everything @DavidSpickett said. We're doing pretty much the same thing
for our CI.
https://github.com/llvm/llvm-project/pull/129817
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mai
Jlalond wrote:
@JDevlieghere I should've closed this, but I'm actually going to fix a couple
spots around the codebase. It looks like Swig will give a codeblock on `::`,
looking at `SBTarget.docstrings.i`. So I'm going to reuse this patch to fix
atleast SBProcess, SBProgress, and I think Memor
101 - 176 of 176 matches
Mail list logo