[clang] [llvm] [AArch64][SVE] Instcombine ptrue(all) to splat(i1) (PR #135016)
via llvm-commits
llvm-commits at lists.llvm.org
Wed Apr 9 07:03:25 PDT 2025
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff HEAD~1 HEAD --extensions c,cpp -- clang/test/CodeGen/AArch64/sve-acle-__ARM_FEATURE_SVE_VECTOR_OPERATORS.c clang/test/CodeGen/AArch64/sve-intrinsics/acle_sve_rdffr.c llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp b/llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp
index ae5792cc8..73b55a2dc 100644
--- a/llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp
+++ b/llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp
@@ -2649,8 +2649,7 @@ static std::optional<Instruction *> instCombinePTrue(InstCombiner &IC,
if (match(II.getOperand(0), m_ConstantInt(Pattern)) &&
Pattern->getZExtValue() == AArch64SVEPredPattern::all) {
Value *One = ConstantInt::get(Builder.getInt1Ty(), APInt(1, 1));
- Value *SplatOne =
- Builder.CreateVectorSplat(Type->getElementCount(), One);
+ Value *SplatOne = Builder.CreateVectorSplat(Type->getElementCount(), One);
return IC.replaceInstUsesWith(II, SplatOne);
}
return std::nullopt;
``````````
</details>
https://github.com/llvm/llvm-project/pull/135016
More information about the llvm-commits
mailing list