Gathered loads/extractelements/extractvalue instructions should be
checked if they can represent a vector reordering node too and their
order should ve taken into account for better graph reordering analysis/
Also, if the gather node has reused scalars, they must be reordered
instead of the scalars themselves.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Unit Tests
Event Timeline
llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp | ||
---|---|---|
2700 | Don't all the lanes need to match for this to be Identity? | |
2718 | Maybe pull E out once and give it a better name, rather than having it redefined by both for loops? | |
2747 | It might be slighter easier to read by returning here and breaking the if-else chain - not sure though? | |
2748 | are we guaranteed to be TE->State == TreeEntry::NeedToGather at this point? If so assert(TE->State == TreeEntry::NeedToGather) might be better. | |
2906 | return and break if-else ? |
llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp | ||
---|---|---|
2700 | Maybe add a description comment then? I took this to mean we have a identity permute mask. |
LGTM, although tbh I'm still not totally clear on the 'partial identity' path
llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp | ||
---|---|---|
7431 | split off this NFC clang-format change |
The identity is 'partial' only in terms that some of the scalars are/may be replaced by undefs, so actually, it is a regular identity, where some indeces are undefs.
llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp | ||
---|---|---|
7431 | Did this accidentally, will restore the original code. |
Don't all the lanes need to match for this to be Identity?