[PATCH] D9804: Optimize scattered vector insert/extract pattern

hfinkel@anl.gov via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 25 14:54:57 PDT 2015


hfinkel added a comment.

In http://reviews.llvm.org/D9804#253832, @hulx2000 wrote:

> Just saw comments from Hal and Nadav.
>
> For Hal's comments:
>
> 1. If the original ext is used more than once, then the original ext can't be deleted after my transformation, so it may not gain anything, that's why I check hasOneUse() on it.


No, you'd replace them all with the corresponding extract. What am I missing?

> 2. I agree, this transformation is designed for AArch64, so I could make it AArch64 specific.

> 

>   For Navav's comment "We are already doing these kind of optimizations in SelectionDAG. The SLPVectorizer is not the right place for this kind of transformation", do you mean I shouldn't do this (my) transformation in SLPVectorizer?  At least for our case, SelectionDAG is unable to catch it, and it caused a performance loss.


Why is it not able to catch it? We need to understand that before we move forward with adding handling in the SLP vectorizer for this.


Repository:
  rL LLVM

http://reviews.llvm.org/D9804





More information about the llvm-commits mailing list