[PATCH] D22886: [llvm] Loop Vectorization fault in collectLoopUni

Wei Mi via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 29 10:42:46 PDT 2016


On Fri, Jul 29, 2016 at 10:28 AM, Adam Nemet <anemet at apple.com> wrote:
> anemet added inline comments.
>
> ================
> Comment at: llvm/trunk/lib/Transforms/Vectorize/LoopVectorize.cpp:4839-4844
> @@ -4838,8 +4838,8 @@
>    BasicBlock *Latch = TheLoop->getLoopLatch();
>    // Start with the conditional branch.
>    if (!isOutOfScope(Latch->getTerminator()->getOperand(0))) {
>      Instruction *Cmp = cast<Instruction>(Latch->getTerminator()->getOperand(0));
>      Worklist.insert(Cmp);
>      DEBUG(dbgs() << "LV: Found uniform instruction: " << *Cmp << "\n");
>    }
>
> ----------------
> anemet wrote:
>> Hi Wei,
>>
>> AFAICT, you introduced this code in D21755.  It would be great if you could explain the rationale/add a comment for the isOutOfScope part (especially that it has led to this bug).
>>
>> Also, was there a test added for the case of an out-of-scope condition in D21755?
>>
>> Thank you,
>> Adam
> @wmi, did you see this request?  It's not urgent; I just wanted to make sure that it does not get lost.
>

Sorry, I did miss your comment here. I will add the comment and test
for out-of-scope condition.

Wei.


More information about the llvm-commits mailing list