[clang-tools-extra] [clang-tidy] Fix broken HeaderFilterRegex when read from config file (PR #133582)

2025-04-02 Thread Carlos Galvez via cfe-commits
https://github.com/carlosgalvezp updated https://github.com/llvm/llvm-project/pull/133582 >From 12b63eb35ab09b6ae1aa0fbfa00487f4cad3cac7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Carlos=20G=C3=A1lvez?= Date: Sat, 29 Mar 2025 11:55:02 + Subject: [PATCH] [clang-tidy] Fix broken HeaderFilterReg

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

2025-04-02 Thread Mikael Holmén via cfe-commits
mikaelholmen wrote: > If I compile clang with clang (18.1.8) the new windows-Wpadded.cpp testcase > fails for me like > > ``` > error: 'expected-warning' diagnostics seen but not expected: > File /repo/clang/test/SemaCXX/windows-Wpadded.cpp Line 20: padding struct > 'Derived' with 2 bits to

[clang] [clang-tools-extra] [flang] [lldb] [llvm] [mlir] Fix typos: paramter, parametr, parametere (PR #134092)

2025-04-02 Thread Owen Pan via cfe-commits
@@ -12304,7 +12304,7 @@ TEST_F(FormatTest, UnderstandsUsesOfStarAndAmp) { verifyIndependentOfContext("f(b * /* confusing comment */ ++c);"); verifyFormat("f(* /* confusing comment */ foo);"); verifyFormat("void (* /*deleter*/)(const Slice &key, void *value)"); - verifyFo

[clang] b384d6d - [CodeGen] Don't include CGDebugInfo.h in CodeGenFunction.h (NFC) (#134100)

2025-04-02 Thread via cfe-commits
Author: Nikita Popov Date: 2025-04-03T08:04:19+02:00 New Revision: b384d6d6ccc8f4452cd7086061c657ce76b41224 URL: https://github.com/llvm/llvm-project/commit/b384d6d6ccc8f4452cd7086061c657ce76b41224 DIFF: https://github.com/llvm/llvm-project/commit/b384d6d6ccc8f4452cd7086061c657ce76b41224.diff

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

2025-04-02 Thread Aniket Lal via cfe-commits
lalaniket8 wrote: pinging for review @arsenm @yxsamliu @rjmccall https://github.com/llvm/llvm-project/pull/115821 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [SYCL][SPIR-V Backend][clang-sycl-linker] Add SPIR-V backend support inside clang-sycl-linker (PR #133967)

2025-04-02 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `clang-ppc64-aix` running on `aix-ppc64` while building `clang` at step 6 "test-build-unified-tree-check-all". Full details are available at: https://lab.llvm.org/buildbot/#/builders/64/builds/2751 Here is the relevant piece

[clang] [clang] Merge gtest binaries into AllClangUnitTests (PR #134196)

2025-04-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-driver Author: Reid Kleckner (rnk) Changes This reduces the size of the clang/unittests build directory by 64% and my overall build dir size by 5%. Static linking is the real driving factor here, but even if the default build configuration used s

[clang] [clang] remove unused frontend flag -fretain-subst-template-type-parm-type-ast-nodes (PR #134177)

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

[clang] [AMDGPU] Remove detection of hip runtime for Spack (PR #133263)

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

[clang] [WIP][Clang] Allow floating point fixed vectors with atomic builtins (PR #129495)

2025-04-02 Thread Vikram Hegde via cfe-commits
vikramRH wrote: Ping... been a while since we last visited this. https://github.com/llvm/llvm-project/pull/129495 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Merge gtest binaries into AllClangUnitTests (PR #134196)

2025-04-02 Thread Reid Kleckner via cfe-commits
https://github.com/rnk created https://github.com/llvm/llvm-project/pull/134196 This reduces the size of the clang/unittests build directory by 64% and my overall build dir size by 5%. Static linking is the real driving factor here, but even if the default build configuration used shared librar

[clang] [clang-format] add option to control bin-packing keyworded parameters (PR #131605)

2025-04-02 Thread Owen Pan via cfe-commits
owenca wrote: > > > IMO, a boolean option, e.g. `AllowBreakBeforeQPropertyKeyword` should > > > suffice. > > > > > > I don't like to hardcode neither the macro name nor the keywords, which > > depend on Qt version. Implementation would not differ save for the source > > we fetch keywords fro

[clang] Hlsl dst function (PR #133828)

2025-04-02 Thread Farzon Lotfi via cfe-commits
@@ -0,0 +1,70 @@ +// RUN: %clang_cc1 -finclude-default-header -x hlsl -triple dxil-pc-shadermodel6.2-library %s -fnative-half-type -emit-llvm -O1 -o - | FileCheck %s farzonl wrote: remove -O1 you should be able to check for correctness without optimizations. h

[clang] Reapply "[cmake] Refactor clang unittest cmake" (PR #134195)

2025-04-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-modules Author: Reid Kleckner (rnk) Changes This reapplies 5ffd9bdb50b57 (#133545) with fixes. The BUILD_SHARED_LIBS=ON build was fixed by adding missing LLVM dependencies to the InterpTests binary in unittests/AST/ByteCode/CMakeLists.txt . ---

[clang] Reapply "[cmake] Refactor clang unittest cmake" (PR #134195)

2025-04-02 Thread Reid Kleckner via cfe-commits
https://github.com/rnk created https://github.com/llvm/llvm-project/pull/134195 This reapplies 5ffd9bdb50b57 (#133545) with fixes. The BUILD_SHARED_LIBS=ON build was fixed by adding missing LLVM dependencies to the InterpTests binary in unittests/AST/ByteCode/CMakeLists.txt . >From fe6604dc283

[clang] [clang-format] Fix a bug in annotating braces (PR #134039)

2025-04-02 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `sanitizer-x86_64-linux-android` running on `sanitizer-buildbot-android` while building `clang` at step 2 "annotate". Full details are available at: https://lab.llvm.org/buildbot/#/builders/186/builds/7879 Here is the releva

[clang] Reapply "[cmake] Refactor clang unittest cmake" (PR #134195)

2025-04-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-driver @llvm/pr-subscribers-clang Author: Reid Kleckner (rnk) Changes This reapplies 5ffd9bdb50b57 (#133545) with fixes. The BUILD_SHARED_LIBS=ON build was fixed by adding missing LLVM dependencies to the InterpTests binary in unittests/AST/ByteCo

[clang] [Clang] Fix a lambda pattern comparison mismatch after ecc7e6ce4 (PR #133863)

2025-04-02 Thread via cfe-commits
llvmbot wrote: /pull-request llvm/llvm-project#134194 https://github.com/llvm/llvm-project/pull/133863 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Fix a lambda pattern comparison mismatch after ecc7e6ce4 (PR #133863)

2025-04-02 Thread Younan Zhang via cfe-commits
zyn0217 wrote: /cherry-pick dcc2182bc https://github.com/llvm/llvm-project/pull/133863 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Check `std::initializer_list` more strictly (PR #133822)

2025-04-02 Thread Younan Zhang via cfe-commits
@@ -12155,16 +12185,16 @@ static ClassTemplateDecl *LookupStdInitializerList(Sema &S, SourceLocation Loc){ Result.suppressDiagnostics(); // We found something weird. Complain about the first thing we found. NamedDecl *Found = *Result.begin(); -S.Diag(Found->get

[clang] [clang] Check `std::initializer_list` more strictly (PR #133822)

2025-04-02 Thread Younan Zhang via cfe-commits
@@ -0,0 +1,77 @@ +// RUN: %clang_cc1 %s -verify=expected,type-param -std=c++23 -DTYPE_PARAM +// RUN: %clang_cc1 %s -verify=expected,others -std=c++23 -DCONSTANT_PARAM +// RUN: %clang_cc1 %s -verify=expected,others -std=c++23 -DTYPE_TEMPLATE_PARAM +// RUN: %clang_cc1 %s -verify=exp

[clang] dcc2182 - [Clang] Fix a lambda pattern comparison mismatch after ecc7e6ce4 (#133863)

2025-04-02 Thread via cfe-commits
Author: Younan Zhang Date: 2025-04-03T11:15:42+08:00 New Revision: dcc2182bce3d2ef0e0a991664c51b4b3bfcf7197 URL: https://github.com/llvm/llvm-project/commit/dcc2182bce3d2ef0e0a991664c51b4b3bfcf7197 DIFF: https://github.com/llvm/llvm-project/commit/dcc2182bce3d2ef0e0a991664c51b4b3bfcf7197.diff

[clang] [Clang] Fix a lambda pattern comparison mismatch after ecc7e6ce4 (PR #133863)

2025-04-02 Thread Younan Zhang via cfe-commits
zyn0217 wrote: /cherry-pick dcc2182bce https://github.com/llvm/llvm-project/pull/133863 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Implement the `lit` intrinsic (PR #134171)

2025-04-02 Thread Farzon Lotfi via cfe-commits
@@ -280,6 +280,22 @@ constexpr bool4 isinf(double4 V) { return isinf((float4)V); } _DXC_COMPAT_TERNARY_DOUBLE_OVERLOADS(lerp) _DXC_COMPAT_TERNARY_INTEGER_OVERLOADS(lerp) +//===--===// +// lit builtins overloa

[clang] [Clang] Fix a lambda pattern comparison mismatch after ecc7e6ce4 (PR #133863)

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

[clang] Reland [Clang][Cmake] fix libtool duplicate member name warnings (PR #133850)

2025-04-02 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl updated https://github.com/llvm/llvm-project/pull/133850 >From cd2f6658a1a609edf7471f629b766eb4ee495122 Mon Sep 17 00:00:00 2001 From: Farzon Lotfi Date: Sun, 30 Mar 2025 00:59:48 -0400 Subject: [PATCH 1/3] [Clang][Cmake] fix libtool duplicate member name warnings fi

[clang] [Sema] Use llvm::erase_if (NFC) (PR #134017)

2025-04-02 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/134017 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Hlsl dst function (PR #133828)

2025-04-02 Thread Farzon Lotfi via cfe-commits
@@ -0,0 +1,37 @@ +// RUN: %clang_cc1 -finclude-default-header -triple dxil-pc-shadermodel6.6-library %s -fnative-half-type -emit-llvm-only -disable-llvm-passes -verify + +float4 test_too_many_arg(float4 p0) +{ +dst(p0, p0, p0); + // expected-error@-1 {{no matching function

[clang] [HLSL] Implement the `lit` intrinsic (PR #134171)

2025-04-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-x86 Author: Kaitlin Peng (kmpeng) Changes Closes #99135. Tasks completed: - Wrote implementation in `hlsl_intrinsics.h`/`hlsl_intrinsic_helpers.h` that matches DXC - Created overloads in `hlsl_compat_overloads.h` that take doubles/ints and e

[clang] [flang] [llvm] [flang-rt] Pass the whole path of libflang_rt.runtime.a to linker on AIX (PR #131041)

2025-04-02 Thread Daniel Chen via cfe-commits
@@ -0,0 +1,38 @@ +!! Testing ld command with flang on POWERPC. + +!! Because flang-rt currently only supports +!! LLVM_ENABLE_PER_TARGET_RUNTIME_DIR=ON, use +!! resource_dir_with_per_target_subdir as inputs. + +! Check powerpc64-ibm-aix 64-bit linking to static flang-rt +! RUN: %

[clang] [modules] Handle friend function that was a definition but became only a declaration during AST deserialization (PR #132214)

2025-04-02 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. Let it go. https://github.com/llvm/llvm-project/pull/132214 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] fixed clang frontend crash with friend class declaration and overload == (PR #133878)

2025-04-02 Thread via cfe-commits
github-actions[bot] wrote: @Ankur-0429 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 bui

[clang-tools-extra] [clang-tidy] Improve integer comparison by matching valid expressions outside implicitCastExpr (PR #134188)

2025-04-02 Thread David Rivera via cfe-commits
https://github.com/RiverDave updated https://github.com/llvm/llvm-project/pull/134188 >From ac9833cd5abdaf4a91c785d5fa9d51190219851a Mon Sep 17 00:00:00 2001 From: David Rivera Date: Wed, 2 Apr 2025 21:02:00 -0400 Subject: [PATCH] [clang-tidy] Improve integer comparison by matching valid expre

[clang] [CIR] Upstream support for break and continue statements (PR #134181)

2025-04-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Andy Kaylor (andykaylor) Changes This adds ClangIR support for break and continue statements in loops. Because only loops are currently implemented upstream in CIR, only breaks in loops are supported here, but this same code will work (wi

[clang] [Clang] fixed clang frontend crash with friend class declaration and overload == (PR #133878)

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

[clang-tools-extra] [clang-tidy] Improve integer comparison by matching valid expressions outside implicitCastExpr (PR #134188)

2025-04-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tools-extra Author: David Rivera (RiverDave) Changes Covered the edge case where an int expression is not necessarily directly wrapped around an ImplicitCastExpr which seemed to be a requirement in this check to trigger. **For instance**: ```cp

[clang-tools-extra] [clang-tidy] Improve integer comparison by matching valid expressions outside implicitCastExpr (PR #134188)

2025-04-02 Thread David Rivera via cfe-commits
https://github.com/RiverDave created https://github.com/llvm/llvm-project/pull/134188 Covered the edge case where an int expression is not necessarily directly wrapped around an ImplicitCastExpr which seemed to be a requirement in this check to trigger. **For instance**: ```cpp #include bo

[clang] [Clang] fixed clang frontend crash with friend class declaration and overload == (PR #133878)

2025-04-02 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `lldb-aarch64-ubuntu` running on `linaro-lldb-aarch64-ubuntu` while building `clang` at step 6 "test". Full details are available at: https://lab.llvm.org/buildbot/#/builders/59/builds/15365 Here is the relevant piece of the

[clang] [SYCL][SPIR-V Backend][clang-sycl-linker] Add SPIR-V backend support inside clang-sycl-linker (PR #133967)

2025-04-02 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `clang-arm64-windows-msvc` running on `linaro-armv8-windows-msvc-04` while building `clang` at step 6 "test-build-unified-tree-check-all". Full details are available at: https://lab.llvm.org/buildbot/#/builders/161/builds/5156

[clang] [Clang] fixed clang frontend crash with friend class declaration and overload == (PR #133878)

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

[clang] [Clang] fixed clang frontend crash with friend class declaration and overload == (PR #133878)

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

[clang] Hlsl dst function (PR #133828)

2025-04-02 Thread Farzon Lotfi via cfe-commits
@@ -0,0 +1,37 @@ +// RUN: %clang_cc1 -finclude-default-header -triple dxil-pc-shadermodel6.6-library %s -fnative-half-type -emit-llvm-only -disable-llvm-passes -verify + +float4 test_too_many_arg(float4 p0) +{ +dst(p0, p0, p0); + // expected-error@-1 {{no matching function

[clang] [HLSL] Implement the `lit` intrinsic (PR #134171)

2025-04-02 Thread Sarah Spall via cfe-commits
@@ -0,0 +1,36 @@ +// NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py UTC_ARGS: --version 5 +// RUN: %clang_cc1 -finclude-default-header -x hlsl -triple dxil-pc-shadermodel6.3-library %s -fnative-half-type -emit-llvm -O1 -o - | FileCheck %s + +// CHECK

[clang] fixed clang frontend crash with friend class declaration and overload == (PR #133878)

2025-04-02 Thread Ankur Ahir via cfe-commits
Ankur-0429 wrote: @cor3ntin feel free to merge the PR when it's ready. Happy to help! https://github.com/llvm/llvm-project/pull/133878 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][CodeGen] Add range metadata for atomic load of boolean type. #131476 (PR #133546)

2025-04-02 Thread Eli Friedman via cfe-commits
Jan =?utf-8?q?Górski?= , Jan =?utf-8?q?Górski?= Message-ID: In-Reply-To: @@ -590,6 +590,29 @@ static void EmitAtomicOp(CodeGenFunction &CGF, AtomicExpr *E, Address Dest, llvm::LoadInst *Load = CGF.Builder.CreateLoad(Ptr); Load->setAtomic(Order, Scope); Load->set

[clang] [clang][CodeGen] Add range metadata for atomic load of boolean type. #131476 (PR #133546)

2025-04-02 Thread Eli Friedman via cfe-commits
Jan =?utf-8?q?Górski?= , Jan =?utf-8?q?Górski?= Message-ID: In-Reply-To: @@ -590,6 +590,29 @@ static void EmitAtomicOp(CodeGenFunction &CGF, AtomicExpr *E, Address Dest, llvm::LoadInst *Load = CGF.Builder.CreateLoad(Ptr); Load->setAtomic(Order, Scope); Load->set

[clang] [clang-sycl-linker] Fix flaky failure and add REQUIRES (PR #134125)

2025-04-02 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `llvm-x86_64-debian-dylib` running on `gribozavr4` while building `clang` at step 5 "build-unified-tree". Full details are available at: https://lab.llvm.org/buildbot/#/builders/60/builds/23721 Here is the relevant piece of t

[clang] [SYCL][SPIR-V Backend][clang-sycl-linker] Add SPIR-V backend support inside clang-sycl-linker (PR #133967)

2025-04-02 Thread Arvind Sudarsanam via cfe-commits
https://github.com/asudarsa updated https://github.com/llvm/llvm-project/pull/133967 >From 0ab40315cd5ca320d84f87c99b8f23d9b6e8ed36 Mon Sep 17 00:00:00 2001 From: Arvind Sudarsanam Date: Mon, 31 Mar 2025 14:31:24 -0700 Subject: [PATCH 1/6] [SYCL][SPIR-V Backend][clang-sycl-linker] Add SPIR-V b

[clang] [clang] remove unused frontend flag -fretain_subst_template_type_parm_type_ast_nodes (PR #134177)

2025-04-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Matheus Izvekov (mizvekov) Changes This is a follow-up to #132748, where we deferred the flag removal in order to ease transition for external users. The plan is to merge this in the nearish future, in two weeks or so is my best guess.

[clang] [HLSL] Implement the `lit` intrinsic (PR #134171)

2025-04-02 Thread Farzon Lotfi via cfe-commits
@@ -253,6 +253,37 @@ const inline float length(__detail::HLSL_FIXED_VECTOR X) { return __detail::length_vec_impl(X); } +//===--===// +// lit builtins +//===--

[clang] [HLSL] Implement the `lit` intrinsic (PR #134171)

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

[clang] [HLSL] Implement the `lit` intrinsic (PR #134171)

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

[clang] [HLSL] Implement the `lit` intrinsic (PR #134171)

2025-04-02 Thread Farzon Lotfi via cfe-commits
@@ -253,6 +253,37 @@ const inline float length(__detail::HLSL_FIXED_VECTOR X) { return __detail::length_vec_impl(X); } +//===--===// +// lit builtins +//===--

[clang] [HLSL] Implement the `lit` intrinsic (PR #134171)

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

[clang] [clang] remove unused frontend flag -fretain_subst_template_type_parm_type_ast_nodes (PR #134177)

2025-04-02 Thread Matheus Izvekov via cfe-commits
https://github.com/mizvekov created https://github.com/llvm/llvm-project/pull/134177 This is a follow-up to #132748, where we deferred the flag removal in order to ease transition for external users. The plan is to merge this in the nearish future, in two weeks or so is my best guess. >From

[clang] [HLSL] Implement the `lit` intrinsic (PR #134171)

2025-04-02 Thread Kaitlin Peng via cfe-commits
https://github.com/kmpeng edited https://github.com/llvm/llvm-project/pull/134171 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Make it possible to assign an array from a cbuffer (PR #134174)

2025-04-02 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 HEAD~1 HEAD --extensions cpp -- clang/lib/Sema/SemaExprCXX.cpp clang/lib/Sema/SemaOve

[clang] [HLSL] Make it possible to assign an array from a cbuffer (PR #134174)

2025-04-02 Thread Sarah Spall via cfe-commits
https://github.com/spall created https://github.com/llvm/llvm-project/pull/134174 Update Sema Checking to always do an HLSL Array RValue cast in the case we are dealing with hlsl constant array types Instead of comparing canonical types, compare canonical unqualified types Add a test to show it

[clang] [HLSL] Implement the `lit` intrinsic (PR #134171)

2025-04-02 Thread Sarah Spall via cfe-commits
@@ -253,6 +253,37 @@ const inline float length(__detail::HLSL_FIXED_VECTOR X) { return __detail::length_vec_impl(X); } +//===--===// +// lit builtins +//===--

[clang] [CIR] Generate the nsw flag correctly for unary ops (PR #133815)

2025-04-02 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `lldb-arm-ubuntu` running on `linaro-lldb-arm-ubuntu` while building `clang` at step 6 "test". Full details are available at: https://lab.llvm.org/buildbot/#/builders/18/builds/13914 Here is the relevant piece of the build lo

[clang] [llvm] [HLSL] Implement dot2add intrinsic (PR #131237)

2025-04-02 Thread Farzon Lotfi via cfe-commits
@@ -168,6 +173,12 @@ class OpLowerer { } } else if (IsVectorArgExpansion) { Args = argVectorFlatten(CI, OpBuilder.getIRB()); + } else if (F.getIntrinsicID() == Intrinsic::dx_dot2add) { farzonl wrote: You are correct this is a one off

[clang] [flang] [flang] Added driver options for arrays repacking. (PR #134002)

2025-04-02 Thread Slava Zakharin via cfe-commits
https://github.com/vzakhari updated https://github.com/llvm/llvm-project/pull/134002 >From 5c83d849a7129840ad8d8accd83e72836d1b2697 Mon Sep 17 00:00:00 2001 From: Slava Zakharin Date: Tue, 1 Apr 2025 15:55:30 -0700 Subject: [PATCH 1/3] [flang] Added driver options for arrays repacking. Added o

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

2025-04-02 Thread via cfe-commits
=?utf-8?q?Théo?= De Magalhaes , =?utf-8?q?Théo?= De Magalhaes , =?utf-8?q?Théo?= De Magalhaes , =?utf-8?q?Théo?= De Magalhaes , =?utf-8?q?Théo?= De Magalhaes , =?utf-8?q?Théo?= De Magalhaes , =?utf-8?q?Théo?= De Magalhaes , =?utf-8?q?Théo?= De Magalhaes Message-ID: In-Reply-To: github-actions[b

[clang] [llvm] [HLSL] Implement dot2add intrinsic (PR #131237)

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

[clang] [HLSL] Implement the `lit` intrinsic (PR #134171)

2025-04-02 Thread Kaitlin Peng via cfe-commits
https://github.com/kmpeng created https://github.com/llvm/llvm-project/pull/134171 Closes #99135. Tasks completed: - Wrote implementation in `hlsl_intrinsics.h`/`hlsl_intrinsic_helpers.h` that matches DXC - Created overloads in `hlsl_compat_overloads.h` that take doubles/ints and explicitly

[clang] [clang-tools-extra] [clang] support pack expansions for trailing requires clauses (PR #133190)

2025-04-02 Thread via cfe-commits
@@ -7379,8 +7378,11 @@ bool ASTContext::isSameEntity(const NamedDecl *X, const NamedDecl *Y) const { return false; } -if (!isSameConstraintExpr(FuncX->getTrailingRequiresClause(), cor3ntin wrote: Can we add an overload, at least + comment? htt

[clang] c57b9c2 - [CIR] Generate the nsw flag correctly for unary ops (#133815)

2025-04-02 Thread via cfe-commits
Author: Andy Kaylor Date: 2025-04-02T15:48:55-07:00 New Revision: c57b9c233a87f37e034445596ed09260cc6b23f5 URL: https://github.com/llvm/llvm-project/commit/c57b9c233a87f37e034445596ed09260cc6b23f5 DIFF: https://github.com/llvm/llvm-project/commit/c57b9c233a87f37e034445596ed09260cc6b23f5.diff L

[clang] Hlsl dst function (PR #133828)

2025-04-02 Thread via cfe-commits
https://github.com/metkarpoonam updated https://github.com/llvm/llvm-project/pull/133828 >From 3a45246453d120da108e597d23da0fb8d9df0b1b Mon Sep 17 00:00:00 2001 From: Poonam Vilas Metkar Date: Mon, 31 Mar 2025 16:49:18 -0700 Subject: [PATCH 1/8] Implement a dst function with test cases for HLSL

[clang] [HLSL] Implement `SpirvType` and `SpirvOpaqueType` (PR #134034)

2025-04-02 Thread Cassandra Beckley via cfe-commits
cassiebeckley wrote: @philnik777 fyi for the changes to builtin templates https://github.com/llvm/llvm-project/pull/134034 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Hlsl dst function (PR #133828)

2025-04-02 Thread via cfe-commits
https://github.com/metkarpoonam updated https://github.com/llvm/llvm-project/pull/133828 >From 3a45246453d120da108e597d23da0fb8d9df0b1b Mon Sep 17 00:00:00 2001 From: Poonam Vilas Metkar Date: Mon, 31 Mar 2025 16:49:18 -0700 Subject: [PATCH 1/7] Implement a dst function with test cases for HLSL

[clang] Hlsl dst function (PR #133828)

2025-04-02 Thread Farzon Lotfi via cfe-commits
@@ -0,0 +1,37 @@ +// RUN: %clang_cc1 -finclude-default-header -triple dxil-pc-shadermodel6.6-library %s -fnative-half-type -emit-llvm-only -disable-llvm-passes -verify + +float4 test_too_many_arg(float4 p0) +{ +dst(p0, p0, p0); + // expected-error@-1 {{no matching function

[clang] [clang][NFC] Refactor CodeGen's hasBooleanRepresentation (PR #134159)

2025-04-02 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor created https://github.com/llvm/llvm-project/pull/134159 The ClangIR upstreaming project needs the same logic for hasBooleanRepresentation() that is currently implemented in the standard clang codegen. In order to share this code, this change moves the implementat

[clang] a0e1e68 - [clang][bytecode] Return Invalid() on non-constexpr builtins (#133700)

2025-04-02 Thread via cfe-commits
Author: Timm Baeder Date: 2025-03-31T18:53:12+02:00 New Revision: a0e1e680d28c4ef5f87be948d1d223fbfda2950c URL: https://github.com/llvm/llvm-project/commit/a0e1e680d28c4ef5f87be948d1d223fbfda2950c DIFF: https://github.com/llvm/llvm-project/commit/a0e1e680d28c4ef5f87be948d1d223fbfda2950c.diff L

[clang] [clang] Fix crash on invalid `std::initializer_list` template-id (PR #132284)

2025-04-02 Thread via cfe-commits
https://github.com/offsetof updated https://github.com/llvm/llvm-project/pull/132284 >From 553ced1e367c0ec6399e71e7a3a3685a550f3431 Mon Sep 17 00:00:00 2001 From: offsetof Date: Thu, 20 Mar 2025 20:54:45 + Subject: [PATCH 1/2] [clang] Fix crash on invalid `std::initializer_list` template-i

[clang] [clang] Track final substitution for Subst* AST nodes (PR #132748)

2025-04-02 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `openmp-offload-amdgpu-runtime-2` running on `rocm-worker-hw-02` while building `clang` at step 5 "compile-openmp". Full details are available at: https://lab.llvm.org/buildbot/#/builders/10/builds/2721 Here is the relevant

[clang] [clang-format] Fix a bug in annotating braces (PR #134039)

2025-04-02 Thread via cfe-commits
https://github.com/mydeveloperday approved this pull request. https://github.com/llvm/llvm-project/pull/134039 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Track final substitution for Subst* AST nodes (PR #132748)

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

[clang] f302f35 - [clang] Track final substitution for Subst* AST nodes (#132748)

2025-04-02 Thread via cfe-commits
Author: Matheus Izvekov Date: 2025-04-02T19:27:29-03:00 New Revision: f302f35526553abcb46dab278c4494c3d01deb45 URL: https://github.com/llvm/llvm-project/commit/f302f35526553abcb46dab278c4494c3d01deb45 DIFF: https://github.com/llvm/llvm-project/commit/f302f35526553abcb46dab278c4494c3d01deb45.dif

[clang] Hlsl dst function (PR #133828)

2025-04-02 Thread Farzon Lotfi via cfe-commits
@@ -0,0 +1,51 @@ +// RUN: %clang_cc1 -finclude-default-header -triple dxil-pc-shadermodel6.6-library %s -fnative-half-type -emit-llvm-only -disable-llvm-passes -verify + +float4 test_too_many_arg(float4 p0) +{ +dst(p0, p0, p0); + // expected-error@-1 {{no matching function

[clang] Hlsl dst function (PR #133828)

2025-04-02 Thread Farzon Lotfi via cfe-commits
@@ -0,0 +1,51 @@ +// RUN: %clang_cc1 -finclude-default-header -triple dxil-pc-shadermodel6.6-library %s -fnative-half-type -emit-llvm-only -disable-llvm-passes -verify + +float4 test_too_many_arg(float4 p0) +{ +dst(p0, p0, p0); + // expected-error@-1 {{no matching function

[clang] Hlsl dst function (PR #133828)

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

[clang] Hlsl dst function (PR #133828)

2025-04-02 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl deleted https://github.com/llvm/llvm-project/pull/133828 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][NFC] Add threadsafe macro helper (PR #134139)

2025-04-02 Thread Eli Friedman via cfe-commits
efriedma-quic wrote: I don't understand what you're planning. Currently, the only thing the POSIXThreads LangOption does is control `_REENTRANT` or equivalent. If you provide a separate option to control the macro, the POSIXThreads option doesn't do anything at all. https://github.com/llvm/

[clang] [Clang][CodeGen][UBSan] Add more precise attributes to recoverable ubsan handlers (PR #130990)

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

[clang] [llvm] [HLSL] Implement dot2add intrinsic (PR #131237)

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

[clang] [llvm] [HLSL] Implement dot2add intrinsic (PR #131237)

2025-04-02 Thread Farzon Lotfi via cfe-commits
@@ -45,6 +45,14 @@ distance_vec_impl(vector X, vector Y) { return length_vec_impl(X - Y); } +constexpr float dot2add_impl(half2 a, half2 b, float c) { +#if defined(__DIRECTX__) farzonl wrote: Also to answer your question we only need to do one or the other

[clang] Reland [Clang][Cmake] fix libtool duplicate member name warnings (PR #133850)

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

[clang] Reland [Clang][Cmake] fix libtool duplicate member name warnings (PR #133850)

2025-04-02 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl updated https://github.com/llvm/llvm-project/pull/133850 >From ac51727e83539ce998e32465665bb87b3ee7ed00 Mon Sep 17 00:00:00 2001 From: Farzon Lotfi Date: Sun, 30 Mar 2025 00:59:48 -0400 Subject: [PATCH 1/3] [Clang][Cmake] fix libtool duplicate member name warnings fi

[clang] Reland [Clang][Cmake] fix libtool duplicate member name warnings (PR #133850)

2025-04-02 Thread Farzon Lotfi via cfe-commits
farzonl wrote: > I don't really get why that problem is specific to DirectX though. All of > these make use of CodeGen, right? @nikic I see what you are asking. you want more specific on the error not that the error happened. because of this: https://github.com/llvm/llvm-project/blob/42b3f9

[clang] [Clang][Driver] Override complex number calculation method by -fno-fa… (PR #132680)

2025-04-02 Thread Fangrui Song via cfe-commits
@@ -3148,6 +3158,7 @@ static void RenderFloatingPointOptions(const ToolChain &TC, const Driver &D, ComplexArithmeticStr(RangeVal)); } } + LastComplexRangeOption = "-fcomplex-arithmetic"; MaskRay wrote: `Arg:

[clang] [Clang][Driver] Override complex number calculation method by -fno-fa… (PR #132680)

2025-04-02 Thread Fangrui Song via cfe-commits
@@ -2997,6 +2997,7 @@ static void RenderFloatingPointOptions(const ToolChain &TC, const Driver &D, LangOptions::ComplexRangeKind Range = LangOptions::ComplexRangeKind::CX_None; std::string ComplexRangeStr = ""; std::string GccRangeComplexOption = ""; + std::string LastC

[libclc] [libclc] Move lgamma, lgamma_r & tgamma to CLC library (PR #134053)

2025-04-02 Thread Fraser Cormack via cfe-commits
https://github.com/frasercrmck created https://github.com/llvm/llvm-project/pull/134053 Also enable half-precision variants of tgamma, which were previously missing. Note that unlike recent work, these builtins are not vectorized as part of this commit. Ultimately all three call into lgamma_r,

[clang] Bypass alignment option based on architecture features instead of command-line flags (PR #134099)

2025-04-02 Thread Simi Pallipurath via cfe-commits
https://github.com/simpal01 edited https://github.com/llvm/llvm-project/pull/134099 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Implement CWG2815 (PR #132778)

2025-04-02 Thread via cfe-commits
https://github.com/offsetof updated https://github.com/llvm/llvm-project/pull/132778 >From 0aa1e7b83888bde7112327fba7db9bdcb71c43d9 Mon Sep 17 00:00:00 2001 From: offsetof Date: Mon, 24 Mar 2025 16:28:28 + Subject: [PATCH 1/4] [clang] Implement CWG2815 CWG2815 "Overload resolution for refe

[clang] [llvm] [OffloadBundler] Rework the ctor of `OffloadTargetInfo` to support AMDGPU's generic target (PR #122629)

2025-04-02 Thread Shilei Tian via cfe-commits
shiltian wrote: @asb I did receive some emails initially but haven't gotten any lately. I assumed that issue had been fixed, as it seemed like the driver was just unconditionally adding `unknown`. https://github.com/llvm/llvm-project/pull/122629 ___

[clang] [llvm] [EquivalenceClasses] Use SmallVector for deterministic iteration order. (PR #134075)

2025-04-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-aarch64 Author: Florian Hahn (fhahn) Changes Currently iterators over EquivalenceClasses will iterate over std::set, which guarantees the order specified by the comperator. Unfortunately in many cases, EquivalenceClasses are used with pointers,

[clang] [Clang][ARM]Ensure both -mno-unaligned-access and -munaligned-access are passed to multilib selection logic (PR #134099)

2025-04-02 Thread Peter Smith via cfe-commits
https://github.com/smithp35 edited https://github.com/llvm/llvm-project/pull/134099 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Hlsl dst function (PR #133828)

2025-04-02 Thread Damyan Pepper via cfe-commits
@@ -35,6 +35,12 @@ length_vec_impl(vector X) { #endif } +template +constexpr vector dst_impl(vector src0, vector src1) { + vector dest = {1, src0[1] * src1[1], src0[2], src1[3]}; + return dest; +} damyanp wrote: Coding conventions: ```suggestion constexpr

[clang] [clang-tools-extra] [clang] support pack expansions for trailing requires clauses (PR #133190)

2025-04-02 Thread Matheus Izvekov via cfe-commits
mizvekov wrote: All done with the comments here. https://github.com/llvm/llvm-project/pull/133190 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [clang] support pack expansions for trailing requires clauses (PR #133190)

2025-04-02 Thread Matheus Izvekov via cfe-commits
https://github.com/mizvekov updated https://github.com/llvm/llvm-project/pull/133190 >From 4a6c03876d9f106df9913aeb66d484afc362454f Mon Sep 17 00:00:00 2001 From: Matheus Izvekov Date: Wed, 26 Mar 2025 18:38:34 -0300 Subject: [PATCH] [clang] support pack expansions for trailing requires clauses

  1   2   3   4   >