[llvm] ConstraintElim: add dry-run routine to fail early (PR #99670)
via llvm-commits
llvm-commits at lists.llvm.org
Sun Jul 21 09:24:44 PDT 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 c5ee3c05ca61f3fae11337c5853aee7b450a9dc6 da823b79459619e7ce88327fc2d9d5b76c3cffc7 --extensions cpp -- llvm/lib/Transforms/Scalar/ConstraintElimination.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/llvm/lib/Transforms/Scalar/ConstraintElimination.cpp b/llvm/lib/Transforms/Scalar/ConstraintElimination.cpp
index 331b972c97..334fb8e5d6 100644
--- a/llvm/lib/Transforms/Scalar/ConstraintElimination.cpp
+++ b/llvm/lib/Transforms/Scalar/ConstraintElimination.cpp
@@ -1721,7 +1721,8 @@ static void dryRunAddFact(CmpInst::Predicate Pred, Value *A, Value *B,
}
for (const auto &KV : concat<DecompEntry>(AVars, BVars)) {
- if (KV.Variable == AStrip || KV.Variable == BStrip || !Value2Index.contains(KV.Variable))
+ if (KV.Variable == AStrip || KV.Variable == BStrip ||
+ !Value2Index.contains(KV.Variable))
++NumNewVars;
}
``````````
</details>
https://github.com/llvm/llvm-project/pull/99670
More information about the llvm-commits
mailing list