[PATCH] D47113: [CVP] Teach CorrelatedValuePropagation to reduce the width of lshr instruction.

Bixia Zheng via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon May 21 00:00:44 PDT 2018


bixia added a comment.

InstCombiner::visitLShr can perform the same transformation for the cases where correlated-value propagation is not needed to discover the range of the values.
However, unlike the transformation here,  InstCombiner::visitLShr carefully makes sure that the transformation won't increase the total number of ZExt/ZExt instructions (Op1.hasOneUse check).  Why the transformation here doesn't need similar check? Is it safe to remove such a check in InstCombiner::visitLShr?


Repository:
  rL LLVM

https://reviews.llvm.org/D47113





More information about the llvm-commits mailing list