[Lldb-commits] [lldb] [LLDB] Add more helper functions to ValueObject class. (PR #87197)

2024-04-01 Thread Alex Langford via lldb-commits
https://github.com/bulbazord requested changes to this pull request. +1 to all of Jim and Adrian's comments. High level comments: 1. I'm a little concerned about the use of assertions in this patch. I generally like assertions when they are used to assert internal consistency. It looks like yo

[Lldb-commits] [lldb] [LLDB] Add more helper functions to ValueObject class. (PR #87197)

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

[Lldb-commits] [lldb] [LLDB] Add APFloat helper functions to Scalar class. (PR #86862)

2024-03-28 Thread Alex Langford via lldb-commits
bulbazord wrote: > > Could you add a test for these new methods in > > `unittests/Utility/ScalarTest.cpp`? > > Done. :-) Thank you! :) https://github.com/llvm/llvm-project/pull/86862 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://

[Lldb-commits] [lldb] [LLDB] Add APFloat helper functions to Scalar class. (PR #86862)

2024-03-28 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. https://github.com/llvm/llvm-project/pull/86862 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [LLDB] Add APFloat helper functions to Scalar class. (PR #86862)

2024-03-27 Thread Alex Langford via lldb-commits
https://github.com/bulbazord requested changes to this pull request. Could you add a test for these new methods in `unittests/Utility/ScalarTest.cpp`? https://github.com/llvm/llvm-project/pull/86862 ___ lldb-commits mailing list lldb-commits@lists.llv

[Lldb-commits] [lldb] [lldb] Avoid deadlock by unlocking before invoking callbacks (PR #86888)

2024-03-27 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. Makes sense to me. https://github.com/llvm/llvm-project/pull/86888 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] [ObjC runtime] Don't cast to signed when left shifting (PR #86605)

2024-03-27 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. https://github.com/llvm/llvm-project/pull/86605 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] [ObjC runtime] Don't cast to signed when left shifting (PR #86605)

2024-03-27 Thread Alex Langford via lldb-commits
@@ -3154,7 +3154,7 @@ AppleObjCRuntimeV2::TaggedPointerVendorExtended::GetClassDescriptor( << m_objc_debug_taggedpointer_ext_payload_lshift) >> m_objc_debug_taggedpointer_ext_payload_rshift); int64_t data_payload_signed

[Lldb-commits] [lldb] [lldb][nfc] Delete unused variable (PR #86740)

2024-03-26 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. https://github.com/llvm/llvm-project/pull/86740 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] [ObjC runtime] Don't cast to signed when left shifting (PR #86605)

2024-03-26 Thread Alex Langford via lldb-commits
@@ -3154,7 +3154,7 @@ AppleObjCRuntimeV2::TaggedPointerVendorExtended::GetClassDescriptor( << m_objc_debug_taggedpointer_ext_payload_lshift) >> m_objc_debug_taggedpointer_ext_payload_rshift); int64_t data_payload_signed

[Lldb-commits] [lldb] Make the correct (5 argument) form of the command definition be the primary one suggested in the docs (PR #86593)

2024-03-25 Thread Alex Langford via lldb-commits
@@ -491,34 +491,42 @@ which will work like all the natively defined lldb commands. This provides a very flexible and easy way to extend LLDB to meet your debugging requirements. To write a python function that implements a new LLDB command define the -function to take four ar

[Lldb-commits] [lldb] Make the correct (5 argument) form of the command definition be the primary one suggested in the docs (PR #86593)

2024-03-25 Thread Alex Langford via lldb-commits
@@ -491,34 +491,42 @@ which will work like all the natively defined lldb commands. This provides a very flexible and easy way to extend LLDB to meet your debugging requirements. To write a python function that implements a new LLDB command define the -function to take four ar

[Lldb-commits] [lldb] Make the correct (5 argument) form of the command definition be the primary one suggested in the docs (PR #86593)

2024-03-25 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/86593 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] Make the correct (5 argument) form of the command definition be the primary one suggested in the docs (PR #86593)

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

[Lldb-commits] [lldb] [lldb][TypeSystem] Enable colored AST dump (PR #86159)

2024-03-21 Thread Alex Langford via lldb-commits
bulbazord wrote: What happens if you have colors disabled in your terminal? Does this do nothing? Or does it start inserting ANSI escape codes in plain text? https://github.com/llvm/llvm-project/pull/86159 ___ lldb-commits mailing list lldb-commits@li

[Lldb-commits] [lldb] [lldb] Invert relationship between Process and AddressableBits (PR #85858)

2024-03-20 Thread Alex Langford via lldb-commits
https://github.com/bulbazord closed https://github.com/llvm/llvm-project/pull/85858 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Remove process restart prompt from TestSourceManager (PR #85861)

2024-03-20 Thread Alex Langford via lldb-commits
https://github.com/bulbazord closed https://github.com/llvm/llvm-project/pull/85861 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Remove process restart prompt from TestSourceManager (PR #85861)

2024-03-19 Thread Alex Langford via lldb-commits
https://github.com/bulbazord updated https://github.com/llvm/llvm-project/pull/85861 >From c24630bbccd3d53079314f7dc6393ffa27ea192f Mon Sep 17 00:00:00 2001 From: Alex Langford Date: Tue, 19 Mar 2024 13:18:23 -0700 Subject: [PATCH 1/2] [lldb] Remove process restart prompt from TestSourceManage

[Lldb-commits] [lldb] [lldb] Remove process restart prompt from TestSourceManager (PR #85861)

2024-03-19 Thread Alex Langford via lldb-commits
@@ -323,13 +323,13 @@ def test_artificial_source_location(self): ) self.expect( -"run", -RUN_SUCCEEDED, +"thread info", substrs=[f"{src_file}:0", "stop reason = breakpoint"] +) +self.expect( +"fra

[Lldb-commits] [lldb] [lldb] Remove process restart prompt from TestSourceManager (PR #85861)

2024-03-19 Thread Alex Langford via lldb-commits
https://github.com/bulbazord created https://github.com/llvm/llvm-project/pull/85861 In TestSourceManager, test_artificial_source_location will give the process restart prompt if you run the test individually. The reason is that we run the process twice: first using a convenience function to r

[Lldb-commits] [lldb] [lldb] Invert relationship between Process and AddressableBits (PR #85858)

2024-03-19 Thread Alex Langford via lldb-commits
https://github.com/bulbazord created https://github.com/llvm/llvm-project/pull/85858 AddressableBits is in the Utility module of LLDB. It currently directly refers to Process, which is from the Target LLDB module. This is a layering violation which concretely means that it is impossible to lin

[Lldb-commits] [lldb] [lldb] Omit --show-globals in `help target var` (PR #85855)

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

[Lldb-commits] [lldb] [lldb] Omit --show-globals in `help target var` (PR #85855)

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

[Lldb-commits] [lldb] [lldb] Omit --show-globals in `help target var` (PR #85855)

2024-03-19 Thread Alex Langford via lldb-commits
@@ -50,6 +50,11 @@ static constexpr OptionDefinition g_variable_options[] = { "Specify a summary string to use to format the variable output."}, }; +static constexpr auto g_num_frame_options = 4; bulbazord wrote: Is this number computable? Or does it nee

[Lldb-commits] [lldb] [lldb] Omit --show-globals in `help target var` (PR #85855)

2024-03-19 Thread Alex Langford via lldb-commits
https://github.com/bulbazord commented: Big fan of centralizing the options here. I had one question about automating another portion of this, but otherwise LGTM. https://github.com/llvm/llvm-project/pull/85855 ___ lldb-commits mailing list lldb-commi

[Lldb-commits] [lldb] [lldb] Show module name in progress update for downloading symbols (PR #85342)

2024-03-15 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. +1 to Adrian's suggestion. LGTM since you've addressed that now https://github.com/llvm/llvm-project/pull/85342 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/c

[Lldb-commits] [lldb] [lldb] Add ability to detect darwin host linker version to xfail tests (PR #83941)

2024-03-07 Thread Alex Langford via lldb-commits
https://github.com/bulbazord closed https://github.com/llvm/llvm-project/pull/83941 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Add ability to detect darwin host linker version to xfail tests (PR #83941)

2024-03-07 Thread Alex Langford via lldb-commits
https://github.com/bulbazord updated https://github.com/llvm/llvm-project/pull/83941 >From 89d1c201636403bb26f12cf9681cbaf86b5c943b Mon Sep 17 00:00:00 2001 From: Alex Langford Date: Mon, 4 Mar 2024 14:17:20 -0800 Subject: [PATCH] [lldb] Add ability to detect darwin host linker version to xfai

[Lldb-commits] [lldb] Fix MSVC build issues (PR #84362)

2024-03-07 Thread Alex Langford via lldb-commits
@@ -168,8 +168,8 @@ class ConstString { // Implicitly convert \class ConstString instances to \class StringRef. operator llvm::StringRef() const { return GetStringRef(); } - // Implicitly convert \class ConstString instances to \class std::string_view. - operator std::s

[Lldb-commits] [lldb] [lldb] Add ability to detect darwin host linker version to xfail tests (PR #83941)

2024-03-07 Thread Alex Langford via lldb-commits
https://github.com/bulbazord updated https://github.com/llvm/llvm-project/pull/83941 >From a72d9d259b441c338399340d630ed7a64c1e228a Mon Sep 17 00:00:00 2001 From: Alex Langford Date: Mon, 4 Mar 2024 14:17:20 -0800 Subject: [PATCH] [lldb] Add ability to detect darwin host linker version to xfai

[Lldb-commits] [lldb] [lldb] Disable shell tests affected by ld_new bug (PR #84246)

2024-03-07 Thread Alex Langford via lldb-commits
bulbazord wrote: > Called it `ld_new-bug`. If it's not the TLS bug, I wonder if the version > range is correct. The TLS bug in the new linker is explicitly from versions 1000 to 1109. If this isn't related to TLS, we'll need to confirm with the linker folks on our side. https://github.com/llv

[Lldb-commits] [lldb] [lldb] Add ability to detect darwin host linker version to xfail tests (PR #83941)

2024-03-06 Thread Alex Langford via lldb-commits
bulbazord wrote: > To start with option #​1, I created #84246 Just took a look, thanks for taking care of that. I'll address your feedback (or just look at what you did in the other PR) and update this tomorrow. https://github.com/llvm/llvm-project/pull/83941 _

[Lldb-commits] [lldb] [lldb] Disable shell tests affected by ld64 bug (PR #84246)

2024-03-06 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. Thanks for taking care of that! https://github.com/llvm/llvm-project/pull/84246 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-comm

[Lldb-commits] [lldb] [lldb] Remove unused #includes in ClangModulesDeclVendor.cpp (PR #84262)

2024-03-06 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. https://github.com/llvm/llvm-project/pull/84262 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] Change the return type of CalculateNumChildren to uint32_t. (PR #83501)

2024-03-05 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. I'm a little disappointed but I think this is the right step to take. Thanks! https://github.com/llvm/llvm-project/pull/83501 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lis

[Lldb-commits] [lldb] [lldb] Add ability to detect darwin host linker version to xfail tests (PR #83941)

2024-03-04 Thread Alex Langford via lldb-commits
https://github.com/bulbazord created https://github.com/llvm/llvm-project/pull/83941 When Apple released its new linker, it had a subtle bug that caused LLDB's TLS tests to fail. Unfortunately this means that TLS tests are not going to work on machines that have affected versions of the linker

[Lldb-commits] [lldb] Change the return type of CalculateNumChildren to uint32_t. (PR #83501)

2024-03-04 Thread Alex Langford via lldb-commits
bulbazord wrote: > I would almost vote to change everything to `uint64_t` except for the public > API since we can't change the API without breaking. Though I winder if we can > actually change this one: > > ``` > uint64_t SBValue::GetNumChildren(); > ``` > > Since the return value isn't mang

[Lldb-commits] [lldb] Change the return type of CalculateNumChildren to uint32_t. (PR #83501)

2024-02-29 Thread Alex Langford via lldb-commits
bulbazord wrote: Why not increase TypeSystem::GetNumChildren to return a size_t instead? https://github.com/llvm/llvm-project/pull/83501 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-comm

[Lldb-commits] [lldb] [lldb] [debugserver] fix qLaunchSuccess error, add QErrorStringInPacketSupported (PR #82593)

2024-02-29 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. Looks great!!! 😄 Thanks for fixing the bug and gardening! https://github.com/llvm/llvm-project/pull/82593 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/

[Lldb-commits] [lldb] [lldb][progress][NFC] Fix Doxygen information (PR #83502)

2024-02-29 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. https://github.com/llvm/llvm-project/pull/83502 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][test][NFC] Add option to exclude third_party packages (PR #83191)

2024-02-29 Thread Alex Langford via lldb-commits
bulbazord wrote: @DavidSpickett If you haven't already, might I suggest looking into a CMake setting I implemented last year? `LLDB_ENFORCE_STRICT_TEST_REQUIREMENTS` -- this will cause your CMake configure step to fail if your bots are missing python packages so that you know your bots are run

[Lldb-commits] [lldb] [lldb] Ignore swig warnings about shadowed overloads (PR #83317)

2024-02-28 Thread Alex Langford via lldb-commits
https://github.com/bulbazord closed https://github.com/llvm/llvm-project/pull/83317 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] Fix interactive use of "command script add". (PR #83350)

2024-02-28 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. Thinkos are the most insidious bugs. Nice catch. https://github.com/llvm/llvm-project/pull/83350 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/l

[Lldb-commits] [lldb] Change `image list -r` so that it actually shows the ref count and whether the image is in the shared cache. (PR #83341)

2024-02-28 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. https://github.com/llvm/llvm-project/pull/83341 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Remove -d(ebug) mode from the lldb driver (PR #83330)

2024-02-28 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. :) https://github.com/llvm/llvm-project/pull/83330 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Ignore swig warnings about shadowed overloads (PR #83317)

2024-02-28 Thread Alex Langford via lldb-commits
https://github.com/bulbazord created https://github.com/llvm/llvm-project/pull/83317 This specifically addresses the warnings: $LLVM/lldb/include/lldb/API/SBCommandReturnObject.h:119: Warning 509: Overloaded method lldb::SBCommandReturnObject::PutCString(char const *) effectively ignored, $LLV

[Lldb-commits] [lldb] [lldb][test] Exclude third_party packages by default (PR #83191)

2024-02-27 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. LGTM @JDevlieghere @adrian-prantl we should consider adding this to the list of required python modules on our bots too and enforce it with `LLDB_ENFORCE_STRICT_TEST_REQUIREMENTS`? Probably not in this PR, but after we can get our bots

[Lldb-commits] [lldb] [lldb] Use CreateOptionParsingError in CommandObjectBreakpoint (PR #83086)

2024-02-27 Thread Alex Langford via lldb-commits
https://github.com/bulbazord closed https://github.com/llvm/llvm-project/pull/83086 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Use CreateOptionParsingError in CommandObjectBreakpoint (PR #83086)

2024-02-26 Thread Alex Langford via lldb-commits
https://github.com/bulbazord created https://github.com/llvm/llvm-project/pull/83086 This updates the remaining SetOptionValue methods in CommandObjectBreakpoint to use CreateOptionParsingError. I found a few minor bugs that were fixed during this refactor (e.g. using the wrong flag in an err

[Lldb-commits] [lldb] [lldb] [debugserver] fix qLaunchSuccess error, add QErrorStringInPacketSupported (PR #82593)

2024-02-23 Thread Alex Langford via lldb-commits
@@ -3944,15 +3955,22 @@ rnb_err_t RNBRemote::HandlePacket_v(const char *p) { // The order of these checks is important. if (process_does_not_exist (pid_attaching_to)) { DNBLogError("Tried to attach to pid that doesn't exist"); - std::string

[Lldb-commits] [lldb] [lldb][docs] Remove/update docs pointing to unittest2 (PR #82672)

2024-02-22 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. LGTM! https://github.com/llvm/llvm-project/pull/82672 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][test] Remove vendored packages `unittest2` and `progress` (PR #82670)

2024-02-22 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. 🥳 Please wait a little bit for others to look. Thanks for taking care of this! https://github.com/llvm/llvm-project/pull/82670 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://

[Lldb-commits] [lldb] [lldb] [debugserver] fix qLaunchSuccess error, add QErrorStringInPacketSupported (PR #82593)

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

[Lldb-commits] [lldb] [lldb] [debugserver] fix qLaunchSuccess error, add QErrorStringInPacketSupported (PR #82593)

2024-02-22 Thread Alex Langford via lldb-commits
@@ -3944,15 +3955,22 @@ rnb_err_t RNBRemote::HandlePacket_v(const char *p) { // The order of these checks is important. if (process_does_not_exist (pid_attaching_to)) { DNBLogError("Tried to attach to pid that doesn't exist"); - std::string

[Lldb-commits] [lldb] [lldb] [debugserver] fix qLaunchSuccess error, add QErrorStringInPacketSupported (PR #82593)

2024-02-22 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. LGTM, seems like a good fix. One question/suggestion. https://github.com/llvm/llvm-project/pull/82593 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mail

[Lldb-commits] [lldb] [lldb] Standardize command option parsing error messages (PR #82273)

2024-02-21 Thread Alex Langford via lldb-commits
https://github.com/bulbazord closed https://github.com/llvm/llvm-project/pull/82273 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][test] Modernize assertEqual(value, bool) (PR #82526)

2024-02-21 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. Thanks! https://github.com/llvm/llvm-project/pull/82526 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Standardize command option parsing error messages (PR #82273)

2024-02-21 Thread Alex Langford via lldb-commits
bulbazord wrote: I've added a doxygen comment to the new function I introduced. I plan on landing this later today if there are no objections. https://github.com/llvm/llvm-project/pull/82273 ___ lldb-commits mailing list lldb-commits@lists.llvm.org ht

[Lldb-commits] [lldb] [lldb] Standardize command option parsing error messages (PR #82273)

2024-02-21 Thread Alex Langford via lldb-commits
https://github.com/bulbazord updated https://github.com/llvm/llvm-project/pull/82273 >From 790810f9318c7947fe2edd187f60425a85c949b5 Mon Sep 17 00:00:00 2001 From: Alex Langford Date: Thu, 15 Feb 2024 17:39:42 -0800 Subject: [PATCH 1/2] [lldb] Standardize command option parsing error messages I

[Lldb-commits] [lldb] [lldb][test] Modernize asserts (PR #82503)

2024-02-21 Thread Alex Langford via lldb-commits
@@ -456,8 +457,9 @@ def queues_with_libBacktraceRecording(self): "doing_the_work_2", "queue 2's pending item #0 should be doing_the_work_2", ) -self.assertTrue( -queue_performer_2.GetPendingItemAtIndex().IsValid() == False

[Lldb-commits] [lldb] [lldb][test] Modernize asserts (PR #82503)

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

[Lldb-commits] [lldb] [lldb][test] Modernize asserts (PR #82503)

2024-02-21 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. I did a quick manual inspection of all of them, the transformation produced by Teyit looks correct to me. I did notice a few places where we were doing convoluted checks (I left a comment on one) but those should be addressed in follow-u

[Lldb-commits] [lldb] [lldb] Standardize command option parsing error messages (PR #82273)

2024-02-20 Thread Alex Langford via lldb-commits
bulbazord wrote: > > > This LGTM! > > > I don't think I can see far enough ahead on what you are planning here, > > > but I was just wondering if the ultimate goal is to have the > > > `option_arg.getAsT` return an `Expected`. In this case, wouldn't all > > > these arguments (short option, lon

[Lldb-commits] [lldb] [lldb] Standardize command option parsing error messages (PR #82273)

2024-02-20 Thread Alex Langford via lldb-commits
bulbazord wrote: > This LGTM! > > I don't think I can see far enough ahead on what you are planning here, but I > was just wondering if the ultimate goal is to have the `option_arg.getAsT` > return an `Expected`. In this case, wouldn't all these arguments (short > option, long option, additio

[Lldb-commits] [lldb] Centralize the handling of completion for simple argument lists. (PR #82085)

2024-02-19 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. LGTM, thanks! https://github.com/llvm/llvm-project/pull/82085 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Standardize command option parsing error messages (PR #82273)

2024-02-19 Thread Alex Langford via lldb-commits
https://github.com/bulbazord created https://github.com/llvm/llvm-project/pull/82273 I have been looking to simplify parsing logic and improve the interfaces so that they are both easier to use and harder to abuse. To be specific, I am referring to functions such as `OptionArgParser::ToBoolean

[Lldb-commits] [lldb] [lldb] Don't rely on ScriptInterpreterPythonImpl::Initialize in the unit tests (PR #82096)

2024-02-17 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. https://github.com/llvm/llvm-project/pull/82096 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Don't rely on ScriptInterpreterPythonImpl::Initialize in the unit tests (PR #82096)

2024-02-17 Thread Alex Langford via lldb-commits
bulbazord wrote: > The downside of doing the initialization manually is that we do lose a bit of > test coverage. For example, issue #70453 also manifested itself in the unit > tests. I think this is an acceptable tradeoff. The unit tests are for testing LLDB's python internals, not for testi

[Lldb-commits] [lldb] [lldb] Call Import_AppendInittab exactly once before Py_Initialize (PR #82095)

2024-02-16 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. Makes sense to me. https://github.com/llvm/llvm-project/pull/82095 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] Centralize the handling of completion for simple argument lists. (PR #82085)

2024-02-16 Thread Alex Langford via lldb-commits
@@ -1139,6 +1097,15 @@ class CommandObjectPlatformProcessLaunch : public CommandObjectParsed { m_arguments.push_back({run_arg_arg}); } + void + HandleArgumentCompletion(CompletionRequest &request, + OptionElementVector &opt_element_vector) ov

[Lldb-commits] [lldb] Centralize the handling of completion for simple argument lists. (PR #82085)

2024-02-16 Thread Alex Langford via lldb-commits
@@ -305,6 +305,42 @@ void CommandObject::HandleCompletion(CompletionRequest &request) { } } +void +CommandObject::HandleArgumentCompletion(CompletionRequest &request, + OptionElementVector &opt_element_vector) { + size_t num_arg_entries = GetNumAr

[Lldb-commits] [lldb] Centralize the handling of completion for simple argument lists. (PR #82085)

2024-02-16 Thread Alex Langford via lldb-commits
@@ -243,7 +243,7 @@ static constexpr CommandObject::ArgumentTableEntry g_argument_table[] = { { lldb::eArgTypeLogCategory, "log-category", lldb::CompletionType::eNoCompletion, {}, { nullptr, false }, "The name of a category within a log channel, e.g. all (try \"log list\"

[Lldb-commits] [lldb] [lldb] Store proper integer bitwidth in Scalar Type (PR #81451)

2024-02-14 Thread Alex Langford via lldb-commits
bulbazord wrote: > @clayborg @bulbazord we have extension in lldb to support cobol code > debugging, we require byteswapping there. upstream version of lldb does not > do byteswapping on scalar so no problem seen. Maybe not, but this should still be testable with a unit test. If somebody modi

[Lldb-commits] [lldb] Report only loaded debug info in statistics dump (PR #81706)

2024-02-14 Thread Alex Langford via lldb-commits
https://github.com/bulbazord commented: Idea looks ok, the naming could use a bit of work. Right now it feels a bit generic and I'm not sure what "loading" means. I like Greg's suggestion here. https://github.com/llvm/llvm-project/pull/81706 ___ lldb-

[Lldb-commits] [lldb] Report only loaded debug info in statistics dump (PR #81706)

2024-02-14 Thread Alex Langford via lldb-commits
@@ -224,6 +224,7 @@ llvm::json::Value DebuggerStats::ReportStatistics( const lldb_private::StatisticsOptions &options) { const bool summary_only = options.summary_only; + const bool force_laoding = options.force_loading; bulbazord wrote: typo in this o

[Lldb-commits] [lldb] [lldb][NFCI] Remove CommandObjectProcessHandle::VerifyCommandOptionValue (PR #79901)

2024-02-14 Thread Alex Langford via lldb-commits
https://github.com/bulbazord closed https://github.com/llvm/llvm-project/pull/79901 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][NFCI] Remove CommandObjectProcessHandle::VerifyCommandOptionValue (PR #79901)

2024-02-13 Thread Alex Langford via lldb-commits
@@ -1666,33 +1646,52 @@ class CommandObjectProcessHandle : public CommandObjectParsed { // the user's options. ProcessSP process_sp = target.GetProcessSP(); -int stop_action = -1; // -1 means leave the current setting alone -int pass_action = -1; // -1 mea

[Lldb-commits] [lldb] [lldb][NFCI] Remove CommandObjectProcessHandle::VerifyCommandOptionValue (PR #79901)

2024-02-13 Thread Alex Langford via lldb-commits
bulbazord wrote: ping @clayborg How does this look now? https://github.com/llvm/llvm-project/pull/79901 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Store proper integer bitwidth in Scalar Type (PR #81451)

2024-02-13 Thread Alex Langford via lldb-commits
bulbazord wrote: > > This uses `DataExtractor::GetMaxU64` which already does this under the > > hood. What does this do that isn't already being done? It may help if you > > add a test case to show what you are trying to fix. > > @clayborg @bulbazord The problem with GetMaxU64 is that it alway

[Lldb-commits] [lldb] [lldb] Detect a Darwin kernel issue and work around it (PR #81573)

2024-02-13 Thread Alex Langford via lldb-commits
@@ -79,6 +79,11 @@ class StopInfo : public std::enable_shared_from_this { virtual bool IsValidForOperatingSystemThread(Thread &thread) { return true; } + /// A Continue operation can result in a false stop event + /// before any execution has happened in certain cases on

[Lldb-commits] [lldb] [lldb] Detect a Darwin kernel issue and work around it (PR #81573)

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

[Lldb-commits] [lldb] [lldb] Detect a Darwin kernel issue and work around it (PR #81573)

2024-02-13 Thread Alex Langford via lldb-commits
https://github.com/bulbazord commented: Makes sense to me! https://github.com/llvm/llvm-project/pull/81573 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Detect a Darwin kernel issue and work around it (PR #81573)

2024-02-13 Thread Alex Langford via lldb-commits
@@ -825,6 +806,56 @@ StopInfoSP StopInfoMachException::CreateStopReasonWithMachException( break; } - return StopInfoSP(new StopInfoMachException(thread, exc_type, exc_data_count, - exc_code, exc_sub_code)); + return StopInf

[Lldb-commits] [lldb] [lldb][NFCI] Add header guard to PlatformRemoteAppleXR.h (PR #81565)

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

[Lldb-commits] [lldb] [lldb][NFCI] Add header guard to PlatformRemoteAppleXR.h (PR #81565)

2024-02-12 Thread Alex Langford via lldb-commits
https://github.com/bulbazord updated https://github.com/llvm/llvm-project/pull/81565 >From a1bb825c34a951a0d99ecf03fe86545ed43bbe42 Mon Sep 17 00:00:00 2001 From: Alex Langford Date: Mon, 12 Feb 2024 19:05:55 -0800 Subject: [PATCH 1/2] [lldb][NFCI] Add header guard to PlatformRemoteAppleXR.h -

[Lldb-commits] [lldb] [lldb][NFCI] Add header guard to PlatformRemoteAppleXR.h (PR #81565)

2024-02-12 Thread Alex Langford via lldb-commits
https://github.com/bulbazord created https://github.com/llvm/llvm-project/pull/81565 None >From a1bb825c34a951a0d99ecf03fe86545ed43bbe42 Mon Sep 17 00:00:00 2001 From: Alex Langford Date: Mon, 12 Feb 2024 19:05:55 -0800 Subject: [PATCH] [lldb][NFCI] Add header guard to PlatformRemoteAppleXR.h

[Lldb-commits] [lldb] [lldb] Store proper integer bitwidth in Scalar Type (PR #81451)

2024-02-12 Thread Alex Langford via lldb-commits
https://github.com/bulbazord requested changes to this pull request. This uses `DataExtractor::GetMaxU64` which already does this under the hood. What does this do that isn't already being done? It may help if you add a test case to show what you are trying to fix. https://github.com/llvm/llvm

[Lldb-commits] [lldb] [LLDB][Docs] Replace LLDB_RELOCATABLE_PYTHON with LLDB_EMBED_PYTHON_HOME (PR #81310)

2024-02-10 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. https://github.com/llvm/llvm-project/pull/81310 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] checks beforehand if lldb can trace/attach a process on FreeBSD. (PR #79662)

2024-02-10 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. LGTM but I'm not really an expert on FreeBSD. @emaste ? https://github.com/llvm/llvm-project/pull/79662 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/ma

[Lldb-commits] [lldb] Add the ability to define a Python based command that uses CommandObjectParsed (PR #70734)

2024-02-10 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. Ok, I think this is good to go in. There are things that can be improved but it would be better to land this and change things in follow up PRs instead of continually adjusting this one. https://github.com/llvm/llvm-project/pull/70734 __

[Lldb-commits] [lldb] Add the ability to define a Python based command that uses CommandObjectParsed (PR #70734)

2024-02-10 Thread Alex Langford via lldb-commits
@@ -0,0 +1,315 @@ +""" +This module implements a couple of utility classes to make writing +lldb parsed commands more Pythonic. +The way to use it is to make a class for you command that inherits from ParsedCommandBase. +That will make an LLDBOVParser which you will use for your

[Lldb-commits] [lldb] [lldb] [NFC] Remove min pkt size for compression setting (PR #81075)

2024-02-07 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. LGTM. I also noticed there's no tests for this functionality... https://github.com/llvm/llvm-project/pull/81075 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cg

[Lldb-commits] [lldb] [lldb] Refactor GetFormatFromCString to always check for partial matches (NFC) (PR #81018)

2024-02-07 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. Makes sense to me. If the test suite is happy then I think this is fine. https://github.com/llvm/llvm-project/pull/81018 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.ll

[Lldb-commits] [lldb] [lldb] Add comment to ParseInternal in FormatEntity (NFC) (PR #81018)

2024-02-07 Thread Alex Langford via lldb-commits
@@ -2204,7 +2204,9 @@ static Status ParseInternal(llvm::StringRef &format, Entry &parent_entry, return error; } } else if (FormatManager::GetFormatFromCString( - entry.printf_format.c_str(), true, entr

[Lldb-commits] [lldb] Don't count all the frames just to skip the current inlined ones. (PR #80918)

2024-02-06 Thread Alex Langford via lldb-commits
@@ -608,11 +608,10 @@ static bool Evaluate_DW_OP_entry_value(std::vector &stack, StackFrameSP parent_frame = nullptr; addr_t return_pc = LLDB_INVALID_ADDRESS; uint32_t current_frame_idx = current_frame->GetFrameIndex(); - uint32_t num_frames = thread->GetStackFrameCount

[Lldb-commits] [lldb] [lldb] Expand background symbol lookup (PR #80890)

2024-02-06 Thread Alex Langford via lldb-commits
https://github.com/bulbazord approved this pull request. I'm happy w/ the name. Thanks! https://github.com/llvm/llvm-project/pull/80890 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commi

[Lldb-commits] [lldb] [lldb] Expand background symbol lookup (PR #80890)

2024-02-06 Thread Alex Langford via lldb-commits
@@ -5,10 +5,11 @@ let Definition = "modulelist" in { Global, DefaultTrue, Desc<"Control the use of external tools and repositories to locate symbol files. Directories listed in target.debug-file-search-paths and directory of the executable are always checked first

[Lldb-commits] [lldb] [lldb] Expand background symbol lookup (PR #80890)

2024-02-06 Thread Alex Langford via lldb-commits
@@ -5,10 +5,11 @@ let Definition = "modulelist" in { Global, DefaultTrue, Desc<"Control the use of external tools and repositories to locate symbol files. Directories listed in target.debug-file-search-paths and directory of the executable are always checked first

[Lldb-commits] [lldb] Add a new SBProcess:: GetCoreFile() API (PR #80767)

2024-02-05 Thread Alex Langford via lldb-commits
bulbazord wrote: I'm not sure I understand. Why do you need to get the path to the core file through the SBAPI? Didn't you also load it through the SBAPI too? https://github.com/llvm/llvm-project/pull/80767 ___ lldb-commits mailing list lldb-commits@l

[Lldb-commits] [lldb] Support statistics dump summary only mode (PR #80745)

2024-02-05 Thread Alex Langford via lldb-commits
@@ -241,7 +241,7 @@ class DWARFUnit : public UserID { FileSpec GetFile(size_t file_idx); FileSpec::Style GetPathStyle(); - SymbolFileDWARFDwo *GetDwoSymbolFile(); + SymbolFileDWARFDwo *GetDwoSymbolFile(bool load_if_needed = true); bulbazord wrote: Inste

<    1   2   3   4   5   6   7   8   9   10   >