[clang] [clang-format] Fix annotating attrs in class/struct (PR #124634)

2025-01-29 Thread Gedare Bloom via cfe-commits
gedare wrote: The improved fix is in https://github.com/llvm/llvm-project/pull/124891. https://github.com/llvm/llvm-project/pull/124634 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [llvm] [Clang] Remove ARCMigrate (PR #119269)

2025-01-29 Thread John McCall via cfe-commits
https://github.com/rjmccall approved this pull request. This looks right to me, but let me tag in @akyrtzi just to make his own pass over this. https://github.com/llvm/llvm-project/pull/119269 ___ cfe-commits mailing list cfe-commits@lists.llvm.org ht

[clang] [llvm] [DRAFT] Root SIgnatures add parser (PR #118895)

2025-01-29 Thread via cfe-commits
https://github.com/joaosaffran closed https://github.com/llvm/llvm-project/pull/118895 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Warn when unique objects might be duplicated in shared libraries (PR #117622)

2025-01-29 Thread Hans Wennborg via cfe-commits
@@ -6153,6 +6153,15 @@ def warn_static_local_in_extern_inline : Warning< def note_convert_inline_to_static : Note< "use 'static' to give inline function %0 internal linkage">; +def warn_possible_object_duplication_mutable : Warning< + "%0 is mutable, has hidden visibility,

[clang] Warn when unique objects might be duplicated in shared libraries (PR #117622)

2025-01-29 Thread Hans Wennborg via cfe-commits
@@ -0,0 +1,187 @@ +/** + * When building shared libraries, hidden objects which are defined in header + * files will be duplicated, with one copy in each shared library. If the object + * was meant to be globally unique (one copy per program), this can cause very + * subtle bugs.

[clang] Warn when unique objects might be duplicated in shared libraries (PR #117622)

2025-01-29 Thread Hans Wennborg via cfe-commits
@@ -0,0 +1,187 @@ +/** + * When building shared libraries, hidden objects which are defined in header + * files will be duplicated, with one copy in each shared library. If the object + * was meant to be globally unique (one copy per program), this can cause very + * subtle bugs.

[clang] Warn when unique objects might be duplicated in shared libraries (PR #117622)

2025-01-29 Thread Hans Wennborg via cfe-commits
@@ -0,0 +1,187 @@ +/** + * When building shared libraries, hidden objects which are defined in header + * files will be duplicated, with one copy in each shared library. If the object + * was meant to be globally unique (one copy per program), this can cause very + * subtle bugs.

[clang] Warn when unique objects might be duplicated in shared libraries (PR #117622)

2025-01-29 Thread Hans Wennborg via cfe-commits
@@ -0,0 +1,187 @@ +/** + * When building shared libraries, hidden objects which are defined in header + * files will be duplicated, with one copy in each shared library. If the object + * was meant to be globally unique (one copy per program), this can cause very + * subtle bugs.

[clang] Warn when unique objects might be duplicated in shared libraries (PR #117622)

2025-01-29 Thread Hans Wennborg via cfe-commits
@@ -6153,6 +6153,15 @@ def warn_static_local_in_extern_inline : Warning< def note_convert_inline_to_static : Note< "use 'static' to give inline function %0 internal linkage">; +def warn_possible_object_duplication_mutable : Warning< + "%0 is mutable, has hidden visibility,

[clang] Warn when unique objects might be duplicated in shared libraries (PR #117622)

2025-01-29 Thread Hans Wennborg via cfe-commits
@@ -508,6 +508,10 @@ New Compiler Flags - clang-cl and clang-dxc now support ``-fdiagnostics-color=[auto|never|always]`` in addition to ``-f[no-]color-diagnostics``. +- The ``-Wunique-object-duplication`` warning has been added to warn about objects zmodem

[clang] Warn when unique objects might be duplicated in shared libraries (PR #117622)

2025-01-29 Thread Hans Wennborg via cfe-commits
@@ -13374,6 +13374,62 @@ void Sema::checkNonTrivialCUnion(QualType QT, SourceLocation Loc, .visit(QT, nullptr, false); } +bool Sema::GloballyUniqueObjectMightBeAccidentallyDuplicated( +const VarDecl *Dcl) { + if (!Dcl || !getLangOpts().CPlusPlus)

[clang] [clang] UEFI handle unsupported triples. (PR #124824)

2025-01-29 Thread via cfe-commits
https://github.com/Prabhuk updated https://github.com/llvm/llvm-project/pull/124824 >From 270c260ba8160c71c6602fcb91a635368ee09a88 Mon Sep 17 00:00:00 2001 From: Prabhu Karthikeyan Rajasekaran Date: Tue, 28 Jan 2025 19:07:06 + Subject: [PATCH 1/5] [clang] Abort on unsupported uefi triples.

[clang] Warn when unique objects might be duplicated in shared libraries (PR #117622)

2025-01-29 Thread Devon Loehr via cfe-commits
@@ -13374,6 +13374,62 @@ void Sema::checkNonTrivialCUnion(QualType QT, SourceLocation Loc, .visit(QT, nullptr, false); } +bool Sema::GloballyUniqueObjectMightBeAccidentallyDuplicated( +const VarDecl *Dcl) { + if (!Dcl || !getLangOpts().CPlusPlus)

[clang] Warn when unique objects might be duplicated in shared libraries (PR #117622)

2025-01-29 Thread Devon Loehr via cfe-commits
@@ -0,0 +1,187 @@ +/** + * When building shared libraries, hidden objects which are defined in header + * files will be duplicated, with one copy in each shared library. If the object + * was meant to be globally unique (one copy per program), this can cause very + * subtle bugs.

[clang] [ARM] Empty structs are 1-byte for C++ ABI (PR #124762)

2025-01-29 Thread Eli Friedman via cfe-commits
@@ -1144,6 +1144,12 @@ Arm and AArch64 Support * FUJITSU-MONAKA (fujitsu-monaka) +- The AArch64 calling convention for empty structs in C++ mode was changed to + pass them as if they have a size of 1 byte, matching the AAPCS64 + specification and GCC's implementation. The

[clang] [clang][Sema] Improve template argument deduction diagnostic (PR #122754)

2025-01-29 Thread Aidan Goldfarb via cfe-commits
https://github.com/AidanGoldfarb updated https://github.com/llvm/llvm-project/pull/122754 >From b6c576fb90362640b2fd4e41bd7f13dfee95d04d Mon Sep 17 00:00:00 2001 From: Aidan Date: Mon, 13 Jan 2025 11:53:39 -0500 Subject: [PATCH 01/23] initial template arg fix push --- .../clang/Basic/Diagnost

[clang] Warn when unique objects might be duplicated in shared libraries (PR #117622)

2025-01-29 Thread Devon Loehr via cfe-commits
@@ -6153,6 +6153,15 @@ def warn_static_local_in_extern_inline : Warning< def note_convert_inline_to_static : Note< "use 'static' to give inline function %0 internal linkage">; +def warn_possible_object_duplication_mutable : Warning< + "%0 is mutable, has hidden visibility,

[clang] Warn when unique objects might be duplicated in shared libraries (PR #117622)

2025-01-29 Thread Devon Loehr via cfe-commits
@@ -0,0 +1,187 @@ +/** + * When building shared libraries, hidden objects which are defined in header + * files will be duplicated, with one copy in each shared library. If the object + * was meant to be globally unique (one copy per program), this can cause very + * subtle bugs.

[clang] Warn when unique objects might be duplicated in shared libraries (PR #117622)

2025-01-29 Thread Devon Loehr via cfe-commits
https://github.com/DKLoehr edited https://github.com/llvm/llvm-project/pull/117622 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Warn when unique objects might be duplicated in shared libraries (PR #117622)

2025-01-29 Thread Devon Loehr via cfe-commits
@@ -0,0 +1,187 @@ +/** + * When building shared libraries, hidden objects which are defined in header + * files will be duplicated, with one copy in each shared library. If the object + * was meant to be globally unique (one copy per program), this can cause very + * subtle bugs.

[clang] [clang][SME] Account for C++ lambdas in SME builtin diagnostics (PR #124750)

2025-01-29 Thread Eli Friedman via cfe-commits
https://github.com/efriedma-quic approved this pull request. https://github.com/llvm/llvm-project/pull/124750 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] do not destruct fields of unions (PR #122330)

2025-01-29 Thread Jameson Nash via cfe-commits
https://github.com/vtjnash updated https://github.com/llvm/llvm-project/pull/122330 >From 829e1c89ce869f782cb802a1d618003770c0d074 Mon Sep 17 00:00:00 2001 From: Jameson Nash Date: Thu, 9 Jan 2025 17:10:08 + Subject: [PATCH 1/2] [Sema] do not destruct fields of unions The C++ standard proh

[clang] [clang] UEFI handle unsupported triples. (PR #124824)

2025-01-29 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi approved this pull request. LGTM. Lets try to follow up w/ something on the llvm side too though. https://github.com/llvm/llvm-project/pull/124824 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org

[clang] [ARM] Empty structs are 1-byte for C++ ABI (PR #124762)

2025-01-29 Thread Oliver Stannard via cfe-commits
https://github.com/ostannard updated https://github.com/llvm/llvm-project/pull/124762 >From 4d883f068c5061e60e90e51d149a361920b431d2 Mon Sep 17 00:00:00 2001 From: Oliver Stannard Date: Thu, 12 Dec 2024 15:29:31 + Subject: [PATCH 1/5] [ARM] Empty structs are 1-byte for C++ ABI For C++ (but

[clang] [clang-format] Fix annotating attrs in class/struct (PR #124634)

2025-01-29 Thread Gedare Bloom via cfe-commits
gedare wrote: I'll rebase on the other PR after it merges. https://github.com/llvm/llvm-project/pull/124634 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Add ClassHeadName to help annotating StartOfName (PR #124891)

2025-01-29 Thread Gedare Bloom via cfe-commits
https://github.com/gedare approved this pull request. https://github.com/llvm/llvm-project/pull/124891 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Fix annotating attrs in class/struct (PR #124634)

2025-01-29 Thread Gedare Bloom via cfe-commits
gedare wrote: See https://github.com/llvm/llvm-project/pull/124891. https://github.com/llvm/llvm-project/pull/124634 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Added support for 3-argument std::string ctor in bugprone-string-constructor check (PR #123413)

2025-01-29 Thread Baranov Victor via cfe-commits
https://github.com/vbvictor updated https://github.com/llvm/llvm-project/pull/123413 >From bc85c10a7d316630843266779cb1465b02d3dbf6 Mon Sep 17 00:00:00 2001 From: Victor Baranov Date: Sat, 18 Jan 2025 00:49:29 +0300 Subject: [PATCH 1/5] [clang-tidy] Added support for 3-argument string ctor ---

[clang] [clang-format] Fix annotating attrs in class/struct (PR #124634)

2025-01-29 Thread Gedare Bloom via cfe-commits
https://github.com/gedare reopened https://github.com/llvm/llvm-project/pull/124634 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Fix annotating attrs in class/struct (PR #124634)

2025-01-29 Thread Gedare Bloom via cfe-commits
https://github.com/gedare closed https://github.com/llvm/llvm-project/pull/124634 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Remove the deprecated flag `-frelaxed-template-template-args`. (PR #111894)

2025-01-29 Thread Matheus Izvekov via cfe-commits
https://github.com/mizvekov updated https://github.com/llvm/llvm-project/pull/111894 >From c15f2faaa2cdc2c6516899c1c0e3c0d90f74f1eb Mon Sep 17 00:00:00 2001 From: Matheus Izvekov Date: Thu, 10 Oct 2024 15:40:48 -0300 Subject: [PATCH] [clang] Remove the deprecated flag `-frelaxed-template-templ

[clang] [clang] Remove the deprecated flag `-frelaxed-template-template-args`. (PR #111894)

2025-01-29 Thread via cfe-commits
https://github.com/cor3ntin approved this pull request. https://github.com/llvm/llvm-project/pull/111894 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Fuchsia] Support PGO (PR #120323)

2025-01-29 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi approved this pull request. LGTM. W/ a rebase, this seems to work fine locally. I'll start following up w/ a larger corpus. https://github.com/llvm/llvm-project/pull/120323 ___ cfe-commits mailing list cfe-commits@lists.llv

[clang] [clang] Return larger CXX records in memory (PR #120670)

2025-01-29 Thread Pranav Kant via cfe-commits
pranavk wrote: Oops. Too bad. I didn't realize we branched off release/20.x Anyhow, I made necessary tweaks to now make it a LLVM 21 feature. > There is a X86 Support section It feels more appropriate to put this in "ABI changes section" than "X86 support" since it's not a "support". But I a

[clang] [clang][dataflow] Fix smart pointer accessor caching to handle aliases (PR #124964)

2025-01-29 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Jan Voung (jvoung) Changes Check the canonical type in the matchers to handle aliases. For example std::optional uses add_pointer_t<...>. --- Full diff: https://github.com/llvm/llvm-project/pull/124964.diff 2 Files Affected: - (modifie

[clang] Warn when unique objects might be duplicated in shared libraries (PR #117622)

2025-01-29 Thread Hans Wennborg via cfe-commits
@@ -3661,6 +3661,12 @@ class Sema final : public SemaBase { NonTrivialCUnionContext UseContext, unsigned NonTrivialKind); + /// Certain globally-unique variables might be accidentally duplicated if + /// built into mu

[clang] [AArch64] Add MSVC mangling for the __mfp8 type (PR #124968)

2025-01-29 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Momchil Velikov (momchil-velikov) Changes Fixes #124907 --- Full diff: https://github.com/llvm/llvm-project/pull/124968.diff 2 Files Affected: - (modified) clang/lib/AST/MicrosoftMangle.cpp (+5) - (added) clang/test/CodeGenCXX/aarch64

[clang] [clang][dataflow] Fix smart pointer accessor caching to handle aliases (PR #124964)

2025-01-29 Thread Jan Voung via cfe-commits
https://github.com/jvoung ready_for_review https://github.com/llvm/llvm-project/pull/124964 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AArch64] Add MSVC mangling for the __mfp8 type (PR #124968)

2025-01-29 Thread Momchil Velikov via cfe-commits
https://github.com/momchil-velikov created https://github.com/llvm/llvm-project/pull/124968 Fixes #124907 >From e490f9684aa8784299a9195a195433270f2cec79 Mon Sep 17 00:00:00 2001 From: Momchil Velikov Date: Wed, 29 Jan 2025 18:31:18 + Subject: [PATCH] [AArch64] Add MSVC mangling for the __

[clang] Reland "[HIP] Use original file path for CUID" (#108771) (PR #111885)

2025-01-29 Thread Artem Belevich via cfe-commits
@@ -1,13 +1,15 @@ // Check CUID generated by hash. // The same CUID is generated for the same file with the same options. +// RUN: cd %S + // RUN: %clang -### -x hip --target=x86_64-unknown-linux-gnu --no-offload-new-driver \ // RUN: --offload-arch=gfx906 -c -nogpuinc -no

[clang] [clang][dataflow] Fix smart pointer accessor caching to handle aliases (PR #124964)

2025-01-29 Thread Yitzhak Mandelbaum via cfe-commits
https://github.com/ymand approved this pull request. https://github.com/llvm/llvm-project/pull/124964 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CUDA] Emit NULL in VTable in the last resort (PR #124687)

2025-01-29 Thread Anshil Gandhi via cfe-commits
https://github.com/gandhi56 closed https://github.com/llvm/llvm-project/pull/124687 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] UEFI handle unsupported triples. (PR #124824)

2025-01-29 Thread via cfe-commits
https://github.com/Prabhuk updated https://github.com/llvm/llvm-project/pull/124824 >From 270c260ba8160c71c6602fcb91a635368ee09a88 Mon Sep 17 00:00:00 2001 From: Prabhu Karthikeyan Rajasekaran Date: Tue, 28 Jan 2025 19:07:06 + Subject: [PATCH 1/7] [clang] Abort on unsupported uefi triples.

[clang] [Clang][P1061] Add stuctured binding packs (PR #121417)

2025-01-29 Thread Jason Rice via cfe-commits
ricejasonf wrote: @cor3ntin > Now that the Clang 20 branch has happened, I think we should go ahead with > that PR Does this mean we should adjust the cxx_status page to not say Clang 20? I also see there is a conflict with the ReleaseNotes.md where it appears all of the C++2c items no long

[clang] [ubsan] Connect -fsanitize-skip-hot-cutoff to LowerAllowCheckPass (PR #124857)

2025-01-29 Thread Thurston Dang via cfe-commits
https://github.com/thurstond updated https://github.com/llvm/llvm-project/pull/124857 >From 68246540d28c765af1fe4d61244e35cc8ff723cc Mon Sep 17 00:00:00 2001 From: Thurston Dang Date: Wed, 22 Jan 2025 18:59:07 + Subject: [PATCH 1/5] [ubsan] Connect -fsanitize-skip-hot-cutoff to LowerAllowC

[clang] [ubsan] Connect -fsanitize-skip-hot-cutoff to LowerAllowCheckPass (PR #124857)

2025-01-29 Thread Thurston Dang via cfe-commits
@@ -795,12 +795,29 @@ static void addSanitizers(const Triple &TargetTriple, PB.registerOptimizerLastEPCallback(SanitizersCallback); } - if (LowerAllowCheckPass::IsRequested()) { + bool lowerAllowCheck = LowerAllowCheckPass::IsRequested(); + // Is there a non-zero cuto

[clang] [ubsan] Connect -fsanitize-skip-hot-cutoff to LowerAllowCheckPass (PR #124857)

2025-01-29 Thread Thurston Dang via cfe-commits
@@ -795,12 +795,29 @@ static void addSanitizers(const Triple &TargetTriple, PB.registerOptimizerLastEPCallback(SanitizersCallback); } - if (LowerAllowCheckPass::IsRequested()) { + bool lowerAllowCheck = LowerAllowCheckPass::IsRequested(); + // Is there a non-zero cuto

[clang] [ubsan] Connect -fsanitize-skip-hot-cutoff to LowerAllowCheckPass (PR #124857)

2025-01-29 Thread Thurston Dang via cfe-commits
@@ -795,12 +795,29 @@ static void addSanitizers(const Triple &TargetTriple, PB.registerOptimizerLastEPCallback(SanitizersCallback); } - if (LowerAllowCheckPass::IsRequested()) { + bool lowerAllowCheck = LowerAllowCheckPass::IsRequested(); + // Is there a non-zero cuto

[clang] [Clang][counted_by] Refactor __builtin_dynamic_object_size on FAMs (PR #122198)

2025-01-29 Thread Bill Wendling via cfe-commits
bwendling wrote: Friendly ping for any further comments. https://github.com/llvm/llvm-project/pull/122198 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 8a334af - [clang] Remove the deprecated flag `-frelaxed-template-template-args`. (#111894)

2025-01-29 Thread via cfe-commits
Author: Matheus Izvekov Date: 2025-01-29T16:57:05-03:00 New Revision: 8a334af417ff2ef49e0bc74f9421b4f3aa479805 URL: https://github.com/llvm/llvm-project/commit/8a334af417ff2ef49e0bc74f9421b4f3aa479805 DIFF: https://github.com/llvm/llvm-project/commit/8a334af417ff2ef49e0bc74f9421b4f3aa479805.dif

[clang] [clang] Remove the deprecated flag `-frelaxed-template-template-args`. (PR #111894)

2025-01-29 Thread Matheus Izvekov via cfe-commits
https://github.com/mizvekov closed https://github.com/llvm/llvm-project/pull/111894 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] a368402 - [ExtractAPI] merge anon declarators even if they're array types (#120801)

2025-01-29 Thread via cfe-commits
Author: QuietMisdreavus Date: 2025-01-29T13:03:33-07:00 New Revision: a368402d633098fc211c29f9726eef6e1874da5f URL: https://github.com/llvm/llvm-project/commit/a368402d633098fc211c29f9726eef6e1874da5f DIFF: https://github.com/llvm/llvm-project/commit/a368402d633098fc211c29f9726eef6e1874da5f.dif

[clang] [clang][Sema] Improve template argument deduction diagnostic (PR #122754)

2025-01-29 Thread Matheus Izvekov via cfe-commits
@@ -11714,13 +11714,37 @@ static void DiagnoseBadDeduction(Sema &S, NamedDecl *Found, Decl *Templated, return; } - case TemplateDeductionResult::InvalidExplicitArguments: + case TemplateDeductionResult::InvalidExplicitArguments: { assert(ParamD && "no parameter f

[clang] [clang][Sema] Improve template argument deduction diagnostic (PR #122754)

2025-01-29 Thread Matheus Izvekov via cfe-commits
https://github.com/mizvekov edited https://github.com/llvm/llvm-project/pull/122754 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

<    1   2   3   4   5