[Lldb-commits] [lldb] [lldb-dap] Support throw and catch exception breakpoints for dynamica… (PR #97871)

2024-07-05 Thread Walter Erquinigo via lldb-commits
walter-erquinigo wrote: This is a screenshot of how it's looking for me on VSCode. ![image](https://github.com/llvm/llvm-project/assets/1613874/7a344b26-549c-4be6-b7d6-7082e701ee88) https://github.com/llvm/llvm-project/pull/97871 ___ lldb-commits

[Lldb-commits] [lldb] [lldb-dap] Support throw and catch exception breakpoints for dynamica… (PR #97871)

2024-07-05 Thread via lldb-commits
llvmbot wrote: @llvm/pr-subscribers-lldb Author: Walter Erquinigo (walter-erquinigo) Changes …lly registered languages First of all, this is done to support exceptions for the Mojo language, but it's done in a way that will benefit any other plugin language. 1. I added a new lldb-dap

[Lldb-commits] [lldb] [lldb-dap] Support throw and catch exception breakpoints for dynamica… (PR #97871)

2024-07-05 Thread Walter Erquinigo via lldb-commits
https://github.com/walter-erquinigo created https://github.com/llvm/llvm-project/pull/97871 …lly registered languages First of all, this is done to support exceptions for the Mojo language, but it's done in a way that will benefit any other plugin language. 1. I added a new lldb-dap CLI

[Lldb-commits] [lldb] cf1ded3 - [lldb] Silence function cast warning when building with Clang ToT targetting Windows

2024-07-05 Thread Alexandre Ganea via lldb-commits
Author: Alexandre Ganea Date: 2024-07-05T20:49:40-04:00 New Revision: cf1ded3ac248ad4feeed7b4dd20c60b7e3c40339 URL: https://github.com/llvm/llvm-project/commit/cf1ded3ac248ad4feeed7b4dd20c60b7e3c40339 DIFF:

[Lldb-commits] [lldb] [lldb/Commands] Add `scripting template list` command with auto discovery (PR #97273)

2024-07-05 Thread Alex Langford via lldb-commits
@@ -19,6 +19,12 @@ if (LLDB_ENABLE_LIBEDIT) list(APPEND LLDB_LIBEDIT_LIBS LibEdit::LibEdit) endif() +set_property(GLOBAL PROPERTY LLDB_EXTRA_SCRIPT_PLUGINS + lldbPluginOperatingSystemPythonInterface + lldbPluginScriptedProcessPythonInterface +

[Lldb-commits] [lldb] [lldb/Commands] Add `scripting template list` command with auto discovery (PR #97273)

2024-07-05 Thread Med Ismail Bennani via lldb-commits
@@ -19,6 +19,12 @@ if (LLDB_ENABLE_LIBEDIT) list(APPEND LLDB_LIBEDIT_LIBS LibEdit::LibEdit) endif() +set_property(GLOBAL PROPERTY LLDB_EXTRA_SCRIPT_PLUGINS + lldbPluginOperatingSystemPythonInterface + lldbPluginScriptedProcessPythonInterface +

[Lldb-commits] [lldb] [lldb/Commands] Add `scripting template list` command with auto discovery (PR #97273)

2024-07-05 Thread Alex Langford via lldb-commits
@@ -29,6 +29,9 @@ add_subdirectory(UnwindAssembly) set(LLDB_STRIPPED_PLUGINS) get_property(LLDB_ALL_PLUGINS GLOBAL PROPERTY LLDB_PLUGINS) +get_property(LLDB_EXTRA_PLUGINS GLOBAL PROPERTY LLDB_EXTRA_SCRIPT_PLUGINS) +list(APPEND LLDB_ALL_PLUGINS ${LLDB_EXTRA_PLUGINS})

[Lldb-commits] [lldb] [llvm] [LLDB][Minidump] Support minidumps where there are multiple exception streams (PR #97470)

2024-07-05 Thread Jacob Lalonde via lldb-commits
Jlalond wrote: @jeffreytan81 I think the callout for multiple exception is a good question. I made a C# testbed to see what would happen if I had multiple simultaneous exceptions. [Gist here](https://gist.github.com/Jlalond/467bc990f10fbb75cc9ca7db897a7beb). When manually collecting a

[Lldb-commits] [lldb] [llvm] [LLDB][Minidump] Support minidumps where there are multiple exception streams (PR #97470)

2024-07-05 Thread via lldb-commits
@@ -464,8 +464,8 @@ Stream::create(const Directory , const object::MinidumpFile ) { StreamKind Kind = getKind(StreamDesc.Type); switch (Kind) { case StreamKind::Exception: { -Expected ExpectedExceptionStream = -File.getExceptionStream(); +Expected

[Lldb-commits] [lldb] [llvm] [LLDB][Minidump] Support minidumps where there are multiple exception streams (PR #97470)

2024-07-05 Thread via lldb-commits
@@ -53,6 +54,31 @@ Expected MinidumpFile::getString(size_t Offset) const { return Result; } +Expected> +MinidumpFile::getExceptionStreams() const { + // Scan the directories for exceptions first + std::vector exceptionStreams; + for (const auto : Streams) { +if

[Lldb-commits] [lldb] [llvm] [LLDB][Minidump] Support minidumps where there are multiple exception streams (PR #97470)

2024-07-05 Thread via lldb-commits
https://github.com/jeffreytan81 requested changes to this pull request. One concern is that, whether minidump format specification supports multiple exception streams. If this is not supported by spec, we may generate minidump that only lldb can read/parse but can fail other consumers. It

[Lldb-commits] [lldb] [llvm] [LLDB][Minidump] Support minidumps where there are multiple exception streams (PR #97470)

2024-07-05 Thread via lldb-commits
@@ -82,15 +82,24 @@ class MinidumpFile : public Binary { return getListStream(minidump::StreamType::ThreadList); } - /// Returns the contents of the Exception stream. An error is returned if the - /// file does not contain this stream, or the stream is smaller than

[Lldb-commits] [lldb] [llvm] [LLDB][Minidump] Support minidumps where there are multiple exception streams (PR #97470)

2024-07-05 Thread via lldb-commits
@@ -53,6 +54,31 @@ Expected MinidumpFile::getString(size_t Offset) const { return Result; } +Expected> +MinidumpFile::getExceptionStreams() const { + // Scan the directories for exceptions first + std::vector exceptionStreams; + for (const auto : Streams) { +if

[Lldb-commits] [lldb] [llvm] [LLDB][Minidump] Support minidumps where there are multiple exception streams (PR #97470)

2024-07-05 Thread via lldb-commits
@@ -9,6 +9,7 @@ #include "llvm/Object/Minidump.h" #include "llvm/Object/Error.h" #include "llvm/Support/ConvertUTF.h" +#include jeffreytan81 wrote: Is this needed? https://github.com/llvm/llvm-project/pull/97470

[Lldb-commits] [lldb] [llvm] [LLDB][Minidump] Support minidumps where there are multiple exception streams (PR #97470)

2024-07-05 Thread via lldb-commits
@@ -109,7 +109,7 @@ class ProcessMinidump : public PostMortemProcess { private: lldb::DataBufferSP m_core_data; llvm::ArrayRef m_thread_list; - const minidump::ExceptionStream *m_active_exception; + std::unordered_map m_exceptions_by_tid; jeffreytan81

[Lldb-commits] [lldb] [llvm] [LLDB][Minidump] Support minidumps where there are multiple exception streams (PR #97470)

2024-07-05 Thread via lldb-commits
@@ -82,15 +82,24 @@ class MinidumpFile : public Binary { return getListStream(minidump::StreamType::ThreadList); } - /// Returns the contents of the Exception stream. An error is returned if the - /// file does not contain this stream, or the stream is smaller than

[Lldb-commits] [lldb] [llvm] [LLDB][Minidump] Support minidumps where there are multiple exception streams (PR #97470)

2024-07-05 Thread via lldb-commits
@@ -209,7 +208,20 @@ Status ProcessMinidump::DoLoadCore() { GetTarget().SetArchitecture(arch, true /*set_platform*/); m_thread_list = m_minidump_parser->GetThreads(); - m_active_exception = m_minidump_parser->GetExceptionStream(); + std::vector exception_streams =

[Lldb-commits] [lldb] [llvm] [LLDB][Minidump] Support minidumps where there are multiple exception streams (PR #97470)

2024-07-05 Thread via lldb-commits
https://github.com/jeffreytan81 edited https://github.com/llvm/llvm-project/pull/97470 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

2024-07-05 Thread Alex Langford via lldb-commits
https://github.com/bulbazord commented: >From an API standpoint, there doesn't actually seem to be a huge difference >between an empty StringMap and an optional with an empty string map in it >right? Why not return a map every time? https://github.com/llvm/llvm-project/pull/97824

[Lldb-commits] [lldb] 3bfc516 - [lldb-dap][NFC] Minor rename

2024-07-05 Thread walter erquinigo via lldb-commits
Author: walter erquinigo Date: 2024-07-05T13:12:13-04:00 New Revision: 3bfc5167d9e49b9a53e364e8d8853fce543cca0f URL: https://github.com/llvm/llvm-project/commit/3bfc5167d9e49b9a53e364e8d8853fce543cca0f DIFF:

[Lldb-commits] [lldb] [lldb][test] Fix type error when calling random.randrange with 'float' arg (PR #97328)

2024-07-05 Thread Kendal Harland via lldb-commits
kendalharland wrote: I'll also need help merging this since I don't have write access to the repo. https://github.com/llvm/llvm-project/pull/97328 ___ lldb-commits mailing list lldb-commits@lists.llvm.org

[Lldb-commits] [lldb] Fix flake in TestZerothFrame.py (PR #96685)

2024-07-05 Thread Kendal Harland via lldb-commits
kendalharland wrote: I'll need help merging this since I don't have write access to the repo. https://github.com/llvm/llvm-project/pull/96685 ___ lldb-commits mailing list lldb-commits@lists.llvm.org

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

2024-07-05 Thread David Spickett via lldb-commits
@@ -22,13 +22,13 @@ using namespace llvm; int main(int argc, char **argv) { #if defined(__i386__) || defined(_M_IX86) || \ defined(__x86_64__) || defined(_M_X64) - if (std::optional> features = + if (const std::optional> features =

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

2024-07-05 Thread David Spickett via lldb-commits
https://github.com/DavidSpickett updated https://github.com/llvm/llvm-project/pull/97824 >From 7ebe4e487b763ff26fbab6d75aa7c8694d63e8b1 Mon Sep 17 00:00:00 2001 From: David Spickett Date: Fri, 5 Jul 2024 08:42:22 + Subject: [PATCH 1/3] [llvm][TargetParser] Return optional from

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

2024-07-05 Thread David Spickett via lldb-commits
@@ -22,13 +22,13 @@ using namespace llvm; int main(int argc, char **argv) { #if defined(__i386__) || defined(_M_IX86) || \ defined(__x86_64__) || defined(_M_X64) - if (std::optional> features = + if (const std::optional> features =

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

2024-07-05 Thread Tomas Matheson via lldb-commits
@@ -22,13 +22,13 @@ using namespace llvm; int main(int argc, char **argv) { #if defined(__i386__) || defined(_M_IX86) || \ defined(__x86_64__) || defined(_M_X64) - if (std::optional> features = + if (const std::optional> features =

[Lldb-commits] [lldb] [lldb][DataFormatter] Simplify std::unordered_map::iterator formatter (PR #97754)

2024-07-05 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/97754 >From b10f76bd6d02106e80315a70a7b72461cb6f2a99 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Thu, 4 Jul 2024 13:35:21 +0200 Subject: [PATCH 1/2] [lldb][DataFormatter] Move std::unordered_map::iterator

[Lldb-commits] [lldb] [lldb][DataFormatter] Simplify std::unordered_map::iterator formatter (PR #97754)

2024-07-05 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/97754 >From b10f76bd6d02106e80315a70a7b72461cb6f2a99 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Thu, 4 Jul 2024 13:35:21 +0200 Subject: [PATCH 1/2] [lldb][DataFormatter] Move std::unordered_map::iterator

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

2024-07-05 Thread David Spickett via lldb-commits
@@ -15,22 +15,23 @@ #include "llvm/Support/raw_ostream.h" #include "llvm/TargetParser/Host.h" +#include + using namespace llvm; int main(int argc, char **argv) { #if defined(__i386__) || defined(_M_IX86) || \ defined(__x86_64__) || defined(_M_X64) - StringMap

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

2024-07-05 Thread David Spickett via lldb-commits
https://github.com/DavidSpickett updated https://github.com/llvm/llvm-project/pull/97824 >From 7ebe4e487b763ff26fbab6d75aa7c8694d63e8b1 Mon Sep 17 00:00:00 2001 From: David Spickett Date: Fri, 5 Jul 2024 08:42:22 + Subject: [PATCH 1/2] [llvm][TargetParser] Return optional from

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

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

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

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

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

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

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

2024-07-05 Thread David Spickett via lldb-commits
@@ -1710,15 +1710,17 @@ VendorSignatures getVendorSignature(unsigned *MaxLeaf) { #if defined(__i386__) || defined(_M_IX86) || \ defined(__x86_64__) || defined(_M_X64) -bool sys::getHostCPUFeatures(StringMap ) { +std::optional> sys::getHostCPUFeatures() { unsigned EAX =

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

2024-07-05 Thread Phoebe Wang via lldb-commits
@@ -1710,15 +1710,17 @@ VendorSignatures getVendorSignature(unsigned *MaxLeaf) { #if defined(__i386__) || defined(_M_IX86) || \ defined(__x86_64__) || defined(_M_X64) -bool sys::getHostCPUFeatures(StringMap ) { +std::optional> sys::getHostCPUFeatures() { unsigned EAX =

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

2024-07-05 Thread Tomas Matheson via lldb-commits
https://github.com/tmatheson-arm edited https://github.com/llvm/llvm-project/pull/97824 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

2024-07-05 Thread Tomas Matheson via lldb-commits
@@ -15,22 +15,23 @@ #include "llvm/Support/raw_ostream.h" #include "llvm/TargetParser/Host.h" +#include + using namespace llvm; int main(int argc, char **argv) { #if defined(__i386__) || defined(_M_IX86) || \ defined(__x86_64__) || defined(_M_X64) - StringMap

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

2024-07-05 Thread Tomas Matheson via lldb-commits
https://github.com/tmatheson-arm edited https://github.com/llvm/llvm-project/pull/97824 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

2024-07-05 Thread Tomas Matheson via lldb-commits
https://github.com/tmatheson-arm approved this pull request. https://github.com/llvm/llvm-project/pull/97824 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

2024-07-05 Thread via lldb-commits
llvmbot wrote: @llvm/pr-subscribers-backend-x86 @llvm/pr-subscribers-clang-driver Author: David Spickett (DavidSpickett) Changes Previously this took a reference to a map and returned a bool to say whether it succeeded. This is an optional but with more steps. The only reason to keep it

[Lldb-commits] [clang] [lldb] [llvm] [llvm][TargetParser] Return optional from getHostCPUFeatures (PR #97824)

2024-07-05 Thread David Spickett via lldb-commits
https://github.com/DavidSpickett created https://github.com/llvm/llvm-project/pull/97824 Previously this took a reference to a map and returned a bool to say whether it succeeded. This is an optional but with more steps. The only reason to keep it that way was if someone was appending to an

[Lldb-commits] [lldb] [lldb][DataFormatter] Simplify std::unordered_map::iterator formatter (PR #97754)

2024-07-05 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/97754 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][DataFormatter] Simplify std::unordered_map::iterator formatter (PR #97754)

2024-07-05 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/97754 >From b10f76bd6d02106e80315a70a7b72461cb6f2a99 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Thu, 4 Jul 2024 13:35:21 +0200 Subject: [PATCH 1/2] [lldb][DataFormatter] Move std::unordered_map::iterator

[Lldb-commits] [lldb] [lldb][FreeBSD] Fix NativeRegisterContextFreeBSD_x86_64() declaration (PR #97796)

2024-07-05 Thread via lldb-commits
github-actions[bot] wrote: @kiyolee Congratulations on having your first Pull Request (PR) merged into the LLVM Project! Your changes will be combined with recent changes from other authors, then tested by our [build bots](https://lab.llvm.org/buildbot/). If there is a problem with a

[Lldb-commits] [lldb] [lldb][FreeBSD] Fix NativeRegisterContextFreeBSD_x86_64() declaration (PR #97796)

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

[Lldb-commits] [lldb] b3fa2a6 - [lldb][FreeBSD] Fix NativeRegisterContextFreeBSD_x86_64() declaration (#97796)

2024-07-05 Thread via lldb-commits
Author: Kelvin Lee Date: 2024-07-05T09:05:05+01:00 New Revision: b3fa2a691ff7d5a85bc31fb428cd58d68bfecd10 URL: https://github.com/llvm/llvm-project/commit/b3fa2a691ff7d5a85bc31fb428cd58d68bfecd10 DIFF: https://github.com/llvm/llvm-project/commit/b3fa2a691ff7d5a85bc31fb428cd58d68bfecd10.diff

[Lldb-commits] [lldb] [lldb][FreeBSD] Fix NativeRegisterContextFreeBSD_x86_64() declaration (PR #97796)

2024-07-05 Thread David Spickett via lldb-commits
DavidSpickett wrote: Specifically changes from https://github.com/llvm/llvm-project/pull/85058. https://github.com/llvm/llvm-project/pull/97796 ___ lldb-commits mailing list lldb-commits@lists.llvm.org

[Lldb-commits] [lldb] [lldb][FreeBSD] Fix NativeRegisterContextFreeBSD_x86_64() declaration (PR #97796)

2024-07-05 Thread David Spickett via lldb-commits
https://github.com/DavidSpickett approved this pull request. Yes this is due to me only testing my changes on AArch64, thanks for the patch. https://github.com/llvm/llvm-project/pull/97796 ___ lldb-commits mailing list lldb-commits@lists.llvm.org

[Lldb-commits] [lldb] [lldb][FreeBSD] Fix NativeRegisterContextFreeBSD_x86_64() declaration (PR #97796)

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

[Lldb-commits] [lldb] lldb/FreeBSD: Fix NativeRegisterContextFreeBSD_x86_64() declaration (PR #97796)

2024-07-05 Thread via lldb-commits
llvmbot wrote: @llvm/pr-subscribers-lldb Author: Kelvin Lee (kiyolee) Changes Supposingly this is a typo. --- Full diff: https://github.com/llvm/llvm-project/pull/97796.diff 1 Files Affected: - (modified) lldb/source/Plugins/Process/FreeBSD/NativeRegisterContextFreeBSD_x86_64.h

[Lldb-commits] [lldb] lldb/FreeBSD: Fix NativeRegisterContextFreeBSD_x86_64() declaration (PR #97796)

2024-07-05 Thread via lldb-commits
github-actions[bot] wrote: Thank you for submitting a Pull Request (PR) to the LLVM Project! This PR will be automatically labeled and the relevant teams will be notified. If you wish to, you can add reviewers by using the "Reviewers" section on this page. If this is not working for you,

[Lldb-commits] [lldb] lldb/FreeBSD: Fix NativeRegisterContextFreeBSD_x86_64() declaration (PR #97796)

2024-07-05 Thread Kelvin Lee via lldb-commits
https://github.com/kiyolee created https://github.com/llvm/llvm-project/pull/97796 Supposingly this is a typo. >From dc56ef5d100525d48e7ecc86dc6bb65bceeea114 Mon Sep 17 00:00:00 2001 From: Kelvin Lee Date: Fri, 5 Jul 2024 17:51:20 +1000 Subject: [PATCH] lldb/FreeBSD: Fix