1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -verify-machineinstrs -mcpu=pwr7 -mattr=+altivec \
3 ; RUN: -vec-extabi -mtriple powerpc-ibm-aix-xcoff < %s | \
4 ; RUN: FileCheck %s --check-prefix=32BIT
6 ; RUN: llc -verify-machineinstrs -mcpu=pwr7 -mattr=+altivec \
7 ; RUN: -vec-extabi -mtriple powerpc64-ibm-aix-xcoff < %s | \
8 ; RUN: FileCheck %s --check-prefix=64BIT
9 %struct.Test = type { double, double, double, double }
11 @__const.caller.t = private unnamed_addr constant %struct.Test { double 0.000000e+00, double 1.000000e+00, double 2.000000e+00, double 3.000000e+00 }, align 8
13 define double @caller() {
14 ; 32BIT-LABEL: caller:
15 ; 32BIT: # %bb.0: # %entry
17 ; 32BIT-NEXT: stw 0, 8(1)
18 ; 32BIT-NEXT: stwu 1, -192(1)
19 ; 32BIT-NEXT: lwz 3, L..C0(2) # @__const.caller.t
20 ; 32BIT-NEXT: li 4, 31
21 ; 32BIT-NEXT: xxlxor 0, 0, 0
22 ; 32BIT-NEXT: lwz 5, L..C1(2) # %const.0
23 ; 32BIT-NEXT: li 6, 512
24 ; 32BIT-NEXT: xxlxor 1, 1, 1
25 ; 32BIT-NEXT: xxlxor 2, 2, 2
26 ; 32BIT-NEXT: lvx 2, 3, 4
27 ; 32BIT-NEXT: li 4, 16
28 ; 32BIT-NEXT: lvsl 4, 0, 3
29 ; 32BIT-NEXT: xxlxor 37, 37, 37
30 ; 32BIT-NEXT: lvx 3, 3, 4
31 ; 32BIT-NEXT: li 4, 172
32 ; 32BIT-NEXT: lxvd2x 32, 0, 5
33 ; 32BIT-NEXT: xxlxor 38, 38, 38
34 ; 32BIT-NEXT: xxlxor 39, 39, 39
35 ; 32BIT-NEXT: li 5, 48
36 ; 32BIT-NEXT: vperm 2, 3, 2, 4
37 ; 32BIT-NEXT: xxlxor 40, 40, 40
38 ; 32BIT-NEXT: xxlxor 41, 41, 41
39 ; 32BIT-NEXT: xxlxor 42, 42, 42
40 ; 32BIT-NEXT: xxlxor 43, 43, 43
41 ; 32BIT-NEXT: xxlxor 44, 44, 44
42 ; 32BIT-NEXT: stxvw4x 34, 1, 4
43 ; 32BIT-NEXT: li 4, 120
44 ; 32BIT-NEXT: xxlxor 45, 45, 45
45 ; 32BIT-NEXT: lvx 2, 0, 3
46 ; 32BIT-NEXT: li 3, 156
47 ; 32BIT-NEXT: xxlxor 3, 3, 3
48 ; 32BIT-NEXT: xxlxor 4, 4, 4
49 ; 32BIT-NEXT: vperm 2, 2, 3, 4
50 ; 32BIT-NEXT: xxlxor 35, 35, 35
51 ; 32BIT-NEXT: xxlxor 36, 36, 36
52 ; 32BIT-NEXT: xxlxor 5, 5, 5
53 ; 32BIT-NEXT: xxlxor 6, 6, 6
54 ; 32BIT-NEXT: xxlxor 7, 7, 7
55 ; 32BIT-NEXT: stxvw4x 34, 1, 3
56 ; 32BIT-NEXT: li 3, 136
57 ; 32BIT-NEXT: xxlxor 34, 34, 34
58 ; 32BIT-NEXT: stxvw4x 0, 1, 3
59 ; 32BIT-NEXT: li 3, 104
60 ; 32BIT-NEXT: stxvw4x 0, 1, 4
61 ; 32BIT-NEXT: li 4, 256
62 ; 32BIT-NEXT: stxvw4x 0, 1, 3
63 ; 32BIT-NEXT: li 3, 88
64 ; 32BIT-NEXT: xxlxor 8, 8, 8
65 ; 32BIT-NEXT: xxlxor 9, 9, 9
66 ; 32BIT-NEXT: stxvw4x 0, 1, 3
67 ; 32BIT-NEXT: li 3, 72
68 ; 32BIT-NEXT: xxlxor 10, 10, 10
69 ; 32BIT-NEXT: stxvw4x 0, 1, 3
70 ; 32BIT-NEXT: li 3, 128
71 ; 32BIT-NEXT: xxlxor 11, 11, 11
72 ; 32BIT-NEXT: stxvd2x 32, 1, 5
73 ; 32BIT-NEXT: stw 6, 152(1)
74 ; 32BIT-NEXT: xxlxor 12, 12, 12
75 ; 32BIT-NEXT: xxlxor 13, 13, 13
76 ; 32BIT-NEXT: bl .callee[PR]
78 ; 32BIT-NEXT: addi 1, 1, 192
79 ; 32BIT-NEXT: lwz 0, 8(1)
83 ; 64BIT-LABEL: caller:
84 ; 64BIT: # %bb.0: # %entry
86 ; 64BIT-NEXT: std 0, 16(1)
87 ; 64BIT-NEXT: stdu 1, -224(1)
88 ; 64BIT-NEXT: ld 3, L..C0(2) # @__const.caller.t
89 ; 64BIT-NEXT: li 4, 16
90 ; 64BIT-NEXT: li 5, 144
91 ; 64BIT-NEXT: xxlxor 1, 1, 1
93 ; 64BIT-NEXT: xxlxor 2, 2, 2
94 ; 64BIT-NEXT: xxlxor 34, 34, 34
95 ; 64BIT-NEXT: lxvd2x 0, 3, 4
96 ; 64BIT-NEXT: li 4, 208
97 ; 64BIT-NEXT: xxlxor 35, 35, 35
98 ; 64BIT-NEXT: xxlxor 36, 36, 36
99 ; 64BIT-NEXT: xxlxor 37, 37, 37
100 ; 64BIT-NEXT: stxvd2x 0, 1, 4
101 ; 64BIT-NEXT: li 4, 160
102 ; 64BIT-NEXT: xxlxor 38, 38, 38
103 ; 64BIT-NEXT: lxvd2x 0, 0, 3
104 ; 64BIT-NEXT: li 3, 192
105 ; 64BIT-NEXT: xxlxor 39, 39, 39
106 ; 64BIT-NEXT: xxlxor 40, 40, 40
107 ; 64BIT-NEXT: xxlxor 41, 41, 41
108 ; 64BIT-NEXT: stxvd2x 0, 1, 3
109 ; 64BIT-NEXT: ld 3, L..C1(2) # %const.0
110 ; 64BIT-NEXT: xxlxor 0, 0, 0
111 ; 64BIT-NEXT: xxlxor 42, 42, 42
112 ; 64BIT-NEXT: stxvw4x 0, 1, 4
113 ; 64BIT-NEXT: li 4, 80
114 ; 64BIT-NEXT: xxlxor 43, 43, 43
115 ; 64BIT-NEXT: lxvd2x 13, 0, 3
116 ; 64BIT-NEXT: li 3, 128
117 ; 64BIT-NEXT: xxlxor 44, 44, 44
118 ; 64BIT-NEXT: stxvw4x 0, 1, 5
119 ; 64BIT-NEXT: xxlxor 45, 45, 45
120 ; 64BIT-NEXT: stxvw4x 0, 1, 3
121 ; 64BIT-NEXT: li 5, 512
122 ; 64BIT-NEXT: xxlxor 3, 3, 3
123 ; 64BIT-NEXT: xxlxor 4, 4, 4
124 ; 64BIT-NEXT: stxvd2x 13, 1, 4
125 ; 64BIT-NEXT: li 4, 256
126 ; 64BIT-NEXT: std 5, 184(1)
127 ; 64BIT-NEXT: xxlxor 5, 5, 5
128 ; 64BIT-NEXT: std 6, 176(1)
129 ; 64BIT-NEXT: xxlxor 6, 6, 6
130 ; 64BIT-NEXT: xxlxor 7, 7, 7
131 ; 64BIT-NEXT: xxlxor 8, 8, 8
132 ; 64BIT-NEXT: xxlxor 9, 9, 9
133 ; 64BIT-NEXT: xxlxor 10, 10, 10
134 ; 64BIT-NEXT: xxlxor 11, 11, 11
135 ; 64BIT-NEXT: xxlxor 12, 12, 12
136 ; 64BIT-NEXT: xxlxor 13, 13, 13
137 ; 64BIT-NEXT: bl .callee[PR]
139 ; 64BIT-NEXT: addi 1, 1, 224
140 ; 64BIT-NEXT: ld 0, 16(1)
145 %call = tail call double @callee(i32 signext 128, i32 signext 256, double 0.000000e+00, double 0.000000e+00, <2 x double> <double 0.000000e+00, double 0.000000e+00>, <2 x double> <double 0.000000e+00, double 0.000000e+00>, <2 x double> <double 0.000000e+00, double 0.000000e+00>, <2 x double> <double 0.000000e+00, double 0.000000e+00>, <2 x double> <double 0.000000e+00, double 0.000000e+00>, <2 x double> <double 0.000000e+00, double 0.000000e+00>, <2 x double> <double 0.000000e+00, double 0.000000e+00>, <2 x double> <double 0.000000e+00, double 0.000000e+00>, <2 x double> <double 0.000000e+00, double 0.000000e+00>, <2 x double> <double 0.000000e+00, double 0.000000e+00>, <2 x double> <double 0.000000e+00, double 0.000000e+00>, <2 x double> <double 0.000000e+00, double 0.000000e+00>, <2 x double> <double 2.400000e+01, double 2.500000e+01>, double 0.000000e+00, double 0.000000e+00, double 0.000000e+00, double 0.000000e+00, double 0.000000e+00, double 0.000000e+00, double 0.000000e+00, double 0.000000e+00, double 0.000000e+00, double 0.000000e+00, double 0.000000e+00, i32 signext 512, %struct.Test* nonnull byval(%struct.Test) align 4 @__const.caller.t)
149 declare double @callee(i32 signext, i32 signext, double, 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>, <2 x double>, <2 x double>, <2 x double>, <2 x double>, double, double, double, double, double, double, double, double, double, double, double, i32 signext, %struct.Test* byval(%struct.Test) align 8)