[Patch]SLP vectorization on tiny fully vectorizable tree

Nadav Rotem nrotem at apple.com
Wed Oct 2 10:00:26 PDT 2013


I want to add that the reason that we check that the entire tree is vectorizable is that it is really difficult to estimate the cost for tiny trees. For example, our cost model thinks that it is profitable to store two scalars to memory by inserting them into a single vector and storing the vector to memory. This is not the kind of transformation that we want to perform at IR-level. 

The patch LGTM. 

On Oct 2, 2013, at 9:54 AM, Yi Jiang <yjiang at apple.com> wrote:

> Hi,
> 
> In the original slp vectorizer, we do not handle tiny tree (height less than 3) and expect that the backend could combine. However, the backend can not handle cases below due to lack of alias information; we have global alias analysis in backend but it is not enable in all back end:
> {
>   // we know dest does not alias to src
>   dest[0] = src[0];
>   dest[1] = src[1];
> }
> 
> In this patch, we will enable slp vectorization on tinny fully vectorizable tree like that.  
> 
> 
> <slp-tinytree.patch>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits




More information about the llvm-commits mailing list