[Lldb-commits] [lldb] [lldb][DWARFASTParserClang] Check DW_AT_declaration to determine static data members (PR #68300)

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

[Lldb-commits] [lldb] [lldb][DWARFASTParserClang] Check DW_AT_declaration to determine static data members (PR #68300)

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

[Lldb-commits] [lldb] [lldb][DWARFASTParserClang] Check DW_AT_declaration to determine static data members (PR #68300)

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

[Lldb-commits] [lldb] [lldb][DWARFASTParserClang] Check DW_AT_declaration to determine static data members (PR #68300)

2023-10-05 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/68300 >From 30ef50b808a8458a60bbd3cdc52b866ee296b6ba Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Thu, 5 Oct 2023 12:13:12 +0100 Subject: [PATCH 1/2] [lldb][DWARFASTParserClang] Check DW_AT_declaration to dete

[Lldb-commits] [lldb] [lldb][DWARFASTParserClang] Check DW_AT_declaration to determine static data members (PR #68300)

2023-10-06 Thread Michael Buch via lldb-commits
https://github.com/Michael137 closed https://github.com/llvm/llvm-project/pull/68300 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][DWARFASTParserClang][NFC] Fix comment regarding static data member detection (PR #68405)

2023-10-06 Thread Michael Buch via lldb-commits
https://github.com/Michael137 created https://github.com/llvm/llvm-project/pull/68405 Fixes misleading comment introduced in `f74aaca63202cabb512c78fe19196ff348d436a8` >From 90db577879200ac4bd33f1078626ca54d8d1dc62 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 6 Oct 2023 11:38:03 +010

[Lldb-commits] [lldb] [lldb][DWARFASTParserClang][NFC] Fix comment regarding static data member detection (PR #68405)

2023-10-06 Thread Michael Buch via lldb-commits
https://github.com/Michael137 closed https://github.com/llvm/llvm-project/pull/68405 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][DWARFASTParserClang][NFC] Fix comment regarding static data member detection (PR #68405)

2023-10-06 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/68405 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][DWARFASTParserClang] Check DW_AT_declaration to determine static data members (PR #68300)

2023-10-06 Thread Michael Buch via lldb-commits
Michael137 wrote: > Hello! It looks like this broke lldb-aarch64-windows bot: > https://lab.llvm.org/buildbot/#/builders/219/builds/6130 Could you please > look at this ? Yup! Was in the process of fixing. I think we just skip this test on windows https://github.com/llvm/llvm-project/pull/683

[Lldb-commits] [lldb] [lldb[test] TestCppUnionStaticMembers.py: XFAIL assertions on windows (PR #68408)

2023-10-06 Thread Michael Buch via lldb-commits
https://github.com/Michael137 created https://github.com/llvm/llvm-project/pull/68408 These tests never worked since their introduction in https://github.com/llvm/llvm-project/pull/68300 >From c5f0e050d8bfaad588693c99b2f680084a956718 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 6 Oct

[Lldb-commits] [lldb] [lldb][DWARFASTParserClang] Check DW_AT_declaration to determine static data members (PR #68300)

2023-10-06 Thread Michael Buch via lldb-commits
Michael137 wrote: @antmox Addressed in https://github.com/llvm/llvm-project/pull/68408 https://github.com/llvm/llvm-project/pull/68300 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commit

[Lldb-commits] [lldb] [lldb[test] TestCppUnionStaticMembers.py: XFAIL assertions on windows (PR #68408)

2023-10-06 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/68408 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb[test] TestCppUnionStaticMembers.py: XFAIL assertions on windows (PR #68408)

2023-10-06 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/68408 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb[test] TestCppUnionStaticMembers.py: XFAIL assertions on windows (PR #68408)

2023-10-06 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/68408 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb[test] TestCppUnionStaticMembers.py: XFAIL assertions on windows (PR #68408)

2023-10-06 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/68408 >From 0692935303b47e3c3f51c55df5ec5d7aac71a6eb Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 6 Oct 2023 12:00:28 +0100 Subject: [PATCH 1/3] [lldb][test] TestCppUnionStaticMembers.py: split out assert

[Lldb-commits] [lldb] [lldb[test] TestCppUnionStaticMembers.py: XFAIL assertions on windows (PR #68408)

2023-10-06 Thread Michael Buch via lldb-commits
https://github.com/Michael137 closed https://github.com/llvm/llvm-project/pull/68408 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][DataFormatter] unordered_map: account for new libc++ __hash_node layout (PR #68574)

2023-10-09 Thread Michael Buch via lldb-commits
https://github.com/Michael137 created https://github.com/llvm/llvm-project/pull/68574 Since D101206 the `__hash_node::__value_` member is wrapped in an anonymous union. `ValueObject::GetChildMemberWithName` doesn't see through the union. This patch accounts for this possible new layout by gett

[Lldb-commits] [lldb] [lldb][DataFormatter] unordered_map: account for new libc++ __hash_node layout (PR #68574)

2023-10-09 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/68574 >From 9001e6a7ac69e1a45f9d32153335feda5523 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Mon, 9 Oct 2023 11:54:56 +0100 Subject: [PATCH] [lldb][DataFormatter] unordered_map: account for new libc++ __h

[Lldb-commits] [lldb] [lldb][DataFormatter] unordered_map: account for new libc++ __hash_node layout (PR #68574)

2023-10-09 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/68574 >From 9001e6a7ac69e1a45f9d32153335feda5523 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Mon, 9 Oct 2023 11:54:56 +0100 Subject: [PATCH 1/2] [lldb][DataFormatter] unordered_map: account for new libc++

[Lldb-commits] [lldb] [lldb][DataFormatter] unordered_map: account for new libc++ __hash_node layout (PR #68574)

2023-10-09 Thread Michael Buch via lldb-commits
@@ -162,10 +162,21 @@ lldb::ValueObjectSP lldb_private::formatters:: if (!node_sp || error.Fail()) return nullptr; - value_sp = node_sp->GetChildMemberWithName("__value_"); hash_sp = node_sp->GetChildMemberWithName("__hash_"); - if (!value_sp |

[Lldb-commits] [lldb] [lldb][DataFormatter] unordered_map: account for new libc++ __hash_node layout (PR #68574)

2023-10-09 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/68574 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Add SBType::FindNestedType() function (PR #68705)

2023-10-12 Thread Michael Buch via lldb-commits
Michael137 wrote: > It's not clear to me whether `TypeSystem::DeclContextIsContainedInLookup` > provides such a guarantee. Implementation suggests that it's only interested > in direct `DeclContext`, maybe ignoring transparent decl contexts like inline > namespace it already handles. I hope re

[Lldb-commits] [lldb] [lldb] Add SBType::FindNestedType() function (PR #68705)

2023-10-12 Thread Michael Buch via lldb-commits
@@ -1082,6 +1082,19 @@ bool TypeImpl::GetDescription(lldb_private::Stream &strm, return true; } +CompilerType TypeImpl::FindNestedType(ConstString name) { Michael137 wrote: Should an `empty` name require special treatment? Like we don't support that as a v

[Lldb-commits] [lldb] [lldb] Add SBType::FindNestedType() function (PR #68705)

2023-10-12 Thread Michael Buch via lldb-commits
@@ -119,6 +119,11 @@ def test(self): self.assertEqual(task_type, task_head_pointee_type) +# Check whether we can find a nested type by name +name_type = task_type.FindNestedType("name") Michael137 wrote: Should add tests for enums/uni

[Lldb-commits] [lldb] [lldb] Add SBType::FindNestedType() function (PR #68705)

2023-10-12 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/68705 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Add SBType::FindNestedType() function (PR #68705)

2023-10-12 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/68705 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Add SBType::FindNestedType() function (PR #68705)

2023-10-12 Thread Michael Buch via lldb-commits
@@ -1082,6 +1082,19 @@ bool TypeImpl::GetDescription(lldb_private::Stream &strm, return true; } +CompilerType TypeImpl::FindNestedType(ConstString name) { Michael137 wrote: fwiw, `name.IsValid()` would check for both nullptr and empty string https://github

[Lldb-commits] [lldb] [lldb] Add SBType::FindNestedType() function (PR #68705)

2023-10-12 Thread Michael Buch via lldb-commits
@@ -186,6 +186,11 @@ std::optional TypeSystem::ReportStatistics() { return std::nullopt; } +CompilerDeclContext Michael137 wrote: Could add a brief oxygen docstring saying: "Returns the direct parent context of specified type". Also, what happens if no su

[Lldb-commits] [lldb] [lldb] Add SBType::FindNestedType() function (PR #68705)

2023-10-12 Thread Michael Buch via lldb-commits
@@ -119,6 +119,11 @@ def test(self): self.assertEqual(task_type, task_head_pointee_type) +# Check whether we can find a nested type by name +name_type = task_type.FindNestedType("name") Michael137 wrote: Up to you, though it would be

[Lldb-commits] [lldb] [lldb] Add SBType::FindNestedType() function (PR #68705)

2023-10-12 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/68705 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Add SBType::FindNestedType() function (PR #68705)

2023-10-12 Thread Michael Buch via lldb-commits
@@ -119,6 +119,15 @@ def test(self): self.assertEqual(task_type, task_head_pointee_type) +# Check whether we can find a nested type by name +name_type = task_type.FindNestedType("name") +self.assertTrue(name_type) +self.DebugSBType(name

[Lldb-commits] [lldb] [lldb][DataFormatter] Fix GetNumChildren for VectorType formatter (PR #68907)

2023-10-12 Thread Michael Buch via lldb-commits
https://github.com/Michael137 created https://github.com/llvm/llvm-project/pull/68907 To get the number of children for a VectorType (i.e., a type declared with a `vector_size`/`ext_vector_type` attribute) LLDB previously did following calculation: 1. Get byte-size of the vector container from C

[Lldb-commits] [lldb] [lldb][DataFormatter] VectorType: fix format for arrays with size not a power-of-2 (PR #68907)

2023-10-12 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/68907 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][DataFormatter] VectorType: fix format for arrays with size not a power-of-2 (PR #68907)

2023-10-12 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/68907 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][DataFormatter] VectorType: fix format for arrays with size not a power-of-2 (PR #68907)

2023-10-12 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/68907 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][DataFormatter] VectorType: fix format for arrays with size not a power-of-2 (PR #68907)

2023-10-12 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/68907 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][DataFormatter] VectorType: fix format for arrays with size not a power-of-2 (PR #68907)

2023-10-12 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/68907 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Add SBType::FindNestedType() function (PR #68705)

2023-10-13 Thread Michael Buch via lldb-commits
@@ -119,6 +119,15 @@ def test(self): self.assertEqual(task_type, task_head_pointee_type) +# Check whether we can find a nested type by name +name_type = task_type.FindNestedType("name") +self.assertTrue(name_type) +self.DebugSBType(name

[Lldb-commits] [lldb] [lldb] Add SBType::FindNestedType() function (PR #68705)

2023-10-13 Thread Michael Buch via lldb-commits
@@ -119,6 +119,38 @@ def test(self): self.assertEqual(task_type, task_head_pointee_type) +# Check whether we can find a directly nested type by name +name_type = task_type.FindDirectNestedType("name") +self.assertTrue(name_type) +self.D

[Lldb-commits] [lldb] [lldb] Add SBType::FindNestedType() function (PR #68705)

2023-10-13 Thread Michael Buch via lldb-commits
@@ -8,6 +8,9 @@ class Task { TASK_TYPE_1, TASK_TYPE_2 } type; +enum E : unsigned char {} e; +union U { +} u; Michael137 wrote: Can you move these below that `struct name`. Just so it's closer to Jim's example where if we did a

[Lldb-commits] [lldb] [lldb] Add SBType::FindNestedType() function (PR #68705)

2023-10-13 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/68705 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][test] Temporarily disable TestQueueFromStdModule.py (PR #68970)

2023-10-13 Thread Michael Buch via lldb-commits
https://github.com/Michael137 created https://github.com/llvm/llvm-project/pull/68970 Started failing since D101206, but root-cause is unclear. It's definitely not an issue with th libc++ patch itself however. So disable the test until we know what's going on. >From 88007827eb5d2ffda60a127e66

[Lldb-commits] [lldb] [lldb] Add SBType::FindNestedType() function (PR #68705)

2023-10-13 Thread Michael Buch via lldb-commits
@@ -119,6 +119,38 @@ def test(self): self.assertEqual(task_type, task_head_pointee_type) +# Check whether we can find a directly nested type by name +name_type = task_type.FindDirectNestedType("name") +self.assertTrue(name_type) +self.D

[Lldb-commits] [lldb] [lldb] Add SBType::FindNestedType() function (PR #68705)

2023-10-13 Thread Michael Buch via lldb-commits
https://github.com/Michael137 approved this pull request. LGTM, if @jimingham doesn't have any other comments https://github.com/llvm/llvm-project/pull/68705 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailm

[Lldb-commits] [lldb] [lldb][test] Temporarily disable TestQueueFromStdModule.py (PR #68970)

2023-10-13 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/68970 >From 88007827eb5d2ffda60a127e664c00b921875d04 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 13 Oct 2023 10:46:42 +0100 Subject: [PATCH 1/2] [lldb][test] Temporarily disable TestQueueFromStdModule.py

[Lldb-commits] [lldb] [lldb][DataFormatter] unordered_map: account for new libc++ __hash_node layout (PR #68574)

2023-10-13 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/68574 >From a421f1883e5b3544ec4b2ceb2bba6fac912c3ffb Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Mon, 9 Oct 2023 11:54:56 +0100 Subject: [PATCH 1/2] [lldb][DataFormatter] unordered_map: account for new libc++

[Lldb-commits] [lldb] [lldb][DataFormatter] unordered_map: account for new libc++ __hash_node layout (PR #68574)

2023-10-13 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/68574 >From a421f1883e5b3544ec4b2ceb2bba6fac912c3ffb Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Mon, 9 Oct 2023 11:54:56 +0100 Subject: [PATCH 1/3] [lldb][DataFormatter] unordered_map: account for new libc++

[Lldb-commits] [lldb] [lldb][DataFormatter] unordered_map: account for new libc++ __hash_node layout (PR #68574)

2023-10-13 Thread Michael Buch via lldb-commits
@@ -162,10 +162,21 @@ lldb::ValueObjectSP lldb_private::formatters:: if (!node_sp || error.Fail()) return nullptr; - value_sp = node_sp->GetChildMemberWithName("__value_"); hash_sp = node_sp->GetChildMemberWithName("__hash_"); - if (!value_sp |

[Lldb-commits] [lldb] [lldb][test] Temporarily disable TestQueueFromStdModule.py (PR #68970)

2023-10-13 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/68970 >From 35a9c6ee8fae2281ac7234e16bb84b7b285ad749 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 13 Oct 2023 10:46:42 +0100 Subject: [PATCH 1/2] [lldb][test] Temporarily disable TestQueueFromStdModule.py

[Lldb-commits] [lldb] [lldb][DataFormatter] unordered_map: account for new libc++ __hash_node layout (PR #68574)

2023-10-13 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/68574 >From a421f1883e5b3544ec4b2ceb2bba6fac912c3ffb Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Mon, 9 Oct 2023 11:54:56 +0100 Subject: [PATCH 1/4] [lldb][DataFormatter] unordered_map: account for new libc++

[Lldb-commits] [lldb] [lldb][test] Temporarily disable TestQueueFromStdModule.py (PR #68970)

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

[Lldb-commits] [lldb] [lldb][DataFormatter] VectorType: fix format for arrays with size not a power-of-2 (PR #68907)

2023-10-13 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/68907 >From 769cbd0a30f0903ff4b7263b7789fb28c49de1d6 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Thu, 12 Oct 2023 16:25:39 +0100 Subject: [PATCH 1/4] [lldb][DataFormatter][NFC] VectorType: remove redundant pa

[Lldb-commits] [lldb] [lldb][DataFormatter] VectorType: fix format for arrays with size not a power-of-2 (PR #68907)

2023-10-13 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/68907 >From 769cbd0a30f0903ff4b7263b7789fb28c49de1d6 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Thu, 12 Oct 2023 16:25:39 +0100 Subject: [PATCH 1/5] [lldb][DataFormatter][NFC] VectorType: remove redundant pa

[Lldb-commits] [lldb] [lldb][DataFormatter] VectorType: fix format for arrays with size not a power-of-2 (PR #68907)

2023-10-13 Thread Michael Buch via lldb-commits
@@ -169,21 +169,49 @@ static lldb::Format GetItemFormatForFormat(lldb::Format format, } } -static size_t CalculateNumChildren( -CompilerType container_type, CompilerType element_type, -lldb_private::ExecutionContextScope *exe_scope = -nullptr // does not mat

[Lldb-commits] [lldb] [lldb][DataFormatter] VectorType: fix format for arrays with size not a power-of-2 (PR #68907)

2023-10-13 Thread Michael Buch via lldb-commits
@@ -169,21 +169,49 @@ static lldb::Format GetItemFormatForFormat(lldb::Format format, } } -static size_t CalculateNumChildren( -CompilerType container_type, CompilerType element_type, -lldb_private::ExecutionContextScope *exe_scope = -nullptr // does not mat

[Lldb-commits] [lldb] [lldb][DataFormatter] VectorType: fix format for arrays with size not a power-of-2 (PR #68907)

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

[Lldb-commits] [lldb] [lldb] Add value to enumerator dump (PR #69815)

2023-10-23 Thread Michael Buch via lldb-commits
@@ -74,9 +74,13 @@ def test(self): ) # Test an enum with fixed underlying type. -self.expect_expr("A::scoped_char_enum_val", result_value="case2") -self.expect_expr("A::scoped_ll_enum_val_neg", result_value="case0") -self.expect_expr("A:

[Lldb-commits] [lldb] [lldb] Add value to enumerator dump (PR #69815)

2023-10-23 Thread Michael Buch via lldb-commits
https://github.com/Michael137 deleted https://github.com/llvm/llvm-project/pull/69815 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Add value to enumerator dump (PR #69815)

2023-10-23 Thread Michael Buch via lldb-commits
@@ -23,9 +23,18 @@ def check_enum(self, suffix): substrs=["Case1", "Case2", "Case3"], ) # Test each case in the enum. -self.expect_expr("var1_" + suffix, result_type=enum_name, result_value="Case1") -self.expect_expr("var2_" + suffix

[Lldb-commits] [lldb] Expose DWARFDIE::GetDeclContext() in lldb_private::Function. (PR #69981)

2023-10-23 Thread Michael Buch via lldb-commits
@@ -396,6 +396,17 @@ void Function::GetDescription(Stream *s, lldb::DescriptionLevel level, s->AsRawOstream() << ", name = \"" << name << '"'; if (mangled) s->AsRawOstream() << ", mangled = \"" << mangled << '"'; + if (level == eDescriptionLevelVerbose) { +*s <<

[Lldb-commits] [lldb] Expose DWARFDIE::GetDeclContext() in lldb_private::Function. (PR #69981)

2023-10-23 Thread Michael Buch via lldb-commits
@@ -322,10 +322,12 @@ std::vector parseCompilerContext() { } result.push_back({kind, ConstString{value}}); } - outs() << "Search context: {\n"; - for (auto entry: result) -entry.Dump(); - outs() << "}\n"; + outs() << "Search context: {"; + lldb_private::Strea

[Lldb-commits] [lldb] Expose DWARFDIE::GetDeclContext() in lldb_private::Function. (PR #69981)

2023-10-23 Thread Michael Buch via lldb-commits
@@ -396,6 +396,17 @@ void Function::GetDescription(Stream *s, lldb::DescriptionLevel level, s->AsRawOstream() << ", name = \"" << name << '"'; if (mangled) s->AsRawOstream() << ", mangled = \"" << mangled << '"'; + if (level == eDescriptionLevelVerbose) { +*s <<

[Lldb-commits] [lldb] [lldb][Test] TestDataFormatterLibcxxChrono.py: skip test on older clang versions (PR #70544)

2023-10-28 Thread Michael Buch via lldb-commits
https://github.com/Michael137 created https://github.com/llvm/llvm-project/pull/70544 These tests were failing on the LLDB public matrix build-bots for older clang versions: ``` clang-7: warning: argument unused during compilation: '-nostdlib++' [-Wunused-command-line-argument] error: invalid

[Lldb-commits] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70551)

2023-10-28 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/70551 >From e02939572877cdc839894454a6fab36ab143d924 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 27 Oct 2023 16:33:07 +0100 Subject: [PATCH 1/3] [clang][DebugInfo][NFC] Add createConstantValueExpression

[Lldb-commits] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70551)

2023-10-28 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/70551 >From e02939572877cdc839894454a6fab36ab143d924 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 27 Oct 2023 16:33:07 +0100 Subject: [PATCH 1/4] [clang][DebugInfo][NFC] Add createConstantValueExpression

[Lldb-commits] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-10-30 Thread Michael Buch via lldb-commits
https://github.com/Michael137 created https://github.com/llvm/llvm-project/pull/70639 When an LLDB user asks for the value of a static data member, LLDB starts by searching the Names accelerator table for the corresponding variable definition DIE. For static data members with out-of-class defini

[Lldb-commits] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-10-30 Thread Michael Buch via lldb-commits
Michael137 wrote: Summing the size of all *.o files in my local debug Clang build increased by `0.7%` with this patch https://github.com/llvm/llvm-project/pull/70639 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-

[Lldb-commits] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-10-30 Thread Michael Buch via lldb-commits
https://github.com/Michael137 ready_for_review https://github.com/llvm/llvm-project/pull/70639 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][test] Add FindGlobalVariables tests for C++ constexpr static data members (PR #70641)

2023-10-30 Thread Michael Buch via lldb-commits
https://github.com/Michael137 created https://github.com/llvm/llvm-project/pull/70641 Tests that LLDB can find inline static data members. Relies on the debug-info change in: https://github.com/llvm/llvm-project/pull/70639 >From 7de2335efd85ae6058705a6a6cd9c5b160aef757 Mon Sep 17 00:00:00 200

[Lldb-commits] [lldb] [lldb][test] Add FindGlobalVariables tests for C++ constexpr static data members (PR #70641)

2023-10-30 Thread Michael Buch via lldb-commits
@@ -113,6 +113,37 @@ def test_class_with_only_const_static(self): self.expect_expr("ClassWithOnlyConstStatic::member", result_value="3") +def check_global_var(self, name: str, expect_type, expect_val): +var_list = self.target().FindGlobalVariables(name, ll

[Lldb-commits] [lldb] [lldb][test] Add FindGlobalVariables tests for C++ inline static data members (PR #70641)

2023-10-30 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/70641 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70551)

2023-10-30 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/70551 >From e02939572877cdc839894454a6fab36ab143d924 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 27 Oct 2023 16:33:07 +0100 Subject: [PATCH 1/4] [clang][DebugInfo][NFC] Add createConstantValueExpression

[Lldb-commits] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-10-30 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/70639 >From cbae5425ac00e3cb597827e4b6c402446cc40d9d Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 27 Oct 2023 16:33:07 +0100 Subject: [PATCH 1/3] [clang][DebugInfo][NFC] Add createConstantValueExpression

[Lldb-commits] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-10-30 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/70639 >From cbae5425ac00e3cb597827e4b6c402446cc40d9d Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 27 Oct 2023 16:33:07 +0100 Subject: [PATCH 1/4] [clang][DebugInfo][NFC] Add createConstantValueExpression

[Lldb-commits] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70551)

2023-10-30 Thread Michael Buch via lldb-commits
https://github.com/Michael137 closed https://github.com/llvm/llvm-project/pull/70551 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-10-30 Thread Michael Buch via lldb-commits
Michael137 wrote: This could also help with the type merging issues discussed in https://github.com/llvm/llvm-project/pull/68721#issuecomment-1764685418 https://github.com/llvm/llvm-project/pull/70639 ___ lldb-commits mailing list lldb-commits@lists.l

[Lldb-commits] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-10-30 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/70639 >From 18db082fc5008283f77cc98d9c733a47c63b7096 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 27 Oct 2023 16:19:47 +0100 Subject: [PATCH 1/3] [clang][DebugInfo] Emit global variable definitions for st

[Lldb-commits] [lldb] [lldb][Test] TestDataFormatterLibcxxChrono.py: skip test on older clang versions (PR #70544)

2023-10-30 Thread Michael Buch via lldb-commits
https://github.com/Michael137 closed https://github.com/llvm/llvm-project/pull/70544 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-10-30 Thread Michael Buch via lldb-commits
Michael137 wrote: > > Should not we remove constant initializer from the type definition if we > > have a DW_TAG_variable with a DW_AT_const_value now? > > Yep, +1 to this. This is where the type normalization benefit would come from > - no longer having this const value on the member declarat

[Lldb-commits] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-10-30 Thread Michael Buch via lldb-commits
@@ -0,0 +1,87 @@ +// RUN: %clangxx -target arm64-apple-macosx11.0.0 -g %s -emit-llvm -S -o - | FileCheck --check-prefixes=CHECK %s + +enum class Enum : int { + VAL = -1 +}; + +struct Empty {}; + +constexpr auto func() { return 25; } + +struct Foo { +static constexpr int cexp

[Lldb-commits] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-10-30 Thread Michael Buch via lldb-commits
Michael137 wrote: > I use `bloaty` for this ( https://github.com/google/bloaty ) - though it's a > bit involved to do this to sum over all the object files - summing up the > results from per-object file, etc... ``` bloaty `find ./patched-build/lib -name *.o` │ bloaty `find ./no-patch-

[Lldb-commits] [lldb] [lldb][test] Add FindGlobalVariables tests for C++ inline static data members (PR #70641)

2023-10-31 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/70641 >From 7de2335efd85ae6058705a6a6cd9c5b160aef757 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Sat, 28 Oct 2023 15:24:47 +0100 Subject: [PATCH 1/2] [lldb][test] Add FindGlobalVariables tests for C++ constex

[Lldb-commits] [clang] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-10-31 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/70639 >From 18db082fc5008283f77cc98d9c733a47c63b7096 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 27 Oct 2023 16:19:47 +0100 Subject: [PATCH 1/4] [clang][DebugInfo] Emit global variable definitions for st

[Lldb-commits] [lldb] [clang] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-10-31 Thread Michael Buch via lldb-commits
@@ -67,15 +67,15 @@ int C::a = 4; // CHECK-NOT:size: // CHECK-NOT:align: // CHECK-NOT:offset: -// CHECK-SAME: flags: DIFlagStaticMember, -// CHECK-SAME: extraData: i1 true) +// CHECK-SAME: flags: DIFlagStaticMemb

[Lldb-commits] [lldb] [clang] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-10-31 Thread Michael Buch via lldb-commits
Michael137 wrote: > size report sounds generally OK - but there's a bunch of what look like > unrelated or strange results in there, perhaps they weren't compared at > exactly the same version? (like why did the apple_names size go down? How did > the .text and .debuG_line size change at all?

[Lldb-commits] [lldb] [clang] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-10-31 Thread Michael Buch via lldb-commits
Michael137 wrote: > > Few minor issues, but looks good to me. (you metnioned somewhere an lldb > > issue I think with this patch when the value is removed from the static > > member declaration inside the class? If that's a problem - probably hold > > off on committing this until lldb's been f

[Lldb-commits] [lldb] [clang] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-10-31 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/70639 >From 18db082fc5008283f77cc98d9c733a47c63b7096 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 27 Oct 2023 16:19:47 +0100 Subject: [PATCH 1/7] [clang][DebugInfo] Emit global variable definitions for st

[Lldb-commits] [clang] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-10-31 Thread Michael Buch via lldb-commits
Michael137 wrote: > The DWARFASTParserClang.cpp will try to create the class from the DWARF for > the class definition. You will need to find the DW_TAG_variable when we are > creating the static field if there is no DW_AT_const_value in the > DW_TAG_member. But we also need to support the DW_

[Lldb-commits] [lldb] [LLDB] Don't ignore artificial variables and members for coroutines (PR #70779)

2023-10-31 Thread Michael Buch via lldb-commits
@@ -41,7 +41,10 @@ CPPLanguageRuntime::CPPLanguageRuntime(Process *process) : LanguageRuntime(process) {} bool CPPLanguageRuntime::IsAllowedRuntimeValue(ConstString name) { - return name == g_this; + // FIXME: use a list when the list grows more. + return name == g_this

[Lldb-commits] [lldb] [LLDB] Don't ignore artificial variables and members for coroutines (PR #70779)

2023-10-31 Thread Michael Buch via lldb-commits
@@ -3061,7 +3061,8 @@ void DWARFASTParserClang::ParseSingleMember( // artificial member with (unnamed bitfield) padding. // FIXME: This check should verify that this is indeed an artificial member // we are supposed to ignore. - if (attrs.is_artificial) { + if (attrs.is

[Lldb-commits] [lldb] [lldb][Symtab][NFCI] Replace vector::swap with shrink_to_fit (PR #70918)

2023-11-01 Thread Michael Buch via lldb-commits
https://github.com/Michael137 created https://github.com/llvm/llvm-project/pull/70918 Replaces the old idiom of swapping the container to shrink it with the newer STL alternative. Similar transition in LLDB was done in: https://reviews.llvm.org/D47492 >From 52c5caf0c352fc13377e56367cc6935e3d9

[Lldb-commits] [lldb] [lldb][Symtab][NFCI] Replace vector::swap with shrink_to_fit (PR #70918)

2023-11-01 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/70918 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][Symtab][NFCI] Replace vector::swap with shrink_to_fit (PR #70918)

2023-11-01 Thread Michael Buch via lldb-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/70918 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb][Symtab][NFCI] Replace vector::swap with shrink_to_fit (PR #70918)

2023-11-01 Thread Michael Buch via lldb-commits
https://github.com/Michael137 closed https://github.com/llvm/llvm-project/pull/70918 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [clang] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-11-01 Thread Michael Buch via lldb-commits
Michael137 wrote: Hmmm it seems like for `constexpr static` data members we don't get a symbol in the MachO the same way we do for out-of-line `const static`s that have a location: ``` struct Foo { static const int val1; static constexpr int val2 = 5; };

[Lldb-commits] [lldb] [clang] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-11-01 Thread Michael Buch via lldb-commits
Michael137 wrote: > One question I have here: where will the DW_TAG_variable get emitted for > these `constexpr`? For actual static member variables we emit a single > DW_TAG_variable in the file that declares the global variable, but for > `constexpr` we won't be able to do this will we? Will

[Lldb-commits] [clang] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-11-01 Thread Michael Buch via lldb-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/70639 >From 18db082fc5008283f77cc98d9c733a47c63b7096 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 27 Oct 2023 16:19:47 +0100 Subject: [PATCH 1/8] [clang][DebugInfo] Emit global variable definitions for st

[Lldb-commits] [clang] [lldb] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-11-01 Thread Michael Buch via lldb-commits
Michael137 wrote: > > That's true, if defined in a header, we'll emit a DW_TAG_variable for the > > constant in each compile unit the header is included in. GCC does do the > > right thing and only emit the definition DIE in a single CU. We should > > probably do the same. Though not sure at w

[Lldb-commits] [lldb] [clang] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

2023-11-01 Thread Michael Buch via lldb-commits
Michael137 wrote: > The DWARFASTParserClang, with the current state of things, will automatically > add the const value initializer to the clang AST field. See > `DWARFASTParserClang::ParseSingleMember(...)` around the `// Handle static > members` around > lldb/source/Plugins/SymbolFile/DWARF

[Lldb-commits] [lldb] [DRAFT][lldb][DWARFASTParserClang] Fetch constant value from variable defintion if available (PR #71004)

2023-11-01 Thread Michael Buch via lldb-commits
https://github.com/Michael137 created https://github.com/llvm/llvm-project/pull/71004 This is a **draft** patch that shows how LLDB could continue to support static initialisers even if the declaration didn't have a `DW_AT_const_value` anymore. https://github.com/llvm/llvm-project/pull/70639 p

<    6   7   8   9   10   11   12   13   14   15   >