1 ; Test calling functions with multiple return values (LLVM ABI extension)
3 ; RUN: llc < %s -mtriple=s390x-linux-gnu -mcpu=z13 | FileCheck %s
5 ; Up to eight vector return values fit into VRs.
6 declare { <2 x double>, <2 x double>, <2 x double>, <2 x double>,
7 <2 x double>, <2 x double>, <2 x double>, <2 x double> } @bar1()
9 define <2 x double> @f1() {
11 ; CHECK: brasl %r14, bar1
12 ; CHECK: vlr %v24, %v31
14 %mret = call { <2 x double>, <2 x double>,
15 <2 x double>, <2 x double>,
16 <2 x double>, <2 x double>,
17 <2 x double>, <2 x double> } @bar1()
18 %ret = extractvalue { <2 x double>, <2 x double>,
19 <2 x double>, <2 x double>,
20 <2 x double>, <2 x double>,
21 <2 x double>, <2 x double> } %mret, 7
25 ; More than eight vector return values use sret.
26 declare { <2 x double>, <2 x double>, <2 x double>, <2 x double>,
27 <2 x double>, <2 x double>, <2 x double>, <2 x double>,
28 <2 x double> } @bar2()
30 define <2 x double> @f2() {
32 ; CHECK: la %r2, 160(%r15)
33 ; CHECK: brasl %r14, bar2
34 ; CHECK: vl %v24, 288(%r15)
36 %mret = call { <2 x double>, <2 x double>,
37 <2 x double>, <2 x double>,
38 <2 x double>, <2 x double>,
39 <2 x double>, <2 x double>,
40 <2 x double> } @bar2()
41 %ret = extractvalue { <2 x double>, <2 x double>,
42 <2 x double>, <2 x double>,
43 <2 x double>, <2 x double>,
44 <2 x double>, <2 x double>,
45 <2 x double> } %mret, 8