[PATCH] D46647: [InstCombine] Teach SimplifyDemandedBits that udiv doesn't demand low dividend bits that are zero in the divisor

Sanjoy Das via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed May 9 10:52:33 PDT 2018


sanjoy added inline comments.


================
Comment at: lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp:556
+
+      APInt DemandedMaskIn =
+          APInt::getHighBitsSet(BitWidth, BitWidth - SA->countTrailingZeros());
----------------
Can we also propagate the demanded bits of the division result (in some form) into `DemandedMaskIn`?


Repository:
  rL LLVM

https://reviews.llvm.org/D46647





More information about the llvm-commits mailing list