[LLVMdev] Failure to optimize vector select

Nadav Rotem nrotem at apple.com
Tue Aug 20 14:49:15 PDT 2013


Hi Matt, 

This code maintains a vector of float4 and it inserts and extracts values from this vector. The ’select’ operations are already vectorized. Maybe a sequence of inst-combines (or DAG-combines) can help. If you re-write this code using scalars then the slp-vectorizer, with some tweaks, will be able to catch it. 

Thanks,
Nadav


On Aug 20, 2013, at 1:14 PM, Matt Arsenault <arsenm2 at gmail.com> wrote:

> On Aug 20, 2013, at 10:22 , Nadav Rotem <nrotem at apple.com> wrote:
> 
>> Can you send the IR of the function ?  
> 
> Attached is the -O0 and -O3 IR
> 
> <vselect_optimized.ll><vselect_unoptimized.ll>





More information about the llvm-dev mailing list