diff options
author | Pablo Barrio <pablo.barrio@arm.com> | 2018-01-24 14:13:47 +0000 |
---|---|---|
committer | Pablo Barrio <pablo.barrio@arm.com> | 2018-01-24 14:13:47 +0000 |
commit | 9b3d4c01a04876c823577c36f9394b755e84640b (patch) | |
tree | 2d69639d4638ff218309d1d470c2333974825b62 /llvm/lib/Transforms/AggressiveInstCombine/TruncInstCombine.cpp | |
parent | 5aef4b5997cbb7a25de8cf2f9309b157f6b9b20c (diff) | |
download | bcm5719-llvm-9b3d4c01a04876c823577c36f9394b755e84640b.tar.gz bcm5719-llvm-9b3d4c01a04876c823577c36f9394b755e84640b.zip |
[AArch64] Avoid unnecessary vector byte-swapping in big-endian
Summary:
Loads/stores of some NEON vector types are promoted to other vector
types with different lane sizes but same vector size. This is not a
problem in little-endian but, when in big-endian, it requires
additional byte reversals required to preserve the lane ordering
while keeping the right endianness of the data inside each lane.
For example:
%1 = load <4 x half>, <4 x half>* %p
results in the following assembly:
ld1 { v0.2s }, [x1]
rev32 v0.4h, v0.4h
This patch changes the promotion of these loads/stores so that the
actual vector load/store (LD1/ST1) takes care of the endianness
correctly and there is no need for further byte reversals. The
previous code now results in the following assembly:
ld1 { v0.4h }, [x1]
Reviewers: olista01, SjoerdMeijer, efriedma
Reviewed By: efriedma
Subscribers: aemerson, rengolin, javed.absar, llvm-commits, kristof.beyls
Differential Revision: https://reviews.llvm.org/D42235
llvm-svn: 323325
Diffstat (limited to 'llvm/lib/Transforms/AggressiveInstCombine/TruncInstCombine.cpp')
0 files changed, 0 insertions, 0 deletions