[PATCH] D100882: [AArch64] Improve vector reverse lowering
Dave Green via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Apr 21 04:33:51 PDT 2021
dmgreen added a comment.
Thanks!
================
Comment at: llvm/lib/Target/AArch64/AArch64ISelLowering.cpp:9038
+ if (V1.getValueType() == VT &&
+ ((VT.getVectorNumElements() == 8 && VT.getScalarSizeInBits() == 16) ||
----------------
sdesmalen wrote:
> nit: Is this condition necessary?
>
> I know for LLVM IR nodes the result type doesn't necessarily have the same number of elements as the source vectors (but instead equals the number of elements in the mask), but is the same true for VECTOR_SHUFFLE?
>
> The reason for asking is that I see in ISDOpcodes that it says:
> /// VECTOR_SHUFFLE(VEC1, VEC2) - Returns a vector, of the same type as
> /// VEC1/VEC2.
Yeah, I added it as an additional safety check. It didn't alter any of the test cases I had, but I figured it was better safe than sorry.
I can remove it though, if it is guaranteed that they will already match in size.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D100882/new/
https://reviews.llvm.org/D100882
More information about the llvm-commits
mailing list