[clang] Implement the `fmod` intrinsic (PR #130320)

2025-03-07 Thread Deric C. via cfe-commits
@@ -22,56 +22,136 @@ // // RUN: %clang_cc1 -finclude-default-header -x hlsl -triple \ // RUN: spirv-unknown-vulkan-compute %s -fnative-half-type \ -// RUN: -emit-llvm -disable-llvm-passes -o - | FileCheck %s \ -// RUN: -DFNATTRS="spir_func noundef nofpclass(nan inf)" -DTY

[clang] [libclang/python] Add equality comparison operators for File (PR #130383)

2025-03-07 Thread Jannick Kremer via cfe-commits
DeinAlptraum wrote: @Endilll do you understand where this test failure might come from? It passes for me locally... https://github.com/llvm/llvm-project/pull/130383 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin

[clang] Implement the `fmod` intrinsic (PR #130320)

2025-03-07 Thread Deric C. via cfe-commits
https://github.com/Icohedron edited https://github.com/llvm/llvm-project/pull/130320 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] select scalar overloads for vector conditions (PR #129396)

2025-03-07 Thread Farzon Lotfi via cfe-commits
@@ -0,0 +1,71 @@ +//===- hlsl_intrinsic_helpers.h - HLSL helpers intrinsics -===// +// +// 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] [HLSL] select scalar overloads for vector conditions (PR #129396)

2025-03-07 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl edited https://github.com/llvm/llvm-project/pull/129396 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] select scalar overloads for vector conditions (PR #129396)

2025-03-07 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl approved this pull request. https://github.com/llvm/llvm-project/pull/129396 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Support] Remove output file checks from `LockFileManager` (PR #130395)

2025-03-07 Thread Jan Svoboda via cfe-commits
https://github.com/jansvoboda11 created https://github.com/llvm/llvm-project/pull/130395 Currently, `LockFileManager` assumes the owner of the lock file creates an output file. This is problematic for at least three reasons: 1. It is orthogonal to the main purpose of this class - mutual exclus

[clang] [llvm] [Support] Remove output file checks from `LockFileManager` (PR #130395)

2025-03-07 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-llvm-support Author: Jan Svoboda (jansvoboda11) Changes Currently, `LockFileManager` assumes the owner of the lock file creates an output file. This is problematic for at least three reasons: 1. It is orthogonal to the main purpose of this class - mutu

[clang] disable unary, vector mask (PR #130400)

2025-03-07 Thread via cfe-commits
https://github.com/wsehjk created https://github.com/llvm/llvm-project/pull/130400 This pr is to fix #92342. >From a6ca9cc820e98b093215b1bd0787d4fa3d31742d Mon Sep 17 00:00:00 2001 From: wang shiwen Date: Sat, 8 Mar 2025 15:40:22 +0800 Subject: [PATCH] disable unary, vector mask --- clang/l

[clang] disable unary, vector mask (PR #130400)

2025-03-07 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-tools-extra] [clang-tidy] Avoid processing declarations in system headers (PR #128150)

2025-03-07 Thread Gábor Horváth via cfe-commits
Xazax-hun wrote: > That is, this issue is unrelated to system headers or not, but rather that > there are some declarations that are not top-level declarations. Why that's > the case, or if it's intentional, is way beyond my knowledge. I see. I think we should the very least investigate this.

[clang] disable unary, vector mask (PR #130400)

2025-03-07 Thread via cfe-commits
wsehjk wrote: @tbaederr Could you review my code? I'm not sure if I did it right https://github.com/llvm/llvm-project/pull/130400 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Avoid processing declarations in system headers (PR #128150)

2025-03-07 Thread Carlos Galvez via cfe-commits
Carlos =?utf-8?q?Gálvez?= , Carlos =?utf-8?q?Gálvez?= Message-ID: In-Reply-To: carlosgalvezp wrote: Thank you all for the valuable input! There's a lot to process :) I will summarize the feedback, hopefully I got it right: - There are more things that can be optimized (clang-tidy's HeaderFil

[clang] [clang] Fix typos in options text. (PR #130129)

2025-03-07 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon approved this pull request. Thanks! https://github.com/llvm/llvm-project/pull/130129 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CLANG-CL] ignores wpadded (PR #130182)

2025-03-07 Thread via cfe-commits
cor3ntin wrote: Please make sure to keep the formatting of the file as it was (you can format the changes _you_ made to the file with `git clang-format`. Thanks! https://github.com/llvm/llvm-project/pull/130182 ___ cfe-commits mailing list cfe-commit

[clang] [clang][bytecode] Yet another __builtin_constant_p implementation (PR #130143)

2025-03-07 Thread Timm Baeder via cfe-commits
tbaederr wrote: For this case: ```c++ constexpr bool test(int& i) { return __builtin_constant_p(i = 5); } constexpr int f() { int a = 10; test(a); return a; } static_assert(f() == 5); ``` I simply don't. This also works in GCC. For ```c++ bool test(int& i) { return __builtin_constant_p

[clang] [llvm] [clang][DebugInfo] Add symbol for debugger with VTable information. (PR #130255)

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

[clang] [clang] Introduce "binary" StringLiteral for #embed data (PR #127629)

2025-03-07 Thread Mariya Podchishchaeva via cfe-commits
Fznamznon wrote: ping https://github.com/llvm/llvm-project/pull/127629 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libunwind] [libunwind] Remove unnecessary dependencies on fprintf and stdio.h for increased baremetal friendliness (PR #72040)

2025-03-07 Thread Michael Kenzel via cfe-commits
https://github.com/michael-kenzel updated https://github.com/llvm/llvm-project/pull/72040 >From 70ef8570614f1fe8140f24bbe27f69f9c1deb994 Mon Sep 17 00:00:00 2001 From: Michael Kenzel Date: Sat, 11 Nov 2023 22:09:05 +0100 Subject: [PATCH] [libunwind] Remove unnecessary dependencies on stdio.h fo

[clang] [llvm] Revert "[AArch64][SVE] Improve fixed-length addressing modes." (PR #130263)

2025-03-07 Thread Ricardo Jesus via cfe-commits
rj-jesus wrote: I'll commit this to get the bot back to green while I look into it offline. https://github.com/llvm/llvm-project/pull/130263 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-com

[clang] [clang][SPIR-V] Use the SPIR-V backend by default (PR #129545)

2025-03-07 Thread Michal Paszkowski via cfe-commits
https://github.com/michalpaszkowski approved this pull request. https://github.com/llvm/llvm-project/pull/129545 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix ASTWriter crash after merging named enums (PR #114240)

2025-03-07 Thread via cfe-commits
github-actions[bot] wrote: @michael-jabbour-sonarsource 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 p

[clang] [clang] Fix ASTWriter crash after merging named enums (PR #114240)

2025-03-07 Thread via cfe-commits
https://github.com/cor3ntin closed https://github.com/llvm/llvm-project/pull/114240 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Feature]: merge host and kernel dependencies for heterogeneous compilation (PR #119513)

2025-03-07 Thread via cfe-commits
https://github.com/zhouronghua updated https://github.com/llvm/llvm-project/pull/119513 >From 7fb6eb66f85f6c4f433406dbb5be5718459bf8f0 Mon Sep 17 00:00:00 2001 From: "ronghua.zhou" Date: Fri, 14 Feb 2025 01:04:51 + Subject: [PATCH] [Feature]: support for the BC library file into the compile

[clang] [ARM] Using cp15 while mtp =auto and arch is arm_arch6k and support thumb2 (PR #130027)

2025-03-07 Thread Vladi Krapp via cfe-commits
VladiKrapp-Arm wrote: @Zhenhang1213 : Code looks ok. Are all edge cases covered by the lit test now? Could you please adjust the commit message to reflect the actual changes? https://github.com/llvm/llvm-project/pull/130027 ___ cfe-commits mailing

[clang] [Feature]: merge host and kernel dependencies for heterogeneous compilation (PR #119513)

2025-03-07 Thread via cfe-commits
https://github.com/zhouronghua updated https://github.com/llvm/llvm-project/pull/119513 >From 012ddd00153cd4528a5573a69cff640c75b34dbd Mon Sep 17 00:00:00 2001 From: "ronghua.zhou" Date: Fri, 14 Feb 2025 01:04:51 + Subject: [PATCH] [Feature]: support for the BC library file into the compile

[clang] [flang] [llvm] [mlir] [mlir][OpenMP] fix crash outlining infinite loop (PR #129872)

2025-03-07 Thread Tom Eccles via cfe-commits
https://github.com/tblah closed https://github.com/llvm/llvm-project/pull/129872 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [C2y] Implement WG14 N3411 (PR #130180)

2025-03-07 Thread via cfe-commits
https://github.com/cor3ntin approved this pull request. I'm happy to approve as-is, but would you be willing to ask WG14 if they would consider encouraging backporting the feature? https://github.com/llvm/llvm-project/pull/130180 ___ cfe-commits maili

[clang-tools-extra] [clang-tidy] Add new check bugprone-capture-this-by-field (PR #130297)

2025-03-07 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 created https://github.com/llvm/llvm-project/pull/130297 Finds lambda captures that capture the ``this`` pointer and store it as class members without handle the copy and move constructors and the assignments. Capture this in a lambda and store it as a class memb

[clang] [LinkerWrapper] Try to fix testing on Windows (PR #130285)

2025-03-07 Thread Michael Kruse via cfe-commits
@@ -599,9 +599,11 @@ Expected writeOffloadFile(const OffloadFile &File) { StringRef Prefix = sys::path::stem(Binary.getMemoryBufferRef().getBufferIdentifier()); - - auto TempFileOrErr = createOutputFile( - Prefix + "-" + Binary.getTriple() + "-" + Binary.getArch

[clang-tools-extra] [clang-tidy] Add new check bugprone-capture-this-by-field (PR #130297)

2025-03-07 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 updated https://github.com/llvm/llvm-project/pull/130297 >From 8ef214f6c78d710dbd9c74b06c7c637baf93e527 Mon Sep 17 00:00:00 2001 From: Congcong Cai Date: Sat, 8 Mar 2025 00:03:39 +0800 Subject: [PATCH] [clang-tidy] Add new check bugprone-capture-this-by-field ---

[clang-tools-extra] [clang-tidy] Add new check bugprone-capture-this-by-field (PR #130297)

2025-03-07 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tidy Author: Congcong Cai (HerrCai0907) Changes Finds lambda captures that capture the ``this`` pointer and store it as class members without handle the copy and move constructors and the assignments. Capture this in a lambda and store it as a cl

[clang] 67960e5 - [OpenACC] Ensure decl OpenACC constructs don't crash

2025-03-07 Thread via cfe-commits
Author: erichkeane Date: 2025-03-07T08:05:19-08:00 New Revision: 67960e5c08629bb78c147bd0a86764967448b33c URL: https://github.com/llvm/llvm-project/commit/67960e5c08629bb78c147bd0a86764967448b33c DIFF: https://github.com/llvm/llvm-project/commit/67960e5c08629bb78c147bd0a86764967448b33c.diff LO

[clang] [LinkerWrapper] Try to fix testing on Windows (PR #130285)

2025-03-07 Thread Michael Kruse via cfe-commits
https://github.com/Meinersbur requested changes to this pull request. Not aware of any filename sanitizer utility either. https://github.com/llvm/llvm-project/pull/130285 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cg

[clang] [LinkerWrapper] Try to fix testing on Windows (PR #130285)

2025-03-07 Thread Michael Kruse via cfe-commits
https://github.com/Meinersbur edited https://github.com/llvm/llvm-project/pull/130285 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [LinkerWrapper] Try to fix testing on Windows (PR #130285)

2025-03-07 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/130285 >From d39b407a6ae2000f91a345c18cb710647b86c1c8 Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Fri, 7 Mar 2025 07:54:50 -0600 Subject: [PATCH 1/3] [LinkerWrapper] Try to fix testing on Windows Summary: Thanks

[clang] [LinkerWrapper] Try to fix testing on Windows (PR #130285)

2025-03-07 Thread Joseph Huber via cfe-commits
@@ -599,9 +599,11 @@ Expected writeOffloadFile(const OffloadFile &File) { StringRef Prefix = sys::path::stem(Binary.getMemoryBufferRef().getBufferIdentifier()); - - auto TempFileOrErr = createOutputFile( - Prefix + "-" + Binary.getTriple() + "-" + Binary.getArch

[clang] [LinkerWrapper] Try to fix testing on Windows (PR #130285)

2025-03-07 Thread Michael Kruse via cfe-commits
@@ -599,9 +599,11 @@ Expected writeOffloadFile(const OffloadFile &File) { StringRef Prefix = sys::path::stem(Binary.getMemoryBufferRef().getBufferIdentifier()); - - auto TempFileOrErr = createOutputFile( - Prefix + "-" + Binary.getTriple() + "-" + Binary.getArch

[clang] [clang][bytecode] Yet another __builtin_constant_p implementation (PR #130143)

2025-03-07 Thread Nikolas Klauser via cfe-commits
philnik777 wrote: Ah, ok. That's why I couldn't figure it out :D. I'm a bit worried that you could get the constant evaluator in a bad state that way, but I trust you that that's not a problem. Nobody should ever try to modify any state in a `__builtin_constant_p` anyways. https://github.com/

[clang] 0a41fb7 - [Clang] Treat `ext_vector_type` as a regular type attribute (#130177)

2025-03-07 Thread via cfe-commits
Author: Joseph Huber Date: 2025-03-07T10:09:06-06:00 New Revision: 0a41fb71f12624f470b8489f997cbe43b188e0a1 URL: https://github.com/llvm/llvm-project/commit/0a41fb71f12624f470b8489f997cbe43b188e0a1 DIFF: https://github.com/llvm/llvm-project/commit/0a41fb71f12624f470b8489f997cbe43b188e0a1.diff

[clang] [Clang] Treat `ext_vector_type` as a regular type attribute (PR #130177)

2025-03-07 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 closed https://github.com/llvm/llvm-project/pull/130177 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [LinkerWrapper] Try to fix testing on Windows (PR #130285)

2025-03-07 Thread Michael Kruse via cfe-commits
https://github.com/Meinersbur approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/130285 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] f7daa9d - [mlir][OpenMP] fix crash outlining infinite loop (#129872)

2025-03-07 Thread via cfe-commits
Author: Tom Eccles Date: 2025-03-07T11:02:52Z New Revision: f7daa9d302a82f35c3b9ed4cede23ab808462b4f URL: https://github.com/llvm/llvm-project/commit/f7daa9d302a82f35c3b9ed4cede23ab808462b4f DIFF: https://github.com/llvm/llvm-project/commit/f7daa9d302a82f35c3b9ed4cede23ab808462b4f.diff LOG: [m

[clang] [Offload] Always consider `flto` on for AMDGPU (PR #129118)

2025-03-07 Thread Jan Patrick Lehr via cfe-commits
jplehr wrote: > but it turns on LTO by default right? This is very much how I read that patch too. Maybe the flag names and comments are a bit misleading here. https://github.com/llvm/llvm-project/pull/129118 ___ cfe-commits mailing list cfe-commits@l

[clang] [alpha.webkit.UncountedCallArgsChecker] Fix a false negative when a call argument is a local variable. (PR #129974)

2025-03-07 Thread Ryosuke Niwa via cfe-commits
https://github.com/rniwa closed https://github.com/llvm/llvm-project/pull/129974 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [clang][DebugInfo] Add symbol for debugger with VTable information. (PR #130255)

2025-03-07 Thread Michael Buch via cfe-commits
@@ -2518,6 +2518,59 @@ StringRef CGDebugInfo::getVTableName(const CXXRecordDecl *RD) { return internString("_vptr$", RD->getNameAsString()); } +// Emit symbol for the debugger that points to the vtable address for +// the given class. The symbol is named as '_vtable$'. +//

[clang] 21610e3 - Revert "[AArch64][SVE] Improve fixed-length addressing modes." (#130263)

2025-03-07 Thread via cfe-commits
Author: Ricardo Jesus Date: 2025-03-07T09:35:55Z New Revision: 21610e3ecc8bc727f99047e544186b35b1291bcd URL: https://github.com/llvm/llvm-project/commit/21610e3ecc8bc727f99047e544186b35b1291bcd DIFF: https://github.com/llvm/llvm-project/commit/21610e3ecc8bc727f99047e544186b35b1291bcd.diff LOG:

[clang] [llvm] Revert "[AArch64][SVE] Improve fixed-length addressing modes." (PR #130263)

2025-03-07 Thread Ricardo Jesus via cfe-commits
https://github.com/rj-jesus closed https://github.com/llvm/llvm-project/pull/130263 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [MTE] generalize overalignment / size of MTE globals (PR #121957)

2025-03-07 Thread Alexander Richardson via cfe-commits
@@ -715,8 +715,16 @@ MCSymbol *AsmPrinter::getSymbolPreferLocal(const GlobalValue &GV) const { return TM.getSymbol(&GV); } -/// EmitGlobalVariable - Emit the specified global variable to the .s file. void AsmPrinter::emitGlobalVariable(const GlobalVariable *GV) { + MaybeA

[clang] [llvm] [clang][DebugInfo] Add symbol for debugger with VTable information. (PR #130255)

2025-03-07 Thread Michael Buch via cfe-commits
@@ -2518,6 +2518,59 @@ StringRef CGDebugInfo::getVTableName(const CXXRecordDecl *RD) { return internString("_vptr$", RD->getNameAsString()); } +// Emit symbol for the debugger that points to the vtable address for +// the given class. The symbol is named as '_vtable$'. +//

[clang] [flang] [flang] Align `-x f95[-cpp-input]` language modes with `gfortran` (PR #127986)

2025-03-07 Thread Iñaki Amatria Barral via cfe-commits
inaki-amatria wrote: Superseded by https://github.com/llvm/llvm-project/pull/130268. https://github.com/llvm/llvm-project/pull/127986 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libunwind] [libunwind] Remove unnecessary dependencies on fprintf and stdio.h for increased baremetal friendliness (PR #72040)

2025-03-07 Thread Michael Kenzel via cfe-commits
https://github.com/michael-kenzel updated https://github.com/llvm/llvm-project/pull/72040 >From 8c59516b8235049dc74e2496b9e1a1833d38f494 Mon Sep 17 00:00:00 2001 From: Michael Kenzel Date: Sat, 11 Nov 2023 22:09:05 +0100 Subject: [PATCH] [libunwind] Remove unnecessary dependencies on stdio.h fo

[clang] [flang] [flang] Align `-x f95[-cpp-input]` language modes with `gfortran` (PR #127986)

2025-03-07 Thread Iñaki Amatria Barral via cfe-commits
inaki-amatria wrote: > Sorry, maybe I'm still getting a bit confused now 😅. I think in > > https://github.com/llvm/llvm-project/blob/dddfd77f653d7e88965b647e9bc38827cae8bf8a/clang/lib/Driver/Types.cpp#L300 > we are still getting things the wrong way around, even with this patch? If we > want to

[clang] [flang] [flang] Align `-x f95[-cpp-input]` language modes with `gfortran` (PR #127986)

2025-03-07 Thread Iñaki Amatria Barral via cfe-commits
https://github.com/inaki-amatria closed https://github.com/llvm/llvm-project/pull/127986 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] d933882 - [Clang] Add test for CWG2285 "Issues with structured bindings" (#126421)

2025-03-07 Thread via cfe-commits
Author: Yanzuo Liu Date: 2025-03-07T07:16:51+01:00 New Revision: d933882ed369a68d118ca661488bb2c89028a2de URL: https://github.com/llvm/llvm-project/commit/d933882ed369a68d118ca661488bb2c89028a2de DIFF: https://github.com/llvm/llvm-project/commit/d933882ed369a68d118ca661488bb2c89028a2de.diff LO

[clang] [llvm] [clang][DebugInfo] Add symbol for debugger with VTable information. (PR #130255)

2025-03-07 Thread Michael Buch via cfe-commits
@@ -2518,6 +2518,59 @@ StringRef CGDebugInfo::getVTableName(const CXXRecordDecl *RD) { return internString("_vptr$", RD->getNameAsString()); } +// Emit symbol for the debugger that points to the vtable address for +// the given class. The symbol is named as '_vtable$'. +//

[clang] [clang][bytecode] Special-case ConstantExpr in if conditions (PR #130294)

2025-03-07 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/130294 This happens a lot with `if constexpr` with a condition based on a template param. In those cases, the condition is a ConstantExpr with a value already set, so we can use that and ignore the other branch. >Fr

[clang] [compiler-rt] [lld] [llvm] [InstrProf] Remove -forder-file-instrumentation (PR #130192)

2025-03-07 Thread Ellis Hoag via cfe-commits
https://github.com/ellishg updated https://github.com/llvm/llvm-project/pull/130192 >From 72109c24229ce3a1deda9f8303e6e75677cd0ce4 Mon Sep 17 00:00:00 2001 From: Ellis Hoag Date: Thu, 6 Mar 2025 14:17:51 -0800 Subject: [PATCH 1/2] [InstrProf] Remove -forder-file-instrumentation --- clang/docs

[clang] [clang][bytecode] Special-case ConstantExpr in if conditions (PR #130294)

2025-03-07 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes This happens a lot with `if constexpr` with a condition based on a template param. In those cases, the condition is a ConstantExpr with a value already set, so we can use that and ignore the other branch. -

[clang] [flang] [flang] Align `-x` language modes with `gfortran` (PR #130268)

2025-03-07 Thread via cfe-commits
=?utf-8?q?Iñaki?= Amatria Barral Message-ID: In-Reply-To: llvmbot wrote: @llvm/pr-subscribers-flang-driver @llvm/pr-subscribers-clang-driver Author: Iñaki Amatria Barral (inaki-amatria) Changes This PR addresses some of the issues described in https://github.com/llvm/llvm-project/issue

[clang] [Feature]: merge host and kernel dependencies for heterogeneous compilation (PR #119513)

2025-03-07 Thread via cfe-commits
https://github.com/zhouronghua updated https://github.com/llvm/llvm-project/pull/119513 >From e5d12544ce273e2c9ff2ef0291b87ddfbbc0d46c Mon Sep 17 00:00:00 2001 From: "ronghua.zhou" Date: Fri, 14 Feb 2025 01:04:51 + Subject: [PATCH] [Feature]: support for the BC library file into the compile

[clang] [Feature]: merge host and kernel dependencies for heterogeneous compilation (PR #119513)

2025-03-07 Thread via cfe-commits
https://github.com/zhouronghua updated https://github.com/llvm/llvm-project/pull/119513 >From fead058e730d25bac7f1eade7b4519f494d7790a Mon Sep 17 00:00:00 2001 From: "ronghua.zhou" Date: Fri, 14 Feb 2025 01:04:51 + Subject: [PATCH] [Feature]: support for the BC library file into the compile

[clang] [flang] [flang] Align `-x` language modes with `gfortran` (PR #130268)

2025-03-07 Thread Iñaki Amatria Barral via cfe-commits
https://github.com/inaki-amatria created https://github.com/llvm/llvm-project/pull/130268 This PR addresses some of the issues described in https://github.com/llvm/llvm-project/issues/127617. Key changes: - Stop assuming fixed-form for `-x f95` unless the input is a `.i` file. This change ens

[clang] [llvm] [Clang][LLVM] Implement multi-single vectors MOP4{A/S} (PR #129226)

2025-03-07 Thread Virginia Cangelosi via cfe-commits
@@ -257,6 +266,17 @@ class SME2_Tile_Movaz_Pat(name # _PSEUDO) $tile, $base, $offset)>; +class SME2_ZA_Tile_TwoVec_Pat +: Pat<(intrinsic imm_ty:$tile, vt:$Zn, vt:$Zm), + (!cast(name # _PSEUDO) $tile, $Zn, $Zm)>; + +class SME2_ZA_Tile_Vec_Multi_Pat v

[clang] [llvm] [clang][DebugInfo] Add symbol for debugger with VTable information. (PR #130255)

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

[clang] [llvm] [clang][DebugInfo] Add symbol for debugger with VTable information. (PR #130255)

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

[clang] [llvm] [clang][DebugInfo] Add symbol for debugger with VTable information. (PR #130255)

2025-03-07 Thread Michael Buch via cfe-commits
@@ -2518,6 +2518,59 @@ StringRef CGDebugInfo::getVTableName(const CXXRecordDecl *RD) { return internString("_vptr$", RD->getNameAsString()); } +// Emit symbol for the debugger that points to the vtable address for +// the given class. The symbol is named as '_vtable$'. +//

[clang] [Clang] Treat `ext_vector_type` as a regular type attribute (PR #130177)

2025-03-07 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > I am extremely not at ease with flipping this to be a C++ attribute. Back in > the dawn of time, C++ attributes were meant to be non-semantic / removable > with no effect. This only applies to *standard* attributes and has never been intended to apply to *vendor* attrib

[clang] [Offload] Always consider `flto` on for AMDGPU (PR #129118)

2025-03-07 Thread Jan Patrick Lehr via cfe-commits
jplehr wrote: > I think people are just confusing what `-flto` means when put on a link job. Including me. :) Apologies for my ignorance, what does this do and why do we want it? It allows for some (LTO-related?) flags to be forwarded/handled correctly? https://github.com/llvm/llvm-project/pul

[clang] [Offload] Always consider `flto` on for AMDGPU (PR #129118)

2025-03-07 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > > I think people are just confusing what `-flto` means when put on a link job. > > Including me. :) > > Apologies for my ignorance, what does this do and why do we want it? It > allows for some (LTO-related?) flags to be forwarded/handled correctly? The clang driver is very c

[clang-tools-extra] [clangd] Add `BuiltinHeaders` flag to Config file (PR #129459)

2025-03-07 Thread kadir çetinkaya via cfe-commits
kadircet wrote: > we've had users for whom the BuiltinHeaders: QueryDriver behaviour worked > better and want to switch back to it (examples here, here, here, here). I'd argue that the fix isn't as simple as using builtin headers from a different toolchain for those users. Because clang itself

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #125492)

2025-03-07 Thread Ivana Ivanovska via cfe-commits
@@ -186,106 +212,208 @@ class MatchDescendantVisitor : public DynamicRecursiveASTVisitor { return DynamicRecursiveASTVisitor::TraverseStmt(Node); } + void setASTContext(ASTContext &Context) { ActiveASTContext = &Context; } + + void setHandler(const UnsafeBufferUsageHa

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #125492)

2025-03-07 Thread Ivana Ivanovska via cfe-commits
@@ -186,106 +212,208 @@ class MatchDescendantVisitor : public DynamicRecursiveASTVisitor { return DynamicRecursiveASTVisitor::TraverseStmt(Node); } + void setASTContext(ASTContext &Context) { ActiveASTContext = &Context; } + + void setHandler(const UnsafeBufferUsageHa

[clang] [Clang] Implement P0963R3 "Structured binding declaration as a condition" (PR #130228)

2025-03-07 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 updated https://github.com/llvm/llvm-project/pull/130228 >From 295b8173b6913d9014c5786eb4af0112384afa65 Mon Sep 17 00:00:00 2001 From: Younan Zhang Date: Fri, 7 Mar 2025 11:38:11 +0800 Subject: [PATCH] [Clang] Implement P0963R3 "Structured binding declaration as a co

[clang] [flang] [flang] Align `-x` language modes with `gfortran` (PR #130268)

2025-03-07 Thread Tarun Prabhu via cfe-commits
=?utf-8?q?Iñaki?= Amatria Barral Message-ID: In-Reply-To: @@ -0,0 +1,12 @@ +! This test verifies that using `-x f95` does not cause the driver to assume +! this file is in fixed-form. + +program main + print *, "Hello, World!" +end + +! RUN: %flang -### -x f95 %s 2>&1 | FileCh

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #125492)

2025-03-07 Thread Ivana Ivanovska via cfe-commits
@@ -186,106 +212,208 @@ class MatchDescendantVisitor : public DynamicRecursiveASTVisitor { return DynamicRecursiveASTVisitor::TraverseStmt(Node); } + void setASTContext(ASTContext &Context) { ActiveASTContext = &Context; } + + void setHandler(const UnsafeBufferUsageHa

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #125492)

2025-03-07 Thread Ivana Ivanovska via cfe-commits
@@ -186,106 +212,208 @@ class MatchDescendantVisitor : public DynamicRecursiveASTVisitor { return DynamicRecursiveASTVisitor::TraverseStmt(Node); } + void setASTContext(ASTContext &Context) { ActiveASTContext = &Context; } + + void setHandler(const UnsafeBufferUsageHa

[clang] [flang] [flang] Align `-x` language modes with `gfortran` (PR #130268)

2025-03-07 Thread Tarun Prabhu via cfe-commits
=?utf-8?q?Iñaki?= Amatria Barral Message-ID: In-Reply-To: @@ -0,0 +1,35 @@ +program main + print *, __FILE__, __LINE__ +end + +! This test verifies that `flang`'s `-x` options behave like `gfortran`'s. +! Specifically: +! - `-x f95` should process the file based on its extensi

[clang] [flang] [flang] Align `-x` language modes with `gfortran` (PR #130268)

2025-03-07 Thread Tarun Prabhu via cfe-commits
=?utf-8?q?I=C3=B1aki?= Amatria Barral Message-ID: In-Reply-To: https://github.com/tarunprabhu commented: Thanks for continuing to see this through https://github.com/llvm/llvm-project/pull/130268 ___ cfe-commits mailing list cfe-commits@lists.llvm.o

[clang] [Offload] Always consider `flto` on for AMDGPU (PR #129118)

2025-03-07 Thread Jan Patrick Lehr via cfe-commits
https://github.com/jplehr approved this pull request. With the explanation that change seems reasonable. Thank you. https://github.com/llvm/llvm-project/pull/129118 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #125492)

2025-03-07 Thread Ivana Ivanovska via cfe-commits
@@ -1561,56 +1821,70 @@ class UnsafeLibcFunctionCallGadget : public WarningGadget { } WarnedFunKind = OTHERS; public: - UnsafeLibcFunctionCallGadget(const MatchFinder::MatchResult &Result) + UnsafeLibcFunctionCallGadget(const MatchResult &Result) : WarningGadget(Ki

[clang] [Clang] Optimize -Wunsafe-buffer-usage. (PR #125492)

2025-03-07 Thread Ivana Ivanovska via cfe-commits
@@ -1561,56 +1821,70 @@ class UnsafeLibcFunctionCallGadget : public WarningGadget { } WarnedFunKind = OTHERS; public: - UnsafeLibcFunctionCallGadget(const MatchFinder::MatchResult &Result) + UnsafeLibcFunctionCallGadget(const MatchResult &Result) : WarningGadget(Ki

[clang] 90e4215 - [Offload] Always consider `flto` on for AMDGPU (#129118)

2025-03-07 Thread via cfe-commits
Author: Joseph Huber Date: 2025-03-07T06:54:09-06:00 New Revision: 90e421516ee29ed475a052d0f5e96c2447e700d7 URL: https://github.com/llvm/llvm-project/commit/90e421516ee29ed475a052d0f5e96c2447e700d7 DIFF: https://github.com/llvm/llvm-project/commit/90e421516ee29ed475a052d0f5e96c2447e700d7.diff

[clang] clang: Enable linker-wrapper test on windows (PR #130248)

2025-03-07 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm updated https://github.com/llvm/llvm-project/pull/130248 >From 6b912b4ecbb3240fc17a19a4e6a20d86f94549c9 Mon Sep 17 00:00:00 2001 From: Matt Arsenault Date: Fri, 7 Mar 2025 12:38:56 +0700 Subject: [PATCH] clang: Enable linker-wrapper test on windows So far the bot has

[clang] [Offload] Always consider `flto` on for AMDGPU (PR #129118)

2025-03-07 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 closed https://github.com/llvm/llvm-project/pull/129118 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [flang] Add options -W[no-]unused-dummy-argument and -W[no-]unused-variable (PR #127214)

2025-03-07 Thread Tarun Prabhu via cfe-commits
tarunprabhu wrote: Thanks for working on this @JDPailleux. This looks like a substantial change including to parts of clang. Is it possible to split this into two. One PR for just the "infrastructure" and another for the flang-specifc warnings. This would make it easier to focus the discussi

[clang] [C2y] Implement WG14 N3409 (PR #130299)

2025-03-07 Thread via cfe-commits
@@ -10425,8 +10425,13 @@ def warn_type_safety_null_pointer_required : Warning< "specified %0 type tag requires a null pointer">, InGroup; // Generic selections. -def err_assoc_type_incomplete : Error< - "type %0 in generic association incomplete">; +def ext_assoc_type_incom

[clang] d6a4828 - [clang][bytecode] Special-case ConstantExpr in if conditions (#130294)

2025-03-07 Thread via cfe-commits
Author: Timm Baeder Date: 2025-03-07T17:35:06+01:00 New Revision: d6a4828c8a37ff9eee5da745a8a012657fe2af98 URL: https://github.com/llvm/llvm-project/commit/d6a4828c8a37ff9eee5da745a8a012657fe2af98 DIFF: https://github.com/llvm/llvm-project/commit/d6a4828c8a37ff9eee5da745a8a012657fe2af98.diff L

[clang] 3ed4daf - [Clang] Add missing printer for vector type attribute

2025-03-07 Thread Joseph Huber via cfe-commits
Author: Joseph Huber Date: 2025-03-07T10:39:09-06:00 New Revision: 3ed4daf9a749fe8590ad291f63fabce48fb4135f URL: https://github.com/llvm/llvm-project/commit/3ed4daf9a749fe8590ad291f63fabce48fb4135f DIFF: https://github.com/llvm/llvm-project/commit/3ed4daf9a749fe8590ad291f63fabce48fb4135f.diff

[clang] [C2y] Implement WG14 N3409 (PR #130299)

2025-03-07 Thread via cfe-commits
@@ -10425,8 +10425,13 @@ def warn_type_safety_null_pointer_required : Warning< "specified %0 type tag requires a null pointer">, InGroup; // Generic selections. -def err_assoc_type_incomplete : Error< - "type %0 in generic association incomplete">; +def ext_assoc_type_incom

[clang] [C2y] Implement WG14 N3409 (PR #130299)

2025-03-07 Thread via cfe-commits
@@ -0,0 +1,32 @@ +// RUN: %clang_cc1 -verify -std=c2y -pedantic %s +// RUN: %clang_cc1 -verify=pre-c2y -std=c2y -Wpre-c2y-compat %s +// RUN: %clang_cc1 -verify=ext -std=c23 -pedantic %s +// expected-no-diagnostics + +/* WG14 N3409: Clang 21 + * Slay Some Earthly Demons X + * + * R

[clang] [C2y] Implement WG14 N3409 (PR #130299)

2025-03-07 Thread via cfe-commits
@@ -10425,8 +10425,13 @@ def warn_type_safety_null_pointer_required : Warning< "specified %0 type tag requires a null pointer">, InGroup; // Generic selections. -def err_assoc_type_incomplete : Error< - "type %0 in generic association incomplete">; +def ext_assoc_type_incom

[clang] [C2y] Implement WG14 N3409 (PR #130299)

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

[clang] clang/HIP: Use regex for final path separator in hip-partial-link.hip (PR #130291)

2025-03-07 Thread Matt Arsenault via cfe-commits
@@ -62,11 +62,11 @@ // STATIC: Found undefined HIP fatbin symbol: __hip_fatbin_[[ID2:[0-9a-f]+]] // STATIC: Found undefined HIP gpubin handle symbol: __hip_gpubin_handle_[[ID1]] // STATIC: Found undefined HIP gpubin handle symbol: __hip_gpubin_handle_[[ID2]] -// STATIC: "{{.*

[clang] [clang][bytecode] Yet another __builtin_constant_p implementation (PR #130143)

2025-03-07 Thread Timm Baeder via cfe-commits
tbaederr wrote: Yeah. I think I'll merge this. The implementation isn't _that_ invasive, so if any problem arises, it's not too bad to revert it again. https://github.com/llvm/llvm-project/pull/130143 ___ cfe-commits mailing list cfe-commits@lists.llv

[clang] c6b9d5c - clang/HIP: Use regex for final path separator in hip-partial-link.hip (#130291)

2025-03-07 Thread via cfe-commits
Author: Matt Arsenault Date: 2025-03-07T23:36:34+07:00 New Revision: c6b9d5ce76a155b682b1562122f43166aaa6391d URL: https://github.com/llvm/llvm-project/commit/c6b9d5ce76a155b682b1562122f43166aaa6391d DIFF: https://github.com/llvm/llvm-project/commit/c6b9d5ce76a155b682b1562122f43166aaa6391d.diff

[clang] clang/HIP: Use regex for final path separator in hip-partial-link.hip (PR #130291)

2025-03-07 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm closed https://github.com/llvm/llvm-project/pull/130291 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] clang: Enable linker-wrapper test on windows (PR #130248)

2025-03-07 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm closed https://github.com/llvm/llvm-project/pull/130248 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][bytecode] Special-case ConstantExpr in if conditions (PR #130294)

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

[clang] [HLSL] select scalar overloads for vector conditions (PR #129396)

2025-03-07 Thread Chris B via cfe-commits
https://github.com/llvm-beanz updated https://github.com/llvm/llvm-project/pull/129396 >From 999c9253dc69c43f2d5d686bb4e9a9fd2f8783d4 Mon Sep 17 00:00:00 2001 From: Chris Bieneman Date: Wed, 19 Feb 2025 17:18:20 -0600 Subject: [PATCH 1/2] [HLSL] select scalar overloads for vector conditions Th

<    1   2   3   4   5   >