[Lldb-commits] [lldb] [lldb/DWARF] Remove "range lower than function low_pc" check (PR #132395)

2025-04-22 Thread Pavel Labath via lldb-commits
https://github.com/labath updated https://github.com/llvm/llvm-project/pull/132395 >From 3326940bbae82afa6b19e1ee696447a39ea3723b Mon Sep 17 00:00:00 2001 From: Pavel Labath Date: Fri, 21 Mar 2025 14:04:12 +0100 Subject: [PATCH 1/2] [lldb/DWARF] Remove "range lower than function low_pc" check

[Lldb-commits] [lldb] [lldb/DWARF] Remove "range lower than function low_pc" check (PR #132395)

2025-04-22 Thread Pavel Labath via lldb-commits
https://github.com/labath updated https://github.com/llvm/llvm-project/pull/132395 >From 3326940bbae82afa6b19e1ee696447a39ea3723b Mon Sep 17 00:00:00 2001 From: Pavel Labath Date: Fri, 21 Mar 2025 14:04:12 +0100 Subject: [PATCH 1/2] [lldb/DWARF] Remove "range lower than function low_pc" check

[Lldb-commits] [lldb] [lldb/DWARF] Remove "range lower than function low_pc" check (PR #132395)

2025-04-22 Thread Pavel Labath via lldb-commits
@@ -42,6 +27,21 @@ look_me_up: .size foo.__part.1, .Lfoo.__part.1_end-foo.__part.1 +bar: +nop +.Lbar_end: +.size bar, .Lbar_end-bar + +.type foo,@function +foo: labath wrote: (and yes, `look_me_up` is in the middle of th

[Lldb-commits] [lldb] [lldb/DWARF] Remove "range lower than function low_pc" check (PR #132395)

2025-04-22 Thread Pavel Labath via lldb-commits
@@ -42,6 +27,21 @@ look_me_up: .size foo.__part.1, .Lfoo.__part.1_end-foo.__part.1 +bar: +nop +.Lbar_end: +.size bar, .Lbar_end-bar + +.type foo,@function +foo: labath wrote: It's because the range `[.Lfoo_inl.__part.1,

[Lldb-commits] [lldb] [lldb/DWARF] Remove "range lower than function low_pc" check (PR #132395)

2025-04-22 Thread Pavel Labath via lldb-commits
labath wrote: > I think this relates to: > > > 2.17 Code Addresses, Ranges and Base Addresses > > <...> > > The base address of the scope for any of the debugging information entries > > listed > > above is given by either the DW_AT_low_pc attribute or the first address in > > the > > first ra

[Lldb-commits] [lldb] [lldb/DWARF] Remove "range lower than function low_pc" check (PR #132395)

2025-04-22 Thread Pavel Labath via lldb-commits
labath wrote: The priority of this has increased from "it's a niche feature only used by google" to "it's used by *everyone*" because (as I was made aware of at the dev meeting), gcc has started producing functions like this on a regular basis. In particular the dynamic loader in the next debi

[Lldb-commits] [lldb] [lldb] Use correct path for debugserver (PR #131609)

2025-04-22 Thread Pavel Labath via lldb-commits
labath wrote: FYI, I reverted this because of problems test failures on mac: https://green.lab.llvm.org/job/llvm.org/view/LLDB/job/as-lldb-cmake/24395/testReport/junit/lldb-api/commands_target_auto-install-main-executable/TestAutoInstallMainExecutable_py/ I'm not quite sure what's happening, bu

[Lldb-commits] [lldb] 616e8cc - Revert "[lldb] Use correct path for debugserver (#131609)"

2025-04-22 Thread Pavel Labath via lldb-commits
Author: Pavel Labath Date: 2025-04-22T15:35:53+02:00 New Revision: 616e8cc1fa0319819aa6978af0af9a3e4896103a URL: https://github.com/llvm/llvm-project/commit/616e8cc1fa0319819aa6978af0af9a3e4896103a DIFF: https://github.com/llvm/llvm-project/commit/616e8cc1fa0319819aa6978af0af9a3e4896103a.diff

[Lldb-commits] [lldb] [lldb/DWARF] Remove "range lower than function low_pc" check (PR #132395)

2025-04-22 Thread Pavel Labath via lldb-commits
labath wrote: ping ping :) https://github.com/llvm/llvm-project/pull/132395 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] 587206a - [lldb] Avoid modifying the source tree in TestPlatformLaunchGDBServer

2025-04-22 Thread Pavel Labath via lldb-commits
Author: Pavel Labath Date: 2025-04-22T14:41:59+02:00 New Revision: 587206a442ebb656f9d72e7e0cc5845ef3a2f7ed URL: https://github.com/llvm/llvm-project/commit/587206a442ebb656f9d72e7e0cc5845ef3a2f7ed DIFF: https://github.com/llvm/llvm-project/commit/587206a442ebb656f9d72e7e0cc5845ef3a2f7ed.diff

[Lldb-commits] [lldb] [lldb] Preparation for DWARF indexing speedup (PR #123732)

2025-04-22 Thread Pavel Labath via lldb-commits
labath wrote: ping https://github.com/llvm/llvm-project/pull/123732 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Preparation for DWARF indexing speedup (PR #123732)

2025-04-22 Thread Pavel Labath via lldb-commits
https://github.com/labath updated https://github.com/llvm/llvm-project/pull/123732 >From 68b192e29131d04f38474b7ad44e84aff41a8c21 Mon Sep 17 00:00:00 2001 From: Pavel Labath Date: Tue, 21 Jan 2025 11:50:31 +0100 Subject: [PATCH] [lldb] Preparation for DWARF indexing speedup This is part of the

[Lldb-commits] [lldb] [lldb] Slide eh_frame unwind plan if it doesn't begin at function boundary (PR #135333)

2025-04-22 Thread Pavel Labath via lldb-commits
https://github.com/labath closed https://github.com/llvm/llvm-project/pull/135333 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][AIX] get host info for AIX (PR #134354)

2025-04-22 Thread Pavel Labath via lldb-commits
@@ -40,8 +40,9 @@ TEST_F(HostTest, GetProcessInfo) { triple.getEnvironment() == llvm::Triple::EnvironmentType::Android)); ProcessInstanceInfo Info; +#ifndef _AIX labath wrote: In that case, what would say to filtering this process out inside the AIX

[Lldb-commits] [lldb] [lldb] Make the statusline separator configurable (PR #136611)

2025-04-22 Thread Pavel Labath via lldb-commits
labath wrote: IIUC, the `${separator}` thingy could be used in places other than the status line, so maybe the setting controlling it shouldn't be called `statusline-separator` ? https://github.com/llvm/llvm-project/pull/136611 ___ lldb-commits maili

[Lldb-commits] [lldb] Fix connecting via abstract socket (PR #136466)

2025-04-22 Thread Pavel Labath via lldb-commits
labath wrote: Agreed https://github.com/llvm/llvm-project/pull/136466 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Use correct path for debugserver (PR #131609)

2025-04-22 Thread Pavel Labath via lldb-commits
labath wrote: > > I can push the button for you if you could just update the patch > > description to what you'd like the commit message to say (in particular, I > > think the last paragraph is no longer correct). > > As for cherry-picking, is this related to the lldb-server platform refactor

[Lldb-commits] [lldb] [lldb] Use correct path for debugserver (PR #131609)

2025-04-22 Thread Pavel Labath via lldb-commits
https://github.com/labath closed https://github.com/llvm/llvm-project/pull/131609 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Clean up StartDebugserverProcess before I start refactoring it (PR #135342)

2025-04-22 Thread Pavel Labath via lldb-commits
https://github.com/labath closed https://github.com/llvm/llvm-project/pull/135342 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][AIX] get host info for AIX (PR #134354)

2025-04-22 Thread Pavel Labath via lldb-commits
@@ -40,8 +40,9 @@ TEST_F(HostTest, GetProcessInfo) { triple.getEnvironment() == llvm::Triple::EnvironmentType::Android)); ProcessInstanceInfo Info; +#ifndef _AIX labath wrote: I see... Well, that could be a bit tricky (not just for this test, but in

[Lldb-commits] [lldb] [lldb][DataFormatter] Surface CalculateNumChildren errors in std::vector summary (PR #135944)

2025-04-22 Thread Pavel Labath via lldb-commits
labath wrote: cool https://github.com/llvm/llvm-project/pull/135944 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][AIX] get host info for AIX (PR #134354)

2025-04-22 Thread Pavel Labath via lldb-commits
@@ -7,21 +7,24 @@ //===--===// #include "lldb/Host/linux/Support.h" +#include "lldb/Host/posix/Support.h" #include "llvm/Support/Threading.h" #include "gtest/gtest.h" using namespace lldb_private; TES

[Lldb-commits] [lldb] [lldb][AIX] get host info for AIX (PR #134354)

2025-04-22 Thread Pavel Labath via lldb-commits
@@ -7,17 +7,135 @@ //===--===// #include "lldb/Host/Host.h" +#include "lldb/Host/posix/Support.h" +#include "lldb/Utility/LLDBLog.h" +#include "lldb/Utility/Log.h" +#include "lldb/Utility/ProcessInfo.h" #inc

[Lldb-commits] [lldb] [lldb][AIX] get host info for AIX (PR #134354)

2025-04-22 Thread Pavel Labath via lldb-commits
@@ -7,21 +7,24 @@ //===--===// #include "lldb/Host/linux/Support.h" +#include "lldb/Host/posix/Support.h" #include "llvm/Support/Threading.h" #include "gtest/gtest.h" using namespace lldb_private; TES

[Lldb-commits] [lldb] [lldb][AIX] get host info for AIX (PR #134354)

2025-04-22 Thread Pavel Labath via lldb-commits
https://github.com/labath commented: Looks pretty good. Just a couple of details. https://github.com/llvm/llvm-project/pull/134354 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][AIX] get host info for AIX (PR #134354)

2025-04-22 Thread Pavel Labath via lldb-commits
@@ -40,8 +40,9 @@ TEST_F(HostTest, GetProcessInfo) { triple.getEnvironment() == llvm::Triple::EnvironmentType::Android)); ProcessInstanceInfo Info; +#ifndef _AIX labath wrote: Why is that? Does process zero exist on AIX? https://github.com/llvm/llvm

[Lldb-commits] [lldb] [lldb][AIX] get host info for AIX (PR #134354)

2025-04-22 Thread Pavel Labath via lldb-commits
@@ -15,10 +15,10 @@ set (FILES XMLTest.cpp ) -if (CMAKE_SYSTEM_NAME MATCHES "Linux|Android") +if (CMAKE_SYSTEM_NAME MATCHES "Linux|Android|AIX") labath wrote: ```suggestion if (UNIX) ``` If individual tests fail on some systems. We can disable them there.

[Lldb-commits] [lldb] [lldb][AIX] get host info for AIX (PR #134354)

2025-04-22 Thread Pavel Labath via lldb-commits
https://github.com/labath edited https://github.com/llvm/llvm-project/pull/134354 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Clean up StartDebugserverProcess before I start refactoring it (PR #135342)

2025-04-22 Thread Pavel Labath via lldb-commits
https://github.com/labath updated https://github.com/llvm/llvm-project/pull/135342 >From 932830b169fd28f536382639a2bc46482962866d Mon Sep 17 00:00:00 2001 From: Pavel Labath Date: Fri, 11 Apr 2025 12:06:15 +0200 Subject: [PATCH] [lldb] Clean up StartDebugserverProcess before I start refactorin

[Lldb-commits] [lldb] [lldb/cmake] Normalize use of HAVE_LIBCOMPRESSION (PR #135528)

2025-04-22 Thread Pavel Labath via lldb-commits
https://github.com/labath closed https://github.com/llvm/llvm-project/pull/135528 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Clean up StartDebugserverProcess before I start refactoring it (PR #135342)

2025-04-22 Thread Pavel Labath via lldb-commits
https://github.com/labath updated https://github.com/llvm/llvm-project/pull/135342 >From 966b50e5a2a8cf7508d2b00f04ff2758d1420c30 Mon Sep 17 00:00:00 2001 From: Pavel Labath Date: Fri, 11 Apr 2025 12:06:15 +0200 Subject: [PATCH] [lldb] Clean up StartDebugserverProcess before I start refactorin

[Lldb-commits] [lldb] [lldb] Fix lock inversion between statusline mutex and output mutex (PR #135956)

2025-04-16 Thread Pavel Labath via lldb-commits
https://github.com/labath approved this pull request. https://github.com/llvm/llvm-project/pull/135956 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [LLDB] Add unary operators Dereference and AddressOf to DIL (PR #134428)

2025-04-14 Thread Pavel Labath via lldb-commits
@@ -18,6 +18,22 @@ namespace lldb_private::dil { +static lldb::ValueObjectSP +ArrayToPointerConversion(lldb::ValueObjectSP valobj, + std::shared_ptr ctx) { + assert(valobj->IsArrayType() && + "an argument to array-to-pointer conversion must be

[Lldb-commits] [lldb] [lldb] Remove ProcessRunLock::TrySetRunning (PR #135455)

2025-04-13 Thread Pavel Labath via lldb-commits
labath wrote: Thanks for looking into this. https://github.com/llvm/llvm-project/pull/135455 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Remove ProcessRunLock::TrySetRunning (PR #135455)

2025-04-13 Thread Pavel Labath via lldb-commits
https://github.com/labath edited https://github.com/llvm/llvm-project/pull/135455 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Remove ProcessRunLock::TrySetRunning (PR #135455)

2025-04-13 Thread Pavel Labath via lldb-commits
@@ -60,6 +49,7 @@ bool ProcessRunLock::SetStopped() { ::pthread_rwlock_unlock(&m_rwlock); labath wrote: This should also do the `was_running` dance. https://github.com/llvm/llvm-project/pull/135455 ___ lldb-commits

[Lldb-commits] [lldb] [lldb] Remove ProcessRunLock::TrySetRunning (PR #135455)

2025-04-13 Thread Pavel Labath via lldb-commits
https://github.com/labath approved this pull request. I was looking at this code as well, and I've (also) came to the conclusion that `TrySetRunning` is a problem. https://github.com/llvm/llvm-project/pull/135455 ___ lldb-commits mailing list lldb-com

[Lldb-commits] [lldb] [lldb] Remove ProcessRunLock::TrySetRunning (PR #135455)

2025-04-13 Thread Pavel Labath via lldb-commits
@@ -29,8 +29,13 @@ class ProcessRunLock { bool ReadTryLock(); bool ReadUnlock(); + + /// Set the process to running. Returns true if the process was stopped. + /// Return false if the process was running. bool SetRunning(); - bool TrySetRunning(); + + /// Set the pr

[Lldb-commits] [lldb] 1c5ce2d - Reapply "[lldb] ProcessGdbRemote header gardning"

2025-04-13 Thread Pavel Labath via lldb-commits
Author: Pavel Labath Date: 2025-04-13T09:52:30+02:00 New Revision: 1c5ce2d74fa3ee15d1cb2e092cce0754c8ce19fa URL: https://github.com/llvm/llvm-project/commit/1c5ce2d74fa3ee15d1cb2e092cce0754c8ce19fa DIFF: https://github.com/llvm/llvm-project/commit/1c5ce2d74fa3ee15d1cb2e092cce0754c8ce19fa.diff

[Lldb-commits] [lldb] [lldb/cmake] Normalize use of HAVE_LIBCOMPRESSION (PR #135528)

2025-04-13 Thread Pavel Labath via lldb-commits
https://github.com/labath created https://github.com/llvm/llvm-project/pull/135528 I *think* this was the reason behind the failures in 2fd860c1f559c0b0be66cc000e38270a04d0a1a3: the clang include tool showed the Config.h headers as unused, and because the macro was referenced through an `#ifd

[Lldb-commits] [lldb] [lldb] Remove vestigial remnants of reproducers (PR #135361)

2025-04-12 Thread Pavel Labath via lldb-commits
https://github.com/labath closed https://github.com/llvm/llvm-project/pull/135361 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Remove vestigial remnants of reproducers (PR #135361)

2025-04-11 Thread Pavel Labath via lldb-commits
https://github.com/labath created https://github.com/llvm/llvm-project/pull/135361 Not touching the SB API. >From 092a72d271372030f530521dabb3559aebb306fe Mon Sep 17 00:00:00 2001 From: Pavel Labath Date: Fri, 11 Apr 2025 14:51:59 +0200 Subject: [PATCH] [lldb] Remove vestigial remnants of repr

[Lldb-commits] [lldb] [lldb] Make sure the process is stopped when computing the symbol context (PR #134757)

2025-04-11 Thread Pavel Labath via lldb-commits
labath wrote: I can see this too, and can reproduce it pretty much 100% of the time. The `GetRunLock` hypothesis seems believable because the process launching code (Process::LaunchPrivate) is mucking around with the private state thread. It's also possible this doesn't reproduce on darwin bec

[Lldb-commits] [libcxxabi] [lldb] [llvm] [lldb] Add frame-format option to highlight function names in backtraces (PR #131836)

2025-04-11 Thread Pavel Labath via lldb-commits
@@ -2074,6 +2076,64 @@ static const Definition *FindEntry(const llvm::StringRef &format_str, return parent; } +/// Parses a single highlighting format specifier. +/// +/// Example syntax for such specifier: +/// \code +/// ${function.name-with-args:%highlight_basename(ansi.

[Lldb-commits] [libcxxabi] [lldb] [llvm] [lldb] Add frame-format option to highlight function names in backtraces (PR #131836)

2025-04-11 Thread Pavel Labath via lldb-commits
@@ -208,6 +209,152 @@ static bool PrettyPrintFunctionNameWithArgs(Stream &out_stream, return true; } +static std::optional GetDemangledBasename(Function &function) { + auto demangled_name = function.GetName().GetStringRef(); + if (demangled_name.empty()) +return std:

[Lldb-commits] [libcxxabi] [lldb] [llvm] [lldb] Add frame-format option to highlight function names in backtraces (PR #131836)

2025-04-11 Thread Pavel Labath via lldb-commits
https://github.com/labath commented: Just some drive-by comments. https://github.com/llvm/llvm-project/pull/131836 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [libcxxabi] [lldb] [llvm] [lldb] Add frame-format option to highlight function names in backtraces (PR #131836)

2025-04-11 Thread Pavel Labath via lldb-commits
@@ -208,6 +209,152 @@ static bool PrettyPrintFunctionNameWithArgs(Stream &out_stream, return true; } +static std::optional GetDemangledBasename(Function &function) { + auto demangled_name = function.GetName().GetStringRef(); + if (demangled_name.empty()) +return std:

[Lldb-commits] [libcxxabi] [lldb] [llvm] [lldb] Add frame-format option to highlight function names in backtraces (PR #131836)

2025-04-11 Thread Pavel Labath via lldb-commits
@@ -0,0 +1,60 @@ +# Test the ${function.arguments} frame-format variable. labath wrote: Probably better to factor this according to the language dimension, since the objc parts will most likely need to be disabled on non-macosx. https://github.com/llvm/llvm-pr

[Lldb-commits] [libcxxabi] [lldb] [llvm] [lldb] Add frame-format option to highlight function names in backtraces (PR #131836)

2025-04-11 Thread Pavel Labath via lldb-commits
@@ -122,7 +122,14 @@ constexpr Definition g_function_child_entries[] = { Definition("pc-offset", EntryType::FunctionPCOffset), Definition("initial-function", EntryType::FunctionInitial), Definition("changed", EntryType::FunctionChanged), -Definition("is-optimize

[Lldb-commits] [libcxxabi] [lldb] [llvm] [lldb] Add frame-format option to highlight function names in backtraces (PR #131836)

2025-04-11 Thread Pavel Labath via lldb-commits
https://github.com/labath edited https://github.com/llvm/llvm-project/pull/131836 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][Format] Display only the inlined frame name in backtraces if available (PR #135343)

2025-04-11 Thread Pavel Labath via lldb-commits
labath wrote: I think this is a good idea. https://github.com/llvm/llvm-project/pull/135343 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Slide eh_frame unwind plan if it doesn't begin at function boundary (PR #135333)

2025-04-11 Thread Pavel Labath via lldb-commits
https://github.com/labath created https://github.com/llvm/llvm-project/pull/135333 This is mainly useful for discontinuous functions because individual parts of the function will have separate FDE entries, which can begin many megabytes from the start of the function. However, I'm separating i

[Lldb-commits] [lldb] [lldb] Slide eh_frame unwind plan if it doesn't begin at function boundary (PR #135333)

2025-04-11 Thread Pavel Labath via lldb-commits
@@ -474,7 +474,7 @@ bool UnwindPlan::PlanValidAtAddress(Address addr) const { // If the 0th Row of unwind instructions is missing, or if it doesn't provide // a register to use to find the Canonical Frame Address, this is not a valid // UnwindPlan. - const Row *row0 = Ge

[Lldb-commits] [lldb] [lldb][Format][NFCI] Refactor CPlusPlusLanguage::GetFunctionDisplayName into helpers and use LLVM style (PR #135331)

2025-04-11 Thread Pavel Labath via lldb-commits
https://github.com/labath approved this pull request. https://github.com/llvm/llvm-project/pull/135331 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Small refactor of eh_frame parsing (PR #134806)

2025-04-11 Thread Pavel Labath via lldb-commits
https://github.com/labath closed https://github.com/llvm/llvm-project/pull/134806 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Synchronize access to m_statusline in the Debugger (PR #134759)

2025-04-11 Thread Pavel Labath via lldb-commits
https://github.com/labath approved this pull request. :ship: https://github.com/llvm/llvm-project/pull/134759 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [LLDB] Add unary operators Dereference and AddressOf to DIL (PR #134428)

2025-04-11 Thread Pavel Labath via lldb-commits
@@ -18,6 +18,22 @@ namespace lldb_private::dil { +static lldb::ValueObjectSP +ArrayToPointerConversion(lldb::ValueObjectSP valobj, + std::shared_ptr ctx) { + assert(valobj->IsArrayType() && + "an argument to array-to-pointer conversion must be

[Lldb-commits] [lldb] [lldb] Handle signals in a separate thread in the driver (PR #134956)

2025-04-10 Thread Pavel Labath via lldb-commits
labath wrote: I kinda like signalfd(2), although the implementation makes it kinda hard to use in environments you don't fully control. For one, it requires that the signal you're listening to is blocked on *all* threads in the process. If any thread unblocks it for any reason, you will miss t

[Lldb-commits] [lldb] [lldb] Handle signals in a separate thread in the driver (PR #134956)

2025-04-10 Thread Pavel Labath via lldb-commits
@@ -824,5 +834,11 @@ int main(int argc, char const *argv[]) { future.wait(); } + // Stop the signal handler thread. Do this after calling SBDebugger::Terminate + // so that impatient users can send a SIGSTOP if they don't want to wait for labath wrote

[Lldb-commits] [lldb] [LLDB][MIPS] Fix signal SIGBUS number mismatch error on mips target (PR #132688)

2025-04-10 Thread Pavel Labath via lldb-commits
https://github.com/labath closed https://github.com/llvm/llvm-project/pull/132688 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Remove unused UnwindPlan functions (PR #134630)

2025-04-10 Thread Pavel Labath via lldb-commits
https://github.com/labath created https://github.com/llvm/llvm-project/pull/134630 `GetLSDAAddress` and `GetPersonalityRoutinePtrAddress` are unused and they create a bit of a problem for discontinuous functions, because the unwind plan for these consists of multiple eh_frame descriptors and (

[Lldb-commits] [lldb] [lldb] Support negative function offsets in UnwindPlans (PR #134662)

2025-04-10 Thread Pavel Labath via lldb-commits
https://github.com/labath created https://github.com/llvm/llvm-project/pull/134662 These are needed for functions whose entry point is not their lowest address. >From 10a1029d776bf5dcae5fe69a72883916de7c4b5f Mon Sep 17 00:00:00 2001 From: Pavel Labath Date: Fri, 4 Apr 2025 11:37:34 +0200 Subje

[Lldb-commits] [lldb] [lldb] Remove unused UnwindPlan functions (PR #134630)

2025-04-10 Thread Pavel Labath via lldb-commits
https://github.com/labath updated https://github.com/llvm/llvm-project/pull/134630 >From ab6dc42c00fd52a0551ec59cfddb012bc56da277 Mon Sep 17 00:00:00 2001 From: Pavel Labath Date: Fri, 4 Apr 2025 12:05:18 +0200 Subject: [PATCH] [lldb] Remove unused UnwindPlan functions `GetLSDAAddress` and `Ge

[Lldb-commits] [lldb] [LLDB] Add unary operators Dereference and AddressOf to DIL (PR #134428)

2025-04-10 Thread Pavel Labath via lldb-commits
labath wrote: > Is it a general consensus that people shouldn't use unit tests anymore? They shouldn't use unit tests for building debug subjects. https://github.com/llvm/llvm-project/pull/134428 ___ lldb-commits mailing list lldb-commits@lists.llvm.o

[Lldb-commits] [lldb] [lldb][AIX] get host info for AIX (PR #134354)

2025-04-10 Thread Pavel Labath via lldb-commits
@@ -141,6 +141,7 @@ else() add_host_subdirectory(aix aix/Host.cpp aix/HostInfoAIX.cpp + linux/Support.cpp labath wrote: This PR is small enough, so I think you can just do it here. At least it will have context for why you're doing this.

[Lldb-commits] [lldb] [lldb] Handle signals in a separate thread in the driver (PR #134956)

2025-04-10 Thread Pavel Labath via lldb-commits
https://github.com/labath commented: Yeah, I'm afraid this isn't the right way to use the MainLoop with signals. `AddPendingCallback` is not signal-safe. You need to actually let the main loop handle the signals (MainLoopPosix::RegisterSignal), as it knows how to do that safely. The function i

[Lldb-commits] [lldb] [lldb] Small refactor of eh_frame parsing (PR #134806)

2025-04-10 Thread Pavel Labath via lldb-commits
https://github.com/labath updated https://github.com/llvm/llvm-project/pull/134806 >From eeaad560a727ea2b113ab3eff218f66a46e30c83 Mon Sep 17 00:00:00 2001 From: Pavel Labath Date: Fri, 4 Apr 2025 13:36:06 +0200 Subject: [PATCH 1/2] [lldb] Small refactor of eh_frame parsing .. which prepares us

[Lldb-commits] [lldb] [lldb] Use correct path for debugserver (PR #131609)

2025-04-10 Thread Pavel Labath via lldb-commits
labath wrote: I can push the button for you if you could just update the patch description to what you'd like the commit message to say (in particular, I think the last paragraph is no longer correct). As for cherry-picking, is this related to the lldb-server platform refactor in any way, or

[Lldb-commits] [lldb] [LLDB] Add unary operators Dereference and AddressOf to DIL (PR #134428)

2025-04-10 Thread Pavel Labath via lldb-commits
labath wrote: > > I'm also not very convinced by this "FlowAnalysis" thingy. Is it supposed > > to be a performance optimization (collapsing *&foo to foo) or does it do > > something more? > > FlowAnalysis is also used in subscript operator, to short-circuit getting an > address of an element

[Lldb-commits] [lldb] [lldb] Small refactor of eh_frame parsing (PR #134806)

2025-04-10 Thread Pavel Labath via lldb-commits
https://github.com/labath updated https://github.com/llvm/llvm-project/pull/134806 >From f16fb6541556f5e82825207064f5f7bb6b3cd343 Mon Sep 17 00:00:00 2001 From: Pavel Labath Date: Fri, 4 Apr 2025 11:37:34 +0200 Subject: [PATCH 1/4] [lldb] Support negative function offsets in UnwindPlans These

[Lldb-commits] [lldb] [lldb][AIX] get host info for AIX (PR #134354)

2025-04-10 Thread Pavel Labath via lldb-commits
labath wrote: > > We have a tests for this function in `unittests/Host/linux/HostTest.cpp` > > and it looks like at least some of it should apply to other systems as > > well. We could move it to the "posix" folder so that it applies to your > > code as well. Depending on the size of linux-spe

[Lldb-commits] [lldb] [lldb] Synchronize access to m_statusline in the Debugger (PR #134759)

2025-04-09 Thread Pavel Labath via lldb-commits
@@ -391,8 +392,13 @@ bool Debugger::SetTerminalWidth(uint64_t term_width) { if (auto handler_sp = m_io_handler_stack.Top()) handler_sp->TerminalSizeChanged(); - if (m_statusline) -m_statusline->TerminalSizeChanged(); + + { +// This might get called from a signa

[Lldb-commits] [libcxxabi] [lldb] [llvm] [lldb] Add frame-format option to highlight function names in backtraces (PR #131836)

2025-04-09 Thread Pavel Labath via lldb-commits
@@ -2074,6 +2076,64 @@ static const Definition *FindEntry(const llvm::StringRef &format_str, return parent; } +/// Parses a single highlighting format specifier. +/// +/// Example syntax for such specifier: +/// \code +/// ${function.name-with-args:%highlight_basename(ansi.

[Lldb-commits] [lldb] [lldb] Handle signals in a separate thread in the driver (PR #134956)

2025-04-09 Thread Pavel Labath via lldb-commits
@@ -794,6 +800,10 @@ int main(int argc, char const *argv[]) { signal(SIGTSTP, sigtstp_handler); #endif + // Run the signal handling MainLoop on a separate thread. + std::thread signal_thread([] { g_signal_loop.Run(); }); + signal_thread.detach(); labath w

[Lldb-commits] [lldb] [lldb] Support negative function offsets in UnwindPlans (PR #134662)

2025-04-09 Thread Pavel Labath via lldb-commits
https://github.com/labath updated https://github.com/llvm/llvm-project/pull/134662 >From 26b46c0f0e3bdb56afed5fb1e9ab1dd577a3ad66 Mon Sep 17 00:00:00 2001 From: Pavel Labath Date: Fri, 4 Apr 2025 11:37:34 +0200 Subject: [PATCH 1/2] [lldb] Support negative function offsets in UnwindPlans These

[Lldb-commits] [lldb] [lldb] Remove unused UnwindPlan functions (PR #134630)

2025-04-09 Thread Pavel Labath via lldb-commits
https://github.com/labath updated https://github.com/llvm/llvm-project/pull/134630 >From ab6dc42c00fd52a0551ec59cfddb012bc56da277 Mon Sep 17 00:00:00 2001 From: Pavel Labath Date: Fri, 4 Apr 2025 12:05:18 +0200 Subject: [PATCH] [lldb] Remove unused UnwindPlan functions `GetLSDAAddress` and `Ge

[Lldb-commits] [lldb] [LLDB][MIPS] Fix signal SIGBUS number mismatch error on mips target (PR #132688)

2025-04-09 Thread Pavel Labath via lldb-commits
labath wrote: The patch (still) looks good. I think what you need is for someone to push the submit button, so I'll do that now. https://github.com/llvm/llvm-project/pull/132688 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.l

[Lldb-commits] [lldb] [lldb] Remove unused UnwindPlan functions (PR #134630)

2025-04-09 Thread Pavel Labath via lldb-commits
https://github.com/labath closed https://github.com/llvm/llvm-project/pull/134630 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Remove unused UnwindPlan functions (PR #134630)

2025-04-09 Thread Pavel Labath via lldb-commits
https://github.com/labath updated https://github.com/llvm/llvm-project/pull/134630 >From 5f226bc5fa08e1b098ee95ba860954079a71c83c Mon Sep 17 00:00:00 2001 From: Pavel Labath Date: Fri, 4 Apr 2025 12:05:18 +0200 Subject: [PATCH] [lldb] Remove unused UnwindPlan functions `GetLSDAAddress` and `Ge

[Lldb-commits] [lldb] [lldb] Handle signals in a separate thread in the driver (PR #134956)

2025-04-09 Thread Pavel Labath via lldb-commits
https://github.com/labath edited https://github.com/llvm/llvm-project/pull/134956 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Handle signals in a separate thread in the driver (PR #134956)

2025-04-09 Thread Pavel Labath via lldb-commits
https://github.com/labath edited https://github.com/llvm/llvm-project/pull/134956 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Handle signals in a separate thread in the driver (PR #134956)

2025-04-09 Thread Pavel Labath via lldb-commits
@@ -637,48 +641,50 @@ void Driver::UpdateWindowSize() { } void sigwinch_handler(int signo) { - if (g_driver != nullptr) -g_driver->UpdateWindowSize(); + g_signal_loop.AddPendingCallback([](MainLoopBase &loop) { +if (g_driver != nullptr) + g_driver->UpdateWindowS

[Lldb-commits] [lldb] [lldb] Remove UnwindPlan::Row shared_ptrs, lite (PR #134081)

2025-04-09 Thread Pavel Labath via lldb-commits
https://github.com/labath closed https://github.com/llvm/llvm-project/pull/134081 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Remove UnwindPlan::Row shared_ptrs, lite (PR #134081)

2025-04-08 Thread Pavel Labath via lldb-commits
labath wrote: Abandoning in favor of #134821 https://github.com/llvm/llvm-project/pull/134081 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] Reapply "[lldb] Remove UnwindPlan::Row shared_ptrs (https://github.com/llvm/llvm-project/pull/132370)" (PR #134821)

2025-04-08 Thread Pavel Labath via lldb-commits
https://github.com/labath closed https://github.com/llvm/llvm-project/pull/134821 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Use correct path for debugserver (PR #131609)

2025-04-08 Thread Pavel Labath via lldb-commits
https://github.com/labath approved this pull request. Looks good, thanks for your patience. https://github.com/llvm/llvm-project/pull/131609 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-

[Lldb-commits] [lldb] [lldb] Small refactor of eh_frame parsing (PR #134806)

2025-04-08 Thread Pavel Labath via lldb-commits
https://github.com/labath created https://github.com/llvm/llvm-project/pull/134806 .. which prepares us for handling of discontinuous functions. The main change there is that we can have multiple FDEs contributing towards an unwind plan of a single function. This patch separates the logic for pa

[Lldb-commits] [lldb] [LLDB] Refactored CPlusPlusLanguage::MethodName to break lldb-server dependencies (PR #132274)

2025-04-07 Thread Pavel Labath via lldb-commits
https://github.com/labath commented: I like the version a lot, but I'd like to leave to final approval to @bulbazord and/or @JDevlieghere. https://github.com/llvm/llvm-project/pull/132274 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https

[Lldb-commits] [lldb] [LLDB] Refactored CPlusPlusLanguage::MethodName to break lldb-server dependencies (PR #132274)

2025-04-07 Thread Pavel Labath via lldb-commits
@@ -222,6 +222,21 @@ ObjCLanguage::GetMethodNameVariants(ConstString method_name) const { return variant_names; } +std::pair +ObjCLanguage::GetFunctionNameInfo(ConstString name) const { + FunctionNameType func_name_type = eFunctionNameTypeNone; + + if (ObjCLanguage::IsPos

[Lldb-commits] [lldb] [LLDB] Refactored CPlusPlusLanguage::MethodName to break lldb-server dependencies (PR #132274)

2025-04-07 Thread Pavel Labath via lldb-commits
https://github.com/labath edited https://github.com/llvm/llvm-project/pull/132274 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [LLDB][NFC] Remove Debugger dependency in SystemLifetimeManager (PR #134383)

2025-04-07 Thread Pavel Labath via lldb-commits
https://github.com/labath approved this pull request. > So, I will move LoadPlugin lambda to SystemInitializerFull. Thanks, this LGTM now, but do wait for @JDevlieghere's review as well. > Note lldbInitialization depends on lldbPluginProcessGDBRemote, > lldbPluginProcessPOSIX and lldbPluginPro

[Lldb-commits] [lldb] [LLDB] Add unary operators Dereference and AddressOf to DIL (PR #134428)

2025-04-07 Thread Pavel Labath via lldb-commits
labath wrote: > Trying to add unit tests with this patch. We already have a big test suite > that came from `lldb-eval`, and I don't see much reason to rewrite them into > Python tests. > I didn't find an existing way to build the binary for debugging using in-tree > compiler and libc++, so

[Lldb-commits] [lldb] [lldb] Use correct path for debugserver (PR #131609)

2025-04-07 Thread Pavel Labath via lldb-commits
@@ -4,6 +4,7 @@ """ import os +import signal labath wrote: I guess this isn't used anymore. https://github.com/llvm/llvm-project/pull/131609 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.l

[Lldb-commits] [lldb] [lldb] Use correct path for debugserver (PR #131609)

2025-04-07 Thread Pavel Labath via lldb-commits
https://github.com/labath edited https://github.com/llvm/llvm-project/pull/131609 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Use correct path for debugserver (PR #131609)

2025-04-07 Thread Pavel Labath via lldb-commits
@@ -58,3 +59,45 @@ def test_platform_process_launch_gdb_server(self): self.runCmd("target create {}".format(self.getBuildArtifact("a.out"))) self.expect("run", substrs=["unable to launch a GDB server on"], error=True) + +@skipIfRemote +@skipUnlessPlatf

[Lldb-commits] [lldb] [LLDB] Add unary operators Dereference and AddressOf to DIL (PR #134428)

2025-04-07 Thread Pavel Labath via lldb-commits
labath wrote: I see this is just a draft, but in order to save time for everyone, I want to say this as early as possible. With this patch, the biggest question you will have to answer is "why is the implementation of `&` more complicated than `inner_value->AddressOf()`" (and a similar questi

[Lldb-commits] [lldb] [LLDB][NFC] Remove Debugger dependency in SystemLifetimeManager (PR #134383)

2025-04-07 Thread Pavel Labath via lldb-commits
labath wrote: I agree with everything Jonas said here (and that's why I am very reluctant to approve #132274). The layering should be between libraries (like they are in the rest of llvm), not individual object files. My mental model for a "dependency" from library `A` to library `B` is "libra

[Lldb-commits] [lldb] [LLDB][NFC] Move CPlusPlusLanguage methods used in Core/Module.cpp to a separated module to break lldb-server dependencies (PR #132274)

2025-04-05 Thread Pavel Labath via lldb-commits
labath wrote: > > Global variables are > > [banned](https://llvm.org/docs/CodingStandards.html#do-not-use-static-constructors) > > by the coding standards, but I wouldn't be surprised if there were still > > some around that cause this. > > TypeSystemClang.cpp contains global `char TypeSystem

[Lldb-commits] [lldb] [lldb] Use correct path for debugserver (PR #131609)

2025-04-05 Thread Pavel Labath via lldb-commits
@@ -58,3 +59,45 @@ def test_platform_process_launch_gdb_server(self): self.runCmd("target create {}".format(self.getBuildArtifact("a.out"))) self.expect("run", substrs=["unable to launch a GDB server on"], error=True) + +@skipIfRemote +@skipUnlessPlatf

[Lldb-commits] [lldb] [LLDB][NFC]Refactor common test setup into SetUp method (PR #131203)

2025-04-05 Thread Pavel Labath via lldb-commits
https://github.com/labath approved this pull request. https://github.com/llvm/llvm-project/pull/131203 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

  1   2   3   4   5   6   7   8   9   10   >