[llvm] [SCEV] Improve applyLoopGuards to support Mul (PR #83428)
via llvm-commits
llvm-commits at lists.llvm.org
Thu Feb 29 05:54:12 PST 2024
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 d1a461dbb2293d9258d400b5426f610bb5191228 84b4d5aff7b47205e1a7b512f57ac0b962ee3466 -- llvm/lib/Analysis/ScalarEvolution.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/llvm/lib/Analysis/ScalarEvolution.cpp b/llvm/lib/Analysis/ScalarEvolution.cpp
index 052ae4923d..ea6cb82b6f 100644
--- a/llvm/lib/Analysis/ScalarEvolution.cpp
+++ b/llvm/lib/Analysis/ScalarEvolution.cpp
@@ -15157,8 +15157,7 @@ const SCEV *ScalarEvolution::applyLoopGuards(const SCEV *Expr, const Loop *L) {
const SCEV *URemRHS = nullptr;
if (matchURem(LHS, URemLHS, URemRHS)) {
auto I = RewriteMap.find(URemLHS);
- const SCEV *RewrittenLHS =
- I != RewriteMap.end() ? I->second : URemLHS;
+ const SCEV *RewrittenLHS = I != RewriteMap.end() ? I->second : URemLHS;
RewrittenLHS = ApplyDivisibiltyOnMinMaxExpr(RewrittenLHS, URemRHS);
const auto *Multiple =
getMulExpr(getUDivExpr(RewrittenLHS, URemRHS), URemRHS);
``````````
</details>
https://github.com/llvm/llvm-project/pull/83428
More information about the llvm-commits
mailing list