[LoopVectorize]Teach Loop Vectorizer about interleaved data accesses
Arnold Schwaighofer
aschwaighofer at apple.com
Fri Apr 3 15:08:01 PDT 2015
On 04/03/15, "Demikhovsky, Elena" wrote:
> (1) Teach LoopVectorizer to identify interleave accesses in the Legality phase.
> Ask LoopVectorizer (Legality->target) whether the specified indices are profitable, give data type and list of constant indices.
> Different sequence may be profitable for different targets.
This should be determined by the cost model. We emit a platform independent intrinsic which can be lowered to scalar operations and gathered into a vector on platforms that don't support it.
The cost model will tell us whether it is a good idea to use it for a specific type by returning the appropriate cost.
I.e there should not be a:
bool isLegalInterleaveType(Type *VecType) override {
return Impl.isLegalInterleaveType(VecType);
}
All vector types should be legal for the intrinsic - the cost model will (should) prevent us from using the once that cause insanely bad code (i.e. are scalarized) by assigning a cost that will make their use not profitable.
Thanks,
Arnold
>
> (2) Teach LoopVectorizer to transform interleave accesses to index.load/index.store with specific interleaved indices.
> index.load/store should just receive the indices. Not just interleave.
>
> - Elena
>
>
> -----Original Message-----
> From: Hao Liu [mailto:Hao.Liu at arm.com](javascript:main.compose()
> Sent: Friday, April 03, 2015 13:43
> To: Hao.Liu at arm.com; aschwaighofer at apple.com; hfinkel at anl.gov; Demikhovsky, Elena; renato.golin at linaro.org; t.p.northover at gmail.com
> Cc: amara.emerson at arm.com; llvm-commits at cs.uiuc.edu; mcrosier at codeaurora.org
> Subject: [PATCH] [LoopVectorize]Teach Loop Vectorizer about interleaved data accesses
>
More information about the llvm-commits
mailing list