[PATCH] D12475: [LV] Pull creation of trip counts into a helper function.

James Molloy via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 31 10:11:17 PDT 2015


jmolloy marked an inline comment as done.

================
Comment at: lib/Transforms/Vectorize/LoopVectorize.cpp:2789
@@ -2753,3 +2788,3 @@
   // Add the start index to the loop count to get the new end index.
-  Value *IdxEnd = BypassBuilder.CreateAdd(Count, StartIdx, "end.idx");
+  Value *CountRoundDown = getOrCreateVectorTripCount(Lp);
 
----------------
mzolotukhin wrote:
> Please double-check whether we generate instructions at the same location, as before the change. I suspect we're doing it in `VecBody` instead of `VectorPH` now, though I didn't check it.
> Also, since it's an NFC, it would be a good to verify it by comparing output IR on existing tests before and after the change.
I've checked, and there's no code changes we weren't expecting. L2654 is where the instructions are created, and that's at the end of the preheader.


Repository:
  rL LLVM

http://reviews.llvm.org/D12475





More information about the llvm-commits mailing list