[clang] [SPIR-V] strengthen some lit tests (PR #111636)

2024-10-09 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl approved this pull request. https://github.com/llvm/llvm-project/pull/111636 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [lldb] [llvm] Propagate IsText parameter to openFileForRead function (PR #110661)

2024-10-09 Thread Abhina Sree via cfe-commits
abhina-sree wrote: > The default is set to OF_Text instead of OF_None, this change in value does > not affect any other platforms other than z/OS. Setting this parameter > correctly is required to open files on z/OS in the correct encoding. The > IsText parameter is based on the context of whe

[clang] [llvm] [HLSL] Implement `WaveReadLaneAt` intrinsic (PR #111010)

2024-10-09 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/111010 >From 70089645ec5cf62b491a56df96ec46f4328fbc11 Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Thu, 3 Oct 2024 11:43:51 -0700 Subject: [PATCH 01/11] [HLSL] Implement `WaveReadLaneAt` intrinsic - create a

[clang] [llvm] [HLSL] Implement `WaveReadLaneAt` intrinsic (PR #111010)

2024-10-09 Thread Finn Plummer via cfe-commits
@@ -87,6 +87,7 @@ class CGHLSLRuntime { GENERATE_HLSL_INTRINSIC_FUNCTION(SDot, sdot) GENERATE_HLSL_INTRINSIC_FUNCTION(UDot, udot) GENERATE_HLSL_INTRINSIC_FUNCTION(WaveIsFirstLane, wave_is_first_lane) + GENERATE_HLSL_INTRINSIC_FUNCTION(WaveReadLaneAt, waveReadLaneAt)

[clang] [Clang] Add explicit visibility symbol macros (PR #108276)

2024-10-09 Thread Aaron Ballman via cfe-commits
@@ -0,0 +1,67 @@ +//===-- clang/Support/Compiler.h - Compiler abstraction support -*- C++ -*-===// +// +// 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] [llvm] [HLSL][DXIL] Implement WaveGetLaneIndex Intrinsic (PR #111576)

2024-10-09 Thread Finn Plummer via cfe-commits
@@ -18827,9 +18827,21 @@ case Builtin::BI__builtin_hlsl_elementwise_isinf: { ArrayRef{Op0, Op1}, nullptr, "hlsl.step"); } case Builtin::BI__builtin_hlsl_wave_get_lane_index: { -return EmitRuntimeCall(CGM.CreateRuntimeFunction( -llvm::FunctionType::get(In

[clang] [llvm] [HLSL][DXIL] Implement WaveGetLaneIndex Intrinsic (PR #111576)

2024-10-09 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/111576 >From 167718e352554e167c4690a4962234ba782bceff Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Tue, 8 Oct 2024 09:28:43 -0700 Subject: [PATCH 1/3] [HLSL][DXIL] Implement WaveGetLaneIndex - add additional

[clang] [llvm] [HLSL][DXIL] Implement WaveGetLaneIndex Intrinsic (PR #111576)

2024-10-09 Thread Finn Plummer via cfe-commits
@@ -0,0 +1,6 @@ +// RUN: %clang_cc1 -finclude-default-header -triple dxil-pc-shadermodel6.6-library %s -fnative-half-type -emit-llvm-only -disable-llvm-passes -verify -verify-ignore-unexpected inbelic wrote: The flag was not needed, so have removed it. https:/

[clang] [clang][frontend] Add support for attribute plugins for statement attributes (PR #110334)

2024-10-09 Thread Eric Astor via cfe-commits
@@ -2125,6 +2126,19 @@ TemplateInstantiator::TransformTemplateParmRefExpr(DeclRefExpr *E, Arg, PackIndex); } +const AnnotateAttr * +TemplateInstantiator::TransformAnnotateAttr(const AnnotateAttr *AA) { + SmallVector Args; + for (Expr

[clang] clang should have a warning to disallow re-externs (PR #109714)

2024-10-09 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: I appreciate the idea, but I don't think it's a diagnostic we'd want to accept in Clang itself. We typically don't want to add new default-off diagnostics because there's plenty of evidence that they aren't enabled often enough to warrant having them. But also, this is real

[clang] Switch DirectX Target to use the Itanium ABI (PR #111632)

2024-10-09 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl approved this pull request. https://github.com/llvm/llvm-project/pull/111632 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CUDA/HIP] fix propagate -cuid to a host-only compilation. (PR #111650)

2024-10-09 Thread Artem Belevich via cfe-commits
Artem-B wrote: > This does not seem to be the right fix. I tends to think the test > https://github.com/ROCm/hip-tests/tree/amd-staging/samples/2_Cookbook/16_assembly_to_executable > needs fix. Since it does not expect host-only compilation to use CUID, it > should add `-fuse-cuid=none` to the

[clang] [llvm] [SystemZ][z/OS] Add new openFileForReadBinary function, and pass IsText parameter to getBufferForFile (PR #111723)

2024-10-09 Thread Sean Perry via cfe-commits
@@ -324,6 +330,17 @@ ErrorOr RealFileSystem::status(const Twine &Path) { ErrorOr> RealFileSystem::openFileForRead(const Twine &Name) { + SmallString<256> RealName, Storage; perry-ca wrote: Can you put this code into a static function or even a private member

[clang] [llvm] [SystemZ][z/OS] Add new openFileForReadBinary function, and pass IsText parameter to getBufferForFile (PR #111723)

2024-10-09 Thread Sean Perry via cfe-commits
@@ -117,8 +117,12 @@ FileSystem::~FileSystem() = default; ErrorOr> FileSystem::getBufferForFile(const llvm::Twine &Name, int64_t FileSize, - bool RequiresNullTerminator, bool IsVolatile) { - auto F = openFileForRead(Name); +

[clang] [clang] Allow `ConditionalOperator` fast-math flags to be overridden by `pragma float_control` (PR #105912)

2024-10-09 Thread Egor Chesakov via cfe-commits
echesakov wrote: > I made an alternative PR, which does not need changes in ConditionalOperator: > https://github.com/llvm/llvm-project/pull/111654. Thank you @spavloff , closing in favor of #111654 https://github.com/llvm/llvm-project/pull/105912 __

[clang] [Clang] Extend lifetime of temporaries in mem-default-init for P2718R0 (PR #86960)

2024-10-09 Thread via cfe-commits
yronglin wrote: I plan to merge in 24 hours if there are no further comments. https://github.com/llvm/llvm-project/pull/86960 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Reapply "[Clang][Sema] Refactor collection of multi-level template argument lists (#106585)" (PR #111173)

2024-10-09 Thread Krystian Stasiowski via cfe-commits
sdkrystian wrote: > Do you think you'll have a fix within a couple of hours @mstorsjo I think so. If not, I'll revert. https://github.com/llvm/llvm-project/pull/73 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-

[clang] [clang] assume_aligned incorrectly diagnoses a dependent return type (PR #111573)

2024-10-09 Thread Amr Hesham via cfe-commits
@@ -4453,9 +4453,9 @@ class Sema final : public SemaBase { SourceLocation *ArgLocation = nullptr); /// Determine if type T is a valid subject for a nonnull and similar - /// attributes. By default, we look through references (the behavi

[clang] Revert "[clang] Track function template instantiation from definition (#110387)" (PR #111764)

2024-10-09 Thread Krystian Stasiowski via cfe-commits
https://github.com/sdkrystian created https://github.com/llvm/llvm-project/pull/111764 This reverts commit 4336f00f2156970cc0af2816331387a0a4039317. >From 79468220ab383f24a86a3c52e0bf02a829992c5f Mon Sep 17 00:00:00 2001 From: Krystian Stasiowski Date: Wed, 9 Oct 2024 17:42:58 -0400 Subject: [

[clang] [Clang] prevent recovery call expression from proceeding with explicit attributes and undeclared templates (PR #107786)

2024-10-09 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/107786 >From e9948a1004cc2b486a0422d83e88392754e9f7e9 Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Mon, 23 Sep 2024 17:17:30 +0300 Subject: [PATCH 1/2] [Clang] prevent recovery call expression from proceeding w

[clang] 91dd4ec - Revert "[clang] Track function template instantiation from definition (#110387)" (#111764)

2024-10-09 Thread via cfe-commits
Author: Krystian Stasiowski Date: 2024-10-09T17:43:55-04:00 New Revision: 91dd4ec20e8371ea5e920f5493688e13306a67d2 URL: https://github.com/llvm/llvm-project/commit/91dd4ec20e8371ea5e920f5493688e13306a67d2 DIFF: https://github.com/llvm/llvm-project/commit/91dd4ec20e8371ea5e920f5493688e13306a67d2

[clang] Revert "[clang] Track function template instantiation from definition (#110387)" (PR #111764)

2024-10-09 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-modules Author: Krystian Stasiowski (sdkrystian) Changes This reverts commit 4336f00f2156970cc0af2816331387a0a4039317. --- Full diff: https://github.com/llvm/llvm-project/pull/111764.diff 12 Files Affected: - (modified) clang/docs/ReleaseNotes.

[clang] [llvm] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds (PR #90933)

2024-10-09 Thread Teresa Johnson via cfe-commits
https://github.com/teresajohnson approved this pull request. lgtm https://github.com/llvm/llvm-project/pull/90933 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Revert "[clang] Track function template instantiation from definition (#110387)" (PR #111764)

2024-10-09 Thread Krystian Stasiowski via cfe-commits
https://github.com/sdkrystian closed https://github.com/llvm/llvm-project/pull/111764 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Revert "Reapply "[Clang][Sema] Refactor collection of multi-level template argument lists (#106585)" (#111173)" (PR #111766)

2024-10-09 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Krystian Stasiowski (sdkrystian) Changes This reverts commit 4da8ac34f76e707ab94380b94f616457cfd2cb83. --- Patch is 103.80 KiB, truncated to 20.00 KiB below, full version: https://github.com/llvm/llvm-project/pull/111766.diff 20 Files

[clang] [Clang][perf-training] Do build of libLLVMSupport for perf training (PR #111625)

2024-10-09 Thread Tom Stellard via cfe-commits
https://github.com/tstellar edited https://github.com/llvm/llvm-project/pull/111625 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Revert "Reapply "[Clang][Sema] Refactor collection of multi-level template argument lists (#106585)" (#111173)" (PR #111766)

2024-10-09 Thread Krystian Stasiowski via cfe-commits
https://github.com/sdkrystian closed https://github.com/llvm/llvm-project/pull/111766 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][deps] Serialize JSON without creating intermediate objects (PR #111734)

2024-10-09 Thread Jan Svoboda via cfe-commits
https://github.com/jansvoboda11 updated https://github.com/llvm/llvm-project/pull/111734 >From c4c5b9cd372707a53cfe1948ab3881a8a64001a3 Mon Sep 17 00:00:00 2001 From: Jan Svoboda Date: Tue, 8 Oct 2024 16:21:40 -0700 Subject: [PATCH 1/2] [clang][deps] Serialize JSON without creating intermediat

[clang] c55d68f - [clang][deps] Serialize JSON without creating intermediate objects (#111734)

2024-10-09 Thread via cfe-commits
Author: Jan Svoboda Date: 2024-10-09T14:49:09-07:00 New Revision: c55d68fcc67d70235d6e4b75fe3879ab4d24a6b6 URL: https://github.com/llvm/llvm-project/commit/c55d68fcc67d70235d6e4b75fe3879ab4d24a6b6 DIFF: https://github.com/llvm/llvm-project/commit/c55d68fcc67d70235d6e4b75fe3879ab4d24a6b6.diff L

[clang] [clang][deps] Serialize JSON without creating intermediate objects (PR #111734)

2024-10-09 Thread Jan Svoboda via cfe-commits
https://github.com/jansvoboda11 closed https://github.com/llvm/llvm-project/pull/111734 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][perf-training] Do build of libLLVMSupport for perf training (PR #111625)

2024-10-09 Thread Tom Stellard via cfe-commits
tstellar wrote: > I'm assuming you used instrumented BOLT here? Also, do you have numbers on > how long the perf training took? Yes, it was instrumented BOLT. I've added the perf training times to the commit summary. https://github.com/llvm/llvm-project/pull/111625 _

[clang] Revert "[clang] Track function template instantiation from definition (#110387)" (PR #111764)

2024-10-09 Thread Krystian Stasiowski via cfe-commits
sdkrystian wrote: @mizvekov Sorry, will do so in the future! https://github.com/llvm/llvm-project/pull/111764 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Revert "Reapply "[Clang][Sema] Refactor collection of multi-level template argument lists (#106585)" (#111173)" (PR #111766)

2024-10-09 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 91dd4ec20e8371ea5e920f5493688e13306a67d2 88925f844c22b9c8b4f0bfce1ebc467d24a8854d --e

[clang] Revert "[clang] Track function template instantiation from definition (#110387)" (PR #111764)

2024-10-09 Thread Matheus Izvekov via cfe-commits
mizvekov wrote: FIY you should include revert reason on the commit message/ PR description. https://github.com/llvm/llvm-project/pull/111764 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-com

[clang] [Clang][perf-training] Do build of libLLVMSupport for perf training (PR #111625)

2024-10-09 Thread Tom Stellard via cfe-commits
https://github.com/tstellar updated https://github.com/llvm/llvm-project/pull/111625 >From 40efbcf0fd348625c892453d915eb7601adda917 Mon Sep 17 00:00:00 2001 From: Tom Stellard Date: Sat, 5 Oct 2024 17:17:33 + Subject: [PATCH 1/2] [Clang][perf-training] Do build of libLLVMSupport for perf t

[clang] [clang][deps] Serialize JSON without creating intermediate objects (PR #111734)

2024-10-09 Thread Jan Svoboda via cfe-commits
@@ -450,58 +458,65 @@ class FullDeps { ModuleIDs.push_back(M.first); llvm::sort(ModuleIDs); -using namespace llvm::json; - -Array OutModules; -for (auto &&ModID : ModuleIDs) { - auto &MD = Modules[ModID]; - Object O{{"name", MD.ID.ModuleName}, -

[clang] Reland: [clang] Finish implementation of P0522 (PR #111711)

2024-10-09 Thread Matheus Izvekov via cfe-commits
mizvekov wrote: No difference at all. It's just that the PR which will take care of the problem is not small, so I want to keep them separate and merge them all in one go. https://github.com/llvm/llvm-project/pull/111711 ___ cfe-commits mailing list c

[clang] [Clang][perf-training] Do build of libLLVMSupport for perf training (PR #111625)

2024-10-09 Thread Tom Stellard via cfe-commits
@@ -0,0 +1,2 @@ +RUN: %cmake -G %cmake_generator -B %t -S %llvm_src_dir -DCMAKE_C_COMPILER=%clang -DCMAKE_CXX_COMPILER=%clang -DCMAKE_CXX_FLAGS="--driver-mode=g++" -DCMAKE_BUILD_TYPE=Release tstellar wrote: The current bolt.lit.cfg substitutes `%clang_cpp` to `

[clang] [llvm] Adding splitdouble HLSL function (PR #109331)

2024-10-09 Thread via cfe-commits
@@ -264,6 +265,31 @@ class OpLowerer { return lowerToBindAndAnnotateHandle(F); } + Error replaceSplitDoubleCallUsages(CallInst *Intrin, CallInst *Op) { +IRBuilder<> &IRB = OpBuilder.getIRB(); + +for (Use &U : make_early_inc_range(Intrin->uses())) { + if (au

[clang] [NvlinkWrapper] Use `-plugin-opt=mattr=` instead of a custom feature (PR #111712)

2024-10-09 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Joseph Huber (jhuber6) Changes Summary: We don't need a custom flag for this, LLVM had a way to get the features which are forwarded via `plugin-opt`. --- Full diff: https://github.com/llvm/llvm-project/pull/111712.diff 4 Files Affected

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2024-10-09 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank commented: I like Mustache! Just took a quick look at this following your Discourse post. Do the custom allocators make any significant performance difference (measure)? Wouldn't want to prematurely optimize. They're the kind of thing that make maintenance annoying

[clang] [llvm] Add Smrnmi extension (PR #111668)

2024-10-09 Thread via cfe-commits
github-actions[bot] wrote: ⚠️ We detected that you are using a GitHub private e-mail address to contribute to the repo. Please turn off [Keep my email addresses private](https://github.com/settings/emails) setting in your account. See [LLVM Discourse](https://discourse.llvm.org/t/hidden-email

[clang] [Clang] fix overload resolution for object parameters with top-level cv-qualifiers in member functions (PR #110435)

2024-10-09 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/110435 >From c52634882631a71fad956a70179b480abf13006a Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Sun, 29 Sep 2024 22:01:38 +0300 Subject: [PATCH 1/3] [Clang] fix overload resolution for object parameters with

[clang] [llvm] Add Smrnmi extension (PR #111668)

2024-10-09 Thread Alex Bradbury via cfe-commits
asb wrote: Welcome to the project @dong-miao! I'm not sure why the auto-labeler didn't kick in to attach the backend:RISC-V label (this is used to help ping the right people), but I've added that now. Just two quick comments as it's end of day here so I can't review properly right now: * We t

[clang] [llvm] [InstrPGO] Instrument sampling profile based cold function (PR #109837)

2024-10-09 Thread Ellis Hoag via cfe-commits
@@ -1891,6 +1914,12 @@ static bool skipPGOGen(const Function &F) { return true; if (F.getInstructionCount() < PGOFunctionSizeThreshold) return true; + if (InstrumentColdFunctionCoverage) { +if (!F.getEntryCount()) + return InstrumentColdFunctionCoverageMode

[clang] [llvm] [SystemZ][z/OS] Add new openFileForReadBinary function, and pass IsText parameter to getBufferForFile (PR #111723)

2024-10-09 Thread Sean Perry via cfe-commits
@@ -302,6 +305,17 @@ class RealFileSystem : public FileSystem { return Storage; } + ErrorOr> openFileForRead(const Twine &Name, perry-ca wrote: np. I was misreading the diff. I didn't see it was a private member function. It looked like a file scop

[clang] [llvm] [HLSL] Implement the `degrees` intrinsic (PR #111209)

2024-10-09 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl approved this pull request. https://github.com/llvm/llvm-project/pull/111209 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [SystemZ][z/OS] Add new openFileForReadBinary function, and pass IsText parameter to getBufferForFile (PR #111723)

2024-10-09 Thread Abhina Sree via cfe-commits
@@ -302,6 +305,17 @@ class RealFileSystem : public FileSystem { return Storage; } + ErrorOr> openFileForRead(const Twine &Name, abhina-sree wrote: I don't think I'm able to mark it static because it calls adjustPath which is non-static https://github

[clang] [llvm] Adding splitdouble HLSL function (PR #109331)

2024-10-09 Thread via cfe-commits
@@ -18901,6 +18901,160 @@ case Builtin::BI__builtin_hlsl_elementwise_isinf: { CGM.getHLSLRuntime().getRadiansIntrinsic(), ArrayRef{Op0}, nullptr, "hlsl.radians"); } + // This should only be called when targeting DXIL + case Builtin::BI__builtin_hlsl_splitdou

[clang] [llvm] Adding splitdouble HLSL function (PR #109331)

2024-10-09 Thread via cfe-commits
@@ -489,6 +542,9 @@ class OpLowerer { case Intrinsic::dx_typedBufferStore: HasErrors |= lowerTypedBufferStore(F); break; + case Intrinsic::dx_splitdouble: joaosaffran wrote: I will resolve this conversation, since that is a topic we

[clang-tools-extra] 0aaac4f - [clang-tidy][performance-move-const-arg] Fix crash when argument type has no definition (#111472)

2024-10-09 Thread via cfe-commits
Author: Nicolas van Kempen Date: 2024-10-09T18:16:43-04:00 New Revision: 0aaac4fe194ae2249e1a01f9d6f5eac0d75c5bb2 URL: https://github.com/llvm/llvm-project/commit/0aaac4fe194ae2249e1a01f9d6f5eac0d75c5bb2 DIFF: https://github.com/llvm/llvm-project/commit/0aaac4fe194ae2249e1a01f9d6f5eac0d75c5bb2.

[clang-tools-extra] [clang-tidy][performance-move-const-arg] Fix crash when argument type has no definition (PR #111472)

2024-10-09 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank closed https://github.com/llvm/llvm-project/pull/111472 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [NFC][clang-tidy] Add type annotations to rename_check.py (PR #108443)

2024-10-09 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank closed https://github.com/llvm/llvm-project/pull/108443 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Adding splitdouble HLSL function (PR #109331)

2024-10-09 Thread Farzon Lotfi via cfe-commits
@@ -461,6 +479,27 @@ class OpLowerer { }); } + [[nodiscard]] bool lowerSplitDouble(Function &F) { +IRBuilder<> &IRB = OpBuilder.getIRB(); +return replaceFunction(F, [&](CallInst *CI) -> Error { + IRB.SetInsertPoint(CI); + + Value *Arg0 = CI->getArgOper

[clang-tools-extra] 4aba20f - [NFC][clang-tidy] Add type annotations to rename_check.py (#108443)

2024-10-09 Thread via cfe-commits
Author: Nicolas van Kempen Date: 2024-10-09T18:19:57-04:00 New Revision: 4aba20fecaa09089132afe451aa04a22cd3794ca URL: https://github.com/llvm/llvm-project/commit/4aba20fecaa09089132afe451aa04a22cd3794ca DIFF: https://github.com/llvm/llvm-project/commit/4aba20fecaa09089132afe451aa04a22cd3794ca.

[clang] [llvm] Adding splitdouble HLSL function (PR #109331)

2024-10-09 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl edited https://github.com/llvm/llvm-project/pull/109331 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Adding splitdouble HLSL function (PR #109331)

2024-10-09 Thread Farzon Lotfi via cfe-commits
@@ -18901,6 +18901,160 @@ case Builtin::BI__builtin_hlsl_elementwise_isinf: { CGM.getHLSLRuntime().getRadiansIntrinsic(), ArrayRef{Op0}, nullptr, "hlsl.radians"); } + // This should only be called when targeting DXIL + case Builtin::BI__builtin_hlsl_splitdou

[clang] [llvm] Adding splitdouble HLSL function (PR #109331)

2024-10-09 Thread via cfe-commits
@@ -461,6 +479,27 @@ class OpLowerer { }); } + [[nodiscard]] bool lowerSplitDouble(Function &F) { +IRBuilder<> &IRB = OpBuilder.getIRB(); +return replaceFunction(F, [&](CallInst *CI) -> Error { + IRB.SetInsertPoint(CI); + + Value *Arg0 = CI->getArgOper

[clang] [llvm] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds (PR #90933)

2024-10-09 Thread Kyungwoo Lee via cfe-commits
kyulee-com wrote: @teresajohnson Thank you for your review and valuable feedback! https://github.com/llvm/llvm-project/pull/90933 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] dc85d52 - [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds (#90933)

2024-10-09 Thread via cfe-commits
Author: Kyungwoo Lee Date: 2024-10-09T15:37:41-07:00 New Revision: dc85d5263ed5e416cb4ddf405611472f4ef12fd3 URL: https://github.com/llvm/llvm-project/commit/dc85d5263ed5e416cb4ddf405611472f4ef12fd3 DIFF: https://github.com/llvm/llvm-project/commit/dc85d5263ed5e416cb4ddf405611472f4ef12fd3.diff

[clang] [llvm] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds (PR #90933)

2024-10-09 Thread Kyungwoo Lee via cfe-commits
https://github.com/kyulee-com closed https://github.com/llvm/llvm-project/pull/90933 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Adding splitdouble HLSL function (PR #109331)

2024-10-09 Thread Farzon Lotfi via cfe-commits
@@ -461,6 +479,27 @@ class OpLowerer { }); } + [[nodiscard]] bool lowerSplitDouble(Function &F) { +IRBuilder<> &IRB = OpBuilder.getIRB(); +return replaceFunction(F, [&](CallInst *CI) -> Error { + IRB.SetInsertPoint(CI); + + Value *Arg0 = CI->getArgOper

[clang] [llvm] Adding splitdouble HLSL function (PR #109331)

2024-10-09 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl edited https://github.com/llvm/llvm-project/pull/109331 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Cuda] Handle -fcuda-short-ptr even with -nocudalib (PR #111682)

2024-10-09 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > I'm not sure why we would ever want the current default if this is an option. > I'm trying to see it, but I can't work out a case where a 64bit pointer would > make sense, since the even tens-of-thousands of money supercomputer cards > have less than 256KiB of addressable shar

[clang] Support BasedOnStyle referencing an arbitrary file (PR #110634)

2024-10-09 Thread Ryan Saunders via cfe-commits
https://github.com/jediry updated https://github.com/llvm/llvm-project/pull/110634 >From 82160d1e6de3f197c847bf8ed21ea1fc314b3cf4 Mon Sep 17 00:00:00 2001 From: Ryan Saunders Date: Tue, 1 Oct 2024 00:03:50 -0700 Subject: [PATCH 1/3] Support BasedOnStyle: file:blah.clang-format --- clang/inclu

[clang] [llvm] [AArch64] Introduce new armv9.6 features (PR #111677)

2024-10-09 Thread Jonathan Thackray via cfe-commits
@@ -522,6 +522,39 @@ def FeatureTLBIW : ExtensionWithMArch<"tlbiw", "TLBIW", "FEAT_TLBIW", // Armv9.6 Architecture Extensions //===--===// +def FeatureCMPBR : ExtensionWithMArch<"cmpbr", "CMPBR", "FEAT_CMPB

[clang] [clang] Allow `ConditionalOperator` fast-math flags to be overridden by `pragma float_control` (PR #105912)

2024-10-09 Thread Egor Chesakov via cfe-commits
https://github.com/echesakov closed https://github.com/llvm/llvm-project/pull/105912 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] fix overload resolution for object parameters with top-level cv-qualifiers in member functions (PR #110435)

2024-10-09 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/110435 >From c52634882631a71fad956a70179b480abf13006a Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Sun, 29 Sep 2024 22:01:38 +0300 Subject: [PATCH 1/3] [Clang] fix overload resolution for object parameters with

[clang] [clang] assume_aligned incorrectly diagnoses a dependent return type (PR #111573)

2024-10-09 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper edited https://github.com/llvm/llvm-project/pull/111573 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] clang should have a warning to disallow re-externs (PR #109714)

2024-10-09 Thread Jeffrey Crowell via cfe-commits
https://github.com/jchcrsp updated https://github.com/llvm/llvm-project/pull/109714 >From 8f512e2a8ad110b1a74c4283f81d4e28555e7567 Mon Sep 17 00:00:00 2001 From: Jeffrey Crowell Date: Mon, 23 Sep 2024 16:17:32 -0400 Subject: [PATCH] clang should have a warning to disallow re-externs clang shou

[clang] [Sema] Support negation/parens with __builtin_available (PR #111439)

2024-10-09 Thread George Burgess IV via cfe-commits
gburgessiv wrote: (...Or a reviewer will find me - thank you!) https://github.com/llvm/llvm-project/pull/111439 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Support negation/parens with __builtin_available (PR #111439)

2024-10-09 Thread George Burgess IV via cfe-commits
https://github.com/gburgessiv closed https://github.com/llvm/llvm-project/pull/111439 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 1553cb5 - [Sema] Support negation/parens with __builtin_available (#111439)

2024-10-09 Thread via cfe-commits
Author: George Burgess IV Date: 2024-10-09T10:40:53-06:00 New Revision: 1553cb5d3b14a0516c2796c295a3b32d147d13d0 URL: https://github.com/llvm/llvm-project/commit/1553cb5d3b14a0516c2796c295a3b32d147d13d0 DIFF: https://github.com/llvm/llvm-project/commit/1553cb5d3b14a0516c2796c295a3b32d147d13d0.d

[clang] [clang] assume_aligned incorrectly diagnoses a dependent return type (PR #111573)

2024-10-09 Thread Amr Hesham via cfe-commits
AmrDeveloper wrote: > > This part in ObjectiveC tests conflict with the current solution, any > > suggestion how we can go around it right now until to be handled later > > https://github.com/llvm/llvm-project/blob/18952bdcd6f987620e6396261c2bb444e428e07e/clang/test/SemaObjCXX/noescape.mm#L202-L

[clang] [clang] assume_aligned incorrectly diagnoses a dependent return type (PR #111573)

2024-10-09 Thread Amr Hesham via cfe-commits
@@ -4453,9 +4453,9 @@ class Sema final : public SemaBase { SourceLocation *ArgLocation = nullptr); /// Determine if type T is a valid subject for a nonnull and similar - /// attributes. By default, we look through references (the behavi

[clang] [clang] assume_aligned incorrectly diagnoses a dependent return type (PR #111573)

2024-10-09 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper edited https://github.com/llvm/llvm-project/pull/111573 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] assume_aligned incorrectly diagnoses a dependent return type (PR #111573)

2024-10-09 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper edited https://github.com/llvm/llvm-project/pull/111573 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Adding splitdouble HLSL function (PR #109331)

2024-10-09 Thread Farzon Lotfi via cfe-commits
@@ -18901,6 +18901,160 @@ case Builtin::BI__builtin_hlsl_elementwise_isinf: { CGM.getHLSLRuntime().getRadiansIntrinsic(), ArrayRef{Op0}, nullptr, "hlsl.radians"); } + // This should only be called when targeting DXIL farzonl wrote: This comm

[clang] [llvm] Adding splitdouble HLSL function (PR #109331)

2024-10-09 Thread Farzon Lotfi via cfe-commits
@@ -18901,6 +18901,160 @@ case Builtin::BI__builtin_hlsl_elementwise_isinf: { CGM.getHLSLRuntime().getRadiansIntrinsic(), ArrayRef{Op0}, nullptr, "hlsl.radians"); } + // This should only be called when targeting DXIL + case Builtin::BI__builtin_hlsl_splitdou

[clang] clang should have a warning to disallow re-externs (PR #109714)

2024-10-09 Thread Jeffrey Crowell via cfe-commits
jchcrsp wrote: Ping fixed merge conflict https://github.com/llvm/llvm-project/pull/109714 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] assume_aligned incorrectly diagnoses a dependent return type (PR #111573)

2024-10-09 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/111573 >From 3e83fd9e73520bfeefd5a39da6daad172cfb2512 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Tue, 8 Oct 2024 20:12:45 +0200 Subject: [PATCH] [clang] assume_aligned incorrectly diagnoses a dependent ret

[clang] [llvm] Adding splitdouble HLSL function (PR #109331)

2024-10-09 Thread Farzon Lotfi via cfe-commits
@@ -18901,6 +18901,160 @@ case Builtin::BI__builtin_hlsl_elementwise_isinf: { CGM.getHLSLRuntime().getRadiansIntrinsic(), ArrayRef{Op0}, nullptr, "hlsl.radians"); } + // This should only be called when targeting DXIL + case Builtin::BI__builtin_hlsl_splitdou

[clang] [llvm] Adding splitdouble HLSL function (PR #109331)

2024-10-09 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl edited https://github.com/llvm/llvm-project/pull/109331 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Reland: [clang] Finish implementation of P0522 (PR #111711)

2024-10-09 Thread Matheus Izvekov via cfe-commits
https://github.com/mizvekov created https://github.com/llvm/llvm-project/pull/111711 This finishes the clang implementation of P0522, getting rid of the fallback to the old, pre-P0522 rules. Before this patch, when partial ordering template template parameters, we would perform, in order: * I

[clang] [clang] assume_aligned incorrectly diagnoses a dependent return type (PR #111573)

2024-10-09 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/111573 >From d3f853895e806ebe2370dafdc628a21d0d4184a6 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Tue, 8 Oct 2024 20:12:45 +0200 Subject: [PATCH] [clang] assume_aligned incorrectly diagnoses a dependent ret

[clang] [llvm] Update llvm::Registry to work for LLVM shared library builds on windows (PR #109024)

2024-10-09 Thread Thomas Fransham via cfe-commits
fsfod wrote: > These changes LGTM but precommit CI was unable to run, so it would be nice if > that could be re-run to ensure it comes back green before landing. It won't be able to pass until https://github.com/llvm/llvm-project/pull/108276 is merged. https://github.com/llvm/llvm-project/pul

[clang] [analyzer] Modernize FuchsiaHandleChecker (PR #111588)

2024-10-09 Thread Pavel Skripkin via cfe-commits
https://github.com/pskrgag edited https://github.com/llvm/llvm-project/pull/111588 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Add Smrnmi extension (PR #111668)

2024-10-09 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-risc-v Author: None (dong-miao) Changes This commit has completed the Extension for Resumable Non Maskable Interrupts, adding four CRSs and one Trap-Return instruction. Specification link:["Smrnmi" Extension](https://github.com/riscv/riscv-isa-

[clang] Reland: [clang] Finish implementation of P0522 (PR #111711)

2024-10-09 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang @llvm/pr-subscribers-clang-modules Author: Matheus Izvekov (mizvekov) Changes This finishes the clang implementation of P0522, getting rid of the fallback to the old, pre-P0522 rules. Before this patch, when partial ordering template template par

[clang] [clang] assume_aligned incorrectly diagnoses a dependent return type (PR #111573)

2024-10-09 Thread Amr Hesham via cfe-commits
AmrDeveloper wrote: > > This part in ObjectiveC tests conflict with the current solution, any > > suggestion how we can go around it right now until to be handled later > > https://github.com/llvm/llvm-project/blob/18952bdcd6f987620e6396261c2bb444e428e07e/clang/test/SemaObjCXX/noescape.mm#L202-L

[clang-tools-extra] [clang-tidy] Create bugprone-bitwise-pointer-cast check (PR #108083)

2024-10-09 Thread LLVM Continuous Integration via cfe-commits
Carlos =?utf-8?q?Gálvez?= Message-ID: In-Reply-To: llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `clang-s390x-linux-multistage` running on `systemz-1` while building `clang-tools-extra` at step 5 "ninja check 1". Full details are available at: https://lab.llvm.org/buil

[clang] [NvlinkWrapper] Use `-plugin-opt=mattr=` instead of a custom feature (PR #111712)

2024-10-09 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 created https://github.com/llvm/llvm-project/pull/111712 Summary: We don't need a custom flag for this, LLVM had a way to get the features which are forwarded via `plugin-opt`. >From 6135a70a45801783a770252e765773905f18313d Mon Sep 17 00:00:00 2001 From: Joseph Huber

[clang] [llvm] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds (PR #90933)

2024-10-09 Thread Teresa Johnson via cfe-commits
@@ -1513,6 +1522,171 @@ class InProcessThinBackend : public ThinBackendProc { return Error::success(); } }; + +/// This backend is utilized in the first round of a two-codegen round process. +/// It first saves optimized bitcode files to disk before the codegen process +/

[clang] [llvm] [HLSL] Implement the `degrees` intrinsic (PR #111209)

2024-10-09 Thread Greg Roth via cfe-commits
@@ -0,0 +1,64 @@ +// RUN: %clang_cc1 -finclude-default-header -x hlsl -triple \ +// RUN: dxil-pc-shadermodel6.3-library %s -fnative-half-type \ +// RUN: -emit-llvm -disable-llvm-passes -o - | FileCheck %s \ +// RUN: --check-prefixes=CHECK,NATIVE_HALF \ +// RUN: -DFNATTRS=n

[clang] [llvm] [HLSL] Implement the `degrees` intrinsic (PR #111209)

2024-10-09 Thread Greg Roth via cfe-commits
https://github.com/pow2clk edited https://github.com/llvm/llvm-project/pull/111209 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL] Implement the `degrees` intrinsic (PR #111209)

2024-10-09 Thread Greg Roth via cfe-commits
@@ -0,0 +1,26 @@ +// RUN: %clang_cc1 -finclude-default-header -triple dxil-pc-shadermodel6.6-library %s -fnative-half-type -emit-llvm-only -disable-llvm-passes -verify -verify-ignore-unexpected pow2clk wrote: I'll copy my comment from elsewhere here: Are you

[clang] [llvm] [HLSL] Implement the `degrees` intrinsic (PR #111209)

2024-10-09 Thread Greg Roth via cfe-commits
@@ -0,0 +1,68 @@ +; RUN: llc -verify-machineinstrs -O0 -mtriple=spirv-unknown-unknown %s -o - | FileCheck %s +; RUN: %if spirv-tools %{ llc -O0 -mtriple=spirv-unknown-unknown %s -o - -filetype=obj | spirv-val %} + +; CHECK-DAG: %[[#op_ext_glsl:]] = OpExtInstImport "GLSL.std.450"

[clang] [llvm] [HLSL] Implement the `degrees` intrinsic (PR #111209)

2024-10-09 Thread Greg Roth via cfe-commits
@@ -0,0 +1,54 @@ +; RUN: opt -S -dxil-intrinsic-expansion -scalarizer -dxil-op-lower -mtriple=dxil-pc-shadermodel6.3-library %s | FileCheck %s + +; Make sure dxil op function calls for degrees are expanded and lowered as fmul for float and half. + +define noundef half @degrees_h

[clang] [llvm] [HLSL] Implement the `degrees` intrinsic (PR #111209)

2024-10-09 Thread Greg Roth via cfe-commits
https://github.com/pow2clk commented: None of my suggestions are essential, but I'll give you a chance to consider them even if you reject them all before I approve. https://github.com/llvm/llvm-project/pull/111209 ___ cfe-commits mailing list cfe-com

[clang] [llvm] [HLSL] Implement the `degrees` intrinsic (PR #111209)

2024-10-09 Thread Greg Roth via cfe-commits
@@ -0,0 +1,54 @@ +; RUN: opt -S -dxil-intrinsic-expansion -scalarizer -dxil-op-lower -mtriple=dxil-pc-shadermodel6.3-library %s | FileCheck %s + +; Make sure dxil op function calls for degrees are expanded and lowered as fmul for float and half. + +define noundef half @degrees_h

  1   2   3   4   5   6   >