summaryrefslogtreecommitdiff
path: root/test/CodeGen/SystemZ/vec-move-09.ll
diff options
context:
space:
mode:
authorUlrich Weigand <ulrich.weigand@de.ibm.com>2015-05-05 19:26:48 +0000
committerUlrich Weigand <ulrich.weigand@de.ibm.com>2015-05-05 19:26:48 +0000
commit16541113840f4695a1e5c03286ccfa2f99a7c7e0 (patch)
tree324c840279f018a270b50f9e83dda9b96acf39e9 /test/CodeGen/SystemZ/vec-move-09.ll
parentaa5c996eda6dbaab398c8502717b37de2d10e4b7 (diff)
[SystemZ] Add CodeGen support for v2f64
This adds ABI and CodeGen support for the v2f64 type, which is natively supported by z13 instructions. Based on a patch by Richard Sandiford. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236522 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/SystemZ/vec-move-09.ll')
-rw-r--r--test/CodeGen/SystemZ/vec-move-09.ll27
1 files changed, 27 insertions, 0 deletions
diff --git a/test/CodeGen/SystemZ/vec-move-09.ll b/test/CodeGen/SystemZ/vec-move-09.ll
index 7863e4305f9..78c5454fb55 100644
--- a/test/CodeGen/SystemZ/vec-move-09.ll
+++ b/test/CodeGen/SystemZ/vec-move-09.ll
@@ -235,3 +235,30 @@ define <2 x i64> @f26(<2 x i64> %val, i32 %index) {
%ret = insertelement <2 x i64> %val, i64 0, i32 %index
ret <2 x i64> %ret
}
+
+; Test v2f64 insertion of 0 into the first element.
+define <2 x double> @f30(<2 x double> %val) {
+; CHECK-LABEL: f30:
+; CHECK: vleig %v24, 0, 0
+; CHECK: br %r14
+ %ret = insertelement <2 x double> %val, double 0.0, i32 0
+ ret <2 x double> %ret
+}
+
+; Test v2f64 insertion of 0 into the last element.
+define <2 x double> @f31(<2 x double> %val) {
+; CHECK-LABEL: f31:
+; CHECK: vleig %v24, 0, 1
+; CHECK: br %r14
+ %ret = insertelement <2 x double> %val, double 0.0, i32 1
+ ret <2 x double> %ret
+}
+
+; Test v2f64 insertion of a nonzero value.
+define <2 x double> @f32(<2 x double> %val) {
+; CHECK-LABEL: f32:
+; CHECK-NOT: vleig
+; CHECK: br %r14
+ %ret = insertelement <2 x double> %val, double 1.0, i32 1
+ ret <2 x double> %ret
+}