[llvm] [indvars] Prove non-negative for widening IVs in count down loops (PR #71214)
via llvm-commits
llvm-commits at lists.llvm.org
Fri Nov 3 11:15:11 PDT 2023
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 49168b2512ef55e225e9b7cd0821daa5c8ae5a9b 7078504bdf3e69414d7d44332e794072c6509328 -- llvm/lib/Transforms/Utils/SimplifyIndVar.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/llvm/lib/Transforms/Utils/SimplifyIndVar.cpp b/llvm/lib/Transforms/Utils/SimplifyIndVar.cpp
index dd8bef69ad17..ce018f3eb11e 100644
--- a/llvm/lib/Transforms/Utils/SimplifyIndVar.cpp
+++ b/llvm/lib/Transforms/Utils/SimplifyIndVar.cpp
@@ -1918,7 +1918,7 @@ bool WidenIV::isKnownNonNegative(const SCEV *S) {
const SCEV *N = SE->getConstant(APInt::getMaxValue(BitWidth) -
SE->getSignedRangeMin(Step));
return SE->isLoopBackedgeGuardedByCond(L, ICmpInst::ICMP_UGT, AR, N) ||
- SE->isLoopBackedgeGuardedByCond(L, ICmpInst::ICMP_UGT, PostInc, N);
+ SE->isLoopBackedgeGuardedByCond(L, ICmpInst::ICMP_UGT, PostInc, N);
}
/// Add eligible users of NarrowDef to NarrowIVUsers.
``````````
</details>
https://github.com/llvm/llvm-project/pull/71214
More information about the llvm-commits
mailing list