[llvm] [AArch64] Add optimizations that are not added as a result of custom lowering for min/max (PR #151880)
via llvm-commits
llvm-commits at lists.llvm.org
Sun Aug 3 15:21:14 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 cpp -- llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp b/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
index c99b07147..3fc661719 100644
--- a/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
+++ b/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
@@ -10980,7 +10980,7 @@ SDValue AArch64TargetLowering::LowerMinMax(SDValue Op,
}
}
- // umax(x,1) --> sub(x,cmpeq(x,0)) iff cmp result is allbits
+ // umax(x,1) --> sub(x,cmpeq(x,0)) iff cmp result is allbits
if (Opcode == ISD::UMAX && llvm::isOneOrOneSplat(Op1, true) && BoolVT == VT &&
getBooleanContents(VT) == ZeroOrNegativeOneBooleanContent) {
Op0 = DAG.getFreeze(Op0);
``````````
</details>
https://github.com/llvm/llvm-project/pull/151880
More information about the llvm-commits
mailing list