[PATCH] D17153: [LV] Identify more induction PHIs by coercing expressions to AddRecExprs

silviu.baranga@arm.com via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 11 10:12:53 PST 2016


sbaranga created this revision.
sbaranga added reviewers: anemet, mzolotukhin.
sbaranga added a subscriber: llvm-commits.
Herald added subscribers: mzolotukhin, sanjoy.

Some PHIs can have expressions that are not AddRecExprs due to the presence
of sext/zext instructions. In order to prevent the Loop Vectorizer from
bailing out when encountering these PHIs, we now coerce the SCEV
expressions to AddRecExprs using SCEV predicates (when possible).

We only do this when the alternative would be to not vectorize.

http://reviews.llvm.org/D17153

Files:
  include/llvm/Transforms/Utils/LoopUtils.h
  lib/Transforms/Utils/LoopUtils.cpp
  lib/Transforms/Vectorize/LoopVectorize.cpp
  test/Transforms/LoopVectorize/induction.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D17153.47678.patch
Type: text/x-patch
Size: 6817 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160211/9ddb05fc/attachment.bin>


More information about the llvm-commits mailing list