[PATCH] Extend LoopVectorizationLegality::isConsecutivePtr to handle multiple level GEPs
wmi at google.com
Mon Jun 22 11:34:46 PDT 2015
repaste the patch using SCEV in phabricator.
One problem I noticed about using SCEV to check consecutiveness is that it may add a new case that: both pointer operand of gep and one operand of gep are variant. For this case, InnerLoopVectorizer::vectorizeMemoryInstruction may generate incorrect code. Previously, isConsecutive only return true for the case either pointer operand of gep is invariant, or all the other operands of gep are invariant. If we simply check SCEV in isConsecutive, It is like we move the complexity from isConsecutive to vectorizeMemoryInstruction.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 4738 bytes
Desc: not available
More information about the llvm-commits