summaryrefslogtreecommitdiff
path: root/test/CodeGen/PowerPC/p9-xxinsertw-xxextractuw.ll
diff options
context:
space:
mode:
Diffstat (limited to 'test/CodeGen/PowerPC/p9-xxinsertw-xxextractuw.ll')
-rw-r--r--test/CodeGen/PowerPC/p9-xxinsertw-xxextractuw.ll18
1 files changed, 18 insertions, 0 deletions
diff --git a/test/CodeGen/PowerPC/p9-xxinsertw-xxextractuw.ll b/test/CodeGen/PowerPC/p9-xxinsertw-xxextractuw.ll
index 8b4a76757c3..e3326595d13 100644
--- a/test/CodeGen/PowerPC/p9-xxinsertw-xxextractuw.ll
+++ b/test/CodeGen/PowerPC/p9-xxinsertw-xxextractuw.ll
@@ -990,3 +990,21 @@ entry:
%vecins = insertelement <4 x i32> %a, i32 %i, i32 %el
ret <4 x i32> %vecins
}
+define <4 x i32> @intrinsicInsertTest(<4 x i32> %a, <2 x i64> %b) {
+entry:
+; CHECK-LABEL:intrinsicInsertTest
+; CHECK: xxinsertw 34, 35, 3
+; CHECK: blr
+ %ans = tail call <4 x i32> @llvm.ppc.vsx.xxinsertw(<4 x i32> %a, <2 x i64> %b, i32 3)
+ ret <4 x i32> %ans
+}
+declare <4 x i32> @llvm.ppc.vsx.xxinsertw(<4 x i32>, <2 x i64>, i32)
+define <2 x i64> @intrinsicExtractTest(<2 x i64> %a) {
+entry:
+; CHECK-LABEL: intrinsicExtractTest
+; CHECK: xxextractuw 0, 34, 5
+; CHECK: blr
+ %ans = tail call <2 x i64> @llvm.ppc.vsx.xxextractuw(<2 x i64> %a, i32 5)
+ ret <2 x i64> %ans
+}
+declare <2 x i64> @llvm.ppc.vsx.xxextractuw(<2 x i64>, i32)