[clang] [clang][Sema] Fix initialization of `NonTypeTemplateParmDecl`... (PR #121768)

2025-01-24 Thread Erich Keane via cfe-commits
Alejandro =?utf-8?q?Álvarez_Ayllón?=, Alejandro =?utf-8?q?Álvarez_Ayllón?=, Alejandro =?utf-8?q?Álvarez_Ayllón?=, Alejandro =?utf-8?q?Álvarez_Ayllón?=, Alejandro =?utf-8?q?Álvarez_Ayllón?Message-ID: In-Reply-To: @@ -1533,13 +1535,11 @@ class NonTypeTemplateParmDecl final ///

[clang] [Sema] Note member decl when initializer list default constructs member (PR #121854)

2025-01-24 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. https://github.com/llvm/llvm-project/pull/121854 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] __STDC_NO_THREADS__ is no longer necessary for VS 2022 1939 and above (PR #117149)

2025-01-24 Thread Aaron Ballman via cfe-commits
@@ -0,0 +1,13 @@ +// RUN: %clang_cc1 -E -dM -triple=arm64ec-windows-msvc -std=c89 -fms-compatibility-version=19.33 -ffreestanding < /dev/null | FileCheck -check-prefix=C89_MSVC33 %s +// RUN: %clang_cc1 -E -dM -triple=arm64ec-windows-msvc -std=c99 -fms-compatibility-version=19.3

[clang] [clang] __STDC_NO_THREADS__ is no longer necessary for VS 2022 1939 and above (PR #117149)

2025-01-24 Thread Aaron Ballman via cfe-commits
@@ -0,0 +1,13 @@ +// RUN: %clang_cc1 -E -dM -triple=arm64ec-windows-msvc -std=c89 -fms-compatibility-version=19.33 -ffreestanding < /dev/null | FileCheck -check-prefix=C89_MSVC33 %s AaronBallman wrote: There are a few typos in the file name; can you rename it f

[clang] [clang] __STDC_NO_THREADS__ is no longer necessary for VS 2022 1939 and above (PR #117149)

2025-01-24 Thread Aaron Ballman via cfe-commits
@@ -0,0 +1,13 @@ +// RUN: %clang_cc1 -E -dM -triple=arm64ec-windows-msvc -std=c89 -fms-compatibility-version=19.33 -ffreestanding < /dev/null | FileCheck -check-prefix=C89_MSVC33 %s +// RUN: %clang_cc1 -E -dM -triple=arm64ec-windows-msvc -std=c99 -fms-compatibility-version=19.3

[clang] [clang] __STDC_NO_THREADS__ is no longer necessary for VS 2022 1939 and above (PR #117149)

2025-01-24 Thread Aaron Ballman via cfe-commits
@@ -0,0 +1,13 @@ +// RUN: %clang_cc1 -E -dM -triple=arm64ec-windows-msvc -std=c89 -fms-compatibility-version=19.33 -ffreestanding < /dev/null | FileCheck -check-prefix=C89_MSVC33 %s +// RUN: %clang_cc1 -E -dM -triple=arm64ec-windows-msvc -std=c99 -fms-compatibility-version=19.3

[clang] [clang] __STDC_NO_THREADS__ is no longer necessary for VS 2022 1939 and above (PR #117149)

2025-01-24 Thread Aaron Ballman via cfe-commits
@@ -259,8 +259,11 @@ static void addVisualCDefines(const LangOptions &Opts, MacroBuilder &Builder) { Builder.defineMacro("_KERNEL_MODE"); Builder.defineMacro("_INTEGRAL_MAX_BITS", "64"); - Builder.defineMacro("__STDC_NO_THREADS__"); - + // Define __STDC_NO_THREADS__ b

[clang] [clang] __STDC_NO_THREADS__ is no longer necessary for VS 2022 1939 and above (PR #117149)

2025-01-24 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman commented: I found a few minor nits, but I think we're pretty close! https://github.com/llvm/llvm-project/pull/117149 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinf

[clang] [clang] __STDC_NO_THREADS__ is no longer necessary for VS 2022 1939 and above (PR #117149)

2025-01-24 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman edited https://github.com/llvm/llvm-project/pull/117149 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][ASTImporter] Fix possible crash at import of function template (PR #124273)

2025-01-24 Thread Balázs Kéri via cfe-commits
https://github.com/balazske created https://github.com/llvm/llvm-project/pull/124273 During import of a function template at specific conditions an assertion "TemplateOrSpecialization.isNull()" can be triggered. This can happen when the new AST is already incompatible after import failures. Prob

[clang] [Clang] raise extension warning for unknown namespaced attributes (PR #120925)

2025-01-24 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > > Thanks for this patch. > > Sorry I did not see this sooner. > > I am not convinced this the best way to resolve #120875 - and I suspect in > > practice it would be a bit difficult to use/be under used. > > I'm not convinced here? I think a flag that says "warn me about u

[clang] [compiler-rt] [llvm] [FMV][AArch64] Remove features predres and ls64. (PR #124266)

2025-01-24 Thread Daniel Kiss via cfe-commits
https://github.com/DanielKristofKiss approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/124266 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [experimental] Detect return-stack-addr using CFG (PR #124133)

2025-01-24 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 updated https://github.com/llvm/llvm-project/pull/124133 >From 22990789b61e9f9d22e88a6b008eb3166fd1cb56 Mon Sep 17 00:00:00 2001 From: Utkarsh Saxena Date: Thu, 23 Jan 2025 15:47:39 + Subject: [PATCH 1/3] [experimental] Detect return-stack-addr using CFG --- .../A

[clang] [Clang] raise extension warning for unknown namespaced attributes (PR #120925)

2025-01-24 Thread Erich Keane via cfe-commits
erichkeane wrote: >That's how this already works in this patch: AH! I missed that this was doing that. Awesome! Though I think the 'no' flag is the one that makes sense in a "turn it on for all BUT these". The flag as typed there isn't particularly useful (that is, ONLY warn me for the ones t

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

2025-01-24 Thread Gabriel Baraldi via cfe-commits
gbaraldi wrote: Bump. For reference, this is holding julia to an older LLVM version than needed ;) https://github.com/llvm/llvm-project/pull/122330 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/

[clang] [Clang] Add -fwrapv-pointer flag (PR #122486)

2025-01-24 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: I am a bit concerned about the behavioral change, but given the more aggressive optimizations in LLVM 20, I think it makes sense to get this into Clang 20 to see what the fallout is during early RCs. If there's negative impact, we can consider cherry-picking a revert from t

[clang] [flang] [flang][driver] add negative from of -fsave-main-program (PR #124110)

2025-01-24 Thread via cfe-commits
https://github.com/jeanPerier updated https://github.com/llvm/llvm-project/pull/124110 >From 28dba56b12b45f8ce82426e2b79165352f549850 Mon Sep 17 00:00:00 2001 From: Jean Perier Date: Thu, 23 Jan 2025 04:37:30 -0800 Subject: [PATCH 1/3] [flang][driver] add negative from of -fsave-main-program -

[clang] [Clang] Add -fwrapv-pointer flag (PR #122486)

2025-01-24 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman commented: The changes look correct to me, but I'd love to hear from the codegen and sanitizer experts as to whether they agree with the changes and the timeline to land it for 20. https://github.com/llvm/llvm-project/pull/122486

[clang] [Clang] Add -fwrapv-pointer flag (PR #122486)

2025-01-24 Thread Aaron Ballman via cfe-commits
@@ -57,15 +57,6 @@ void test1(void) { // TRAPV_HANDLER: foo( --a; - // -fwrapv should turn off inbounds for GEP's, PR9256 - extern int* P; - ++P; - // DEFAULT: getelementptr inbounds nuw i32, ptr - // WRAPV: getelementptr i32, ptr - // TRAPV: getelementptr inbounds

[clang] [Clang] Add -fwrapv-pointer flag (PR #122486)

2025-01-24 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman edited https://github.com/llvm/llvm-project/pull/122486 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] raise extension warning for unknown namespaced attributes (PR #120925)

2025-01-24 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > > That's how this already works in this patch: > > AH! I missed that this was doing that. Awesome! Though I think the 'no' > > flag is the one that makes sense in a "turn it on for all BUT these". The > > flag as typed there isn't particularly useful (that is, ONLY warn

[clang] [flang] [flang][driver] add negative from of -fsave-main-program (PR #124110)

2025-01-24 Thread via cfe-commits
@@ -6968,8 +6968,11 @@ defm unsigned : OptInFC1FFlag<"unsigned", "Enables UNSIGNED type">; def fno_automatic : Flag<["-"], "fno-automatic">, Group, HelpText<"Implies the SAVE attribute for non-automatic local objects in subprograms unless RECURSIVE">; -def fsave_main_progr

[clang] [clang][docs] Update bytecode interpreter docs (PR #124252)

2025-01-24 Thread via cfe-commits
https://github.com/yronglin approved this pull request. LGTM! https://github.com/llvm/llvm-project/pull/124252 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] raise extension warning for unknown namespaced attributes (PR #120925)

2025-01-24 Thread Erich Keane via cfe-commits
erichkeane wrote: > > > That's how this already works in this patch: > > > AH! I missed that this was doing that. Awesome! Though I think the 'no' > > > flag is the one that makes sense in a "turn it on for all BUT these". The > > > flag as typed there isn't particularly useful (that is, ONLY

[clang] [clang-format] Add null-terminated path option (#123921) (PR #123926)

2025-01-24 Thread Nikolaos Chatzikonstantinou via cfe-commits
@@ -205,6 +205,12 @@ def main(): "commits" ), ) +p.add_argument( +"-0", +"--null", +action="store_true", +help="print the affected paths with null-terminated characters", createyourpersonalaccount wrot

[clang-tools-extra] [clang-tidy][NFC] simplify `TimerGroup` in `ClangTidyProfiling` (PR #123958)

2025-01-24 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 closed https://github.com/llvm/llvm-project/pull/123958 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] 8e6d6a5 - [clang-tidy][NFC] improve performance misc-unused-using-decls (#123454)

2025-01-24 Thread via cfe-commits
Author: Congcong Cai Date: 2025-01-24T19:32:11+08:00 New Revision: 8e6d6a55108c7979f0392bf8ad3444c92a2474e9 URL: https://github.com/llvm/llvm-project/commit/8e6d6a55108c7979f0392bf8ad3444c92a2474e9 DIFF: https://github.com/llvm/llvm-project/commit/8e6d6a55108c7979f0392bf8ad3444c92a2474e9.diff

[clang-tools-extra] [clang-tidy][NFC] improve performance misc-unused-using-decls (PR #123454)

2025-01-24 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 closed https://github.com/llvm/llvm-project/pull/123454 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Add null-terminated path option (#123921) (PR #123926)

2025-01-24 Thread Nikolaos Chatzikonstantinou via cfe-commits
https://github.com/createyourpersonalaccount updated https://github.com/llvm/llvm-project/pull/123926 >From 9dfbb9a3cc7f6bc557bc1ccf25cc727a02c4274c Mon Sep 17 00:00:00 2001 From: Nikolaos Chatzikonstantinou Date: Wed, 22 Jan 2025 05:43:02 -0500 Subject: [PATCH 1/2] [clang-format] Add null-term

[clang] [llvm] [Clang] restrict use of attribute names reserved by the C++ standard (PR #106036)

2025-01-24 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `premerge-monolithic-linux` running on `premerge-linux-1` while building `clang,llvm,utils` at step 7 "test-build-unified-tree-check-all". Full details are available at: https://lab.llvm.org/buildbot/#/builders/153/builds/2072

[clang] [llvm] [mlir] [TableGen] Only store direct superclasses in Record (PR #123072)

2025-01-24 Thread Jay Foad via cfe-commits
@@ -1630,9 +1630,9 @@ class Record { SmallVector Assertions; SmallVector Dumps; - // All superclasses in the inheritance forest in post-order (yes, it + // Direct superclasses, which are roots of the inheritance forest (yes, it // must be a forest; diamond-shaped inhe

[clang] [clang][docs] Update bytecode interpreter docs (PR #124252)

2025-01-24 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/124252 Just a light update, not adding a lot of new information. >From 46fc5380ca92e80fc9c7d968f82c8e83eb632aee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Fri, 24 Jan 2025 11:33:24 +0100 Subje

[clang] [clang][docs] Update bytecode interpreter docs (PR #124252)

2025-01-24 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes Just a light update, not adding a lot of new information. --- Full diff: https://github.com/llvm/llvm-project/pull/124252.diff 2 Files Affected: - (modified) clang/docs/ConstantInterpreter.rst (+16-103) -

[clang] [clang][Sema] Fix initialization of `NonTypeTemplateParmDecl`... (PR #121768)

2025-01-24 Thread Alejandro Álvarez Ayllón via cfe-commits
@@ -1533,13 +1535,11 @@ class NonTypeTemplateParmDecl final /// Return the constraint introduced by the placeholder type of this non-type /// template parameter (if any). Expr *getPlaceholderTypeConstraint() const { -return hasPlaceholderTypeConstraint() ? *getTrailin

[clang] [llvm] [polly] [NFC][DebugInfo] Use iterator-flavour getFirstNonPHI at many call-sites (PR #123737)

2025-01-24 Thread Jeremy Morse via cfe-commits
jmorse wrote: > Regarding the direction of the patch, it seems a little unfortunate to > completely remove getFirstNonPHI() - sometimes we want the instruction and > sometimes we want the iterator, and forcing all of them to go through > getFirstNonPHIIt() may increase the chances that the it

[clang] [llvm] [polly] [NFC][DebugInfo] Use iterator-flavour getFirstNonPHI at many call-sites (PR #123737)

2025-01-24 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse updated https://github.com/llvm/llvm-project/pull/123737 >From 36f969cc26363da7a6a109538d27af2c1d4f59f8 Mon Sep 17 00:00:00 2001 From: Jeremy Morse Date: Fri, 17 Jan 2025 17:49:05 + Subject: [PATCH 1/3] [NFC][DebugInfo] Use iterator-flavour getFirstNonPHI at many

[clang] 6292a80 - [NFC][DebugInfo] Use iterator-flavour getFirstNonPHI at many call-sites (#123737)

2025-01-24 Thread via cfe-commits
Author: Jeremy Morse Date: 2025-01-24T13:27:56Z New Revision: 6292a808b3524d9ba6f4ce55bc5b9e547b088dd8 URL: https://github.com/llvm/llvm-project/commit/6292a808b3524d9ba6f4ce55bc5b9e547b088dd8 DIFF: https://github.com/llvm/llvm-project/commit/6292a808b3524d9ba6f4ce55bc5b9e547b088dd8.diff LOG:

[clang] [llvm] [polly] [NFC][DebugInfo] Use iterator-flavour getFirstNonPHI at many call-sites (PR #123737)

2025-01-24 Thread Jeremy Morse via cfe-commits
https://github.com/jmorse closed https://github.com/llvm/llvm-project/pull/123737 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [clang][DebugInfo] Emit DW_AT_object_pointer on function declarations with explicit `this` (PR #122928)

2025-01-24 Thread Mats Jun Larsen via cfe-commits
junlarsen wrote: I wasn't aware of that exception either, so my apologies there. I still think it's fair policy to keep things as compatible if easily possible though. https://github.com/llvm/llvm-project/pull/122928 ___ cfe-commits mailing list cfe-c

[clang] [Clang] Add -fwrapv-pointer flag (PR #122486)

2025-01-24 Thread Nikita Popov via cfe-commits
https://github.com/nikic updated https://github.com/llvm/llvm-project/pull/122486 >From 925f74cad21eb6c46514d1ae543ac202073baf27 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Fri, 10 Jan 2025 17:01:07 +0100 Subject: [PATCH 1/2] [Clang] Add -fwrapv-pointer flag GCC supports three flags rela

[clang] [Clang] Add -fwrapv-pointer flag (PR #122486)

2025-01-24 Thread Nikita Popov via cfe-commits
https://github.com/nikic updated https://github.com/llvm/llvm-project/pull/122486 >From 925f74cad21eb6c46514d1ae543ac202073baf27 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Fri, 10 Jan 2025 17:01:07 +0100 Subject: [PATCH 1/2] [Clang] Add -fwrapv-pointer flag GCC supports three flags rela

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2025-01-24 Thread Stephen Tozer via cfe-commits
@@ -3595,15 +3595,26 @@ static llvm::StoreInst *findDominatingStoreToReturnValue(CodeGenFunction &CGF) { llvm::BasicBlock *IP = CGF.Builder.GetInsertBlock(); if (IP->empty()) return nullptr; -// Look at directly preceding instruction, skipping bitcasts and lifetim

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2025-01-24 Thread Stephen Tozer via cfe-commits
https://github.com/SLTozer edited https://github.com/llvm/llvm-project/pull/110102 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [flang][driver] add negative from of -fsave-main-program (PR #124110)

2025-01-24 Thread Tarun Prabhu via cfe-commits
https://github.com/tarunprabhu approved this pull request. LGTM. Thanks! https://github.com/llvm/llvm-project/pull/124110 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [flang][driver] add negative from of -fsave-main-program (PR #124110)

2025-01-24 Thread Tarun Prabhu via cfe-commits
@@ -6968,8 +6968,11 @@ defm unsigned : OptInFC1FFlag<"unsigned", "Enables UNSIGNED type">; def fno_automatic : Flag<["-"], "fno-automatic">, Group, HelpText<"Implies the SAVE attribute for non-automatic local objects in subprograms unless RECURSIVE">; -def fsave_main_progr

[clang] [Clang] Add fake use emission to Clang with -fextend-lifetimes (PR #110102)

2025-01-24 Thread Paul T Robinson via cfe-commits
@@ -87,6 +87,10 @@ class EHScope { LLVM_PREFERRED_TYPE(bool) unsigned IsLifetimeMarker : 1; +/// Whether this cleanup is a fake use pogo59 wrote: Full-stop at the end https://github.com/llvm/llvm-project/pull/110102 __

[clang] [Clang] Add -fwrapv-pointer flag (PR #122486)

2025-01-24 Thread Fangrui Song via cfe-commits
@@ -1,11 +1,24 @@ // RUN: %clang -### -S -fwrapv -fno-wrapv -fwrapv %s 2>&1 | FileCheck -check-prefix=CHECK1 %s // CHECK1: -fwrapv // +// RUN: %clang -### -S -fwrapv-pointer -fno-wrapv-pointer -fwrapv-pointer %s 2>&1 | FileCheck -check-prefix=CHECK1-POINTER %s +// CHECK1-POIN

[clang] [clang][ASTImporter] Fix possible crash at import of function template (PR #124273)

2025-01-24 Thread Michael Buch via cfe-commits
=?utf-8?q?Balázs_Kéri?= Message-ID: In-Reply-To: https://github.com/Michael137 commented: So in spirit this is kind of like an ODR violation right? Which the ASTImporter does try to handle, so this seems reasonable to me. For my own understanding, where did the crash end up happening? Also,

[clang] [Clang] Add -fwrapv-pointer flag (PR #122486)

2025-01-24 Thread Nikita Popov via cfe-commits
@@ -57,15 +57,6 @@ void test1(void) { // TRAPV_HANDLER: foo( --a; - // -fwrapv should turn off inbounds for GEP's, PR9256 - extern int* P; - ++P; - // DEFAULT: getelementptr inbounds nuw i32, ptr - // WRAPV: getelementptr i32, ptr - // TRAPV: getelementptr inbounds

[clang] [llvm] [WIP][RISCV] Support for Zvabd fast-track proposal (PR #124239)

2025-01-24 Thread Craig Topper via cfe-commits
https://github.com/topperc edited https://github.com/llvm/llvm-project/pull/124239 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [WIP][RISCV] Support for Zvabd fast-track proposal (PR #124239)

2025-01-24 Thread Craig Topper via cfe-commits
@@ -29,6 +29,7 @@ #include "llvm/CodeGen/MachineJumpTableInfo.h" #include "llvm/CodeGen/MachineRegisterInfo.h" #include "llvm/CodeGen/SelectionDAGAddressAnalysis.h" +#include "llvm/CodeGen/SelectionDAGNodes.h" topperc wrote: what's special about this patch tha

[clang] [Clang] Add -fwrapv-pointer flag (PR #122486)

2025-01-24 Thread Nikita Popov via cfe-commits
https://github.com/nikic updated https://github.com/llvm/llvm-project/pull/122486 >From 925f74cad21eb6c46514d1ae543ac202073baf27 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Fri, 10 Jan 2025 17:01:07 +0100 Subject: [PATCH 1/3] [Clang] Add -fwrapv-pointer flag GCC supports three flags rela

[clang] [Clang] Add -fwrapv-pointer flag (PR #122486)

2025-01-24 Thread Nikita Popov via cfe-commits
@@ -1,11 +1,24 @@ // RUN: %clang -### -S -fwrapv -fno-wrapv -fwrapv %s 2>&1 | FileCheck -check-prefix=CHECK1 %s // CHECK1: -fwrapv // +// RUN: %clang -### -S -fwrapv-pointer -fno-wrapv-pointer -fwrapv-pointer %s 2>&1 | FileCheck -check-prefix=CHECK1-POINTER %s +// CHECK1-POIN

[clang] [llvm] [LLVM][Clang][AArch64] Implement AArch64 build attributes (PR #118771)

2025-01-24 Thread via cfe-commits
@@ -0,0 +1,117 @@ +//===-- AArch64BuildAttributes.cpp - AArch64 Build Attributes -===// +// +// 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: Ap

[clang] [llvm] [HLSL][SPIRV][DXIL] Implement `WaveActiveMax` intrinsic (PR #123428)

2025-01-24 Thread Adam Yang via cfe-commits
@@ -0,0 +1,55 @@ +; RUN: llc -verify-machineinstrs -O0 -mtriple=spirv-vulkan-unknown %s -o - | FileCheck %s +; RUN: %if spirv-tools %{ llc -O0 -mtriple=spirv-vulkan-unknown %s -o - -filetype=obj | spirv-val %} + +; Test lowering to spir-v backend for various types and scalar/vec

[clang] [llvm] [HLSL][SPIRV][DXIL] Implement `WaveActiveMax` intrinsic (PR #123428)

2025-01-24 Thread Adam Yang via cfe-commits
@@ -2132,6 +2135,33 @@ bool SPIRVInstructionSelector::selectWaveActiveCountBits( return Result; } +bool SPIRVInstructionSelector::selectWaveReduceMax(Register ResVReg, + const SPIRVType *ResType, +

[clang] [llvm] [HLSL][SPIRV][DXIL] Implement `WaveActiveMax` intrinsic (PR #123428)

2025-01-24 Thread Adam Yang via cfe-commits
https://github.com/adam-yang updated https://github.com/llvm/llvm-project/pull/123428 >From 9a0cf138d99ebc9ae18db054b4d8eaa34e8174a8 Mon Sep 17 00:00:00 2001 From: Adam Yang <31109344+adam-y...@users.noreply.github.com> Date: Fri, 17 Jan 2025 16:14:44 -0800 Subject: [PATCH 1/4] Added WaveActiveM

[clang] 4ea44eb - [WebAssembly] Fix EH feature flags when compiling multiple files (#124374)

2025-01-24 Thread via cfe-commits
Author: Heejin Ahn Date: 2025-01-24T16:56:26-08:00 New Revision: 4ea44eb1e292369b0b3f2f8ad4680081558f1e01 URL: https://github.com/llvm/llvm-project/commit/4ea44eb1e292369b0b3f2f8ad4680081558f1e01 DIFF: https://github.com/llvm/llvm-project/commit/4ea44eb1e292369b0b3f2f8ad4680081558f1e01.diff LO

[clang] [HLSL] Introduce address space `hlsl_constant(2)` for constant buffer declarations (PR #123411)

2025-01-24 Thread Helena Kotas via cfe-commits
https://github.com/hekota closed https://github.com/llvm/llvm-project/pull/123411 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [WebAssembly] Fix EH feature flags when compiling multiple files (PR #124374)

2025-01-24 Thread Heejin Ahn via cfe-commits
https://github.com/aheejin closed https://github.com/llvm/llvm-project/pull/124374 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [OpenMP] Replace nvvm.annotation usage with kernel calling conventions (PR #122320)

2025-01-24 Thread Alex MacLean via cfe-commits
https://github.com/AlexMaclean closed https://github.com/llvm/llvm-project/pull/122320 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] bug fix for pp-trace (PR #124376)

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

[clang] [PGO] Add a clang option -fprofile-continuous that enables PGO continuous mode (PR #124353)

2025-01-24 Thread Wael Yehia via cfe-commits
@@ -3033,6 +3033,14 @@ indexed format, regardeless whether it is produced by frontend or the IR pass. overhead. ``prefer-atomic`` will be transformed to ``atomic`` when supported by the target, or ``single`` otherwise. +.. option:: -fprofile-continuous w2

[clang] [PGO] Add a clang option -fprofile-continuous that enables PGO continuous mode (PR #124353)

2025-01-24 Thread Wael Yehia via cfe-commits
@@ -3033,6 +3033,14 @@ indexed format, regardeless whether it is produced by frontend or the IR pass. overhead. ``prefer-atomic`` will be transformed to ``atomic`` when supported by the target, or ``single`` otherwise. +.. option:: -fprofile-continuous w2

[clang] [clang][bytecode] Fix dummy handling for p2280r4 (PR #124396)

2025-01-24 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes This makes some other problems show up like the fact that we didn't suppress diagnostics during __builtin_constant_p evaluation. --- Full diff: https://github.com/llvm/llvm-project/pull/124396.diff 8 Files

[clang] [TySan] Add initial documentation for Type Sanitizer (PR #123595)

2025-01-24 Thread Vitaly Buka via cfe-commits
vitalybuka wrote: Maybe paragraph or link to a doc about how it works can be useful? Basic understanding of algorithm may help users to avoid false expectations. https://github.com/llvm/llvm-project/pull/123595 ___ cfe-commits mailing list cfe-commits

[clang] [Clang] use constant evaluation context for constexpr if conditions (PR #123667)

2025-01-24 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 edited https://github.com/llvm/llvm-project/pull/123667 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Treat uppercase identifiers after struct as macros (PR #124397)

2025-01-24 Thread Owen Pan via cfe-commits
https://github.com/owenca created https://github.com/llvm/llvm-project/pull/124397 This restores the behavior before llvmorg-20-init. Fixes #94184. >From e0567ce91a07df1b9a497adb63d5842441855d92 Mon Sep 17 00:00:00 2001 From: Owen Pan Date: Fri, 24 Jan 2025 22:47:26 -0800 Subject: [PATCH] [cl

[clang] [Clang][Sema] Reject declaring an alias template with the same name as its template parameter. (PR #123533)

2025-01-24 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 approved this pull request. Thanks! https://github.com/llvm/llvm-project/pull/123533 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Treat uppercase identifiers after struct as macros (PR #124397)

2025-01-24 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Author: Owen Pan (owenca) Changes This restores the behavior before llvmorg-20-init. Fixes #94184. --- Full diff: https://github.com/llvm/llvm-project/pull/124397.diff 2 Files Affected: - (modified) clang/lib/Format/UnwrappedLineParser.

[clang] [Clang] use constant evaluation context for constexpr if conditions (PR #123667)

2025-01-24 Thread Younan Zhang via cfe-commits
@@ -977,6 +977,7 @@ Bug Fixes to C++ Support - Fix immediate escalation not propagating through inherited constructors. (#GH112677) - Fixed assertions or false compiler diagnostics in the case of C++ modules for lambda functions or inline friend functions defined inside tem

[clang] [clang][bytecode] Fix dummy handling for p2280r4 (PR #124396)

2025-01-24 Thread via cfe-commits
gsfuds wrote: Impressive work! This change looks like it will significantly improve the project. Excited to see it move forward!https://mtoolshub.com https://github.com/llvm/llvm-project/pull/124396 ___ cfe-commits mailing list cfe-commits@lists.llvm.

[clang] [Clang][Sema] Reject declaring an alias template with the same name as its template parameter. (PR #123533)

2025-01-24 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 closed https://github.com/llvm/llvm-project/pull/123533 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] f607e3f - [Clang][Sema] Reject declaring an alias template with the same name as its template parameter. (#123533)

2025-01-24 Thread via cfe-commits
Author: Valentyn Yukhymenko Date: 2025-01-25T15:01:40+08:00 New Revision: f607e3fd23ef0019b2f3b289b4d46012400b8db5 URL: https://github.com/llvm/llvm-project/commit/f607e3fd23ef0019b2f3b289b4d46012400b8db5 DIFF: https://github.com/llvm/llvm-project/commit/f607e3fd23ef0019b2f3b289b4d46012400b8db5

[clang] [clang][bytecode] Fix dummy handling for p2280r4 (PR #124396)

2025-01-24 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/124396 This makes some other problems show up like the fact that we didn't suppress diagnostics during __builtin_constant_p evaluation. >From 9abf895d97fe1a5be80e3ae73cd906eb104453fe Mon Sep 17 00:00:00 2001 From: =?

[clang] [Clang][Sema] Reject declaring an alias template with the same name as its template parameter. (PR #123533)

2025-01-24 Thread via cfe-commits
github-actions[bot] wrote: @BaLiKfromUA 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 bu

[clang] [Clang][Sema] Reject declaring an alias template with the same name as its template parameter. (PR #123533)

2025-01-24 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `openmp-offload-libc-amdgpu-runtime` running on `omp-vega20-1` while building `clang` at step 7 "Add check check-offload". Full details are available at: https://lab.llvm.org/buildbot/#/builders/73/builds/12403 Here is the r

[clang] [clang-format] Handle AttributeMacros in parseRecord() (PR #94189)

2025-01-24 Thread Owen Pan via cfe-commits
owenca wrote: > As noted in the issue, I think it should also keep working without the > attribute macro. (I'd be fine with the all upper case is a macro heuristic.) See #124397. https://github.com/llvm/llvm-project/pull/94189 ___ cfe-commits mailing

[clang] [clang] Fix a use-after-free in expression evaluation (PR #118480)

2025-01-24 Thread Shafik Yaghmour via cfe-commits
shafik wrote: ping, is this still a problem? https://github.com/llvm/llvm-project/pull/118480 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][docs] Fix typos concerning wasm __funcref (PR #124365)

2025-01-24 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timothy Herchen (anematode) Changes The docs conflate `__funcref` with an actual type in a couple places. --- Full diff: https://github.com/llvm/llvm-project/pull/124365.diff 1 Files Affected: - (modified) clang/docs/LanguageExtensions.

[clang] [clang][Sema] Fix type of an statement expression ending with an atomic type (PR #119711)

2025-01-24 Thread Shafik Yaghmour via cfe-commits
Alejandro =?utf-8?q?=C3=81lvarez_Ayll=C3=B3n?=, Alejandro =?utf-8?q?=C3=81lvarez_Ayll=C3=B3n?=, Alejandro =?utf-8?q?=C3=81lvarez_Ayll=C3=B3n?= Message-ID: In-Reply-To: https://github.com/shafik commented: This looks about right to me but I would like another set of eyes. https://github.com/llv

[clang] [HLSL] Introduce address space `hlsl_constant(2)` for constant buffer declarations (PR #123411)

2025-01-24 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `flang-aarch64-dylib` running on `linaro-flang-aarch64-dylib` while building `clang` at step 5 "build-unified-tree". Full details are available at: https://lab.llvm.org/buildbot/#/builders/50/builds/9388 Here is the relevant

[clang] 8e31050 - [clang-format] Fix a bug in annotating overloaded co_await decl (#124240)

2025-01-24 Thread via cfe-commits
Author: Owen Pan Date: 2025-01-24T17:57:04-08:00 New Revision: 8e31050bc2e02d7a3c654def7d7af899ce1cdb1d URL: https://github.com/llvm/llvm-project/commit/8e31050bc2e02d7a3c654def7d7af899ce1cdb1d DIFF: https://github.com/llvm/llvm-project/commit/8e31050bc2e02d7a3c654def7d7af899ce1cdb1d.diff LOG:

[clang] [clang-format] Fix a crash on comment after TableGen l_paren (PR #124380)

2025-01-24 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Author: Owen Pan (owenca) Changes Fixes #124248. --- Full diff: https://github.com/llvm/llvm-project/pull/124380.diff 2 Files Affected: - (modified) clang/lib/Format/TokenAnnotator.cpp (+4-6) - (modified) clang/unittests/Format/FormatTe

[clang] [clang-format] Fix a bug in annotating overloaded co_await decl (PR #124240)

2025-01-24 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `openmp-offload-libc-amdgpu-runtime` running on `omp-vega20-1` while building `clang` at step 7 "Add check check-offload". Full details are available at: https://lab.llvm.org/buildbot/#/builders/73/builds/12400 Here is the r

[clang] [clang-format] Fix a crash on comment after TableGen l_paren (PR #124380)

2025-01-24 Thread Owen Pan via cfe-commits
https://github.com/owenca created https://github.com/llvm/llvm-project/pull/124380 Fixes #124248. >From 5b45be664597788137686c1b374f362f23e06d78 Mon Sep 17 00:00:00 2001 From: Owen Pan Date: Fri, 24 Jan 2025 18:07:05 -0800 Subject: [PATCH] [clang-format] Fix a crash on comment after TableGen l

[clang] [clang-format] Fix a TableGen crash on comment after l_paren (PR #124380)

2025-01-24 Thread Owen Pan via cfe-commits
https://github.com/owenca edited https://github.com/llvm/llvm-project/pull/124380 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [WebAssembly] Fix EH feature flags when compiling multiple files (PR #124374)

2025-01-24 Thread Heejin Ahn via cfe-commits
https://github.com/aheejin created https://github.com/llvm/llvm-project/pull/124374 #124042 caused a problem that when invoking `clang` with multiple files, the static `HasRun` variables were set when processing the first file so the appropriate feature flags were not added from the second fi

[clang] [llvm] [HLSL][SPIRV][DXIL] Implement `WaveActiveMax` intrinsic (PR #123428)

2025-01-24 Thread Adam Yang via cfe-commits
@@ -0,0 +1,143 @@ +; RUN: opt -S -scalarizer -dxil-op-lower -mtriple=dxil-pc-shadermodel6.3-library < %s | FileCheck %s + +; Test that for scalar values, WaveActiveMax maps down to the DirectX op + +define noundef half @wave_active_max_half(half noundef %expr) { +entry: +; CHECK:

[clang] [WebAssembly] Fix EH feature flags when compiling multiple files (PR #124374)

2025-01-24 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Heejin Ahn (aheejin) Changes #124042 caused a problem that when invoking `clang` with multiple files, the static `HasRun` variables were set when processing the first file so the appropriate feature flags were not added from the second f

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

2025-01-24 Thread Pranav Kant via cfe-commits
pranavk wrote: > Shouldn't this have some sort of Release not maybe under the X86 section? you mean mention this in release section? I plan to add a note in clang/docs/ReleaseNotes.rst. Next week. https://github.com/llvm/llvm-project/pull/120670 ___

[clang] [clang][docs] Fix typos concerning wasm __funcref (PR #124365)

2025-01-24 Thread Timothy Herchen via cfe-commits
https://github.com/anematode created https://github.com/llvm/llvm-project/pull/124365 The docs conflate `__funcref` with an actual type in a couple places. >From 2508da6fd7f38101011573460724f13df1c1616d Mon Sep 17 00:00:00 2001 From: Timothy Herchen Date: Fri, 24 Jan 2025 15:13:30 -0800 Subjec

[clang] [Clang][OpenCL][AMDGPU] Allow a kernel to call another kernel (PR #115821)

2025-01-24 Thread John McCall via cfe-commits
@@ -5692,7 +5692,10 @@ CGCallee CodeGenFunction::EmitCallee(const Expr *E) { // Resolve direct calls. } else if (auto DRE = dyn_cast(E)) { if (auto FD = dyn_cast(DRE->getDecl())) { - return EmitDirectCallee(*this, FD); + auto CalleeDecl = FD->hasAttr() +

[clang] [Clang][Sema] Reject declaring an alias template with the same name as its template parameter. (PR #123533)

2025-01-24 Thread Valentyn Yukhymenko via cfe-commits
https://github.com/BaLiKfromUA updated https://github.com/llvm/llvm-project/pull/123533 >From e451a8869420d9240f9006eb2adb599a3e6fd9f8 Mon Sep 17 00:00:00 2001 From: Valentyn Yukhymenko Date: Sun, 19 Jan 2025 23:13:46 + Subject: [PATCH 1/5] [Clang] Reject declaring an alias template with th

[clang] [llvm] [HLSL][SPIRV][DXIL] Implement `WaveActiveMax` intrinsic (PR #123428)

2025-01-24 Thread Adam Yang via cfe-commits
https://github.com/adam-yang updated https://github.com/llvm/llvm-project/pull/123428 >From 055412fd8d01d796ca070fafeca4375fd442986a Mon Sep 17 00:00:00 2001 From: Adam Yang <31109344+adam-y...@users.noreply.github.com> Date: Fri, 17 Jan 2025 16:14:44 -0800 Subject: [PATCH 1/5] Added WaveActiveM

[clang] [AST] Migrate away from PointerUnion::dyn_cast (NFC) (PR #124388)

2025-01-24 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/124388 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [Index] Migrate away from PointerUnion::dyn_cast (NFC) (PR #124389)

2025-01-24 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Kazu Hirata (kazutakahirata) Changes Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Litera

[clang] [Index] Migrate away from PointerUnion::dyn_cast (NFC) (PR #124389)

2025-01-24 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/124389 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [AST] Migrate away from PointerUnion::dyn_cast (NFC) (PR #124388)

2025-01-24 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Kazu Hirata (kazutakahirata) Changes Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Litera

[clang] [Sema] Migrate away from PointerUnion::dyn_cast (NFC) (PR #124391)

2025-01-24 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/124391 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

<    1   2   3   4   >