[Lldb-commits] [lldb] [lldb] Claim to support swbreak and hwbreak packets when debugging a gdbremote (PR #102873)

2024-08-13 Thread David Spickett via lldb-commits
DavidSpickett wrote: The test content is fine, but I was assuming that we'd extend the existing `TestStopPCs.py` to do the same thing in less code. If that test had 1 more thread, you could have normal / swbreak / hwbreak threads in one test case. https://github.com/llvm/llvm-project/pull/1028

[Lldb-commits] [lldb] [lldb] Claim to support swbreak and hwbreak packets when debugging a gdbremote (PR #102873)

2024-08-13 Thread via lldb-commits
github-actions[bot] wrote: :warning: Python code formatter, darker found issues in your code. :warning: You can test this locally with the following command: ``bash darker --check --diff -r 55d7e59023bc48f97321970cda5e400c07de59fa...55f9473b8832723b96db45103bf4d5aa0b10da90 lldb/

[Lldb-commits] [lldb] [lldb] Multithreading lldb-server works on Windows now; fixed gdb port mapping (PR #100670)

2024-08-13 Thread Dmitry Vasilyev via lldb-commits
slydiman wrote: See the replacement #101283. https://github.com/llvm/llvm-project/pull/100670 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Multithreading lldb-server works on Windows now; fixed gdb port mapping (PR #100670)

2024-08-13 Thread Dmitry Vasilyev via lldb-commits
https://github.com/slydiman closed https://github.com/llvm/llvm-project/pull/100670 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Add 'FindInMemory()' overload for PostMortemProcess. (PR #102536)

2024-08-13 Thread Miro Bucko via lldb-commits
mbucko wrote: > It just so happens that I got a `memory find` bug today, which made me > realize just how broken the current behavior is -- it will effectively abort > the search as soon as it runs into any unreadable block of memory (plus it > also reads one byte at a time, which makes it exc

[Lldb-commits] [lldb] Remove redundant symbol lookups in IRExecutionUnit::FindInSymbols (PR #102835)

2024-08-13 Thread Dmitrii Galimzianov via lldb-commits
@@ -285,7 +285,7 @@ class ModuleList { /// \see Module::FindFunctions () void FindFunctions(ConstString name, lldb::FunctionNameType name_type_mask, const ModuleFunctionSearchOptions &options, - SymbolContextList &sc_list) const; +

[Lldb-commits] [lldb] Remove redundant symbol lookups in IRExecutionUnit::FindInSymbols (PR #102835)

2024-08-13 Thread Dmitrii Galimzianov via lldb-commits
https://github.com/DmT021 edited https://github.com/llvm/llvm-project/pull/102835 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Claim to support swbreak and hwbreak packets when debugging a gdbremote (PR #102873)

2024-08-13 Thread via lldb-commits
https://github.com/xusheng6 updated https://github.com/llvm/llvm-project/pull/102873 >From cdd4b8ce09fb536defb3df182e8b5ebf16ada685 Mon Sep 17 00:00:00 2001 From: Xusheng Date: Mon, 20 Mar 2023 20:24:11 +0800 Subject: [PATCH] [lldb] Claim to support swbreak and hwbreak packets when debugging a

[Lldb-commits] [lldb] [lldb] Claim to support swbreak and hwbreak packets when debugging a gdbremote (PR #102873)

2024-08-13 Thread via lldb-commits
https://github.com/xusheng6 updated https://github.com/llvm/llvm-project/pull/102873 >From 51a356b384f28cce3b2cd874fbba139414b0e207 Mon Sep 17 00:00:00 2001 From: Xusheng Date: Mon, 20 Mar 2023 20:24:11 +0800 Subject: [PATCH] [lldb] Claim to support swbreak and hwbreak packets when debugging a

[Lldb-commits] [lldb] [lldb] Claim to support swbreak and hwbreak packets when debugging a gdbremote (PR #102873)

2024-08-13 Thread via lldb-commits
@@ -10,13 +10,15 @@ class TestStopPCs(GDBRemoteTestBase): def test(self): class MyResponder(MockGDBServerResponder): def haltReason(self): -return "T02thread:1ff0d;threads:1ff0d,2ff0d;thread-pcs:10001bc00,10002bc00;" +ret

[Lldb-commits] [lldb] [lldb] Claim to support swbreak and hwbreak packets when debugging a gdbremote (PR #102873)

2024-08-13 Thread via lldb-commits
@@ -3594,6 +3594,9 @@ rnb_err_t RNBRemote::HandlePacket_qSupported(const char *p) { reply << "SupportedWatchpointTypes=x86_64;"; #endif + // We consume lldb's swbreak/hwbreak feature, but it doesn't change the + // behaviour of lldb-server. We always adjust the program co

[Lldb-commits] [lldb] [lldb] Claim to support swbreak and hwbreak packets when debugging a gdbremote (PR #102873)

2024-08-13 Thread David Spickett via lldb-commits
https://github.com/DavidSpickett edited https://github.com/llvm/llvm-project/pull/102873 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] 5dbec8c - [lldb] Claim to support swbreak and hwbreak packets when debugging a gdbremote (#102873)

2024-08-13 Thread via lldb-commits
Author: xusheng Date: 2024-08-13T15:28:35+01:00 New Revision: 5dbec8c6ce473352cac2d89d6a5b81f65182df59 URL: https://github.com/llvm/llvm-project/commit/5dbec8c6ce473352cac2d89d6a5b81f65182df59 DIFF: https://github.com/llvm/llvm-project/commit/5dbec8c6ce473352cac2d89d6a5b81f65182df59.diff LOG:

[Lldb-commits] [lldb] [lldb] Claim to support swbreak and hwbreak packets when debugging a gdbremote (PR #102873)

2024-08-13 Thread David Spickett via lldb-commits
https://github.com/DavidSpickett closed https://github.com/llvm/llvm-project/pull/102873 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Claim to support swbreak and hwbreak packets when debugging a gdbremote (PR #102873)

2024-08-13 Thread David Spickett via lldb-commits
DavidSpickett wrote: Thanks for the contribution! The test especially, it will keep us honest and protect your downstream tools going forward. https://github.com/llvm/llvm-project/pull/102873 ___ lldb-commits mailing list lldb-commits@lists.llvm.org h

[Lldb-commits] [lldb] [lldb][DWARFASTParser] Don't pass CompilerType by non-const reference in the DWARFASTParserClang APIs (PR #103245)

2024-08-13 Thread Michael Buch via lldb-commits
https://github.com/Michael137 created https://github.com/llvm/llvm-project/pull/103245 The `CompilerType` is just a wrapper around two pointers, and there is no usage of the `CompilerType` where those are expected to change underneath the caller. To make the interface more straightforward to r

[Lldb-commits] [lldb] [lldb][DWARFASTParser] Don't pass CompilerType by non-const reference in the DWARFASTParserClang APIs (PR #103245)

2024-08-13 Thread via lldb-commits
llvmbot wrote: @llvm/pr-subscribers-lldb Author: Michael Buch (Michael137) Changes The `CompilerType` is just a wrapper around two pointers, and there is no usage of the `CompilerType` where those are expected to change underneath the caller. To make the interface more straightforward to

[Lldb-commits] [lldb] [LLDB] Add AST node classes, functions, etc. for Data Inspection Lang… (PR #95738)

2024-08-13 Thread via lldb-commits
@@ -0,0 +1,459 @@ +//===-- DILAST.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: Ap

[Lldb-commits] [lldb] [lldb] Add 'FindInMemory()' overload for PostMortemProcess. (PR #102536)

2024-08-13 Thread Pavel Labath via lldb-commits
labath wrote: > This would be quite the rework of the FindInMemory() API. Would it be worth > creating an Issue and move the discussion there to unblock this PR? I think the two are related because if we (I?) do something like I proposed, then this patch becomes unnecessary (or even gets in th

[Lldb-commits] [lldb] Remove redundant symbol lookups in IRExecutionUnit::FindInSymbols (PR #102835)

2024-08-13 Thread Dmitrii Galimzianov via lldb-commits
DmT021 wrote: Oh, wait a sec. I actually changed the behavior of the `IRExecutionUnit::FindInSymbols`. It used to exit early if the function was found in `module_sp`, but now we will always scan through the whole ModuleList. And we can't change the behavior `ModuleList::FindFunctions` to return

[Lldb-commits] [lldb] [lldb] Claim to support swbreak and hwbreak packets when debugging a gdbremote (PR #102873)

2024-08-13 Thread Jason Molenda via lldb-commits
@@ -4245,6 +4245,10 @@ std::vector GDBRemoteCommunicationServerLLGS::HandleFeatures( .Case("vfork-events+", Extension::vfork) .Default({}); + // We consume lldb's swbreak/hwbreak feature, but it doesn't change the + // behaviour of lldb-server. We al

[Lldb-commits] [lldb] [lldb] Claim to support swbreak and hwbreak packets when debugging a gdbremote (PR #102873)

2024-08-13 Thread Jason Molenda via lldb-commits
https://github.com/jasonmolenda commented: Thanks for writing up the patch. We do see some handling of this behavior for x86 in lldb, e.g. ProcessWindowsNative, and KDP protocol support with x86 Darwin kernel debugging, also `breakpoint-pc-offset` in ProcessGDBRemote. But we do assume that th

[Lldb-commits] [lldb] [lldb] Claim to support swbreak and hwbreak packets when debugging a gdbremote (PR #102873)

2024-08-13 Thread Jason Molenda via lldb-commits
https://github.com/jasonmolenda edited https://github.com/llvm/llvm-project/pull/102873 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Claim to support swbreak and hwbreak packets when debugging a gdbremote (PR #102873)

2024-08-13 Thread Jason Molenda via lldb-commits
@@ -2354,6 +2354,9 @@ StateType ProcessGDBRemote::SetThreadStopInfo(StringExtractor &stop_packet) { if (!key.getAsInteger(16, reg)) expedited_register_map[reg] = std::string(std::move(value)); } + // swbreak and hwbreak are also expected keys, but

[Lldb-commits] [lldb] [LLDB] Add AST node classes, functions, etc. for Data Inspection Lang… (PR #95738)

2024-08-13 Thread Pavel Labath via lldb-commits
@@ -0,0 +1,459 @@ +//===-- DILAST.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: Ap

[Lldb-commits] [lldb] [lldb] Claim to support swbreak and hwbreak packets when debugging a gdbremote (PR #102873)

2024-08-13 Thread Jason Molenda via lldb-commits
jasonmolenda wrote: oh lol I missed that this was already merged. But I am curious what you think about treating `swbreak`/`hwbreak` as equivalent to having received `reason:breakpoint`. https://github.com/llvm/llvm-project/pull/102873 ___ lldb-comm

[Lldb-commits] [lldb] Remove redundant symbol lookups in IRExecutionUnit::FindInSymbols (PR #102835)

2024-08-13 Thread Augusto Noronha via lldb-commits
augusto2112 wrote: > > @clayborg I can see how a module could be used as a hint, but I'm not sure > > how we'd prioritize lookups using functions or compile unit. The code in > > `SymTab.cpp` does a binary search to find the symbol, how could we restrict > > this further by passing a function

[Lldb-commits] [lldb] [lldb] Claim to support swbreak and hwbreak packets when debugging a gdbremote (PR #102873)

2024-08-13 Thread Jason Molenda via lldb-commits
jasonmolenda wrote: Just to be clear, if I'm understanding the packet we'll be getting back, we have no indication that we hit the breakpoint, we only show that we are stopped at an address which has a breakpoint. Current lldb stepping behavior will work -- because the rule is, when we stop a

[Lldb-commits] [lldb] Remove redundant symbol lookups in IRExecutionUnit::FindInSymbols (PR #102835)

2024-08-13 Thread Michael Buch via lldb-commits
Michael137 wrote: > Oh, wait a sec. I actually changed the behavior of the > `IRExecutionUnit::FindInSymbols`. It used to exit early if the function was > found in `module_sp`, but now we will always scan through the whole > ModuleList. And we can't change the behavior of the > `ModuleList::F

[Lldb-commits] [lldb] Remove redundant symbol lookups in IRExecutionUnit::FindInSymbols (PR #102835)

2024-08-13 Thread Augusto Noronha via lldb-commits
augusto2112 wrote: > Oh, wait a sec. I actually changed the behavior of the > `IRExecutionUnit::FindInSymbols`. It used to exit early if the function was > found in `module_sp`, but now we will always scan through the whole > ModuleList. And we can't change the behavior of the > `ModuleList::

[Lldb-commits] [lldb] Remove redundant symbol lookups in IRExecutionUnit::FindInSymbols (PR #102835)

2024-08-13 Thread Augusto Noronha via lldb-commits
@@ -441,14 +441,20 @@ ModuleSP ModuleList::GetModuleAtIndexUnlocked(size_t idx) const { void ModuleList::FindFunctions(ConstString name, FunctionNameType name_type_mask, const ModuleFunctionSearchOptions &options, +

[Lldb-commits] [lldb] Remove redundant symbol lookups in IRExecutionUnit::FindInSymbols (PR #102835)

2024-08-13 Thread Michael Buch via lldb-commits
Michael137 wrote: > > Oh, wait a sec. I actually changed the behavior of the > > `IRExecutionUnit::FindInSymbols`. It used to exit early if the function was > > found in `module_sp`, but now we will always scan through the whole > > ModuleList. And we can't change the behavior of the > > `Mod

[Lldb-commits] [lldb] 7e23613 - [lldb] Skip libcxx tests with older versions of clang

2024-08-13 Thread Adrian Prantl via lldb-commits
Author: Adrian Prantl Date: 2024-08-13T09:43:07-07:00 New Revision: 7e236136ab2896dee12bbe96d5994bb65c326e9f URL: https://github.com/llvm/llvm-project/commit/7e236136ab2896dee12bbe96d5994bb65c326e9f DIFF: https://github.com/llvm/llvm-project/commit/7e236136ab2896dee12bbe96d5994bb65c326e9f.diff

[Lldb-commits] [lldb] Remove redundant symbol lookups in IRExecutionUnit::FindInSymbols (PR #102835)

2024-08-13 Thread Dmitrii Galimzianov via lldb-commits
DmT021 wrote: > > > Oh, wait a sec. I actually changed the behavior of the > > > `IRExecutionUnit::FindInSymbols`. It used to exit early if the function > > > was found in `module_sp`, but now we will always scan through the whole > > > ModuleList. And we can't change the behavior of the > >

[Lldb-commits] [lldb] [lldb] Add 'FindInMemory()' overload for PostMortemProcess. (PR #102536)

2024-08-13 Thread Kevin Frei via lldb-commits
@@ -2835,6 +2835,34 @@ void PruneThreadPlans(); AddressRanges &matches, size_t alignment, size_t max_matches); + template + lldb::addr_t FindInMemoryGeneric(IT &&iterator, lldb::addr_t low, +

[Lldb-commits] [lldb] Remove redundant symbol lookups in IRExecutionUnit::FindInSymbols (PR #102835)

2024-08-13 Thread Augusto Noronha via lldb-commits
augusto2112 wrote: > > > > Oh, wait a sec. I actually changed the behavior of the > > > > `IRExecutionUnit::FindInSymbols`. It used to exit early if the function > > > > was found in `module_sp`, but now we will always scan through the whole > > > > ModuleList. And we can't change the behavior

[Lldb-commits] [lldb] [lldb] Realpath symlinks for breakpoints (PR #102223)

2024-08-13 Thread via lldb-commits
royitaqi wrote: Gentle ping. @jimingham and @labath Is there anything else you want me to improve/fix in this PR? > I think I have addressed all of your comments. > When you have the time, I will appreciate you taking another look cc @clayborg https://github.com/llvm/llvm-project/pull/102223

[Lldb-commits] [lldb] 494eec0 - [lldb][NFCI] Simplify ProcessElfCore::GetAuxvData() (#102263)

2024-08-13 Thread via lldb-commits
Author: Igor Kudrin Date: 2024-08-13T10:55:28-07:00 New Revision: 494eec0255d0e270ed877e960843177759f0ee73 URL: https://github.com/llvm/llvm-project/commit/494eec0255d0e270ed877e960843177759f0ee73 DIFF: https://github.com/llvm/llvm-project/commit/494eec0255d0e270ed877e960843177759f0ee73.diff L

[Lldb-commits] [lldb] [lldb][NFCI] Simplify ProcessElfCore::GetAuxvData() (PR #102263)

2024-08-13 Thread Igor Kudrin via lldb-commits
https://github.com/igorkudrin closed https://github.com/llvm/llvm-project/pull/102263 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [clang] [lldb] Use CLANG_RESOURCE_DIR more consistently (PR #103388)

2024-08-13 Thread Kim Gräsman via lldb-commits
https://github.com/kimgr created https://github.com/llvm/llvm-project/pull/103388 When Clang is consumed as a library, the CLANG_RESOURCE_DIR definition is not exported from the CMake system, so external clients will be unable to compute the same resource dir as Clang itself would, because the

[Lldb-commits] [clang] [lldb] Use CLANG_RESOURCE_DIR more consistently (PR #103388)

2024-08-13 Thread via lldb-commits
llvmbot wrote: @llvm/pr-subscribers-clang-driver Author: Kim Gräsman (kimgr) Changes When Clang is consumed as a library, the CLANG_RESOURCE_DIR definition is not exported from the CMake system, so external clients will be unable to compute the same resource dir as Clang itself would, be

[Lldb-commits] [clang] [lldb] Use CLANG_RESOURCE_DIR more consistently (PR #103388)

2024-08-13 Thread via lldb-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Kim Gräsman (kimgr) Changes When Clang is consumed as a library, the CLANG_RESOURCE_DIR definition is not exported from the CMake system, so external clients will be unable to compute the same resource dir as Clang itself would, because t

[Lldb-commits] [clang] [lldb] Use CLANG_RESOURCE_DIR more consistently (PR #103388)

2024-08-13 Thread via lldb-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff 4377656f2419a8eb18c01e86929b689dcf22b5d6 102517cd9d53695c9ae56135492bab09df9d90ee --e

[Lldb-commits] [clang] [lldb] Use CLANG_RESOURCE_DIR more consistently (PR #103388)

2024-08-13 Thread Kim Gräsman via lldb-commits
https://github.com/kimgr updated https://github.com/llvm/llvm-project/pull/103388 From 3722d673ee409c1320c9d66aa2f3f6568ffdfd77 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kim=20Gr=C3=A4sman?= Date: Mon, 5 Aug 2024 11:49:32 +0200 Subject: [PATCH] Use CLANG_RESOURCE_DIR more consistently When Clan

[Lldb-commits] [clang] [lldb] Use CLANG_RESOURCE_DIR more consistently (PR #103388)

2024-08-13 Thread Kim Gräsman via lldb-commits
kimgr wrote: @nico You're the original author of this thing back in 2019, maybe you have some additional information. Please take a look if you have a chance. https://github.com/llvm/llvm-project/pull/103388 ___ lldb-commits mailing list lldb-commits@

[Lldb-commits] [lldb] [lldb][DWARFASTParser] Don't pass CompilerType by non-const reference in the DWARFASTParserClang APIs (PR #103245)

2024-08-13 Thread Pavel Labath via lldb-commits
https://github.com/labath approved this pull request. https://github.com/llvm/llvm-project/pull/103245 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [clang] [clang-tools-extra] [compiler-rt] [flang] [libc] [libcxx] [lldb] [llvm] [mlir] [InstCombine] Don't look at ConstantData users (PR #103302)

2024-08-13 Thread Alexis Engelke via lldb-commits
https://github.com/aengelke edited https://github.com/llvm/llvm-project/pull/103302 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [clang] [clang-tools-extra] [compiler-rt] [flang] [libc] [libcxx] [lldb] [llvm] [mlir] [InstCombine] Don't look at ConstantData users (PR #103302)

2024-08-13 Thread Alexis Engelke via lldb-commits
https://github.com/aengelke closed https://github.com/llvm/llvm-project/pull/103302 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] 28050e1 - [lldb][DWARFASTParser] Don't pass CompilerType by non-const reference in the DWARFASTParserClang APIs (#103245)

2024-08-13 Thread via lldb-commits
Author: Michael Buch Date: 2024-08-13T20:04:18+01:00 New Revision: 28050e1b0b9da6d9c24ba20e8c70cf90b8135f49 URL: https://github.com/llvm/llvm-project/commit/28050e1b0b9da6d9c24ba20e8c70cf90b8135f49 DIFF: https://github.com/llvm/llvm-project/commit/28050e1b0b9da6d9c24ba20e8c70cf90b8135f49.diff

[Lldb-commits] [lldb] [lldb][DWARFASTParser] Don't pass CompilerType by non-const reference in the DWARFASTParserClang APIs (PR #103245)

2024-08-13 Thread Michael Buch via lldb-commits
https://github.com/Michael137 closed https://github.com/llvm/llvm-project/pull/103245 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [LLDB] Add AST node classes, functions, etc. for Data Inspection Lang… (PR #95738)

2024-08-13 Thread Andy Hippo via lldb-commits
@@ -0,0 +1,459 @@ +//===-- DILAST.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: Ap

[Lldb-commits] [lldb] [lldb] Add 'FindInMemory()' overload for PostMortemProcess. (PR #102536)

2024-08-13 Thread Greg Clayton via lldb-commits
@@ -0,0 +1,83 @@ +//===-- PostMortemProcess.cpp ---*- 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: Apa

[Lldb-commits] [lldb] [lldb] Add 'FindInMemory()' overload for PostMortemProcess. (PR #102536)

2024-08-13 Thread Greg Clayton via lldb-commits
https://github.com/clayborg requested changes to this pull request. https://github.com/llvm/llvm-project/pull/102536 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Add 'FindInMemory()' overload for PostMortemProcess. (PR #102536)

2024-08-13 Thread Greg Clayton via lldb-commits
@@ -0,0 +1,83 @@ +//===-- PostMortemProcess.cpp ---*- 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: Apa

[Lldb-commits] [lldb] [lldb] Add 'FindInMemory()' overload for PostMortemProcess. (PR #102536)

2024-08-13 Thread Greg Clayton via lldb-commits
@@ -0,0 +1,83 @@ +//===-- PostMortemProcess.cpp ---*- 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: Apa

[Lldb-commits] [lldb] [lldb] Add 'FindInMemory()' overload for PostMortemProcess. (PR #102536)

2024-08-13 Thread Greg Clayton via lldb-commits
@@ -0,0 +1,83 @@ +//===-- PostMortemProcess.cpp ---*- 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: Apa

[Lldb-commits] [lldb] [lldb] Add 'FindInMemory()' overload for PostMortemProcess. (PR #102536)

2024-08-13 Thread Greg Clayton via lldb-commits
@@ -0,0 +1,83 @@ +//===-- PostMortemProcess.cpp ---*- 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: Apa

[Lldb-commits] [lldb] [lldb] Realpath symlinks for breakpoints (PR #102223)

2024-08-13 Thread Greg Clayton via lldb-commits
https://github.com/clayborg commented: I am good with this if Jim and Pavel's issues have been resolved. https://github.com/llvm/llvm-project/pull/102223 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/l

[Lldb-commits] [lldb] [LLDB][OSX] Add a fallback support exe directory (PR #103458)

2024-08-13 Thread Walter Erquinigo via lldb-commits
https://github.com/walter-erquinigo created https://github.com/llvm/llvm-project/pull/103458 LLDB on OSX is looking at a `bin` directory sibling to the `lib` one that contains liblldb for its supporting executables. This works well for CMake, however, for other build systems like bazel, it's n

[Lldb-commits] [lldb] [LLDB][OSX] Add a fallback support exe directory (PR #103458)

2024-08-13 Thread via lldb-commits
llvmbot wrote: @llvm/pr-subscribers-lldb Author: Walter Erquinigo (walter-erquinigo) Changes LLDB on OSX is looking at a `bin` directory sibling to the `lib` one that contains liblldb for its supporting executables. This works well for CMake, however, for other build systems like bazel,

[Lldb-commits] [lldb] [LLDB][OSX] Add a fallback support exe directory (PR #103458)

2024-08-13 Thread Keith Smiley via lldb-commits
https://github.com/keith approved this pull request. lgtm, but not a LLDB expert https://github.com/llvm/llvm-project/pull/103458 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [LLDB][OSX] Add a fallback support exe directory (PR #103458)

2024-08-13 Thread Keith Smiley via lldb-commits
keith wrote: note that this is similar to lldb-server is discovered on linux as well https://github.com/llvm/llvm-project/pull/103458 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [LLDB][OSX] Add a fallback support exe directory (PR #103458)

2024-08-13 Thread Jonas Devlieghere via lldb-commits
https://github.com/JDevlieghere edited https://github.com/llvm/llvm-project/pull/103458 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [LLDB][OSX] Add a fallback support exe directory (PR #103458)

2024-08-13 Thread Jonas Devlieghere via lldb-commits
https://github.com/JDevlieghere approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/103458 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [LLDB][OSX] Add a fallback support exe directory (PR #103458)

2024-08-13 Thread Jonas Devlieghere via lldb-commits
@@ -144,16 +150,22 @@ static void ParseOSVersion(llvm::VersionTuple &version, NSString *Key) { #endif } else { // Find the bin path relative to the lib path where the cmake-based -// OS X .dylib lives. This is not going to work if the bin and lib -// dir are not

[Lldb-commits] [lldb] [LLDB][OSX] Add a fallback support exe directory (PR #103458)

2024-08-13 Thread Alex Langford via lldb-commits
https://github.com/bulbazord edited https://github.com/llvm/llvm-project/pull/103458 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [LLDB][OSX] Add a fallback support exe directory (PR #103458)

2024-08-13 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. lgtm, one small suggestion https://github.com/llvm/llvm-project/pull/103458 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [LLDB][OSX] Add a fallback support exe directory (PR #103458)

2024-08-13 Thread Alex Langford via lldb-commits
@@ -144,16 +150,22 @@ static void ParseOSVersion(llvm::VersionTuple &version, NSString *Key) { #endif } else { // Find the bin path relative to the lib path where the cmake-based -// OS X .dylib lives. This is not going to work if the bin and lib -// dir are not

[Lldb-commits] [lldb] [lldb] Realpath symlinks for breakpoints (PR #102223)

2024-08-13 Thread Alex Langford via lldb-commits
https://github.com/bulbazord edited https://github.com/llvm/llvm-project/pull/102223 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Realpath symlinks for breakpoints (PR #102223)

2024-08-13 Thread Alex Langford via lldb-commits
@@ -0,0 +1,77 @@ +//===-- RealpathPrefixes.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: Apa

[Lldb-commits] [lldb] [lldb] Realpath symlinks for breakpoints (PR #102223)

2024-08-13 Thread Alex Langford via lldb-commits
https://github.com/bulbazord commented: Interesting. I left a few minor comments, I think Jim and Greg got a lot of the edge cases and bulky feedback out of the way already. :) https://github.com/llvm/llvm-project/pull/102223 ___ lldb-commits mailing

[Lldb-commits] [lldb] [lldb] Realpath symlinks for breakpoints (PR #102223)

2024-08-13 Thread Alex Langford via lldb-commits
@@ -0,0 +1,77 @@ +//===-- RealpathPrefixes.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: Apa

[Lldb-commits] [clang] [lldb] Use CLANG_RESOURCE_DIR more consistently (PR #103388)

2024-08-13 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. The LLDB changes look good to me. I can't speak for the clang portions but fwiw I think they look ok too. https://github.com/llvm/llvm-project/pull/103388 ___ lldb-commits mailing list lldb-comm

[Lldb-commits] [lldb] [lldb-dap] Expose log path in extension settings (PR #103482)

2024-08-13 Thread Adrian Vogelsgesang via lldb-commits
https://github.com/vogelsgesang created https://github.com/llvm/llvm-project/pull/103482 lldb-dap already supports a log file which can be enabled by setting the `LLDBDAP_LOG` environment variable. With this commit, the log location can be set directly through the VS-Code extension settings.

[Lldb-commits] [lldb] [lldb-dap] Expose log path in extension settings (PR #103482)

2024-08-13 Thread via lldb-commits
llvmbot wrote: @llvm/pr-subscribers-lldb Author: Adrian Vogelsgesang (vogelsgesang) Changes lldb-dap already supports a log file which can be enabled by setting the `LLDBDAP_LOG` environment variable. With this commit, the log location can be set directly through the VS-Code extension se

[Lldb-commits] [clang] [lldb] Use CLANG_RESOURCE_DIR more consistently (PR #103388)

2024-08-13 Thread Fangrui Song via lldb-commits
https://github.com/MaskRay approved this pull request. clangDriver changes look reasonable. https://github.com/llvm/llvm-project/pull/103388 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-

[Lldb-commits] [lldb] [lldb] Realpath symlinks for breakpoints (PR #102223)

2024-08-13 Thread via lldb-commits
@@ -0,0 +1,77 @@ +//===-- RealpathPrefixes.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: Apa

[Lldb-commits] [lldb] New ThreadPlanSingleThreadTimeout to resolve potential deadlock in single thread stepping (PR #90930)

2024-08-13 Thread via lldb-commits
jeffreytan81 wrote: Thanks for sharing. I have written a shell script to run `TestSingleThreadStepTimeout.py` in a loop infinitely until failing. Unfortunately, it has been running for 127 iterations (more than 7 hours) on my CentOS9 machine, haven't seen a single failure/timeout yet. I am not

[Lldb-commits] [lldb] [LLDB][Data Formatters] Calculate average and total time for summary providers within lldb (PR #102708)

2024-08-13 Thread Jacob Lalonde via lldb-commits
https://github.com/Jlalond updated https://github.com/llvm/llvm-project/pull/102708 >From c0a7286b0107d3161b18de8f05d4d016150e96a5 Mon Sep 17 00:00:00 2001 From: Jacob Lalonde Date: Thu, 8 Aug 2024 08:58:52 -0700 Subject: [PATCH 1/4] Initial attempt at new classes Summary statistics in Summary

[Lldb-commits] [lldb] [LLDB][Data Formatters] Calculate average and total time for summary providers within lldb (PR #102708)

2024-08-13 Thread Jacob Lalonde via lldb-commits
https://github.com/Jlalond updated https://github.com/llvm/llvm-project/pull/102708 >From c0a7286b0107d3161b18de8f05d4d016150e96a5 Mon Sep 17 00:00:00 2001 From: Jacob Lalonde Date: Thu, 8 Aug 2024 08:58:52 -0700 Subject: [PATCH 1/5] Initial attempt at new classes Summary statistics in Summary

[Lldb-commits] [lldb] [LLDB][Data Formatters] Calculate average and total time for summary providers within lldb (PR #102708)

2024-08-13 Thread Jacob Lalonde via lldb-commits
@@ -1,7 +1,13 @@ // Test that the lldb command `statistics` works. +#include + +void foo() { + std::string str = "hello world"; Jlalond wrote: @clayborg I created a basic template test, and made sure the formatter was invoked, and I added a different test f

[Lldb-commits] [lldb] [LLDB][Data Formatters] Calculate average and total time for summary providers within lldb (PR #102708)

2024-08-13 Thread Jacob Lalonde via lldb-commits
@@ -174,6 +176,83 @@ struct StatisticsOptions { std::optional m_include_transcript; }; +/// A class that represents statistics about a TypeSummaryProviders invocations +class SummaryStatistics { +public: + SummaryStatistics() = default; + SummaryStatistics(lldb_private::Co

[Lldb-commits] [lldb] [LLDB][Data Formatters] Calculate average and total time for summary providers within lldb (PR #102708)

2024-08-13 Thread Jacob Lalonde via lldb-commits
https://github.com/Jlalond updated https://github.com/llvm/llvm-project/pull/102708 >From c0a7286b0107d3161b18de8f05d4d016150e96a5 Mon Sep 17 00:00:00 2001 From: Jacob Lalonde Date: Thu, 8 Aug 2024 08:58:52 -0700 Subject: [PATCH 1/6] Initial attempt at new classes Summary statistics in Summary

[Lldb-commits] [lldb] [lldb] Claim to support swbreak and hwbreak packets when debugging a gdbremote (PR #102873)

2024-08-13 Thread via lldb-commits
xusheng6 wrote: > Just to be clear, if I'm understanding the packet we'll be getting back, we > have no indication that we hit the breakpoint, we only show that we are > stopped at an address which has a breakpoint. Current lldb stepping behavior > will work -- because the rule is, when we sto

[Lldb-commits] [lldb] [LLDB][Data Formatters] Calculate average and total time for summary providers within lldb (PR #102708)

2024-08-13 Thread Greg Clayton via lldb-commits
https://github.com/clayborg requested changes to this pull request. https://github.com/llvm/llvm-project/pull/102708 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [LLDB][Data Formatters] Calculate average and total time for summary providers within lldb (PR #102708)

2024-08-13 Thread Greg Clayton via lldb-commits
@@ -258,6 +258,9 @@ class TypeSummaryImpl { virtual std::string GetDescription() = 0; + virtual ConstString GetName() = 0; + virtual ConstString GetImplType() = 0; clayborg wrote: Add header doc for these explaining what they are. https://github.com/llv

[Lldb-commits] [lldb] [LLDB][Data Formatters] Calculate average and total time for summary providers within lldb (PR #102708)

2024-08-13 Thread Greg Clayton via lldb-commits
@@ -145,15 +148,34 @@ std::string CXXFunctionSummaryFormat::GetDescription() { return std::string(sstr.GetString()); } +ConstString CXXFunctionSummaryFormat::GetName() { + return ConstString(m_description); +} + +ConstString CXXFunctionSummaryFormat::GetImplType() { + retu

[Lldb-commits] [lldb] [LLDB][Data Formatters] Calculate average and total time for summary providers within lldb (PR #102708)

2024-08-13 Thread Greg Clayton via lldb-commits
@@ -602,7 +602,7 @@ bool ValueObject::GetSummaryAsCString(TypeSummaryImpl *summary_ptr, actual_options.SetLanguage(GetPreferredDisplayLanguage()); // this is a hot path in code and we prefer to avoid setting this string all - // too often also clearing out other inform

[Lldb-commits] [lldb] [LLDB][Data Formatters] Calculate average and total time for summary providers within lldb (PR #102708)

2024-08-13 Thread Greg Clayton via lldb-commits
@@ -258,6 +258,9 @@ class TypeSummaryImpl { virtual std::string GetDescription() = 0; + virtual ConstString GetName() = 0; + virtual ConstString GetImplType() = 0; + clayborg wrote: We should switch to `std::string` instead of `ConstString.. These object

[Lldb-commits] [lldb] [LLDB][Data Formatters] Calculate average and total time for summary providers within lldb (PR #102708)

2024-08-13 Thread Greg Clayton via lldb-commits
@@ -174,6 +176,83 @@ struct StatisticsOptions { std::optional m_include_transcript; }; +/// A class that represents statistics about a TypeSummaryProviders invocations +class SummaryStatistics { +public: + SummaryStatistics() = default; + SummaryStatistics(lldb_private::Co

[Lldb-commits] [lldb] [LLDB][Data Formatters] Calculate average and total time for summary providers within lldb (PR #102708)

2024-08-13 Thread Greg Clayton via lldb-commits
@@ -116,6 +116,9 @@ std::string StringSummaryFormat::GetDescription() { return std::string(sstr.GetString()); } +ConstString StringSummaryFormat::GetName() { return ConstString(m_format_str); } +ConstString StringSummaryFormat::GetImplType() { return ConstString("string");

[Lldb-commits] [lldb] [LLDB][Data Formatters] Calculate average and total time for summary providers within lldb (PR #102708)

2024-08-13 Thread Greg Clayton via lldb-commits
@@ -174,6 +177,84 @@ struct StatisticsOptions { std::optional m_include_transcript; }; +/// A class that represents statistics about a TypeSummaryProviders invocations +class SummaryStatistics { +public: + explicit SummaryStatistics(lldb_private::ConstString name, +

[Lldb-commits] [lldb] [lldb] Add 'FindInMemory()' overload for PostMortemProcess. (PR #102536)

2024-08-13 Thread Greg Clayton via lldb-commits
https://github.com/clayborg commented: I vote to leave this PR as is because `VMRangeToFileOffset` is a list of VMRanges that map to file offsets and this list combines entries with consecutive address ranges whose data is consecutive in the core file. And `VMRangeToPermissions` does not break

[Lldb-commits] [lldb] [lldb] Add 'FindInMemory()' overload for PostMortemProcess. (PR #102536)

2024-08-13 Thread Greg Clayton via lldb-commits
clayborg wrote: That being said, if there is something we can do to this PR to make it easy for you (Pavel) to implement this feature, we can make those changes. Like I think it would be fair to change all `PeekMemory/DoPeekMemory` over a virtual `ReadMemory/DoReadMemory` that returns a `DataE