[PATCH] Add optimization remarks to the loop unroller and vectorizer.

Zinovy Nis zinovy.nis at gmail.com
Tue Apr 29 07:53:49 PDT 2014


================
Comment at: lib/Transforms/Vectorize/LoopVectorize.cpp:1197
@@ -1196,1 +1196,3 @@
 
+    // Report the vectorization decision.
+    F->getContext().emitOptimizationRemark(
----------------
Your code will report loop as vectorized even if it was only unrolled.
Please see lines


     InnerLoopVectorizer LB(L, SE, LI, DT, DL, TLI, VF.Width, UF);
        LB.vectorize(&LVL);
        ++LoopsVectorized;
      }
  


and above. Is it the desired behavior?

http://reviews.llvm.org/D3456






More information about the llvm-commits mailing list