[llvm] [ValueTracking] isNonEqual Pointers with with a recursive GEP (PR #70459)

David Green via llvm-commits llvm-commits at lists.llvm.org
Fri Dec 8 04:29:45 PST 2023


================
@@ -3141,6 +3141,63 @@ static bool isNonEqualSelect(const Value *V1, const Value *V2, unsigned Depth,
          isKnownNonEqual(SI1->getFalseValue(), V2, Depth + 1, Q);
 }
 
+static bool isNonEqualPointersWithRecursiveGEP(const Value *A, const Value *B,
+                                               unsigned Depth,
+                                               const SimplifyQuery &Q) {
+  // Where A is a recursive GEP for an incoming value of PHI indicating a
+  // loop. B can be a ptr/GEP.
+  // If the PHI has 2 incoming values, one of it being the recursive GEP A
----------------
davemgreen wrote:

it -> them

https://github.com/llvm/llvm-project/pull/70459


More information about the llvm-commits mailing list