[clang] [clang][DebugInfo][NFC] Add createConstantValueExpression helper (PR #70674)

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

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

2023-11-06 Thread Michael Buch via cfe-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/70639 >From 81bd54091451eb2021007bc10b8a7c6965178800 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] [clang] [clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (PR #70639)

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

[clang] 333124c - Revert "[clang][DebugInfo] Emit global variable definitions for static data members with constant initializers (#70639)"

2023-11-06 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2023-11-06T10:58:02Z New Revision: 333124cfd6dfa413294e80f9be75460b9a9314f9 URL: https://github.com/llvm/llvm-project/commit/333124cfd6dfa413294e80f9be75460b9a9314f9 DIFF: https://github.com/llvm/llvm-project/commit/333124cfd6dfa413294e80f9be75460b9a9314f9.diff LOG:

[clang] [clang][DebugInfo] Attach DW_AT_const_value to static data-member definitions if available (PR #72730)

2023-11-27 Thread Michael Buch via cfe-commits
Michael137 wrote: > @Michael137 is this patch ready to land? We (I have took over the bug from > @ilovepi ) have a few builders that are currently blocked by the behavior > change introduced in PR #70639 . It would be great if this change can be > landed timely. Thx. Nope this isn't ready yet

[clang] [clang][DebugInfo] Attach DW_AT_const_value to static data-member definitions if available (PR #72730)

2023-11-27 Thread Michael Buch via cfe-commits
Michael137 wrote: > Would confuse `DwarfDebug` without your changes/this patch? Or only with this > patch? (& hopefully there's some way to reach the merge globals > functionality/problem/interesting IR from clang itself - but I guess even if > it isn't, this is still a demonstration of repres

[clang] [lldb] Reland "[clang][DebugInfo] Emit global variable definitions for static data members with constant initializers" (PR #71780)

2023-11-27 Thread Michael Buch via cfe-commits
Michael137 wrote: > Can we add back the constant to the declaration? It's been a week and the > progress on #72730 seems to have stalled while our builders are still broken. Yup will do, apologies for the noise https://github.com/llvm/llvm-project/pull/71780 ___

[clang] [clang][DebugInfo] Revert to attaching DW_AT_const_value on static member declarations (PR #73626)

2023-11-28 Thread Michael Buch via cfe-commits
https://github.com/Michael137 created https://github.com/llvm/llvm-project/pull/73626 In #71780 we started emitting definitions for all static data-members with constant initialisers, even if they were constants (i.e., didn't have a location). We also dropped the DW_AT_const_value from the dec

[clang] [clang][DebugInfo] Revert to attaching DW_AT_const_value on static member declarations (PR #73626)

2023-11-28 Thread Michael Buch via cfe-commits
Michael137 wrote: FYI @petrhosek https://github.com/llvm/llvm-project/pull/73626 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][DebugInfo] Revert to attaching DW_AT_const_value on static member declarations (PR #73626)

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

[clang] [clang][DebugInfo] Revert to attaching DW_AT_const_value on static member declarations (PR #73626)

2023-11-28 Thread Michael Buch via cfe-commits
Michael137 wrote: I do wonder how feasible it would be for the downstream tests to be adjusted to look at the `DW_AT_location`.. https://github.com/llvm/llvm-project/pull/73626 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm

[clang] [clang][DebugInfo] Revert to attaching DW_AT_const_value on static member declarations (PR #73626)

2023-11-28 Thread Michael Buch via cfe-commits
Michael137 wrote: > > I do wonder how feasible it would be for the downstream tests to be > > adjusted to look at the `DW_AT_location`.. > > As I mentioned on the other thread, the point is not to have to read the > value from the process-under-debug. This is not efficient in a > remote-debug

[clang] [clang][DebugInfo] Revert to attaching DW_AT_const_value on static member declarations (PR #73626)

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

[clang] [clang][DebugInfo] Revert to attaching DW_AT_const_value on static member declarations (PR #73626)

2023-11-28 Thread Michael Buch via cfe-commits
Michael137 wrote: Looks like LLDB linux buildbot isn't happy, checking... https://github.com/llvm/llvm-project/pull/73626 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][DebugInfo] Revert to attaching DW_AT_const_value on static member declarations (PR #73626)

2023-11-28 Thread Michael Buch via cfe-commits
Michael137 wrote: > Looks like LLDB linux buildbot isn't happy, checking... Fix in https://github.com/llvm/llvm-project/pull/73707 https://github.com/llvm/llvm-project/pull/73626 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.l

[clang-tools-extra] [llvm] [clang] [clang][DebugInfo] Improve heuristic to determine whether to evaluate a static variable's initializer (PR #72974)

2023-11-30 Thread Michael Buch via cfe-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/72974 >From 012096290352438668d8f4bb7a97179952a87a3a Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Sat, 18 Nov 2023 00:20:05 + Subject: [PATCH] [clang][DebugInfo] Create evaluateConstantInitializer helper f

[clang-tools-extra] [llvm] [clang] [clang][DebugInfo] Improve heuristic to determine whether to evaluate a static variable's initializer (PR #72974)

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

[clang-tools-extra] [clang] [llvm] [clang][DebugInfo] Improve heuristic to determine whether to evaluate a static variable's initializer (PR #72974)

2023-11-30 Thread Michael Buch via cfe-commits
Michael137 wrote: Test fix in flight... https://github.com/llvm/llvm-project/pull/72974 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] c80b91b - [clang][DebugInfo][test] Remove unchecked member variable in debug-info-static-inline-member

2023-11-30 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2023-11-30T11:13:36Z New Revision: c80b91bce3a5a92281ad1c7e090ac25e7a5bd395 URL: https://github.com/llvm/llvm-project/commit/c80b91bce3a5a92281ad1c7e090ac25e7a5bd395 DIFF: https://github.com/llvm/llvm-project/commit/c80b91bce3a5a92281ad1c7e090ac25e7a5bd395.diff LOG:

[clang] [clang][DebugInfo] DWARFv5: static data members declarations are DW_TAG_variable (PR #72235)

2024-01-03 Thread Michael Buch via cfe-commits
Michael137 wrote: > Should've mentioned this earlier, but we've been seeing crashes in lldb due > to this change (though possibly related to our use of GALA python/gdb interop > https://github.com/sivachandra/gala - we haven't isolated the failures from > that yet (though we've been using it f

[clang] [clang][DebugInfo] DWARFv5: static data members declarations are DW_TAG_variable (PR #72235)

2024-01-03 Thread Michael Buch via cfe-commits
Michael137 wrote: > Yeah, that seems to do it: > > ``` > > struct t1 { > > t1(); > > static int i; > > }; > > int t1::i = 43; > > int main() { > > } > > ``` > > ``` > > $ clang++-tot -gsplit-dwarf -g test.cpp > > $ lldb ./a.out -o "b main" -o "run" -o "p t1::i" -batch > > This is

[clang] [clang][DebugInfo] DWARFv5: static data members declarations are DW_TAG_variable (PR #72235)

2024-01-04 Thread Michael Buch via cfe-commits
Michael137 wrote: Ah looks like in `GetClangDeclForDIE`, when trying to parse the `DW_AT_specification` that the CU-level `DW_TAG_variable` points to, we now try to `CreateVariableDeclaration`, because the static member is a `DW_TAG_variable` too. Whereas previously we would just fall-through

[clang] [clang][ASTImporter] Only reorder fields of RecordDecls (PR #77079)

2024-01-05 Thread Michael Buch via cfe-commits
https://github.com/Michael137 created https://github.com/llvm/llvm-project/pull/77079 Prior to `e9536698720ec524cc8b72599363622bc1a31558` (https://reviews.llvm.org/D154764) we only re-ordered the fields of `RecordDecl`s. The change refactored this logic to make sure `FieldDecl`s are imported

[clang] [clang][ASTImporter] Only reorder fields of RecordDecls (PR #77079)

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

[clang] [clang][ASTImporter] Only reorder fields of RecordDecls (PR #77079)

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

[clang] [clang][ASTImporter] Only reorder fields of RecordDecls (PR #77079)

2024-01-05 Thread Michael Buch via cfe-commits
Michael137 wrote: Need to sort out some test failures https://github.com/llvm/llvm-project/pull/77079 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][ASTImporter] Only reorder fields of RecordDecls (PR #77079)

2024-01-05 Thread Michael Buch via cfe-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/77079 >From 544e2b12695fa572b08abc8efdceeadd63ebbde5 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 5 Jan 2024 10:41:55 + Subject: [PATCH 1/2] [clang][ASTImporter] Only reorder fields of RecordDecls Pri

[clang] [clang][ASTImporter] Only reorder fields of RecordDecls (PR #77079)

2024-01-05 Thread Michael Buch via cfe-commits
Michael137 wrote: > I can not check what caused exactly the problems but the change looks correct > and in change D154764 there seems to be no reason for re-ordering at > non-record objects. As an improvement, some tests could be added that check > for re-ordering at `RecordDecl` and (this is

[clang] [clang][ASTImporter] Only reorder fields of RecordDecls (PR #77079)

2024-01-05 Thread Michael Buch via cfe-commits
Michael137 wrote: I guess if there's some other type of ObjC decl that could trigger the re-ordering that would be useful. https://github.com/llvm/llvm-project/pull/77079 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/c

[clang] [clang][DebugInfo] DWARFv5: static data members declarations are DW_TAG_variable (PR #72235)

2024-01-05 Thread Michael Buch via cfe-commits
Michael137 wrote: > Yes, in the totally reduced reproducer - another debugger might be able to do > this name lookup with only a declaration, but I understand that at least > Clang's AST expression evaluator wouldn't be able to handle this case. > (though perhaps the lldb-eval work will provid

[clang] [clang][DebugInfo] DWARFv5: static data members declarations are DW_TAG_variable (PR #72235)

2024-01-05 Thread Michael Buch via cfe-commits
Michael137 wrote: Proposed fix: https://github.com/llvm/llvm-project/pull/77155 https://github.com/llvm/llvm-project/pull/72235 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][ASTImporter] Only reorder fields of RecordDecls (PR #77079)

2024-01-08 Thread Michael Buch via cfe-commits
Michael137 wrote: Tried to find a way to test "objective-c fields aren't reordered". After talking to some objective-c experts, there doesn't seem to be a good way to force such "incorrect field order", because it's strictly an in-order language. Reducing the LLDB crashes has been tricky becau

[clang] [clang][ASTImporter] Only reorder fields of RecordDecls (PR #77079)

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

[clang] [clang][DebugInfo] DWARFv5: static data members declarations are DW_TAG_variable (PR #72235)

2024-01-08 Thread Michael Buch via cfe-commits
Michael137 wrote: @dwblaikie merged the fix, let me know if you're still seeing problems https://github.com/llvm/llvm-project/pull/72235 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][ASTImporter] fix assert fail due to offset overflow (PR #79084)

2024-02-12 Thread Michael Buch via cfe-commits
@@ -9896,9 +9903,13 @@ Expected ASTImporter::Import(FileID FromID, bool IsBuiltin) { // FIXME: The filename may be a virtual name that does probably not // point to a valid file and we get no Entry here. In this case try with // the memory buffer below

[clang] [clang][ASTImporter] fix assert fail due to offset overflow (PR #79084)

2024-02-12 Thread Michael Buch via cfe-commits
@@ -9896,9 +9903,13 @@ Expected ASTImporter::Import(FileID FromID, bool IsBuiltin) { // FIXME: The filename may be a virtual name that does probably not // point to a valid file and we get no Entry here. In this case try with // the memory buffer below

[clang] [clang][CodeCompletion] Allow debuggers to code-complete reserved identifiers (PR #84891)

2024-03-12 Thread Michael Buch via cfe-commits
https://github.com/Michael137 created https://github.com/llvm/llvm-project/pull/84891 It is not uncommon for LLDB users to dig into internal implementation details of system types (including the STL). LLDB's expression evaluator makes use of Clang's code-completion facilities but currently res

[clang] [clang][CodeCompletion] Allow debuggers to code-complete reserved identifiers (PR #84891)

2024-03-12 Thread Michael Buch via cfe-commits
https://github.com/Michael137 closed https://github.com/llvm/llvm-project/pull/84891 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[lldb] [clang] [clang-tools-extra] [llvm] [lldb][test] Add tests for target.max-string-summary-length setting (PR #77920)

2024-01-12 Thread Michael Buch via cfe-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/77920 >From 4de3716b55a22dc8b7dda621889089f390026739 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 12 Jan 2024 12:34:16 + Subject: [PATCH 1/2] [lldb][test] Add tests for target.max-string-summary-lengt

[clang] [llvm] [clang-tools-extra] [lldb] [lldb][test] Add tests for target.max-string-summary-length setting (PR #77920)

2024-01-12 Thread Michael Buch via cfe-commits
https://github.com/Michael137 closed https://github.com/llvm/llvm-project/pull/77920 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] e456d2b - [clang][ASTImporter] DeclContext::localUncachedLookup: Continue lookup into decl chain when regular lookup fails

2022-09-16 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2022-09-16T12:38:50-04:00 New Revision: e456d2ba8bcadaa63386b339a4f2abcb39505502 URL: https://github.com/llvm/llvm-project/commit/e456d2ba8bcadaa63386b339a4f2abcb39505502 DIFF: https://github.com/llvm/llvm-project/commit/e456d2ba8bcadaa63386b339a4f2abcb39505502.diff

[clang] 798494e - [clang][TypePrinter] Support expression template arguments when checking defaultedness

2023-01-26 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2023-01-27T02:24:32Z New Revision: 798494ed4f112bf64dcabbe8b60becb42b23208f URL: https://github.com/llvm/llvm-project/commit/798494ed4f112bf64dcabbe8b60becb42b23208f DIFF: https://github.com/llvm/llvm-project/commit/798494ed4f112bf64dcabbe8b60becb42b23208f.diff LOG:

[clang] 8b4279b - [clang][TemplateBase] Add IsDefaulted bit to TemplateArgument

2023-01-26 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2023-01-27T02:24:33Z New Revision: 8b4279b66fc2f535184642b739b573ead1733711 URL: https://github.com/llvm/llvm-project/commit/8b4279b66fc2f535184642b739b573ead1733711 DIFF: https://github.com/llvm/llvm-project/commit/8b4279b66fc2f535184642b739b573ead1733711.diff LOG:

[clang] 3d7dcec - [clang][TypePrinter] Test TemplateArgument::IsDefaulted when omitting default arguments

2023-01-26 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2023-01-27T02:24:33Z New Revision: 3d7dcec5db2f86bd8b9142d180716725a8fc0b0f URL: https://github.com/llvm/llvm-project/commit/3d7dcec5db2f86bd8b9142d180716725a8fc0b0f DIFF: https://github.com/llvm/llvm-project/commit/3d7dcec5db2f86bd8b9142d180716725a8fc0b0f.diff LOG:

[clang] 29ecf0e - [clang][DebugInfo] Check TemplateArgument::IsDefaulted

2023-01-26 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2023-01-27T02:24:34Z New Revision: 29ecf0e62cd7899dee84732a31875179ec4d5a80 URL: https://github.com/llvm/llvm-project/commit/29ecf0e62cd7899dee84732a31875179ec4d5a80 DIFF: https://github.com/llvm/llvm-project/commit/29ecf0e62cd7899dee84732a31875179ec4d5a80.diff LOG:

[clang] d194d81 - [clang][ASTImporter] Propagate TemplateArgument::IsDefaulted during import

2023-01-27 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2023-01-27T16:39:17Z New Revision: d194d817b0b29c6e244d01cf7b836b9e4bbe2794 URL: https://github.com/llvm/llvm-project/commit/d194d817b0b29c6e244d01cf7b836b9e4bbe2794 DIFF: https://github.com/llvm/llvm-project/commit/d194d817b0b29c6e244d01cf7b836b9e4bbe2794.diff LOG:

[clang] bee8860 - [clang][DebugInfo] Don't canonicalize names in template argument list for alias templates

2023-01-23 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2023-01-23T09:43:17Z New Revision: bee8860525acbfe33f5b32870ad5e13de07fa6ff URL: https://github.com/llvm/llvm-project/commit/bee8860525acbfe33f5b32870ad5e13de07fa6ff DIFF: https://github.com/llvm/llvm-project/commit/bee8860525acbfe33f5b32870ad5e13de07fa6ff.diff LOG:

[clang] [libc++] Add a CI job for the LLDB data formatters (PR #65174)

2023-10-12 Thread Michael Buch via cfe-commits
@@ -574,6 +574,20 @@ benchmarks) generate-cmake check-cxx-benchmarks ;; +check-lldb-data-formatters) +clean +${CMAKE}\ +-S "${MONOREPO_ROOT}/llvm" \ +-B "${BUILD_DIR}"

[clang-tools-extra] [libc++] Add a CI job for the LLDB data formatters (PR #65174)

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

[clang] [libc++] Add a CI job for the LLDB data formatters (PR #65174)

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

[clang] c146df9 - [clang][DebugInfo] Emit DW_AT_deleted on any deleted member function

2023-06-20 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2023-06-20T09:19:19+01:00 New Revision: c146df9618764d5548c38ce61edc45147094b26f URL: https://github.com/llvm/llvm-project/commit/c146df9618764d5548c38ce61edc45147094b26f DIFF: https://github.com/llvm/llvm-project/commit/c146df9618764d5548c38ce61edc45147094b26f.diff

[clang] 711a644 - [clang][DebugInfo] Emit DW_AT_type of preferred name if available

2023-04-06 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2023-04-07T01:37:36+01:00 New Revision: 711a64412749ae73709562b591ab1609a3ee7751 URL: https://github.com/llvm/llvm-project/commit/711a64412749ae73709562b591ab1609a3ee7751 DIFF: https://github.com/llvm/llvm-project/commit/711a64412749ae73709562b591ab1609a3ee7751.diff

[clang] 5996ce1 - [clang][DebugInfo] Attach DW_AT_default_value to template arg metadata regardless of DwarfVersion

2022-12-14 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2022-12-14T22:31:45Z New Revision: 5996ce17fb265e461b5d580c1873cb8e3ff8d62d URL: https://github.com/llvm/llvm-project/commit/5996ce17fb265e461b5d580c1873cb8e3ff8d62d DIFF: https://github.com/llvm/llvm-project/commit/5996ce17fb265e461b5d580c1873cb8e3ff8d62d.diff LOG:

[clang] c9861e5 - [llvm][DebugInfo] Backport DW_AT_default_value for template args

2022-12-14 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2022-12-14T22:31:46Z New Revision: c9861e5718f6352bb1ee9fe6b5c3e16a0e649360 URL: https://github.com/llvm/llvm-project/commit/c9861e5718f6352bb1ee9fe6b5c3e16a0e649360 DIFF: https://github.com/llvm/llvm-project/commit/c9861e5718f6352bb1ee9fe6b5c3e16a0e649360.diff LOG:

[clang] 738bfbc - [llvm][test] Split DW_AT_default_value check out of clang/test/

2022-12-14 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2022-12-15T02:57:08Z New Revision: 738bfbce09e700124dbcea55b2cfe7f499250b9c URL: https://github.com/llvm/llvm-project/commit/738bfbce09e700124dbcea55b2cfe7f499250b9c DIFF: https://github.com/llvm/llvm-project/commit/738bfbce09e700124dbcea55b2cfe7f499250b9c.diff LOG:

[clang] 98afcba - [clang][AST][NFC] Expose clang::isSubstitutedDefaultArgument to clang/AST consumers

2022-12-16 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2022-12-16T11:38:50Z New Revision: 98afcbab66505661045dccb85ee9acdbf9410047 URL: https://github.com/llvm/llvm-project/commit/98afcbab66505661045dccb85ee9acdbf9410047 DIFF: https://github.com/llvm/llvm-project/commit/98afcbab66505661045dccb85ee9acdbf9410047.diff LOG:

[clang] 1706f34 - [clang][TypePrinter] Teach isSubstitutedDefaultArgument about integral types

2022-12-16 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2022-12-16T11:38:51Z New Revision: 1706f34d604ec304af58a7b95dbc127bd77e17fa URL: https://github.com/llvm/llvm-project/commit/1706f34d604ec304af58a7b95dbc127bd77e17fa DIFF: https://github.com/llvm/llvm-project/commit/1706f34d604ec304af58a7b95dbc127bd77e17fa.diff LOG:

[clang] 8d3843b - [clang][DebugInfo] Simplify logic to determine DW_AT_default_value for template parameters

2022-12-16 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2022-12-16T11:38:52Z New Revision: 8d3843badb8a32a56531e383a2a9eb5b07ae8b0d URL: https://github.com/llvm/llvm-project/commit/8d3843badb8a32a56531e383a2a9eb5b07ae8b0d DIFF: https://github.com/llvm/llvm-project/commit/8d3843badb8a32a56531e383a2a9eb5b07ae8b0d.diff LOG:

[clang] 2c22cfd - [clang][DebugInfo] Add DW_AT_default_value support for template template parameters

2022-12-16 Thread Michael Buch via cfe-commits
Author: Michael Buch Date: 2022-12-16T11:38:54Z New Revision: 2c22cfd4c95606adec311dece051e95e86e3f0f3 URL: https://github.com/llvm/llvm-project/commit/2c22cfd4c95606adec311dece051e95e86e3f0f3 DIFF: https://github.com/llvm/llvm-project/commit/2c22cfd4c95606adec311dece051e95e86e3f0f3.diff LOG:

[clang] [clang][CGRecordLayout] Remove dependency on isZeroSize (PR #96422)

2024-07-01 Thread Michael Buch via cfe-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/96422 >From 419af1b1db2bef88c5145276ffd24ed93bcb15a5 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 21 Jun 2024 12:15:07 +0100 Subject: [PATCH 1/7] [clang][CGRecordLayout] Remove dependency on isZeroSize Th

[clang] [lldb] [clang][RecordLayoutBuilder] Be stricter about inferring packed-ness in ExternalLayouts (PR #97443)

2024-07-02 Thread Michael Buch via cfe-commits
https://github.com/Michael137 created https://github.com/llvm/llvm-project/pull/97443 This patch is motivated by the LLDB support required for: https://github.com/llvm/llvm-project/issues/93069 In the presence of `[[no_unique_address]]`, LLDB may ask Clang to lay out types with overlapping fi

[clang] [lldb] [clang][RecordLayoutBuilder] Be stricter about inferring packed-ness in ExternalLayouts (PR #97443)

2024-07-02 Thread Michael Buch via cfe-commits
@@ -2250,14 +2246,18 @@ void ItaniumRecordLayoutBuilder::UpdateAlignment( } } -uint64_t -ItaniumRecordLayoutBuilder::updateExternalFieldOffset(const FieldDecl *Field, - uint64_t ComputedOffset) { +uint64_t ItaniumRecordLa

[clang] [lldb] [clang][RecordLayoutBuilder] Be stricter about inferring packed-ness in ExternalLayouts (PR #97443)

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

[clang] [clang][CGRecordLayout] Remove dependency on isZeroSize (PR #96422)

2024-07-05 Thread Michael Buch via cfe-commits
Michael137 wrote: Had to adjust `isEmptyFieldForLayout`/`isEmptyRecordForLayout` because `isEmptyField`/`isEmptyRecord` would call each other recursively, so dispatching from `isEmptyFieldForLayout` wouldn't have been correct (since the `isEmptyField`/`isEmptyRecord` have extra checks for unna

[clang] [clang][CGRecordLayout] Remove dependency on isZeroSize (PR #96422)

2024-07-05 Thread Michael Buch via cfe-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/96422 >From 7fb44b1cd3ffac0a0f509cefa3a141dac50da142 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 21 Jun 2024 12:15:07 +0100 Subject: [PATCH 1/8] [clang][CGRecordLayout] Remove dependency on isZeroSize Th

[clang] [lldb] [ASTImporter][lldb] Avoid implicit imports in VisitFieldDecl (PR #107828)

2024-09-09 Thread Michael Buch via cfe-commits
Michael137 wrote: Thanks for taking a stab at this and for the analysis. You rightly point out that this is the root problem: > If an implicit import happens between (2) and (3), it may indirectly bring > the same field into the context. When (3) happens we add it again, > duplicating the f

[clang] [lldb] [ASTImporter][lldb] Avoid implicit imports in VisitFieldDecl (PR #107828)

2024-09-10 Thread Michael Buch via cfe-commits
Michael137 wrote: > As I understand it, minimal import is used in LLDB for performance reasons, > so we don't waste time parsing and loading AST elements that we don't need. > It sounds like a fine idea in general. Implicit imports of external sources > in Clang, however, turn import process i

[clang] [clang][DebugInfo] Don't mark structured bindings as artificial (PR #100355)

2024-08-08 Thread Michael Buch via cfe-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/100355 >From 2b1255de05856e4c79f58d3e4071384ba80a881d Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Thu, 18 Jul 2024 16:26:16 -0500 Subject: [PATCH 1/3] [clang][Sema] Don't mark VarDecls of bindings in tuple-li

[clang] [clang][DebugInfo] Don't mark structured bindings as artificial (PR #100355)

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

[clang] [llvm] [Clang] Emit DW_TAG_template_alias for template aliases (PR #87623)

2024-04-11 Thread Michael Buch via cfe-commits
@@ -1,4 +1,4 @@ -// RUN: %clang -g -std=c++11 -S -emit-llvm %s -o - | FileCheck %s +// RUN: %clang -ggdb -std=c++11 -S -emit-llvm %s -o - | FileCheck %s Michael137 wrote: Do we now lose a tiny bit of coverage for `-glldb`? I assume this change is to make sure th

[clang] [llvm] [Clang] Emit DW_TAG_template_alias for template aliases (PR #87623)

2024-04-11 Thread Michael Buch via cfe-commits
@@ -5361,7 +5383,56 @@ static bool IsReconstitutableType(QualType QT) { return T.Reconstitutable; } -std::string CGDebugInfo::GetName(const Decl *D, bool Qualified) const { +bool CGDebugInfo::HasReconstitutableArgs( +ArrayRef Args) const { + return llvm::all_of(Args, [&

[clang] [PAC][clang] Define `PointerAuthQualifier` and `PointerAuthenticationMode` (PR #84384)

2024-04-12 Thread Michael Buch via cfe-commits
@@ -251,15 +423,16 @@ class Qualifiers { } // Deserialize qualifiers from an opaque representation. - static Qualifiers fromOpaqueValue(unsigned opaque) { + static Qualifiers fromOpaqueValue(uint64_t Opaque) { Qualifiers Qs; -Qs.Mask = opaque; +Qs.Mask = uin

[clang] [PAC][clang] Define `PointerAuthQualifier` and `PointerAuthenticationMode` (PR #84384)

2024-04-12 Thread Michael Buch via cfe-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/84384 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [PAC][clang] Define `PointerAuthQualifier` and `PointerAuthenticationMode` (PR #84384)

2024-04-12 Thread Michael Buch via cfe-commits
Michael137 wrote: LGTM, but would like @rjmccall or @AaronBallman (or another code-owner) to give final approval https://github.com/llvm/llvm-project/pull/84384 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mai

[clang] [llvm] Enable LLDB tests in Linux pre-merge CI (PR #94208)

2024-06-07 Thread Michael Buch via cfe-commits
Michael137 wrote: > Given the libc++ experience, let's move forward with this PR as-is. If > there's an issue in practice, we'll disable the tests on changes to Clang at > that point. Do note that libc++ CI only runs a subset of the LLDB tests. Only the ones that are impacted by libc++. We co

[clang] [lldb] [clang][lldb] Don't assert structure layout correctness for layouts provided by LLDB (PR #93809)

2024-06-17 Thread Michael Buch via cfe-commits
Michael137 wrote: > > > The correct answer here is probably to fix the sizes in the RecordLayout > > > itself; in particular, the DataSize of the members. > > > > > > That would be ideal, but also means we'd have to reflect the various C++ > > attributes that affect layout in DWARF. Avoiding

[clang] [lldb] [clang][lldb] Don't assert structure layout correctness for layouts provided by LLDB (PR #93809)

2024-06-17 Thread Michael Buch via cfe-commits
Michael137 wrote: Yea the problem with checking the size reported by the AST layout vs. the LLVM type layout is that in DWARF we get following representation: ``` // main.cpp struct A { long c, d; }; struct B { [[no_unique_address]] Empty x; }; struct C { [[no_unique_address]] Empty x; }

[clang] [lldb] [clang][lldb] Don't assert structure layout correctness for layouts provided by LLDB (PR #93809)

2024-06-19 Thread Michael Buch via cfe-commits
Michael137 wrote: Ah got it, thanks for clarifying. > so we could instead just check if the field is empty. Couldn't find an existing API for this on `FieldDecl`. Here "empty" would be "field is of a type which is empty"? Which might still cause complications because a `CXXRecordDecl::isEmpty

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-06-21 Thread Michael Buch via cfe-commits
@@ -27,6 +27,9 @@ namespace llvm { } } +// Prefix for __builtin_verbose_trap. +#define CLANG_VERBOSE_TRAP_PREFIX "__llvm_verbose_trap" Michael137 wrote: Not a big deal for LLDB either way, whatever people prefer here, we can work around it. https://github

[clang] [compiler-rt] [lldb] [llvm] [Support] Remove terminfo dependency (PR #92865)

2024-05-29 Thread Michael Buch via cfe-commits
Michael137 wrote: I'm going to revert this for now until since the bots have been red for a while now https://github.com/llvm/llvm-project/pull/92865 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listin

[clang] [lldb] [clang][lldb] Don't assert structure layout correctness for layouts provided by LLDB (PR #93809)

2024-05-30 Thread Michael Buch via cfe-commits
https://github.com/Michael137 created https://github.com/llvm/llvm-project/pull/93809 This is the outcome of the discussions we had in https://discourse.llvm.org/t/rfc-lldb-handling-no-unique-address-in-lldb/77483 To summarize, LLDB creates AST nodes by parsing debug-info and hands those off t

[clang] [lldb] [clang][lldb] Don't assert structure layout correctness for layouts provided by LLDB (PR #93809)

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

[clang] [lldb] [clang][lldb] Don't assert structure layout correctness for layouts provided by LLDB (PR #93809)

2024-05-30 Thread Michael Buch via cfe-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/93809 >From 91276f5b2dc05032a285b465c0c8a69541bb25c4 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Thu, 2 May 2024 09:05:01 +0100 Subject: [PATCH 1/2] [clang][lldb] Don't assert structure layout correctness for

[clang] [lldb] [clang][lldb] Don't assert structure layout correctness for layouts provided by LLDB (PR #93809)

2024-05-30 Thread Michael Buch via cfe-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/93809 >From 91276f5b2dc05032a285b465c0c8a69541bb25c4 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Thu, 2 May 2024 09:05:01 +0100 Subject: [PATCH 1/3] [clang][lldb] Don't assert structure layout correctness for

[clang] [lldb] [clang][lldb] Don't assert structure layout correctness for layouts provided by LLDB (PR #93809)

2024-05-31 Thread Michael Buch via cfe-commits
Michael137 wrote: > The correct answer here is probably to fix the sizes in the RecordLayout > itself; in particular, the DataSize of the members. That would be ideal, but also means we'd have to reflect the various C++ attributes that affect layout in DWARF. Avoiding adding such language-spec

[clang] [llvm] Enable LLDB tests in pre-merge CI (PR #94208)

2024-06-03 Thread Michael Buch via cfe-commits
Michael137 wrote: Worth a shot i guess. Though it could be somewhat disruptive if we do in fact have flaky tests. I don't think we need to run *all* tests. Should we just run the tests for the LLDB C++ language plugin (i.e., the part of LLDB that invokes Clang and the JIT). And then we could e

[clang] [serialization] no transitive decl change (PR #92083)

2024-06-03 Thread Michael Buch via cfe-commits
Michael137 wrote: I.e., also broke the macOS LLDB buildbots: https://green.lab.llvm.org/job/llvm.org/view/LLDB/job/lldb-cmake/2637/execution/node/97/log/ ``` Assertion failed: (!((*IDAddress) >> 48) && "We should only set the module ID once"), function setOwningModuleID, file DeclBase.cpp, lin

[clang] [llvm] Enable LLDB tests in pre-merge CI (PR #94208)

2024-06-03 Thread Michael Buch via cfe-commits
Michael137 wrote: > > Should we just run the tests for the LLDB C++ language plugin (i.e., the > > part of LLDB that invokes Clang and the JIT). And then we could expand the > > set of tests from there later? > > In the bash script that currently handles this, "targets that we need to > check

[clang] [llvm] Enable LLDB tests in pre-merge CI (PR #94208)

2024-06-03 Thread Michael Buch via cfe-commits
Michael137 wrote: > @Michael137 This is for Linux. Windows works the same way just below those > lines: > > https://github.com/llvm/llvm-project/blob/9a7bd8a60f03595be5d42315790df6d409f81091/.ci/generate-buildkite-pipeline-premerge#L253-L255 Ah, so what would the issue be with just adding more

[clang] [serialization] no transitive decl change (PR #92083)

2024-06-04 Thread Michael Buch via cfe-commits
Michael137 wrote: Unfortunately this is still failing one test on the macOS CI: https://green.lab.llvm.org/job/llvm.org/view/LLDB/job/as-lldb-cmake/5083/execution/node/97/log ``` == FAIL: test_duplicate_decls_gmodules (TestTem

[clang] [serialization] no transitive decl change (PR #92083)

2024-06-04 Thread Michael Buch via cfe-commits
Michael137 wrote: > Oh, this is not wanted. It should be almost a NFC patch for users. I'll > revert it. Thanks! https://github.com/llvm/llvm-project/pull/92083 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/ma

[clang] [llvm] [Clang] Emit DW_TAG_template_alias for template aliases (PR #87623)

2024-04-15 Thread Michael Buch via cfe-commits
@@ -5361,7 +5383,56 @@ static bool IsReconstitutableType(QualType QT) { return T.Reconstitutable; } -std::string CGDebugInfo::GetName(const Decl *D, bool Qualified) const { +bool CGDebugInfo::HasReconstitutableArgs( +ArrayRef Args) const { + return llvm::all_of(Args, [&

[clang] [llvm] [Clang] Emit DW_TAG_template_alias for template aliases (PR #87623)

2024-04-16 Thread Michael Buch via cfe-commits
@@ -1332,6 +1332,54 @@ llvm::DIType *CGDebugInfo::CreateType(const TemplateSpecializationType *Ty, auto PP = getPrintingPolicy(); Ty->getTemplateName().print(OS, PP, TemplateName::Qualified::None); + SourceLocation Loc = AliasDecl->getLocation(); + + if (CGM.getCodeGenO

[clang] [llvm] [Clang] Emit DW_TAG_template_alias for template aliases (PR #87623)

2024-04-16 Thread Michael Buch via cfe-commits
Michael137 wrote: Btw, as a follow-up to this patch should we check that this is compatible with dsymutil (i.e., running `dsymutil --verify`)? I suspect it might need a fixup (given LLDB doesn't even support this tag) https://github.com/llvm/llvm-project/pull/87623

[clang] [llvm] [Clang] Emit DW_TAG_template_alias for template aliases (PR #87623)

2024-04-17 Thread Michael Buch via cfe-commits
@@ -1332,6 +1332,54 @@ llvm::DIType *CGDebugInfo::CreateType(const TemplateSpecializationType *Ty, auto PP = getPrintingPolicy(); Ty->getTemplateName().print(OS, PP, TemplateName::Qualified::None); + SourceLocation Loc = AliasDecl->getLocation(); + + if (CGM.getCodeGenO

[clang] [llvm] [Clang] Emit DW_TAG_template_alias for template aliases (PR #87623)

2024-04-17 Thread Michael Buch via cfe-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/87623 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Clang] Emit DW_TAG_template_alias for template aliases (PR #87623)

2024-04-17 Thread Michael Buch via cfe-commits
@@ -1332,6 +1332,54 @@ llvm::DIType *CGDebugInfo::CreateType(const TemplateSpecializationType *Ty, auto PP = getPrintingPolicy(); Ty->getTemplateName().print(OS, PP, TemplateName::Qualified::None); + SourceLocation Loc = AliasDecl->getLocation(); + + if (CGM.getCodeGenO

[clang] [llvm] [Clang] Emit DW_TAG_template_alias for template aliases (PR #87623)

2024-04-17 Thread Michael Buch via cfe-commits
@@ -1313,6 +1313,61 @@ llvm::DIType *CGDebugInfo::CreateType(const BlockPointerType *Ty, return DBuilder.createPointerType(EltTy, Size); } +static llvm::SmallVector +GetTemplateArgs(const TemplateDecl *TD, const TemplateSpecializationType *Ty) { + assert(Ty->isTypeAlias())

[clang] [llvm] [Clang] Emit DW_TAG_template_alias for template aliases (PR #87623)

2024-04-17 Thread Michael Buch via cfe-commits
@@ -1332,6 +1332,54 @@ llvm::DIType *CGDebugInfo::CreateType(const TemplateSpecializationType *Ty, auto PP = getPrintingPolicy(); Ty->getTemplateName().print(OS, PP, TemplateName::Qualified::None); + SourceLocation Loc = AliasDecl->getLocation(); + + if (CGM.getCodeGenO

[clang] [llvm] [Clang] Emit DW_TAG_template_alias for template aliases (PR #87623)

2024-04-18 Thread Michael Buch via cfe-commits
@@ -1332,6 +1332,54 @@ llvm::DIType *CGDebugInfo::CreateType(const TemplateSpecializationType *Ty, auto PP = getPrintingPolicy(); Ty->getTemplateName().print(OS, PP, TemplateName::Qualified::None); + SourceLocation Loc = AliasDecl->getLocation(); + + if (CGM.getCodeGenO

<    1   2   3   4   5   6   >