summaryrefslogtreecommitdiff
path: root/test/CodeGen
diff options
context:
space:
mode:
authorKevin Qin <Kevin.Qin@arm.com>2013-11-26 03:26:47 +0000
committerKevin Qin <Kevin.Qin@arm.com>2013-11-26 03:26:47 +0000
commitcf7ed12a1da0f7b425e81991410ee0fa830968e0 (patch)
tree78bd33a9a89844ba835a6ee3c986d88dfdc5bceb /test/CodeGen
parenteaa1aa72aa5ef1090e6c982638fbcd443c2c7085 (diff)
downloadllvm-cf7ed12a1da0f7b425e81991410ee0fa830968e0.tar.gz
llvm-cf7ed12a1da0f7b425e81991410ee0fa830968e0.tar.bz2
llvm-cf7ed12a1da0f7b425e81991410ee0fa830968e0.tar.xz
Refactored the implementation of AArch64 NEON instruction ZIP, UZP
and TRN. Fix a bug when mixed use of vget_high_u8() and vuzp_u8(). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@195716 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen')
-rw-r--r--test/CodeGen/AArch64/neon-perm.ll14
1 files changed, 14 insertions, 0 deletions
diff --git a/test/CodeGen/AArch64/neon-perm.ll b/test/CodeGen/AArch64/neon-perm.ll
index 6ad93d01f9..fa4d54dc74 100644
--- a/test/CodeGen/AArch64/neon-perm.ll
+++ b/test/CodeGen/AArch64/neon-perm.ll
@@ -1677,3 +1677,17 @@ entry:
%.fca.0.1.insert = insertvalue %struct.poly16x8x2_t %.fca.0.0.insert, <8 x i16> %vtrn1.i, 0, 1
ret %struct.poly16x8x2_t %.fca.0.1.insert
}
+
+define %struct.uint8x8x2_t @test_uzp(<16 x i8> %y) {
+; CHECK: test_uzp:
+
+ %vuzp.i = shufflevector <16 x i8> %y, <16 x i8> undef, <8 x i32> <i32 0, i32 2, i32 4, i32 6, i32 8, i32 10, i32 12, i32 14>
+ %vuzp1.i = shufflevector <16 x i8> %y, <16 x i8> undef, <8 x i32> <i32 1, i32 3, i32 5, i32 7, i32 9, i32 11, i32 13, i32 15>
+ %.fca.0.0.insert = insertvalue %struct.uint8x8x2_t undef, <8 x i8> %vuzp.i, 0, 0
+ %.fca.0.1.insert = insertvalue %struct.uint8x8x2_t %.fca.0.0.insert, <8 x i8> %vuzp1.i, 0, 1
+ ret %struct.uint8x8x2_t %.fca.0.1.insert
+
+; CHECK: dup {{d[0-9]+}}, {{v[0-9]+}}.d[1]
+; CHECK-NEXT: uzp1 {{v[0-9]+}}.8b, {{v[0-9]+}}.8b, {{v[0-9]+}}.8b
+; CHECK-NEXT: uzp2 {{v[0-9]+}}.8b, {{v[0-9]+}}.8b, {{v[0-9]+}}.8b
+}