[llvm] [ValueTracking] Handle recursive select/PHI in ComputeKnownBits/IsKnownNonZero (PR #114689)
via llvm-commits
llvm-commits at lists.llvm.org
Sat Nov 2 17:22:25 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 79178ca689a8259d19d93320a6299e3d31383ac4 3dfe4f0b2df671e7c4913e15c05465063140b0de --extensions cpp -- llvm/lib/Analysis/ValueTracking.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/llvm/lib/Analysis/ValueTracking.cpp b/llvm/lib/Analysis/ValueTracking.cpp
index c65a4c8001..48b450d826 100644
--- a/llvm/lib/Analysis/ValueTracking.cpp
+++ b/llvm/lib/Analysis/ValueTracking.cpp
@@ -1572,7 +1572,7 @@ static void computeKnownBitsFromOperator(const Operator *I,
// edges so we don't overly clamp analysis.
unsigned IncDepth = MaxAnalysisRecursionDepth - 1;
- Instruction *CxtI = P->getIncomingBlock(u)->getTerminator();
+ Instruction *CxtI = P->getIncomingBlock(u)->getTerminator();
// If the Use is a select of this phi, use the knownbit of the other
// operand to break the recursion.
if (auto *SI = dyn_cast<SelectInst>(IncValue)) {
``````````
</details>
https://github.com/llvm/llvm-project/pull/114689
More information about the llvm-commits
mailing list