3 #define s390_generate_float_test(insn, asm_string) \
4 s390_test_generate(v##insn##00, "v" #insn " " asm_string ",0, 0") \
5 s390_test_generate(v##insn##01, "v" #insn " " asm_string ",0, 1") \
6 s390_test_generate(v##insn##03, "v" #insn " " asm_string ",0, 3") \
7 s390_test_generate(v##insn##04, "v" #insn " " asm_string ",0, 4") \
8 s390_test_generate(v##insn##05, "v" #insn " " asm_string ",0, 5") \
9 s390_test_generate(v##insn##06, "v" #insn " " asm_string ",0, 6") \
10 s390_test_generate(v##insn##07, "v" #insn " " asm_string ",0, 7") \
11 s390_test_generate(w##insn##00, "w" #insn " " asm_string ",0, 0") \
12 s390_test_generate(w##insn##01, "w" #insn " " asm_string ",0, 1") \
13 s390_test_generate(w##insn##03, "w" #insn " " asm_string ",0, 3") \
14 s390_test_generate(w##insn##04, "w" #insn " " asm_string ",0, 4") \
15 s390_test_generate(w##insn##05, "w" #insn " " asm_string ",0, 5") \
16 s390_test_generate(w##insn##06, "w" #insn " " asm_string ",0, 6") \
17 s390_test_generate(w##insn##07, "w" #insn " " asm_string ",0, 7") \
19 #define s390_call_float_test(insn, info) \
20 test_with_selective_printing(v ##insn ## 00, info); \
21 test_with_selective_printing(v ##insn ## 01, info); \
22 test_with_selective_printing(v ##insn ## 03, info); \
23 test_with_selective_printing(v ##insn ## 04, info); \
24 test_with_selective_printing(v ##insn ## 05, info); \
25 test_with_selective_printing(v ##insn ## 06, info); \
26 test_with_selective_printing(v ##insn ## 07, info); \
27 test_with_selective_printing(w ##insn ## 00, info | V128_V_RES_ZERO_ONLY); \
28 test_with_selective_printing(w ##insn ## 01, info | V128_V_RES_ZERO_ONLY); \
29 test_with_selective_printing(w ##insn ## 03, info | V128_V_RES_ZERO_ONLY); \
30 test_with_selective_printing(w ##insn ## 04, info | V128_V_RES_ZERO_ONLY); \
31 test_with_selective_printing(w ##insn ## 05, info | V128_V_RES_ZERO_ONLY); \
32 test_with_selective_printing(w ##insn ## 06, info | V128_V_RES_ZERO_ONLY); \
33 test_with_selective_printing(w ##insn ## 07, info | V128_V_RES_ZERO_ONLY); \
35 s390_generate_float_test(cdgb, " %%v5, %%v1")
36 s390_generate_float_test(cdlgb
, " %%v5, %%v1")
37 s390_generate_float_test(cgdb
, " %%v5, %%v1")
38 s390_generate_float_test(clgdb
, " %%v5, %%v1")
39 s390_generate_float_test(fidb
, " %%v5, %%v1")
40 s390_generate_float_test(ledb
, " %%v5, %%v1")
42 s390_test_generate(vldeb
, "vldeb %%v5, %%v1")
43 s390_test_generate(wldeb
, "wldeb %%v5, %%v1")
45 s390_test_generate(vflcdb
, "vflcdb %%v5, %%v1")
46 s390_test_generate(wflcdb
, "wflcdb %%v5, %%v1")
47 s390_test_generate(vflndb
, "vflndb %%v5, %%v1")
48 s390_test_generate(wflndb
, "wflndb %%v5, %%v1")
49 s390_test_generate(vflpdb
, "vflpdb %%v5, %%v1")
50 s390_test_generate(wflpdb
, "wflpdb %%v5, %%v1")
52 s390_test_generate(vfadb
, "vfadb %%v5, %%v1, %%v2")
53 s390_test_generate(wfadb
, "wfadb %%v5, %%v1, %%v2")
54 s390_test_generate(vfsdb
, "vfsdb %%v5, %%v1, %%v2")
55 s390_test_generate(wfsdb
, "wfsdb %%v5, %%v1, %%v2")
56 s390_test_generate(vfmdb
, "vfmdb %%v5, %%v1, %%v2")
57 s390_test_generate(wfmdb
, "wfmdb %%v5, %%v1, %%v2")
58 s390_test_generate(vfddb
, "vfddb %%v5, %%v1, %%v2")
59 s390_test_generate(wfddb
, "wfddb %%v5, %%v1, %%v2")
61 s390_test_generate(vfsqdb
, "vfsqdb %%v5, %%v1")
62 s390_test_generate(wfsqdb
, "wfsqdb %%v5, %%v1")
64 s390_test_generate(vfmadb
, "vfmadb %%v5, %%v1, %%v2, %%v3")
65 s390_test_generate(wfmadb
, "wfmadb %%v5, %%v1, %%v2, %%v3")
66 s390_test_generate(vfmsdb
, "vfmsdb %%v5, %%v1, %%v2, %%v3")
67 s390_test_generate(wfmsdb
, "wfmsdb %%v5, %%v1, %%v2, %%v3")
69 s390_test_generate(wfcdb
, "wfcdb %%v1, %%v2\n" S390_TEST_PUT_CC_TO_RESULT
)
70 s390_test_generate(wfkdb
, "wfkdb %%v1, %%v2\n" S390_TEST_PUT_CC_TO_RESULT
)
72 s390_test_generate(vfcedb
, "vfcedb %%v5, %%v1, %%v2")
73 s390_test_generate(wfcedb
, "wfcedb %%v5, %%v1, %%v2")
74 s390_test_generate(vfcedbs
, "vfcedbs %%v5, %%v1, %%v2\n" S390_TEST_PUT_CC_TO_RESULT
)
75 s390_test_generate(wfcedbs
, "wfcedbs %%v5, %%v1, %%v2\n" S390_TEST_PUT_CC_TO_RESULT
)
77 s390_test_generate(vfchdb
, "vfchdb %%v5, %%v1, %%v2")
78 s390_test_generate(wfchdb
, "wfchdb %%v5, %%v1, %%v2")
79 s390_test_generate(vfchdbs
, "vfchdbs %%v5, %%v1, %%v2\n" S390_TEST_PUT_CC_TO_RESULT
)
80 s390_test_generate(wfchdbs
, "wfchdbs %%v5, %%v1, %%v2\n" S390_TEST_PUT_CC_TO_RESULT
)
82 s390_test_generate(vfchedb
, "vfchedb %%v5, %%v1, %%v2")
83 s390_test_generate(wfchedb
, "wfchedb %%v5, %%v1, %%v2")
84 s390_test_generate(vfchedbs
, "vfchedbs %%v5, %%v1, %%v2\n" S390_TEST_PUT_CC_TO_RESULT
)
85 s390_test_generate(wfchedbs
, "wfchedbs %%v5, %%v1, %%v2\n" S390_TEST_PUT_CC_TO_RESULT
)
87 s390_test_generate(vftcidb0
, "vftcidb %%v5, %%v1, 0 \n" S390_TEST_PUT_CC_TO_RESULT
)
88 s390_test_generate(vftcidb1
, "vftcidb %%v5, %%v1, 1 \n" S390_TEST_PUT_CC_TO_RESULT
)
89 s390_test_generate(vftcidb2
, "vftcidb %%v5, %%v1, 2 \n" S390_TEST_PUT_CC_TO_RESULT
)
90 s390_test_generate(vftcidb3
, "vftcidb %%v5, %%v1, 0 \n" S390_TEST_PUT_CC_TO_RESULT
)
91 s390_test_generate(vftcidb4
, "vftcidb %%v5, %%v1, 4 \n" S390_TEST_PUT_CC_TO_RESULT
)
92 s390_test_generate(vftcidb8
, "vftcidb %%v5, %%v1, 8 \n" S390_TEST_PUT_CC_TO_RESULT
)
93 s390_test_generate(vftcidb16
, "vftcidb %%v5, %%v1, 16 \n" S390_TEST_PUT_CC_TO_RESULT
)
94 s390_test_generate(vftcidb32
, "vftcidb %%v5, %%v1, 32 \n" S390_TEST_PUT_CC_TO_RESULT
)
95 s390_test_generate(vftcidb64
, "vftcidb %%v5, %%v1, 64 \n" S390_TEST_PUT_CC_TO_RESULT
)
96 s390_test_generate(vftcidb128
, "vftcidb %%v5, %%v1, 128 \n" S390_TEST_PUT_CC_TO_RESULT
)
97 s390_test_generate(vftcidb256
, "vftcidb %%v5, %%v1, 256 \n" S390_TEST_PUT_CC_TO_RESULT
)
98 s390_test_generate(vftcidb512
, "vftcidb %%v5, %%v1, 512 \n" S390_TEST_PUT_CC_TO_RESULT
)
99 s390_test_generate(vftcidb1024
, "vftcidb %%v5, %%v1, 1024\n" S390_TEST_PUT_CC_TO_RESULT
)
100 s390_test_generate(vftcidb2048
, "vftcidb %%v5, %%v1, 2048\n" S390_TEST_PUT_CC_TO_RESULT
)
104 size_t iteration
= 0;
106 s390_call_float_test(cdgb
, (V128_V_RES_AS_FLOAT64
| V128_V_ARG1_AS_INT
));
107 s390_call_float_test(cdlgb
, (V128_V_RES_AS_FLOAT64
| V128_V_ARG1_AS_INT
));
108 s390_call_float_test(cgdb
, (V128_V_RES_AS_INT
| V128_V_ARG1_AS_FLOAT64
));
109 s390_call_float_test(clgdb
, (V128_V_RES_AS_INT
| V128_V_ARG1_AS_FLOAT64
));
110 s390_call_float_test(fidb
, (V128_V_RES_AS_FLOAT64
| V128_V_ARG1_AS_FLOAT64
));
111 s390_call_float_test(ledb
, (V128_V_RES_AS_FLOAT32
| V128_V_RES_EVEN_ONLY
|
112 V128_V_ARG1_AS_FLOAT64
));
114 test_with_selective_printing(vldeb
, (V128_V_RES_AS_FLOAT64
|
115 V128_V_ARG1_AS_FLOAT64
));
116 test_with_selective_printing(wldeb
, (V128_V_RES_AS_FLOAT64
|
117 V128_V_ARG1_AS_FLOAT64
|
118 V128_V_RES_ZERO_ONLY
));
120 test_with_selective_printing(vflcdb
, (V128_V_RES_AS_FLOAT64
|
121 V128_V_ARG1_AS_FLOAT64
));
122 test_with_selective_printing(wflcdb
, (V128_V_RES_AS_FLOAT64
|
123 V128_V_ARG1_AS_FLOAT64
|
124 V128_V_RES_ZERO_ONLY
));
125 test_with_selective_printing(vflndb
, (V128_V_RES_AS_FLOAT64
|
126 V128_V_ARG1_AS_FLOAT64
));
127 test_with_selective_printing(wflndb
, (V128_V_RES_AS_FLOAT64
|
128 V128_V_ARG1_AS_FLOAT64
|
129 V128_V_RES_ZERO_ONLY
));
130 test_with_selective_printing(vflpdb
, (V128_V_RES_AS_FLOAT64
|
131 V128_V_ARG1_AS_FLOAT64
));
132 test_with_selective_printing(wflpdb
, (V128_V_RES_AS_FLOAT64
|
133 V128_V_ARG1_AS_FLOAT64
|
134 V128_V_RES_ZERO_ONLY
));
136 test_with_selective_printing(vfadb
, (V128_V_RES_AS_FLOAT64
|
137 V128_V_ARG1_AS_FLOAT64
|
138 V128_V_ARG2_AS_FLOAT64
));
139 test_with_selective_printing(wfadb
, (V128_V_RES_AS_FLOAT64
|
140 V128_V_ARG1_AS_FLOAT64
|
141 V128_V_ARG2_AS_FLOAT64
|
142 V128_V_RES_ZERO_ONLY
));
143 test_with_selective_printing(vfsdb
, (V128_V_RES_AS_FLOAT64
|
144 V128_V_ARG1_AS_FLOAT64
|
145 V128_V_ARG2_AS_FLOAT64
));
146 test_with_selective_printing(wfsdb
, (V128_V_RES_AS_FLOAT64
|
147 V128_V_ARG1_AS_FLOAT64
|
148 V128_V_ARG2_AS_FLOAT64
|
149 V128_V_RES_ZERO_ONLY
));
150 test_with_selective_printing(vfmdb
, (V128_V_RES_AS_FLOAT64
|
151 V128_V_ARG1_AS_FLOAT64
|
152 V128_V_ARG2_AS_FLOAT64
));
153 test_with_selective_printing(wfmdb
, (V128_V_RES_AS_FLOAT64
|
154 V128_V_ARG1_AS_FLOAT64
|
155 V128_V_ARG2_AS_FLOAT64
|
156 V128_V_RES_ZERO_ONLY
));
157 test_with_selective_printing(vfddb
, (V128_V_RES_AS_FLOAT64
|
158 V128_V_ARG1_AS_FLOAT64
|
159 V128_V_ARG2_AS_FLOAT64
));
160 test_with_selective_printing(wfddb
, (V128_V_RES_AS_FLOAT64
|
161 V128_V_ARG1_AS_FLOAT64
|
162 V128_V_ARG2_AS_FLOAT64
|
163 V128_V_RES_ZERO_ONLY
));
165 test_with_selective_printing(vfsqdb
, (V128_V_RES_AS_FLOAT64
|
166 V128_V_ARG1_AS_FLOAT64
));
167 test_with_selective_printing(wfsqdb
, (V128_V_RES_AS_FLOAT64
|
168 V128_V_ARG1_AS_FLOAT64
|
169 V128_V_RES_ZERO_ONLY
));
171 test_with_selective_printing(vfmadb
, (V128_V_RES_AS_FLOAT64
|
172 V128_V_ARG1_AS_FLOAT64
|
173 V128_V_ARG2_AS_FLOAT64
|
174 V128_V_ARG3_AS_FLOAT64
));
175 test_with_selective_printing(wfmadb
, (V128_V_RES_AS_FLOAT64
|
176 V128_V_ARG1_AS_FLOAT64
|
177 V128_V_ARG2_AS_FLOAT64
|
178 V128_V_ARG3_AS_FLOAT64
|
179 V128_V_RES_ZERO_ONLY
));
180 test_with_selective_printing(vfmsdb
, (V128_V_RES_AS_FLOAT64
|
181 V128_V_ARG1_AS_FLOAT64
|
182 V128_V_ARG2_AS_FLOAT64
|
183 V128_V_ARG3_AS_FLOAT64
));
184 test_with_selective_printing(wfmsdb
, (V128_V_RES_AS_FLOAT64
|
185 V128_V_ARG1_AS_FLOAT64
|
186 V128_V_ARG2_AS_FLOAT64
|
187 V128_V_ARG3_AS_FLOAT64
|
188 V128_V_RES_ZERO_ONLY
));
190 test_with_selective_printing(wfcdb
, (V128_V_ARG1_AS_FLOAT64
|
191 V128_V_ARG2_AS_FLOAT64
|
193 V128_V_RES_ZERO_ONLY
));
194 test_with_selective_printing(wfkdb
, (V128_V_ARG1_AS_FLOAT64
|
195 V128_V_ARG2_AS_FLOAT64
|
197 V128_V_RES_ZERO_ONLY
));
199 test_with_selective_printing(vfcedb
, (V128_V_RES_AS_INT
|
200 V128_V_ARG1_AS_FLOAT64
|
201 V128_V_ARG2_AS_FLOAT64
));
202 test_with_selective_printing(wfcedb
, (V128_V_RES_AS_INT
|
203 V128_V_ARG1_AS_FLOAT64
|
204 V128_V_ARG2_AS_FLOAT64
|
205 V128_V_RES_ZERO_ONLY
));
206 test_with_selective_printing(vfcedbs
, (V128_V_RES_AS_INT
|
207 V128_V_ARG1_AS_FLOAT64
|
208 V128_V_ARG2_AS_FLOAT64
|
210 test_with_selective_printing(wfcedbs
, (V128_V_RES_AS_INT
|
211 V128_V_ARG1_AS_FLOAT64
|
212 V128_V_ARG2_AS_FLOAT64
|
214 V128_V_RES_ZERO_ONLY
));
216 test_with_selective_printing(vfchdb
, (V128_V_RES_AS_INT
|
217 V128_V_ARG1_AS_FLOAT64
|
218 V128_V_ARG2_AS_FLOAT64
));
219 test_with_selective_printing(wfchdb
, (V128_V_RES_AS_INT
|
220 V128_V_ARG1_AS_FLOAT64
|
221 V128_V_ARG2_AS_FLOAT64
|
222 V128_V_RES_ZERO_ONLY
));
223 test_with_selective_printing(vfchdbs
, (V128_V_RES_AS_INT
|
224 V128_V_ARG1_AS_FLOAT64
|
225 V128_V_ARG2_AS_FLOAT64
|
227 test_with_selective_printing(wfchdbs
, (V128_V_RES_AS_INT
|
228 V128_V_ARG1_AS_FLOAT64
|
229 V128_V_ARG2_AS_FLOAT64
|
231 V128_V_RES_ZERO_ONLY
));
233 test_with_selective_printing(vfchedb
, (V128_V_RES_AS_INT
|
234 V128_V_ARG1_AS_FLOAT64
|
235 V128_V_ARG2_AS_FLOAT64
));
236 test_with_selective_printing(wfchedb
, (V128_V_RES_AS_INT
|
237 V128_V_ARG1_AS_FLOAT64
|
238 V128_V_ARG2_AS_FLOAT64
|
239 V128_V_RES_ZERO_ONLY
));
240 test_with_selective_printing(vfchedbs
, (V128_V_RES_AS_INT
|
241 V128_V_ARG1_AS_FLOAT64
|
242 V128_V_ARG2_AS_FLOAT64
|
244 test_with_selective_printing(wfchedbs
, (V128_V_RES_AS_INT
|
245 V128_V_ARG1_AS_FLOAT64
|
246 V128_V_ARG2_AS_FLOAT64
|
248 V128_V_RES_ZERO_ONLY
));
250 test_with_selective_printing(vftcidb0
, (V128_V_RES_AS_INT
|
251 V128_V_ARG1_AS_FLOAT64
|
253 test_with_selective_printing(vftcidb1
, (V128_V_RES_AS_INT
|
254 V128_V_ARG1_AS_FLOAT64
|
256 test_with_selective_printing(vftcidb2
, (V128_V_RES_AS_INT
|
257 V128_V_ARG1_AS_FLOAT64
|
259 test_with_selective_printing(vftcidb3
, (V128_V_RES_AS_INT
|
260 V128_V_ARG1_AS_FLOAT64
|
262 test_with_selective_printing(vftcidb4
, (V128_V_RES_AS_INT
|
263 V128_V_ARG1_AS_FLOAT64
|
265 test_with_selective_printing(vftcidb8
, (V128_V_RES_AS_INT
|
266 V128_V_ARG1_AS_FLOAT64
|
268 test_with_selective_printing(vftcidb16
, (V128_V_RES_AS_INT
|
269 V128_V_ARG1_AS_FLOAT64
|
271 test_with_selective_printing(vftcidb32
, (V128_V_RES_AS_INT
|
272 V128_V_ARG1_AS_FLOAT64
|
274 test_with_selective_printing(vftcidb64
, (V128_V_RES_AS_INT
|
275 V128_V_ARG1_AS_FLOAT64
|
277 test_with_selective_printing(vftcidb128
, (V128_V_RES_AS_INT
|
278 V128_V_ARG1_AS_FLOAT64
|
280 test_with_selective_printing(vftcidb256
, (V128_V_RES_AS_INT
|
281 V128_V_ARG1_AS_FLOAT64
|
283 test_with_selective_printing(vftcidb512
, (V128_V_RES_AS_INT
|
284 V128_V_ARG1_AS_FLOAT64
|
286 test_with_selective_printing(vftcidb1024
, (V128_V_RES_AS_INT
|
287 V128_V_ARG1_AS_FLOAT64
|
289 test_with_selective_printing(vftcidb2048
, (V128_V_RES_AS_INT
|
290 V128_V_ARG1_AS_FLOAT64
|