[clang] 6ff6191 - [Driver] Reject -fptrauth-intrinsics on non-AArch64 targets

2024-03-26 Thread Fangrui Song via cfe-commits
Author: Fangrui Song Date: 2024-03-26T00:04:19-07:00 New Revision: 6ff61914a1ef2c05702ba73cf31ffdeed59c1740 URL: https://github.com/llvm/llvm-project/commit/6ff61914a1ef2c05702ba73cf31ffdeed59c1740 DIFF: https://github.com/llvm/llvm-project/commit/6ff61914a1ef2c05702ba73cf31ffdeed59c1740.diff

[clang] [AArch64][PAC][clang][ELF] Support PAuth ABI compatibility tag (PR #85235)

2024-03-26 Thread Fangrui Song via cfe-commits
@@ -0,0 +1,32 @@ +// Check that we can manually enable specific ptrauth features. + +// RUN: %clang --target=aarch64 -c %s -### 2>&1 | FileCheck %s --check-prefix NONE +// NONE: "-cc1" +// NONE-NOT: "-fptrauth-intrinsics" MaskRay wrote: `// NONE-NOT: "-fptrauth-

[clang] [AArch64][PAC][clang][ELF] Support PAuth ABI compatibility tag (PR #85235)

2024-03-26 Thread Fangrui Song via cfe-commits
@@ -0,0 +1,32 @@ +// Check that we can manually enable specific ptrauth features. MaskRay wrote: aarch64-ptrauth.c is more conventional for such target-specific features https://github.com/llvm/llvm-project/pull/85235

[clang] [AArch64][PAC][clang][ELF] Support PAuth ABI compatibility tag (PR #85235)

2024-03-26 Thread Fangrui Song via cfe-commits
@@ -7203,6 +7203,33 @@ void Clang::ConstructJob(Compilation &C, const JobAction &JA, options::OPT_fno_ptrauth_intrinsics, false)) CmdArgs.push_back("-fptrauth-intrinsics"); + if (Args.hasFlag(options::OPT_fptrauth_calls, options::OPT_fno_ptrauth_calls,

[clang] [clang] Fix assertion failure when printing atomic apvalues (PR #85259)

2024-03-26 Thread Timm Baeder via cfe-commits
tbaederr wrote: Right, I was just hoping for an existing unittest for `APValue`. https://github.com/llvm/llvm-project/pull/85259 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 6a6f9bf - [clang] Fix assertion failure when printing atomic apvalues (#85259)

2024-03-26 Thread via cfe-commits
Author: Timm Baeder Date: 2024-03-26T08:35:03+01:00 New Revision: 6a6f9bf38e65ec45b32da4b578e2830341a9b364 URL: https://github.com/llvm/llvm-project/commit/6a6f9bf38e65ec45b32da4b578e2830341a9b364 DIFF: https://github.com/llvm/llvm-project/commit/6a6f9bf38e65ec45b32da4b578e2830341a9b364.diff L

[clang] [clang] Fix assertion failure when printing atomic apvalues (PR #85259)

2024-03-26 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr closed https://github.com/llvm/llvm-project/pull/85259 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][analyzer] add documentation for optin performance padding (padding checker) #73675 (PR #86411)

2024-03-26 Thread via cfe-commits
@@ -804,10 +804,38 @@ Check for performance anti-patterns when using Grand Central Dispatch. .. _optin-performance-Padding: -optin.performance.Padding -" +optin.performance.Padding (C, C++, ObjC) + Check for ex

[clang] [llvm] [Sema] Implement support for -Wformat-signedness (PR #74440)

2024-03-26 Thread Karl-Johan Karlsson via cfe-commits
https://github.com/karka228 updated https://github.com/llvm/llvm-project/pull/74440 >From aa9d6cd10ff32fdcdd3d1b2ef334aa70f56cccb1 Mon Sep 17 00:00:00 2001 From: Karl-Johan Karlsson Date: Tue, 5 Dec 2023 10:03:00 +0100 Subject: [PATCH 1/9] [Sema] Implement support for -Wformat-signedness In gc

[clang] [llvm] [Sema] Implement support for -Wformat-signedness (PR #74440)

2024-03-26 Thread Karl-Johan Karlsson via cfe-commits
karka228 wrote: > > With the current implementation `-Wformat-signedness` by itself actually > > turn on the signedness warnings. This is not compatible with how gcc do it. > > I guess I have thought that it was not that important to be compatible with > > gcc in this respect. However if it is

[clang] [Clang][analyzer] add documentation for optin performance padding (padding checker) #73675 (PR #86411)

2024-03-26 Thread via cfe-commits
@@ -804,10 +804,38 @@ Check for performance anti-patterns when using Grand Central Dispatch. .. _optin-performance-Padding: -optin.performance.Padding -" +optin.performance.Padding (C, C++, ObjC) + Check for ex

[clang] [Clang][analyzer] add documentation for optin performance padding (padding checker) #73675 (PR #86411)

2024-03-26 Thread via cfe-commits
https://github.com/komalverma04 edited https://github.com/llvm/llvm-project/pull/86411 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [libcxx] [clang] Enable sized deallocation by default in C++14 onwards (PR #83774)

2024-03-26 Thread Petr Hosek via cfe-commits
@@ -49,3 +49,62 @@ if ((MINGW OR CYGWIN) AND BUILD_SHARED_LIBS) # despite potential dllexports. target_link_options(clangInterpreter PRIVATE LINKER:--export-all-symbols) endif() + +if(MSVC) + set_target_properties(clangInterpreter PROPERTIES WINDOWS_EXPORT_ALL_SYMBOLS 1)

[clang] [[clang::always_destroy]] attribute silences warn-exit-time-destructor (PR #86486)

2024-03-26 Thread via cfe-commits
https://github.com/ycdtosa updated https://github.com/llvm/llvm-project/pull/86486 >From 016152bc21c2625db77d3e31a7123bcf08114133 Mon Sep 17 00:00:00 2001 From: ycdtosa Date: Mon, 25 Mar 2024 10:28:02 + Subject: [PATCH 1/5] add test for [[clang::always-destroy]] attribute user wants the wa

[clang] [Clang] [C++26] Implement P2573R2: `= delete("should have a reason");` (PR #86526)

2024-03-26 Thread Mariya Podchishchaeva via cfe-commits
@@ -873,9 +873,14 @@ void DeclPrinter::VisitFunctionDecl(FunctionDecl *D) { if (D->isPureVirtual()) Out << " = 0"; - else if (D->isDeletedAsWritten()) + else if (D->isDeletedAsWritten()) { Out << " = delete"; - else if (D->isExplicitlyDefaulted()) +if (const

[clang] [Clang] [C++26] Implement P2573R2: `= delete("should have a reason");` (PR #86526)

2024-03-26 Thread Mariya Podchishchaeva via cfe-commits
@@ -1936,6 +1936,9 @@ void TextNodeDumper::VisitFunctionDecl(const FunctionDecl *D) { if (D->isTrivial()) OS << " trivial"; + if (const auto *M = D->getDeletedMessage()) Fznamznon wrote: Here too. ```suggestion if (const StringLiteral *M = D->getDe

[clang] [clang-tools-extra] [libcxx] [clang] Enable sized deallocation by default in C++14 onwards (PR #83774)

2024-03-26 Thread Wang Pengcheng via cfe-commits
@@ -49,3 +49,62 @@ if ((MINGW OR CYGWIN) AND BUILD_SHARED_LIBS) # despite potential dllexports. target_link_options(clangInterpreter PRIVATE LINKER:--export-all-symbols) endif() + +if(MSVC) + set_target_properties(clangInterpreter PROPERTIES WINDOWS_EXPORT_ALL_SYMBOLS 1)

[clang] 4fa736b - [Clang] NFC Silence compiler warning spam (#86532)

2024-03-26 Thread via cfe-commits
Author: NagyDonat Date: 2024-03-26T10:33:12+01:00 New Revision: 4fa736ba41fce885047bd5a242230b216ea85c70 URL: https://github.com/llvm/llvm-project/commit/4fa736ba41fce885047bd5a242230b216ea85c70 DIFF: https://github.com/llvm/llvm-project/commit/4fa736ba41fce885047bd5a242230b216ea85c70.diff LOG

[clang] [Clang] NFC Silence compiler warning spam (PR #86532)

2024-03-26 Thread via cfe-commits
https://github.com/NagyDonat closed https://github.com/llvm/llvm-project/pull/86532 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Emit bad shift warnings (PR #70307)

2024-03-26 Thread Budimir Aranđelović via cfe-commits
https://github.com/budimirarandjelovicsyrmia updated https://github.com/llvm/llvm-project/pull/70307 From 17fb77d094018db20de0ac2a65861338006f9d68 Mon Sep 17 00:00:00 2001 From: budimirarandjelovicsyrmia Date: Thu, 26 Oct 2023 10:39:52 +0200 Subject: [PATCH] [clang] Emit bad shift warnings ---

[clang] [clang] Emit bad shift warnings (PR #70307)

2024-03-26 Thread Budimir Aranđelović via cfe-commits
@@ -2805,7 +2805,7 @@ static bool handleIntIntBinOp(EvalInfo &Info, const Expr *E, const APSInt &LHS, unsigned SA = (unsigned) RHS.getLimitedValue(LHS.getBitWidth()-1); if (SA != RHS) { Info.CCEDiag(E, diag::note_constexpr_large_shift) -<< RHS << E->getTy

[clang] [clang-format] Do not update cursor pos if no includes replacement (PR #77456)

2024-03-26 Thread via cfe-commits
https://github.com/NorthBlue333 updated https://github.com/llvm/llvm-project/pull/77456 >From a3ddae11b909a319d73fccff409fa5c0648a234f Mon Sep 17 00:00:00 2001 From: NorthBlue333 Date: Tue, 9 Jan 2024 14:01:14 +0100 Subject: [PATCH 1/2] [clang-format] Do not update cursor pos if no includes re

[clang] Fix printing of templated records. (PR #86339)

2024-03-26 Thread Zahira Ammarguellat via cfe-commits
@@ -2303,11 +2303,6 @@ printTo(raw_ostream &OS, ArrayRef Args, const PrintingPolicy &Policy, } else { if (!FirstArg) OS << Comma; - if (!Policy.SuppressTagKeyword && - Argument.getKind() == TemplateArgument::Type && - isa(Argument.getAs

[clang] [clang-format] Do not update cursor pos if no includes replacement (PR #77456)

2024-03-26 Thread via cfe-commits
https://github.com/NorthBlue333 updated https://github.com/llvm/llvm-project/pull/77456 >From d4fd95374a82361e3dbfcd7a5d87c37da4542d2b Mon Sep 17 00:00:00 2001 From: NorthBlue333 Date: Tue, 9 Jan 2024 14:01:14 +0100 Subject: [PATCH 1/2] [clang-format] Do not update cursor pos if no includes re

[clang] [clang][PowerPC] Add flag to enable compatibility with GNU for complex arguments (PR #77732)

2024-03-26 Thread Kishan Parmar via cfe-commits
https://github.com/Long5hot updated https://github.com/llvm/llvm-project/pull/77732 >From 618762c79f5ec1ea9a945b81e182e3d8e1046baf Mon Sep 17 00:00:00 2001 From: Kishan Parmar Date: Tue, 26 Mar 2024 16:21:10 +0530 Subject: [PATCH] [clang][PowerPC] Add flag to enable compatibility with GNU for

[clang] [clang-format] Do not update cursor pos if no includes replacement (PR #77456)

2024-03-26 Thread via cfe-commits
https://github.com/NorthBlue333 updated https://github.com/llvm/llvm-project/pull/77456 >From d4fd95374a82361e3dbfcd7a5d87c37da4542d2b Mon Sep 17 00:00:00 2001 From: NorthBlue333 Date: Tue, 9 Jan 2024 14:01:14 +0100 Subject: [PATCH 1/2] [clang-format] Do not update cursor pos if no includes re

[clang] [clang][PowerPC] Add flag to enable compatibility with GNU for complex arguments (PR #77732)

2024-03-26 Thread Kishan Parmar via cfe-commits
https://github.com/Long5hot updated https://github.com/llvm/llvm-project/pull/77732 >From 59bd85681c590a5b3e259bfa93d87a80e5362878 Mon Sep 17 00:00:00 2001 From: Kishan Parmar Date: Tue, 26 Mar 2024 16:40:32 +0530 Subject: [PATCH] [clang][PowerPC] Add flag to enable compatibility with GNU for

[clang] [clang-format] Do not update cursor pos if no includes replacement (PR #77456)

2024-03-26 Thread via cfe-commits
NorthBlue333 wrote: Woops, sorry, I missed the update here. I've done all your changes in a second commit just to be able to keep track of my previous changes; but I am actually not sure how your suggested modifications are any different from mine? Well, I admit it looks a bit better, but it

[clang] [clang][PowerPC] Add flag to enable compatibility with GNU for complex arguments (PR #77732)

2024-03-26 Thread Kishan Parmar via cfe-commits
@@ -337,12 +347,58 @@ CharUnits PPC32_SVR4_ABIInfo::getParamTypeAlignment(QualType Ty) const { return CharUnits::fromQuantity(4); } +ABIArgInfo PPC32_SVR4_ABIInfo::handleComplex(uint64_t &TypeSize) const { + llvm::Type *ElemTy; + unsigned RegsNeeded; // Registers Needed f

[clang] [Clang] Fix __is_array returning true for zero-sized arrays (PR #86652)

2024-03-26 Thread Nikolas Klauser via cfe-commits
https://github.com/philnik777 created https://github.com/llvm/llvm-project/pull/86652 Fixes #54705 >From 90f88bdac3dc40635c58f3f67e29354e6a32896e Mon Sep 17 00:00:00 2001 From: Nikolas Klauser Date: Tue, 26 Mar 2024 12:23:24 +0100 Subject: [PATCH] [Clang] Fix __is_array returning true for zer

[clang] [Clang] Fix __is_array returning true for zero-sized arrays (PR #86652)

2024-03-26 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Nikolas Klauser (philnik777) Changes Fixes #54705 --- Full diff: https://github.com/llvm/llvm-project/pull/86652.diff 3 Files Affected: - (modified) clang/docs/ReleaseNotes.rst (+2) - (modified) clang/lib/Sema/SemaExprCXX.cpp (+4) -

[clang] [Clang] Fix __is_array returning true for zero-sized arrays (PR #86652)

2024-03-26 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff 5b544b511c7133fcb26a5c563b746a4baefb38d6 90f88bdac3dc40635c58f3f67e29354e6a32896e --

[clang] da9ac43 - [FMV] Allow mixing target_version with target_clones. (#86493)

2024-03-26 Thread via cfe-commits
Author: Alexandros Lamprineas Date: 2024-03-26T11:36:34Z New Revision: da9ac43433ace54b262cd8552a9fafac21186381 URL: https://github.com/llvm/llvm-project/commit/da9ac43433ace54b262cd8552a9fafac21186381 DIFF: https://github.com/llvm/llvm-project/commit/da9ac43433ace54b262cd8552a9fafac21186381.di

[clang] [FMV] Allow mixing target_version with target_clones. (PR #86493)

2024-03-26 Thread Alexandros Lamprineas via cfe-commits
https://github.com/labrinea closed https://github.com/llvm/llvm-project/pull/86493 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][ExtractAPI] improve template argument name deduction (PR #77716)

2024-03-26 Thread Daniel Grumberg via cfe-commits
@@ -1127,7 +1096,7 @@ DeclarationFragmentsBuilder::getFragmentsForVarTemplatePartialSpecialization( .append("<", DeclarationFragments::FragmentKind::Text) .append(getFragmentsForTemplateArguments( Decl->getTemplateArgs().asArray(), Decl->getASTContext(),

[clang] [clang][PowerPC] Add flag to enable compatibility with GNU for complex arguments (PR #77732)

2024-03-26 Thread Kishan Parmar via cfe-commits
https://github.com/Long5hot updated https://github.com/llvm/llvm-project/pull/77732 >From 81d57b415738e4cea8fbbade990046271cb505a5 Mon Sep 17 00:00:00 2001 From: Kishan Parmar Date: Tue, 26 Mar 2024 17:08:25 +0530 Subject: [PATCH] [clang][PowerPC] Add flag to enable compatibility with GNU for

[clang] [llvm] [AMDGPU] Emit a waitcnt instruction after each memory instruction (PR #79236)

2024-03-26 Thread Jay Foad via cfe-commits
@@ -2326,6 +2326,20 @@ bool SIInsertWaitcnts::insertWaitcntInBlock(MachineFunction &MF, } #endif +if (ST->isPreciseMemoryEnabled() && Inst.mayLoadOrStore()) { + AMDGPU::Waitcnt Wait; + if (ST->hasExtendedWaitCounts()) +Wait = AMDGPU::Waitcnt(0, 0, 0,

[clang] Fix printing of templated records. (PR #86339)

2024-03-26 Thread Zahira Ammarguellat via cfe-commits
https://github.com/zahiraam edited https://github.com/llvm/llvm-project/pull/86339 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix printing of templated records. (PR #86339)

2024-03-26 Thread Zahira Ammarguellat via cfe-commits
https://github.com/zahiraam edited https://github.com/llvm/llvm-project/pull/86339 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Fix __is_array returning true for zero-sized arrays (PR #86652)

2024-03-26 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman edited https://github.com/llvm/llvm-project/pull/86652 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Fix __is_array returning true for zero-sized arrays (PR #86652)

2024-03-26 Thread Aaron Ballman via cfe-commits
@@ -1804,7 +1806,7 @@ void is_layout_compatible(int n) static_assert(!__is_layout_compatible(EnumForward, int)); static_assert(!__is_layout_compatible(EnumClassForward, int)); // FIXME: the following should be rejected (array of unknown bound and void are the only allowe

[clang] [Clang] Fix __is_array returning true for zero-sized arrays (PR #86652)

2024-03-26 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman requested changes to this pull request. My primary question is: then what is it? We return true for `__is_aggregrate` (https://godbolt.org/z/67zjeo7Mj), and an aggregate is an array or class type (https://eel.is/c++draft/dcl.init.aggr#1). This isn't a class type

[compiler-rt] [libcxx] [libcxxabi] [libunwind] [libunwind][libcxx][libcxxabi][compiler-rt-builtins] Fix Exception Handling build for wasm (PR #79667)

2024-03-26 Thread via cfe-commits
@@ -12,6 +12,7 @@ #include #include "config.h" +#ifndef __wasm__ trcrsired wrote: then it has to change cmake file, which is annoying for users. https://github.com/llvm/llvm-project/pull/79667 ___ cfe-commits mail

[compiler-rt] [libcxx] [libcxxabi] [libunwind] [libunwind][libcxx][libcxxabi][compiler-rt-builtins] Fix Exception Handling build for wasm (PR #79667)

2024-03-26 Thread via cfe-commits
@@ -12,6 +12,7 @@ #ifndef __LIBUNWIND_EXT__ #define __LIBUNWIND_EXT__ +#ifndef __wasm__ trcrsired wrote: The problem is that __WASM_EXCEPTIONS__ macro is not defined by clang, so using any other the header without __wasm__ will trigger ODR violation. Remote

[compiler-rt] [libcxx] [libcxxabi] [libunwind] [libunwind][libcxx][libcxxabi][compiler-rt-builtins] Fix Exception Handling build for wasm (PR #79667)

2024-03-26 Thread via cfe-commits
https://github.com/trcrsired edited https://github.com/llvm/llvm-project/pull/79667 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[compiler-rt] [libcxx] [libcxxabi] [libunwind] [libunwind][libcxx][libcxxabi][compiler-rt-builtins] Fix Exception Handling build for wasm (PR #79667)

2024-03-26 Thread via cfe-commits
https://github.com/trcrsired edited https://github.com/llvm/llvm-project/pull/79667 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Fix __is_array returning true for zero-sized arrays (PR #86652)

2024-03-26 Thread Nikolas Klauser via cfe-commits
philnik777 wrote: > My primary question is: then what is it? > > We return true for `__is_aggregrate` (https://godbolt.org/z/67zjeo7Mj), and > an aggregate is an array or class type > (https://eel.is/c++draft/dcl.init.aggr#1). This isn't a class type... but it > is an aggregate... so it must

[clang] [[clang::always_destroy]] attribute silences warn-exit-time-destructor (PR #86486)

2024-03-26 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman edited https://github.com/llvm/llvm-project/pull/86486 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [[clang::always_destroy]] attribute silences warn-exit-time-destructor (PR #86486)

2024-03-26 Thread Aaron Ballman via cfe-commits
@@ -6069,6 +6069,9 @@ def AlwaysDestroyDocs : Documentation { The ``always_destroy`` attribute specifies that a variable with static or thread storage duration should have its exit-time destructor run. This attribute is the default unless clang was invoked with -fno-c++-stati

[clang] [[clang::always_destroy]] attribute silences warn-exit-time-destructor (PR #86486)

2024-03-26 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman approved this pull request. LGTM aside from a few minor nits, thank you for the improvement! I'm assuming you need me to land this on your behalf, so I'll go ahead and apply the fixes myself and then land the changes. https://github.com/llvm/llvm-project/pull/86

[clang] [[clang::always_destroy]] attribute silences warn-exit-time-destructor (PR #86486)

2024-03-26 Thread Aaron Ballman via cfe-commits
@@ -289,6 +289,10 @@ Improvements to Clang's diagnostics - Clang now correctly diagnoses no arguments to a variadic macro parameter as a C23/C++20 extension. Fixes #GH84495. +- Clang no longer emits the ``exit-time destructor`` warning on static variables explicitly --

[clang] [[clang::always_destroy]] attribute silences warn-exit-time-destructor (PR #86486)

2024-03-26 Thread Aaron Ballman via cfe-commits
@@ -289,6 +289,10 @@ Improvements to Clang's diagnostics - Clang now correctly diagnoses no arguments to a variadic macro parameter as a C23/C++20 extension. Fixes #GH84495. +- Clang no longer emits a ``-Wexit-time destructor`` warning on static variables explicitly --

[clang] [[clang::always_destroy]] attribute silences warn-exit-time-destructor (PR #86486)

2024-03-26 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman commented: Suggesting a typo fix to my previous suggested edits https://github.com/llvm/llvm-project/pull/86486 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-

[clang] [[clang::always_destroy]] attribute silences warn-exit-time-destructor (PR #86486)

2024-03-26 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman edited https://github.com/llvm/llvm-project/pull/86486 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [[clang::always_destroy]] attribute silences warn-exit-time-destructor (PR #86486)

2024-03-26 Thread Aaron Ballman via cfe-commits
@@ -6069,6 +6069,9 @@ def AlwaysDestroyDocs : Documentation { The ``always_destroy`` attribute specifies that a variable with static or thread storage duration should have its exit-time destructor run. This attribute is the default unless clang was invoked with -fno-c++-stati

[libcxx] [libunwind] [DRAFT][libc++] Switch FreeBSD to C++26 (PR #86658)

2024-03-26 Thread Ed Maste via cfe-commits
https://github.com/emaste created https://github.com/llvm/llvm-project/pull/86658 As discussed in #86320; opening this PR for CI. It looks like (prior to this change) there are no C++26 jobs right now. >From 6cf1345feee41ec3bad51ba853091e35723c85ab Mon Sep 17 00:00:00 2001 From: Dmitry Chagin

[libcxx] [libunwind] [DRAFT][libc++] Switch FreeBSD to C++26 (PR #86658)

2024-03-26 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-libunwind Author: Ed Maste (emaste) Changes As discussed in #86320; opening this PR for CI. It looks like (prior to this change) there are no C++26 jobs right now. --- Full diff: https://github.com/llvm/llvm-project/pull/86658.diff 3 Files Affected:

[clang] 59e0525 - [[clang::always_destroy]] attribute silences warn-exit-time-destructor (#86486)

2024-03-26 Thread via cfe-commits
Author: ycdtosa Date: 2024-03-26T08:38:31-04:00 New Revision: 59e052568e7d46cc0489269e3c76f53bb21941f5 URL: https://github.com/llvm/llvm-project/commit/59e052568e7d46cc0489269e3c76f53bb21941f5 DIFF: https://github.com/llvm/llvm-project/commit/59e052568e7d46cc0489269e3c76f53bb21941f5.diff LOG:

[clang] [[clang::always_destroy]] attribute silences warn-exit-time-destructor (PR #86486)

2024-03-26 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman closed https://github.com/llvm/llvm-project/pull/86486 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [[clang::always_destroy]] attribute silences warn-exit-time-destructor (PR #86486)

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

[clang-tools-extra] Add clang-tidy check readability-math-missing-parentheses (PR #84481)

2024-03-26 Thread Julian Schmidt via cfe-commits
@@ -0,0 +1,25 @@ +.. title:: clang-tidy - readability-math-missing-parentheses + +readability-math-missing-parentheses + + +Check for missing parentheses in mathematical expressions that involve operators +of different priorities. Parentheses i

[clang] feebcd6 - [clang] Fix -Wunused-variable in SemaDecl.cpp (NFC)

2024-03-26 Thread Jie Fu via cfe-commits
Author: Jie Fu Date: 2024-03-26T20:41:46+08:00 New Revision: feebcd65fb7e0534f5219e05432a05e45aa8cd2a URL: https://github.com/llvm/llvm-project/commit/feebcd65fb7e0534f5219e05432a05e45aa8cd2a DIFF: https://github.com/llvm/llvm-project/commit/feebcd65fb7e0534f5219e05432a05e45aa8cd2a.diff LOG: [

[clang-tools-extra] [clang-tidy] Fix fix-it overlaps in readability-static-definition-in-anonymous-namespace (PR #86599)

2024-03-26 Thread Julian Schmidt via cfe-commits
https://github.com/5chmidti approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/86599 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[compiler-rt] [libcxx] [libcxxabi] [libunwind] [libunwind][libcxx][libcxxabi][compiler-rt-builtins] Fix Exception Handling build for wasm (PR #79667)

2024-03-26 Thread via cfe-commits
@@ -12,6 +12,7 @@ #include #include "config.h" +#ifndef __wasm__ EricWF wrote: I feel like we could detect `__wasm__` or similar in CMake. And it feels like the right tool, though maybe not the most trivial to implement. https://github.com/llvm/llvm-projec

[clang-tools-extra] Add clang-tidy check readability-math-missing-parentheses (PR #84481)

2024-03-26 Thread Bhuminjay Soni via cfe-commits
https://github.com/11happy updated https://github.com/llvm/llvm-project/pull/84481 >From 8fdf6306085ed4cf0f77b7e718e374e9f65fedf9 Mon Sep 17 00:00:00 2001 From: 11happy Date: Fri, 8 Mar 2024 19:02:47 +0530 Subject: [PATCH 1/8] add clang-tidy check readability-math-missing-parentheses Signed-of

[clang-tools-extra] Add clang-tidy check readability-math-missing-parentheses (PR #84481)

2024-03-26 Thread Bhuminjay Soni via cfe-commits
@@ -0,0 +1,25 @@ +.. title:: clang-tidy - readability-math-missing-parentheses + +readability-math-missing-parentheses + + +Check for missing parentheses in mathematical expressions that involve operators +of different priorities. Parentheses i

[clang] [Clang] Fix __is_array returning true for zero-sized arrays (PR #86652)

2024-03-26 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > According to the spec it's ill-formed, so I'm not sure it falls under any > sensible category. It's an extension we support so it's up to us to decide what sensible is. > For T[0] this returns false. Understood, but why is this not the bug to be fixed? (It would also fix

[clang] [llvm] [clang][HLSL][SPRI-V] Add convergence intrinsics (PR #80680)

2024-03-26 Thread Nathan Gauër via cfe-commits
Keenuts wrote: @arsenm would you be fine with those codegen changes as-is? Given that the convergent/no-convergent switch will be done later, depending on when the required IR change is merged? https://github.com/llvm/llvm-project/pull/80680 ___ cfe-

[clang] [llvm] [Sema] Implement support for -Wformat-signedness (PR #74440)

2024-03-26 Thread Aaron Ballman via cfe-commits
@@ -0,0 +1,223 @@ +// RUN: %clang_cc1 -triple=x86_64-pc-linux-gnu -std=c11 -fsyntax-only -verify -Wformat -Wformat-signedness %s +// RUN: %clang_cc1 -triple=x86_64-pc-win32 -std=c11 -fsyntax-only -verify -Wformat -Wformat-signedness %s + +// Verify that -Wformat-signedness alone

[clang] [llvm] [Sema] Implement support for -Wformat-signedness (PR #74440)

2024-03-26 Thread Aaron Ballman via cfe-commits
@@ -0,0 +1,223 @@ +// RUN: %clang_cc1 -triple=x86_64-pc-linux-gnu -std=c11 -fsyntax-only -verify -Wformat -Wformat-signedness %s +// RUN: %clang_cc1 -triple=x86_64-pc-win32 -std=c11 -fsyntax-only -verify -Wformat -Wformat-signedness %s + +// Verify that -Wformat-signedness alone

[clang] [llvm] [Sema] Implement support for -Wformat-signedness (PR #74440)

2024-03-26 Thread Aaron Ballman via cfe-commits
@@ -0,0 +1,223 @@ +// RUN: %clang_cc1 -triple=x86_64-pc-linux-gnu -std=c11 -fsyntax-only -verify -Wformat -Wformat-signedness %s +// RUN: %clang_cc1 -triple=x86_64-pc-win32 -std=c11 -fsyntax-only -verify -Wformat -Wformat-signedness %s + +// Verify that -Wformat-signedness alone

[clang] [llvm] [Sema] Implement support for -Wformat-signedness (PR #74440)

2024-03-26 Thread Aaron Ballman via cfe-commits
@@ -0,0 +1,223 @@ +// RUN: %clang_cc1 -triple=x86_64-pc-linux-gnu -std=c11 -fsyntax-only -verify -Wformat -Wformat-signedness %s +// RUN: %clang_cc1 -triple=x86_64-pc-win32 -std=c11 -fsyntax-only -verify -Wformat -Wformat-signedness %s + +// Verify that -Wformat-signedness alone

[clang] Fix printing of templated records. (PR #86339)

2024-03-26 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman approved this pull request. Good catch, LGTM! https://github.com/llvm/llvm-project/pull/86339 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Fix __is_array returning true for zero-sized arrays (PR #86652)

2024-03-26 Thread Nikolas Klauser via cfe-commits
philnik777 wrote: > > According to the spec it's ill-formed, so I'm not sure it falls under any > > sensible category. > > It's an extension we support so it's up to us to decide what sensible is. Sure. If we end up putting it in the array category we should probably coordinate with GCC. > >

[clang] [clang] Emit bad shift warnings (PR #70307)

2024-03-26 Thread Aaron Ballman via cfe-commits
@@ -2805,7 +2805,7 @@ static bool handleIntIntBinOp(EvalInfo &Info, const Expr *E, const APSInt &LHS, unsigned SA = (unsigned) RHS.getLimitedValue(LHS.getBitWidth()-1); if (SA != RHS) { Info.CCEDiag(E, diag::note_constexpr_large_shift) -<< RHS << E->getTy

[clang] Fix printing of templated records. (PR #86339)

2024-03-26 Thread Zahira Ammarguellat via cfe-commits
zahiraam wrote: @AaronBallman Thanks! https://github.com/llvm/llvm-project/pull/86339 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix printing of templated records. (PR #86339)

2024-03-26 Thread Zahira Ammarguellat via cfe-commits
https://github.com/zahiraam closed https://github.com/llvm/llvm-project/pull/86339 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 3a2c70b - Fix printing of templated records. (#86339)

2024-03-26 Thread via cfe-commits
Author: Zahira Ammarguellat Date: 2024-03-26T09:06:46-04:00 New Revision: 3a2c70b3713a856ea416d92abdddb7893fca308b URL: https://github.com/llvm/llvm-project/commit/3a2c70b3713a856ea416d92abdddb7893fca308b DIFF: https://github.com/llvm/llvm-project/commit/3a2c70b3713a856ea416d92abdddb7893fca308b

[clang-tools-extra] [clang-tidy] Improve performance of google-runtime-int (PR #86596)

2024-03-26 Thread Julian Schmidt via cfe-commits
https://github.com/5chmidti approved this pull request. LGTM. That's a very nice speedup :) https://github.com/llvm/llvm-project/pull/86596 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-comm

[clang] [llvm] [clang][HLSL][SPRI-V] Add convergence intrinsics (PR #80680)

2024-03-26 Thread Matt Arsenault via cfe-commits
Nathan =?utf-8?q?Gauër?= , Nathan =?utf-8?q?Gauër?= , Nathan =?utf-8?q?Gauër?= , Nathan =?utf-8?q?Gauër?= , Nathan =?utf-8?q?Gauër?= , Nathan =?utf-8?q?Gauër?= , Nathan =?utf-8?q?Gauër?= Message-ID: In-Reply-To: arsenm wrote: > @arsenm would you be fine with those codegen changes as-is? Given

[clang] [clang] Emit bad shift warnings (PR #70307)

2024-03-26 Thread Aaron Ballman via cfe-commits
@@ -11444,9 +11444,12 @@ static void DiagnoseBadShiftValues(Sema& S, ExprResult &LHS, ExprResult &RHS, llvm::APSInt Right = RHSResult.Val.getInt(); if (Right.isNegative()) { -S.DiagRuntimeBehavior(Loc, RHS.get(), - S.PDiag(diag::warn_shift_neg

[clang] [llvm] [clang][HLSL][SPRI-V] Add convergence intrinsics (PR #80680)

2024-03-26 Thread Nathan Gauër via cfe-commits
Keenuts wrote: @ssahasra it is up to you then 😊 https://github.com/llvm/llvm-project/pull/80680 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [clang][HLSL][SPRI-V] Add convergence intrinsics (PR #80680)

2024-03-26 Thread Nathan Gauër via cfe-commits
https://github.com/Keenuts edited https://github.com/llvm/llvm-project/pull/80680 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [InstallAPI] Add *umbrella-header options (PR #86587)

2024-03-26 Thread Cyndy Ishida via cfe-commits
https://github.com/cyndyishida updated https://github.com/llvm/llvm-project/pull/86587 >From 9b25b0486d8f3c8409ee199a9f4695da7780e6cb Mon Sep 17 00:00:00 2001 From: Cyndy Ishida Date: Mon, 25 Mar 2024 17:12:14 -0400 Subject: [PATCH 1/2] [InstallAPI] Add *umbrella-header options Umbrella header

[clang] [Clang] [C++26] Implement P2573R2: `= delete("should have a reason");` (PR #86526)

2024-03-26 Thread via cfe-commits
@@ -873,9 +873,14 @@ void DeclPrinter::VisitFunctionDecl(FunctionDecl *D) { if (D->isPureVirtual()) Out << " = 0"; - else if (D->isDeletedAsWritten()) + else if (D->isDeletedAsWritten()) { Out << " = delete"; - else if (D->isExplicitlyDefaulted()) +if (const

[clang] [Clang] [C++26] Implement P2573R2: `= delete("should have a reason");` (PR #86526)

2024-03-26 Thread via cfe-commits
https://github.com/Sirraide updated https://github.com/llvm/llvm-project/pull/86526 >From 98af47e8ccc633016c14b91c221f9f8fc620f068 Mon Sep 17 00:00:00 2001 From: Sirraide Date: Mon, 25 Mar 2024 14:46:52 +0100 Subject: [PATCH 1/8] [Clang] Parse `= delete("message")` --- clang/include/clang/AST

[clang] [Clang] [C++26] Implement P2573R2: `= delete("should have a reason");` (PR #86526)

2024-03-26 Thread via cfe-commits
https://github.com/Sirraide updated https://github.com/llvm/llvm-project/pull/86526 >From 98af47e8ccc633016c14b91c221f9f8fc620f068 Mon Sep 17 00:00:00 2001 From: Sirraide Date: Mon, 25 Mar 2024 14:46:52 +0100 Subject: [PATCH 1/9] [Clang] Parse `= delete("message")` --- clang/include/clang/AST

[clang] [llvm] [InstallAPI] Add *umbrella-header options (PR #86587)

2024-03-26 Thread Cyndy Ishida via cfe-commits
@@ -424,6 +448,56 @@ InstallAPIContext Options::createContext() { if (!Glob->didMatch()) Diags->Report(diag::warn_glob_did_not_match) << Glob->str(); + // Mark any explicit or inferred umbrella headers. If one exists, move + // that to the beginning of the input he

[clang-tools-extra] [clang-tidy] add new check readability-enum-initial-value (PR #86129)

2024-03-26 Thread Congcong Cai via cfe-commits
@@ -0,0 +1,82 @@ +//===--- EnumInitialValueCheck.cpp - clang-tidy ---===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apa

[clang] ca594fe - Update documentation and release notes for llvm-profgen COFF support (#84864)

2024-03-26 Thread via cfe-commits
Author: Tim Creech Date: 2024-03-26T21:52:36+08:00 New Revision: ca594fedeb3d6bb8ee0f80c92b0089147fb5e757 URL: https://github.com/llvm/llvm-project/commit/ca594fedeb3d6bb8ee0f80c92b0089147fb5e757 DIFF: https://github.com/llvm/llvm-project/commit/ca594fedeb3d6bb8ee0f80c92b0089147fb5e757.diff LO

[clang] [llvm] Update documentation and release notes for llvm-profgen COFF support (PR #84864)

2024-03-26 Thread Wei Xiao via cfe-commits
https://github.com/williamweixiao closed https://github.com/llvm/llvm-project/pull/84864 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Update documentation and release notes for llvm-profgen COFF support (PR #84864)

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

[clang] Fix failure in buildbot, builds/25788. (PR #86661)

2024-03-26 Thread Zahira Ammarguellat via cfe-commits
https://github.com/zahiraam created https://github.com/llvm/llvm-project/pull/86661 None >From 5ef0aca43c2eefbb9967b98c70a58a29a9407e97 Mon Sep 17 00:00:00 2001 From: Zahira Ammarguellat Date: Tue, 26 Mar 2024 06:53:31 -0700 Subject: [PATCH] Fix failure in buildbot, builds/25788. --- clang/l

[clang] Fix failure in buildbot (PR #86661)

2024-03-26 Thread Zahira Ammarguellat via cfe-commits
https://github.com/zahiraam edited https://github.com/llvm/llvm-project/pull/86661 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix failure in buildbot (PR #86661)

2024-03-26 Thread Zahira Ammarguellat via cfe-commits
https://github.com/zahiraam edited https://github.com/llvm/llvm-project/pull/86661 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] [Sema] Fix dependence of DREs in lambdas with an explicit object parameter (PR #84473)

2024-03-26 Thread via cfe-commits
Sirraide wrote: @AaronBallman ping https://github.com/llvm/llvm-project/pull/84473 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 2e38c50 - [clang-repl] Fix remove invalidates iterators in CleanUpPTU() (#85378)

2024-03-26 Thread via cfe-commits
Author: Stefan Gränitz Date: 2024-03-26T15:07:05+01:00 New Revision: 2e38c50e5c53d66d4968fbd47b78e71a220a28ca URL: https://github.com/llvm/llvm-project/commit/2e38c50e5c53d66d4968fbd47b78e71a220a28ca DIFF: https://github.com/llvm/llvm-project/commit/2e38c50e5c53d66d4968fbd47b78e71a220a28ca.diff

[clang] [clang-repl] Fix assertion failure in CleanUpPTU() (PR #85378)

2024-03-26 Thread Stefan Gränitz via cfe-commits
https://github.com/weliveindetail closed https://github.com/llvm/llvm-project/pull/85378 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][OpenMP] Add const-qualified `getIteratorModifier` to OMPMapClause (PR #86666)

2024-03-26 Thread Krzysztof Parzyszek via cfe-commits
https://github.com/kparzysz created https://github.com/llvm/llvm-project/pull/8 NFC >From 3ffabe11eb01f42ceaeb92895a0eb0f251e6ef9a Mon Sep 17 00:00:00 2001 From: Krzysztof Parzyszek Date: Thu, 21 Mar 2024 06:54:02 -0500 Subject: [PATCH] [clang][OpenMP] Add const-qualified `getIteratorModif

[clang] [clang][OpenMP] Add const-qualified `getIteratorModifier` to OMPMapClause (PR #86666)

2024-03-26 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Krzysztof Parzyszek (kparzysz) Changes NFC --- Full diff: https://github.com/llvm/llvm-project/pull/8.diff 1 Files Affected: - (modified) clang/include/clang/AST/OpenMPClause.h (+5) ``diff diff --git a/clang/include/clang

  1   2   3   4   5   >