[PATCH] Revert 221429 and fix bug in TargetLowering::SimplifyDemandedBits
gil.rapaport at intel.com
Tue Jan 13 06:33:46 PST 2015
Suggest to replace [[ http://reviews.llvm.org/rL221429 | rL221429 ]] with the fix described in [[ http://reviews.llvm.org/D6321 | D6321 ]].
The bug in SimplifyDemandedBits (using DemandedMask instead of the single-use guarded NewMask) should be fixed regardless of the specific X86 blend optimization. Once it's applied, handling multi-uses in the X86 specific code is not needed for correctness.
While 221429 offers a way to perform the optimization even under multiple uses the current implementation would not get a chance to do so due to the multi-use guard (also note that test3 on vselect-avx.ll actually benefits from not performing the optimization as the sext-in-reg is removed altogether if left untouched). Perhaps this approach is worth generalizing to other multi-use cases?
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 9635 bytes
Desc: not available
More information about the llvm-commits