[PATCH] D23410: [SLP] Initialize VectorizedValue when gathering

Matthew Simpson via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 16 13:43:12 PDT 2016


mssimpso updated this revision to Diff 68248.
mssimpso added a comment.

Addressed Michael's comments.

Michael,

I'm not sure we can avoid the "else" block like I previously guessed we might. We can end up with uninitialized schedule data if we exit early from buildTree_rec (in addition to a missing entry in BlocksSchedules). I've detailed the cases in the new comments I added. The "else" block is replaced by a new "if" to check for the null schedule data case.

Iterating over the block to find the insert point should be extremely rare I think, and probably only happens in exceptional cases such as the one demonstrated in the test case where we hit some hard limit and give up building the tree. I tested the current patch on the test suite and spec2000/2006, and we didn't have to iterate over the block a single time.


https://reviews.llvm.org/D23410

Files:
  lib/Transforms/Vectorize/SLPVectorizer.cpp
  test/Transforms/SLPVectorizer/AArch64/gather-root.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D23410.68248.patch
Type: text/x-patch
Size: 9536 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160816/3cc06321/attachment.bin>


More information about the llvm-commits mailing list