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 e258bca9505f35e0a22cb213a305eea9b76d11ea
5fffbe4f50a9870ec778db840abd02655efe670a --e
Author: Nick Sarnie
Date: 2025-02-12T16:40:05Z
New Revision: cb3498c6704daefc6e5221beb757126765737aa7
URL:
https://github.com/llvm/llvm-project/commit/cb3498c6704daefc6e5221beb757126765737aa7
DIFF:
https://github.com/llvm/llvm-project/commit/cb3498c6704daefc6e5221beb757126765737aa7.diff
LOG: [
https://github.com/sarnex closed
https://github.com/llvm/llvm-project/pull/126801
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
kiranchandramohan wrote:
> > Also, I don't have a very strong opinion about this, but it seems
> > misleading to have the `DoConcurrentConversionToOpenMP.md` document be
> > written as if all of the features in the ROCm fork were already present,
> > with the last section only implying that n
https://github.com/steakhal approved this pull request.
https://github.com/llvm/llvm-project/pull/126941
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -96,6 +100,47 @@ the header file to conditionally make a
function constexpr whenever
the constant evaluation of the corresponding builtin (for example,
``std::fmax`` calls ``__builtin_fmax``) is supported in Clang.
+``__has_target_builtin``
+
+
@@ -96,6 +100,55 @@ the header file to conditionally make a
function constexpr whenever
the constant evaluation of the corresponding builtin (for example,
``std::fmax`` calls ``__builtin_fmax``) is supported in Clang.
+``__has_target_builtin``
+
+
@@ -,6 +,105 @@ void CodeGenFunction::EmitOMPMasterDirective(const
OMPMasterDirective &S) {
emitMaster(*this, S);
}
+static Expr *getInitialExprFromCapturedExpr(Expr *Cond) {
SunilKuravinakop wrote:
The code has changed. I do not have this any more
llvmbot wrote:
@llvm/pr-subscribers-clang
Author: Miguel A. Arroyo (mayanez)
Changes
Fixes the changes introduced in
https://github.com/llvm/llvm-project/pull/126675 and subsequently reverted by
https://github.com/llvm/llvm-project/pull/126934 .
Originally, I mistakenly put the `install
llvmbot wrote:
@llvm/pr-subscribers-platform-windows
Author: Miguel A. Arroyo (mayanez)
Changes
Fixes the changes introduced in
https://github.com/llvm/llvm-project/pull/126675 and subsequently reverted by
https://github.com/llvm/llvm-project/pull/126934 .
Originally, I mistakenly put t
tsepez wrote:
Ok, I believe I have updated the patch in the correct place, please take a look.
https://github.com/llvm/llvm-project/pull/126826
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-
@@ -2624,9 +2624,8 @@ void CGOpenMPRuntime::emitDistributeStaticInit(
emitUpdateLocation(CGF, Loc, OMP_IDENT_WORK_DISTRIBUTE);
llvm::Value *ThreadId = getThreadID(CGF, Loc);
llvm::FunctionCallee StaticInitFunction;
- bool isGPUDistribute =
- CGM.getLangOpts().Op
rnk wrote:
This is an observable behavior change, so it should have a test. There's a test
for this header at clang/test/Headers/ms-intrins.cpp that you can extend. You
probably need to add a new RUN line that adds `-mrtm` or some other
micro-architectural feature so that rtmintrin.h declares
https://github.com/tsepez updated
https://github.com/llvm/llvm-project/pull/126826
>From a1c97178f02dd93e6ae28416273ff7cebfa49d45 Mon Sep 17 00:00:00 2001
From: Tom Sepez
Date: Tue, 11 Feb 2025 23:54:10 +
Subject: [PATCH 1/2] [-Wunsafe-buffer-usage] add test for constexpr size in
snprintf
@@ -1338,9 +1338,7 @@ struct InformationCache {
bool stackIsAccessibleByOtherThreads() { return !targetIsGPU(); }
/// Return true if the target is a GPU.
- bool targetIsGPU() {
-return TargetTriple.isAMDGPU() || TargetTriple.isNVPTX();
- }
+ bool targetIsGPU() { ret
@@ -2624,9 +2624,8 @@ void CGOpenMPRuntime::emitDistributeStaticInit(
emitUpdateLocation(CGF, Loc, OMP_IDENT_WORK_DISTRIBUTE);
llvm::Value *ThreadId = getThreadID(CGF, Loc);
llvm::FunctionCallee StaticInitFunction;
- bool isGPUDistribute =
- CGM.getLangOpts().Op
https://github.com/aeubanks updated
https://github.com/llvm/llvm-project/pull/124834
>From 7c40169ec7430ec64aaeb053e423eca1ceff7f0d Mon Sep 17 00:00:00 2001
From: Arthur Eubanks
Date: Tue, 28 Jan 2025 20:36:58 +
Subject: [PATCH 1/9] [clang][X86] Support
__attribute__((model("small"/"large"
llvmbot wrote:
@llvm/pr-subscribers-llvm-transforms
Author: Nick Sarnie (sarnex)
Changes
I'm adding support for SPIR-V, so let's consolidate these checks.
---
Full diff: https://github.com/llvm/llvm-project/pull/126956.diff
11 Files Affected:
- (modified) clang/lib/CodeGen/CGOpenMPRunt
@@ -1109,6 +1109,11 @@ class Triple {
Env == llvm::Triple::EABIHF;
}
+ /// Tests if the target represents a GPU which can be offloaded to.
+ bool isOffloadingTargetGPU() const {
shiltian wrote:
Is it better to use `isOffloadingTarget`?
https:/
https://github.com/sarnex edited
https://github.com/llvm/llvm-project/pull/126324
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/momchil-velikov unassigned
https://github.com/llvm/llvm-project/pull/126945
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
llvm-ci wrote:
LLVM Buildbot has detected a new failure on builder `ml-opt-rel-x86-64` running
on `ml-opt-rel-x86-64-b2` while building `clang,llvm` at step 6
"test-build-unified-tree-check-all".
Full details are available at:
https://lab.llvm.org/buildbot/#/builders/185/builds/13063
Here i
llvm-ci wrote:
LLVM Buildbot has detected a new failure on builder `mlir-nvidia` running on
`mlir-nvidia` while building `clang,llvm` at step 7
"test-build-check-mlir-build-only-check-mlir".
Full details are available at:
https://lab.llvm.org/buildbot/#/builders/138/builds/10230
Here is the
llvm-ci wrote:
LLVM Buildbot has detected a new failure on builder
`llvm-clang-x86_64-win-fast` running on `as-builder-3` while building
`clang,llvm` at step 7 "test-build-unified-tree-check-llvm-unit".
Full details are available at:
https://lab.llvm.org/buildbot/#/builders/2/builds/16997
H
hvdijk wrote:
The buildbot failures look like something conflicted with changes that have
since gone in on LLVM. I have reverted the change for now and will check what
is going on and update.
https://github.com/llvm/llvm-project/pull/126059
___
cfe-c
yxsamliu wrote:
ping
https://github.com/llvm/llvm-project/pull/114841
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
rj-jesus wrote:
I believe this fixes #113297, right?
https://github.com/llvm/llvm-project/pull/126945
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -491,6 +491,31 @@ static bool isTrivialFiller(Expr *E) {
return false;
}
+static void EmitHLSLSplatCast(CodeGenFunction &CGF, Address DestVal,
+ QualType DestTy, llvm::Value *SrcVal,
+ QualType SrcTy, SourceLocatio
@@ -0,0 +1,87 @@
+// RUN: %clang_cc1 -finclude-default-header -triple
dxil-pc-shadermodel6.3-library -x hlsl -emit-llvm -disable-llvm-passes -o - %s
| FileCheck %s
+
+// array splat
+// CHECK-LABEL: define void {{.*}}call4
+// CHECK: [[B:%.*]] = alloca [2 x i32], align 4
+// CHE
@@ -2804,6 +2804,42 @@ bool SemaHLSL::ContainsBitField(QualType BaseTy) {
return false;
}
+// Can perform an HLSL splat cast if the Dest is an aggregate and the
+// Src is a scalar or a vector of length 1
+// Or if Dest is a vector and Src is a vector of length 1
+bool SemaH
@@ -2804,6 +2804,42 @@ bool SemaHLSL::ContainsBitField(QualType BaseTy) {
return false;
}
+// Can perform an HLSL splat cast if the Dest is an aggregate and the
+// Src is a scalar or a vector of length 1
+// Or if Dest is a vector and Src is a vector of length 1
+bool SemaH
SunilKuravinakop wrote:
> Hi!
>
> FYI -- I have a partial implementation of semantic & codegen support for
> "dispatch" directives also. I've created a draft PR for it here: #126914
>
> Obviously there's no point in duplicating effort on this feature, but perhaps
> bits from my implementation
@@ -115,10 +115,19 @@ class LLVM_LIBRARY_VISIBILITY SystemZTargetInfo : public
TargetInfo {
return RegName == "r15";
}
+ // CC has interval [0, 4).
+ unsigned getFlagOutputCCUpperBound() const override { return 4; }
bool validateAsmConstraint(const char *&Name,
@@ -8132,7 +8722,9 @@ SDValue SystemZTargetLowering::combineBR_CCMASK(
SDValue Chain = N->getOperand(0);
SDValue CCReg = N->getOperand(4);
- if (combineCCMask(CCReg, CCValidVal, CCMaskVal))
+ // combineCCIPMMask tries to combine srl/ipm sequence for flag output
operand.
@@ -2837,8 +2837,37 @@ void SelectionDAGBuilder::visitBr(const BranchInst &I) {
Opcode = Instruction::And;
else if (match(BOp, m_LogicalOr(m_Value(BOp0), m_Value(BOp1
Opcode = Instruction::Or;
-
-if (Opcode &&
+auto &TLI = DAG.getTargetLoweringInfo()
@@ -1689,6 +1696,35 @@ Register
SystemZTargetLowering::getExceptionSelectorRegister(
return Subtarget.isTargetXPLINK64() ? SystemZ::R2D : SystemZ::R7D;
}
+// Lower @cc targets via setcc.
+SDValue SystemZTargetLowering::LowerAsmOutputForConstraint(
+SDValue &Chain, SDVal
https://github.com/melver updated
https://github.com/llvm/llvm-project/pull/123063
>From 6727047d25b8b72f8e23b03a84c0b23f6dad566a Mon Sep 17 00:00:00 2001
From: Marco Elver
Date: Wed, 15 Jan 2025 13:23:14 +0100
Subject: [PATCH 1/5] Thread Safety Analysis: Support warning on obtaining
address o
@@ -515,8 +515,18 @@ Warning flags
+ ``-Wthread-safety-analysis``: The core analysis.
+ ``-Wthread-safety-precise``: Requires that mutex expressions match
precisely.
This warning can be disabled for code which has a lot of aliases.
- + ``-Wthread-safety-reference``
https://github.com/krzysz00 updated
https://github.com/llvm/llvm-project/pull/126828
>From 457350589fc4c4295a212025873ab4b90124e02f Mon Sep 17 00:00:00 2001
From: Krzysztof Drewniak
Date: Tue, 11 Feb 2025 23:55:36 +
Subject: [PATCH 1/3] [AMDGPU] Generalize amdgcn.make.buffer.rsrc to fat
po
@@ -96,6 +100,47 @@ the header file to conditionally make a
function constexpr whenever
the constant evaluation of the corresponding builtin (for example,
``std::fmax`` calls ``__builtin_fmax``) is supported in Clang.
+``__has_target_builtin``
+
+
llvm-ci wrote:
LLVM Buildbot has detected a new failure on builder
`llvm-nvptx64-nvidia-ubuntu` running on `as-builder-7` while building
`clang,llvm` at step 6 "test-build-unified-tree-check-llvm".
Full details are available at:
https://lab.llvm.org/buildbot/#/builders/160/builds/12905
Here
@@ -96,6 +100,47 @@ the header file to conditionally make a
function constexpr whenever
the constant evaluation of the corresponding builtin (for example,
``std::fmax`` calls ``__builtin_fmax``) is supported in Clang.
+``__has_target_builtin``
+
+
@@ -50,6 +51,42 @@ findCallsAtConstantOffset(SmallVectorImpl
&DevirtCalls,
}
}
+static bool hasTypeIdLoadAtConstantOffset(const Module *M, Value *VPtr,
+ int64_t Offset, const CallInst *CI,
+
https://github.com/teresajohnson commented:
Thanks for sending the PR! I think this should enable some nice size savings
hopefully.
I went through most of it (though not the bitcode or llvm assembler changes
yet). A couple of concerns:
- It doesn't look like it is guarded on whole program visi
@@ -0,0 +1,49 @@
+#include "llvm/Transforms/IPO/DeadRTTIElimination.h"
+#include "llvm/ADT/Statistic.h"
+#include "llvm/IR/ModuleSummaryIndex.h"
+#include "llvm/Support/Debug.h"
+#include "llvm/Support/LibCXXABI.h"
+
+using namespace llvm;
+
+#define DEBUG_TYPE "dre"
+
+STATISTIC(
@@ -573,14 +574,29 @@ static void dropDeadSymbols(Module &Mod, const
GVSummaryMapTy &DefinedGlobals,
convertToDeclaration(GV);
}
+ Triple TT(Mod.getTargetTriple());
+ std::unique_ptr ABI = CXXABI::Create(TT);
+
// Now that all dead bodies have been dropped,
@@ -115,10 +115,19 @@ class LLVM_LIBRARY_VISIBILITY SystemZTargetInfo : public
TargetInfo {
return RegName == "r15";
}
+ // CC has interval [0, 4).
+ unsigned getFlagOutputCCUpperBound() const override { return 4; }
bool validateAsmConstraint(const char *&Name,
llvm-ci wrote:
LLVM Buildbot has detected a new failure on builder `llvm-x86_64-debian-dylib`
running on `gribozavr4` while building `clang,llvm` at step 7
"test-build-unified-tree-check-llvm".
Full details are available at:
https://lab.llvm.org/buildbot/#/builders/60/builds/19454
Here is t
https://github.com/sarnex edited
https://github.com/llvm/llvm-project/pull/126956
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
llvm-ci wrote:
LLVM Buildbot has detected a new failure on builder
`llvm-clang-x86_64-expensive-checks-debian` running on `gribozavr4` while
building `clang,llvm` at step 6 "test-build-unified-tree-check-all".
Full details are available at:
https://lab.llvm.org/buildbot/#/builders/16/builds/1
https://github.com/sarnex edited
https://github.com/llvm/llvm-project/pull/126956
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/sarnex edited
https://github.com/llvm/llvm-project/pull/126956
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/sarnex ready_for_review
https://github.com/llvm/llvm-project/pull/126956
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
llvm-ci wrote:
LLVM Buildbot has detected a new failure on builder `clang-x86_64-debian-fast`
running on `gribozavr4` while building `clang,llvm` at step 6
"test-build-unified-tree-check-all".
Full details are available at:
https://lab.llvm.org/buildbot/#/builders/56/builds/18511
Here is th
llvmbot wrote:
@llvm/pr-subscribers-clang-codegen
@llvm/pr-subscribers-compiler-rt-sanitizer
Author: Nick Sarnie (sarnex)
Changes
I'm adding support for SPIR-V, so let's consolidate these checks.
---
Full diff: https://github.com/llvm/llvm-project/pull/126956.diff
11 Files Affected:
-
https://github.com/fmayer closed
https://github.com/llvm/llvm-project/pull/126163
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
fmayer wrote:
Sorry, I made a mistake. This should not be needed.
https://github.com/llvm/llvm-project/pull/126163
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,194 @@
+#include "clang/Parse/ParseHLSLRootSignature.h"
+
+namespace clang {
+namespace hlsl {
+
+// Lexer Definitions
+
+static bool IsNumberChar(char C) {
+ // TODO(#126565): extend for float support exponents
+ return isdigit(C); // integer support
+}
+
+bool RootS
https://github.com/aeubanks updated
https://github.com/llvm/llvm-project/pull/124834
>From 7c40169ec7430ec64aaeb053e423eca1ceff7f0d Mon Sep 17 00:00:00 2001
From: Arthur Eubanks
Date: Tue, 28 Jan 2025 20:36:58 +
Subject: [PATCH 01/10] [clang][X86] Support
__attribute__((model("small"/"larg
@@ -2964,20 +2963,36 @@ static bool isValidCodeModelAttr(Sema &S, StringRef
Str) {
static void handleCodeModelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {
StringRef Str;
SourceLocation LiteralLoc;
+ auto IsTripleSupported = [](const llvm::Triple Triple) {
+return Tr
@@ -2950,12 +2950,11 @@ static void handleSectionAttr(Sema &S, Decl *D, const
ParsedAttr &AL) {
}
}
-static bool isValidCodeModelAttr(Sema &S, StringRef Str) {
- if (S.Context.getTargetInfo().getTriple().isLoongArch()) {
+static bool isValidCodeModelAttr(llvm::Triple Tripl
@@ -2964,20 +2963,36 @@ static bool isValidCodeModelAttr(Sema &S, StringRef
Str) {
static void handleCodeModelAttr(Sema &S, Decl *D, const ParsedAttr &AL) {
StringRef Str;
SourceLocation LiteralLoc;
+ auto IsTripleSupported = [](const llvm::Triple Triple) {
+return Tr
https://github.com/compnerd approved this pull request.
https://github.com/llvm/llvm-project/pull/126961
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
llvm-ci wrote:
LLVM Buildbot has detected a new failure on builder `clang-s390x-linux-lnt`
running on `systemz-1` while building `clang` at step 7 "ninja check 1".
Full details are available at:
https://lab.llvm.org/buildbot/#/builders/136/builds/2772
Here is the relevant piece of the build
tex3d wrote:
> How does it not duplicate sub-expressions while also not creating temporary
> variables to capture results?
The way I thought of to comprehensively solve this in a clear general way was
to:
- create a new temporary with an anonymous struct type containing the exact
sequence of
501 - 565 of 565 matches
Mail list logo