vec-args-06.ll
3.79 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
; Test multiple return values (LLVM ABI extension)
;
; RUN: llc < %s -mtriple=s390x-linux-gnu -mcpu=z13 | FileCheck %s
; RUN: llc < %s -mtriple=s390x-linux-gnu -mcpu=z13 -mattr=soft-float \
; RUN: | FileCheck %s --check-prefix=SOFT-FLOAT
; Up to eight vector return values fit into VRs.
define { <2 x double>, <2 x double>, <2 x double>, <2 x double>,
<2 x double>, <2 x double>, <2 x double>, <2 x double> } @f1() {
; CHECK-LABEL: f1:
; CHECK: larl [[TMP:%r[0-5]]], .LCPI
; CHECK: vl %v24, 0([[TMP]])
; CHECK: larl [[TMP:%r[0-5]]], .LCPI
; CHECK: vl %v26, 0([[TMP]])
; CHECK: larl [[TMP:%r[0-5]]], .LCPI
; CHECK: vl %v28, 0([[TMP]])
; CHECK: larl [[TMP:%r[0-5]]], .LCPI
; CHECK: vl %v30, 0([[TMP]])
; CHECK: larl [[TMP:%r[0-5]]], .LCPI
; CHECK: vl %v25, 0([[TMP]])
; CHECK: larl [[TMP:%r[0-5]]], .LCPI
; CHECK: vl %v27, 0([[TMP]])
; CHECK: larl [[TMP:%r[0-5]]], .LCPI
; CHECK: vl %v29, 0([[TMP]])
; CHECK: larl [[TMP:%r[0-5]]], .LCPI
; CHECK: vl %v31, 0([[TMP]])
; CHECK: br %r14
; SOFT-FLOAT-LABEL: f1:
; SOFT-FLOAT-NOT: %{{[fv]}}
; SOFT-FLOAT: llihf
; SOFT-FLOAT-NEXT: oilf
; SOFT-FLOAT-NEXT: stg
; SOFT-FLOAT-NEXT: llihh
; SOFT-FLOAT-NEXT: stg
; SOFT-FLOAT-NEXT: llihf
; SOFT-FLOAT-NOT: %{{[fv]}}
; SOFT-FLOAT: br %r14
ret { <2 x double>, <2 x double>, <2 x double>, <2 x double>,
<2 x double>, <2 x double>, <2 x double>, <2 x double> }
{ <2 x double> <double 1.0, double 1.1>,
<2 x double> <double 2.0, double 2.1>,
<2 x double> <double 3.0, double 3.1>,
<2 x double> <double 4.0, double 4.1>,
<2 x double> <double 5.0, double 5.1>,
<2 x double> <double 6.0, double 6.1>,
<2 x double> <double 7.0, double 7.1>,
<2 x double> <double 8.0, double 8.1> }
}
; More than eight vector return values use sret.
define { <2 x double>, <2 x double>, <2 x double>, <2 x double>,
<2 x double>, <2 x double>, <2 x double>, <2 x double>,
<2 x double> } @f2() {
; CHECK-LABEL: f2:
; CHECK: larl [[TMP:%r[0-5]]], .LCPI
; CHECK: vl [[VTMP:%v[0-9]+]], 0([[TMP]])
; CHECK-DAG: vst [[VTMP]], 128(%r2)
; CHECK-DAG: larl [[TMP:%r[0-5]]], .LCPI
; CHECK: vl [[VTMP:%v[0-9]+]], 0([[TMP]])
; CHECK-DAG: vst [[VTMP]], 112(%r2)
; CHECK-DAG: larl [[TMP:%r[0-5]]], .LCPI
; CHECK: vl [[VTMP:%v[0-9]+]], 0([[TMP]])
; CHECK-DAG: vst [[VTMP]], 96(%r2)
; CHECK-DAG: larl [[TMP:%r[0-5]]], .LCPI
; CHECK: vl [[VTMP:%v[0-9]+]], 0([[TMP]])
; CHECK-DAG: vst [[VTMP]], 80(%r2)
; CHECK-DAG: larl [[TMP:%r[0-5]]], .LCPI
; CHECK: vl [[VTMP:%v[0-9]+]], 0([[TMP]])
; CHECK-DAG: vst [[VTMP]], 64(%r2)
; CHECK-DAG: larl [[TMP:%r[0-5]]], .LCPI
; CHECK: vl [[VTMP:%v[0-9]+]], 0([[TMP]])
; CHECK-DAG: vst [[VTMP]], 48(%r2)
; CHECK-DAG: larl [[TMP:%r[0-5]]], .LCPI
; CHECK: vl [[VTMP:%v[0-9]+]], 0([[TMP]])
; CHECK-DAG: vst [[VTMP]], 32(%r2)
; CHECK-DAG: larl [[TMP:%r[0-5]]], .LCPI
; CHECK: vl [[VTMP:%v[0-9]+]], 0([[TMP]])
; CHECK-DAG: vst [[VTMP]], 16(%r2)
; CHECK-DAG: larl [[TMP:%r[0-5]]], .LCPI
; CHECK: vl [[VTMP:%v[0-9]+]], 0([[TMP]])
; CHECK: vst [[VTMP]], 0(%r2)
; CHECK: br %r14
; SOFT-FLOAT-LABEL: f2:
; SOFT-FLOAT-NOT: %{{[fv]}}
; SOFT-FLOAT: llihf
; SOFT-FLOAT-NEXT: oilf
; SOFT-FLOAT-NEXT: stg
; SOFT-FLOAT-NEXT: llihh
; SOFT-FLOAT-NEXT: stg
; SOFT-FLOAT-NEXT: llihf
; SOFT-FLOAT-NOT: %{{[fv]}}
; SOFT-FLOAT: br %r14
ret { <2 x double>, <2 x double>, <2 x double>, <2 x double>,
<2 x double>, <2 x double>, <2 x double>, <2 x double>,
<2 x double> }
{ <2 x double> <double 1.0, double 1.1>,
<2 x double> <double 2.0, double 2.1>,
<2 x double> <double 3.0, double 3.1>,
<2 x double> <double 4.0, double 4.1>,
<2 x double> <double 5.0, double 5.1>,
<2 x double> <double 6.0, double 6.1>,
<2 x double> <double 7.0, double 7.1>,
<2 x double> <double 8.0, double 8.1>,
<2 x double> <double 9.0, double 9.1> }
}