[llvm] [ValueTracking] Handle recursive select/PHI in ComputeKnownBits (PR #114689)
Thorsten Schütt via llvm-commits
llvm-commits at lists.llvm.org
Sun Nov 3 10:19:45 PST 2024
================
@@ -580,6 +580,42 @@ static bool cmpExcludesZero(CmpInst::Predicate Pred, const Value *RHS) {
return true;
}
+static void breakSelfRecursivePHI(const Use *U, const PHINode *PHI,
+ Value *&ValOut, Instruction *&CtxIOut,
+ unsigned *DepthInOut = nullptr) {
+ ValOut = U->get();
+ if (ValOut == PHI)
+ return;
+ CtxIOut = PHI->getIncomingBlock(*U)->getTerminator();
+ Value *V;
+ // If the Use is a select of this phi, compute analysis on other arm to be
----------------
tschuett wrote:
`be` or `break` ?
https://github.com/llvm/llvm-project/pull/114689
More information about the llvm-commits
mailing list