[PATCH] D10950: [SLPVectorizer] Try different vectorization factors and set max vector register size based on target

Michael Zolotukhin mzolotukhin at apple.com
Tue Jul 7 14:50:38 PDT 2015


mzolotukhin added a subscriber: mzolotukhin.

Hi Sanjay,

I think this patch is good to commit as-is, though I have one question (I'm ok with just adding TODO for now).

Thanks,
Michael


================
Comment at: lib/Transforms/Vectorize/SLPVectorizer.cpp:4020-4022
@@ -3996,5 +4019,5 @@
 
     // Process the stores in chunks of 16.
     for (unsigned CI = 0, CE = it->second.size(); CI < CE; CI+=16) {
       unsigned Len = std::min<unsigned>(CE - CI, 16);
       Changed |= vectorizeStores(makeArrayRef(&it->second[CI], Len),
----------------
Shouldn't we update this threshold too? Otherwise, we won't be able to vectorize with VF=32 (and AVX2 might need <32 x i8> vectors).

However, increasing this value change *would* hurt compile time, so we need to be careful here.


http://reviews.llvm.org/D10950







More information about the llvm-commits mailing list