[PATCH] D102253: [AArch64][LoopVectorize] Add AArch64TTIImpl::isLegalToVectorizeType function
Kerry McLaughlin via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue May 11 09:53:08 PDT 2021
kmclaughlin created this revision.
kmclaughlin added reviewers: sdesmalen, david-arm, CarolineConcatto, joechrisellis.
Herald added subscribers: danielkiss, hiraditya, kristof.beyls, inglorion.
kmclaughlin requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
This function was added to query whether a given element type can be
vectorized; for SVE this should return false for element types such as
i128 which are not supported. This fixes loops such as the following, which
currently crash with "Cannot legalize this vector" when compiled with SVE:
int foo(__int128_t* ptr, int N)
#pragma clang loop vectorize_width(4, scalable)
for (int i=0; i<N; ++i)
ptr[i] = ptr[i] + 42;
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D102253
Files:
llvm/include/llvm/Analysis/TargetTransformInfo.h
llvm/include/llvm/Analysis/TargetTransformInfoImpl.h
llvm/lib/Analysis/TargetTransformInfo.cpp
llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp
llvm/lib/Target/AArch64/AArch64TargetTransformInfo.h
llvm/lib/Transforms/Vectorize/LoopVectorizationLegality.cpp
llvm/test/Transforms/LoopVectorize/AArch64/scalable-reductions.ll
llvm/test/Transforms/LoopVectorize/AArch64/sve-illegal-type.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D102253.344447.patch
Type: text/x-patch
Size: 8378 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210511/75002a00/attachment.bin>
More information about the llvm-commits
mailing list