[PATCH] D28907: [SLP] Fix for PR30787: Failure to beneficially vectorize 'copyable' elements in integer binary ops.
Dinar Temirbulatov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Dec 13 07:47:14 PST 2017
dtemirbulatov added inline comments.
================
Comment at: lib/Transforms/Vectorize/SLPVectorizer.cpp:1583
+ unsigned AltOpcode = getAltOpcode(S.Opcode);
+ if (S.IsNonAlt) {
+ bool SkipVector = false;
----------------
ABataev wrote:
> dtemirbulatov wrote:
> > This is the place where we check if a vector is diverse.
> What are you trying to do here? What's the real problem?
there are two issues here:
1) we could not combine remainder operation to any other operation in one vector, because of rem(interger, 1) != integer.
2) sometime we could schedule non-alternative, for example, a load operation, to other for example adds and the load operation is at the bottom of BB and that could result in dominance error for a constructed vector. There are two examples in pr35497.ll
https://reviews.llvm.org/D28907
More information about the llvm-commits
mailing list