[PATCH] D38637: [InstSimplify] don't let poison inhibit an easy fold

Sanjay Patel via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Oct 7 08:55:46 PDT 2017


spatel added inline comments.


================
Comment at: lib/Analysis/ValueTracking.cpp:822-824
+  // If the shift amount could be greater than or equal to the bit-width of the
+  // LHS, the value could be undef, so we don't know anything about it. We have
+  // to be more conservative than the poison situation above.
----------------
Oops - this comment doesn't make sense. An overshift produces poison too. Removing this check would mean we're going to fall through to the expensive check below more often though. Do we want to do that or should I just fix the comment?


https://reviews.llvm.org/D38637





More information about the llvm-commits mailing list