[PATCH] Optimise chains when splitting vector loads & stores
Richard Sandiford
rsandifo at linux.vnet.ibm.com
Mon Jul 15 04:21:49 PDT 2013
Duncan Sands <duncan.sands at gmail.com> writes:
> Hi Richard, I think this would be better off as a general DAG combine,
> in which case it would have to handle the elements of the TokenFactor
> perhaps being permuted from what you would like.
OK, I suppose that's what the -combiner-alias-analysis thing I mentioned is.
What would it take to enable that by default? (Preferably
-combiner-global-alias-analysis too.)
Thanks,
Richard
> Ciao, Duncan.
>
> On 28/06/13 12:14, Richard Sandiford wrote:
>> When vector loads and stores are split into two, the original chain
>> is replaced with a TokenFactor of the two new loads or stores.
>> This means that if the chain for a vector store (say) is a load
>> from the same address X, we end up with:
>>
>> load from Xlo load from Xhi
>> \ /
>> TokenFactor
>> / \
>> store to Xlo store to Xhi
>> \ /
>> TokenFactor
>>
>> In cases like these we can just use:
>>
>> load from Xlo load from Xhi
>> | |
>> store to Xlo store to Xhi
>> \ /
>> TokenFactor
>>
>> This optimisation overlaps with -combiner-alias-analysis, but it seems
>> like a simple and obvious case that is hopefully less controversial than
>> turning -c-a-a on by default. (But it's because of -c-a-a that isAccessTo()
>> is so restricted. It isn't trying to be a general alias check.)
>>
>> The motivation for doing this is that natural conditional vector stores
>> become natural conditional scalar stores, which helps improve the llvmpipe
>> code for SystemZ.
>>
>> Thanks,
>> Richard
>>
>>
>>
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>>
>
> _______________________________________________
> 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