1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -verify-machineinstrs -mtriple=powerpc64le-unknown-linux-gnu \
3 ; RUN: -mcpu=pwr10 -ppc-asm-full-reg-names -ppc-vsr-nums-as-vr \
4 ; RUN: < %s | FileCheck %s --check-prefixes=CHECK,CHECK-POSTP8,CHECK-P10
5 ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu \
6 ; RUN: -mcpu=pwr10 -ppc-asm-full-reg-names -ppc-vsr-nums-as-vr \
7 ; RUN: < %s | FileCheck %s --check-prefixes=CHECK,CHECK-POSTP8,CHECK-P10
8 ; RUN: llc -verify-machineinstrs -mtriple=powerpc64le-unknown-linux-gnu \
9 ; RUN: -mcpu=pwr9 -ppc-asm-full-reg-names -ppc-vsr-nums-as-vr \
10 ; RUN: < %s | FileCheck %s --check-prefixes=CHECK,CHECK-POSTP8,CHECK-PREP10,CHECK-P9
11 ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu \
12 ; RUN: -mcpu=pwr9 -ppc-asm-full-reg-names -ppc-vsr-nums-as-vr \
13 ; RUN: < %s | FileCheck %s --check-prefixes=CHECK,CHECK-POSTP8,CHECK-PREP10,CHECK-P9
14 ; RUN: llc -verify-machineinstrs -mtriple=powerpc64le-unknown-linux-gnu \
15 ; RUN: -mcpu=pwr8 -ppc-asm-full-reg-names -ppc-vsr-nums-as-vr \
16 ; RUN: < %s | FileCheck %s --check-prefixes=CHECK,CHECK-PREP10,CHECK-P8
17 ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu \
18 ; RUN: -mcpu=pwr8 -ppc-asm-full-reg-names -ppc-vsr-nums-as-vr \
19 ; RUN: < %s | FileCheck %s --check-prefixes=CHECK,CHECK-PREP10,CHECK-P8
21 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
22 define dso_local float @ld_0_float_uint8_t(i64 %ptr) {
23 ; CHECK-POSTP8-LABEL: ld_0_float_uint8_t:
24 ; CHECK-POSTP8: # %bb.0: # %entry
25 ; CHECK-POSTP8-NEXT: lxsibzx f0, 0, r3
26 ; CHECK-POSTP8-NEXT: xscvuxdsp f1, f0
27 ; CHECK-POSTP8-NEXT: blr
29 ; CHECK-P8-LABEL: ld_0_float_uint8_t:
30 ; CHECK-P8: # %bb.0: # %entry
31 ; CHECK-P8-NEXT: lbz r3, 0(r3)
32 ; CHECK-P8-NEXT: mtfprwz f0, r3
33 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
36 %0 = inttoptr i64 %ptr to i8*
37 %1 = load i8, i8* %0, align 1
38 %conv = uitofp i8 %1 to float
42 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
43 define dso_local float @ld_align16_float_uint8_t(i8* nocapture readonly %ptr) {
44 ; CHECK-POSTP8-LABEL: ld_align16_float_uint8_t:
45 ; CHECK-POSTP8: # %bb.0: # %entry
46 ; CHECK-POSTP8-NEXT: addi r3, r3, 8
47 ; CHECK-POSTP8-NEXT: lxsibzx f0, 0, r3
48 ; CHECK-POSTP8-NEXT: xscvuxdsp f1, f0
49 ; CHECK-POSTP8-NEXT: blr
51 ; CHECK-P8-LABEL: ld_align16_float_uint8_t:
52 ; CHECK-P8: # %bb.0: # %entry
53 ; CHECK-P8-NEXT: lbz r3, 8(r3)
54 ; CHECK-P8-NEXT: mtfprwz f0, r3
55 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
58 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
59 %0 = load i8, i8* %add.ptr, align 1
60 %conv = uitofp i8 %0 to float
64 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
65 define dso_local float @ld_align32_float_uint8_t(i8* nocapture readonly %ptr) {
66 ; CHECK-P10-LABEL: ld_align32_float_uint8_t:
67 ; CHECK-P10: # %bb.0: # %entry
68 ; CHECK-P10-NEXT: pli r4, 99999000
69 ; CHECK-P10-NEXT: lxsibzx f0, r3, r4
70 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
73 ; CHECK-P9-LABEL: ld_align32_float_uint8_t:
74 ; CHECK-P9: # %bb.0: # %entry
75 ; CHECK-P9-NEXT: lis r4, 1525
76 ; CHECK-P9-NEXT: ori r4, r4, 56600
77 ; CHECK-P9-NEXT: lxsibzx f0, r3, r4
78 ; CHECK-P9-NEXT: xscvuxdsp f1, f0
81 ; CHECK-P8-LABEL: ld_align32_float_uint8_t:
82 ; CHECK-P8: # %bb.0: # %entry
83 ; CHECK-P8-NEXT: lis r4, 1525
84 ; CHECK-P8-NEXT: ori r4, r4, 56600
85 ; CHECK-P8-NEXT: lbzx r3, r3, r4
86 ; CHECK-P8-NEXT: mtfprwz f0, r3
87 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
90 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
91 %0 = load i8, i8* %add.ptr, align 1
92 %conv = uitofp i8 %0 to float
96 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
97 define dso_local float @ld_align64_float_uint8_t(i8* nocapture readonly %ptr) {
98 ; CHECK-P10-LABEL: ld_align64_float_uint8_t:
99 ; CHECK-P10: # %bb.0: # %entry
100 ; CHECK-P10-NEXT: pli r4, 244140625
101 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
102 ; CHECK-P10-NEXT: lxsibzx f0, r3, r4
103 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
104 ; CHECK-P10-NEXT: blr
106 ; CHECK-P9-LABEL: ld_align64_float_uint8_t:
107 ; CHECK-P9: # %bb.0: # %entry
108 ; CHECK-P9-NEXT: lis r4, 3725
109 ; CHECK-P9-NEXT: ori r4, r4, 19025
110 ; CHECK-P9-NEXT: rldic r4, r4, 12, 24
111 ; CHECK-P9-NEXT: lxsibzx f0, r3, r4
112 ; CHECK-P9-NEXT: xscvuxdsp f1, f0
115 ; CHECK-P8-LABEL: ld_align64_float_uint8_t:
116 ; CHECK-P8: # %bb.0: # %entry
117 ; CHECK-P8-NEXT: lis r4, 3725
118 ; CHECK-P8-NEXT: ori r4, r4, 19025
119 ; CHECK-P8-NEXT: rldic r4, r4, 12, 24
120 ; CHECK-P8-NEXT: lbzx r3, r3, r4
121 ; CHECK-P8-NEXT: mtfprwz f0, r3
122 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
125 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
126 %0 = load i8, i8* %add.ptr, align 1
127 %conv = uitofp i8 %0 to float
131 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
132 define dso_local float @ld_reg_float_uint8_t(i8* nocapture readonly %ptr, i64 %off) {
133 ; CHECK-POSTP8-LABEL: ld_reg_float_uint8_t:
134 ; CHECK-POSTP8: # %bb.0: # %entry
135 ; CHECK-POSTP8-NEXT: lxsibzx f0, r3, r4
136 ; CHECK-POSTP8-NEXT: xscvuxdsp f1, f0
137 ; CHECK-POSTP8-NEXT: blr
139 ; CHECK-P8-LABEL: ld_reg_float_uint8_t:
140 ; CHECK-P8: # %bb.0: # %entry
141 ; CHECK-P8-NEXT: lbzx r3, r3, r4
142 ; CHECK-P8-NEXT: mtfprwz f0, r3
143 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
146 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
147 %0 = load i8, i8* %add.ptr, align 1
148 %conv = uitofp i8 %0 to float
152 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
153 define dso_local float @ld_or_float_uint8_t(i64 %ptr, i8 zeroext %off) {
154 ; CHECK-POSTP8-LABEL: ld_or_float_uint8_t:
155 ; CHECK-POSTP8: # %bb.0: # %entry
156 ; CHECK-POSTP8-NEXT: or r3, r4, r3
157 ; CHECK-POSTP8-NEXT: lxsibzx f0, 0, r3
158 ; CHECK-POSTP8-NEXT: xscvuxdsp f1, f0
159 ; CHECK-POSTP8-NEXT: blr
161 ; CHECK-P8-LABEL: ld_or_float_uint8_t:
162 ; CHECK-P8: # %bb.0: # %entry
163 ; CHECK-P8-NEXT: or r3, r4, r3
164 ; CHECK-P8-NEXT: lbz r3, 0(r3)
165 ; CHECK-P8-NEXT: mtfprwz f0, r3
166 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
169 %conv = zext i8 %off to i64
170 %or = or i64 %conv, %ptr
171 %0 = inttoptr i64 %or to i8*
172 %1 = load i8, i8* %0, align 1
173 %conv1 = uitofp i8 %1 to float
177 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
178 define dso_local float @ld_not_disjoint16_float_uint8_t(i64 %ptr) {
179 ; CHECK-POSTP8-LABEL: ld_not_disjoint16_float_uint8_t:
180 ; CHECK-POSTP8: # %bb.0: # %entry
181 ; CHECK-POSTP8-NEXT: ori r3, r3, 6
182 ; CHECK-POSTP8-NEXT: lxsibzx f0, 0, r3
183 ; CHECK-POSTP8-NEXT: xscvuxdsp f1, f0
184 ; CHECK-POSTP8-NEXT: blr
186 ; CHECK-P8-LABEL: ld_not_disjoint16_float_uint8_t:
187 ; CHECK-P8: # %bb.0: # %entry
188 ; CHECK-P8-NEXT: ori r3, r3, 6
189 ; CHECK-P8-NEXT: lbz r3, 0(r3)
190 ; CHECK-P8-NEXT: mtfprwz f0, r3
191 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
195 %0 = inttoptr i64 %or to i8*
196 %1 = load i8, i8* %0, align 1
197 %conv = uitofp i8 %1 to float
201 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
202 define dso_local float @ld_disjoint_align16_float_uint8_t(i64 %ptr) {
203 ; CHECK-POSTP8-LABEL: ld_disjoint_align16_float_uint8_t:
204 ; CHECK-POSTP8: # %bb.0: # %entry
205 ; CHECK-POSTP8-NEXT: rldicr r3, r3, 0, 51
206 ; CHECK-POSTP8-NEXT: ori r3, r3, 24
207 ; CHECK-POSTP8-NEXT: lxsibzx f0, 0, r3
208 ; CHECK-POSTP8-NEXT: xscvuxdsp f1, f0
209 ; CHECK-POSTP8-NEXT: blr
211 ; CHECK-P8-LABEL: ld_disjoint_align16_float_uint8_t:
212 ; CHECK-P8: # %bb.0: # %entry
213 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 51
214 ; CHECK-P8-NEXT: lbz r3, 24(r3)
215 ; CHECK-P8-NEXT: mtfprwz f0, r3
216 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
219 %and = and i64 %ptr, -4096
220 %or = or i64 %and, 24
221 %0 = inttoptr i64 %or to i8*
222 %1 = load i8, i8* %0, align 8
223 %conv = uitofp i8 %1 to float
227 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
228 define dso_local float @ld_not_disjoint32_float_uint8_t(i64 %ptr) {
229 ; CHECK-POSTP8-LABEL: ld_not_disjoint32_float_uint8_t:
230 ; CHECK-POSTP8: # %bb.0: # %entry
231 ; CHECK-POSTP8-NEXT: ori r3, r3, 34463
232 ; CHECK-POSTP8-NEXT: oris r3, r3, 1
233 ; CHECK-POSTP8-NEXT: lxsibzx f0, 0, r3
234 ; CHECK-POSTP8-NEXT: xscvuxdsp f1, f0
235 ; CHECK-POSTP8-NEXT: blr
237 ; CHECK-P8-LABEL: ld_not_disjoint32_float_uint8_t:
238 ; CHECK-P8: # %bb.0: # %entry
239 ; CHECK-P8-NEXT: ori r3, r3, 34463
240 ; CHECK-P8-NEXT: oris r3, r3, 1
241 ; CHECK-P8-NEXT: lbz r3, 0(r3)
242 ; CHECK-P8-NEXT: mtfprwz f0, r3
243 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
246 %or = or i64 %ptr, 99999
247 %0 = inttoptr i64 %or to i8*
248 %1 = load i8, i8* %0, align 1
249 %conv = uitofp i8 %1 to float
253 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
254 define dso_local float @ld_disjoint_align32_float_uint8_t(i64 %ptr) {
255 ; CHECK-P10-LABEL: ld_disjoint_align32_float_uint8_t:
256 ; CHECK-P10: # %bb.0: # %entry
257 ; CHECK-P10-NEXT: lis r4, -15264
258 ; CHECK-P10-NEXT: and r3, r3, r4
259 ; CHECK-P10-NEXT: pli r4, 999990000
260 ; CHECK-P10-NEXT: lxsibzx f0, r3, r4
261 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
262 ; CHECK-P10-NEXT: blr
264 ; CHECK-P9-LABEL: ld_disjoint_align32_float_uint8_t:
265 ; CHECK-P9: # %bb.0: # %entry
266 ; CHECK-P9-NEXT: lis r4, -15264
267 ; CHECK-P9-NEXT: and r3, r3, r4
268 ; CHECK-P9-NEXT: lis r4, 15258
269 ; CHECK-P9-NEXT: ori r4, r4, 41712
270 ; CHECK-P9-NEXT: lxsibzx f0, r3, r4
271 ; CHECK-P9-NEXT: xscvuxdsp f1, f0
274 ; CHECK-P8-LABEL: ld_disjoint_align32_float_uint8_t:
275 ; CHECK-P8: # %bb.0: # %entry
276 ; CHECK-P8-NEXT: lis r4, -15264
277 ; CHECK-P8-NEXT: lis r5, 15258
278 ; CHECK-P8-NEXT: and r3, r3, r4
279 ; CHECK-P8-NEXT: ori r4, r5, 41712
280 ; CHECK-P8-NEXT: lbzx r3, r3, r4
281 ; CHECK-P8-NEXT: mtfprwz f0, r3
282 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
285 %and = and i64 %ptr, -1000341504
286 %or = or i64 %and, 999990000
287 %0 = inttoptr i64 %or to i8*
288 %1 = load i8, i8* %0, align 16
289 %conv = uitofp i8 %1 to float
293 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
294 define dso_local float @ld_not_disjoint64_float_uint8_t(i64 %ptr) {
295 ; CHECK-P10-LABEL: ld_not_disjoint64_float_uint8_t:
296 ; CHECK-P10: # %bb.0: # %entry
297 ; CHECK-P10-NEXT: pli r4, 232
298 ; CHECK-P10-NEXT: pli r5, 3567587329
299 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
300 ; CHECK-P10-NEXT: or r3, r3, r5
301 ; CHECK-P10-NEXT: lxsibzx f0, 0, r3
302 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
303 ; CHECK-P10-NEXT: blr
305 ; CHECK-P9-LABEL: ld_not_disjoint64_float_uint8_t:
306 ; CHECK-P9: # %bb.0: # %entry
307 ; CHECK-P9-NEXT: li r4, 29
308 ; CHECK-P9-NEXT: rldic r4, r4, 35, 24
309 ; CHECK-P9-NEXT: oris r4, r4, 54437
310 ; CHECK-P9-NEXT: ori r4, r4, 4097
311 ; CHECK-P9-NEXT: or r3, r3, r4
312 ; CHECK-P9-NEXT: lxsibzx f0, 0, r3
313 ; CHECK-P9-NEXT: xscvuxdsp f1, f0
316 ; CHECK-P8-LABEL: ld_not_disjoint64_float_uint8_t:
317 ; CHECK-P8: # %bb.0: # %entry
318 ; CHECK-P8-NEXT: li r4, 29
319 ; CHECK-P8-NEXT: rldic r4, r4, 35, 24
320 ; CHECK-P8-NEXT: oris r4, r4, 54437
321 ; CHECK-P8-NEXT: ori r4, r4, 4097
322 ; CHECK-P8-NEXT: or r3, r3, r4
323 ; CHECK-P8-NEXT: lbz r3, 0(r3)
324 ; CHECK-P8-NEXT: mtfprwz f0, r3
325 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
328 %or = or i64 %ptr, 1000000000001
329 %0 = inttoptr i64 %or to i8*
330 %1 = load i8, i8* %0, align 1
331 %conv = uitofp i8 %1 to float
335 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
336 define dso_local float @ld_disjoint_align64_float_uint8_t(i64 %ptr) {
337 ; CHECK-P10-LABEL: ld_disjoint_align64_float_uint8_t:
338 ; CHECK-P10: # %bb.0: # %entry
339 ; CHECK-P10-NEXT: pli r4, 244140625
340 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
341 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
342 ; CHECK-P10-NEXT: lxsibzx f0, r3, r4
343 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
344 ; CHECK-P10-NEXT: blr
346 ; CHECK-P9-LABEL: ld_disjoint_align64_float_uint8_t:
347 ; CHECK-P9: # %bb.0: # %entry
348 ; CHECK-P9-NEXT: lis r4, 3725
349 ; CHECK-P9-NEXT: rldicr r3, r3, 0, 23
350 ; CHECK-P9-NEXT: ori r4, r4, 19025
351 ; CHECK-P9-NEXT: rldic r4, r4, 12, 24
352 ; CHECK-P9-NEXT: lxsibzx f0, r3, r4
353 ; CHECK-P9-NEXT: xscvuxdsp f1, f0
356 ; CHECK-P8-LABEL: ld_disjoint_align64_float_uint8_t:
357 ; CHECK-P8: # %bb.0: # %entry
358 ; CHECK-P8-NEXT: lis r4, 3725
359 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 23
360 ; CHECK-P8-NEXT: ori r4, r4, 19025
361 ; CHECK-P8-NEXT: rldic r4, r4, 12, 24
362 ; CHECK-P8-NEXT: lbzx r3, r3, r4
363 ; CHECK-P8-NEXT: mtfprwz f0, r3
364 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
367 %and = and i64 %ptr, -1099511627776
368 %or = or i64 %and, 1000000000000
369 %0 = inttoptr i64 %or to i8*
370 %1 = load i8, i8* %0, align 4096
371 %conv = uitofp i8 %1 to float
375 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
376 define dso_local float @ld_cst_align16_float_uint8_t() {
377 ; CHECK-POSTP8-LABEL: ld_cst_align16_float_uint8_t:
378 ; CHECK-POSTP8: # %bb.0: # %entry
379 ; CHECK-POSTP8-NEXT: li r3, 4080
380 ; CHECK-POSTP8-NEXT: lxsibzx f0, 0, r3
381 ; CHECK-POSTP8-NEXT: xscvuxdsp f1, f0
382 ; CHECK-POSTP8-NEXT: blr
384 ; CHECK-P8-LABEL: ld_cst_align16_float_uint8_t:
385 ; CHECK-P8: # %bb.0: # %entry
386 ; CHECK-P8-NEXT: lbz r3, 4080(0)
387 ; CHECK-P8-NEXT: mtfprwz f0, r3
388 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
391 %0 = load i8, i8* inttoptr (i64 4080 to i8*), align 16
392 %conv = uitofp i8 %0 to float
396 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
397 define dso_local float @ld_cst_align32_float_uint8_t() {
398 ; CHECK-P10-LABEL: ld_cst_align32_float_uint8_t:
399 ; CHECK-P10: # %bb.0: # %entry
400 ; CHECK-P10-NEXT: pli r3, 9999900
401 ; CHECK-P10-NEXT: lxsibzx f0, 0, r3
402 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
403 ; CHECK-P10-NEXT: blr
405 ; CHECK-P9-LABEL: ld_cst_align32_float_uint8_t:
406 ; CHECK-P9: # %bb.0: # %entry
407 ; CHECK-P9-NEXT: lis r3, 152
408 ; CHECK-P9-NEXT: ori r3, r3, 38428
409 ; CHECK-P9-NEXT: lxsibzx f0, 0, r3
410 ; CHECK-P9-NEXT: xscvuxdsp f1, f0
413 ; CHECK-P8-LABEL: ld_cst_align32_float_uint8_t:
414 ; CHECK-P8: # %bb.0: # %entry
415 ; CHECK-P8-NEXT: lis r3, 153
416 ; CHECK-P8-NEXT: lbz r3, -27108(r3)
417 ; CHECK-P8-NEXT: mtfprwz f0, r3
418 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
421 %0 = load i8, i8* inttoptr (i64 9999900 to i8*), align 4
422 %conv = uitofp i8 %0 to float
426 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
427 define dso_local float @ld_cst_align64_float_uint8_t() {
428 ; CHECK-P10-LABEL: ld_cst_align64_float_uint8_t:
429 ; CHECK-P10: # %bb.0: # %entry
430 ; CHECK-P10-NEXT: pli r3, 244140625
431 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
432 ; CHECK-P10-NEXT: lxsibzx f0, 0, r3
433 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
434 ; CHECK-P10-NEXT: blr
436 ; CHECK-P9-LABEL: ld_cst_align64_float_uint8_t:
437 ; CHECK-P9: # %bb.0: # %entry
438 ; CHECK-P9-NEXT: lis r3, 3725
439 ; CHECK-P9-NEXT: ori r3, r3, 19025
440 ; CHECK-P9-NEXT: rldic r3, r3, 12, 24
441 ; CHECK-P9-NEXT: lxsibzx f0, 0, r3
442 ; CHECK-P9-NEXT: xscvuxdsp f1, f0
445 ; CHECK-P8-LABEL: ld_cst_align64_float_uint8_t:
446 ; CHECK-P8: # %bb.0: # %entry
447 ; CHECK-P8-NEXT: lis r3, 3725
448 ; CHECK-P8-NEXT: ori r3, r3, 19025
449 ; CHECK-P8-NEXT: rldic r3, r3, 12, 24
450 ; CHECK-P8-NEXT: lbz r3, 0(r3)
451 ; CHECK-P8-NEXT: mtfprwz f0, r3
452 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
455 %0 = load i8, i8* inttoptr (i64 1000000000000 to i8*), align 4096
456 %conv = uitofp i8 %0 to float
460 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
461 define dso_local float @ld_0_float_int8_t(i64 %ptr) {
462 ; CHECK-POSTP8-LABEL: ld_0_float_int8_t:
463 ; CHECK-POSTP8: # %bb.0: # %entry
464 ; CHECK-POSTP8-NEXT: lxsibzx v2, 0, r3
465 ; CHECK-POSTP8-NEXT: vextsb2d v2, v2
466 ; CHECK-POSTP8-NEXT: xscvsxdsp f1, v2
467 ; CHECK-POSTP8-NEXT: blr
469 ; CHECK-P8-LABEL: ld_0_float_int8_t:
470 ; CHECK-P8: # %bb.0: # %entry
471 ; CHECK-P8-NEXT: lbz r3, 0(r3)
472 ; CHECK-P8-NEXT: extsb r3, r3
473 ; CHECK-P8-NEXT: mtfprwa f0, r3
474 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
477 %0 = inttoptr i64 %ptr to i8*
478 %1 = load i8, i8* %0, align 1
479 %conv = sitofp i8 %1 to float
483 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
484 define dso_local float @ld_align16_float_int8_t(i8* nocapture readonly %ptr) {
485 ; CHECK-POSTP8-LABEL: ld_align16_float_int8_t:
486 ; CHECK-POSTP8: # %bb.0: # %entry
487 ; CHECK-POSTP8-NEXT: addi r3, r3, 8
488 ; CHECK-POSTP8-NEXT: lxsibzx v2, 0, r3
489 ; CHECK-POSTP8-NEXT: vextsb2d v2, v2
490 ; CHECK-POSTP8-NEXT: xscvsxdsp f1, v2
491 ; CHECK-POSTP8-NEXT: blr
493 ; CHECK-P8-LABEL: ld_align16_float_int8_t:
494 ; CHECK-P8: # %bb.0: # %entry
495 ; CHECK-P8-NEXT: lbz r3, 8(r3)
496 ; CHECK-P8-NEXT: extsb r3, r3
497 ; CHECK-P8-NEXT: mtfprwa f0, r3
498 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
501 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
502 %0 = load i8, i8* %add.ptr, align 1
503 %conv = sitofp i8 %0 to float
507 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
508 define dso_local float @ld_align32_float_int8_t(i8* nocapture readonly %ptr) {
509 ; CHECK-P10-LABEL: ld_align32_float_int8_t:
510 ; CHECK-P10: # %bb.0: # %entry
511 ; CHECK-P10-NEXT: pli r4, 99999000
512 ; CHECK-P10-NEXT: lxsibzx v2, r3, r4
513 ; CHECK-P10-NEXT: vextsb2d v2, v2
514 ; CHECK-P10-NEXT: xscvsxdsp f1, v2
515 ; CHECK-P10-NEXT: blr
517 ; CHECK-P9-LABEL: ld_align32_float_int8_t:
518 ; CHECK-P9: # %bb.0: # %entry
519 ; CHECK-P9-NEXT: lis r4, 1525
520 ; CHECK-P9-NEXT: ori r4, r4, 56600
521 ; CHECK-P9-NEXT: lxsibzx v2, r3, r4
522 ; CHECK-P9-NEXT: vextsb2d v2, v2
523 ; CHECK-P9-NEXT: xscvsxdsp f1, v2
526 ; CHECK-P8-LABEL: ld_align32_float_int8_t:
527 ; CHECK-P8: # %bb.0: # %entry
528 ; CHECK-P8-NEXT: lis r4, 1525
529 ; CHECK-P8-NEXT: ori r4, r4, 56600
530 ; CHECK-P8-NEXT: lbzx r3, r3, r4
531 ; CHECK-P8-NEXT: extsb r3, r3
532 ; CHECK-P8-NEXT: mtfprwa f0, r3
533 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
536 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
537 %0 = load i8, i8* %add.ptr, align 1
538 %conv = sitofp i8 %0 to float
542 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
543 define dso_local float @ld_align64_float_int8_t(i8* nocapture readonly %ptr) {
544 ; CHECK-P10-LABEL: ld_align64_float_int8_t:
545 ; CHECK-P10: # %bb.0: # %entry
546 ; CHECK-P10-NEXT: pli r4, 244140625
547 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
548 ; CHECK-P10-NEXT: lxsibzx v2, r3, r4
549 ; CHECK-P10-NEXT: vextsb2d v2, v2
550 ; CHECK-P10-NEXT: xscvsxdsp f1, v2
551 ; CHECK-P10-NEXT: blr
553 ; CHECK-P9-LABEL: ld_align64_float_int8_t:
554 ; CHECK-P9: # %bb.0: # %entry
555 ; CHECK-P9-NEXT: lis r4, 3725
556 ; CHECK-P9-NEXT: ori r4, r4, 19025
557 ; CHECK-P9-NEXT: rldic r4, r4, 12, 24
558 ; CHECK-P9-NEXT: lxsibzx v2, r3, r4
559 ; CHECK-P9-NEXT: vextsb2d v2, v2
560 ; CHECK-P9-NEXT: xscvsxdsp f1, v2
563 ; CHECK-P8-LABEL: ld_align64_float_int8_t:
564 ; CHECK-P8: # %bb.0: # %entry
565 ; CHECK-P8-NEXT: lis r4, 3725
566 ; CHECK-P8-NEXT: ori r4, r4, 19025
567 ; CHECK-P8-NEXT: rldic r4, r4, 12, 24
568 ; CHECK-P8-NEXT: lbzx r3, r3, r4
569 ; CHECK-P8-NEXT: extsb r3, r3
570 ; CHECK-P8-NEXT: mtfprwa f0, r3
571 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
574 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
575 %0 = load i8, i8* %add.ptr, align 1
576 %conv = sitofp i8 %0 to float
580 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
581 define dso_local float @ld_reg_float_int8_t(i8* nocapture readonly %ptr, i64 %off) {
582 ; CHECK-POSTP8-LABEL: ld_reg_float_int8_t:
583 ; CHECK-POSTP8: # %bb.0: # %entry
584 ; CHECK-POSTP8-NEXT: lxsibzx v2, r3, r4
585 ; CHECK-POSTP8-NEXT: vextsb2d v2, v2
586 ; CHECK-POSTP8-NEXT: xscvsxdsp f1, v2
587 ; CHECK-POSTP8-NEXT: blr
589 ; CHECK-P8-LABEL: ld_reg_float_int8_t:
590 ; CHECK-P8: # %bb.0: # %entry
591 ; CHECK-P8-NEXT: lbzx r3, r3, r4
592 ; CHECK-P8-NEXT: extsb r3, r3
593 ; CHECK-P8-NEXT: mtfprwa f0, r3
594 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
597 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
598 %0 = load i8, i8* %add.ptr, align 1
599 %conv = sitofp i8 %0 to float
603 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
604 define dso_local float @ld_or_float_int8_t(i64 %ptr, i8 zeroext %off) {
605 ; CHECK-POSTP8-LABEL: ld_or_float_int8_t:
606 ; CHECK-POSTP8: # %bb.0: # %entry
607 ; CHECK-POSTP8-NEXT: or r3, r4, r3
608 ; CHECK-POSTP8-NEXT: lxsibzx v2, 0, r3
609 ; CHECK-POSTP8-NEXT: vextsb2d v2, v2
610 ; CHECK-POSTP8-NEXT: xscvsxdsp f1, v2
611 ; CHECK-POSTP8-NEXT: blr
613 ; CHECK-P8-LABEL: ld_or_float_int8_t:
614 ; CHECK-P8: # %bb.0: # %entry
615 ; CHECK-P8-NEXT: or r3, r4, r3
616 ; CHECK-P8-NEXT: lbz r3, 0(r3)
617 ; CHECK-P8-NEXT: extsb r3, r3
618 ; CHECK-P8-NEXT: mtfprwa f0, r3
619 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
622 %conv = zext i8 %off to i64
623 %or = or i64 %conv, %ptr
624 %0 = inttoptr i64 %or to i8*
625 %1 = load i8, i8* %0, align 1
626 %conv1 = sitofp i8 %1 to float
630 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
631 define dso_local float @ld_not_disjoint16_float_int8_t(i64 %ptr) {
632 ; CHECK-POSTP8-LABEL: ld_not_disjoint16_float_int8_t:
633 ; CHECK-POSTP8: # %bb.0: # %entry
634 ; CHECK-POSTP8-NEXT: ori r3, r3, 6
635 ; CHECK-POSTP8-NEXT: lxsibzx v2, 0, r3
636 ; CHECK-POSTP8-NEXT: vextsb2d v2, v2
637 ; CHECK-POSTP8-NEXT: xscvsxdsp f1, v2
638 ; CHECK-POSTP8-NEXT: blr
640 ; CHECK-P8-LABEL: ld_not_disjoint16_float_int8_t:
641 ; CHECK-P8: # %bb.0: # %entry
642 ; CHECK-P8-NEXT: ori r3, r3, 6
643 ; CHECK-P8-NEXT: lbz r3, 0(r3)
644 ; CHECK-P8-NEXT: extsb r3, r3
645 ; CHECK-P8-NEXT: mtfprwa f0, r3
646 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
650 %0 = inttoptr i64 %or to i8*
651 %1 = load i8, i8* %0, align 1
652 %conv = sitofp i8 %1 to float
656 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
657 define dso_local float @ld_disjoint_align16_float_int8_t(i64 %ptr) {
658 ; CHECK-POSTP8-LABEL: ld_disjoint_align16_float_int8_t:
659 ; CHECK-POSTP8: # %bb.0: # %entry
660 ; CHECK-POSTP8-NEXT: rldicr r3, r3, 0, 51
661 ; CHECK-POSTP8-NEXT: ori r3, r3, 24
662 ; CHECK-POSTP8-NEXT: lxsibzx v2, 0, r3
663 ; CHECK-POSTP8-NEXT: vextsb2d v2, v2
664 ; CHECK-POSTP8-NEXT: xscvsxdsp f1, v2
665 ; CHECK-POSTP8-NEXT: blr
667 ; CHECK-P8-LABEL: ld_disjoint_align16_float_int8_t:
668 ; CHECK-P8: # %bb.0: # %entry
669 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 51
670 ; CHECK-P8-NEXT: lbz r3, 24(r3)
671 ; CHECK-P8-NEXT: extsb r3, r3
672 ; CHECK-P8-NEXT: mtfprwa f0, r3
673 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
676 %and = and i64 %ptr, -4096
677 %or = or i64 %and, 24
678 %0 = inttoptr i64 %or to i8*
679 %1 = load i8, i8* %0, align 8
680 %conv = sitofp i8 %1 to float
684 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
685 define dso_local float @ld_not_disjoint32_float_int8_t(i64 %ptr) {
686 ; CHECK-POSTP8-LABEL: ld_not_disjoint32_float_int8_t:
687 ; CHECK-POSTP8: # %bb.0: # %entry
688 ; CHECK-POSTP8-NEXT: ori r3, r3, 34463
689 ; CHECK-POSTP8-NEXT: oris r3, r3, 1
690 ; CHECK-POSTP8-NEXT: lxsibzx v2, 0, r3
691 ; CHECK-POSTP8-NEXT: vextsb2d v2, v2
692 ; CHECK-POSTP8-NEXT: xscvsxdsp f1, v2
693 ; CHECK-POSTP8-NEXT: blr
695 ; CHECK-P8-LABEL: ld_not_disjoint32_float_int8_t:
696 ; CHECK-P8: # %bb.0: # %entry
697 ; CHECK-P8-NEXT: ori r3, r3, 34463
698 ; CHECK-P8-NEXT: oris r3, r3, 1
699 ; CHECK-P8-NEXT: lbz r3, 0(r3)
700 ; CHECK-P8-NEXT: extsb r3, r3
701 ; CHECK-P8-NEXT: mtfprwa f0, r3
702 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
705 %or = or i64 %ptr, 99999
706 %0 = inttoptr i64 %or to i8*
707 %1 = load i8, i8* %0, align 1
708 %conv = sitofp i8 %1 to float
712 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
713 define dso_local float @ld_disjoint_align32_float_int8_t(i64 %ptr) {
714 ; CHECK-P10-LABEL: ld_disjoint_align32_float_int8_t:
715 ; CHECK-P10: # %bb.0: # %entry
716 ; CHECK-P10-NEXT: lis r4, -15264
717 ; CHECK-P10-NEXT: and r3, r3, r4
718 ; CHECK-P10-NEXT: pli r4, 999990000
719 ; CHECK-P10-NEXT: lxsibzx v2, r3, r4
720 ; CHECK-P10-NEXT: vextsb2d v2, v2
721 ; CHECK-P10-NEXT: xscvsxdsp f1, v2
722 ; CHECK-P10-NEXT: blr
724 ; CHECK-P9-LABEL: ld_disjoint_align32_float_int8_t:
725 ; CHECK-P9: # %bb.0: # %entry
726 ; CHECK-P9-NEXT: lis r4, -15264
727 ; CHECK-P9-NEXT: and r3, r3, r4
728 ; CHECK-P9-NEXT: lis r4, 15258
729 ; CHECK-P9-NEXT: ori r4, r4, 41712
730 ; CHECK-P9-NEXT: lxsibzx v2, r3, r4
731 ; CHECK-P9-NEXT: vextsb2d v2, v2
732 ; CHECK-P9-NEXT: xscvsxdsp f1, v2
735 ; CHECK-P8-LABEL: ld_disjoint_align32_float_int8_t:
736 ; CHECK-P8: # %bb.0: # %entry
737 ; CHECK-P8-NEXT: lis r4, -15264
738 ; CHECK-P8-NEXT: lis r5, 15258
739 ; CHECK-P8-NEXT: and r3, r3, r4
740 ; CHECK-P8-NEXT: ori r4, r5, 41712
741 ; CHECK-P8-NEXT: lbzx r3, r3, r4
742 ; CHECK-P8-NEXT: extsb r3, r3
743 ; CHECK-P8-NEXT: mtfprwa f0, r3
744 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
747 %and = and i64 %ptr, -1000341504
748 %or = or i64 %and, 999990000
749 %0 = inttoptr i64 %or to i8*
750 %1 = load i8, i8* %0, align 16
751 %conv = sitofp i8 %1 to float
755 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
756 define dso_local float @ld_not_disjoint64_float_int8_t(i64 %ptr) {
757 ; CHECK-P10-LABEL: ld_not_disjoint64_float_int8_t:
758 ; CHECK-P10: # %bb.0: # %entry
759 ; CHECK-P10-NEXT: pli r4, 232
760 ; CHECK-P10-NEXT: pli r5, 3567587329
761 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
762 ; CHECK-P10-NEXT: or r3, r3, r5
763 ; CHECK-P10-NEXT: lxsibzx v2, 0, r3
764 ; CHECK-P10-NEXT: vextsb2d v2, v2
765 ; CHECK-P10-NEXT: xscvsxdsp f1, v2
766 ; CHECK-P10-NEXT: blr
768 ; CHECK-P9-LABEL: ld_not_disjoint64_float_int8_t:
769 ; CHECK-P9: # %bb.0: # %entry
770 ; CHECK-P9-NEXT: li r4, 29
771 ; CHECK-P9-NEXT: rldic r4, r4, 35, 24
772 ; CHECK-P9-NEXT: oris r4, r4, 54437
773 ; CHECK-P9-NEXT: ori r4, r4, 4097
774 ; CHECK-P9-NEXT: or r3, r3, r4
775 ; CHECK-P9-NEXT: lxsibzx v2, 0, r3
776 ; CHECK-P9-NEXT: vextsb2d v2, v2
777 ; CHECK-P9-NEXT: xscvsxdsp f1, v2
780 ; CHECK-P8-LABEL: ld_not_disjoint64_float_int8_t:
781 ; CHECK-P8: # %bb.0: # %entry
782 ; CHECK-P8-NEXT: li r4, 29
783 ; CHECK-P8-NEXT: rldic r4, r4, 35, 24
784 ; CHECK-P8-NEXT: oris r4, r4, 54437
785 ; CHECK-P8-NEXT: ori r4, r4, 4097
786 ; CHECK-P8-NEXT: or r3, r3, r4
787 ; CHECK-P8-NEXT: lbz r3, 0(r3)
788 ; CHECK-P8-NEXT: extsb r3, r3
789 ; CHECK-P8-NEXT: mtfprwa f0, r3
790 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
793 %or = or i64 %ptr, 1000000000001
794 %0 = inttoptr i64 %or to i8*
795 %1 = load i8, i8* %0, align 1
796 %conv = sitofp i8 %1 to float
800 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
801 define dso_local float @ld_disjoint_align64_float_int8_t(i64 %ptr) {
802 ; CHECK-P10-LABEL: ld_disjoint_align64_float_int8_t:
803 ; CHECK-P10: # %bb.0: # %entry
804 ; CHECK-P10-NEXT: pli r4, 244140625
805 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
806 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
807 ; CHECK-P10-NEXT: lxsibzx v2, r3, r4
808 ; CHECK-P10-NEXT: vextsb2d v2, v2
809 ; CHECK-P10-NEXT: xscvsxdsp f1, v2
810 ; CHECK-P10-NEXT: blr
812 ; CHECK-P9-LABEL: ld_disjoint_align64_float_int8_t:
813 ; CHECK-P9: # %bb.0: # %entry
814 ; CHECK-P9-NEXT: lis r4, 3725
815 ; CHECK-P9-NEXT: rldicr r3, r3, 0, 23
816 ; CHECK-P9-NEXT: ori r4, r4, 19025
817 ; CHECK-P9-NEXT: rldic r4, r4, 12, 24
818 ; CHECK-P9-NEXT: lxsibzx v2, r3, r4
819 ; CHECK-P9-NEXT: vextsb2d v2, v2
820 ; CHECK-P9-NEXT: xscvsxdsp f1, v2
823 ; CHECK-P8-LABEL: ld_disjoint_align64_float_int8_t:
824 ; CHECK-P8: # %bb.0: # %entry
825 ; CHECK-P8-NEXT: lis r4, 3725
826 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 23
827 ; CHECK-P8-NEXT: ori r4, r4, 19025
828 ; CHECK-P8-NEXT: rldic r4, r4, 12, 24
829 ; CHECK-P8-NEXT: lbzx r3, r3, r4
830 ; CHECK-P8-NEXT: extsb r3, r3
831 ; CHECK-P8-NEXT: mtfprwa f0, r3
832 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
835 %and = and i64 %ptr, -1099511627776
836 %or = or i64 %and, 1000000000000
837 %0 = inttoptr i64 %or to i8*
838 %1 = load i8, i8* %0, align 4096
839 %conv = sitofp i8 %1 to float
843 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
844 define dso_local float @ld_cst_align16_float_int8_t() {
845 ; CHECK-POSTP8-LABEL: ld_cst_align16_float_int8_t:
846 ; CHECK-POSTP8: # %bb.0: # %entry
847 ; CHECK-POSTP8-NEXT: li r3, 4080
848 ; CHECK-POSTP8-NEXT: lxsibzx v2, 0, r3
849 ; CHECK-POSTP8-NEXT: vextsb2d v2, v2
850 ; CHECK-POSTP8-NEXT: xscvsxdsp f1, v2
851 ; CHECK-POSTP8-NEXT: blr
853 ; CHECK-P8-LABEL: ld_cst_align16_float_int8_t:
854 ; CHECK-P8: # %bb.0: # %entry
855 ; CHECK-P8-NEXT: lbz r3, 4080(0)
856 ; CHECK-P8-NEXT: extsb r3, r3
857 ; CHECK-P8-NEXT: mtfprwa f0, r3
858 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
861 %0 = load i8, i8* inttoptr (i64 4080 to i8*), align 16
862 %conv = sitofp i8 %0 to float
866 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
867 define dso_local float @ld_cst_align32_float_int8_t() {
868 ; CHECK-P10-LABEL: ld_cst_align32_float_int8_t:
869 ; CHECK-P10: # %bb.0: # %entry
870 ; CHECK-P10-NEXT: pli r3, 9999900
871 ; CHECK-P10-NEXT: lxsibzx v2, 0, r3
872 ; CHECK-P10-NEXT: vextsb2d v2, v2
873 ; CHECK-P10-NEXT: xscvsxdsp f1, v2
874 ; CHECK-P10-NEXT: blr
876 ; CHECK-P9-LABEL: ld_cst_align32_float_int8_t:
877 ; CHECK-P9: # %bb.0: # %entry
878 ; CHECK-P9-NEXT: lis r3, 152
879 ; CHECK-P9-NEXT: ori r3, r3, 38428
880 ; CHECK-P9-NEXT: lxsibzx v2, 0, r3
881 ; CHECK-P9-NEXT: vextsb2d v2, v2
882 ; CHECK-P9-NEXT: xscvsxdsp f1, v2
885 ; CHECK-P8-LABEL: ld_cst_align32_float_int8_t:
886 ; CHECK-P8: # %bb.0: # %entry
887 ; CHECK-P8-NEXT: lis r3, 153
888 ; CHECK-P8-NEXT: lbz r3, -27108(r3)
889 ; CHECK-P8-NEXT: extsb r3, r3
890 ; CHECK-P8-NEXT: mtfprwa f0, r3
891 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
894 %0 = load i8, i8* inttoptr (i64 9999900 to i8*), align 4
895 %conv = sitofp i8 %0 to float
899 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
900 define dso_local float @ld_cst_align64_float_int8_t() {
901 ; CHECK-P10-LABEL: ld_cst_align64_float_int8_t:
902 ; CHECK-P10: # %bb.0: # %entry
903 ; CHECK-P10-NEXT: pli r3, 244140625
904 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
905 ; CHECK-P10-NEXT: lxsibzx v2, 0, r3
906 ; CHECK-P10-NEXT: vextsb2d v2, v2
907 ; CHECK-P10-NEXT: xscvsxdsp f1, v2
908 ; CHECK-P10-NEXT: blr
910 ; CHECK-P9-LABEL: ld_cst_align64_float_int8_t:
911 ; CHECK-P9: # %bb.0: # %entry
912 ; CHECK-P9-NEXT: lis r3, 3725
913 ; CHECK-P9-NEXT: ori r3, r3, 19025
914 ; CHECK-P9-NEXT: rldic r3, r3, 12, 24
915 ; CHECK-P9-NEXT: lxsibzx v2, 0, r3
916 ; CHECK-P9-NEXT: vextsb2d v2, v2
917 ; CHECK-P9-NEXT: xscvsxdsp f1, v2
920 ; CHECK-P8-LABEL: ld_cst_align64_float_int8_t:
921 ; CHECK-P8: # %bb.0: # %entry
922 ; CHECK-P8-NEXT: lis r3, 3725
923 ; CHECK-P8-NEXT: ori r3, r3, 19025
924 ; CHECK-P8-NEXT: rldic r3, r3, 12, 24
925 ; CHECK-P8-NEXT: lbz r3, 0(r3)
926 ; CHECK-P8-NEXT: extsb r3, r3
927 ; CHECK-P8-NEXT: mtfprwa f0, r3
928 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
931 %0 = load i8, i8* inttoptr (i64 1000000000000 to i8*), align 4096
932 %conv = sitofp i8 %0 to float
936 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
937 define dso_local float @ld_0_float_uint16_t(i64 %ptr) {
938 ; CHECK-POSTP8-LABEL: ld_0_float_uint16_t:
939 ; CHECK-POSTP8: # %bb.0: # %entry
940 ; CHECK-POSTP8-NEXT: lxsihzx f0, 0, r3
941 ; CHECK-POSTP8-NEXT: xscvuxdsp f1, f0
942 ; CHECK-POSTP8-NEXT: blr
944 ; CHECK-P8-LABEL: ld_0_float_uint16_t:
945 ; CHECK-P8: # %bb.0: # %entry
946 ; CHECK-P8-NEXT: lhz r3, 0(r3)
947 ; CHECK-P8-NEXT: mtfprwz f0, r3
948 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
951 %0 = inttoptr i64 %ptr to i16*
952 %1 = load i16, i16* %0, align 2
953 %conv = uitofp i16 %1 to float
957 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
958 define dso_local float @ld_align16_float_uint16_t(i8* nocapture readonly %ptr) {
959 ; CHECK-POSTP8-LABEL: ld_align16_float_uint16_t:
960 ; CHECK-POSTP8: # %bb.0: # %entry
961 ; CHECK-POSTP8-NEXT: addi r3, r3, 8
962 ; CHECK-POSTP8-NEXT: lxsihzx f0, 0, r3
963 ; CHECK-POSTP8-NEXT: xscvuxdsp f1, f0
964 ; CHECK-POSTP8-NEXT: blr
966 ; CHECK-P8-LABEL: ld_align16_float_uint16_t:
967 ; CHECK-P8: # %bb.0: # %entry
968 ; CHECK-P8-NEXT: lhz r3, 8(r3)
969 ; CHECK-P8-NEXT: mtfprwz f0, r3
970 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
973 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
974 %0 = bitcast i8* %add.ptr to i16*
975 %1 = load i16, i16* %0, align 2
976 %conv = uitofp i16 %1 to float
980 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
981 define dso_local float @ld_align32_float_uint16_t(i8* nocapture readonly %ptr) {
982 ; CHECK-P10-LABEL: ld_align32_float_uint16_t:
983 ; CHECK-P10: # %bb.0: # %entry
984 ; CHECK-P10-NEXT: pli r4, 99999000
985 ; CHECK-P10-NEXT: lxsihzx f0, r3, r4
986 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
987 ; CHECK-P10-NEXT: blr
989 ; CHECK-P9-LABEL: ld_align32_float_uint16_t:
990 ; CHECK-P9: # %bb.0: # %entry
991 ; CHECK-P9-NEXT: lis r4, 1525
992 ; CHECK-P9-NEXT: ori r4, r4, 56600
993 ; CHECK-P9-NEXT: lxsihzx f0, r3, r4
994 ; CHECK-P9-NEXT: xscvuxdsp f1, f0
997 ; CHECK-P8-LABEL: ld_align32_float_uint16_t:
998 ; CHECK-P8: # %bb.0: # %entry
999 ; CHECK-P8-NEXT: lis r4, 1525
1000 ; CHECK-P8-NEXT: ori r4, r4, 56600
1001 ; CHECK-P8-NEXT: lhzx r3, r3, r4
1002 ; CHECK-P8-NEXT: mtfprwz f0, r3
1003 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
1004 ; CHECK-P8-NEXT: blr
1006 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
1007 %0 = bitcast i8* %add.ptr to i16*
1008 %1 = load i16, i16* %0, align 2
1009 %conv = uitofp i16 %1 to float
1013 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1014 define dso_local float @ld_align64_float_uint16_t(i8* nocapture readonly %ptr) {
1015 ; CHECK-P10-LABEL: ld_align64_float_uint16_t:
1016 ; CHECK-P10: # %bb.0: # %entry
1017 ; CHECK-P10-NEXT: pli r4, 244140625
1018 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
1019 ; CHECK-P10-NEXT: lxsihzx f0, r3, r4
1020 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
1021 ; CHECK-P10-NEXT: blr
1023 ; CHECK-P9-LABEL: ld_align64_float_uint16_t:
1024 ; CHECK-P9: # %bb.0: # %entry
1025 ; CHECK-P9-NEXT: lis r4, 3725
1026 ; CHECK-P9-NEXT: ori r4, r4, 19025
1027 ; CHECK-P9-NEXT: rldic r4, r4, 12, 24
1028 ; CHECK-P9-NEXT: lxsihzx f0, r3, r4
1029 ; CHECK-P9-NEXT: xscvuxdsp f1, f0
1030 ; CHECK-P9-NEXT: blr
1032 ; CHECK-P8-LABEL: ld_align64_float_uint16_t:
1033 ; CHECK-P8: # %bb.0: # %entry
1034 ; CHECK-P8-NEXT: lis r4, 3725
1035 ; CHECK-P8-NEXT: ori r4, r4, 19025
1036 ; CHECK-P8-NEXT: rldic r4, r4, 12, 24
1037 ; CHECK-P8-NEXT: lhzx r3, r3, r4
1038 ; CHECK-P8-NEXT: mtfprwz f0, r3
1039 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
1040 ; CHECK-P8-NEXT: blr
1042 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
1043 %0 = bitcast i8* %add.ptr to i16*
1044 %1 = load i16, i16* %0, align 2
1045 %conv = uitofp i16 %1 to float
1049 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1050 define dso_local float @ld_reg_float_uint16_t(i8* nocapture readonly %ptr, i64 %off) {
1051 ; CHECK-POSTP8-LABEL: ld_reg_float_uint16_t:
1052 ; CHECK-POSTP8: # %bb.0: # %entry
1053 ; CHECK-POSTP8-NEXT: lxsihzx f0, r3, r4
1054 ; CHECK-POSTP8-NEXT: xscvuxdsp f1, f0
1055 ; CHECK-POSTP8-NEXT: blr
1057 ; CHECK-P8-LABEL: ld_reg_float_uint16_t:
1058 ; CHECK-P8: # %bb.0: # %entry
1059 ; CHECK-P8-NEXT: lhzx r3, r3, r4
1060 ; CHECK-P8-NEXT: mtfprwz f0, r3
1061 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
1062 ; CHECK-P8-NEXT: blr
1064 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
1065 %0 = bitcast i8* %add.ptr to i16*
1066 %1 = load i16, i16* %0, align 2
1067 %conv = uitofp i16 %1 to float
1071 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1072 define dso_local float @ld_or_float_uint16_t(i64 %ptr, i8 zeroext %off) {
1073 ; CHECK-POSTP8-LABEL: ld_or_float_uint16_t:
1074 ; CHECK-POSTP8: # %bb.0: # %entry
1075 ; CHECK-POSTP8-NEXT: or r3, r4, r3
1076 ; CHECK-POSTP8-NEXT: lxsihzx f0, 0, r3
1077 ; CHECK-POSTP8-NEXT: xscvuxdsp f1, f0
1078 ; CHECK-POSTP8-NEXT: blr
1080 ; CHECK-P8-LABEL: ld_or_float_uint16_t:
1081 ; CHECK-P8: # %bb.0: # %entry
1082 ; CHECK-P8-NEXT: or r3, r4, r3
1083 ; CHECK-P8-NEXT: lhz r3, 0(r3)
1084 ; CHECK-P8-NEXT: mtfprwz f0, r3
1085 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
1086 ; CHECK-P8-NEXT: blr
1088 %conv = zext i8 %off to i64
1089 %or = or i64 %conv, %ptr
1090 %0 = inttoptr i64 %or to i16*
1091 %1 = load i16, i16* %0, align 2
1092 %conv1 = uitofp i16 %1 to float
1096 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1097 define dso_local float @ld_not_disjoint16_float_uint16_t(i64 %ptr) {
1098 ; CHECK-POSTP8-LABEL: ld_not_disjoint16_float_uint16_t:
1099 ; CHECK-POSTP8: # %bb.0: # %entry
1100 ; CHECK-POSTP8-NEXT: ori r3, r3, 6
1101 ; CHECK-POSTP8-NEXT: lxsihzx f0, 0, r3
1102 ; CHECK-POSTP8-NEXT: xscvuxdsp f1, f0
1103 ; CHECK-POSTP8-NEXT: blr
1105 ; CHECK-P8-LABEL: ld_not_disjoint16_float_uint16_t:
1106 ; CHECK-P8: # %bb.0: # %entry
1107 ; CHECK-P8-NEXT: ori r3, r3, 6
1108 ; CHECK-P8-NEXT: lhz r3, 0(r3)
1109 ; CHECK-P8-NEXT: mtfprwz f0, r3
1110 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
1111 ; CHECK-P8-NEXT: blr
1113 %or = or i64 %ptr, 6
1114 %0 = inttoptr i64 %or to i16*
1115 %1 = load i16, i16* %0, align 2
1116 %conv = uitofp i16 %1 to float
1120 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1121 define dso_local float @ld_disjoint_align16_float_uint16_t(i64 %ptr) {
1122 ; CHECK-POSTP8-LABEL: ld_disjoint_align16_float_uint16_t:
1123 ; CHECK-POSTP8: # %bb.0: # %entry
1124 ; CHECK-POSTP8-NEXT: rldicr r3, r3, 0, 51
1125 ; CHECK-POSTP8-NEXT: ori r3, r3, 24
1126 ; CHECK-POSTP8-NEXT: lxsihzx f0, 0, r3
1127 ; CHECK-POSTP8-NEXT: xscvuxdsp f1, f0
1128 ; CHECK-POSTP8-NEXT: blr
1130 ; CHECK-P8-LABEL: ld_disjoint_align16_float_uint16_t:
1131 ; CHECK-P8: # %bb.0: # %entry
1132 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 51
1133 ; CHECK-P8-NEXT: lhz r3, 24(r3)
1134 ; CHECK-P8-NEXT: mtfprwz f0, r3
1135 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
1136 ; CHECK-P8-NEXT: blr
1138 %and = and i64 %ptr, -4096
1139 %or = or i64 %and, 24
1140 %0 = inttoptr i64 %or to i16*
1141 %1 = load i16, i16* %0, align 8
1142 %conv = uitofp i16 %1 to float
1146 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1147 define dso_local float @ld_not_disjoint32_float_uint16_t(i64 %ptr) {
1148 ; CHECK-POSTP8-LABEL: ld_not_disjoint32_float_uint16_t:
1149 ; CHECK-POSTP8: # %bb.0: # %entry
1150 ; CHECK-POSTP8-NEXT: ori r3, r3, 34463
1151 ; CHECK-POSTP8-NEXT: oris r3, r3, 1
1152 ; CHECK-POSTP8-NEXT: lxsihzx f0, 0, r3
1153 ; CHECK-POSTP8-NEXT: xscvuxdsp f1, f0
1154 ; CHECK-POSTP8-NEXT: blr
1156 ; CHECK-P8-LABEL: ld_not_disjoint32_float_uint16_t:
1157 ; CHECK-P8: # %bb.0: # %entry
1158 ; CHECK-P8-NEXT: ori r3, r3, 34463
1159 ; CHECK-P8-NEXT: oris r3, r3, 1
1160 ; CHECK-P8-NEXT: lhz r3, 0(r3)
1161 ; CHECK-P8-NEXT: mtfprwz f0, r3
1162 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
1163 ; CHECK-P8-NEXT: blr
1165 %or = or i64 %ptr, 99999
1166 %0 = inttoptr i64 %or to i16*
1167 %1 = load i16, i16* %0, align 2
1168 %conv = uitofp i16 %1 to float
1172 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1173 define dso_local float @ld_disjoint_align32_float_uint16_t(i64 %ptr) {
1174 ; CHECK-P10-LABEL: ld_disjoint_align32_float_uint16_t:
1175 ; CHECK-P10: # %bb.0: # %entry
1176 ; CHECK-P10-NEXT: lis r4, -15264
1177 ; CHECK-P10-NEXT: and r3, r3, r4
1178 ; CHECK-P10-NEXT: pli r4, 999990000
1179 ; CHECK-P10-NEXT: lxsihzx f0, r3, r4
1180 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
1181 ; CHECK-P10-NEXT: blr
1183 ; CHECK-P9-LABEL: ld_disjoint_align32_float_uint16_t:
1184 ; CHECK-P9: # %bb.0: # %entry
1185 ; CHECK-P9-NEXT: lis r4, -15264
1186 ; CHECK-P9-NEXT: and r3, r3, r4
1187 ; CHECK-P9-NEXT: lis r4, 15258
1188 ; CHECK-P9-NEXT: ori r4, r4, 41712
1189 ; CHECK-P9-NEXT: lxsihzx f0, r3, r4
1190 ; CHECK-P9-NEXT: xscvuxdsp f1, f0
1191 ; CHECK-P9-NEXT: blr
1193 ; CHECK-P8-LABEL: ld_disjoint_align32_float_uint16_t:
1194 ; CHECK-P8: # %bb.0: # %entry
1195 ; CHECK-P8-NEXT: lis r4, -15264
1196 ; CHECK-P8-NEXT: lis r5, 15258
1197 ; CHECK-P8-NEXT: and r3, r3, r4
1198 ; CHECK-P8-NEXT: ori r4, r5, 41712
1199 ; CHECK-P8-NEXT: lhzx r3, r3, r4
1200 ; CHECK-P8-NEXT: mtfprwz f0, r3
1201 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
1202 ; CHECK-P8-NEXT: blr
1204 %and = and i64 %ptr, -1000341504
1205 %or = or i64 %and, 999990000
1206 %0 = inttoptr i64 %or to i16*
1207 %1 = load i16, i16* %0, align 16
1208 %conv = uitofp i16 %1 to float
1212 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1213 define dso_local float @ld_not_disjoint64_float_uint16_t(i64 %ptr) {
1214 ; CHECK-P10-LABEL: ld_not_disjoint64_float_uint16_t:
1215 ; CHECK-P10: # %bb.0: # %entry
1216 ; CHECK-P10-NEXT: pli r4, 232
1217 ; CHECK-P10-NEXT: pli r5, 3567587329
1218 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
1219 ; CHECK-P10-NEXT: or r3, r3, r5
1220 ; CHECK-P10-NEXT: lxsihzx f0, 0, r3
1221 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
1222 ; CHECK-P10-NEXT: blr
1224 ; CHECK-P9-LABEL: ld_not_disjoint64_float_uint16_t:
1225 ; CHECK-P9: # %bb.0: # %entry
1226 ; CHECK-P9-NEXT: li r4, 29
1227 ; CHECK-P9-NEXT: rldic r4, r4, 35, 24
1228 ; CHECK-P9-NEXT: oris r4, r4, 54437
1229 ; CHECK-P9-NEXT: ori r4, r4, 4097
1230 ; CHECK-P9-NEXT: or r3, r3, r4
1231 ; CHECK-P9-NEXT: lxsihzx f0, 0, r3
1232 ; CHECK-P9-NEXT: xscvuxdsp f1, f0
1233 ; CHECK-P9-NEXT: blr
1235 ; CHECK-P8-LABEL: ld_not_disjoint64_float_uint16_t:
1236 ; CHECK-P8: # %bb.0: # %entry
1237 ; CHECK-P8-NEXT: li r4, 29
1238 ; CHECK-P8-NEXT: rldic r4, r4, 35, 24
1239 ; CHECK-P8-NEXT: oris r4, r4, 54437
1240 ; CHECK-P8-NEXT: ori r4, r4, 4097
1241 ; CHECK-P8-NEXT: or r3, r3, r4
1242 ; CHECK-P8-NEXT: lhz r3, 0(r3)
1243 ; CHECK-P8-NEXT: mtfprwz f0, r3
1244 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
1245 ; CHECK-P8-NEXT: blr
1247 %or = or i64 %ptr, 1000000000001
1248 %0 = inttoptr i64 %or to i16*
1249 %1 = load i16, i16* %0, align 2
1250 %conv = uitofp i16 %1 to float
1254 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1255 define dso_local float @ld_disjoint_align64_float_uint16_t(i64 %ptr) {
1256 ; CHECK-P10-LABEL: ld_disjoint_align64_float_uint16_t:
1257 ; CHECK-P10: # %bb.0: # %entry
1258 ; CHECK-P10-NEXT: pli r4, 244140625
1259 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
1260 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
1261 ; CHECK-P10-NEXT: lxsihzx f0, r3, r4
1262 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
1263 ; CHECK-P10-NEXT: blr
1265 ; CHECK-P9-LABEL: ld_disjoint_align64_float_uint16_t:
1266 ; CHECK-P9: # %bb.0: # %entry
1267 ; CHECK-P9-NEXT: lis r4, 3725
1268 ; CHECK-P9-NEXT: rldicr r3, r3, 0, 23
1269 ; CHECK-P9-NEXT: ori r4, r4, 19025
1270 ; CHECK-P9-NEXT: rldic r4, r4, 12, 24
1271 ; CHECK-P9-NEXT: lxsihzx f0, r3, r4
1272 ; CHECK-P9-NEXT: xscvuxdsp f1, f0
1273 ; CHECK-P9-NEXT: blr
1275 ; CHECK-P8-LABEL: ld_disjoint_align64_float_uint16_t:
1276 ; CHECK-P8: # %bb.0: # %entry
1277 ; CHECK-P8-NEXT: lis r4, 3725
1278 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 23
1279 ; CHECK-P8-NEXT: ori r4, r4, 19025
1280 ; CHECK-P8-NEXT: rldic r4, r4, 12, 24
1281 ; CHECK-P8-NEXT: lhzx r3, r3, r4
1282 ; CHECK-P8-NEXT: mtfprwz f0, r3
1283 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
1284 ; CHECK-P8-NEXT: blr
1286 %and = and i64 %ptr, -1099511627776
1287 %or = or i64 %and, 1000000000000
1288 %0 = inttoptr i64 %or to i16*
1289 %1 = load i16, i16* %0, align 4096
1290 %conv = uitofp i16 %1 to float
1294 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1295 define dso_local float @ld_cst_align16_float_uint16_t() {
1296 ; CHECK-POSTP8-LABEL: ld_cst_align16_float_uint16_t:
1297 ; CHECK-POSTP8: # %bb.0: # %entry
1298 ; CHECK-POSTP8-NEXT: li r3, 4080
1299 ; CHECK-POSTP8-NEXT: lxsihzx f0, 0, r3
1300 ; CHECK-POSTP8-NEXT: xscvuxdsp f1, f0
1301 ; CHECK-POSTP8-NEXT: blr
1303 ; CHECK-P8-LABEL: ld_cst_align16_float_uint16_t:
1304 ; CHECK-P8: # %bb.0: # %entry
1305 ; CHECK-P8-NEXT: lhz r3, 4080(0)
1306 ; CHECK-P8-NEXT: mtfprwz f0, r3
1307 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
1308 ; CHECK-P8-NEXT: blr
1310 %0 = load i16, i16* inttoptr (i64 4080 to i16*), align 16
1311 %conv = uitofp i16 %0 to float
1315 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1316 define dso_local float @ld_cst_align32_float_uint16_t() {
1317 ; CHECK-P10-LABEL: ld_cst_align32_float_uint16_t:
1318 ; CHECK-P10: # %bb.0: # %entry
1319 ; CHECK-P10-NEXT: pli r3, 9999900
1320 ; CHECK-P10-NEXT: lxsihzx f0, 0, r3
1321 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
1322 ; CHECK-P10-NEXT: blr
1324 ; CHECK-P9-LABEL: ld_cst_align32_float_uint16_t:
1325 ; CHECK-P9: # %bb.0: # %entry
1326 ; CHECK-P9-NEXT: lis r3, 152
1327 ; CHECK-P9-NEXT: ori r3, r3, 38428
1328 ; CHECK-P9-NEXT: lxsihzx f0, 0, r3
1329 ; CHECK-P9-NEXT: xscvuxdsp f1, f0
1330 ; CHECK-P9-NEXT: blr
1332 ; CHECK-P8-LABEL: ld_cst_align32_float_uint16_t:
1333 ; CHECK-P8: # %bb.0: # %entry
1334 ; CHECK-P8-NEXT: lis r3, 153
1335 ; CHECK-P8-NEXT: lhz r3, -27108(r3)
1336 ; CHECK-P8-NEXT: mtfprwz f0, r3
1337 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
1338 ; CHECK-P8-NEXT: blr
1340 %0 = load i16, i16* inttoptr (i64 9999900 to i16*), align 4
1341 %conv = uitofp i16 %0 to float
1345 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1346 define dso_local float @ld_cst_align64_float_uint16_t() {
1347 ; CHECK-P10-LABEL: ld_cst_align64_float_uint16_t:
1348 ; CHECK-P10: # %bb.0: # %entry
1349 ; CHECK-P10-NEXT: pli r3, 244140625
1350 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
1351 ; CHECK-P10-NEXT: lxsihzx f0, 0, r3
1352 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
1353 ; CHECK-P10-NEXT: blr
1355 ; CHECK-P9-LABEL: ld_cst_align64_float_uint16_t:
1356 ; CHECK-P9: # %bb.0: # %entry
1357 ; CHECK-P9-NEXT: lis r3, 3725
1358 ; CHECK-P9-NEXT: ori r3, r3, 19025
1359 ; CHECK-P9-NEXT: rldic r3, r3, 12, 24
1360 ; CHECK-P9-NEXT: lxsihzx f0, 0, r3
1361 ; CHECK-P9-NEXT: xscvuxdsp f1, f0
1362 ; CHECK-P9-NEXT: blr
1364 ; CHECK-P8-LABEL: ld_cst_align64_float_uint16_t:
1365 ; CHECK-P8: # %bb.0: # %entry
1366 ; CHECK-P8-NEXT: lis r3, 3725
1367 ; CHECK-P8-NEXT: ori r3, r3, 19025
1368 ; CHECK-P8-NEXT: rldic r3, r3, 12, 24
1369 ; CHECK-P8-NEXT: lhz r3, 0(r3)
1370 ; CHECK-P8-NEXT: mtfprwz f0, r3
1371 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
1372 ; CHECK-P8-NEXT: blr
1374 %0 = load i16, i16* inttoptr (i64 1000000000000 to i16*), align 4096
1375 %conv = uitofp i16 %0 to float
1379 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1380 define dso_local float @ld_0_float_int16_t(i64 %ptr) {
1381 ; CHECK-POSTP8-LABEL: ld_0_float_int16_t:
1382 ; CHECK-POSTP8: # %bb.0: # %entry
1383 ; CHECK-POSTP8-NEXT: lxsihzx v2, 0, r3
1384 ; CHECK-POSTP8-NEXT: vextsh2d v2, v2
1385 ; CHECK-POSTP8-NEXT: xscvsxdsp f1, v2
1386 ; CHECK-POSTP8-NEXT: blr
1388 ; CHECK-P8-LABEL: ld_0_float_int16_t:
1389 ; CHECK-P8: # %bb.0: # %entry
1390 ; CHECK-P8-NEXT: lha r3, 0(r3)
1391 ; CHECK-P8-NEXT: mtfprwa f0, r3
1392 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
1393 ; CHECK-P8-NEXT: blr
1395 %0 = inttoptr i64 %ptr to i16*
1396 %1 = load i16, i16* %0, align 2
1397 %conv = sitofp i16 %1 to float
1401 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1402 define dso_local float @ld_align16_float_int16_t(i8* nocapture readonly %ptr) {
1403 ; CHECK-POSTP8-LABEL: ld_align16_float_int16_t:
1404 ; CHECK-POSTP8: # %bb.0: # %entry
1405 ; CHECK-POSTP8-NEXT: addi r3, r3, 8
1406 ; CHECK-POSTP8-NEXT: lxsihzx v2, 0, r3
1407 ; CHECK-POSTP8-NEXT: vextsh2d v2, v2
1408 ; CHECK-POSTP8-NEXT: xscvsxdsp f1, v2
1409 ; CHECK-POSTP8-NEXT: blr
1411 ; CHECK-P8-LABEL: ld_align16_float_int16_t:
1412 ; CHECK-P8: # %bb.0: # %entry
1413 ; CHECK-P8-NEXT: lha r3, 8(r3)
1414 ; CHECK-P8-NEXT: mtfprwa f0, r3
1415 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
1416 ; CHECK-P8-NEXT: blr
1418 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
1419 %0 = bitcast i8* %add.ptr to i16*
1420 %1 = load i16, i16* %0, align 2
1421 %conv = sitofp i16 %1 to float
1425 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1426 define dso_local float @ld_align32_float_int16_t(i8* nocapture readonly %ptr) {
1427 ; CHECK-P10-LABEL: ld_align32_float_int16_t:
1428 ; CHECK-P10: # %bb.0: # %entry
1429 ; CHECK-P10-NEXT: pli r4, 99999000
1430 ; CHECK-P10-NEXT: lxsihzx v2, r3, r4
1431 ; CHECK-P10-NEXT: vextsh2d v2, v2
1432 ; CHECK-P10-NEXT: xscvsxdsp f1, v2
1433 ; CHECK-P10-NEXT: blr
1435 ; CHECK-P9-LABEL: ld_align32_float_int16_t:
1436 ; CHECK-P9: # %bb.0: # %entry
1437 ; CHECK-P9-NEXT: lis r4, 1525
1438 ; CHECK-P9-NEXT: ori r4, r4, 56600
1439 ; CHECK-P9-NEXT: lxsihzx v2, r3, r4
1440 ; CHECK-P9-NEXT: vextsh2d v2, v2
1441 ; CHECK-P9-NEXT: xscvsxdsp f1, v2
1442 ; CHECK-P9-NEXT: blr
1444 ; CHECK-P8-LABEL: ld_align32_float_int16_t:
1445 ; CHECK-P8: # %bb.0: # %entry
1446 ; CHECK-P8-NEXT: lis r4, 1525
1447 ; CHECK-P8-NEXT: ori r4, r4, 56600
1448 ; CHECK-P8-NEXT: lhax r3, r3, r4
1449 ; CHECK-P8-NEXT: mtfprwa f0, r3
1450 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
1451 ; CHECK-P8-NEXT: blr
1453 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
1454 %0 = bitcast i8* %add.ptr to i16*
1455 %1 = load i16, i16* %0, align 2
1456 %conv = sitofp i16 %1 to float
1460 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1461 define dso_local float @ld_align64_float_int16_t(i8* nocapture readonly %ptr) {
1462 ; CHECK-P10-LABEL: ld_align64_float_int16_t:
1463 ; CHECK-P10: # %bb.0: # %entry
1464 ; CHECK-P10-NEXT: pli r4, 244140625
1465 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
1466 ; CHECK-P10-NEXT: lxsihzx v2, r3, r4
1467 ; CHECK-P10-NEXT: vextsh2d v2, v2
1468 ; CHECK-P10-NEXT: xscvsxdsp f1, v2
1469 ; CHECK-P10-NEXT: blr
1471 ; CHECK-P9-LABEL: ld_align64_float_int16_t:
1472 ; CHECK-P9: # %bb.0: # %entry
1473 ; CHECK-P9-NEXT: lis r4, 3725
1474 ; CHECK-P9-NEXT: ori r4, r4, 19025
1475 ; CHECK-P9-NEXT: rldic r4, r4, 12, 24
1476 ; CHECK-P9-NEXT: lxsihzx v2, r3, r4
1477 ; CHECK-P9-NEXT: vextsh2d v2, v2
1478 ; CHECK-P9-NEXT: xscvsxdsp f1, v2
1479 ; CHECK-P9-NEXT: blr
1481 ; CHECK-P8-LABEL: ld_align64_float_int16_t:
1482 ; CHECK-P8: # %bb.0: # %entry
1483 ; CHECK-P8-NEXT: lis r4, 3725
1484 ; CHECK-P8-NEXT: ori r4, r4, 19025
1485 ; CHECK-P8-NEXT: rldic r4, r4, 12, 24
1486 ; CHECK-P8-NEXT: lhax r3, r3, r4
1487 ; CHECK-P8-NEXT: mtfprwa f0, r3
1488 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
1489 ; CHECK-P8-NEXT: blr
1491 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
1492 %0 = bitcast i8* %add.ptr to i16*
1493 %1 = load i16, i16* %0, align 2
1494 %conv = sitofp i16 %1 to float
1498 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1499 define dso_local float @ld_reg_float_int16_t(i8* nocapture readonly %ptr, i64 %off) {
1500 ; CHECK-POSTP8-LABEL: ld_reg_float_int16_t:
1501 ; CHECK-POSTP8: # %bb.0: # %entry
1502 ; CHECK-POSTP8-NEXT: lxsihzx v2, r3, r4
1503 ; CHECK-POSTP8-NEXT: vextsh2d v2, v2
1504 ; CHECK-POSTP8-NEXT: xscvsxdsp f1, v2
1505 ; CHECK-POSTP8-NEXT: blr
1507 ; CHECK-P8-LABEL: ld_reg_float_int16_t:
1508 ; CHECK-P8: # %bb.0: # %entry
1509 ; CHECK-P8-NEXT: lhax r3, r3, r4
1510 ; CHECK-P8-NEXT: mtfprwa f0, r3
1511 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
1512 ; CHECK-P8-NEXT: blr
1514 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
1515 %0 = bitcast i8* %add.ptr to i16*
1516 %1 = load i16, i16* %0, align 2
1517 %conv = sitofp i16 %1 to float
1521 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1522 define dso_local float @ld_or_float_int16_t(i64 %ptr, i8 zeroext %off) {
1523 ; CHECK-POSTP8-LABEL: ld_or_float_int16_t:
1524 ; CHECK-POSTP8: # %bb.0: # %entry
1525 ; CHECK-POSTP8-NEXT: or r3, r4, r3
1526 ; CHECK-POSTP8-NEXT: lxsihzx v2, 0, r3
1527 ; CHECK-POSTP8-NEXT: vextsh2d v2, v2
1528 ; CHECK-POSTP8-NEXT: xscvsxdsp f1, v2
1529 ; CHECK-POSTP8-NEXT: blr
1531 ; CHECK-P8-LABEL: ld_or_float_int16_t:
1532 ; CHECK-P8: # %bb.0: # %entry
1533 ; CHECK-P8-NEXT: or r3, r4, r3
1534 ; CHECK-P8-NEXT: lha r3, 0(r3)
1535 ; CHECK-P8-NEXT: mtfprwa f0, r3
1536 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
1537 ; CHECK-P8-NEXT: blr
1539 %conv = zext i8 %off to i64
1540 %or = or i64 %conv, %ptr
1541 %0 = inttoptr i64 %or to i16*
1542 %1 = load i16, i16* %0, align 2
1543 %conv1 = sitofp i16 %1 to float
1547 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1548 define dso_local float @ld_not_disjoint16_float_int16_t(i64 %ptr) {
1549 ; CHECK-POSTP8-LABEL: ld_not_disjoint16_float_int16_t:
1550 ; CHECK-POSTP8: # %bb.0: # %entry
1551 ; CHECK-POSTP8-NEXT: ori r3, r3, 6
1552 ; CHECK-POSTP8-NEXT: lxsihzx v2, 0, r3
1553 ; CHECK-POSTP8-NEXT: vextsh2d v2, v2
1554 ; CHECK-POSTP8-NEXT: xscvsxdsp f1, v2
1555 ; CHECK-POSTP8-NEXT: blr
1557 ; CHECK-P8-LABEL: ld_not_disjoint16_float_int16_t:
1558 ; CHECK-P8: # %bb.0: # %entry
1559 ; CHECK-P8-NEXT: ori r3, r3, 6
1560 ; CHECK-P8-NEXT: lha r3, 0(r3)
1561 ; CHECK-P8-NEXT: mtfprwa f0, r3
1562 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
1563 ; CHECK-P8-NEXT: blr
1565 %or = or i64 %ptr, 6
1566 %0 = inttoptr i64 %or to i16*
1567 %1 = load i16, i16* %0, align 2
1568 %conv = sitofp i16 %1 to float
1572 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1573 define dso_local float @ld_disjoint_align16_float_int16_t(i64 %ptr) {
1574 ; CHECK-POSTP8-LABEL: ld_disjoint_align16_float_int16_t:
1575 ; CHECK-POSTP8: # %bb.0: # %entry
1576 ; CHECK-POSTP8-NEXT: rldicr r3, r3, 0, 51
1577 ; CHECK-POSTP8-NEXT: ori r3, r3, 24
1578 ; CHECK-POSTP8-NEXT: lxsihzx v2, 0, r3
1579 ; CHECK-POSTP8-NEXT: vextsh2d v2, v2
1580 ; CHECK-POSTP8-NEXT: xscvsxdsp f1, v2
1581 ; CHECK-POSTP8-NEXT: blr
1583 ; CHECK-P8-LABEL: ld_disjoint_align16_float_int16_t:
1584 ; CHECK-P8: # %bb.0: # %entry
1585 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 51
1586 ; CHECK-P8-NEXT: lha r3, 24(r3)
1587 ; CHECK-P8-NEXT: mtfprwa f0, r3
1588 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
1589 ; CHECK-P8-NEXT: blr
1591 %and = and i64 %ptr, -4096
1592 %or = or i64 %and, 24
1593 %0 = inttoptr i64 %or to i16*
1594 %1 = load i16, i16* %0, align 8
1595 %conv = sitofp i16 %1 to float
1599 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1600 define dso_local float @ld_not_disjoint32_float_int16_t(i64 %ptr) {
1601 ; CHECK-POSTP8-LABEL: ld_not_disjoint32_float_int16_t:
1602 ; CHECK-POSTP8: # %bb.0: # %entry
1603 ; CHECK-POSTP8-NEXT: ori r3, r3, 34463
1604 ; CHECK-POSTP8-NEXT: oris r3, r3, 1
1605 ; CHECK-POSTP8-NEXT: lxsihzx v2, 0, r3
1606 ; CHECK-POSTP8-NEXT: vextsh2d v2, v2
1607 ; CHECK-POSTP8-NEXT: xscvsxdsp f1, v2
1608 ; CHECK-POSTP8-NEXT: blr
1610 ; CHECK-P8-LABEL: ld_not_disjoint32_float_int16_t:
1611 ; CHECK-P8: # %bb.0: # %entry
1612 ; CHECK-P8-NEXT: ori r3, r3, 34463
1613 ; CHECK-P8-NEXT: oris r3, r3, 1
1614 ; CHECK-P8-NEXT: lha r3, 0(r3)
1615 ; CHECK-P8-NEXT: mtfprwa f0, r3
1616 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
1617 ; CHECK-P8-NEXT: blr
1619 %or = or i64 %ptr, 99999
1620 %0 = inttoptr i64 %or to i16*
1621 %1 = load i16, i16* %0, align 2
1622 %conv = sitofp i16 %1 to float
1626 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1627 define dso_local float @ld_disjoint_align32_float_int16_t(i64 %ptr) {
1628 ; CHECK-P10-LABEL: ld_disjoint_align32_float_int16_t:
1629 ; CHECK-P10: # %bb.0: # %entry
1630 ; CHECK-P10-NEXT: lis r4, -15264
1631 ; CHECK-P10-NEXT: and r3, r3, r4
1632 ; CHECK-P10-NEXT: pli r4, 999990000
1633 ; CHECK-P10-NEXT: lxsihzx v2, r3, r4
1634 ; CHECK-P10-NEXT: vextsh2d v2, v2
1635 ; CHECK-P10-NEXT: xscvsxdsp f1, v2
1636 ; CHECK-P10-NEXT: blr
1638 ; CHECK-P9-LABEL: ld_disjoint_align32_float_int16_t:
1639 ; CHECK-P9: # %bb.0: # %entry
1640 ; CHECK-P9-NEXT: lis r4, -15264
1641 ; CHECK-P9-NEXT: and r3, r3, r4
1642 ; CHECK-P9-NEXT: lis r4, 15258
1643 ; CHECK-P9-NEXT: ori r4, r4, 41712
1644 ; CHECK-P9-NEXT: lxsihzx v2, r3, r4
1645 ; CHECK-P9-NEXT: vextsh2d v2, v2
1646 ; CHECK-P9-NEXT: xscvsxdsp f1, v2
1647 ; CHECK-P9-NEXT: blr
1649 ; CHECK-P8-LABEL: ld_disjoint_align32_float_int16_t:
1650 ; CHECK-P8: # %bb.0: # %entry
1651 ; CHECK-P8-NEXT: lis r4, -15264
1652 ; CHECK-P8-NEXT: lis r5, 15258
1653 ; CHECK-P8-NEXT: and r3, r3, r4
1654 ; CHECK-P8-NEXT: ori r4, r5, 41712
1655 ; CHECK-P8-NEXT: lhax r3, r3, r4
1656 ; CHECK-P8-NEXT: mtfprwa f0, r3
1657 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
1658 ; CHECK-P8-NEXT: blr
1660 %and = and i64 %ptr, -1000341504
1661 %or = or i64 %and, 999990000
1662 %0 = inttoptr i64 %or to i16*
1663 %1 = load i16, i16* %0, align 16
1664 %conv = sitofp i16 %1 to float
1668 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1669 define dso_local float @ld_not_disjoint64_float_int16_t(i64 %ptr) {
1670 ; CHECK-P10-LABEL: ld_not_disjoint64_float_int16_t:
1671 ; CHECK-P10: # %bb.0: # %entry
1672 ; CHECK-P10-NEXT: pli r4, 232
1673 ; CHECK-P10-NEXT: pli r5, 3567587329
1674 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
1675 ; CHECK-P10-NEXT: or r3, r3, r5
1676 ; CHECK-P10-NEXT: lxsihzx v2, 0, r3
1677 ; CHECK-P10-NEXT: vextsh2d v2, v2
1678 ; CHECK-P10-NEXT: xscvsxdsp f1, v2
1679 ; CHECK-P10-NEXT: blr
1681 ; CHECK-P9-LABEL: ld_not_disjoint64_float_int16_t:
1682 ; CHECK-P9: # %bb.0: # %entry
1683 ; CHECK-P9-NEXT: li r4, 29
1684 ; CHECK-P9-NEXT: rldic r4, r4, 35, 24
1685 ; CHECK-P9-NEXT: oris r4, r4, 54437
1686 ; CHECK-P9-NEXT: ori r4, r4, 4097
1687 ; CHECK-P9-NEXT: or r3, r3, r4
1688 ; CHECK-P9-NEXT: lxsihzx v2, 0, r3
1689 ; CHECK-P9-NEXT: vextsh2d v2, v2
1690 ; CHECK-P9-NEXT: xscvsxdsp f1, v2
1691 ; CHECK-P9-NEXT: blr
1693 ; CHECK-P8-LABEL: ld_not_disjoint64_float_int16_t:
1694 ; CHECK-P8: # %bb.0: # %entry
1695 ; CHECK-P8-NEXT: li r4, 29
1696 ; CHECK-P8-NEXT: rldic r4, r4, 35, 24
1697 ; CHECK-P8-NEXT: oris r4, r4, 54437
1698 ; CHECK-P8-NEXT: ori r4, r4, 4097
1699 ; CHECK-P8-NEXT: or r3, r3, r4
1700 ; CHECK-P8-NEXT: lha r3, 0(r3)
1701 ; CHECK-P8-NEXT: mtfprwa f0, r3
1702 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
1703 ; CHECK-P8-NEXT: blr
1705 %or = or i64 %ptr, 1000000000001
1706 %0 = inttoptr i64 %or to i16*
1707 %1 = load i16, i16* %0, align 2
1708 %conv = sitofp i16 %1 to float
1712 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1713 define dso_local float @ld_disjoint_align64_float_int16_t(i64 %ptr) {
1714 ; CHECK-P10-LABEL: ld_disjoint_align64_float_int16_t:
1715 ; CHECK-P10: # %bb.0: # %entry
1716 ; CHECK-P10-NEXT: pli r4, 244140625
1717 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
1718 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
1719 ; CHECK-P10-NEXT: lxsihzx v2, r3, r4
1720 ; CHECK-P10-NEXT: vextsh2d v2, v2
1721 ; CHECK-P10-NEXT: xscvsxdsp f1, v2
1722 ; CHECK-P10-NEXT: blr
1724 ; CHECK-P9-LABEL: ld_disjoint_align64_float_int16_t:
1725 ; CHECK-P9: # %bb.0: # %entry
1726 ; CHECK-P9-NEXT: lis r4, 3725
1727 ; CHECK-P9-NEXT: rldicr r3, r3, 0, 23
1728 ; CHECK-P9-NEXT: ori r4, r4, 19025
1729 ; CHECK-P9-NEXT: rldic r4, r4, 12, 24
1730 ; CHECK-P9-NEXT: lxsihzx v2, r3, r4
1731 ; CHECK-P9-NEXT: vextsh2d v2, v2
1732 ; CHECK-P9-NEXT: xscvsxdsp f1, v2
1733 ; CHECK-P9-NEXT: blr
1735 ; CHECK-P8-LABEL: ld_disjoint_align64_float_int16_t:
1736 ; CHECK-P8: # %bb.0: # %entry
1737 ; CHECK-P8-NEXT: lis r4, 3725
1738 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 23
1739 ; CHECK-P8-NEXT: ori r4, r4, 19025
1740 ; CHECK-P8-NEXT: rldic r4, r4, 12, 24
1741 ; CHECK-P8-NEXT: lhax r3, r3, r4
1742 ; CHECK-P8-NEXT: mtfprwa f0, r3
1743 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
1744 ; CHECK-P8-NEXT: blr
1746 %and = and i64 %ptr, -1099511627776
1747 %or = or i64 %and, 1000000000000
1748 %0 = inttoptr i64 %or to i16*
1749 %1 = load i16, i16* %0, align 4096
1750 %conv = sitofp i16 %1 to float
1754 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1755 define dso_local float @ld_cst_align16_float_int16_t() {
1756 ; CHECK-POSTP8-LABEL: ld_cst_align16_float_int16_t:
1757 ; CHECK-POSTP8: # %bb.0: # %entry
1758 ; CHECK-POSTP8-NEXT: li r3, 4080
1759 ; CHECK-POSTP8-NEXT: lxsihzx v2, 0, r3
1760 ; CHECK-POSTP8-NEXT: vextsh2d v2, v2
1761 ; CHECK-POSTP8-NEXT: xscvsxdsp f1, v2
1762 ; CHECK-POSTP8-NEXT: blr
1764 ; CHECK-P8-LABEL: ld_cst_align16_float_int16_t:
1765 ; CHECK-P8: # %bb.0: # %entry
1766 ; CHECK-P8-NEXT: lha r3, 4080(0)
1767 ; CHECK-P8-NEXT: mtfprwa f0, r3
1768 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
1769 ; CHECK-P8-NEXT: blr
1771 %0 = load i16, i16* inttoptr (i64 4080 to i16*), align 16
1772 %conv = sitofp i16 %0 to float
1776 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1777 define dso_local float @ld_cst_align32_float_int16_t() {
1778 ; CHECK-P10-LABEL: ld_cst_align32_float_int16_t:
1779 ; CHECK-P10: # %bb.0: # %entry
1780 ; CHECK-P10-NEXT: pli r3, 9999900
1781 ; CHECK-P10-NEXT: lxsihzx v2, 0, r3
1782 ; CHECK-P10-NEXT: vextsh2d v2, v2
1783 ; CHECK-P10-NEXT: xscvsxdsp f1, v2
1784 ; CHECK-P10-NEXT: blr
1786 ; CHECK-P9-LABEL: ld_cst_align32_float_int16_t:
1787 ; CHECK-P9: # %bb.0: # %entry
1788 ; CHECK-P9-NEXT: lis r3, 152
1789 ; CHECK-P9-NEXT: ori r3, r3, 38428
1790 ; CHECK-P9-NEXT: lxsihzx v2, 0, r3
1791 ; CHECK-P9-NEXT: vextsh2d v2, v2
1792 ; CHECK-P9-NEXT: xscvsxdsp f1, v2
1793 ; CHECK-P9-NEXT: blr
1795 ; CHECK-P8-LABEL: ld_cst_align32_float_int16_t:
1796 ; CHECK-P8: # %bb.0: # %entry
1797 ; CHECK-P8-NEXT: lis r3, 153
1798 ; CHECK-P8-NEXT: lha r3, -27108(r3)
1799 ; CHECK-P8-NEXT: mtfprwa f0, r3
1800 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
1801 ; CHECK-P8-NEXT: blr
1803 %0 = load i16, i16* inttoptr (i64 9999900 to i16*), align 4
1804 %conv = sitofp i16 %0 to float
1808 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1809 define dso_local float @ld_cst_align64_float_int16_t() {
1810 ; CHECK-P10-LABEL: ld_cst_align64_float_int16_t:
1811 ; CHECK-P10: # %bb.0: # %entry
1812 ; CHECK-P10-NEXT: pli r3, 244140625
1813 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
1814 ; CHECK-P10-NEXT: lxsihzx v2, 0, r3
1815 ; CHECK-P10-NEXT: vextsh2d v2, v2
1816 ; CHECK-P10-NEXT: xscvsxdsp f1, v2
1817 ; CHECK-P10-NEXT: blr
1819 ; CHECK-P9-LABEL: ld_cst_align64_float_int16_t:
1820 ; CHECK-P9: # %bb.0: # %entry
1821 ; CHECK-P9-NEXT: lis r3, 3725
1822 ; CHECK-P9-NEXT: ori r3, r3, 19025
1823 ; CHECK-P9-NEXT: rldic r3, r3, 12, 24
1824 ; CHECK-P9-NEXT: lxsihzx v2, 0, r3
1825 ; CHECK-P9-NEXT: vextsh2d v2, v2
1826 ; CHECK-P9-NEXT: xscvsxdsp f1, v2
1827 ; CHECK-P9-NEXT: blr
1829 ; CHECK-P8-LABEL: ld_cst_align64_float_int16_t:
1830 ; CHECK-P8: # %bb.0: # %entry
1831 ; CHECK-P8-NEXT: lis r3, 3725
1832 ; CHECK-P8-NEXT: ori r3, r3, 19025
1833 ; CHECK-P8-NEXT: rldic r3, r3, 12, 24
1834 ; CHECK-P8-NEXT: lha r3, 0(r3)
1835 ; CHECK-P8-NEXT: mtfprwa f0, r3
1836 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
1837 ; CHECK-P8-NEXT: blr
1839 %0 = load i16, i16* inttoptr (i64 1000000000000 to i16*), align 4096
1840 %conv = sitofp i16 %0 to float
1844 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1845 define dso_local float @ld_0_float_uint32_t(i64 %ptr) {
1846 ; CHECK-LABEL: ld_0_float_uint32_t:
1847 ; CHECK: # %bb.0: # %entry
1848 ; CHECK-NEXT: lfiwzx f0, 0, r3
1849 ; CHECK-NEXT: xscvuxdsp f1, f0
1852 %0 = inttoptr i64 %ptr to i32*
1853 %1 = load i32, i32* %0, align 4
1854 %conv = uitofp i32 %1 to float
1858 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1859 define dso_local float @ld_align16_float_uint32_t(i8* nocapture readonly %ptr) {
1860 ; CHECK-LABEL: ld_align16_float_uint32_t:
1861 ; CHECK: # %bb.0: # %entry
1862 ; CHECK-NEXT: addi r3, r3, 8
1863 ; CHECK-NEXT: lfiwzx f0, 0, r3
1864 ; CHECK-NEXT: xscvuxdsp f1, f0
1867 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
1868 %0 = bitcast i8* %add.ptr to i32*
1869 %1 = load i32, i32* %0, align 4
1870 %conv = uitofp i32 %1 to float
1874 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1875 define dso_local float @ld_align32_float_uint32_t(i8* nocapture readonly %ptr) {
1876 ; CHECK-P10-LABEL: ld_align32_float_uint32_t:
1877 ; CHECK-P10: # %bb.0: # %entry
1878 ; CHECK-P10-NEXT: pli r4, 99999000
1879 ; CHECK-P10-NEXT: lfiwzx f0, r3, r4
1880 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
1881 ; CHECK-P10-NEXT: blr
1883 ; CHECK-PREP10-LABEL: ld_align32_float_uint32_t:
1884 ; CHECK-PREP10: # %bb.0: # %entry
1885 ; CHECK-PREP10-NEXT: lis r4, 1525
1886 ; CHECK-PREP10-NEXT: ori r4, r4, 56600
1887 ; CHECK-PREP10-NEXT: lfiwzx f0, r3, r4
1888 ; CHECK-PREP10-NEXT: xscvuxdsp f1, f0
1889 ; CHECK-PREP10-NEXT: blr
1891 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
1892 %0 = bitcast i8* %add.ptr to i32*
1893 %1 = load i32, i32* %0, align 4
1894 %conv = uitofp i32 %1 to float
1898 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1899 define dso_local float @ld_align64_float_uint32_t(i8* nocapture readonly %ptr) {
1900 ; CHECK-P10-LABEL: ld_align64_float_uint32_t:
1901 ; CHECK-P10: # %bb.0: # %entry
1902 ; CHECK-P10-NEXT: pli r4, 244140625
1903 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
1904 ; CHECK-P10-NEXT: lfiwzx f0, r3, r4
1905 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
1906 ; CHECK-P10-NEXT: blr
1908 ; CHECK-PREP10-LABEL: ld_align64_float_uint32_t:
1909 ; CHECK-PREP10: # %bb.0: # %entry
1910 ; CHECK-PREP10-NEXT: lis r4, 3725
1911 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
1912 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
1913 ; CHECK-PREP10-NEXT: lfiwzx f0, r3, r4
1914 ; CHECK-PREP10-NEXT: xscvuxdsp f1, f0
1915 ; CHECK-PREP10-NEXT: blr
1917 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
1918 %0 = bitcast i8* %add.ptr to i32*
1919 %1 = load i32, i32* %0, align 4
1920 %conv = uitofp i32 %1 to float
1924 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1925 define dso_local float @ld_reg_float_uint32_t(i8* nocapture readonly %ptr, i64 %off) {
1926 ; CHECK-LABEL: ld_reg_float_uint32_t:
1927 ; CHECK: # %bb.0: # %entry
1928 ; CHECK-NEXT: lfiwzx f0, r3, r4
1929 ; CHECK-NEXT: xscvuxdsp f1, f0
1932 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
1933 %0 = bitcast i8* %add.ptr to i32*
1934 %1 = load i32, i32* %0, align 4
1935 %conv = uitofp i32 %1 to float
1939 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1940 define dso_local float @ld_or_float_uint32_t(i64 %ptr, i8 zeroext %off) {
1941 ; CHECK-LABEL: ld_or_float_uint32_t:
1942 ; CHECK: # %bb.0: # %entry
1943 ; CHECK-NEXT: or r3, r4, r3
1944 ; CHECK-NEXT: lfiwzx f0, 0, r3
1945 ; CHECK-NEXT: xscvuxdsp f1, f0
1948 %conv = zext i8 %off to i64
1949 %or = or i64 %conv, %ptr
1950 %0 = inttoptr i64 %or to i32*
1951 %1 = load i32, i32* %0, align 4
1952 %conv1 = uitofp i32 %1 to float
1956 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1957 define dso_local float @ld_not_disjoint16_float_uint32_t(i64 %ptr) {
1958 ; CHECK-LABEL: ld_not_disjoint16_float_uint32_t:
1959 ; CHECK: # %bb.0: # %entry
1960 ; CHECK-NEXT: ori r3, r3, 6
1961 ; CHECK-NEXT: lfiwzx f0, 0, r3
1962 ; CHECK-NEXT: xscvuxdsp f1, f0
1965 %or = or i64 %ptr, 6
1966 %0 = inttoptr i64 %or to i32*
1967 %1 = load i32, i32* %0, align 4
1968 %conv = uitofp i32 %1 to float
1972 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1973 define dso_local float @ld_disjoint_align16_float_uint32_t(i64 %ptr) {
1974 ; CHECK-LABEL: ld_disjoint_align16_float_uint32_t:
1975 ; CHECK: # %bb.0: # %entry
1976 ; CHECK-NEXT: rldicr r3, r3, 0, 51
1977 ; CHECK-NEXT: ori r3, r3, 24
1978 ; CHECK-NEXT: lfiwzx f0, 0, r3
1979 ; CHECK-NEXT: xscvuxdsp f1, f0
1982 %and = and i64 %ptr, -4096
1983 %or = or i64 %and, 24
1984 %0 = inttoptr i64 %or to i32*
1985 %1 = load i32, i32* %0, align 8
1986 %conv = uitofp i32 %1 to float
1990 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
1991 define dso_local float @ld_not_disjoint32_float_uint32_t(i64 %ptr) {
1992 ; CHECK-LABEL: ld_not_disjoint32_float_uint32_t:
1993 ; CHECK: # %bb.0: # %entry
1994 ; CHECK-NEXT: ori r3, r3, 34463
1995 ; CHECK-NEXT: oris r3, r3, 1
1996 ; CHECK-NEXT: lfiwzx f0, 0, r3
1997 ; CHECK-NEXT: xscvuxdsp f1, f0
2000 %or = or i64 %ptr, 99999
2001 %0 = inttoptr i64 %or to i32*
2002 %1 = load i32, i32* %0, align 4
2003 %conv = uitofp i32 %1 to float
2007 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2008 define dso_local float @ld_disjoint_align32_float_uint32_t(i64 %ptr) {
2009 ; CHECK-P10-LABEL: ld_disjoint_align32_float_uint32_t:
2010 ; CHECK-P10: # %bb.0: # %entry
2011 ; CHECK-P10-NEXT: lis r4, -15264
2012 ; CHECK-P10-NEXT: and r3, r3, r4
2013 ; CHECK-P10-NEXT: pli r4, 999990000
2014 ; CHECK-P10-NEXT: lfiwzx f0, r3, r4
2015 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
2016 ; CHECK-P10-NEXT: blr
2018 ; CHECK-P9-LABEL: ld_disjoint_align32_float_uint32_t:
2019 ; CHECK-P9: # %bb.0: # %entry
2020 ; CHECK-P9-NEXT: lis r4, -15264
2021 ; CHECK-P9-NEXT: and r3, r3, r4
2022 ; CHECK-P9-NEXT: lis r4, 15258
2023 ; CHECK-P9-NEXT: ori r4, r4, 41712
2024 ; CHECK-P9-NEXT: lfiwzx f0, r3, r4
2025 ; CHECK-P9-NEXT: xscvuxdsp f1, f0
2026 ; CHECK-P9-NEXT: blr
2028 ; CHECK-P8-LABEL: ld_disjoint_align32_float_uint32_t:
2029 ; CHECK-P8: # %bb.0: # %entry
2030 ; CHECK-P8-NEXT: lis r4, -15264
2031 ; CHECK-P8-NEXT: lis r5, 15258
2032 ; CHECK-P8-NEXT: and r3, r3, r4
2033 ; CHECK-P8-NEXT: ori r4, r5, 41712
2034 ; CHECK-P8-NEXT: lfiwzx f0, r3, r4
2035 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
2036 ; CHECK-P8-NEXT: blr
2038 %and = and i64 %ptr, -1000341504
2039 %or = or i64 %and, 999990000
2040 %0 = inttoptr i64 %or to i32*
2041 %1 = load i32, i32* %0, align 16
2042 %conv = uitofp i32 %1 to float
2046 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2047 define dso_local float @ld_not_disjoint64_float_uint32_t(i64 %ptr) {
2048 ; CHECK-P10-LABEL: ld_not_disjoint64_float_uint32_t:
2049 ; CHECK-P10: # %bb.0: # %entry
2050 ; CHECK-P10-NEXT: pli r4, 232
2051 ; CHECK-P10-NEXT: pli r5, 3567587329
2052 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
2053 ; CHECK-P10-NEXT: or r3, r3, r5
2054 ; CHECK-P10-NEXT: lfiwzx f0, 0, r3
2055 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
2056 ; CHECK-P10-NEXT: blr
2058 ; CHECK-PREP10-LABEL: ld_not_disjoint64_float_uint32_t:
2059 ; CHECK-PREP10: # %bb.0: # %entry
2060 ; CHECK-PREP10-NEXT: li r4, 29
2061 ; CHECK-PREP10-NEXT: rldic r4, r4, 35, 24
2062 ; CHECK-PREP10-NEXT: oris r4, r4, 54437
2063 ; CHECK-PREP10-NEXT: ori r4, r4, 4097
2064 ; CHECK-PREP10-NEXT: or r3, r3, r4
2065 ; CHECK-PREP10-NEXT: lfiwzx f0, 0, r3
2066 ; CHECK-PREP10-NEXT: xscvuxdsp f1, f0
2067 ; CHECK-PREP10-NEXT: blr
2069 %or = or i64 %ptr, 1000000000001
2070 %0 = inttoptr i64 %or to i32*
2071 %1 = load i32, i32* %0, align 4
2072 %conv = uitofp i32 %1 to float
2076 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2077 define dso_local float @ld_disjoint_align64_float_uint32_t(i64 %ptr) {
2078 ; CHECK-P10-LABEL: ld_disjoint_align64_float_uint32_t:
2079 ; CHECK-P10: # %bb.0: # %entry
2080 ; CHECK-P10-NEXT: pli r4, 244140625
2081 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
2082 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
2083 ; CHECK-P10-NEXT: lfiwzx f0, r3, r4
2084 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
2085 ; CHECK-P10-NEXT: blr
2087 ; CHECK-PREP10-LABEL: ld_disjoint_align64_float_uint32_t:
2088 ; CHECK-PREP10: # %bb.0: # %entry
2089 ; CHECK-PREP10-NEXT: lis r4, 3725
2090 ; CHECK-PREP10-NEXT: rldicr r3, r3, 0, 23
2091 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
2092 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
2093 ; CHECK-PREP10-NEXT: lfiwzx f0, r3, r4
2094 ; CHECK-PREP10-NEXT: xscvuxdsp f1, f0
2095 ; CHECK-PREP10-NEXT: blr
2097 %and = and i64 %ptr, -1099511627776
2098 %or = or i64 %and, 1000000000000
2099 %0 = inttoptr i64 %or to i32*
2100 %1 = load i32, i32* %0, align 4096
2101 %conv = uitofp i32 %1 to float
2105 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2106 define dso_local float @ld_cst_align16_float_uint32_t() {
2107 ; CHECK-LABEL: ld_cst_align16_float_uint32_t:
2108 ; CHECK: # %bb.0: # %entry
2109 ; CHECK-NEXT: li r3, 4080
2110 ; CHECK-NEXT: lfiwzx f0, 0, r3
2111 ; CHECK-NEXT: xscvuxdsp f1, f0
2114 %0 = load i32, i32* inttoptr (i64 4080 to i32*), align 16
2115 %conv = uitofp i32 %0 to float
2119 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2120 define dso_local float @ld_cst_align32_float_uint32_t() {
2121 ; CHECK-P10-LABEL: ld_cst_align32_float_uint32_t:
2122 ; CHECK-P10: # %bb.0: # %entry
2123 ; CHECK-P10-NEXT: pli r3, 9999900
2124 ; CHECK-P10-NEXT: lfiwzx f0, 0, r3
2125 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
2126 ; CHECK-P10-NEXT: blr
2128 ; CHECK-PREP10-LABEL: ld_cst_align32_float_uint32_t:
2129 ; CHECK-PREP10: # %bb.0: # %entry
2130 ; CHECK-PREP10-NEXT: lis r3, 152
2131 ; CHECK-PREP10-NEXT: ori r3, r3, 38428
2132 ; CHECK-PREP10-NEXT: lfiwzx f0, 0, r3
2133 ; CHECK-PREP10-NEXT: xscvuxdsp f1, f0
2134 ; CHECK-PREP10-NEXT: blr
2136 %0 = load i32, i32* inttoptr (i64 9999900 to i32*), align 4
2137 %conv = uitofp i32 %0 to float
2141 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2142 define dso_local float @ld_cst_align64_float_uint32_t() {
2143 ; CHECK-P10-LABEL: ld_cst_align64_float_uint32_t:
2144 ; CHECK-P10: # %bb.0: # %entry
2145 ; CHECK-P10-NEXT: pli r3, 244140625
2146 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
2147 ; CHECK-P10-NEXT: lfiwzx f0, 0, r3
2148 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
2149 ; CHECK-P10-NEXT: blr
2151 ; CHECK-PREP10-LABEL: ld_cst_align64_float_uint32_t:
2152 ; CHECK-PREP10: # %bb.0: # %entry
2153 ; CHECK-PREP10-NEXT: lis r3, 3725
2154 ; CHECK-PREP10-NEXT: ori r3, r3, 19025
2155 ; CHECK-PREP10-NEXT: rldic r3, r3, 12, 24
2156 ; CHECK-PREP10-NEXT: lfiwzx f0, 0, r3
2157 ; CHECK-PREP10-NEXT: xscvuxdsp f1, f0
2158 ; CHECK-PREP10-NEXT: blr
2160 %0 = load i32, i32* inttoptr (i64 1000000000000 to i32*), align 4096
2161 %conv = uitofp i32 %0 to float
2165 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2166 define dso_local float @ld_0_float_int32_t(i64 %ptr) {
2167 ; CHECK-LABEL: ld_0_float_int32_t:
2168 ; CHECK: # %bb.0: # %entry
2169 ; CHECK-NEXT: lfiwax f0, 0, r3
2170 ; CHECK-NEXT: xscvsxdsp f1, f0
2173 %0 = inttoptr i64 %ptr to i32*
2174 %1 = load i32, i32* %0, align 4
2175 %conv = sitofp i32 %1 to float
2179 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2180 define dso_local float @ld_align16_float_int32_t(i8* nocapture readonly %ptr) {
2181 ; CHECK-LABEL: ld_align16_float_int32_t:
2182 ; CHECK: # %bb.0: # %entry
2183 ; CHECK-NEXT: addi r3, r3, 8
2184 ; CHECK-NEXT: lfiwax f0, 0, r3
2185 ; CHECK-NEXT: xscvsxdsp f1, f0
2188 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
2189 %0 = bitcast i8* %add.ptr to i32*
2190 %1 = load i32, i32* %0, align 4
2191 %conv = sitofp i32 %1 to float
2195 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2196 define dso_local float @ld_align32_float_int32_t(i8* nocapture readonly %ptr) {
2197 ; CHECK-P10-LABEL: ld_align32_float_int32_t:
2198 ; CHECK-P10: # %bb.0: # %entry
2199 ; CHECK-P10-NEXT: pli r4, 99999000
2200 ; CHECK-P10-NEXT: lfiwax f0, r3, r4
2201 ; CHECK-P10-NEXT: xscvsxdsp f1, f0
2202 ; CHECK-P10-NEXT: blr
2204 ; CHECK-PREP10-LABEL: ld_align32_float_int32_t:
2205 ; CHECK-PREP10: # %bb.0: # %entry
2206 ; CHECK-PREP10-NEXT: lis r4, 1525
2207 ; CHECK-PREP10-NEXT: ori r4, r4, 56600
2208 ; CHECK-PREP10-NEXT: lfiwax f0, r3, r4
2209 ; CHECK-PREP10-NEXT: xscvsxdsp f1, f0
2210 ; CHECK-PREP10-NEXT: blr
2212 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
2213 %0 = bitcast i8* %add.ptr to i32*
2214 %1 = load i32, i32* %0, align 4
2215 %conv = sitofp i32 %1 to float
2219 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2220 define dso_local float @ld_align64_float_int32_t(i8* nocapture readonly %ptr) {
2221 ; CHECK-P10-LABEL: ld_align64_float_int32_t:
2222 ; CHECK-P10: # %bb.0: # %entry
2223 ; CHECK-P10-NEXT: pli r4, 244140625
2224 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
2225 ; CHECK-P10-NEXT: lfiwax f0, r3, r4
2226 ; CHECK-P10-NEXT: xscvsxdsp f1, f0
2227 ; CHECK-P10-NEXT: blr
2229 ; CHECK-PREP10-LABEL: ld_align64_float_int32_t:
2230 ; CHECK-PREP10: # %bb.0: # %entry
2231 ; CHECK-PREP10-NEXT: lis r4, 3725
2232 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
2233 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
2234 ; CHECK-PREP10-NEXT: lfiwax f0, r3, r4
2235 ; CHECK-PREP10-NEXT: xscvsxdsp f1, f0
2236 ; CHECK-PREP10-NEXT: blr
2238 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
2239 %0 = bitcast i8* %add.ptr to i32*
2240 %1 = load i32, i32* %0, align 4
2241 %conv = sitofp i32 %1 to float
2245 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2246 define dso_local float @ld_reg_float_int32_t(i8* nocapture readonly %ptr, i64 %off) {
2247 ; CHECK-LABEL: ld_reg_float_int32_t:
2248 ; CHECK: # %bb.0: # %entry
2249 ; CHECK-NEXT: lfiwax f0, r3, r4
2250 ; CHECK-NEXT: xscvsxdsp f1, f0
2253 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
2254 %0 = bitcast i8* %add.ptr to i32*
2255 %1 = load i32, i32* %0, align 4
2256 %conv = sitofp i32 %1 to float
2260 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2261 define dso_local float @ld_or_float_int32_t(i64 %ptr, i8 zeroext %off) {
2262 ; CHECK-LABEL: ld_or_float_int32_t:
2263 ; CHECK: # %bb.0: # %entry
2264 ; CHECK-NEXT: or r3, r4, r3
2265 ; CHECK-NEXT: lfiwax f0, 0, r3
2266 ; CHECK-NEXT: xscvsxdsp f1, f0
2269 %conv = zext i8 %off to i64
2270 %or = or i64 %conv, %ptr
2271 %0 = inttoptr i64 %or to i32*
2272 %1 = load i32, i32* %0, align 4
2273 %conv1 = sitofp i32 %1 to float
2277 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2278 define dso_local float @ld_not_disjoint16_float_int32_t(i64 %ptr) {
2279 ; CHECK-LABEL: ld_not_disjoint16_float_int32_t:
2280 ; CHECK: # %bb.0: # %entry
2281 ; CHECK-NEXT: ori r3, r3, 6
2282 ; CHECK-NEXT: lfiwax f0, 0, r3
2283 ; CHECK-NEXT: xscvsxdsp f1, f0
2286 %or = or i64 %ptr, 6
2287 %0 = inttoptr i64 %or to i32*
2288 %1 = load i32, i32* %0, align 4
2289 %conv = sitofp i32 %1 to float
2293 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2294 define dso_local float @ld_disjoint_align16_float_int32_t(i64 %ptr) {
2295 ; CHECK-LABEL: ld_disjoint_align16_float_int32_t:
2296 ; CHECK: # %bb.0: # %entry
2297 ; CHECK-NEXT: rldicr r3, r3, 0, 51
2298 ; CHECK-NEXT: ori r3, r3, 24
2299 ; CHECK-NEXT: lfiwax f0, 0, r3
2300 ; CHECK-NEXT: xscvsxdsp f1, f0
2303 %and = and i64 %ptr, -4096
2304 %or = or i64 %and, 24
2305 %0 = inttoptr i64 %or to i32*
2306 %1 = load i32, i32* %0, align 8
2307 %conv = sitofp i32 %1 to float
2311 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2312 define dso_local float @ld_not_disjoint32_float_int32_t(i64 %ptr) {
2313 ; CHECK-LABEL: ld_not_disjoint32_float_int32_t:
2314 ; CHECK: # %bb.0: # %entry
2315 ; CHECK-NEXT: ori r3, r3, 34463
2316 ; CHECK-NEXT: oris r3, r3, 1
2317 ; CHECK-NEXT: lfiwax f0, 0, r3
2318 ; CHECK-NEXT: xscvsxdsp f1, f0
2321 %or = or i64 %ptr, 99999
2322 %0 = inttoptr i64 %or to i32*
2323 %1 = load i32, i32* %0, align 4
2324 %conv = sitofp i32 %1 to float
2328 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2329 define dso_local float @ld_disjoint_align32_float_int32_t(i64 %ptr) {
2330 ; CHECK-P10-LABEL: ld_disjoint_align32_float_int32_t:
2331 ; CHECK-P10: # %bb.0: # %entry
2332 ; CHECK-P10-NEXT: lis r4, -15264
2333 ; CHECK-P10-NEXT: and r3, r3, r4
2334 ; CHECK-P10-NEXT: pli r4, 999990000
2335 ; CHECK-P10-NEXT: lfiwax f0, r3, r4
2336 ; CHECK-P10-NEXT: xscvsxdsp f1, f0
2337 ; CHECK-P10-NEXT: blr
2339 ; CHECK-P9-LABEL: ld_disjoint_align32_float_int32_t:
2340 ; CHECK-P9: # %bb.0: # %entry
2341 ; CHECK-P9-NEXT: lis r4, -15264
2342 ; CHECK-P9-NEXT: and r3, r3, r4
2343 ; CHECK-P9-NEXT: lis r4, 15258
2344 ; CHECK-P9-NEXT: ori r4, r4, 41712
2345 ; CHECK-P9-NEXT: lfiwax f0, r3, r4
2346 ; CHECK-P9-NEXT: xscvsxdsp f1, f0
2347 ; CHECK-P9-NEXT: blr
2349 ; CHECK-P8-LABEL: ld_disjoint_align32_float_int32_t:
2350 ; CHECK-P8: # %bb.0: # %entry
2351 ; CHECK-P8-NEXT: lis r4, -15264
2352 ; CHECK-P8-NEXT: lis r5, 15258
2353 ; CHECK-P8-NEXT: and r3, r3, r4
2354 ; CHECK-P8-NEXT: ori r4, r5, 41712
2355 ; CHECK-P8-NEXT: lfiwax f0, r3, r4
2356 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
2357 ; CHECK-P8-NEXT: blr
2359 %and = and i64 %ptr, -1000341504
2360 %or = or i64 %and, 999990000
2361 %0 = inttoptr i64 %or to i32*
2362 %1 = load i32, i32* %0, align 16
2363 %conv = sitofp i32 %1 to float
2367 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2368 define dso_local float @ld_not_disjoint64_float_int32_t(i64 %ptr) {
2369 ; CHECK-P10-LABEL: ld_not_disjoint64_float_int32_t:
2370 ; CHECK-P10: # %bb.0: # %entry
2371 ; CHECK-P10-NEXT: pli r4, 232
2372 ; CHECK-P10-NEXT: pli r5, 3567587329
2373 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
2374 ; CHECK-P10-NEXT: or r3, r3, r5
2375 ; CHECK-P10-NEXT: lfiwax f0, 0, r3
2376 ; CHECK-P10-NEXT: xscvsxdsp f1, f0
2377 ; CHECK-P10-NEXT: blr
2379 ; CHECK-PREP10-LABEL: ld_not_disjoint64_float_int32_t:
2380 ; CHECK-PREP10: # %bb.0: # %entry
2381 ; CHECK-PREP10-NEXT: li r4, 29
2382 ; CHECK-PREP10-NEXT: rldic r4, r4, 35, 24
2383 ; CHECK-PREP10-NEXT: oris r4, r4, 54437
2384 ; CHECK-PREP10-NEXT: ori r4, r4, 4097
2385 ; CHECK-PREP10-NEXT: or r3, r3, r4
2386 ; CHECK-PREP10-NEXT: lfiwax f0, 0, r3
2387 ; CHECK-PREP10-NEXT: xscvsxdsp f1, f0
2388 ; CHECK-PREP10-NEXT: blr
2390 %or = or i64 %ptr, 1000000000001
2391 %0 = inttoptr i64 %or to i32*
2392 %1 = load i32, i32* %0, align 4
2393 %conv = sitofp i32 %1 to float
2397 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2398 define dso_local float @ld_disjoint_align64_float_int32_t(i64 %ptr) {
2399 ; CHECK-P10-LABEL: ld_disjoint_align64_float_int32_t:
2400 ; CHECK-P10: # %bb.0: # %entry
2401 ; CHECK-P10-NEXT: pli r4, 244140625
2402 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
2403 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
2404 ; CHECK-P10-NEXT: lfiwax f0, r3, r4
2405 ; CHECK-P10-NEXT: xscvsxdsp f1, f0
2406 ; CHECK-P10-NEXT: blr
2408 ; CHECK-PREP10-LABEL: ld_disjoint_align64_float_int32_t:
2409 ; CHECK-PREP10: # %bb.0: # %entry
2410 ; CHECK-PREP10-NEXT: lis r4, 3725
2411 ; CHECK-PREP10-NEXT: rldicr r3, r3, 0, 23
2412 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
2413 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
2414 ; CHECK-PREP10-NEXT: lfiwax f0, r3, r4
2415 ; CHECK-PREP10-NEXT: xscvsxdsp f1, f0
2416 ; CHECK-PREP10-NEXT: blr
2418 %and = and i64 %ptr, -1099511627776
2419 %or = or i64 %and, 1000000000000
2420 %0 = inttoptr i64 %or to i32*
2421 %1 = load i32, i32* %0, align 4096
2422 %conv = sitofp i32 %1 to float
2426 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2427 define dso_local float @ld_cst_align16_float_int32_t() {
2428 ; CHECK-LABEL: ld_cst_align16_float_int32_t:
2429 ; CHECK: # %bb.0: # %entry
2430 ; CHECK-NEXT: li r3, 4080
2431 ; CHECK-NEXT: lfiwax f0, 0, r3
2432 ; CHECK-NEXT: xscvsxdsp f1, f0
2435 %0 = load i32, i32* inttoptr (i64 4080 to i32*), align 16
2436 %conv = sitofp i32 %0 to float
2440 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2441 define dso_local float @ld_cst_align32_float_int32_t() {
2442 ; CHECK-P10-LABEL: ld_cst_align32_float_int32_t:
2443 ; CHECK-P10: # %bb.0: # %entry
2444 ; CHECK-P10-NEXT: pli r3, 9999900
2445 ; CHECK-P10-NEXT: lfiwax f0, 0, r3
2446 ; CHECK-P10-NEXT: xscvsxdsp f1, f0
2447 ; CHECK-P10-NEXT: blr
2449 ; CHECK-PREP10-LABEL: ld_cst_align32_float_int32_t:
2450 ; CHECK-PREP10: # %bb.0: # %entry
2451 ; CHECK-PREP10-NEXT: lis r3, 152
2452 ; CHECK-PREP10-NEXT: ori r3, r3, 38428
2453 ; CHECK-PREP10-NEXT: lfiwax f0, 0, r3
2454 ; CHECK-PREP10-NEXT: xscvsxdsp f1, f0
2455 ; CHECK-PREP10-NEXT: blr
2457 %0 = load i32, i32* inttoptr (i64 9999900 to i32*), align 4
2458 %conv = sitofp i32 %0 to float
2462 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2463 define dso_local float @ld_cst_align64_float_int32_t() {
2464 ; CHECK-P10-LABEL: ld_cst_align64_float_int32_t:
2465 ; CHECK-P10: # %bb.0: # %entry
2466 ; CHECK-P10-NEXT: pli r3, 244140625
2467 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
2468 ; CHECK-P10-NEXT: lfiwax f0, 0, r3
2469 ; CHECK-P10-NEXT: xscvsxdsp f1, f0
2470 ; CHECK-P10-NEXT: blr
2472 ; CHECK-PREP10-LABEL: ld_cst_align64_float_int32_t:
2473 ; CHECK-PREP10: # %bb.0: # %entry
2474 ; CHECK-PREP10-NEXT: lis r3, 3725
2475 ; CHECK-PREP10-NEXT: ori r3, r3, 19025
2476 ; CHECK-PREP10-NEXT: rldic r3, r3, 12, 24
2477 ; CHECK-PREP10-NEXT: lfiwax f0, 0, r3
2478 ; CHECK-PREP10-NEXT: xscvsxdsp f1, f0
2479 ; CHECK-PREP10-NEXT: blr
2481 %0 = load i32, i32* inttoptr (i64 1000000000000 to i32*), align 4096
2482 %conv = sitofp i32 %0 to float
2486 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2487 define dso_local float @ld_0_float_uint64_t(i64 %ptr) {
2488 ; CHECK-LABEL: ld_0_float_uint64_t:
2489 ; CHECK: # %bb.0: # %entry
2490 ; CHECK-NEXT: lfd f0, 0(r3)
2491 ; CHECK-NEXT: xscvuxdsp f1, f0
2494 %0 = inttoptr i64 %ptr to i64*
2495 %1 = load i64, i64* %0, align 8
2496 %conv = uitofp i64 %1 to float
2500 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2501 define dso_local float @ld_align16_float_uint64_t(i8* nocapture readonly %ptr) {
2502 ; CHECK-LABEL: ld_align16_float_uint64_t:
2503 ; CHECK: # %bb.0: # %entry
2504 ; CHECK-NEXT: lfd f0, 8(r3)
2505 ; CHECK-NEXT: xscvuxdsp f1, f0
2508 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
2509 %0 = bitcast i8* %add.ptr to i64*
2510 %1 = load i64, i64* %0, align 8
2511 %conv = uitofp i64 %1 to float
2515 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2516 define dso_local float @ld_align32_float_uint64_t(i8* nocapture readonly %ptr) {
2517 ; CHECK-P10-LABEL: ld_align32_float_uint64_t:
2518 ; CHECK-P10: # %bb.0: # %entry
2519 ; CHECK-P10-NEXT: pli r4, 99999000
2520 ; CHECK-P10-NEXT: lfdx f0, r3, r4
2521 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
2522 ; CHECK-P10-NEXT: blr
2524 ; CHECK-PREP10-LABEL: ld_align32_float_uint64_t:
2525 ; CHECK-PREP10: # %bb.0: # %entry
2526 ; CHECK-PREP10-NEXT: lis r4, 1525
2527 ; CHECK-PREP10-NEXT: ori r4, r4, 56600
2528 ; CHECK-PREP10-NEXT: lfdx f0, r3, r4
2529 ; CHECK-PREP10-NEXT: xscvuxdsp f1, f0
2530 ; CHECK-PREP10-NEXT: blr
2532 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
2533 %0 = bitcast i8* %add.ptr to i64*
2534 %1 = load i64, i64* %0, align 8
2535 %conv = uitofp i64 %1 to float
2539 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2540 define dso_local float @ld_align64_float_uint64_t(i8* nocapture readonly %ptr) {
2541 ; CHECK-P10-LABEL: ld_align64_float_uint64_t:
2542 ; CHECK-P10: # %bb.0: # %entry
2543 ; CHECK-P10-NEXT: pli r4, 244140625
2544 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
2545 ; CHECK-P10-NEXT: lfdx f0, r3, r4
2546 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
2547 ; CHECK-P10-NEXT: blr
2549 ; CHECK-PREP10-LABEL: ld_align64_float_uint64_t:
2550 ; CHECK-PREP10: # %bb.0: # %entry
2551 ; CHECK-PREP10-NEXT: lis r4, 3725
2552 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
2553 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
2554 ; CHECK-PREP10-NEXT: lfdx f0, r3, r4
2555 ; CHECK-PREP10-NEXT: xscvuxdsp f1, f0
2556 ; CHECK-PREP10-NEXT: blr
2558 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
2559 %0 = bitcast i8* %add.ptr to i64*
2560 %1 = load i64, i64* %0, align 8
2561 %conv = uitofp i64 %1 to float
2565 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2566 define dso_local float @ld_reg_float_uint64_t(i8* nocapture readonly %ptr, i64 %off) {
2567 ; CHECK-LABEL: ld_reg_float_uint64_t:
2568 ; CHECK: # %bb.0: # %entry
2569 ; CHECK-NEXT: lfdx f0, r3, r4
2570 ; CHECK-NEXT: xscvuxdsp f1, f0
2573 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
2574 %0 = bitcast i8* %add.ptr to i64*
2575 %1 = load i64, i64* %0, align 8
2576 %conv = uitofp i64 %1 to float
2580 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2581 define dso_local float @ld_or_float_uint64_t(i64 %ptr, i8 zeroext %off) {
2582 ; CHECK-LABEL: ld_or_float_uint64_t:
2583 ; CHECK: # %bb.0: # %entry
2584 ; CHECK-NEXT: or r3, r4, r3
2585 ; CHECK-NEXT: lfd f0, 0(r3)
2586 ; CHECK-NEXT: xscvuxdsp f1, f0
2589 %conv = zext i8 %off to i64
2590 %or = or i64 %conv, %ptr
2591 %0 = inttoptr i64 %or to i64*
2592 %1 = load i64, i64* %0, align 8
2593 %conv1 = uitofp i64 %1 to float
2597 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2598 define dso_local float @ld_not_disjoint16_float_uint64_t(i64 %ptr) {
2599 ; CHECK-LABEL: ld_not_disjoint16_float_uint64_t:
2600 ; CHECK: # %bb.0: # %entry
2601 ; CHECK-NEXT: ori r3, r3, 6
2602 ; CHECK-NEXT: lfd f0, 0(r3)
2603 ; CHECK-NEXT: xscvuxdsp f1, f0
2606 %or = or i64 %ptr, 6
2607 %0 = inttoptr i64 %or to i64*
2608 %1 = load i64, i64* %0, align 8
2609 %conv = uitofp i64 %1 to float
2613 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2614 define dso_local float @ld_disjoint_align16_float_uint64_t(i64 %ptr) {
2615 ; CHECK-LABEL: ld_disjoint_align16_float_uint64_t:
2616 ; CHECK: # %bb.0: # %entry
2617 ; CHECK-NEXT: rldicr r3, r3, 0, 51
2618 ; CHECK-NEXT: lfd f0, 24(r3)
2619 ; CHECK-NEXT: xscvuxdsp f1, f0
2622 %and = and i64 %ptr, -4096
2623 %or = or i64 %and, 24
2624 %0 = inttoptr i64 %or to i64*
2625 %1 = load i64, i64* %0, align 8
2626 %conv = uitofp i64 %1 to float
2630 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2631 define dso_local float @ld_not_disjoint32_float_uint64_t(i64 %ptr) {
2632 ; CHECK-LABEL: ld_not_disjoint32_float_uint64_t:
2633 ; CHECK: # %bb.0: # %entry
2634 ; CHECK-NEXT: ori r3, r3, 34463
2635 ; CHECK-NEXT: oris r3, r3, 1
2636 ; CHECK-NEXT: lfd f0, 0(r3)
2637 ; CHECK-NEXT: xscvuxdsp f1, f0
2640 %or = or i64 %ptr, 99999
2641 %0 = inttoptr i64 %or to i64*
2642 %1 = load i64, i64* %0, align 8
2643 %conv = uitofp i64 %1 to float
2647 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2648 define dso_local float @ld_disjoint_align32_float_uint64_t(i64 %ptr) {
2649 ; CHECK-P10-LABEL: ld_disjoint_align32_float_uint64_t:
2650 ; CHECK-P10: # %bb.0: # %entry
2651 ; CHECK-P10-NEXT: lis r4, -15264
2652 ; CHECK-P10-NEXT: and r3, r3, r4
2653 ; CHECK-P10-NEXT: pli r4, 999990000
2654 ; CHECK-P10-NEXT: lfdx f0, r3, r4
2655 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
2656 ; CHECK-P10-NEXT: blr
2658 ; CHECK-P9-LABEL: ld_disjoint_align32_float_uint64_t:
2659 ; CHECK-P9: # %bb.0: # %entry
2660 ; CHECK-P9-NEXT: lis r4, -15264
2661 ; CHECK-P9-NEXT: and r3, r3, r4
2662 ; CHECK-P9-NEXT: lis r4, 15258
2663 ; CHECK-P9-NEXT: ori r4, r4, 41712
2664 ; CHECK-P9-NEXT: lfdx f0, r3, r4
2665 ; CHECK-P9-NEXT: xscvuxdsp f1, f0
2666 ; CHECK-P9-NEXT: blr
2668 ; CHECK-P8-LABEL: ld_disjoint_align32_float_uint64_t:
2669 ; CHECK-P8: # %bb.0: # %entry
2670 ; CHECK-P8-NEXT: lis r4, -15264
2671 ; CHECK-P8-NEXT: lis r5, 15258
2672 ; CHECK-P8-NEXT: and r3, r3, r4
2673 ; CHECK-P8-NEXT: ori r4, r5, 41712
2674 ; CHECK-P8-NEXT: lfdx f0, r3, r4
2675 ; CHECK-P8-NEXT: xscvuxdsp f1, f0
2676 ; CHECK-P8-NEXT: blr
2678 %and = and i64 %ptr, -1000341504
2679 %or = or i64 %and, 999990000
2680 %0 = inttoptr i64 %or to i64*
2681 %1 = load i64, i64* %0, align 16
2682 %conv = uitofp i64 %1 to float
2686 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2687 define dso_local float @ld_not_disjoint64_float_uint64_t(i64 %ptr) {
2688 ; CHECK-P10-LABEL: ld_not_disjoint64_float_uint64_t:
2689 ; CHECK-P10: # %bb.0: # %entry
2690 ; CHECK-P10-NEXT: pli r4, 232
2691 ; CHECK-P10-NEXT: pli r5, 3567587329
2692 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
2693 ; CHECK-P10-NEXT: or r3, r3, r5
2694 ; CHECK-P10-NEXT: lfd f0, 0(r3)
2695 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
2696 ; CHECK-P10-NEXT: blr
2698 ; CHECK-PREP10-LABEL: ld_not_disjoint64_float_uint64_t:
2699 ; CHECK-PREP10: # %bb.0: # %entry
2700 ; CHECK-PREP10-NEXT: li r4, 29
2701 ; CHECK-PREP10-NEXT: rldic r4, r4, 35, 24
2702 ; CHECK-PREP10-NEXT: oris r4, r4, 54437
2703 ; CHECK-PREP10-NEXT: ori r4, r4, 4097
2704 ; CHECK-PREP10-NEXT: or r3, r3, r4
2705 ; CHECK-PREP10-NEXT: lfd f0, 0(r3)
2706 ; CHECK-PREP10-NEXT: xscvuxdsp f1, f0
2707 ; CHECK-PREP10-NEXT: blr
2709 %or = or i64 %ptr, 1000000000001
2710 %0 = inttoptr i64 %or to i64*
2711 %1 = load i64, i64* %0, align 8
2712 %conv = uitofp i64 %1 to float
2716 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2717 define dso_local float @ld_disjoint_align64_float_uint64_t(i64 %ptr) {
2718 ; CHECK-P10-LABEL: ld_disjoint_align64_float_uint64_t:
2719 ; CHECK-P10: # %bb.0: # %entry
2720 ; CHECK-P10-NEXT: pli r4, 244140625
2721 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
2722 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
2723 ; CHECK-P10-NEXT: lfdx f0, r3, r4
2724 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
2725 ; CHECK-P10-NEXT: blr
2727 ; CHECK-PREP10-LABEL: ld_disjoint_align64_float_uint64_t:
2728 ; CHECK-PREP10: # %bb.0: # %entry
2729 ; CHECK-PREP10-NEXT: lis r4, 3725
2730 ; CHECK-PREP10-NEXT: rldicr r3, r3, 0, 23
2731 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
2732 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
2733 ; CHECK-PREP10-NEXT: lfdx f0, r3, r4
2734 ; CHECK-PREP10-NEXT: xscvuxdsp f1, f0
2735 ; CHECK-PREP10-NEXT: blr
2737 %and = and i64 %ptr, -1099511627776
2738 %or = or i64 %and, 1000000000000
2739 %0 = inttoptr i64 %or to i64*
2740 %1 = load i64, i64* %0, align 4096
2741 %conv = uitofp i64 %1 to float
2745 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2746 define dso_local float @ld_cst_align16_float_uint64_t() {
2747 ; CHECK-LABEL: ld_cst_align16_float_uint64_t:
2748 ; CHECK: # %bb.0: # %entry
2749 ; CHECK-NEXT: lfd f0, 4080(0)
2750 ; CHECK-NEXT: xscvuxdsp f1, f0
2753 %0 = load i64, i64* inttoptr (i64 4080 to i64*), align 16
2754 %conv = uitofp i64 %0 to float
2758 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2759 define dso_local float @ld_cst_align32_float_uint64_t() {
2760 ; CHECK-LABEL: ld_cst_align32_float_uint64_t:
2761 ; CHECK: # %bb.0: # %entry
2762 ; CHECK-NEXT: lis r3, 153
2763 ; CHECK-NEXT: lfd f0, -27108(r3)
2764 ; CHECK-NEXT: xscvuxdsp f1, f0
2767 %0 = load i64, i64* inttoptr (i64 9999900 to i64*), align 8
2768 %conv = uitofp i64 %0 to float
2772 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2773 define dso_local float @ld_cst_align64_float_uint64_t() {
2774 ; CHECK-P10-LABEL: ld_cst_align64_float_uint64_t:
2775 ; CHECK-P10: # %bb.0: # %entry
2776 ; CHECK-P10-NEXT: pli r3, 244140625
2777 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
2778 ; CHECK-P10-NEXT: lfd f0, 0(r3)
2779 ; CHECK-P10-NEXT: xscvuxdsp f1, f0
2780 ; CHECK-P10-NEXT: blr
2782 ; CHECK-PREP10-LABEL: ld_cst_align64_float_uint64_t:
2783 ; CHECK-PREP10: # %bb.0: # %entry
2784 ; CHECK-PREP10-NEXT: lis r3, 3725
2785 ; CHECK-PREP10-NEXT: ori r3, r3, 19025
2786 ; CHECK-PREP10-NEXT: rldic r3, r3, 12, 24
2787 ; CHECK-PREP10-NEXT: lfd f0, 0(r3)
2788 ; CHECK-PREP10-NEXT: xscvuxdsp f1, f0
2789 ; CHECK-PREP10-NEXT: blr
2791 %0 = load i64, i64* inttoptr (i64 1000000000000 to i64*), align 4096
2792 %conv = uitofp i64 %0 to float
2796 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2797 define dso_local float @ld_0_float_int64_t(i64 %ptr) {
2798 ; CHECK-LABEL: ld_0_float_int64_t:
2799 ; CHECK: # %bb.0: # %entry
2800 ; CHECK-NEXT: lfd f0, 0(r3)
2801 ; CHECK-NEXT: xscvsxdsp f1, f0
2804 %0 = inttoptr i64 %ptr to i64*
2805 %1 = load i64, i64* %0, align 8
2806 %conv = sitofp i64 %1 to float
2810 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2811 define dso_local float @ld_align16_float_int64_t(i8* nocapture readonly %ptr) {
2812 ; CHECK-LABEL: ld_align16_float_int64_t:
2813 ; CHECK: # %bb.0: # %entry
2814 ; CHECK-NEXT: lfd f0, 8(r3)
2815 ; CHECK-NEXT: xscvsxdsp f1, f0
2818 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
2819 %0 = bitcast i8* %add.ptr to i64*
2820 %1 = load i64, i64* %0, align 8
2821 %conv = sitofp i64 %1 to float
2825 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2826 define dso_local float @ld_align32_float_int64_t(i8* nocapture readonly %ptr) {
2827 ; CHECK-P10-LABEL: ld_align32_float_int64_t:
2828 ; CHECK-P10: # %bb.0: # %entry
2829 ; CHECK-P10-NEXT: pli r4, 99999000
2830 ; CHECK-P10-NEXT: lfdx f0, r3, r4
2831 ; CHECK-P10-NEXT: xscvsxdsp f1, f0
2832 ; CHECK-P10-NEXT: blr
2834 ; CHECK-PREP10-LABEL: ld_align32_float_int64_t:
2835 ; CHECK-PREP10: # %bb.0: # %entry
2836 ; CHECK-PREP10-NEXT: lis r4, 1525
2837 ; CHECK-PREP10-NEXT: ori r4, r4, 56600
2838 ; CHECK-PREP10-NEXT: lfdx f0, r3, r4
2839 ; CHECK-PREP10-NEXT: xscvsxdsp f1, f0
2840 ; CHECK-PREP10-NEXT: blr
2842 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
2843 %0 = bitcast i8* %add.ptr to i64*
2844 %1 = load i64, i64* %0, align 8
2845 %conv = sitofp i64 %1 to float
2849 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2850 define dso_local float @ld_align64_float_int64_t(i8* nocapture readonly %ptr) {
2851 ; CHECK-P10-LABEL: ld_align64_float_int64_t:
2852 ; CHECK-P10: # %bb.0: # %entry
2853 ; CHECK-P10-NEXT: pli r4, 244140625
2854 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
2855 ; CHECK-P10-NEXT: lfdx f0, r3, r4
2856 ; CHECK-P10-NEXT: xscvsxdsp f1, f0
2857 ; CHECK-P10-NEXT: blr
2859 ; CHECK-PREP10-LABEL: ld_align64_float_int64_t:
2860 ; CHECK-PREP10: # %bb.0: # %entry
2861 ; CHECK-PREP10-NEXT: lis r4, 3725
2862 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
2863 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
2864 ; CHECK-PREP10-NEXT: lfdx f0, r3, r4
2865 ; CHECK-PREP10-NEXT: xscvsxdsp f1, f0
2866 ; CHECK-PREP10-NEXT: blr
2868 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
2869 %0 = bitcast i8* %add.ptr to i64*
2870 %1 = load i64, i64* %0, align 8
2871 %conv = sitofp i64 %1 to float
2875 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2876 define dso_local float @ld_reg_float_int64_t(i8* nocapture readonly %ptr, i64 %off) {
2877 ; CHECK-LABEL: ld_reg_float_int64_t:
2878 ; CHECK: # %bb.0: # %entry
2879 ; CHECK-NEXT: lfdx f0, r3, r4
2880 ; CHECK-NEXT: xscvsxdsp f1, f0
2883 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
2884 %0 = bitcast i8* %add.ptr to i64*
2885 %1 = load i64, i64* %0, align 8
2886 %conv = sitofp i64 %1 to float
2890 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2891 define dso_local float @ld_or_float_int64_t(i64 %ptr, i8 zeroext %off) {
2892 ; CHECK-LABEL: ld_or_float_int64_t:
2893 ; CHECK: # %bb.0: # %entry
2894 ; CHECK-NEXT: or r3, r4, r3
2895 ; CHECK-NEXT: lfd f0, 0(r3)
2896 ; CHECK-NEXT: xscvsxdsp f1, f0
2899 %conv = zext i8 %off to i64
2900 %or = or i64 %conv, %ptr
2901 %0 = inttoptr i64 %or to i64*
2902 %1 = load i64, i64* %0, align 8
2903 %conv1 = sitofp i64 %1 to float
2907 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2908 define dso_local float @ld_not_disjoint16_float_int64_t(i64 %ptr) {
2909 ; CHECK-LABEL: ld_not_disjoint16_float_int64_t:
2910 ; CHECK: # %bb.0: # %entry
2911 ; CHECK-NEXT: ori r3, r3, 6
2912 ; CHECK-NEXT: lfd f0, 0(r3)
2913 ; CHECK-NEXT: xscvsxdsp f1, f0
2916 %or = or i64 %ptr, 6
2917 %0 = inttoptr i64 %or to i64*
2918 %1 = load i64, i64* %0, align 8
2919 %conv = sitofp i64 %1 to float
2923 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2924 define dso_local float @ld_disjoint_align16_float_int64_t(i64 %ptr) {
2925 ; CHECK-LABEL: ld_disjoint_align16_float_int64_t:
2926 ; CHECK: # %bb.0: # %entry
2927 ; CHECK-NEXT: rldicr r3, r3, 0, 51
2928 ; CHECK-NEXT: lfd f0, 24(r3)
2929 ; CHECK-NEXT: xscvsxdsp f1, f0
2932 %and = and i64 %ptr, -4096
2933 %or = or i64 %and, 24
2934 %0 = inttoptr i64 %or to i64*
2935 %1 = load i64, i64* %0, align 8
2936 %conv = sitofp i64 %1 to float
2940 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2941 define dso_local float @ld_not_disjoint32_float_int64_t(i64 %ptr) {
2942 ; CHECK-LABEL: ld_not_disjoint32_float_int64_t:
2943 ; CHECK: # %bb.0: # %entry
2944 ; CHECK-NEXT: ori r3, r3, 34463
2945 ; CHECK-NEXT: oris r3, r3, 1
2946 ; CHECK-NEXT: lfd f0, 0(r3)
2947 ; CHECK-NEXT: xscvsxdsp f1, f0
2950 %or = or i64 %ptr, 99999
2951 %0 = inttoptr i64 %or to i64*
2952 %1 = load i64, i64* %0, align 8
2953 %conv = sitofp i64 %1 to float
2957 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2958 define dso_local float @ld_disjoint_align32_float_int64_t(i64 %ptr) {
2959 ; CHECK-P10-LABEL: ld_disjoint_align32_float_int64_t:
2960 ; CHECK-P10: # %bb.0: # %entry
2961 ; CHECK-P10-NEXT: lis r4, -15264
2962 ; CHECK-P10-NEXT: and r3, r3, r4
2963 ; CHECK-P10-NEXT: pli r4, 999990000
2964 ; CHECK-P10-NEXT: lfdx f0, r3, r4
2965 ; CHECK-P10-NEXT: xscvsxdsp f1, f0
2966 ; CHECK-P10-NEXT: blr
2968 ; CHECK-P9-LABEL: ld_disjoint_align32_float_int64_t:
2969 ; CHECK-P9: # %bb.0: # %entry
2970 ; CHECK-P9-NEXT: lis r4, -15264
2971 ; CHECK-P9-NEXT: and r3, r3, r4
2972 ; CHECK-P9-NEXT: lis r4, 15258
2973 ; CHECK-P9-NEXT: ori r4, r4, 41712
2974 ; CHECK-P9-NEXT: lfdx f0, r3, r4
2975 ; CHECK-P9-NEXT: xscvsxdsp f1, f0
2976 ; CHECK-P9-NEXT: blr
2978 ; CHECK-P8-LABEL: ld_disjoint_align32_float_int64_t:
2979 ; CHECK-P8: # %bb.0: # %entry
2980 ; CHECK-P8-NEXT: lis r4, -15264
2981 ; CHECK-P8-NEXT: lis r5, 15258
2982 ; CHECK-P8-NEXT: and r3, r3, r4
2983 ; CHECK-P8-NEXT: ori r4, r5, 41712
2984 ; CHECK-P8-NEXT: lfdx f0, r3, r4
2985 ; CHECK-P8-NEXT: xscvsxdsp f1, f0
2986 ; CHECK-P8-NEXT: blr
2988 %and = and i64 %ptr, -1000341504
2989 %or = or i64 %and, 999990000
2990 %0 = inttoptr i64 %or to i64*
2991 %1 = load i64, i64* %0, align 16
2992 %conv = sitofp i64 %1 to float
2996 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
2997 define dso_local float @ld_not_disjoint64_float_int64_t(i64 %ptr) {
2998 ; CHECK-P10-LABEL: ld_not_disjoint64_float_int64_t:
2999 ; CHECK-P10: # %bb.0: # %entry
3000 ; CHECK-P10-NEXT: pli r4, 232
3001 ; CHECK-P10-NEXT: pli r5, 3567587329
3002 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
3003 ; CHECK-P10-NEXT: or r3, r3, r5
3004 ; CHECK-P10-NEXT: lfd f0, 0(r3)
3005 ; CHECK-P10-NEXT: xscvsxdsp f1, f0
3006 ; CHECK-P10-NEXT: blr
3008 ; CHECK-PREP10-LABEL: ld_not_disjoint64_float_int64_t:
3009 ; CHECK-PREP10: # %bb.0: # %entry
3010 ; CHECK-PREP10-NEXT: li r4, 29
3011 ; CHECK-PREP10-NEXT: rldic r4, r4, 35, 24
3012 ; CHECK-PREP10-NEXT: oris r4, r4, 54437
3013 ; CHECK-PREP10-NEXT: ori r4, r4, 4097
3014 ; CHECK-PREP10-NEXT: or r3, r3, r4
3015 ; CHECK-PREP10-NEXT: lfd f0, 0(r3)
3016 ; CHECK-PREP10-NEXT: xscvsxdsp f1, f0
3017 ; CHECK-PREP10-NEXT: blr
3019 %or = or i64 %ptr, 1000000000001
3020 %0 = inttoptr i64 %or to i64*
3021 %1 = load i64, i64* %0, align 8
3022 %conv = sitofp i64 %1 to float
3026 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3027 define dso_local float @ld_disjoint_align64_float_int64_t(i64 %ptr) {
3028 ; CHECK-P10-LABEL: ld_disjoint_align64_float_int64_t:
3029 ; CHECK-P10: # %bb.0: # %entry
3030 ; CHECK-P10-NEXT: pli r4, 244140625
3031 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
3032 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
3033 ; CHECK-P10-NEXT: lfdx f0, r3, r4
3034 ; CHECK-P10-NEXT: xscvsxdsp f1, f0
3035 ; CHECK-P10-NEXT: blr
3037 ; CHECK-PREP10-LABEL: ld_disjoint_align64_float_int64_t:
3038 ; CHECK-PREP10: # %bb.0: # %entry
3039 ; CHECK-PREP10-NEXT: lis r4, 3725
3040 ; CHECK-PREP10-NEXT: rldicr r3, r3, 0, 23
3041 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
3042 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
3043 ; CHECK-PREP10-NEXT: lfdx f0, r3, r4
3044 ; CHECK-PREP10-NEXT: xscvsxdsp f1, f0
3045 ; CHECK-PREP10-NEXT: blr
3047 %and = and i64 %ptr, -1099511627776
3048 %or = or i64 %and, 1000000000000
3049 %0 = inttoptr i64 %or to i64*
3050 %1 = load i64, i64* %0, align 4096
3051 %conv = sitofp i64 %1 to float
3055 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3056 define dso_local float @ld_cst_align16_float_int64_t() {
3057 ; CHECK-LABEL: ld_cst_align16_float_int64_t:
3058 ; CHECK: # %bb.0: # %entry
3059 ; CHECK-NEXT: lfd f0, 4080(0)
3060 ; CHECK-NEXT: xscvsxdsp f1, f0
3063 %0 = load i64, i64* inttoptr (i64 4080 to i64*), align 16
3064 %conv = sitofp i64 %0 to float
3068 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3069 define dso_local float @ld_cst_align32_float_int64_t() {
3070 ; CHECK-LABEL: ld_cst_align32_float_int64_t:
3071 ; CHECK: # %bb.0: # %entry
3072 ; CHECK-NEXT: lis r3, 153
3073 ; CHECK-NEXT: lfd f0, -27108(r3)
3074 ; CHECK-NEXT: xscvsxdsp f1, f0
3077 %0 = load i64, i64* inttoptr (i64 9999900 to i64*), align 8
3078 %conv = sitofp i64 %0 to float
3082 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3083 define dso_local float @ld_cst_align64_float_int64_t() {
3084 ; CHECK-P10-LABEL: ld_cst_align64_float_int64_t:
3085 ; CHECK-P10: # %bb.0: # %entry
3086 ; CHECK-P10-NEXT: pli r3, 244140625
3087 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
3088 ; CHECK-P10-NEXT: lfd f0, 0(r3)
3089 ; CHECK-P10-NEXT: xscvsxdsp f1, f0
3090 ; CHECK-P10-NEXT: blr
3092 ; CHECK-PREP10-LABEL: ld_cst_align64_float_int64_t:
3093 ; CHECK-PREP10: # %bb.0: # %entry
3094 ; CHECK-PREP10-NEXT: lis r3, 3725
3095 ; CHECK-PREP10-NEXT: ori r3, r3, 19025
3096 ; CHECK-PREP10-NEXT: rldic r3, r3, 12, 24
3097 ; CHECK-PREP10-NEXT: lfd f0, 0(r3)
3098 ; CHECK-PREP10-NEXT: xscvsxdsp f1, f0
3099 ; CHECK-PREP10-NEXT: blr
3101 %0 = load i64, i64* inttoptr (i64 1000000000000 to i64*), align 4096
3102 %conv = sitofp i64 %0 to float
3106 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3107 define dso_local float @ld_0_float_float(i64 %ptr) {
3108 ; CHECK-LABEL: ld_0_float_float:
3109 ; CHECK: # %bb.0: # %entry
3110 ; CHECK-NEXT: lfs f1, 0(r3)
3113 %0 = inttoptr i64 %ptr to float*
3114 %1 = load float, float* %0, align 4
3118 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3119 define dso_local float @ld_align16_float_float(i8* nocapture readonly %ptr) {
3120 ; CHECK-LABEL: ld_align16_float_float:
3121 ; CHECK: # %bb.0: # %entry
3122 ; CHECK-NEXT: lfs f1, 8(r3)
3125 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
3126 %0 = bitcast i8* %add.ptr to float*
3127 %1 = load float, float* %0, align 4
3131 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3132 define dso_local float @ld_align32_float_float(i8* nocapture readonly %ptr) {
3133 ; CHECK-P10-LABEL: ld_align32_float_float:
3134 ; CHECK-P10: # %bb.0: # %entry
3135 ; CHECK-P10-NEXT: pli r4, 99999000
3136 ; CHECK-P10-NEXT: lfsx f1, r3, r4
3137 ; CHECK-P10-NEXT: blr
3139 ; CHECK-PREP10-LABEL: ld_align32_float_float:
3140 ; CHECK-PREP10: # %bb.0: # %entry
3141 ; CHECK-PREP10-NEXT: lis r4, 1525
3142 ; CHECK-PREP10-NEXT: ori r4, r4, 56600
3143 ; CHECK-PREP10-NEXT: lfsx f1, r3, r4
3144 ; CHECK-PREP10-NEXT: blr
3146 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
3147 %0 = bitcast i8* %add.ptr to float*
3148 %1 = load float, float* %0, align 4
3152 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3153 define dso_local float @ld_align64_float_float(i8* nocapture readonly %ptr) {
3154 ; CHECK-P10-LABEL: ld_align64_float_float:
3155 ; CHECK-P10: # %bb.0: # %entry
3156 ; CHECK-P10-NEXT: pli r4, 244140625
3157 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
3158 ; CHECK-P10-NEXT: lfsx f1, r3, r4
3159 ; CHECK-P10-NEXT: blr
3161 ; CHECK-PREP10-LABEL: ld_align64_float_float:
3162 ; CHECK-PREP10: # %bb.0: # %entry
3163 ; CHECK-PREP10-NEXT: lis r4, 3725
3164 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
3165 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
3166 ; CHECK-PREP10-NEXT: lfsx f1, r3, r4
3167 ; CHECK-PREP10-NEXT: blr
3169 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
3170 %0 = bitcast i8* %add.ptr to float*
3171 %1 = load float, float* %0, align 4
3175 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3176 define dso_local float @ld_reg_float_float(i8* nocapture readonly %ptr, i64 %off) {
3177 ; CHECK-LABEL: ld_reg_float_float:
3178 ; CHECK: # %bb.0: # %entry
3179 ; CHECK-NEXT: lfsx f1, r3, r4
3182 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
3183 %0 = bitcast i8* %add.ptr to float*
3184 %1 = load float, float* %0, align 4
3188 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3189 define dso_local float @ld_or_float_float(i64 %ptr, i8 zeroext %off) {
3190 ; CHECK-LABEL: ld_or_float_float:
3191 ; CHECK: # %bb.0: # %entry
3192 ; CHECK-NEXT: or r3, r4, r3
3193 ; CHECK-NEXT: lfs f1, 0(r3)
3196 %conv = zext i8 %off to i64
3197 %or = or i64 %conv, %ptr
3198 %0 = inttoptr i64 %or to float*
3199 %1 = load float, float* %0, align 4
3203 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3204 define dso_local float @ld_not_disjoint16_float_float(i64 %ptr) {
3205 ; CHECK-LABEL: ld_not_disjoint16_float_float:
3206 ; CHECK: # %bb.0: # %entry
3207 ; CHECK-NEXT: ori r3, r3, 6
3208 ; CHECK-NEXT: lfs f1, 0(r3)
3211 %or = or i64 %ptr, 6
3212 %0 = inttoptr i64 %or to float*
3213 %1 = load float, float* %0, align 4
3217 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3218 define dso_local float @ld_disjoint_align16_float_float(i64 %ptr) {
3219 ; CHECK-LABEL: ld_disjoint_align16_float_float:
3220 ; CHECK: # %bb.0: # %entry
3221 ; CHECK-NEXT: rldicr r3, r3, 0, 51
3222 ; CHECK-NEXT: lfs f1, 24(r3)
3225 %and = and i64 %ptr, -4096
3226 %or = or i64 %and, 24
3227 %0 = inttoptr i64 %or to float*
3228 %1 = load float, float* %0, align 8
3232 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3233 define dso_local float @ld_not_disjoint32_float_float(i64 %ptr) {
3234 ; CHECK-LABEL: ld_not_disjoint32_float_float:
3235 ; CHECK: # %bb.0: # %entry
3236 ; CHECK-NEXT: ori r3, r3, 34463
3237 ; CHECK-NEXT: oris r3, r3, 1
3238 ; CHECK-NEXT: lfs f1, 0(r3)
3241 %or = or i64 %ptr, 99999
3242 %0 = inttoptr i64 %or to float*
3243 %1 = load float, float* %0, align 4
3247 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3248 define dso_local float @ld_disjoint_align32_float_float(i64 %ptr) {
3249 ; CHECK-P10-LABEL: ld_disjoint_align32_float_float:
3250 ; CHECK-P10: # %bb.0: # %entry
3251 ; CHECK-P10-NEXT: lis r4, -15264
3252 ; CHECK-P10-NEXT: and r3, r3, r4
3253 ; CHECK-P10-NEXT: pli r4, 999990000
3254 ; CHECK-P10-NEXT: lfsx f1, r3, r4
3255 ; CHECK-P10-NEXT: blr
3257 ; CHECK-P9-LABEL: ld_disjoint_align32_float_float:
3258 ; CHECK-P9: # %bb.0: # %entry
3259 ; CHECK-P9-NEXT: lis r4, -15264
3260 ; CHECK-P9-NEXT: and r3, r3, r4
3261 ; CHECK-P9-NEXT: lis r4, 15258
3262 ; CHECK-P9-NEXT: ori r4, r4, 41712
3263 ; CHECK-P9-NEXT: lfsx f1, r3, r4
3264 ; CHECK-P9-NEXT: blr
3266 ; CHECK-P8-LABEL: ld_disjoint_align32_float_float:
3267 ; CHECK-P8: # %bb.0: # %entry
3268 ; CHECK-P8-NEXT: lis r4, -15264
3269 ; CHECK-P8-NEXT: lis r5, 15258
3270 ; CHECK-P8-NEXT: and r3, r3, r4
3271 ; CHECK-P8-NEXT: ori r4, r5, 41712
3272 ; CHECK-P8-NEXT: lfsx f1, r3, r4
3273 ; CHECK-P8-NEXT: blr
3275 %and = and i64 %ptr, -1000341504
3276 %or = or i64 %and, 999990000
3277 %0 = inttoptr i64 %or to float*
3278 %1 = load float, float* %0, align 16
3282 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3283 define dso_local float @ld_not_disjoint64_float_float(i64 %ptr) {
3284 ; CHECK-P10-LABEL: ld_not_disjoint64_float_float:
3285 ; CHECK-P10: # %bb.0: # %entry
3286 ; CHECK-P10-NEXT: pli r4, 232
3287 ; CHECK-P10-NEXT: pli r5, 3567587329
3288 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
3289 ; CHECK-P10-NEXT: or r3, r3, r5
3290 ; CHECK-P10-NEXT: lfs f1, 0(r3)
3291 ; CHECK-P10-NEXT: blr
3293 ; CHECK-PREP10-LABEL: ld_not_disjoint64_float_float:
3294 ; CHECK-PREP10: # %bb.0: # %entry
3295 ; CHECK-PREP10-NEXT: li r4, 29
3296 ; CHECK-PREP10-NEXT: rldic r4, r4, 35, 24
3297 ; CHECK-PREP10-NEXT: oris r4, r4, 54437
3298 ; CHECK-PREP10-NEXT: ori r4, r4, 4097
3299 ; CHECK-PREP10-NEXT: or r3, r3, r4
3300 ; CHECK-PREP10-NEXT: lfs f1, 0(r3)
3301 ; CHECK-PREP10-NEXT: blr
3303 %or = or i64 %ptr, 1000000000001
3304 %0 = inttoptr i64 %or to float*
3305 %1 = load float, float* %0, align 4
3309 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3310 define dso_local float @ld_disjoint_align64_float_float(i64 %ptr) {
3311 ; CHECK-P10-LABEL: ld_disjoint_align64_float_float:
3312 ; CHECK-P10: # %bb.0: # %entry
3313 ; CHECK-P10-NEXT: pli r4, 244140625
3314 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
3315 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
3316 ; CHECK-P10-NEXT: lfsx f1, r3, r4
3317 ; CHECK-P10-NEXT: blr
3319 ; CHECK-PREP10-LABEL: ld_disjoint_align64_float_float:
3320 ; CHECK-PREP10: # %bb.0: # %entry
3321 ; CHECK-PREP10-NEXT: lis r4, 3725
3322 ; CHECK-PREP10-NEXT: rldicr r3, r3, 0, 23
3323 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
3324 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
3325 ; CHECK-PREP10-NEXT: lfsx f1, r3, r4
3326 ; CHECK-PREP10-NEXT: blr
3328 %and = and i64 %ptr, -1099511627776
3329 %or = or i64 %and, 1000000000000
3330 %0 = inttoptr i64 %or to float*
3331 %1 = load float, float* %0, align 4096
3335 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3336 define dso_local float @ld_cst_align16_float_float() {
3337 ; CHECK-LABEL: ld_cst_align16_float_float:
3338 ; CHECK: # %bb.0: # %entry
3339 ; CHECK-NEXT: lfs f1, 4080(0)
3342 %0 = load float, float* inttoptr (i64 4080 to float*), align 16
3346 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3347 define dso_local float @ld_cst_align32_float_float() {
3348 ; CHECK-LABEL: ld_cst_align32_float_float:
3349 ; CHECK: # %bb.0: # %entry
3350 ; CHECK-NEXT: lis r3, 153
3351 ; CHECK-NEXT: lfs f1, -27108(r3)
3354 %0 = load float, float* inttoptr (i64 9999900 to float*), align 4
3358 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3359 define dso_local float @ld_cst_align64_float_float() {
3360 ; CHECK-P10-LABEL: ld_cst_align64_float_float:
3361 ; CHECK-P10: # %bb.0: # %entry
3362 ; CHECK-P10-NEXT: pli r3, 244140625
3363 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
3364 ; CHECK-P10-NEXT: lfs f1, 0(r3)
3365 ; CHECK-P10-NEXT: blr
3367 ; CHECK-PREP10-LABEL: ld_cst_align64_float_float:
3368 ; CHECK-PREP10: # %bb.0: # %entry
3369 ; CHECK-PREP10-NEXT: lis r3, 3725
3370 ; CHECK-PREP10-NEXT: ori r3, r3, 19025
3371 ; CHECK-PREP10-NEXT: rldic r3, r3, 12, 24
3372 ; CHECK-PREP10-NEXT: lfs f1, 0(r3)
3373 ; CHECK-PREP10-NEXT: blr
3375 %0 = load float, float* inttoptr (i64 1000000000000 to float*), align 4096
3379 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3380 define dso_local float @ld_0_float_double(i64 %ptr) {
3381 ; CHECK-LABEL: ld_0_float_double:
3382 ; CHECK: # %bb.0: # %entry
3383 ; CHECK-NEXT: lfd f0, 0(r3)
3384 ; CHECK-NEXT: xsrsp f1, f0
3387 %0 = inttoptr i64 %ptr to double*
3388 %1 = load double, double* %0, align 8
3389 %conv = fptrunc double %1 to float
3393 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3394 define dso_local float @ld_align16_float_double(i8* nocapture readonly %ptr) {
3395 ; CHECK-LABEL: ld_align16_float_double:
3396 ; CHECK: # %bb.0: # %entry
3397 ; CHECK-NEXT: lfd f0, 8(r3)
3398 ; CHECK-NEXT: xsrsp f1, f0
3401 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
3402 %0 = bitcast i8* %add.ptr to double*
3403 %1 = load double, double* %0, align 8
3404 %conv = fptrunc double %1 to float
3408 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3409 define dso_local float @ld_align32_float_double(i8* nocapture readonly %ptr) {
3410 ; CHECK-P10-LABEL: ld_align32_float_double:
3411 ; CHECK-P10: # %bb.0: # %entry
3412 ; CHECK-P10-NEXT: pli r4, 99999000
3413 ; CHECK-P10-NEXT: lfdx f0, r3, r4
3414 ; CHECK-P10-NEXT: xsrsp f1, f0
3415 ; CHECK-P10-NEXT: blr
3417 ; CHECK-PREP10-LABEL: ld_align32_float_double:
3418 ; CHECK-PREP10: # %bb.0: # %entry
3419 ; CHECK-PREP10-NEXT: lis r4, 1525
3420 ; CHECK-PREP10-NEXT: ori r4, r4, 56600
3421 ; CHECK-PREP10-NEXT: lfdx f0, r3, r4
3422 ; CHECK-PREP10-NEXT: xsrsp f1, f0
3423 ; CHECK-PREP10-NEXT: blr
3425 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
3426 %0 = bitcast i8* %add.ptr to double*
3427 %1 = load double, double* %0, align 8
3428 %conv = fptrunc double %1 to float
3432 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3433 define dso_local float @ld_align64_float_double(i8* nocapture readonly %ptr) {
3434 ; CHECK-P10-LABEL: ld_align64_float_double:
3435 ; CHECK-P10: # %bb.0: # %entry
3436 ; CHECK-P10-NEXT: pli r4, 244140625
3437 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
3438 ; CHECK-P10-NEXT: lfdx f0, r3, r4
3439 ; CHECK-P10-NEXT: xsrsp f1, f0
3440 ; CHECK-P10-NEXT: blr
3442 ; CHECK-PREP10-LABEL: ld_align64_float_double:
3443 ; CHECK-PREP10: # %bb.0: # %entry
3444 ; CHECK-PREP10-NEXT: lis r4, 3725
3445 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
3446 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
3447 ; CHECK-PREP10-NEXT: lfdx f0, r3, r4
3448 ; CHECK-PREP10-NEXT: xsrsp f1, f0
3449 ; CHECK-PREP10-NEXT: blr
3451 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
3452 %0 = bitcast i8* %add.ptr to double*
3453 %1 = load double, double* %0, align 8
3454 %conv = fptrunc double %1 to float
3458 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3459 define dso_local float @ld_reg_float_double(i8* nocapture readonly %ptr, i64 %off) {
3460 ; CHECK-LABEL: ld_reg_float_double:
3461 ; CHECK: # %bb.0: # %entry
3462 ; CHECK-NEXT: lfdx f0, r3, r4
3463 ; CHECK-NEXT: xsrsp f1, f0
3466 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
3467 %0 = bitcast i8* %add.ptr to double*
3468 %1 = load double, double* %0, align 8
3469 %conv = fptrunc double %1 to float
3473 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3474 define dso_local float @ld_or_float_double(i64 %ptr, i8 zeroext %off) {
3475 ; CHECK-LABEL: ld_or_float_double:
3476 ; CHECK: # %bb.0: # %entry
3477 ; CHECK-NEXT: or r3, r4, r3
3478 ; CHECK-NEXT: lfd f0, 0(r3)
3479 ; CHECK-NEXT: xsrsp f1, f0
3482 %conv = zext i8 %off to i64
3483 %or = or i64 %conv, %ptr
3484 %0 = inttoptr i64 %or to double*
3485 %1 = load double, double* %0, align 8
3486 %conv1 = fptrunc double %1 to float
3490 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3491 define dso_local float @ld_not_disjoint16_float_double(i64 %ptr) {
3492 ; CHECK-LABEL: ld_not_disjoint16_float_double:
3493 ; CHECK: # %bb.0: # %entry
3494 ; CHECK-NEXT: ori r3, r3, 6
3495 ; CHECK-NEXT: lfd f0, 0(r3)
3496 ; CHECK-NEXT: xsrsp f1, f0
3499 %or = or i64 %ptr, 6
3500 %0 = inttoptr i64 %or to double*
3501 %1 = load double, double* %0, align 8
3502 %conv = fptrunc double %1 to float
3506 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3507 define dso_local float @ld_disjoint_align16_float_double(i64 %ptr) {
3508 ; CHECK-LABEL: ld_disjoint_align16_float_double:
3509 ; CHECK: # %bb.0: # %entry
3510 ; CHECK-NEXT: rldicr r3, r3, 0, 51
3511 ; CHECK-NEXT: lfd f0, 24(r3)
3512 ; CHECK-NEXT: xsrsp f1, f0
3515 %and = and i64 %ptr, -4096
3516 %or = or i64 %and, 24
3517 %0 = inttoptr i64 %or to double*
3518 %1 = load double, double* %0, align 8
3519 %conv = fptrunc double %1 to float
3523 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3524 define dso_local float @ld_not_disjoint32_float_double(i64 %ptr) {
3525 ; CHECK-LABEL: ld_not_disjoint32_float_double:
3526 ; CHECK: # %bb.0: # %entry
3527 ; CHECK-NEXT: ori r3, r3, 34463
3528 ; CHECK-NEXT: oris r3, r3, 1
3529 ; CHECK-NEXT: lfd f0, 0(r3)
3530 ; CHECK-NEXT: xsrsp f1, f0
3533 %or = or i64 %ptr, 99999
3534 %0 = inttoptr i64 %or to double*
3535 %1 = load double, double* %0, align 8
3536 %conv = fptrunc double %1 to float
3540 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3541 define dso_local float @ld_disjoint_align32_float_double(i64 %ptr) {
3542 ; CHECK-P10-LABEL: ld_disjoint_align32_float_double:
3543 ; CHECK-P10: # %bb.0: # %entry
3544 ; CHECK-P10-NEXT: lis r4, -15264
3545 ; CHECK-P10-NEXT: and r3, r3, r4
3546 ; CHECK-P10-NEXT: pli r4, 999990000
3547 ; CHECK-P10-NEXT: lfdx f0, r3, r4
3548 ; CHECK-P10-NEXT: xsrsp f1, f0
3549 ; CHECK-P10-NEXT: blr
3551 ; CHECK-P9-LABEL: ld_disjoint_align32_float_double:
3552 ; CHECK-P9: # %bb.0: # %entry
3553 ; CHECK-P9-NEXT: lis r4, -15264
3554 ; CHECK-P9-NEXT: and r3, r3, r4
3555 ; CHECK-P9-NEXT: lis r4, 15258
3556 ; CHECK-P9-NEXT: ori r4, r4, 41712
3557 ; CHECK-P9-NEXT: lfdx f0, r3, r4
3558 ; CHECK-P9-NEXT: xsrsp f1, f0
3559 ; CHECK-P9-NEXT: blr
3561 ; CHECK-P8-LABEL: ld_disjoint_align32_float_double:
3562 ; CHECK-P8: # %bb.0: # %entry
3563 ; CHECK-P8-NEXT: lis r4, -15264
3564 ; CHECK-P8-NEXT: lis r5, 15258
3565 ; CHECK-P8-NEXT: and r3, r3, r4
3566 ; CHECK-P8-NEXT: ori r4, r5, 41712
3567 ; CHECK-P8-NEXT: lfdx f0, r3, r4
3568 ; CHECK-P8-NEXT: xsrsp f1, f0
3569 ; CHECK-P8-NEXT: blr
3571 %and = and i64 %ptr, -1000341504
3572 %or = or i64 %and, 999990000
3573 %0 = inttoptr i64 %or to double*
3574 %1 = load double, double* %0, align 16
3575 %conv = fptrunc double %1 to float
3579 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3580 define dso_local float @ld_not_disjoint64_float_double(i64 %ptr) {
3581 ; CHECK-P10-LABEL: ld_not_disjoint64_float_double:
3582 ; CHECK-P10: # %bb.0: # %entry
3583 ; CHECK-P10-NEXT: pli r4, 232
3584 ; CHECK-P10-NEXT: pli r5, 3567587329
3585 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
3586 ; CHECK-P10-NEXT: or r3, r3, r5
3587 ; CHECK-P10-NEXT: lfd f0, 0(r3)
3588 ; CHECK-P10-NEXT: xsrsp f1, f0
3589 ; CHECK-P10-NEXT: blr
3591 ; CHECK-PREP10-LABEL: ld_not_disjoint64_float_double:
3592 ; CHECK-PREP10: # %bb.0: # %entry
3593 ; CHECK-PREP10-NEXT: li r4, 29
3594 ; CHECK-PREP10-NEXT: rldic r4, r4, 35, 24
3595 ; CHECK-PREP10-NEXT: oris r4, r4, 54437
3596 ; CHECK-PREP10-NEXT: ori r4, r4, 4097
3597 ; CHECK-PREP10-NEXT: or r3, r3, r4
3598 ; CHECK-PREP10-NEXT: lfd f0, 0(r3)
3599 ; CHECK-PREP10-NEXT: xsrsp f1, f0
3600 ; CHECK-PREP10-NEXT: blr
3602 %or = or i64 %ptr, 1000000000001
3603 %0 = inttoptr i64 %or to double*
3604 %1 = load double, double* %0, align 8
3605 %conv = fptrunc double %1 to float
3609 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3610 define dso_local float @ld_disjoint_align64_float_double(i64 %ptr) {
3611 ; CHECK-P10-LABEL: ld_disjoint_align64_float_double:
3612 ; CHECK-P10: # %bb.0: # %entry
3613 ; CHECK-P10-NEXT: pli r4, 244140625
3614 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
3615 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
3616 ; CHECK-P10-NEXT: lfdx f0, r3, r4
3617 ; CHECK-P10-NEXT: xsrsp f1, f0
3618 ; CHECK-P10-NEXT: blr
3620 ; CHECK-PREP10-LABEL: ld_disjoint_align64_float_double:
3621 ; CHECK-PREP10: # %bb.0: # %entry
3622 ; CHECK-PREP10-NEXT: lis r4, 3725
3623 ; CHECK-PREP10-NEXT: rldicr r3, r3, 0, 23
3624 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
3625 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
3626 ; CHECK-PREP10-NEXT: lfdx f0, r3, r4
3627 ; CHECK-PREP10-NEXT: xsrsp f1, f0
3628 ; CHECK-PREP10-NEXT: blr
3630 %and = and i64 %ptr, -1099511627776
3631 %or = or i64 %and, 1000000000000
3632 %0 = inttoptr i64 %or to double*
3633 %1 = load double, double* %0, align 4096
3634 %conv = fptrunc double %1 to float
3638 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3639 define dso_local float @ld_cst_align16_float_double() {
3640 ; CHECK-LABEL: ld_cst_align16_float_double:
3641 ; CHECK: # %bb.0: # %entry
3642 ; CHECK-NEXT: lfd f0, 4080(0)
3643 ; CHECK-NEXT: xsrsp f1, f0
3646 %0 = load double, double* inttoptr (i64 4080 to double*), align 16
3647 %conv = fptrunc double %0 to float
3651 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3652 define dso_local float @ld_cst_align32_float_double() {
3653 ; CHECK-LABEL: ld_cst_align32_float_double:
3654 ; CHECK: # %bb.0: # %entry
3655 ; CHECK-NEXT: lis r3, 153
3656 ; CHECK-NEXT: lfd f0, -27108(r3)
3657 ; CHECK-NEXT: xsrsp f1, f0
3660 %0 = load double, double* inttoptr (i64 9999900 to double*), align 8
3661 %conv = fptrunc double %0 to float
3665 ; Function Attrs: norecurse nounwind readonly uwtable willreturn
3666 define dso_local float @ld_cst_align64_float_double() {
3667 ; CHECK-P10-LABEL: ld_cst_align64_float_double:
3668 ; CHECK-P10: # %bb.0: # %entry
3669 ; CHECK-P10-NEXT: pli r3, 244140625
3670 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
3671 ; CHECK-P10-NEXT: lfd f0, 0(r3)
3672 ; CHECK-P10-NEXT: xsrsp f1, f0
3673 ; CHECK-P10-NEXT: blr
3675 ; CHECK-PREP10-LABEL: ld_cst_align64_float_double:
3676 ; CHECK-PREP10: # %bb.0: # %entry
3677 ; CHECK-PREP10-NEXT: lis r3, 3725
3678 ; CHECK-PREP10-NEXT: ori r3, r3, 19025
3679 ; CHECK-PREP10-NEXT: rldic r3, r3, 12, 24
3680 ; CHECK-PREP10-NEXT: lfd f0, 0(r3)
3681 ; CHECK-PREP10-NEXT: xsrsp f1, f0
3682 ; CHECK-PREP10-NEXT: blr
3684 %0 = load double, double* inttoptr (i64 1000000000000 to double*), align 4096
3685 %conv = fptrunc double %0 to float
3689 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
3690 define dso_local void @st_0_float_uint8_t(i64 %ptr, float %str) {
3691 ; CHECK-POSTP8-LABEL: st_0_float_uint8_t:
3692 ; CHECK-POSTP8: # %bb.0: # %entry
3693 ; CHECK-POSTP8-NEXT: xscvdpuxws f0, f1
3694 ; CHECK-POSTP8-NEXT: stxsibx f0, 0, r3
3695 ; CHECK-POSTP8-NEXT: blr
3697 ; CHECK-P8-LABEL: st_0_float_uint8_t:
3698 ; CHECK-P8: # %bb.0: # %entry
3699 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
3700 ; CHECK-P8-NEXT: mffprwz r4, f0
3701 ; CHECK-P8-NEXT: stb r4, 0(r3)
3702 ; CHECK-P8-NEXT: blr
3704 %conv = fptoui float %str to i8
3705 %0 = inttoptr i64 %ptr to i8*
3706 store i8 %conv, i8* %0, align 1
3710 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
3711 define dso_local void @st_align16_float_uint8_t(i8* nocapture %ptr, float %str) {
3712 ; CHECK-POSTP8-LABEL: st_align16_float_uint8_t:
3713 ; CHECK-POSTP8: # %bb.0: # %entry
3714 ; CHECK-POSTP8-NEXT: xscvdpuxws f0, f1
3715 ; CHECK-POSTP8-NEXT: addi r3, r3, 8
3716 ; CHECK-POSTP8-NEXT: stxsibx f0, 0, r3
3717 ; CHECK-POSTP8-NEXT: blr
3719 ; CHECK-P8-LABEL: st_align16_float_uint8_t:
3720 ; CHECK-P8: # %bb.0: # %entry
3721 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
3722 ; CHECK-P8-NEXT: mffprwz r4, f0
3723 ; CHECK-P8-NEXT: stb r4, 8(r3)
3724 ; CHECK-P8-NEXT: blr
3726 %conv = fptoui float %str to i8
3727 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
3728 store i8 %conv, i8* %add.ptr, align 1
3732 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
3733 define dso_local void @st_align32_float_uint8_t(i8* nocapture %ptr, float %str) {
3734 ; CHECK-P10-LABEL: st_align32_float_uint8_t:
3735 ; CHECK-P10: # %bb.0: # %entry
3736 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
3737 ; CHECK-P10-NEXT: pli r4, 99999000
3738 ; CHECK-P10-NEXT: stxsibx f0, r3, r4
3739 ; CHECK-P10-NEXT: blr
3741 ; CHECK-P9-LABEL: st_align32_float_uint8_t:
3742 ; CHECK-P9: # %bb.0: # %entry
3743 ; CHECK-P9-NEXT: xscvdpuxws f0, f1
3744 ; CHECK-P9-NEXT: lis r4, 1525
3745 ; CHECK-P9-NEXT: ori r4, r4, 56600
3746 ; CHECK-P9-NEXT: stxsibx f0, r3, r4
3747 ; CHECK-P9-NEXT: blr
3749 ; CHECK-P8-LABEL: st_align32_float_uint8_t:
3750 ; CHECK-P8: # %bb.0: # %entry
3751 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
3752 ; CHECK-P8-NEXT: lis r4, 1525
3753 ; CHECK-P8-NEXT: ori r4, r4, 56600
3754 ; CHECK-P8-NEXT: mffprwz r5, f0
3755 ; CHECK-P8-NEXT: stbx r5, r3, r4
3756 ; CHECK-P8-NEXT: blr
3758 %conv = fptoui float %str to i8
3759 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
3760 store i8 %conv, i8* %add.ptr, align 1
3764 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
3765 define dso_local void @st_align64_float_uint8_t(i8* nocapture %ptr, float %str) {
3766 ; CHECK-P10-LABEL: st_align64_float_uint8_t:
3767 ; CHECK-P10: # %bb.0: # %entry
3768 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
3769 ; CHECK-P10-NEXT: pli r4, 244140625
3770 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
3771 ; CHECK-P10-NEXT: stxsibx f0, r3, r4
3772 ; CHECK-P10-NEXT: blr
3774 ; CHECK-P9-LABEL: st_align64_float_uint8_t:
3775 ; CHECK-P9: # %bb.0: # %entry
3776 ; CHECK-P9-NEXT: xscvdpuxws f0, f1
3777 ; CHECK-P9-NEXT: lis r4, 3725
3778 ; CHECK-P9-NEXT: ori r4, r4, 19025
3779 ; CHECK-P9-NEXT: rldic r4, r4, 12, 24
3780 ; CHECK-P9-NEXT: stxsibx f0, r3, r4
3781 ; CHECK-P9-NEXT: blr
3783 ; CHECK-P8-LABEL: st_align64_float_uint8_t:
3784 ; CHECK-P8: # %bb.0: # %entry
3785 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
3786 ; CHECK-P8-NEXT: lis r4, 3725
3787 ; CHECK-P8-NEXT: ori r4, r4, 19025
3788 ; CHECK-P8-NEXT: rldic r4, r4, 12, 24
3789 ; CHECK-P8-NEXT: mffprwz r5, f0
3790 ; CHECK-P8-NEXT: stbx r5, r3, r4
3791 ; CHECK-P8-NEXT: blr
3793 %conv = fptoui float %str to i8
3794 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
3795 store i8 %conv, i8* %add.ptr, align 1
3799 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
3800 define dso_local void @st_reg_float_uint8_t(i8* nocapture %ptr, i64 %off, float %str) {
3801 ; CHECK-POSTP8-LABEL: st_reg_float_uint8_t:
3802 ; CHECK-POSTP8: # %bb.0: # %entry
3803 ; CHECK-POSTP8-NEXT: xscvdpuxws f0, f1
3804 ; CHECK-POSTP8-NEXT: stxsibx f0, r3, r4
3805 ; CHECK-POSTP8-NEXT: blr
3807 ; CHECK-P8-LABEL: st_reg_float_uint8_t:
3808 ; CHECK-P8: # %bb.0: # %entry
3809 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
3810 ; CHECK-P8-NEXT: mffprwz r5, f0
3811 ; CHECK-P8-NEXT: stbx r5, r3, r4
3812 ; CHECK-P8-NEXT: blr
3814 %conv = fptoui float %str to i8
3815 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
3816 store i8 %conv, i8* %add.ptr, align 1
3820 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
3821 define dso_local void @st_or1_float_uint8_t(i64 %ptr, i8 zeroext %off, float %str) {
3822 ; CHECK-POSTP8-LABEL: st_or1_float_uint8_t:
3823 ; CHECK-POSTP8: # %bb.0: # %entry
3824 ; CHECK-POSTP8-NEXT: xscvdpuxws f0, f1
3825 ; CHECK-POSTP8-NEXT: or r3, r4, r3
3826 ; CHECK-POSTP8-NEXT: stxsibx f0, 0, r3
3827 ; CHECK-POSTP8-NEXT: blr
3829 ; CHECK-P8-LABEL: st_or1_float_uint8_t:
3830 ; CHECK-P8: # %bb.0: # %entry
3831 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
3832 ; CHECK-P8-NEXT: or r3, r4, r3
3833 ; CHECK-P8-NEXT: mffprwz r5, f0
3834 ; CHECK-P8-NEXT: stb r5, 0(r3)
3835 ; CHECK-P8-NEXT: blr
3837 %conv = fptoui float %str to i8
3838 %conv1 = zext i8 %off to i64
3839 %or = or i64 %conv1, %ptr
3840 %0 = inttoptr i64 %or to i8*
3841 store i8 %conv, i8* %0, align 1
3845 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
3846 define dso_local void @st_not_disjoint16_float_uint8_t(i64 %ptr, float %str) {
3847 ; CHECK-POSTP8-LABEL: st_not_disjoint16_float_uint8_t:
3848 ; CHECK-POSTP8: # %bb.0: # %entry
3849 ; CHECK-POSTP8-NEXT: xscvdpuxws f0, f1
3850 ; CHECK-POSTP8-NEXT: ori r3, r3, 6
3851 ; CHECK-POSTP8-NEXT: stxsibx f0, 0, r3
3852 ; CHECK-POSTP8-NEXT: blr
3854 ; CHECK-P8-LABEL: st_not_disjoint16_float_uint8_t:
3855 ; CHECK-P8: # %bb.0: # %entry
3856 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
3857 ; CHECK-P8-NEXT: ori r3, r3, 6
3858 ; CHECK-P8-NEXT: mffprwz r4, f0
3859 ; CHECK-P8-NEXT: stb r4, 0(r3)
3860 ; CHECK-P8-NEXT: blr
3862 %conv = fptoui float %str to i8
3863 %or = or i64 %ptr, 6
3864 %0 = inttoptr i64 %or to i8*
3865 store i8 %conv, i8* %0, align 1
3869 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
3870 define dso_local void @st_disjoint_align16_float_uint8_t(i64 %ptr, float %str) {
3871 ; CHECK-POSTP8-LABEL: st_disjoint_align16_float_uint8_t:
3872 ; CHECK-POSTP8: # %bb.0: # %entry
3873 ; CHECK-POSTP8-NEXT: xscvdpuxws f0, f1
3874 ; CHECK-POSTP8-NEXT: rldicr r3, r3, 0, 51
3875 ; CHECK-POSTP8-NEXT: ori r3, r3, 24
3876 ; CHECK-POSTP8-NEXT: stxsibx f0, 0, r3
3877 ; CHECK-POSTP8-NEXT: blr
3879 ; CHECK-P8-LABEL: st_disjoint_align16_float_uint8_t:
3880 ; CHECK-P8: # %bb.0: # %entry
3881 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
3882 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 51
3883 ; CHECK-P8-NEXT: mffprwz r4, f0
3884 ; CHECK-P8-NEXT: stb r4, 24(r3)
3885 ; CHECK-P8-NEXT: blr
3887 %and = and i64 %ptr, -4096
3888 %conv = fptoui float %str to i8
3889 %or = or i64 %and, 24
3890 %0 = inttoptr i64 %or to i8*
3891 store i8 %conv, i8* %0, align 8
3895 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
3896 define dso_local void @st_not_disjoint32_float_uint8_t(i64 %ptr, float %str) {
3897 ; CHECK-POSTP8-LABEL: st_not_disjoint32_float_uint8_t:
3898 ; CHECK-POSTP8: # %bb.0: # %entry
3899 ; CHECK-POSTP8-NEXT: xscvdpuxws f0, f1
3900 ; CHECK-POSTP8-NEXT: ori r3, r3, 34463
3901 ; CHECK-POSTP8-NEXT: oris r3, r3, 1
3902 ; CHECK-POSTP8-NEXT: stxsibx f0, 0, r3
3903 ; CHECK-POSTP8-NEXT: blr
3905 ; CHECK-P8-LABEL: st_not_disjoint32_float_uint8_t:
3906 ; CHECK-P8: # %bb.0: # %entry
3907 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
3908 ; CHECK-P8-NEXT: ori r3, r3, 34463
3909 ; CHECK-P8-NEXT: oris r3, r3, 1
3910 ; CHECK-P8-NEXT: mffprwz r4, f0
3911 ; CHECK-P8-NEXT: stb r4, 0(r3)
3912 ; CHECK-P8-NEXT: blr
3914 %conv = fptoui float %str to i8
3915 %or = or i64 %ptr, 99999
3916 %0 = inttoptr i64 %or to i8*
3917 store i8 %conv, i8* %0, align 1
3921 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
3922 define dso_local void @st_disjoint_align32_float_uint8_t(i64 %ptr, float %str) {
3923 ; CHECK-P10-LABEL: st_disjoint_align32_float_uint8_t:
3924 ; CHECK-P10: # %bb.0: # %entry
3925 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
3926 ; CHECK-P10-NEXT: lis r4, -15264
3927 ; CHECK-P10-NEXT: and r3, r3, r4
3928 ; CHECK-P10-NEXT: pli r4, 999990000
3929 ; CHECK-P10-NEXT: stxsibx f0, r3, r4
3930 ; CHECK-P10-NEXT: blr
3932 ; CHECK-P9-LABEL: st_disjoint_align32_float_uint8_t:
3933 ; CHECK-P9: # %bb.0: # %entry
3934 ; CHECK-P9-NEXT: xscvdpuxws f0, f1
3935 ; CHECK-P9-NEXT: lis r4, -15264
3936 ; CHECK-P9-NEXT: and r3, r3, r4
3937 ; CHECK-P9-NEXT: lis r4, 15258
3938 ; CHECK-P9-NEXT: ori r4, r4, 41712
3939 ; CHECK-P9-NEXT: stxsibx f0, r3, r4
3940 ; CHECK-P9-NEXT: blr
3942 ; CHECK-P8-LABEL: st_disjoint_align32_float_uint8_t:
3943 ; CHECK-P8: # %bb.0: # %entry
3944 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
3945 ; CHECK-P8-NEXT: lis r4, -15264
3946 ; CHECK-P8-NEXT: lis r6, 15258
3947 ; CHECK-P8-NEXT: and r3, r3, r4
3948 ; CHECK-P8-NEXT: ori r4, r6, 41712
3949 ; CHECK-P8-NEXT: mffprwz r5, f0
3950 ; CHECK-P8-NEXT: stbx r5, r3, r4
3951 ; CHECK-P8-NEXT: blr
3953 %and = and i64 %ptr, -1000341504
3954 %conv = fptoui float %str to i8
3955 %or = or i64 %and, 999990000
3956 %0 = inttoptr i64 %or to i8*
3957 store i8 %conv, i8* %0, align 16
3961 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
3962 define dso_local void @st_not_disjoint64_float_uint8_t(i64 %ptr, float %str) {
3963 ; CHECK-P10-LABEL: st_not_disjoint64_float_uint8_t:
3964 ; CHECK-P10: # %bb.0: # %entry
3965 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
3966 ; CHECK-P10-NEXT: pli r4, 232
3967 ; CHECK-P10-NEXT: pli r5, 3567587329
3968 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
3969 ; CHECK-P10-NEXT: or r3, r3, r5
3970 ; CHECK-P10-NEXT: stxsibx f0, 0, r3
3971 ; CHECK-P10-NEXT: blr
3973 ; CHECK-P9-LABEL: st_not_disjoint64_float_uint8_t:
3974 ; CHECK-P9: # %bb.0: # %entry
3975 ; CHECK-P9-NEXT: li r4, 29
3976 ; CHECK-P9-NEXT: xscvdpuxws f0, f1
3977 ; CHECK-P9-NEXT: rldic r4, r4, 35, 24
3978 ; CHECK-P9-NEXT: oris r4, r4, 54437
3979 ; CHECK-P9-NEXT: ori r4, r4, 4097
3980 ; CHECK-P9-NEXT: or r3, r3, r4
3981 ; CHECK-P9-NEXT: stxsibx f0, 0, r3
3982 ; CHECK-P9-NEXT: blr
3984 ; CHECK-P8-LABEL: st_not_disjoint64_float_uint8_t:
3985 ; CHECK-P8: # %bb.0: # %entry
3986 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
3987 ; CHECK-P8-NEXT: li r4, 29
3988 ; CHECK-P8-NEXT: rldic r4, r4, 35, 24
3989 ; CHECK-P8-NEXT: oris r4, r4, 54437
3990 ; CHECK-P8-NEXT: ori r4, r4, 4097
3991 ; CHECK-P8-NEXT: or r3, r3, r4
3992 ; CHECK-P8-NEXT: mffprwz r5, f0
3993 ; CHECK-P8-NEXT: stb r5, 0(r3)
3994 ; CHECK-P8-NEXT: blr
3996 %conv = fptoui float %str to i8
3997 %or = or i64 %ptr, 1000000000001
3998 %0 = inttoptr i64 %or to i8*
3999 store i8 %conv, i8* %0, align 1
4003 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4004 define dso_local void @st_disjoint_align64_float_uint8_t(i64 %ptr, float %str) {
4005 ; CHECK-P10-LABEL: st_disjoint_align64_float_uint8_t:
4006 ; CHECK-P10: # %bb.0: # %entry
4007 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
4008 ; CHECK-P10-NEXT: pli r4, 244140625
4009 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
4010 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
4011 ; CHECK-P10-NEXT: stxsibx f0, r3, r4
4012 ; CHECK-P10-NEXT: blr
4014 ; CHECK-P9-LABEL: st_disjoint_align64_float_uint8_t:
4015 ; CHECK-P9: # %bb.0: # %entry
4016 ; CHECK-P9-NEXT: xscvdpuxws f0, f1
4017 ; CHECK-P9-NEXT: lis r4, 3725
4018 ; CHECK-P9-NEXT: rldicr r3, r3, 0, 23
4019 ; CHECK-P9-NEXT: ori r4, r4, 19025
4020 ; CHECK-P9-NEXT: rldic r4, r4, 12, 24
4021 ; CHECK-P9-NEXT: stxsibx f0, r3, r4
4022 ; CHECK-P9-NEXT: blr
4024 ; CHECK-P8-LABEL: st_disjoint_align64_float_uint8_t:
4025 ; CHECK-P8: # %bb.0: # %entry
4026 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4027 ; CHECK-P8-NEXT: lis r4, 3725
4028 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 23
4029 ; CHECK-P8-NEXT: ori r4, r4, 19025
4030 ; CHECK-P8-NEXT: rldic r4, r4, 12, 24
4031 ; CHECK-P8-NEXT: mffprwz r5, f0
4032 ; CHECK-P8-NEXT: stbx r5, r3, r4
4033 ; CHECK-P8-NEXT: blr
4035 %and = and i64 %ptr, -1099511627776
4036 %conv = fptoui float %str to i8
4037 %or = or i64 %and, 1000000000000
4038 %0 = inttoptr i64 %or to i8*
4039 store i8 %conv, i8* %0, align 4096
4043 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4044 define dso_local void @st_cst_align16_float_uint8_t(float %str) {
4045 ; CHECK-POSTP8-LABEL: st_cst_align16_float_uint8_t:
4046 ; CHECK-POSTP8: # %bb.0: # %entry
4047 ; CHECK-POSTP8-NEXT: xscvdpuxws f0, f1
4048 ; CHECK-POSTP8-NEXT: li r3, 4080
4049 ; CHECK-POSTP8-NEXT: stxsibx f0, 0, r3
4050 ; CHECK-POSTP8-NEXT: blr
4052 ; CHECK-P8-LABEL: st_cst_align16_float_uint8_t:
4053 ; CHECK-P8: # %bb.0: # %entry
4054 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4055 ; CHECK-P8-NEXT: mffprwz r3, f0
4056 ; CHECK-P8-NEXT: stb r3, 4080(0)
4057 ; CHECK-P8-NEXT: blr
4059 %conv = fptoui float %str to i8
4060 store i8 %conv, i8* inttoptr (i64 4080 to i8*), align 16
4064 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4065 define dso_local void @st_cst_align32_float_uint8_t(float %str) {
4066 ; CHECK-P10-LABEL: st_cst_align32_float_uint8_t:
4067 ; CHECK-P10: # %bb.0: # %entry
4068 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
4069 ; CHECK-P10-NEXT: pli r3, 9999900
4070 ; CHECK-P10-NEXT: stxsibx f0, 0, r3
4071 ; CHECK-P10-NEXT: blr
4073 ; CHECK-P9-LABEL: st_cst_align32_float_uint8_t:
4074 ; CHECK-P9: # %bb.0: # %entry
4075 ; CHECK-P9-NEXT: xscvdpuxws f0, f1
4076 ; CHECK-P9-NEXT: lis r3, 152
4077 ; CHECK-P9-NEXT: ori r3, r3, 38428
4078 ; CHECK-P9-NEXT: stxsibx f0, 0, r3
4079 ; CHECK-P9-NEXT: blr
4081 ; CHECK-P8-LABEL: st_cst_align32_float_uint8_t:
4082 ; CHECK-P8: # %bb.0: # %entry
4083 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4084 ; CHECK-P8-NEXT: lis r4, 153
4085 ; CHECK-P8-NEXT: mffprwz r3, f0
4086 ; CHECK-P8-NEXT: stb r3, -27108(r4)
4087 ; CHECK-P8-NEXT: blr
4089 %conv = fptoui float %str to i8
4090 store i8 %conv, i8* inttoptr (i64 9999900 to i8*), align 4
4094 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4095 define dso_local void @st_cst_align64_float_uint8_t(float %str) {
4096 ; CHECK-P10-LABEL: st_cst_align64_float_uint8_t:
4097 ; CHECK-P10: # %bb.0: # %entry
4098 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
4099 ; CHECK-P10-NEXT: pli r3, 244140625
4100 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
4101 ; CHECK-P10-NEXT: stxsibx f0, 0, r3
4102 ; CHECK-P10-NEXT: blr
4104 ; CHECK-P9-LABEL: st_cst_align64_float_uint8_t:
4105 ; CHECK-P9: # %bb.0: # %entry
4106 ; CHECK-P9-NEXT: xscvdpuxws f0, f1
4107 ; CHECK-P9-NEXT: lis r3, 3725
4108 ; CHECK-P9-NEXT: ori r3, r3, 19025
4109 ; CHECK-P9-NEXT: rldic r3, r3, 12, 24
4110 ; CHECK-P9-NEXT: stxsibx f0, 0, r3
4111 ; CHECK-P9-NEXT: blr
4113 ; CHECK-P8-LABEL: st_cst_align64_float_uint8_t:
4114 ; CHECK-P8: # %bb.0: # %entry
4115 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4116 ; CHECK-P8-NEXT: lis r3, 3725
4117 ; CHECK-P8-NEXT: ori r3, r3, 19025
4118 ; CHECK-P8-NEXT: rldic r3, r3, 12, 24
4119 ; CHECK-P8-NEXT: mffprwz r4, f0
4120 ; CHECK-P8-NEXT: stb r4, 0(r3)
4121 ; CHECK-P8-NEXT: blr
4123 %conv = fptoui float %str to i8
4124 store i8 %conv, i8* inttoptr (i64 1000000000000 to i8*), align 4096
4128 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4129 define dso_local void @st_0_float_int8_t(i64 %ptr, float %str) {
4130 ; CHECK-POSTP8-LABEL: st_0_float_int8_t:
4131 ; CHECK-POSTP8: # %bb.0: # %entry
4132 ; CHECK-POSTP8-NEXT: xscvdpsxws f0, f1
4133 ; CHECK-POSTP8-NEXT: stxsibx f0, 0, r3
4134 ; CHECK-POSTP8-NEXT: blr
4136 ; CHECK-P8-LABEL: st_0_float_int8_t:
4137 ; CHECK-P8: # %bb.0: # %entry
4138 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4139 ; CHECK-P8-NEXT: mffprwz r4, f0
4140 ; CHECK-P8-NEXT: stb r4, 0(r3)
4141 ; CHECK-P8-NEXT: blr
4143 %conv = fptosi float %str to i8
4144 %0 = inttoptr i64 %ptr to i8*
4145 store i8 %conv, i8* %0, align 1
4149 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4150 define dso_local void @st_align16_float_int8_t(i8* nocapture %ptr, float %str) {
4151 ; CHECK-POSTP8-LABEL: st_align16_float_int8_t:
4152 ; CHECK-POSTP8: # %bb.0: # %entry
4153 ; CHECK-POSTP8-NEXT: xscvdpsxws f0, f1
4154 ; CHECK-POSTP8-NEXT: addi r3, r3, 8
4155 ; CHECK-POSTP8-NEXT: stxsibx f0, 0, r3
4156 ; CHECK-POSTP8-NEXT: blr
4158 ; CHECK-P8-LABEL: st_align16_float_int8_t:
4159 ; CHECK-P8: # %bb.0: # %entry
4160 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4161 ; CHECK-P8-NEXT: mffprwz r4, f0
4162 ; CHECK-P8-NEXT: stb r4, 8(r3)
4163 ; CHECK-P8-NEXT: blr
4165 %conv = fptosi float %str to i8
4166 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
4167 store i8 %conv, i8* %add.ptr, align 1
4171 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4172 define dso_local void @st_align32_float_int8_t(i8* nocapture %ptr, float %str) {
4173 ; CHECK-P10-LABEL: st_align32_float_int8_t:
4174 ; CHECK-P10: # %bb.0: # %entry
4175 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
4176 ; CHECK-P10-NEXT: pli r4, 99999000
4177 ; CHECK-P10-NEXT: stxsibx f0, r3, r4
4178 ; CHECK-P10-NEXT: blr
4180 ; CHECK-P9-LABEL: st_align32_float_int8_t:
4181 ; CHECK-P9: # %bb.0: # %entry
4182 ; CHECK-P9-NEXT: xscvdpsxws f0, f1
4183 ; CHECK-P9-NEXT: lis r4, 1525
4184 ; CHECK-P9-NEXT: ori r4, r4, 56600
4185 ; CHECK-P9-NEXT: stxsibx f0, r3, r4
4186 ; CHECK-P9-NEXT: blr
4188 ; CHECK-P8-LABEL: st_align32_float_int8_t:
4189 ; CHECK-P8: # %bb.0: # %entry
4190 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4191 ; CHECK-P8-NEXT: lis r4, 1525
4192 ; CHECK-P8-NEXT: ori r4, r4, 56600
4193 ; CHECK-P8-NEXT: mffprwz r5, f0
4194 ; CHECK-P8-NEXT: stbx r5, r3, r4
4195 ; CHECK-P8-NEXT: blr
4197 %conv = fptosi float %str to i8
4198 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
4199 store i8 %conv, i8* %add.ptr, align 1
4203 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4204 define dso_local void @st_align64_float_int8_t(i8* nocapture %ptr, float %str) {
4205 ; CHECK-P10-LABEL: st_align64_float_int8_t:
4206 ; CHECK-P10: # %bb.0: # %entry
4207 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
4208 ; CHECK-P10-NEXT: pli r4, 244140625
4209 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
4210 ; CHECK-P10-NEXT: stxsibx f0, r3, r4
4211 ; CHECK-P10-NEXT: blr
4213 ; CHECK-P9-LABEL: st_align64_float_int8_t:
4214 ; CHECK-P9: # %bb.0: # %entry
4215 ; CHECK-P9-NEXT: xscvdpsxws f0, f1
4216 ; CHECK-P9-NEXT: lis r4, 3725
4217 ; CHECK-P9-NEXT: ori r4, r4, 19025
4218 ; CHECK-P9-NEXT: rldic r4, r4, 12, 24
4219 ; CHECK-P9-NEXT: stxsibx f0, r3, r4
4220 ; CHECK-P9-NEXT: blr
4222 ; CHECK-P8-LABEL: st_align64_float_int8_t:
4223 ; CHECK-P8: # %bb.0: # %entry
4224 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4225 ; CHECK-P8-NEXT: lis r4, 3725
4226 ; CHECK-P8-NEXT: ori r4, r4, 19025
4227 ; CHECK-P8-NEXT: rldic r4, r4, 12, 24
4228 ; CHECK-P8-NEXT: mffprwz r5, f0
4229 ; CHECK-P8-NEXT: stbx r5, r3, r4
4230 ; CHECK-P8-NEXT: blr
4232 %conv = fptosi float %str to i8
4233 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
4234 store i8 %conv, i8* %add.ptr, align 1
4238 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4239 define dso_local void @st_reg_float_int8_t(i8* nocapture %ptr, i64 %off, float %str) {
4240 ; CHECK-POSTP8-LABEL: st_reg_float_int8_t:
4241 ; CHECK-POSTP8: # %bb.0: # %entry
4242 ; CHECK-POSTP8-NEXT: xscvdpsxws f0, f1
4243 ; CHECK-POSTP8-NEXT: stxsibx f0, r3, r4
4244 ; CHECK-POSTP8-NEXT: blr
4246 ; CHECK-P8-LABEL: st_reg_float_int8_t:
4247 ; CHECK-P8: # %bb.0: # %entry
4248 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4249 ; CHECK-P8-NEXT: mffprwz r5, f0
4250 ; CHECK-P8-NEXT: stbx r5, r3, r4
4251 ; CHECK-P8-NEXT: blr
4253 %conv = fptosi float %str to i8
4254 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
4255 store i8 %conv, i8* %add.ptr, align 1
4259 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4260 define dso_local void @st_or1_float_int8_t(i64 %ptr, i8 zeroext %off, float %str) {
4261 ; CHECK-POSTP8-LABEL: st_or1_float_int8_t:
4262 ; CHECK-POSTP8: # %bb.0: # %entry
4263 ; CHECK-POSTP8-NEXT: xscvdpsxws f0, f1
4264 ; CHECK-POSTP8-NEXT: or r3, r4, r3
4265 ; CHECK-POSTP8-NEXT: stxsibx f0, 0, r3
4266 ; CHECK-POSTP8-NEXT: blr
4268 ; CHECK-P8-LABEL: st_or1_float_int8_t:
4269 ; CHECK-P8: # %bb.0: # %entry
4270 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4271 ; CHECK-P8-NEXT: or r3, r4, r3
4272 ; CHECK-P8-NEXT: mffprwz r5, f0
4273 ; CHECK-P8-NEXT: stb r5, 0(r3)
4274 ; CHECK-P8-NEXT: blr
4276 %conv = fptosi float %str to i8
4277 %conv1 = zext i8 %off to i64
4278 %or = or i64 %conv1, %ptr
4279 %0 = inttoptr i64 %or to i8*
4280 store i8 %conv, i8* %0, align 1
4284 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4285 define dso_local void @st_not_disjoint16_float_int8_t(i64 %ptr, float %str) {
4286 ; CHECK-POSTP8-LABEL: st_not_disjoint16_float_int8_t:
4287 ; CHECK-POSTP8: # %bb.0: # %entry
4288 ; CHECK-POSTP8-NEXT: xscvdpsxws f0, f1
4289 ; CHECK-POSTP8-NEXT: ori r3, r3, 6
4290 ; CHECK-POSTP8-NEXT: stxsibx f0, 0, r3
4291 ; CHECK-POSTP8-NEXT: blr
4293 ; CHECK-P8-LABEL: st_not_disjoint16_float_int8_t:
4294 ; CHECK-P8: # %bb.0: # %entry
4295 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4296 ; CHECK-P8-NEXT: ori r3, r3, 6
4297 ; CHECK-P8-NEXT: mffprwz r4, f0
4298 ; CHECK-P8-NEXT: stb r4, 0(r3)
4299 ; CHECK-P8-NEXT: blr
4301 %conv = fptosi float %str to i8
4302 %or = or i64 %ptr, 6
4303 %0 = inttoptr i64 %or to i8*
4304 store i8 %conv, i8* %0, align 1
4308 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4309 define dso_local void @st_disjoint_align16_float_int8_t(i64 %ptr, float %str) {
4310 ; CHECK-POSTP8-LABEL: st_disjoint_align16_float_int8_t:
4311 ; CHECK-POSTP8: # %bb.0: # %entry
4312 ; CHECK-POSTP8-NEXT: xscvdpsxws f0, f1
4313 ; CHECK-POSTP8-NEXT: rldicr r3, r3, 0, 51
4314 ; CHECK-POSTP8-NEXT: ori r3, r3, 24
4315 ; CHECK-POSTP8-NEXT: stxsibx f0, 0, r3
4316 ; CHECK-POSTP8-NEXT: blr
4318 ; CHECK-P8-LABEL: st_disjoint_align16_float_int8_t:
4319 ; CHECK-P8: # %bb.0: # %entry
4320 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4321 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 51
4322 ; CHECK-P8-NEXT: mffprwz r4, f0
4323 ; CHECK-P8-NEXT: stb r4, 24(r3)
4324 ; CHECK-P8-NEXT: blr
4326 %and = and i64 %ptr, -4096
4327 %conv = fptosi float %str to i8
4328 %or = or i64 %and, 24
4329 %0 = inttoptr i64 %or to i8*
4330 store i8 %conv, i8* %0, align 8
4334 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4335 define dso_local void @st_not_disjoint32_float_int8_t(i64 %ptr, float %str) {
4336 ; CHECK-POSTP8-LABEL: st_not_disjoint32_float_int8_t:
4337 ; CHECK-POSTP8: # %bb.0: # %entry
4338 ; CHECK-POSTP8-NEXT: xscvdpsxws f0, f1
4339 ; CHECK-POSTP8-NEXT: ori r3, r3, 34463
4340 ; CHECK-POSTP8-NEXT: oris r3, r3, 1
4341 ; CHECK-POSTP8-NEXT: stxsibx f0, 0, r3
4342 ; CHECK-POSTP8-NEXT: blr
4344 ; CHECK-P8-LABEL: st_not_disjoint32_float_int8_t:
4345 ; CHECK-P8: # %bb.0: # %entry
4346 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4347 ; CHECK-P8-NEXT: ori r3, r3, 34463
4348 ; CHECK-P8-NEXT: oris r3, r3, 1
4349 ; CHECK-P8-NEXT: mffprwz r4, f0
4350 ; CHECK-P8-NEXT: stb r4, 0(r3)
4351 ; CHECK-P8-NEXT: blr
4353 %conv = fptosi float %str to i8
4354 %or = or i64 %ptr, 99999
4355 %0 = inttoptr i64 %or to i8*
4356 store i8 %conv, i8* %0, align 1
4360 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4361 define dso_local void @st_disjoint_align32_float_int8_t(i64 %ptr, float %str) {
4362 ; CHECK-P10-LABEL: st_disjoint_align32_float_int8_t:
4363 ; CHECK-P10: # %bb.0: # %entry
4364 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
4365 ; CHECK-P10-NEXT: lis r4, -15264
4366 ; CHECK-P10-NEXT: and r3, r3, r4
4367 ; CHECK-P10-NEXT: pli r4, 999990000
4368 ; CHECK-P10-NEXT: stxsibx f0, r3, r4
4369 ; CHECK-P10-NEXT: blr
4371 ; CHECK-P9-LABEL: st_disjoint_align32_float_int8_t:
4372 ; CHECK-P9: # %bb.0: # %entry
4373 ; CHECK-P9-NEXT: xscvdpsxws f0, f1
4374 ; CHECK-P9-NEXT: lis r4, -15264
4375 ; CHECK-P9-NEXT: and r3, r3, r4
4376 ; CHECK-P9-NEXT: lis r4, 15258
4377 ; CHECK-P9-NEXT: ori r4, r4, 41712
4378 ; CHECK-P9-NEXT: stxsibx f0, r3, r4
4379 ; CHECK-P9-NEXT: blr
4381 ; CHECK-P8-LABEL: st_disjoint_align32_float_int8_t:
4382 ; CHECK-P8: # %bb.0: # %entry
4383 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4384 ; CHECK-P8-NEXT: lis r4, -15264
4385 ; CHECK-P8-NEXT: lis r6, 15258
4386 ; CHECK-P8-NEXT: and r3, r3, r4
4387 ; CHECK-P8-NEXT: ori r4, r6, 41712
4388 ; CHECK-P8-NEXT: mffprwz r5, f0
4389 ; CHECK-P8-NEXT: stbx r5, r3, r4
4390 ; CHECK-P8-NEXT: blr
4392 %and = and i64 %ptr, -1000341504
4393 %conv = fptosi float %str to i8
4394 %or = or i64 %and, 999990000
4395 %0 = inttoptr i64 %or to i8*
4396 store i8 %conv, i8* %0, align 16
4400 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4401 define dso_local void @st_not_disjoint64_float_int8_t(i64 %ptr, float %str) {
4402 ; CHECK-P10-LABEL: st_not_disjoint64_float_int8_t:
4403 ; CHECK-P10: # %bb.0: # %entry
4404 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
4405 ; CHECK-P10-NEXT: pli r4, 232
4406 ; CHECK-P10-NEXT: pli r5, 3567587329
4407 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
4408 ; CHECK-P10-NEXT: or r3, r3, r5
4409 ; CHECK-P10-NEXT: stxsibx f0, 0, r3
4410 ; CHECK-P10-NEXT: blr
4412 ; CHECK-P9-LABEL: st_not_disjoint64_float_int8_t:
4413 ; CHECK-P9: # %bb.0: # %entry
4414 ; CHECK-P9-NEXT: li r4, 29
4415 ; CHECK-P9-NEXT: xscvdpsxws f0, f1
4416 ; CHECK-P9-NEXT: rldic r4, r4, 35, 24
4417 ; CHECK-P9-NEXT: oris r4, r4, 54437
4418 ; CHECK-P9-NEXT: ori r4, r4, 4097
4419 ; CHECK-P9-NEXT: or r3, r3, r4
4420 ; CHECK-P9-NEXT: stxsibx f0, 0, r3
4421 ; CHECK-P9-NEXT: blr
4423 ; CHECK-P8-LABEL: st_not_disjoint64_float_int8_t:
4424 ; CHECK-P8: # %bb.0: # %entry
4425 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4426 ; CHECK-P8-NEXT: li r4, 29
4427 ; CHECK-P8-NEXT: rldic r4, r4, 35, 24
4428 ; CHECK-P8-NEXT: oris r4, r4, 54437
4429 ; CHECK-P8-NEXT: ori r4, r4, 4097
4430 ; CHECK-P8-NEXT: or r3, r3, r4
4431 ; CHECK-P8-NEXT: mffprwz r5, f0
4432 ; CHECK-P8-NEXT: stb r5, 0(r3)
4433 ; CHECK-P8-NEXT: blr
4435 %conv = fptosi float %str to i8
4436 %or = or i64 %ptr, 1000000000001
4437 %0 = inttoptr i64 %or to i8*
4438 store i8 %conv, i8* %0, align 1
4442 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4443 define dso_local void @st_disjoint_align64_float_int8_t(i64 %ptr, float %str) {
4444 ; CHECK-P10-LABEL: st_disjoint_align64_float_int8_t:
4445 ; CHECK-P10: # %bb.0: # %entry
4446 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
4447 ; CHECK-P10-NEXT: pli r4, 244140625
4448 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
4449 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
4450 ; CHECK-P10-NEXT: stxsibx f0, r3, r4
4451 ; CHECK-P10-NEXT: blr
4453 ; CHECK-P9-LABEL: st_disjoint_align64_float_int8_t:
4454 ; CHECK-P9: # %bb.0: # %entry
4455 ; CHECK-P9-NEXT: xscvdpsxws f0, f1
4456 ; CHECK-P9-NEXT: lis r4, 3725
4457 ; CHECK-P9-NEXT: rldicr r3, r3, 0, 23
4458 ; CHECK-P9-NEXT: ori r4, r4, 19025
4459 ; CHECK-P9-NEXT: rldic r4, r4, 12, 24
4460 ; CHECK-P9-NEXT: stxsibx f0, r3, r4
4461 ; CHECK-P9-NEXT: blr
4463 ; CHECK-P8-LABEL: st_disjoint_align64_float_int8_t:
4464 ; CHECK-P8: # %bb.0: # %entry
4465 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4466 ; CHECK-P8-NEXT: lis r4, 3725
4467 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 23
4468 ; CHECK-P8-NEXT: ori r4, r4, 19025
4469 ; CHECK-P8-NEXT: rldic r4, r4, 12, 24
4470 ; CHECK-P8-NEXT: mffprwz r5, f0
4471 ; CHECK-P8-NEXT: stbx r5, r3, r4
4472 ; CHECK-P8-NEXT: blr
4474 %and = and i64 %ptr, -1099511627776
4475 %conv = fptosi float %str to i8
4476 %or = or i64 %and, 1000000000000
4477 %0 = inttoptr i64 %or to i8*
4478 store i8 %conv, i8* %0, align 4096
4482 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4483 define dso_local void @st_cst_align16_float_int8_t(float %str) {
4484 ; CHECK-POSTP8-LABEL: st_cst_align16_float_int8_t:
4485 ; CHECK-POSTP8: # %bb.0: # %entry
4486 ; CHECK-POSTP8-NEXT: xscvdpsxws f0, f1
4487 ; CHECK-POSTP8-NEXT: li r3, 4080
4488 ; CHECK-POSTP8-NEXT: stxsibx f0, 0, r3
4489 ; CHECK-POSTP8-NEXT: blr
4491 ; CHECK-P8-LABEL: st_cst_align16_float_int8_t:
4492 ; CHECK-P8: # %bb.0: # %entry
4493 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4494 ; CHECK-P8-NEXT: mffprwz r3, f0
4495 ; CHECK-P8-NEXT: stb r3, 4080(0)
4496 ; CHECK-P8-NEXT: blr
4498 %conv = fptosi float %str to i8
4499 store i8 %conv, i8* inttoptr (i64 4080 to i8*), align 16
4503 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4504 define dso_local void @st_cst_align32_float_int8_t(float %str) {
4505 ; CHECK-P10-LABEL: st_cst_align32_float_int8_t:
4506 ; CHECK-P10: # %bb.0: # %entry
4507 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
4508 ; CHECK-P10-NEXT: pli r3, 9999900
4509 ; CHECK-P10-NEXT: stxsibx f0, 0, r3
4510 ; CHECK-P10-NEXT: blr
4512 ; CHECK-P9-LABEL: st_cst_align32_float_int8_t:
4513 ; CHECK-P9: # %bb.0: # %entry
4514 ; CHECK-P9-NEXT: xscvdpsxws f0, f1
4515 ; CHECK-P9-NEXT: lis r3, 152
4516 ; CHECK-P9-NEXT: ori r3, r3, 38428
4517 ; CHECK-P9-NEXT: stxsibx f0, 0, r3
4518 ; CHECK-P9-NEXT: blr
4520 ; CHECK-P8-LABEL: st_cst_align32_float_int8_t:
4521 ; CHECK-P8: # %bb.0: # %entry
4522 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4523 ; CHECK-P8-NEXT: lis r4, 153
4524 ; CHECK-P8-NEXT: mffprwz r3, f0
4525 ; CHECK-P8-NEXT: stb r3, -27108(r4)
4526 ; CHECK-P8-NEXT: blr
4528 %conv = fptosi float %str to i8
4529 store i8 %conv, i8* inttoptr (i64 9999900 to i8*), align 4
4533 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4534 define dso_local void @st_cst_align64_float_int8_t(float %str) {
4535 ; CHECK-P10-LABEL: st_cst_align64_float_int8_t:
4536 ; CHECK-P10: # %bb.0: # %entry
4537 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
4538 ; CHECK-P10-NEXT: pli r3, 244140625
4539 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
4540 ; CHECK-P10-NEXT: stxsibx f0, 0, r3
4541 ; CHECK-P10-NEXT: blr
4543 ; CHECK-P9-LABEL: st_cst_align64_float_int8_t:
4544 ; CHECK-P9: # %bb.0: # %entry
4545 ; CHECK-P9-NEXT: xscvdpsxws f0, f1
4546 ; CHECK-P9-NEXT: lis r3, 3725
4547 ; CHECK-P9-NEXT: ori r3, r3, 19025
4548 ; CHECK-P9-NEXT: rldic r3, r3, 12, 24
4549 ; CHECK-P9-NEXT: stxsibx f0, 0, r3
4550 ; CHECK-P9-NEXT: blr
4552 ; CHECK-P8-LABEL: st_cst_align64_float_int8_t:
4553 ; CHECK-P8: # %bb.0: # %entry
4554 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4555 ; CHECK-P8-NEXT: lis r3, 3725
4556 ; CHECK-P8-NEXT: ori r3, r3, 19025
4557 ; CHECK-P8-NEXT: rldic r3, r3, 12, 24
4558 ; CHECK-P8-NEXT: mffprwz r4, f0
4559 ; CHECK-P8-NEXT: stb r4, 0(r3)
4560 ; CHECK-P8-NEXT: blr
4562 %conv = fptosi float %str to i8
4563 store i8 %conv, i8* inttoptr (i64 1000000000000 to i8*), align 4096
4567 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4568 define dso_local void @st_0_float_uint16_t(i64 %ptr, float %str) {
4569 ; CHECK-POSTP8-LABEL: st_0_float_uint16_t:
4570 ; CHECK-POSTP8: # %bb.0: # %entry
4571 ; CHECK-POSTP8-NEXT: xscvdpuxws f0, f1
4572 ; CHECK-POSTP8-NEXT: stxsihx f0, 0, r3
4573 ; CHECK-POSTP8-NEXT: blr
4575 ; CHECK-P8-LABEL: st_0_float_uint16_t:
4576 ; CHECK-P8: # %bb.0: # %entry
4577 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4578 ; CHECK-P8-NEXT: mffprwz r4, f0
4579 ; CHECK-P8-NEXT: sth r4, 0(r3)
4580 ; CHECK-P8-NEXT: blr
4582 %conv = fptoui float %str to i16
4583 %0 = inttoptr i64 %ptr to i16*
4584 store i16 %conv, i16* %0, align 2
4588 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4589 define dso_local void @st_align16_float_uint16_t(i8* nocapture %ptr, float %str) {
4590 ; CHECK-POSTP8-LABEL: st_align16_float_uint16_t:
4591 ; CHECK-POSTP8: # %bb.0: # %entry
4592 ; CHECK-POSTP8-NEXT: xscvdpuxws f0, f1
4593 ; CHECK-POSTP8-NEXT: addi r3, r3, 8
4594 ; CHECK-POSTP8-NEXT: stxsihx f0, 0, r3
4595 ; CHECK-POSTP8-NEXT: blr
4597 ; CHECK-P8-LABEL: st_align16_float_uint16_t:
4598 ; CHECK-P8: # %bb.0: # %entry
4599 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4600 ; CHECK-P8-NEXT: mffprwz r4, f0
4601 ; CHECK-P8-NEXT: sth r4, 8(r3)
4602 ; CHECK-P8-NEXT: blr
4604 %conv = fptoui float %str to i16
4605 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
4606 %0 = bitcast i8* %add.ptr to i16*
4607 store i16 %conv, i16* %0, align 2
4611 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4612 define dso_local void @st_align32_float_uint16_t(i8* nocapture %ptr, float %str) {
4613 ; CHECK-P10-LABEL: st_align32_float_uint16_t:
4614 ; CHECK-P10: # %bb.0: # %entry
4615 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
4616 ; CHECK-P10-NEXT: pli r4, 99999000
4617 ; CHECK-P10-NEXT: stxsihx f0, r3, r4
4618 ; CHECK-P10-NEXT: blr
4620 ; CHECK-P9-LABEL: st_align32_float_uint16_t:
4621 ; CHECK-P9: # %bb.0: # %entry
4622 ; CHECK-P9-NEXT: xscvdpuxws f0, f1
4623 ; CHECK-P9-NEXT: lis r4, 1525
4624 ; CHECK-P9-NEXT: ori r4, r4, 56600
4625 ; CHECK-P9-NEXT: stxsihx f0, r3, r4
4626 ; CHECK-P9-NEXT: blr
4628 ; CHECK-P8-LABEL: st_align32_float_uint16_t:
4629 ; CHECK-P8: # %bb.0: # %entry
4630 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4631 ; CHECK-P8-NEXT: lis r4, 1525
4632 ; CHECK-P8-NEXT: ori r4, r4, 56600
4633 ; CHECK-P8-NEXT: mffprwz r5, f0
4634 ; CHECK-P8-NEXT: sthx r5, r3, r4
4635 ; CHECK-P8-NEXT: blr
4637 %conv = fptoui float %str to i16
4638 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
4639 %0 = bitcast i8* %add.ptr to i16*
4640 store i16 %conv, i16* %0, align 2
4644 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4645 define dso_local void @st_align64_float_uint16_t(i8* nocapture %ptr, float %str) {
4646 ; CHECK-P10-LABEL: st_align64_float_uint16_t:
4647 ; CHECK-P10: # %bb.0: # %entry
4648 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
4649 ; CHECK-P10-NEXT: pli r4, 244140625
4650 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
4651 ; CHECK-P10-NEXT: stxsihx f0, r3, r4
4652 ; CHECK-P10-NEXT: blr
4654 ; CHECK-P9-LABEL: st_align64_float_uint16_t:
4655 ; CHECK-P9: # %bb.0: # %entry
4656 ; CHECK-P9-NEXT: xscvdpuxws f0, f1
4657 ; CHECK-P9-NEXT: lis r4, 3725
4658 ; CHECK-P9-NEXT: ori r4, r4, 19025
4659 ; CHECK-P9-NEXT: rldic r4, r4, 12, 24
4660 ; CHECK-P9-NEXT: stxsihx f0, r3, r4
4661 ; CHECK-P9-NEXT: blr
4663 ; CHECK-P8-LABEL: st_align64_float_uint16_t:
4664 ; CHECK-P8: # %bb.0: # %entry
4665 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4666 ; CHECK-P8-NEXT: lis r4, 3725
4667 ; CHECK-P8-NEXT: ori r4, r4, 19025
4668 ; CHECK-P8-NEXT: rldic r4, r4, 12, 24
4669 ; CHECK-P8-NEXT: mffprwz r5, f0
4670 ; CHECK-P8-NEXT: sthx r5, r3, r4
4671 ; CHECK-P8-NEXT: blr
4673 %conv = fptoui float %str to i16
4674 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
4675 %0 = bitcast i8* %add.ptr to i16*
4676 store i16 %conv, i16* %0, align 2
4680 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4681 define dso_local void @st_reg_float_uint16_t(i8* nocapture %ptr, i64 %off, float %str) {
4682 ; CHECK-POSTP8-LABEL: st_reg_float_uint16_t:
4683 ; CHECK-POSTP8: # %bb.0: # %entry
4684 ; CHECK-POSTP8-NEXT: xscvdpuxws f0, f1
4685 ; CHECK-POSTP8-NEXT: stxsihx f0, r3, r4
4686 ; CHECK-POSTP8-NEXT: blr
4688 ; CHECK-P8-LABEL: st_reg_float_uint16_t:
4689 ; CHECK-P8: # %bb.0: # %entry
4690 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4691 ; CHECK-P8-NEXT: mffprwz r5, f0
4692 ; CHECK-P8-NEXT: sthx r5, r3, r4
4693 ; CHECK-P8-NEXT: blr
4695 %conv = fptoui float %str to i16
4696 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
4697 %0 = bitcast i8* %add.ptr to i16*
4698 store i16 %conv, i16* %0, align 2
4702 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4703 define dso_local void @st_or1_float_uint16_t(i64 %ptr, i8 zeroext %off, float %str) {
4704 ; CHECK-POSTP8-LABEL: st_or1_float_uint16_t:
4705 ; CHECK-POSTP8: # %bb.0: # %entry
4706 ; CHECK-POSTP8-NEXT: xscvdpuxws f0, f1
4707 ; CHECK-POSTP8-NEXT: or r3, r4, r3
4708 ; CHECK-POSTP8-NEXT: stxsihx f0, 0, r3
4709 ; CHECK-POSTP8-NEXT: blr
4711 ; CHECK-P8-LABEL: st_or1_float_uint16_t:
4712 ; CHECK-P8: # %bb.0: # %entry
4713 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4714 ; CHECK-P8-NEXT: or r3, r4, r3
4715 ; CHECK-P8-NEXT: mffprwz r5, f0
4716 ; CHECK-P8-NEXT: sth r5, 0(r3)
4717 ; CHECK-P8-NEXT: blr
4719 %conv = fptoui float %str to i16
4720 %conv1 = zext i8 %off to i64
4721 %or = or i64 %conv1, %ptr
4722 %0 = inttoptr i64 %or to i16*
4723 store i16 %conv, i16* %0, align 2
4727 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4728 define dso_local void @st_not_disjoint16_float_uint16_t(i64 %ptr, float %str) {
4729 ; CHECK-POSTP8-LABEL: st_not_disjoint16_float_uint16_t:
4730 ; CHECK-POSTP8: # %bb.0: # %entry
4731 ; CHECK-POSTP8-NEXT: xscvdpuxws f0, f1
4732 ; CHECK-POSTP8-NEXT: ori r3, r3, 6
4733 ; CHECK-POSTP8-NEXT: stxsihx f0, 0, r3
4734 ; CHECK-POSTP8-NEXT: blr
4736 ; CHECK-P8-LABEL: st_not_disjoint16_float_uint16_t:
4737 ; CHECK-P8: # %bb.0: # %entry
4738 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4739 ; CHECK-P8-NEXT: ori r3, r3, 6
4740 ; CHECK-P8-NEXT: mffprwz r4, f0
4741 ; CHECK-P8-NEXT: sth r4, 0(r3)
4742 ; CHECK-P8-NEXT: blr
4744 %conv = fptoui float %str to i16
4745 %or = or i64 %ptr, 6
4746 %0 = inttoptr i64 %or to i16*
4747 store i16 %conv, i16* %0, align 2
4751 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4752 define dso_local void @st_disjoint_align16_float_uint16_t(i64 %ptr, float %str) {
4753 ; CHECK-POSTP8-LABEL: st_disjoint_align16_float_uint16_t:
4754 ; CHECK-POSTP8: # %bb.0: # %entry
4755 ; CHECK-POSTP8-NEXT: xscvdpuxws f0, f1
4756 ; CHECK-POSTP8-NEXT: rldicr r3, r3, 0, 51
4757 ; CHECK-POSTP8-NEXT: ori r3, r3, 24
4758 ; CHECK-POSTP8-NEXT: stxsihx f0, 0, r3
4759 ; CHECK-POSTP8-NEXT: blr
4761 ; CHECK-P8-LABEL: st_disjoint_align16_float_uint16_t:
4762 ; CHECK-P8: # %bb.0: # %entry
4763 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4764 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 51
4765 ; CHECK-P8-NEXT: mffprwz r4, f0
4766 ; CHECK-P8-NEXT: sth r4, 24(r3)
4767 ; CHECK-P8-NEXT: blr
4769 %and = and i64 %ptr, -4096
4770 %conv = fptoui float %str to i16
4771 %or = or i64 %and, 24
4772 %0 = inttoptr i64 %or to i16*
4773 store i16 %conv, i16* %0, align 8
4777 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4778 define dso_local void @st_not_disjoint32_float_uint16_t(i64 %ptr, float %str) {
4779 ; CHECK-POSTP8-LABEL: st_not_disjoint32_float_uint16_t:
4780 ; CHECK-POSTP8: # %bb.0: # %entry
4781 ; CHECK-POSTP8-NEXT: xscvdpuxws f0, f1
4782 ; CHECK-POSTP8-NEXT: ori r3, r3, 34463
4783 ; CHECK-POSTP8-NEXT: oris r3, r3, 1
4784 ; CHECK-POSTP8-NEXT: stxsihx f0, 0, r3
4785 ; CHECK-POSTP8-NEXT: blr
4787 ; CHECK-P8-LABEL: st_not_disjoint32_float_uint16_t:
4788 ; CHECK-P8: # %bb.0: # %entry
4789 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4790 ; CHECK-P8-NEXT: ori r3, r3, 34463
4791 ; CHECK-P8-NEXT: oris r3, r3, 1
4792 ; CHECK-P8-NEXT: mffprwz r4, f0
4793 ; CHECK-P8-NEXT: sth r4, 0(r3)
4794 ; CHECK-P8-NEXT: blr
4796 %conv = fptoui float %str to i16
4797 %or = or i64 %ptr, 99999
4798 %0 = inttoptr i64 %or to i16*
4799 store i16 %conv, i16* %0, align 2
4803 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4804 define dso_local void @st_disjoint_align32_float_uint16_t(i64 %ptr, float %str) {
4805 ; CHECK-P10-LABEL: st_disjoint_align32_float_uint16_t:
4806 ; CHECK-P10: # %bb.0: # %entry
4807 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
4808 ; CHECK-P10-NEXT: lis r4, -15264
4809 ; CHECK-P10-NEXT: and r3, r3, r4
4810 ; CHECK-P10-NEXT: pli r4, 999990000
4811 ; CHECK-P10-NEXT: stxsihx f0, r3, r4
4812 ; CHECK-P10-NEXT: blr
4814 ; CHECK-P9-LABEL: st_disjoint_align32_float_uint16_t:
4815 ; CHECK-P9: # %bb.0: # %entry
4816 ; CHECK-P9-NEXT: xscvdpuxws f0, f1
4817 ; CHECK-P9-NEXT: lis r4, -15264
4818 ; CHECK-P9-NEXT: and r3, r3, r4
4819 ; CHECK-P9-NEXT: lis r4, 15258
4820 ; CHECK-P9-NEXT: ori r4, r4, 41712
4821 ; CHECK-P9-NEXT: stxsihx f0, r3, r4
4822 ; CHECK-P9-NEXT: blr
4824 ; CHECK-P8-LABEL: st_disjoint_align32_float_uint16_t:
4825 ; CHECK-P8: # %bb.0: # %entry
4826 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4827 ; CHECK-P8-NEXT: lis r4, -15264
4828 ; CHECK-P8-NEXT: lis r6, 15258
4829 ; CHECK-P8-NEXT: and r3, r3, r4
4830 ; CHECK-P8-NEXT: ori r4, r6, 41712
4831 ; CHECK-P8-NEXT: mffprwz r5, f0
4832 ; CHECK-P8-NEXT: sthx r5, r3, r4
4833 ; CHECK-P8-NEXT: blr
4835 %and = and i64 %ptr, -1000341504
4836 %conv = fptoui float %str to i16
4837 %or = or i64 %and, 999990000
4838 %0 = inttoptr i64 %or to i16*
4839 store i16 %conv, i16* %0, align 16
4843 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4844 define dso_local void @st_not_disjoint64_float_uint16_t(i64 %ptr, float %str) {
4845 ; CHECK-P10-LABEL: st_not_disjoint64_float_uint16_t:
4846 ; CHECK-P10: # %bb.0: # %entry
4847 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
4848 ; CHECK-P10-NEXT: pli r4, 232
4849 ; CHECK-P10-NEXT: pli r5, 3567587329
4850 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
4851 ; CHECK-P10-NEXT: or r3, r3, r5
4852 ; CHECK-P10-NEXT: stxsihx f0, 0, r3
4853 ; CHECK-P10-NEXT: blr
4855 ; CHECK-P9-LABEL: st_not_disjoint64_float_uint16_t:
4856 ; CHECK-P9: # %bb.0: # %entry
4857 ; CHECK-P9-NEXT: li r4, 29
4858 ; CHECK-P9-NEXT: xscvdpuxws f0, f1
4859 ; CHECK-P9-NEXT: rldic r4, r4, 35, 24
4860 ; CHECK-P9-NEXT: oris r4, r4, 54437
4861 ; CHECK-P9-NEXT: ori r4, r4, 4097
4862 ; CHECK-P9-NEXT: or r3, r3, r4
4863 ; CHECK-P9-NEXT: stxsihx f0, 0, r3
4864 ; CHECK-P9-NEXT: blr
4866 ; CHECK-P8-LABEL: st_not_disjoint64_float_uint16_t:
4867 ; CHECK-P8: # %bb.0: # %entry
4868 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4869 ; CHECK-P8-NEXT: li r4, 29
4870 ; CHECK-P8-NEXT: rldic r4, r4, 35, 24
4871 ; CHECK-P8-NEXT: oris r4, r4, 54437
4872 ; CHECK-P8-NEXT: ori r4, r4, 4097
4873 ; CHECK-P8-NEXT: or r3, r3, r4
4874 ; CHECK-P8-NEXT: mffprwz r5, f0
4875 ; CHECK-P8-NEXT: sth r5, 0(r3)
4876 ; CHECK-P8-NEXT: blr
4878 %conv = fptoui float %str to i16
4879 %or = or i64 %ptr, 1000000000001
4880 %0 = inttoptr i64 %or to i16*
4881 store i16 %conv, i16* %0, align 2
4885 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4886 define dso_local void @st_disjoint_align64_float_uint16_t(i64 %ptr, float %str) {
4887 ; CHECK-P10-LABEL: st_disjoint_align64_float_uint16_t:
4888 ; CHECK-P10: # %bb.0: # %entry
4889 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
4890 ; CHECK-P10-NEXT: pli r4, 244140625
4891 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
4892 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
4893 ; CHECK-P10-NEXT: stxsihx f0, r3, r4
4894 ; CHECK-P10-NEXT: blr
4896 ; CHECK-P9-LABEL: st_disjoint_align64_float_uint16_t:
4897 ; CHECK-P9: # %bb.0: # %entry
4898 ; CHECK-P9-NEXT: xscvdpuxws f0, f1
4899 ; CHECK-P9-NEXT: lis r4, 3725
4900 ; CHECK-P9-NEXT: rldicr r3, r3, 0, 23
4901 ; CHECK-P9-NEXT: ori r4, r4, 19025
4902 ; CHECK-P9-NEXT: rldic r4, r4, 12, 24
4903 ; CHECK-P9-NEXT: stxsihx f0, r3, r4
4904 ; CHECK-P9-NEXT: blr
4906 ; CHECK-P8-LABEL: st_disjoint_align64_float_uint16_t:
4907 ; CHECK-P8: # %bb.0: # %entry
4908 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4909 ; CHECK-P8-NEXT: lis r4, 3725
4910 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 23
4911 ; CHECK-P8-NEXT: ori r4, r4, 19025
4912 ; CHECK-P8-NEXT: rldic r4, r4, 12, 24
4913 ; CHECK-P8-NEXT: mffprwz r5, f0
4914 ; CHECK-P8-NEXT: sthx r5, r3, r4
4915 ; CHECK-P8-NEXT: blr
4917 %and = and i64 %ptr, -1099511627776
4918 %conv = fptoui float %str to i16
4919 %or = or i64 %and, 1000000000000
4920 %0 = inttoptr i64 %or to i16*
4921 store i16 %conv, i16* %0, align 4096
4925 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4926 define dso_local void @st_cst_align16_float_uint16_t(float %str) {
4927 ; CHECK-POSTP8-LABEL: st_cst_align16_float_uint16_t:
4928 ; CHECK-POSTP8: # %bb.0: # %entry
4929 ; CHECK-POSTP8-NEXT: xscvdpuxws f0, f1
4930 ; CHECK-POSTP8-NEXT: li r3, 4080
4931 ; CHECK-POSTP8-NEXT: stxsihx f0, 0, r3
4932 ; CHECK-POSTP8-NEXT: blr
4934 ; CHECK-P8-LABEL: st_cst_align16_float_uint16_t:
4935 ; CHECK-P8: # %bb.0: # %entry
4936 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4937 ; CHECK-P8-NEXT: mffprwz r3, f0
4938 ; CHECK-P8-NEXT: sth r3, 4080(0)
4939 ; CHECK-P8-NEXT: blr
4941 %conv = fptoui float %str to i16
4942 store i16 %conv, i16* inttoptr (i64 4080 to i16*), align 16
4946 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4947 define dso_local void @st_cst_align32_float_uint16_t(float %str) {
4948 ; CHECK-P10-LABEL: st_cst_align32_float_uint16_t:
4949 ; CHECK-P10: # %bb.0: # %entry
4950 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
4951 ; CHECK-P10-NEXT: pli r3, 9999900
4952 ; CHECK-P10-NEXT: stxsihx f0, 0, r3
4953 ; CHECK-P10-NEXT: blr
4955 ; CHECK-P9-LABEL: st_cst_align32_float_uint16_t:
4956 ; CHECK-P9: # %bb.0: # %entry
4957 ; CHECK-P9-NEXT: xscvdpuxws f0, f1
4958 ; CHECK-P9-NEXT: lis r3, 152
4959 ; CHECK-P9-NEXT: ori r3, r3, 38428
4960 ; CHECK-P9-NEXT: stxsihx f0, 0, r3
4961 ; CHECK-P9-NEXT: blr
4963 ; CHECK-P8-LABEL: st_cst_align32_float_uint16_t:
4964 ; CHECK-P8: # %bb.0: # %entry
4965 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4966 ; CHECK-P8-NEXT: lis r4, 153
4967 ; CHECK-P8-NEXT: mffprwz r3, f0
4968 ; CHECK-P8-NEXT: sth r3, -27108(r4)
4969 ; CHECK-P8-NEXT: blr
4971 %conv = fptoui float %str to i16
4972 store i16 %conv, i16* inttoptr (i64 9999900 to i16*), align 4
4976 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
4977 define dso_local void @st_cst_align64_float_uint16_t(float %str) {
4978 ; CHECK-P10-LABEL: st_cst_align64_float_uint16_t:
4979 ; CHECK-P10: # %bb.0: # %entry
4980 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
4981 ; CHECK-P10-NEXT: pli r3, 244140625
4982 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
4983 ; CHECK-P10-NEXT: stxsihx f0, 0, r3
4984 ; CHECK-P10-NEXT: blr
4986 ; CHECK-P9-LABEL: st_cst_align64_float_uint16_t:
4987 ; CHECK-P9: # %bb.0: # %entry
4988 ; CHECK-P9-NEXT: xscvdpuxws f0, f1
4989 ; CHECK-P9-NEXT: lis r3, 3725
4990 ; CHECK-P9-NEXT: ori r3, r3, 19025
4991 ; CHECK-P9-NEXT: rldic r3, r3, 12, 24
4992 ; CHECK-P9-NEXT: stxsihx f0, 0, r3
4993 ; CHECK-P9-NEXT: blr
4995 ; CHECK-P8-LABEL: st_cst_align64_float_uint16_t:
4996 ; CHECK-P8: # %bb.0: # %entry
4997 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
4998 ; CHECK-P8-NEXT: lis r3, 3725
4999 ; CHECK-P8-NEXT: ori r3, r3, 19025
5000 ; CHECK-P8-NEXT: rldic r3, r3, 12, 24
5001 ; CHECK-P8-NEXT: mffprwz r4, f0
5002 ; CHECK-P8-NEXT: sth r4, 0(r3)
5003 ; CHECK-P8-NEXT: blr
5005 %conv = fptoui float %str to i16
5006 store i16 %conv, i16* inttoptr (i64 1000000000000 to i16*), align 4096
5010 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5011 define dso_local void @st_0_float_int16_t(i64 %ptr, float %str) {
5012 ; CHECK-POSTP8-LABEL: st_0_float_int16_t:
5013 ; CHECK-POSTP8: # %bb.0: # %entry
5014 ; CHECK-POSTP8-NEXT: xscvdpsxws f0, f1
5015 ; CHECK-POSTP8-NEXT: stxsihx f0, 0, r3
5016 ; CHECK-POSTP8-NEXT: blr
5018 ; CHECK-P8-LABEL: st_0_float_int16_t:
5019 ; CHECK-P8: # %bb.0: # %entry
5020 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
5021 ; CHECK-P8-NEXT: mffprwz r4, f0
5022 ; CHECK-P8-NEXT: sth r4, 0(r3)
5023 ; CHECK-P8-NEXT: blr
5025 %conv = fptosi float %str to i16
5026 %0 = inttoptr i64 %ptr to i16*
5027 store i16 %conv, i16* %0, align 2
5031 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5032 define dso_local void @st_align16_float_int16_t(i8* nocapture %ptr, float %str) {
5033 ; CHECK-POSTP8-LABEL: st_align16_float_int16_t:
5034 ; CHECK-POSTP8: # %bb.0: # %entry
5035 ; CHECK-POSTP8-NEXT: xscvdpsxws f0, f1
5036 ; CHECK-POSTP8-NEXT: addi r3, r3, 8
5037 ; CHECK-POSTP8-NEXT: stxsihx f0, 0, r3
5038 ; CHECK-POSTP8-NEXT: blr
5040 ; CHECK-P8-LABEL: st_align16_float_int16_t:
5041 ; CHECK-P8: # %bb.0: # %entry
5042 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
5043 ; CHECK-P8-NEXT: mffprwz r4, f0
5044 ; CHECK-P8-NEXT: sth r4, 8(r3)
5045 ; CHECK-P8-NEXT: blr
5047 %conv = fptosi float %str to i16
5048 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
5049 %0 = bitcast i8* %add.ptr to i16*
5050 store i16 %conv, i16* %0, align 2
5054 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5055 define dso_local void @st_align32_float_int16_t(i8* nocapture %ptr, float %str) {
5056 ; CHECK-P10-LABEL: st_align32_float_int16_t:
5057 ; CHECK-P10: # %bb.0: # %entry
5058 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
5059 ; CHECK-P10-NEXT: pli r4, 99999000
5060 ; CHECK-P10-NEXT: stxsihx f0, r3, r4
5061 ; CHECK-P10-NEXT: blr
5063 ; CHECK-P9-LABEL: st_align32_float_int16_t:
5064 ; CHECK-P9: # %bb.0: # %entry
5065 ; CHECK-P9-NEXT: xscvdpsxws f0, f1
5066 ; CHECK-P9-NEXT: lis r4, 1525
5067 ; CHECK-P9-NEXT: ori r4, r4, 56600
5068 ; CHECK-P9-NEXT: stxsihx f0, r3, r4
5069 ; CHECK-P9-NEXT: blr
5071 ; CHECK-P8-LABEL: st_align32_float_int16_t:
5072 ; CHECK-P8: # %bb.0: # %entry
5073 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
5074 ; CHECK-P8-NEXT: lis r4, 1525
5075 ; CHECK-P8-NEXT: ori r4, r4, 56600
5076 ; CHECK-P8-NEXT: mffprwz r5, f0
5077 ; CHECK-P8-NEXT: sthx r5, r3, r4
5078 ; CHECK-P8-NEXT: blr
5080 %conv = fptosi float %str to i16
5081 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
5082 %0 = bitcast i8* %add.ptr to i16*
5083 store i16 %conv, i16* %0, align 2
5087 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5088 define dso_local void @st_align64_float_int16_t(i8* nocapture %ptr, float %str) {
5089 ; CHECK-P10-LABEL: st_align64_float_int16_t:
5090 ; CHECK-P10: # %bb.0: # %entry
5091 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
5092 ; CHECK-P10-NEXT: pli r4, 244140625
5093 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
5094 ; CHECK-P10-NEXT: stxsihx f0, r3, r4
5095 ; CHECK-P10-NEXT: blr
5097 ; CHECK-P9-LABEL: st_align64_float_int16_t:
5098 ; CHECK-P9: # %bb.0: # %entry
5099 ; CHECK-P9-NEXT: xscvdpsxws f0, f1
5100 ; CHECK-P9-NEXT: lis r4, 3725
5101 ; CHECK-P9-NEXT: ori r4, r4, 19025
5102 ; CHECK-P9-NEXT: rldic r4, r4, 12, 24
5103 ; CHECK-P9-NEXT: stxsihx f0, r3, r4
5104 ; CHECK-P9-NEXT: blr
5106 ; CHECK-P8-LABEL: st_align64_float_int16_t:
5107 ; CHECK-P8: # %bb.0: # %entry
5108 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
5109 ; CHECK-P8-NEXT: lis r4, 3725
5110 ; CHECK-P8-NEXT: ori r4, r4, 19025
5111 ; CHECK-P8-NEXT: rldic r4, r4, 12, 24
5112 ; CHECK-P8-NEXT: mffprwz r5, f0
5113 ; CHECK-P8-NEXT: sthx r5, r3, r4
5114 ; CHECK-P8-NEXT: blr
5116 %conv = fptosi float %str to i16
5117 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
5118 %0 = bitcast i8* %add.ptr to i16*
5119 store i16 %conv, i16* %0, align 2
5123 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5124 define dso_local void @st_reg_float_int16_t(i8* nocapture %ptr, i64 %off, float %str) {
5125 ; CHECK-POSTP8-LABEL: st_reg_float_int16_t:
5126 ; CHECK-POSTP8: # %bb.0: # %entry
5127 ; CHECK-POSTP8-NEXT: xscvdpsxws f0, f1
5128 ; CHECK-POSTP8-NEXT: stxsihx f0, r3, r4
5129 ; CHECK-POSTP8-NEXT: blr
5131 ; CHECK-P8-LABEL: st_reg_float_int16_t:
5132 ; CHECK-P8: # %bb.0: # %entry
5133 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
5134 ; CHECK-P8-NEXT: mffprwz r5, f0
5135 ; CHECK-P8-NEXT: sthx r5, r3, r4
5136 ; CHECK-P8-NEXT: blr
5138 %conv = fptosi float %str to i16
5139 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
5140 %0 = bitcast i8* %add.ptr to i16*
5141 store i16 %conv, i16* %0, align 2
5145 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5146 define dso_local void @st_or1_float_int16_t(i64 %ptr, i8 zeroext %off, float %str) {
5147 ; CHECK-POSTP8-LABEL: st_or1_float_int16_t:
5148 ; CHECK-POSTP8: # %bb.0: # %entry
5149 ; CHECK-POSTP8-NEXT: xscvdpsxws f0, f1
5150 ; CHECK-POSTP8-NEXT: or r3, r4, r3
5151 ; CHECK-POSTP8-NEXT: stxsihx f0, 0, r3
5152 ; CHECK-POSTP8-NEXT: blr
5154 ; CHECK-P8-LABEL: st_or1_float_int16_t:
5155 ; CHECK-P8: # %bb.0: # %entry
5156 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
5157 ; CHECK-P8-NEXT: or r3, r4, r3
5158 ; CHECK-P8-NEXT: mffprwz r5, f0
5159 ; CHECK-P8-NEXT: sth r5, 0(r3)
5160 ; CHECK-P8-NEXT: blr
5162 %conv = fptosi float %str to i16
5163 %conv1 = zext i8 %off to i64
5164 %or = or i64 %conv1, %ptr
5165 %0 = inttoptr i64 %or to i16*
5166 store i16 %conv, i16* %0, align 2
5170 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5171 define dso_local void @st_not_disjoint16_float_int16_t(i64 %ptr, float %str) {
5172 ; CHECK-POSTP8-LABEL: st_not_disjoint16_float_int16_t:
5173 ; CHECK-POSTP8: # %bb.0: # %entry
5174 ; CHECK-POSTP8-NEXT: xscvdpsxws f0, f1
5175 ; CHECK-POSTP8-NEXT: ori r3, r3, 6
5176 ; CHECK-POSTP8-NEXT: stxsihx f0, 0, r3
5177 ; CHECK-POSTP8-NEXT: blr
5179 ; CHECK-P8-LABEL: st_not_disjoint16_float_int16_t:
5180 ; CHECK-P8: # %bb.0: # %entry
5181 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
5182 ; CHECK-P8-NEXT: ori r3, r3, 6
5183 ; CHECK-P8-NEXT: mffprwz r4, f0
5184 ; CHECK-P8-NEXT: sth r4, 0(r3)
5185 ; CHECK-P8-NEXT: blr
5187 %conv = fptosi float %str to i16
5188 %or = or i64 %ptr, 6
5189 %0 = inttoptr i64 %or to i16*
5190 store i16 %conv, i16* %0, align 2
5194 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5195 define dso_local void @st_disjoint_align16_float_int16_t(i64 %ptr, float %str) {
5196 ; CHECK-POSTP8-LABEL: st_disjoint_align16_float_int16_t:
5197 ; CHECK-POSTP8: # %bb.0: # %entry
5198 ; CHECK-POSTP8-NEXT: xscvdpsxws f0, f1
5199 ; CHECK-POSTP8-NEXT: rldicr r3, r3, 0, 51
5200 ; CHECK-POSTP8-NEXT: ori r3, r3, 24
5201 ; CHECK-POSTP8-NEXT: stxsihx f0, 0, r3
5202 ; CHECK-POSTP8-NEXT: blr
5204 ; CHECK-P8-LABEL: st_disjoint_align16_float_int16_t:
5205 ; CHECK-P8: # %bb.0: # %entry
5206 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
5207 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 51
5208 ; CHECK-P8-NEXT: mffprwz r4, f0
5209 ; CHECK-P8-NEXT: sth r4, 24(r3)
5210 ; CHECK-P8-NEXT: blr
5212 %and = and i64 %ptr, -4096
5213 %conv = fptosi float %str to i16
5214 %or = or i64 %and, 24
5215 %0 = inttoptr i64 %or to i16*
5216 store i16 %conv, i16* %0, align 8
5220 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5221 define dso_local void @st_not_disjoint32_float_int16_t(i64 %ptr, float %str) {
5222 ; CHECK-POSTP8-LABEL: st_not_disjoint32_float_int16_t:
5223 ; CHECK-POSTP8: # %bb.0: # %entry
5224 ; CHECK-POSTP8-NEXT: xscvdpsxws f0, f1
5225 ; CHECK-POSTP8-NEXT: ori r3, r3, 34463
5226 ; CHECK-POSTP8-NEXT: oris r3, r3, 1
5227 ; CHECK-POSTP8-NEXT: stxsihx f0, 0, r3
5228 ; CHECK-POSTP8-NEXT: blr
5230 ; CHECK-P8-LABEL: st_not_disjoint32_float_int16_t:
5231 ; CHECK-P8: # %bb.0: # %entry
5232 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
5233 ; CHECK-P8-NEXT: ori r3, r3, 34463
5234 ; CHECK-P8-NEXT: oris r3, r3, 1
5235 ; CHECK-P8-NEXT: mffprwz r4, f0
5236 ; CHECK-P8-NEXT: sth r4, 0(r3)
5237 ; CHECK-P8-NEXT: blr
5239 %conv = fptosi float %str to i16
5240 %or = or i64 %ptr, 99999
5241 %0 = inttoptr i64 %or to i16*
5242 store i16 %conv, i16* %0, align 2
5246 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5247 define dso_local void @st_disjoint_align32_float_int16_t(i64 %ptr, float %str) {
5248 ; CHECK-P10-LABEL: st_disjoint_align32_float_int16_t:
5249 ; CHECK-P10: # %bb.0: # %entry
5250 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
5251 ; CHECK-P10-NEXT: lis r4, -15264
5252 ; CHECK-P10-NEXT: and r3, r3, r4
5253 ; CHECK-P10-NEXT: pli r4, 999990000
5254 ; CHECK-P10-NEXT: stxsihx f0, r3, r4
5255 ; CHECK-P10-NEXT: blr
5257 ; CHECK-P9-LABEL: st_disjoint_align32_float_int16_t:
5258 ; CHECK-P9: # %bb.0: # %entry
5259 ; CHECK-P9-NEXT: xscvdpsxws f0, f1
5260 ; CHECK-P9-NEXT: lis r4, -15264
5261 ; CHECK-P9-NEXT: and r3, r3, r4
5262 ; CHECK-P9-NEXT: lis r4, 15258
5263 ; CHECK-P9-NEXT: ori r4, r4, 41712
5264 ; CHECK-P9-NEXT: stxsihx f0, r3, r4
5265 ; CHECK-P9-NEXT: blr
5267 ; CHECK-P8-LABEL: st_disjoint_align32_float_int16_t:
5268 ; CHECK-P8: # %bb.0: # %entry
5269 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
5270 ; CHECK-P8-NEXT: lis r4, -15264
5271 ; CHECK-P8-NEXT: lis r6, 15258
5272 ; CHECK-P8-NEXT: and r3, r3, r4
5273 ; CHECK-P8-NEXT: ori r4, r6, 41712
5274 ; CHECK-P8-NEXT: mffprwz r5, f0
5275 ; CHECK-P8-NEXT: sthx r5, r3, r4
5276 ; CHECK-P8-NEXT: blr
5278 %and = and i64 %ptr, -1000341504
5279 %conv = fptosi float %str to i16
5280 %or = or i64 %and, 999990000
5281 %0 = inttoptr i64 %or to i16*
5282 store i16 %conv, i16* %0, align 16
5286 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5287 define dso_local void @st_not_disjoint64_float_int16_t(i64 %ptr, float %str) {
5288 ; CHECK-P10-LABEL: st_not_disjoint64_float_int16_t:
5289 ; CHECK-P10: # %bb.0: # %entry
5290 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
5291 ; CHECK-P10-NEXT: pli r4, 232
5292 ; CHECK-P10-NEXT: pli r5, 3567587329
5293 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
5294 ; CHECK-P10-NEXT: or r3, r3, r5
5295 ; CHECK-P10-NEXT: stxsihx f0, 0, r3
5296 ; CHECK-P10-NEXT: blr
5298 ; CHECK-P9-LABEL: st_not_disjoint64_float_int16_t:
5299 ; CHECK-P9: # %bb.0: # %entry
5300 ; CHECK-P9-NEXT: li r4, 29
5301 ; CHECK-P9-NEXT: xscvdpsxws f0, f1
5302 ; CHECK-P9-NEXT: rldic r4, r4, 35, 24
5303 ; CHECK-P9-NEXT: oris r4, r4, 54437
5304 ; CHECK-P9-NEXT: ori r4, r4, 4097
5305 ; CHECK-P9-NEXT: or r3, r3, r4
5306 ; CHECK-P9-NEXT: stxsihx f0, 0, r3
5307 ; CHECK-P9-NEXT: blr
5309 ; CHECK-P8-LABEL: st_not_disjoint64_float_int16_t:
5310 ; CHECK-P8: # %bb.0: # %entry
5311 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
5312 ; CHECK-P8-NEXT: li r4, 29
5313 ; CHECK-P8-NEXT: rldic r4, r4, 35, 24
5314 ; CHECK-P8-NEXT: oris r4, r4, 54437
5315 ; CHECK-P8-NEXT: ori r4, r4, 4097
5316 ; CHECK-P8-NEXT: or r3, r3, r4
5317 ; CHECK-P8-NEXT: mffprwz r5, f0
5318 ; CHECK-P8-NEXT: sth r5, 0(r3)
5319 ; CHECK-P8-NEXT: blr
5321 %conv = fptosi float %str to i16
5322 %or = or i64 %ptr, 1000000000001
5323 %0 = inttoptr i64 %or to i16*
5324 store i16 %conv, i16* %0, align 2
5328 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5329 define dso_local void @st_disjoint_align64_float_int16_t(i64 %ptr, float %str) {
5330 ; CHECK-P10-LABEL: st_disjoint_align64_float_int16_t:
5331 ; CHECK-P10: # %bb.0: # %entry
5332 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
5333 ; CHECK-P10-NEXT: pli r4, 244140625
5334 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
5335 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
5336 ; CHECK-P10-NEXT: stxsihx f0, r3, r4
5337 ; CHECK-P10-NEXT: blr
5339 ; CHECK-P9-LABEL: st_disjoint_align64_float_int16_t:
5340 ; CHECK-P9: # %bb.0: # %entry
5341 ; CHECK-P9-NEXT: xscvdpsxws f0, f1
5342 ; CHECK-P9-NEXT: lis r4, 3725
5343 ; CHECK-P9-NEXT: rldicr r3, r3, 0, 23
5344 ; CHECK-P9-NEXT: ori r4, r4, 19025
5345 ; CHECK-P9-NEXT: rldic r4, r4, 12, 24
5346 ; CHECK-P9-NEXT: stxsihx f0, r3, r4
5347 ; CHECK-P9-NEXT: blr
5349 ; CHECK-P8-LABEL: st_disjoint_align64_float_int16_t:
5350 ; CHECK-P8: # %bb.0: # %entry
5351 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
5352 ; CHECK-P8-NEXT: lis r4, 3725
5353 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 23
5354 ; CHECK-P8-NEXT: ori r4, r4, 19025
5355 ; CHECK-P8-NEXT: rldic r4, r4, 12, 24
5356 ; CHECK-P8-NEXT: mffprwz r5, f0
5357 ; CHECK-P8-NEXT: sthx r5, r3, r4
5358 ; CHECK-P8-NEXT: blr
5360 %and = and i64 %ptr, -1099511627776
5361 %conv = fptosi float %str to i16
5362 %or = or i64 %and, 1000000000000
5363 %0 = inttoptr i64 %or to i16*
5364 store i16 %conv, i16* %0, align 4096
5368 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5369 define dso_local void @st_cst_align16_float_int16_t(float %str) {
5370 ; CHECK-POSTP8-LABEL: st_cst_align16_float_int16_t:
5371 ; CHECK-POSTP8: # %bb.0: # %entry
5372 ; CHECK-POSTP8-NEXT: xscvdpsxws f0, f1
5373 ; CHECK-POSTP8-NEXT: li r3, 4080
5374 ; CHECK-POSTP8-NEXT: stxsihx f0, 0, r3
5375 ; CHECK-POSTP8-NEXT: blr
5377 ; CHECK-P8-LABEL: st_cst_align16_float_int16_t:
5378 ; CHECK-P8: # %bb.0: # %entry
5379 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
5380 ; CHECK-P8-NEXT: mffprwz r3, f0
5381 ; CHECK-P8-NEXT: sth r3, 4080(0)
5382 ; CHECK-P8-NEXT: blr
5384 %conv = fptosi float %str to i16
5385 store i16 %conv, i16* inttoptr (i64 4080 to i16*), align 16
5389 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5390 define dso_local void @st_cst_align32_float_int16_t(float %str) {
5391 ; CHECK-P10-LABEL: st_cst_align32_float_int16_t:
5392 ; CHECK-P10: # %bb.0: # %entry
5393 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
5394 ; CHECK-P10-NEXT: pli r3, 9999900
5395 ; CHECK-P10-NEXT: stxsihx f0, 0, r3
5396 ; CHECK-P10-NEXT: blr
5398 ; CHECK-P9-LABEL: st_cst_align32_float_int16_t:
5399 ; CHECK-P9: # %bb.0: # %entry
5400 ; CHECK-P9-NEXT: xscvdpsxws f0, f1
5401 ; CHECK-P9-NEXT: lis r3, 152
5402 ; CHECK-P9-NEXT: ori r3, r3, 38428
5403 ; CHECK-P9-NEXT: stxsihx f0, 0, r3
5404 ; CHECK-P9-NEXT: blr
5406 ; CHECK-P8-LABEL: st_cst_align32_float_int16_t:
5407 ; CHECK-P8: # %bb.0: # %entry
5408 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
5409 ; CHECK-P8-NEXT: lis r4, 153
5410 ; CHECK-P8-NEXT: mffprwz r3, f0
5411 ; CHECK-P8-NEXT: sth r3, -27108(r4)
5412 ; CHECK-P8-NEXT: blr
5414 %conv = fptosi float %str to i16
5415 store i16 %conv, i16* inttoptr (i64 9999900 to i16*), align 4
5419 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5420 define dso_local void @st_cst_align64_float_int16_t(float %str) {
5421 ; CHECK-P10-LABEL: st_cst_align64_float_int16_t:
5422 ; CHECK-P10: # %bb.0: # %entry
5423 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
5424 ; CHECK-P10-NEXT: pli r3, 244140625
5425 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
5426 ; CHECK-P10-NEXT: stxsihx f0, 0, r3
5427 ; CHECK-P10-NEXT: blr
5429 ; CHECK-P9-LABEL: st_cst_align64_float_int16_t:
5430 ; CHECK-P9: # %bb.0: # %entry
5431 ; CHECK-P9-NEXT: xscvdpsxws f0, f1
5432 ; CHECK-P9-NEXT: lis r3, 3725
5433 ; CHECK-P9-NEXT: ori r3, r3, 19025
5434 ; CHECK-P9-NEXT: rldic r3, r3, 12, 24
5435 ; CHECK-P9-NEXT: stxsihx f0, 0, r3
5436 ; CHECK-P9-NEXT: blr
5438 ; CHECK-P8-LABEL: st_cst_align64_float_int16_t:
5439 ; CHECK-P8: # %bb.0: # %entry
5440 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
5441 ; CHECK-P8-NEXT: lis r3, 3725
5442 ; CHECK-P8-NEXT: ori r3, r3, 19025
5443 ; CHECK-P8-NEXT: rldic r3, r3, 12, 24
5444 ; CHECK-P8-NEXT: mffprwz r4, f0
5445 ; CHECK-P8-NEXT: sth r4, 0(r3)
5446 ; CHECK-P8-NEXT: blr
5448 %conv = fptosi float %str to i16
5449 store i16 %conv, i16* inttoptr (i64 1000000000000 to i16*), align 4096
5453 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5454 define dso_local void @st_0_float_uint32_t(i64 %ptr, float %str) {
5455 ; CHECK-LABEL: st_0_float_uint32_t:
5456 ; CHECK: # %bb.0: # %entry
5457 ; CHECK-NEXT: xscvdpuxws f0, f1
5458 ; CHECK-NEXT: stfiwx f0, 0, r3
5461 %conv = fptoui float %str to i32
5462 %0 = inttoptr i64 %ptr to i32*
5463 store i32 %conv, i32* %0, align 4
5467 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5468 define dso_local void @st_align16_float_uint32_t(i8* nocapture %ptr, float %str) {
5469 ; CHECK-LABEL: st_align16_float_uint32_t:
5470 ; CHECK: # %bb.0: # %entry
5471 ; CHECK-NEXT: xscvdpuxws f0, f1
5472 ; CHECK-NEXT: addi r3, r3, 8
5473 ; CHECK-NEXT: stfiwx f0, 0, r3
5476 %conv = fptoui float %str to i32
5477 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
5478 %0 = bitcast i8* %add.ptr to i32*
5479 store i32 %conv, i32* %0, align 4
5483 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5484 define dso_local void @st_align32_float_uint32_t(i8* nocapture %ptr, float %str) {
5485 ; CHECK-P10-LABEL: st_align32_float_uint32_t:
5486 ; CHECK-P10: # %bb.0: # %entry
5487 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
5488 ; CHECK-P10-NEXT: pli r4, 99999000
5489 ; CHECK-P10-NEXT: stfiwx f0, r3, r4
5490 ; CHECK-P10-NEXT: blr
5492 ; CHECK-PREP10-LABEL: st_align32_float_uint32_t:
5493 ; CHECK-PREP10: # %bb.0: # %entry
5494 ; CHECK-PREP10-NEXT: xscvdpuxws f0, f1
5495 ; CHECK-PREP10-NEXT: lis r4, 1525
5496 ; CHECK-PREP10-NEXT: ori r4, r4, 56600
5497 ; CHECK-PREP10-NEXT: stfiwx f0, r3, r4
5498 ; CHECK-PREP10-NEXT: blr
5500 %conv = fptoui float %str to i32
5501 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
5502 %0 = bitcast i8* %add.ptr to i32*
5503 store i32 %conv, i32* %0, align 4
5507 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5508 define dso_local void @st_align64_float_uint32_t(i8* nocapture %ptr, float %str) {
5509 ; CHECK-P10-LABEL: st_align64_float_uint32_t:
5510 ; CHECK-P10: # %bb.0: # %entry
5511 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
5512 ; CHECK-P10-NEXT: pli r4, 244140625
5513 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
5514 ; CHECK-P10-NEXT: stfiwx f0, r3, r4
5515 ; CHECK-P10-NEXT: blr
5517 ; CHECK-PREP10-LABEL: st_align64_float_uint32_t:
5518 ; CHECK-PREP10: # %bb.0: # %entry
5519 ; CHECK-PREP10-NEXT: xscvdpuxws f0, f1
5520 ; CHECK-PREP10-NEXT: lis r4, 3725
5521 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
5522 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
5523 ; CHECK-PREP10-NEXT: stfiwx f0, r3, r4
5524 ; CHECK-PREP10-NEXT: blr
5526 %conv = fptoui float %str to i32
5527 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
5528 %0 = bitcast i8* %add.ptr to i32*
5529 store i32 %conv, i32* %0, align 4
5533 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5534 define dso_local void @st_reg_float_uint32_t(i8* nocapture %ptr, i64 %off, float %str) {
5535 ; CHECK-LABEL: st_reg_float_uint32_t:
5536 ; CHECK: # %bb.0: # %entry
5537 ; CHECK-NEXT: xscvdpuxws f0, f1
5538 ; CHECK-NEXT: stfiwx f0, r3, r4
5541 %conv = fptoui float %str to i32
5542 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
5543 %0 = bitcast i8* %add.ptr to i32*
5544 store i32 %conv, i32* %0, align 4
5548 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5549 define dso_local void @st_or1_float_uint32_t(i64 %ptr, i8 zeroext %off, float %str) {
5550 ; CHECK-LABEL: st_or1_float_uint32_t:
5551 ; CHECK: # %bb.0: # %entry
5552 ; CHECK-NEXT: xscvdpuxws f0, f1
5553 ; CHECK-NEXT: or r3, r4, r3
5554 ; CHECK-NEXT: stfiwx f0, 0, r3
5557 %conv = fptoui float %str to i32
5558 %conv1 = zext i8 %off to i64
5559 %or = or i64 %conv1, %ptr
5560 %0 = inttoptr i64 %or to i32*
5561 store i32 %conv, i32* %0, align 4
5565 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5566 define dso_local void @st_not_disjoint16_float_uint32_t(i64 %ptr, float %str) {
5567 ; CHECK-LABEL: st_not_disjoint16_float_uint32_t:
5568 ; CHECK: # %bb.0: # %entry
5569 ; CHECK-NEXT: xscvdpuxws f0, f1
5570 ; CHECK-NEXT: ori r3, r3, 6
5571 ; CHECK-NEXT: stfiwx f0, 0, r3
5574 %conv = fptoui float %str to i32
5575 %or = or i64 %ptr, 6
5576 %0 = inttoptr i64 %or to i32*
5577 store i32 %conv, i32* %0, align 4
5581 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5582 define dso_local void @st_disjoint_align16_float_uint32_t(i64 %ptr, float %str) {
5583 ; CHECK-LABEL: st_disjoint_align16_float_uint32_t:
5584 ; CHECK: # %bb.0: # %entry
5585 ; CHECK-NEXT: xscvdpuxws f0, f1
5586 ; CHECK-NEXT: rldicr r3, r3, 0, 51
5587 ; CHECK-NEXT: ori r3, r3, 24
5588 ; CHECK-NEXT: stfiwx f0, 0, r3
5591 %and = and i64 %ptr, -4096
5592 %conv = fptoui float %str to i32
5593 %or = or i64 %and, 24
5594 %0 = inttoptr i64 %or to i32*
5595 store i32 %conv, i32* %0, align 8
5599 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5600 define dso_local void @st_not_disjoint32_float_uint32_t(i64 %ptr, float %str) {
5601 ; CHECK-LABEL: st_not_disjoint32_float_uint32_t:
5602 ; CHECK: # %bb.0: # %entry
5603 ; CHECK-NEXT: xscvdpuxws f0, f1
5604 ; CHECK-NEXT: ori r3, r3, 34463
5605 ; CHECK-NEXT: oris r3, r3, 1
5606 ; CHECK-NEXT: stfiwx f0, 0, r3
5609 %conv = fptoui float %str to i32
5610 %or = or i64 %ptr, 99999
5611 %0 = inttoptr i64 %or to i32*
5612 store i32 %conv, i32* %0, align 4
5616 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5617 define dso_local void @st_disjoint_align32_float_uint32_t(i64 %ptr, float %str) {
5618 ; CHECK-P10-LABEL: st_disjoint_align32_float_uint32_t:
5619 ; CHECK-P10: # %bb.0: # %entry
5620 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
5621 ; CHECK-P10-NEXT: lis r4, -15264
5622 ; CHECK-P10-NEXT: and r3, r3, r4
5623 ; CHECK-P10-NEXT: pli r4, 999990000
5624 ; CHECK-P10-NEXT: stfiwx f0, r3, r4
5625 ; CHECK-P10-NEXT: blr
5627 ; CHECK-P9-LABEL: st_disjoint_align32_float_uint32_t:
5628 ; CHECK-P9: # %bb.0: # %entry
5629 ; CHECK-P9-NEXT: xscvdpuxws f0, f1
5630 ; CHECK-P9-NEXT: lis r4, -15264
5631 ; CHECK-P9-NEXT: and r3, r3, r4
5632 ; CHECK-P9-NEXT: lis r4, 15258
5633 ; CHECK-P9-NEXT: ori r4, r4, 41712
5634 ; CHECK-P9-NEXT: stfiwx f0, r3, r4
5635 ; CHECK-P9-NEXT: blr
5637 ; CHECK-P8-LABEL: st_disjoint_align32_float_uint32_t:
5638 ; CHECK-P8: # %bb.0: # %entry
5639 ; CHECK-P8-NEXT: xscvdpuxws f0, f1
5640 ; CHECK-P8-NEXT: lis r4, -15264
5641 ; CHECK-P8-NEXT: lis r5, 15258
5642 ; CHECK-P8-NEXT: and r3, r3, r4
5643 ; CHECK-P8-NEXT: ori r4, r5, 41712
5644 ; CHECK-P8-NEXT: stfiwx f0, r3, r4
5645 ; CHECK-P8-NEXT: blr
5647 %and = and i64 %ptr, -1000341504
5648 %conv = fptoui float %str to i32
5649 %or = or i64 %and, 999990000
5650 %0 = inttoptr i64 %or to i32*
5651 store i32 %conv, i32* %0, align 16
5655 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5656 define dso_local void @st_not_disjoint64_float_uint32_t(i64 %ptr, float %str) {
5657 ; CHECK-P10-LABEL: st_not_disjoint64_float_uint32_t:
5658 ; CHECK-P10: # %bb.0: # %entry
5659 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
5660 ; CHECK-P10-NEXT: pli r4, 232
5661 ; CHECK-P10-NEXT: pli r5, 3567587329
5662 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
5663 ; CHECK-P10-NEXT: or r3, r3, r5
5664 ; CHECK-P10-NEXT: stfiwx f0, 0, r3
5665 ; CHECK-P10-NEXT: blr
5667 ; CHECK-P9-LABEL: st_not_disjoint64_float_uint32_t:
5668 ; CHECK-P9: # %bb.0: # %entry
5669 ; CHECK-P9-NEXT: li r4, 29
5670 ; CHECK-P9-NEXT: xscvdpuxws f0, f1
5671 ; CHECK-P9-NEXT: rldic r4, r4, 35, 24
5672 ; CHECK-P9-NEXT: oris r4, r4, 54437
5673 ; CHECK-P9-NEXT: ori r4, r4, 4097
5674 ; CHECK-P9-NEXT: or r3, r3, r4
5675 ; CHECK-P9-NEXT: stfiwx f0, 0, r3
5676 ; CHECK-P9-NEXT: blr
5678 ; CHECK-P8-LABEL: st_not_disjoint64_float_uint32_t:
5679 ; CHECK-P8: # %bb.0: # %entry
5680 ; CHECK-P8-NEXT: xscvdpuxws f0, f1
5681 ; CHECK-P8-NEXT: li r4, 29
5682 ; CHECK-P8-NEXT: rldic r4, r4, 35, 24
5683 ; CHECK-P8-NEXT: oris r4, r4, 54437
5684 ; CHECK-P8-NEXT: ori r4, r4, 4097
5685 ; CHECK-P8-NEXT: or r3, r3, r4
5686 ; CHECK-P8-NEXT: stfiwx f0, 0, r3
5687 ; CHECK-P8-NEXT: blr
5689 %conv = fptoui float %str to i32
5690 %or = or i64 %ptr, 1000000000001
5691 %0 = inttoptr i64 %or to i32*
5692 store i32 %conv, i32* %0, align 4
5696 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5697 define dso_local void @st_disjoint_align64_float_uint32_t(i64 %ptr, float %str) {
5698 ; CHECK-P10-LABEL: st_disjoint_align64_float_uint32_t:
5699 ; CHECK-P10: # %bb.0: # %entry
5700 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
5701 ; CHECK-P10-NEXT: pli r4, 244140625
5702 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
5703 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
5704 ; CHECK-P10-NEXT: stfiwx f0, r3, r4
5705 ; CHECK-P10-NEXT: blr
5707 ; CHECK-PREP10-LABEL: st_disjoint_align64_float_uint32_t:
5708 ; CHECK-PREP10: # %bb.0: # %entry
5709 ; CHECK-PREP10-NEXT: xscvdpuxws f0, f1
5710 ; CHECK-PREP10-NEXT: lis r4, 3725
5711 ; CHECK-PREP10-NEXT: rldicr r3, r3, 0, 23
5712 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
5713 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
5714 ; CHECK-PREP10-NEXT: stfiwx f0, r3, r4
5715 ; CHECK-PREP10-NEXT: blr
5717 %and = and i64 %ptr, -1099511627776
5718 %conv = fptoui float %str to i32
5719 %or = or i64 %and, 1000000000000
5720 %0 = inttoptr i64 %or to i32*
5721 store i32 %conv, i32* %0, align 4096
5725 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5726 define dso_local void @st_cst_align16_float_uint32_t(float %str) {
5727 ; CHECK-LABEL: st_cst_align16_float_uint32_t:
5728 ; CHECK: # %bb.0: # %entry
5729 ; CHECK-NEXT: xscvdpuxws f0, f1
5730 ; CHECK-NEXT: li r3, 4080
5731 ; CHECK-NEXT: stfiwx f0, 0, r3
5734 %conv = fptoui float %str to i32
5735 store i32 %conv, i32* inttoptr (i64 4080 to i32*), align 16
5739 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5740 define dso_local void @st_cst_align32_float_uint32_t(float %str) {
5741 ; CHECK-P10-LABEL: st_cst_align32_float_uint32_t:
5742 ; CHECK-P10: # %bb.0: # %entry
5743 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
5744 ; CHECK-P10-NEXT: pli r3, 9999900
5745 ; CHECK-P10-NEXT: stfiwx f0, 0, r3
5746 ; CHECK-P10-NEXT: blr
5748 ; CHECK-PREP10-LABEL: st_cst_align32_float_uint32_t:
5749 ; CHECK-PREP10: # %bb.0: # %entry
5750 ; CHECK-PREP10-NEXT: xscvdpuxws f0, f1
5751 ; CHECK-PREP10-NEXT: lis r3, 152
5752 ; CHECK-PREP10-NEXT: ori r3, r3, 38428
5753 ; CHECK-PREP10-NEXT: stfiwx f0, 0, r3
5754 ; CHECK-PREP10-NEXT: blr
5756 %conv = fptoui float %str to i32
5757 store i32 %conv, i32* inttoptr (i64 9999900 to i32*), align 4
5761 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5762 define dso_local void @st_cst_align64_float_uint32_t(float %str) {
5763 ; CHECK-P10-LABEL: st_cst_align64_float_uint32_t:
5764 ; CHECK-P10: # %bb.0: # %entry
5765 ; CHECK-P10-NEXT: xscvdpuxws f0, f1
5766 ; CHECK-P10-NEXT: pli r3, 244140625
5767 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
5768 ; CHECK-P10-NEXT: stfiwx f0, 0, r3
5769 ; CHECK-P10-NEXT: blr
5771 ; CHECK-PREP10-LABEL: st_cst_align64_float_uint32_t:
5772 ; CHECK-PREP10: # %bb.0: # %entry
5773 ; CHECK-PREP10-NEXT: xscvdpuxws f0, f1
5774 ; CHECK-PREP10-NEXT: lis r3, 3725
5775 ; CHECK-PREP10-NEXT: ori r3, r3, 19025
5776 ; CHECK-PREP10-NEXT: rldic r3, r3, 12, 24
5777 ; CHECK-PREP10-NEXT: stfiwx f0, 0, r3
5778 ; CHECK-PREP10-NEXT: blr
5780 %conv = fptoui float %str to i32
5781 store i32 %conv, i32* inttoptr (i64 1000000000000 to i32*), align 4096
5785 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5786 define dso_local void @st_0_float_int32_t(i64 %ptr, float %str) {
5787 ; CHECK-LABEL: st_0_float_int32_t:
5788 ; CHECK: # %bb.0: # %entry
5789 ; CHECK-NEXT: xscvdpsxws f0, f1
5790 ; CHECK-NEXT: stfiwx f0, 0, r3
5793 %conv = fptosi float %str to i32
5794 %0 = inttoptr i64 %ptr to i32*
5795 store i32 %conv, i32* %0, align 4
5799 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5800 define dso_local void @st_align16_float_int32_t(i8* nocapture %ptr, float %str) {
5801 ; CHECK-LABEL: st_align16_float_int32_t:
5802 ; CHECK: # %bb.0: # %entry
5803 ; CHECK-NEXT: xscvdpsxws f0, f1
5804 ; CHECK-NEXT: addi r3, r3, 8
5805 ; CHECK-NEXT: stfiwx f0, 0, r3
5808 %conv = fptosi float %str to i32
5809 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
5810 %0 = bitcast i8* %add.ptr to i32*
5811 store i32 %conv, i32* %0, align 4
5815 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5816 define dso_local void @st_align32_float_int32_t(i8* nocapture %ptr, float %str) {
5817 ; CHECK-P10-LABEL: st_align32_float_int32_t:
5818 ; CHECK-P10: # %bb.0: # %entry
5819 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
5820 ; CHECK-P10-NEXT: pli r4, 99999000
5821 ; CHECK-P10-NEXT: stfiwx f0, r3, r4
5822 ; CHECK-P10-NEXT: blr
5824 ; CHECK-PREP10-LABEL: st_align32_float_int32_t:
5825 ; CHECK-PREP10: # %bb.0: # %entry
5826 ; CHECK-PREP10-NEXT: xscvdpsxws f0, f1
5827 ; CHECK-PREP10-NEXT: lis r4, 1525
5828 ; CHECK-PREP10-NEXT: ori r4, r4, 56600
5829 ; CHECK-PREP10-NEXT: stfiwx f0, r3, r4
5830 ; CHECK-PREP10-NEXT: blr
5832 %conv = fptosi float %str to i32
5833 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
5834 %0 = bitcast i8* %add.ptr to i32*
5835 store i32 %conv, i32* %0, align 4
5839 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5840 define dso_local void @st_align64_float_int32_t(i8* nocapture %ptr, float %str) {
5841 ; CHECK-P10-LABEL: st_align64_float_int32_t:
5842 ; CHECK-P10: # %bb.0: # %entry
5843 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
5844 ; CHECK-P10-NEXT: pli r4, 244140625
5845 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
5846 ; CHECK-P10-NEXT: stfiwx f0, r3, r4
5847 ; CHECK-P10-NEXT: blr
5849 ; CHECK-PREP10-LABEL: st_align64_float_int32_t:
5850 ; CHECK-PREP10: # %bb.0: # %entry
5851 ; CHECK-PREP10-NEXT: xscvdpsxws f0, f1
5852 ; CHECK-PREP10-NEXT: lis r4, 3725
5853 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
5854 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
5855 ; CHECK-PREP10-NEXT: stfiwx f0, r3, r4
5856 ; CHECK-PREP10-NEXT: blr
5858 %conv = fptosi float %str to i32
5859 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
5860 %0 = bitcast i8* %add.ptr to i32*
5861 store i32 %conv, i32* %0, align 4
5865 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5866 define dso_local void @st_reg_float_int32_t(i8* nocapture %ptr, i64 %off, float %str) {
5867 ; CHECK-LABEL: st_reg_float_int32_t:
5868 ; CHECK: # %bb.0: # %entry
5869 ; CHECK-NEXT: xscvdpsxws f0, f1
5870 ; CHECK-NEXT: stfiwx f0, r3, r4
5873 %conv = fptosi float %str to i32
5874 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
5875 %0 = bitcast i8* %add.ptr to i32*
5876 store i32 %conv, i32* %0, align 4
5880 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5881 define dso_local void @st_or1_float_int32_t(i64 %ptr, i8 zeroext %off, float %str) {
5882 ; CHECK-LABEL: st_or1_float_int32_t:
5883 ; CHECK: # %bb.0: # %entry
5884 ; CHECK-NEXT: xscvdpsxws f0, f1
5885 ; CHECK-NEXT: or r3, r4, r3
5886 ; CHECK-NEXT: stfiwx f0, 0, r3
5889 %conv = fptosi float %str to i32
5890 %conv1 = zext i8 %off to i64
5891 %or = or i64 %conv1, %ptr
5892 %0 = inttoptr i64 %or to i32*
5893 store i32 %conv, i32* %0, align 4
5897 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5898 define dso_local void @st_not_disjoint16_float_int32_t(i64 %ptr, float %str) {
5899 ; CHECK-LABEL: st_not_disjoint16_float_int32_t:
5900 ; CHECK: # %bb.0: # %entry
5901 ; CHECK-NEXT: xscvdpsxws f0, f1
5902 ; CHECK-NEXT: ori r3, r3, 6
5903 ; CHECK-NEXT: stfiwx f0, 0, r3
5906 %conv = fptosi float %str to i32
5907 %or = or i64 %ptr, 6
5908 %0 = inttoptr i64 %or to i32*
5909 store i32 %conv, i32* %0, align 4
5913 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5914 define dso_local void @st_disjoint_align16_float_int32_t(i64 %ptr, float %str) {
5915 ; CHECK-LABEL: st_disjoint_align16_float_int32_t:
5916 ; CHECK: # %bb.0: # %entry
5917 ; CHECK-NEXT: xscvdpsxws f0, f1
5918 ; CHECK-NEXT: rldicr r3, r3, 0, 51
5919 ; CHECK-NEXT: ori r3, r3, 24
5920 ; CHECK-NEXT: stfiwx f0, 0, r3
5923 %and = and i64 %ptr, -4096
5924 %conv = fptosi float %str to i32
5925 %or = or i64 %and, 24
5926 %0 = inttoptr i64 %or to i32*
5927 store i32 %conv, i32* %0, align 8
5931 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5932 define dso_local void @st_not_disjoint32_float_int32_t(i64 %ptr, float %str) {
5933 ; CHECK-LABEL: st_not_disjoint32_float_int32_t:
5934 ; CHECK: # %bb.0: # %entry
5935 ; CHECK-NEXT: xscvdpsxws f0, f1
5936 ; CHECK-NEXT: ori r3, r3, 34463
5937 ; CHECK-NEXT: oris r3, r3, 1
5938 ; CHECK-NEXT: stfiwx f0, 0, r3
5941 %conv = fptosi float %str to i32
5942 %or = or i64 %ptr, 99999
5943 %0 = inttoptr i64 %or to i32*
5944 store i32 %conv, i32* %0, align 4
5948 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5949 define dso_local void @st_disjoint_align32_float_int32_t(i64 %ptr, float %str) {
5950 ; CHECK-P10-LABEL: st_disjoint_align32_float_int32_t:
5951 ; CHECK-P10: # %bb.0: # %entry
5952 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
5953 ; CHECK-P10-NEXT: lis r4, -15264
5954 ; CHECK-P10-NEXT: and r3, r3, r4
5955 ; CHECK-P10-NEXT: pli r4, 999990000
5956 ; CHECK-P10-NEXT: stfiwx f0, r3, r4
5957 ; CHECK-P10-NEXT: blr
5959 ; CHECK-P9-LABEL: st_disjoint_align32_float_int32_t:
5960 ; CHECK-P9: # %bb.0: # %entry
5961 ; CHECK-P9-NEXT: xscvdpsxws f0, f1
5962 ; CHECK-P9-NEXT: lis r4, -15264
5963 ; CHECK-P9-NEXT: and r3, r3, r4
5964 ; CHECK-P9-NEXT: lis r4, 15258
5965 ; CHECK-P9-NEXT: ori r4, r4, 41712
5966 ; CHECK-P9-NEXT: stfiwx f0, r3, r4
5967 ; CHECK-P9-NEXT: blr
5969 ; CHECK-P8-LABEL: st_disjoint_align32_float_int32_t:
5970 ; CHECK-P8: # %bb.0: # %entry
5971 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
5972 ; CHECK-P8-NEXT: lis r4, -15264
5973 ; CHECK-P8-NEXT: lis r5, 15258
5974 ; CHECK-P8-NEXT: and r3, r3, r4
5975 ; CHECK-P8-NEXT: ori r4, r5, 41712
5976 ; CHECK-P8-NEXT: stfiwx f0, r3, r4
5977 ; CHECK-P8-NEXT: blr
5979 %and = and i64 %ptr, -1000341504
5980 %conv = fptosi float %str to i32
5981 %or = or i64 %and, 999990000
5982 %0 = inttoptr i64 %or to i32*
5983 store i32 %conv, i32* %0, align 16
5987 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
5988 define dso_local void @st_not_disjoint64_float_int32_t(i64 %ptr, float %str) {
5989 ; CHECK-P10-LABEL: st_not_disjoint64_float_int32_t:
5990 ; CHECK-P10: # %bb.0: # %entry
5991 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
5992 ; CHECK-P10-NEXT: pli r4, 232
5993 ; CHECK-P10-NEXT: pli r5, 3567587329
5994 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
5995 ; CHECK-P10-NEXT: or r3, r3, r5
5996 ; CHECK-P10-NEXT: stfiwx f0, 0, r3
5997 ; CHECK-P10-NEXT: blr
5999 ; CHECK-P9-LABEL: st_not_disjoint64_float_int32_t:
6000 ; CHECK-P9: # %bb.0: # %entry
6001 ; CHECK-P9-NEXT: li r4, 29
6002 ; CHECK-P9-NEXT: xscvdpsxws f0, f1
6003 ; CHECK-P9-NEXT: rldic r4, r4, 35, 24
6004 ; CHECK-P9-NEXT: oris r4, r4, 54437
6005 ; CHECK-P9-NEXT: ori r4, r4, 4097
6006 ; CHECK-P9-NEXT: or r3, r3, r4
6007 ; CHECK-P9-NEXT: stfiwx f0, 0, r3
6008 ; CHECK-P9-NEXT: blr
6010 ; CHECK-P8-LABEL: st_not_disjoint64_float_int32_t:
6011 ; CHECK-P8: # %bb.0: # %entry
6012 ; CHECK-P8-NEXT: xscvdpsxws f0, f1
6013 ; CHECK-P8-NEXT: li r4, 29
6014 ; CHECK-P8-NEXT: rldic r4, r4, 35, 24
6015 ; CHECK-P8-NEXT: oris r4, r4, 54437
6016 ; CHECK-P8-NEXT: ori r4, r4, 4097
6017 ; CHECK-P8-NEXT: or r3, r3, r4
6018 ; CHECK-P8-NEXT: stfiwx f0, 0, r3
6019 ; CHECK-P8-NEXT: blr
6021 %conv = fptosi float %str to i32
6022 %or = or i64 %ptr, 1000000000001
6023 %0 = inttoptr i64 %or to i32*
6024 store i32 %conv, i32* %0, align 4
6028 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6029 define dso_local void @st_disjoint_align64_float_int32_t(i64 %ptr, float %str) {
6030 ; CHECK-P10-LABEL: st_disjoint_align64_float_int32_t:
6031 ; CHECK-P10: # %bb.0: # %entry
6032 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
6033 ; CHECK-P10-NEXT: pli r4, 244140625
6034 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
6035 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
6036 ; CHECK-P10-NEXT: stfiwx f0, r3, r4
6037 ; CHECK-P10-NEXT: blr
6039 ; CHECK-PREP10-LABEL: st_disjoint_align64_float_int32_t:
6040 ; CHECK-PREP10: # %bb.0: # %entry
6041 ; CHECK-PREP10-NEXT: xscvdpsxws f0, f1
6042 ; CHECK-PREP10-NEXT: lis r4, 3725
6043 ; CHECK-PREP10-NEXT: rldicr r3, r3, 0, 23
6044 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
6045 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
6046 ; CHECK-PREP10-NEXT: stfiwx f0, r3, r4
6047 ; CHECK-PREP10-NEXT: blr
6049 %and = and i64 %ptr, -1099511627776
6050 %conv = fptosi float %str to i32
6051 %or = or i64 %and, 1000000000000
6052 %0 = inttoptr i64 %or to i32*
6053 store i32 %conv, i32* %0, align 4096
6057 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6058 define dso_local void @st_cst_align16_float_int32_t(float %str) {
6059 ; CHECK-LABEL: st_cst_align16_float_int32_t:
6060 ; CHECK: # %bb.0: # %entry
6061 ; CHECK-NEXT: xscvdpsxws f0, f1
6062 ; CHECK-NEXT: li r3, 4080
6063 ; CHECK-NEXT: stfiwx f0, 0, r3
6066 %conv = fptosi float %str to i32
6067 store i32 %conv, i32* inttoptr (i64 4080 to i32*), align 16
6071 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6072 define dso_local void @st_cst_align32_float_int32_t(float %str) {
6073 ; CHECK-P10-LABEL: st_cst_align32_float_int32_t:
6074 ; CHECK-P10: # %bb.0: # %entry
6075 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
6076 ; CHECK-P10-NEXT: pli r3, 9999900
6077 ; CHECK-P10-NEXT: stfiwx f0, 0, r3
6078 ; CHECK-P10-NEXT: blr
6080 ; CHECK-PREP10-LABEL: st_cst_align32_float_int32_t:
6081 ; CHECK-PREP10: # %bb.0: # %entry
6082 ; CHECK-PREP10-NEXT: xscvdpsxws f0, f1
6083 ; CHECK-PREP10-NEXT: lis r3, 152
6084 ; CHECK-PREP10-NEXT: ori r3, r3, 38428
6085 ; CHECK-PREP10-NEXT: stfiwx f0, 0, r3
6086 ; CHECK-PREP10-NEXT: blr
6088 %conv = fptosi float %str to i32
6089 store i32 %conv, i32* inttoptr (i64 9999900 to i32*), align 4
6093 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6094 define dso_local void @st_cst_align64_float_int32_t(float %str) {
6095 ; CHECK-P10-LABEL: st_cst_align64_float_int32_t:
6096 ; CHECK-P10: # %bb.0: # %entry
6097 ; CHECK-P10-NEXT: xscvdpsxws f0, f1
6098 ; CHECK-P10-NEXT: pli r3, 244140625
6099 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
6100 ; CHECK-P10-NEXT: stfiwx f0, 0, r3
6101 ; CHECK-P10-NEXT: blr
6103 ; CHECK-PREP10-LABEL: st_cst_align64_float_int32_t:
6104 ; CHECK-PREP10: # %bb.0: # %entry
6105 ; CHECK-PREP10-NEXT: xscvdpsxws f0, f1
6106 ; CHECK-PREP10-NEXT: lis r3, 3725
6107 ; CHECK-PREP10-NEXT: ori r3, r3, 19025
6108 ; CHECK-PREP10-NEXT: rldic r3, r3, 12, 24
6109 ; CHECK-PREP10-NEXT: stfiwx f0, 0, r3
6110 ; CHECK-PREP10-NEXT: blr
6112 %conv = fptosi float %str to i32
6113 store i32 %conv, i32* inttoptr (i64 1000000000000 to i32*), align 4096
6117 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6118 define dso_local void @st_0_float_uint64_t(i64 %ptr, float %str) {
6119 ; CHECK-POSTP8-LABEL: st_0_float_uint64_t:
6120 ; CHECK-POSTP8: # %bb.0: # %entry
6121 ; CHECK-POSTP8-NEXT: xscvdpuxds v2, f1
6122 ; CHECK-POSTP8-NEXT: stxsd v2, 0(r3)
6123 ; CHECK-POSTP8-NEXT: blr
6125 ; CHECK-P8-LABEL: st_0_float_uint64_t:
6126 ; CHECK-P8: # %bb.0: # %entry
6127 ; CHECK-P8-NEXT: xscvdpuxds f0, f1
6128 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6129 ; CHECK-P8-NEXT: blr
6131 %conv = fptoui float %str to i64
6132 %0 = inttoptr i64 %ptr to i64*
6133 store i64 %conv, i64* %0, align 8
6137 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6138 define dso_local void @st_align16_float_uint64_t(i8* nocapture %ptr, float %str) {
6139 ; CHECK-POSTP8-LABEL: st_align16_float_uint64_t:
6140 ; CHECK-POSTP8: # %bb.0: # %entry
6141 ; CHECK-POSTP8-NEXT: xscvdpuxds v2, f1
6142 ; CHECK-POSTP8-NEXT: stxsd v2, 8(r3)
6143 ; CHECK-POSTP8-NEXT: blr
6145 ; CHECK-P8-LABEL: st_align16_float_uint64_t:
6146 ; CHECK-P8: # %bb.0: # %entry
6147 ; CHECK-P8-NEXT: xscvdpuxds f0, f1
6148 ; CHECK-P8-NEXT: li r4, 8
6149 ; CHECK-P8-NEXT: stxsdx f0, r3, r4
6150 ; CHECK-P8-NEXT: blr
6152 %conv = fptoui float %str to i64
6153 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
6154 %0 = bitcast i8* %add.ptr to i64*
6155 store i64 %conv, i64* %0, align 8
6159 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6160 define dso_local void @st_align32_float_uint64_t(i8* nocapture %ptr, float %str) {
6161 ; CHECK-P10-LABEL: st_align32_float_uint64_t:
6162 ; CHECK-P10: # %bb.0: # %entry
6163 ; CHECK-P10-NEXT: xscvdpuxds f0, f1
6164 ; CHECK-P10-NEXT: pli r4, 99999000
6165 ; CHECK-P10-NEXT: stxsdx f0, r3, r4
6166 ; CHECK-P10-NEXT: blr
6168 ; CHECK-PREP10-LABEL: st_align32_float_uint64_t:
6169 ; CHECK-PREP10: # %bb.0: # %entry
6170 ; CHECK-PREP10-NEXT: xscvdpuxds f0, f1
6171 ; CHECK-PREP10-NEXT: lis r4, 1525
6172 ; CHECK-PREP10-NEXT: ori r4, r4, 56600
6173 ; CHECK-PREP10-NEXT: stxsdx f0, r3, r4
6174 ; CHECK-PREP10-NEXT: blr
6176 %conv = fptoui float %str to i64
6177 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
6178 %0 = bitcast i8* %add.ptr to i64*
6179 store i64 %conv, i64* %0, align 8
6183 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6184 define dso_local void @st_align64_float_uint64_t(i8* nocapture %ptr, float %str) {
6185 ; CHECK-P10-LABEL: st_align64_float_uint64_t:
6186 ; CHECK-P10: # %bb.0: # %entry
6187 ; CHECK-P10-NEXT: xscvdpuxds f0, f1
6188 ; CHECK-P10-NEXT: pli r4, 244140625
6189 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
6190 ; CHECK-P10-NEXT: stxsdx f0, r3, r4
6191 ; CHECK-P10-NEXT: blr
6193 ; CHECK-PREP10-LABEL: st_align64_float_uint64_t:
6194 ; CHECK-PREP10: # %bb.0: # %entry
6195 ; CHECK-PREP10-NEXT: xscvdpuxds f0, f1
6196 ; CHECK-PREP10-NEXT: lis r4, 3725
6197 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
6198 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
6199 ; CHECK-PREP10-NEXT: stxsdx f0, r3, r4
6200 ; CHECK-PREP10-NEXT: blr
6202 %conv = fptoui float %str to i64
6203 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
6204 %0 = bitcast i8* %add.ptr to i64*
6205 store i64 %conv, i64* %0, align 8
6209 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6210 define dso_local void @st_reg_float_uint64_t(i8* nocapture %ptr, i64 %off, float %str) {
6211 ; CHECK-LABEL: st_reg_float_uint64_t:
6212 ; CHECK: # %bb.0: # %entry
6213 ; CHECK-NEXT: xscvdpuxds f0, f1
6214 ; CHECK-NEXT: stxsdx f0, r3, r4
6217 %conv = fptoui float %str to i64
6218 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
6219 %0 = bitcast i8* %add.ptr to i64*
6220 store i64 %conv, i64* %0, align 8
6224 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6225 define dso_local void @st_or1_float_uint64_t(i64 %ptr, i8 zeroext %off, float %str) {
6226 ; CHECK-POSTP8-LABEL: st_or1_float_uint64_t:
6227 ; CHECK-POSTP8: # %bb.0: # %entry
6228 ; CHECK-POSTP8-NEXT: xscvdpuxds v2, f1
6229 ; CHECK-POSTP8-NEXT: or r3, r4, r3
6230 ; CHECK-POSTP8-NEXT: stxsd v2, 0(r3)
6231 ; CHECK-POSTP8-NEXT: blr
6233 ; CHECK-P8-LABEL: st_or1_float_uint64_t:
6234 ; CHECK-P8: # %bb.0: # %entry
6235 ; CHECK-P8-NEXT: xscvdpuxds f0, f1
6236 ; CHECK-P8-NEXT: or r3, r4, r3
6237 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6238 ; CHECK-P8-NEXT: blr
6240 %conv = fptoui float %str to i64
6241 %conv1 = zext i8 %off to i64
6242 %or = or i64 %conv1, %ptr
6243 %0 = inttoptr i64 %or to i64*
6244 store i64 %conv, i64* %0, align 8
6248 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6249 define dso_local void @st_not_disjoint16_float_uint64_t(i64 %ptr, float %str) {
6250 ; CHECK-POSTP8-LABEL: st_not_disjoint16_float_uint64_t:
6251 ; CHECK-POSTP8: # %bb.0: # %entry
6252 ; CHECK-POSTP8-NEXT: xscvdpuxds v2, f1
6253 ; CHECK-POSTP8-NEXT: ori r3, r3, 6
6254 ; CHECK-POSTP8-NEXT: stxsd v2, 0(r3)
6255 ; CHECK-POSTP8-NEXT: blr
6257 ; CHECK-P8-LABEL: st_not_disjoint16_float_uint64_t:
6258 ; CHECK-P8: # %bb.0: # %entry
6259 ; CHECK-P8-NEXT: xscvdpuxds f0, f1
6260 ; CHECK-P8-NEXT: ori r3, r3, 6
6261 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6262 ; CHECK-P8-NEXT: blr
6264 %conv = fptoui float %str to i64
6265 %or = or i64 %ptr, 6
6266 %0 = inttoptr i64 %or to i64*
6267 store i64 %conv, i64* %0, align 8
6271 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6272 define dso_local void @st_disjoint_align16_float_uint64_t(i64 %ptr, float %str) {
6273 ; CHECK-POSTP8-LABEL: st_disjoint_align16_float_uint64_t:
6274 ; CHECK-POSTP8: # %bb.0: # %entry
6275 ; CHECK-POSTP8-NEXT: xscvdpuxds v2, f1
6276 ; CHECK-POSTP8-NEXT: rldicr r3, r3, 0, 51
6277 ; CHECK-POSTP8-NEXT: stxsd v2, 24(r3)
6278 ; CHECK-POSTP8-NEXT: blr
6280 ; CHECK-P8-LABEL: st_disjoint_align16_float_uint64_t:
6281 ; CHECK-P8: # %bb.0: # %entry
6282 ; CHECK-P8-NEXT: xscvdpuxds f0, f1
6283 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 51
6284 ; CHECK-P8-NEXT: ori r3, r3, 24
6285 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6286 ; CHECK-P8-NEXT: blr
6288 %and = and i64 %ptr, -4096
6289 %conv = fptoui float %str to i64
6290 %or = or i64 %and, 24
6291 %0 = inttoptr i64 %or to i64*
6292 store i64 %conv, i64* %0, align 8
6296 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6297 define dso_local void @st_not_disjoint32_float_uint64_t(i64 %ptr, float %str) {
6298 ; CHECK-POSTP8-LABEL: st_not_disjoint32_float_uint64_t:
6299 ; CHECK-POSTP8: # %bb.0: # %entry
6300 ; CHECK-POSTP8-NEXT: xscvdpuxds v2, f1
6301 ; CHECK-POSTP8-NEXT: ori r3, r3, 34463
6302 ; CHECK-POSTP8-NEXT: oris r3, r3, 1
6303 ; CHECK-POSTP8-NEXT: stxsd v2, 0(r3)
6304 ; CHECK-POSTP8-NEXT: blr
6306 ; CHECK-P8-LABEL: st_not_disjoint32_float_uint64_t:
6307 ; CHECK-P8: # %bb.0: # %entry
6308 ; CHECK-P8-NEXT: xscvdpuxds f0, f1
6309 ; CHECK-P8-NEXT: ori r3, r3, 34463
6310 ; CHECK-P8-NEXT: oris r3, r3, 1
6311 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6312 ; CHECK-P8-NEXT: blr
6314 %conv = fptoui float %str to i64
6315 %or = or i64 %ptr, 99999
6316 %0 = inttoptr i64 %or to i64*
6317 store i64 %conv, i64* %0, align 8
6321 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6322 define dso_local void @st_disjoint_align32_float_uint64_t(i64 %ptr, float %str) {
6323 ; CHECK-P10-LABEL: st_disjoint_align32_float_uint64_t:
6324 ; CHECK-P10: # %bb.0: # %entry
6325 ; CHECK-P10-NEXT: xscvdpuxds f0, f1
6326 ; CHECK-P10-NEXT: lis r4, -15264
6327 ; CHECK-P10-NEXT: and r3, r3, r4
6328 ; CHECK-P10-NEXT: pli r4, 999990000
6329 ; CHECK-P10-NEXT: stxsdx f0, r3, r4
6330 ; CHECK-P10-NEXT: blr
6332 ; CHECK-P9-LABEL: st_disjoint_align32_float_uint64_t:
6333 ; CHECK-P9: # %bb.0: # %entry
6334 ; CHECK-P9-NEXT: xscvdpuxds f0, f1
6335 ; CHECK-P9-NEXT: lis r4, -15264
6336 ; CHECK-P9-NEXT: and r3, r3, r4
6337 ; CHECK-P9-NEXT: lis r4, 15258
6338 ; CHECK-P9-NEXT: ori r4, r4, 41712
6339 ; CHECK-P9-NEXT: stxsdx f0, r3, r4
6340 ; CHECK-P9-NEXT: blr
6342 ; CHECK-P8-LABEL: st_disjoint_align32_float_uint64_t:
6343 ; CHECK-P8: # %bb.0: # %entry
6344 ; CHECK-P8-NEXT: xscvdpuxds f0, f1
6345 ; CHECK-P8-NEXT: lis r4, -15264
6346 ; CHECK-P8-NEXT: lis r5, 15258
6347 ; CHECK-P8-NEXT: and r3, r3, r4
6348 ; CHECK-P8-NEXT: ori r4, r5, 41712
6349 ; CHECK-P8-NEXT: stxsdx f0, r3, r4
6350 ; CHECK-P8-NEXT: blr
6352 %and = and i64 %ptr, -1000341504
6353 %conv = fptoui float %str to i64
6354 %or = or i64 %and, 999990000
6355 %0 = inttoptr i64 %or to i64*
6356 store i64 %conv, i64* %0, align 16
6360 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6361 define dso_local void @st_not_disjoint64_float_uint64_t(i64 %ptr, float %str) {
6362 ; CHECK-P10-LABEL: st_not_disjoint64_float_uint64_t:
6363 ; CHECK-P10: # %bb.0: # %entry
6364 ; CHECK-P10-NEXT: xscvdpuxds v2, f1
6365 ; CHECK-P10-NEXT: pli r4, 232
6366 ; CHECK-P10-NEXT: pli r5, 3567587329
6367 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
6368 ; CHECK-P10-NEXT: or r3, r3, r5
6369 ; CHECK-P10-NEXT: stxsd v2, 0(r3)
6370 ; CHECK-P10-NEXT: blr
6372 ; CHECK-P9-LABEL: st_not_disjoint64_float_uint64_t:
6373 ; CHECK-P9: # %bb.0: # %entry
6374 ; CHECK-P9-NEXT: li r4, 29
6375 ; CHECK-P9-NEXT: xscvdpuxds v2, f1
6376 ; CHECK-P9-NEXT: rldic r4, r4, 35, 24
6377 ; CHECK-P9-NEXT: oris r4, r4, 54437
6378 ; CHECK-P9-NEXT: ori r4, r4, 4097
6379 ; CHECK-P9-NEXT: or r3, r3, r4
6380 ; CHECK-P9-NEXT: stxsd v2, 0(r3)
6381 ; CHECK-P9-NEXT: blr
6383 ; CHECK-P8-LABEL: st_not_disjoint64_float_uint64_t:
6384 ; CHECK-P8: # %bb.0: # %entry
6385 ; CHECK-P8-NEXT: xscvdpuxds f0, f1
6386 ; CHECK-P8-NEXT: li r4, 29
6387 ; CHECK-P8-NEXT: rldic r4, r4, 35, 24
6388 ; CHECK-P8-NEXT: oris r4, r4, 54437
6389 ; CHECK-P8-NEXT: ori r4, r4, 4097
6390 ; CHECK-P8-NEXT: or r3, r3, r4
6391 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6392 ; CHECK-P8-NEXT: blr
6394 %conv = fptoui float %str to i64
6395 %or = or i64 %ptr, 1000000000001
6396 %0 = inttoptr i64 %or to i64*
6397 store i64 %conv, i64* %0, align 8
6401 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6402 define dso_local void @st_disjoint_align64_float_uint64_t(i64 %ptr, float %str) {
6403 ; CHECK-P10-LABEL: st_disjoint_align64_float_uint64_t:
6404 ; CHECK-P10: # %bb.0: # %entry
6405 ; CHECK-P10-NEXT: xscvdpuxds f0, f1
6406 ; CHECK-P10-NEXT: pli r4, 244140625
6407 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
6408 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
6409 ; CHECK-P10-NEXT: stxsdx f0, r3, r4
6410 ; CHECK-P10-NEXT: blr
6412 ; CHECK-PREP10-LABEL: st_disjoint_align64_float_uint64_t:
6413 ; CHECK-PREP10: # %bb.0: # %entry
6414 ; CHECK-PREP10-NEXT: xscvdpuxds f0, f1
6415 ; CHECK-PREP10-NEXT: lis r4, 3725
6416 ; CHECK-PREP10-NEXT: rldicr r3, r3, 0, 23
6417 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
6418 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
6419 ; CHECK-PREP10-NEXT: stxsdx f0, r3, r4
6420 ; CHECK-PREP10-NEXT: blr
6422 %and = and i64 %ptr, -1099511627776
6423 %conv = fptoui float %str to i64
6424 %or = or i64 %and, 1000000000000
6425 %0 = inttoptr i64 %or to i64*
6426 store i64 %conv, i64* %0, align 4096
6430 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6431 define dso_local void @st_cst_align16_float_uint64_t(float %str) {
6432 ; CHECK-POSTP8-LABEL: st_cst_align16_float_uint64_t:
6433 ; CHECK-POSTP8: # %bb.0: # %entry
6434 ; CHECK-POSTP8-NEXT: xscvdpuxds v2, f1
6435 ; CHECK-POSTP8-NEXT: stxsd v2, 4080(0)
6436 ; CHECK-POSTP8-NEXT: blr
6438 ; CHECK-P8-LABEL: st_cst_align16_float_uint64_t:
6439 ; CHECK-P8: # %bb.0: # %entry
6440 ; CHECK-P8-NEXT: xscvdpuxds f0, f1
6441 ; CHECK-P8-NEXT: li r3, 4080
6442 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6443 ; CHECK-P8-NEXT: blr
6445 %conv = fptoui float %str to i64
6446 store i64 %conv, i64* inttoptr (i64 4080 to i64*), align 16
6450 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6451 define dso_local void @st_cst_align32_float_uint64_t(float %str) {
6452 ; CHECK-POSTP8-LABEL: st_cst_align32_float_uint64_t:
6453 ; CHECK-POSTP8: # %bb.0: # %entry
6454 ; CHECK-POSTP8-NEXT: xscvdpuxds v2, f1
6455 ; CHECK-POSTP8-NEXT: lis r3, 153
6456 ; CHECK-POSTP8-NEXT: stxsd v2, -27108(r3)
6457 ; CHECK-POSTP8-NEXT: blr
6459 ; CHECK-P8-LABEL: st_cst_align32_float_uint64_t:
6460 ; CHECK-P8: # %bb.0: # %entry
6461 ; CHECK-P8-NEXT: xscvdpuxds f0, f1
6462 ; CHECK-P8-NEXT: lis r3, 152
6463 ; CHECK-P8-NEXT: ori r3, r3, 38428
6464 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6465 ; CHECK-P8-NEXT: blr
6467 %conv = fptoui float %str to i64
6468 store i64 %conv, i64* inttoptr (i64 9999900 to i64*), align 8
6472 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6473 define dso_local void @st_cst_align64_float_uint64_t(float %str) {
6474 ; CHECK-P10-LABEL: st_cst_align64_float_uint64_t:
6475 ; CHECK-P10: # %bb.0: # %entry
6476 ; CHECK-P10-NEXT: xscvdpuxds v2, f1
6477 ; CHECK-P10-NEXT: pli r3, 244140625
6478 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
6479 ; CHECK-P10-NEXT: stxsd v2, 0(r3)
6480 ; CHECK-P10-NEXT: blr
6482 ; CHECK-P9-LABEL: st_cst_align64_float_uint64_t:
6483 ; CHECK-P9: # %bb.0: # %entry
6484 ; CHECK-P9-NEXT: xscvdpuxds v2, f1
6485 ; CHECK-P9-NEXT: lis r3, 3725
6486 ; CHECK-P9-NEXT: ori r3, r3, 19025
6487 ; CHECK-P9-NEXT: rldic r3, r3, 12, 24
6488 ; CHECK-P9-NEXT: stxsd v2, 0(r3)
6489 ; CHECK-P9-NEXT: blr
6491 ; CHECK-P8-LABEL: st_cst_align64_float_uint64_t:
6492 ; CHECK-P8: # %bb.0: # %entry
6493 ; CHECK-P8-NEXT: xscvdpuxds f0, f1
6494 ; CHECK-P8-NEXT: lis r3, 3725
6495 ; CHECK-P8-NEXT: ori r3, r3, 19025
6496 ; CHECK-P8-NEXT: rldic r3, r3, 12, 24
6497 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6498 ; CHECK-P8-NEXT: blr
6500 %conv = fptoui float %str to i64
6501 store i64 %conv, i64* inttoptr (i64 1000000000000 to i64*), align 4096
6505 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6506 define dso_local void @st_0_float_int64_t(i64 %ptr, float %str) {
6507 ; CHECK-POSTP8-LABEL: st_0_float_int64_t:
6508 ; CHECK-POSTP8: # %bb.0: # %entry
6509 ; CHECK-POSTP8-NEXT: xscvdpsxds v2, f1
6510 ; CHECK-POSTP8-NEXT: stxsd v2, 0(r3)
6511 ; CHECK-POSTP8-NEXT: blr
6513 ; CHECK-P8-LABEL: st_0_float_int64_t:
6514 ; CHECK-P8: # %bb.0: # %entry
6515 ; CHECK-P8-NEXT: xscvdpsxds f0, f1
6516 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6517 ; CHECK-P8-NEXT: blr
6519 %conv = fptosi float %str to i64
6520 %0 = inttoptr i64 %ptr to i64*
6521 store i64 %conv, i64* %0, align 8
6525 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6526 define dso_local void @st_align16_float_int64_t(i8* nocapture %ptr, float %str) {
6527 ; CHECK-POSTP8-LABEL: st_align16_float_int64_t:
6528 ; CHECK-POSTP8: # %bb.0: # %entry
6529 ; CHECK-POSTP8-NEXT: xscvdpsxds v2, f1
6530 ; CHECK-POSTP8-NEXT: stxsd v2, 8(r3)
6531 ; CHECK-POSTP8-NEXT: blr
6533 ; CHECK-P8-LABEL: st_align16_float_int64_t:
6534 ; CHECK-P8: # %bb.0: # %entry
6535 ; CHECK-P8-NEXT: xscvdpsxds f0, f1
6536 ; CHECK-P8-NEXT: li r4, 8
6537 ; CHECK-P8-NEXT: stxsdx f0, r3, r4
6538 ; CHECK-P8-NEXT: blr
6540 %conv = fptosi float %str to i64
6541 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
6542 %0 = bitcast i8* %add.ptr to i64*
6543 store i64 %conv, i64* %0, align 8
6547 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6548 define dso_local void @st_align32_float_int64_t(i8* nocapture %ptr, float %str) {
6549 ; CHECK-P10-LABEL: st_align32_float_int64_t:
6550 ; CHECK-P10: # %bb.0: # %entry
6551 ; CHECK-P10-NEXT: xscvdpsxds f0, f1
6552 ; CHECK-P10-NEXT: pli r4, 99999000
6553 ; CHECK-P10-NEXT: stxsdx f0, r3, r4
6554 ; CHECK-P10-NEXT: blr
6556 ; CHECK-PREP10-LABEL: st_align32_float_int64_t:
6557 ; CHECK-PREP10: # %bb.0: # %entry
6558 ; CHECK-PREP10-NEXT: xscvdpsxds f0, f1
6559 ; CHECK-PREP10-NEXT: lis r4, 1525
6560 ; CHECK-PREP10-NEXT: ori r4, r4, 56600
6561 ; CHECK-PREP10-NEXT: stxsdx f0, r3, r4
6562 ; CHECK-PREP10-NEXT: blr
6564 %conv = fptosi float %str to i64
6565 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
6566 %0 = bitcast i8* %add.ptr to i64*
6567 store i64 %conv, i64* %0, align 8
6571 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6572 define dso_local void @st_align64_float_int64_t(i8* nocapture %ptr, float %str) {
6573 ; CHECK-P10-LABEL: st_align64_float_int64_t:
6574 ; CHECK-P10: # %bb.0: # %entry
6575 ; CHECK-P10-NEXT: xscvdpsxds f0, f1
6576 ; CHECK-P10-NEXT: pli r4, 244140625
6577 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
6578 ; CHECK-P10-NEXT: stxsdx f0, r3, r4
6579 ; CHECK-P10-NEXT: blr
6581 ; CHECK-PREP10-LABEL: st_align64_float_int64_t:
6582 ; CHECK-PREP10: # %bb.0: # %entry
6583 ; CHECK-PREP10-NEXT: xscvdpsxds f0, f1
6584 ; CHECK-PREP10-NEXT: lis r4, 3725
6585 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
6586 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
6587 ; CHECK-PREP10-NEXT: stxsdx f0, r3, r4
6588 ; CHECK-PREP10-NEXT: blr
6590 %conv = fptosi float %str to i64
6591 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
6592 %0 = bitcast i8* %add.ptr to i64*
6593 store i64 %conv, i64* %0, align 8
6597 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6598 define dso_local void @st_reg_float_int64_t(i8* nocapture %ptr, i64 %off, float %str) {
6599 ; CHECK-LABEL: st_reg_float_int64_t:
6600 ; CHECK: # %bb.0: # %entry
6601 ; CHECK-NEXT: xscvdpsxds f0, f1
6602 ; CHECK-NEXT: stxsdx f0, r3, r4
6605 %conv = fptosi float %str to i64
6606 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
6607 %0 = bitcast i8* %add.ptr to i64*
6608 store i64 %conv, i64* %0, align 8
6612 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6613 define dso_local void @st_or1_float_int64_t(i64 %ptr, i8 zeroext %off, float %str) {
6614 ; CHECK-POSTP8-LABEL: st_or1_float_int64_t:
6615 ; CHECK-POSTP8: # %bb.0: # %entry
6616 ; CHECK-POSTP8-NEXT: xscvdpsxds v2, f1
6617 ; CHECK-POSTP8-NEXT: or r3, r4, r3
6618 ; CHECK-POSTP8-NEXT: stxsd v2, 0(r3)
6619 ; CHECK-POSTP8-NEXT: blr
6621 ; CHECK-P8-LABEL: st_or1_float_int64_t:
6622 ; CHECK-P8: # %bb.0: # %entry
6623 ; CHECK-P8-NEXT: xscvdpsxds f0, f1
6624 ; CHECK-P8-NEXT: or r3, r4, r3
6625 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6626 ; CHECK-P8-NEXT: blr
6628 %conv = fptosi float %str to i64
6629 %conv1 = zext i8 %off to i64
6630 %or = or i64 %conv1, %ptr
6631 %0 = inttoptr i64 %or to i64*
6632 store i64 %conv, i64* %0, align 8
6636 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6637 define dso_local void @st_not_disjoint16_float_int64_t(i64 %ptr, float %str) {
6638 ; CHECK-POSTP8-LABEL: st_not_disjoint16_float_int64_t:
6639 ; CHECK-POSTP8: # %bb.0: # %entry
6640 ; CHECK-POSTP8-NEXT: xscvdpsxds v2, f1
6641 ; CHECK-POSTP8-NEXT: ori r3, r3, 6
6642 ; CHECK-POSTP8-NEXT: stxsd v2, 0(r3)
6643 ; CHECK-POSTP8-NEXT: blr
6645 ; CHECK-P8-LABEL: st_not_disjoint16_float_int64_t:
6646 ; CHECK-P8: # %bb.0: # %entry
6647 ; CHECK-P8-NEXT: xscvdpsxds f0, f1
6648 ; CHECK-P8-NEXT: ori r3, r3, 6
6649 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6650 ; CHECK-P8-NEXT: blr
6652 %conv = fptosi float %str to i64
6653 %or = or i64 %ptr, 6
6654 %0 = inttoptr i64 %or to i64*
6655 store i64 %conv, i64* %0, align 8
6659 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6660 define dso_local void @st_disjoint_align16_float_int64_t(i64 %ptr, float %str) {
6661 ; CHECK-POSTP8-LABEL: st_disjoint_align16_float_int64_t:
6662 ; CHECK-POSTP8: # %bb.0: # %entry
6663 ; CHECK-POSTP8-NEXT: xscvdpsxds v2, f1
6664 ; CHECK-POSTP8-NEXT: rldicr r3, r3, 0, 51
6665 ; CHECK-POSTP8-NEXT: stxsd v2, 24(r3)
6666 ; CHECK-POSTP8-NEXT: blr
6668 ; CHECK-P8-LABEL: st_disjoint_align16_float_int64_t:
6669 ; CHECK-P8: # %bb.0: # %entry
6670 ; CHECK-P8-NEXT: xscvdpsxds f0, f1
6671 ; CHECK-P8-NEXT: rldicr r3, r3, 0, 51
6672 ; CHECK-P8-NEXT: ori r3, r3, 24
6673 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6674 ; CHECK-P8-NEXT: blr
6676 %and = and i64 %ptr, -4096
6677 %conv = fptosi float %str to i64
6678 %or = or i64 %and, 24
6679 %0 = inttoptr i64 %or to i64*
6680 store i64 %conv, i64* %0, align 8
6684 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6685 define dso_local void @st_not_disjoint32_float_int64_t(i64 %ptr, float %str) {
6686 ; CHECK-POSTP8-LABEL: st_not_disjoint32_float_int64_t:
6687 ; CHECK-POSTP8: # %bb.0: # %entry
6688 ; CHECK-POSTP8-NEXT: xscvdpsxds v2, f1
6689 ; CHECK-POSTP8-NEXT: ori r3, r3, 34463
6690 ; CHECK-POSTP8-NEXT: oris r3, r3, 1
6691 ; CHECK-POSTP8-NEXT: stxsd v2, 0(r3)
6692 ; CHECK-POSTP8-NEXT: blr
6694 ; CHECK-P8-LABEL: st_not_disjoint32_float_int64_t:
6695 ; CHECK-P8: # %bb.0: # %entry
6696 ; CHECK-P8-NEXT: xscvdpsxds f0, f1
6697 ; CHECK-P8-NEXT: ori r3, r3, 34463
6698 ; CHECK-P8-NEXT: oris r3, r3, 1
6699 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6700 ; CHECK-P8-NEXT: blr
6702 %conv = fptosi float %str to i64
6703 %or = or i64 %ptr, 99999
6704 %0 = inttoptr i64 %or to i64*
6705 store i64 %conv, i64* %0, align 8
6709 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6710 define dso_local void @st_disjoint_align32_float_int64_t(i64 %ptr, float %str) {
6711 ; CHECK-P10-LABEL: st_disjoint_align32_float_int64_t:
6712 ; CHECK-P10: # %bb.0: # %entry
6713 ; CHECK-P10-NEXT: xscvdpsxds f0, f1
6714 ; CHECK-P10-NEXT: lis r4, -15264
6715 ; CHECK-P10-NEXT: and r3, r3, r4
6716 ; CHECK-P10-NEXT: pli r4, 999990000
6717 ; CHECK-P10-NEXT: stxsdx f0, r3, r4
6718 ; CHECK-P10-NEXT: blr
6720 ; CHECK-P9-LABEL: st_disjoint_align32_float_int64_t:
6721 ; CHECK-P9: # %bb.0: # %entry
6722 ; CHECK-P9-NEXT: xscvdpsxds f0, f1
6723 ; CHECK-P9-NEXT: lis r4, -15264
6724 ; CHECK-P9-NEXT: and r3, r3, r4
6725 ; CHECK-P9-NEXT: lis r4, 15258
6726 ; CHECK-P9-NEXT: ori r4, r4, 41712
6727 ; CHECK-P9-NEXT: stxsdx f0, r3, r4
6728 ; CHECK-P9-NEXT: blr
6730 ; CHECK-P8-LABEL: st_disjoint_align32_float_int64_t:
6731 ; CHECK-P8: # %bb.0: # %entry
6732 ; CHECK-P8-NEXT: xscvdpsxds f0, f1
6733 ; CHECK-P8-NEXT: lis r4, -15264
6734 ; CHECK-P8-NEXT: lis r5, 15258
6735 ; CHECK-P8-NEXT: and r3, r3, r4
6736 ; CHECK-P8-NEXT: ori r4, r5, 41712
6737 ; CHECK-P8-NEXT: stxsdx f0, r3, r4
6738 ; CHECK-P8-NEXT: blr
6740 %and = and i64 %ptr, -1000341504
6741 %conv = fptosi float %str to i64
6742 %or = or i64 %and, 999990000
6743 %0 = inttoptr i64 %or to i64*
6744 store i64 %conv, i64* %0, align 16
6748 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6749 define dso_local void @st_not_disjoint64_float_int64_t(i64 %ptr, float %str) {
6750 ; CHECK-P10-LABEL: st_not_disjoint64_float_int64_t:
6751 ; CHECK-P10: # %bb.0: # %entry
6752 ; CHECK-P10-NEXT: xscvdpsxds v2, f1
6753 ; CHECK-P10-NEXT: pli r4, 232
6754 ; CHECK-P10-NEXT: pli r5, 3567587329
6755 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
6756 ; CHECK-P10-NEXT: or r3, r3, r5
6757 ; CHECK-P10-NEXT: stxsd v2, 0(r3)
6758 ; CHECK-P10-NEXT: blr
6760 ; CHECK-P9-LABEL: st_not_disjoint64_float_int64_t:
6761 ; CHECK-P9: # %bb.0: # %entry
6762 ; CHECK-P9-NEXT: li r4, 29
6763 ; CHECK-P9-NEXT: xscvdpsxds v2, f1
6764 ; CHECK-P9-NEXT: rldic r4, r4, 35, 24
6765 ; CHECK-P9-NEXT: oris r4, r4, 54437
6766 ; CHECK-P9-NEXT: ori r4, r4, 4097
6767 ; CHECK-P9-NEXT: or r3, r3, r4
6768 ; CHECK-P9-NEXT: stxsd v2, 0(r3)
6769 ; CHECK-P9-NEXT: blr
6771 ; CHECK-P8-LABEL: st_not_disjoint64_float_int64_t:
6772 ; CHECK-P8: # %bb.0: # %entry
6773 ; CHECK-P8-NEXT: xscvdpsxds f0, f1
6774 ; CHECK-P8-NEXT: li r4, 29
6775 ; CHECK-P8-NEXT: rldic r4, r4, 35, 24
6776 ; CHECK-P8-NEXT: oris r4, r4, 54437
6777 ; CHECK-P8-NEXT: ori r4, r4, 4097
6778 ; CHECK-P8-NEXT: or r3, r3, r4
6779 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6780 ; CHECK-P8-NEXT: blr
6782 %conv = fptosi float %str to i64
6783 %or = or i64 %ptr, 1000000000001
6784 %0 = inttoptr i64 %or to i64*
6785 store i64 %conv, i64* %0, align 8
6789 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6790 define dso_local void @st_disjoint_align64_float_int64_t(i64 %ptr, float %str) {
6791 ; CHECK-P10-LABEL: st_disjoint_align64_float_int64_t:
6792 ; CHECK-P10: # %bb.0: # %entry
6793 ; CHECK-P10-NEXT: xscvdpsxds f0, f1
6794 ; CHECK-P10-NEXT: pli r4, 244140625
6795 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
6796 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
6797 ; CHECK-P10-NEXT: stxsdx f0, r3, r4
6798 ; CHECK-P10-NEXT: blr
6800 ; CHECK-PREP10-LABEL: st_disjoint_align64_float_int64_t:
6801 ; CHECK-PREP10: # %bb.0: # %entry
6802 ; CHECK-PREP10-NEXT: xscvdpsxds f0, f1
6803 ; CHECK-PREP10-NEXT: lis r4, 3725
6804 ; CHECK-PREP10-NEXT: rldicr r3, r3, 0, 23
6805 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
6806 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
6807 ; CHECK-PREP10-NEXT: stxsdx f0, r3, r4
6808 ; CHECK-PREP10-NEXT: blr
6810 %and = and i64 %ptr, -1099511627776
6811 %conv = fptosi float %str to i64
6812 %or = or i64 %and, 1000000000000
6813 %0 = inttoptr i64 %or to i64*
6814 store i64 %conv, i64* %0, align 4096
6818 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6819 define dso_local void @st_cst_align16_float_int64_t(float %str) {
6820 ; CHECK-POSTP8-LABEL: st_cst_align16_float_int64_t:
6821 ; CHECK-POSTP8: # %bb.0: # %entry
6822 ; CHECK-POSTP8-NEXT: xscvdpsxds v2, f1
6823 ; CHECK-POSTP8-NEXT: stxsd v2, 4080(0)
6824 ; CHECK-POSTP8-NEXT: blr
6826 ; CHECK-P8-LABEL: st_cst_align16_float_int64_t:
6827 ; CHECK-P8: # %bb.0: # %entry
6828 ; CHECK-P8-NEXT: xscvdpsxds f0, f1
6829 ; CHECK-P8-NEXT: li r3, 4080
6830 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6831 ; CHECK-P8-NEXT: blr
6833 %conv = fptosi float %str to i64
6834 store i64 %conv, i64* inttoptr (i64 4080 to i64*), align 16
6838 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6839 define dso_local void @st_cst_align32_float_int64_t(float %str) {
6840 ; CHECK-POSTP8-LABEL: st_cst_align32_float_int64_t:
6841 ; CHECK-POSTP8: # %bb.0: # %entry
6842 ; CHECK-POSTP8-NEXT: xscvdpsxds v2, f1
6843 ; CHECK-POSTP8-NEXT: lis r3, 153
6844 ; CHECK-POSTP8-NEXT: stxsd v2, -27108(r3)
6845 ; CHECK-POSTP8-NEXT: blr
6847 ; CHECK-P8-LABEL: st_cst_align32_float_int64_t:
6848 ; CHECK-P8: # %bb.0: # %entry
6849 ; CHECK-P8-NEXT: xscvdpsxds f0, f1
6850 ; CHECK-P8-NEXT: lis r3, 152
6851 ; CHECK-P8-NEXT: ori r3, r3, 38428
6852 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6853 ; CHECK-P8-NEXT: blr
6855 %conv = fptosi float %str to i64
6856 store i64 %conv, i64* inttoptr (i64 9999900 to i64*), align 8
6860 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6861 define dso_local void @st_cst_align64_float_int64_t(float %str) {
6862 ; CHECK-P10-LABEL: st_cst_align64_float_int64_t:
6863 ; CHECK-P10: # %bb.0: # %entry
6864 ; CHECK-P10-NEXT: xscvdpsxds v2, f1
6865 ; CHECK-P10-NEXT: pli r3, 244140625
6866 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
6867 ; CHECK-P10-NEXT: stxsd v2, 0(r3)
6868 ; CHECK-P10-NEXT: blr
6870 ; CHECK-P9-LABEL: st_cst_align64_float_int64_t:
6871 ; CHECK-P9: # %bb.0: # %entry
6872 ; CHECK-P9-NEXT: xscvdpsxds v2, f1
6873 ; CHECK-P9-NEXT: lis r3, 3725
6874 ; CHECK-P9-NEXT: ori r3, r3, 19025
6875 ; CHECK-P9-NEXT: rldic r3, r3, 12, 24
6876 ; CHECK-P9-NEXT: stxsd v2, 0(r3)
6877 ; CHECK-P9-NEXT: blr
6879 ; CHECK-P8-LABEL: st_cst_align64_float_int64_t:
6880 ; CHECK-P8: # %bb.0: # %entry
6881 ; CHECK-P8-NEXT: xscvdpsxds f0, f1
6882 ; CHECK-P8-NEXT: lis r3, 3725
6883 ; CHECK-P8-NEXT: ori r3, r3, 19025
6884 ; CHECK-P8-NEXT: rldic r3, r3, 12, 24
6885 ; CHECK-P8-NEXT: stxsdx f0, 0, r3
6886 ; CHECK-P8-NEXT: blr
6888 %conv = fptosi float %str to i64
6889 store i64 %conv, i64* inttoptr (i64 1000000000000 to i64*), align 4096
6893 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6894 define dso_local void @st_0_float_float(i64 %ptr, float %str) {
6895 ; CHECK-LABEL: st_0_float_float:
6896 ; CHECK: # %bb.0: # %entry
6897 ; CHECK-NEXT: stfs f1, 0(r3)
6900 %0 = inttoptr i64 %ptr to float*
6901 store float %str, float* %0, align 4
6905 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6906 define dso_local void @st_align16_float_float(i8* nocapture %ptr, float %str) {
6907 ; CHECK-LABEL: st_align16_float_float:
6908 ; CHECK: # %bb.0: # %entry
6909 ; CHECK-NEXT: stfs f1, 8(r3)
6912 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
6913 %0 = bitcast i8* %add.ptr to float*
6914 store float %str, float* %0, align 4
6918 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6919 define dso_local void @st_align32_float_float(i8* nocapture %ptr, float %str) {
6920 ; CHECK-P10-LABEL: st_align32_float_float:
6921 ; CHECK-P10: # %bb.0: # %entry
6922 ; CHECK-P10-NEXT: pli r4, 99999000
6923 ; CHECK-P10-NEXT: stfsx f1, r3, r4
6924 ; CHECK-P10-NEXT: blr
6926 ; CHECK-PREP10-LABEL: st_align32_float_float:
6927 ; CHECK-PREP10: # %bb.0: # %entry
6928 ; CHECK-PREP10-NEXT: lis r4, 1525
6929 ; CHECK-PREP10-NEXT: ori r4, r4, 56600
6930 ; CHECK-PREP10-NEXT: stfsx f1, r3, r4
6931 ; CHECK-PREP10-NEXT: blr
6933 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
6934 %0 = bitcast i8* %add.ptr to float*
6935 store float %str, float* %0, align 4
6939 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6940 define dso_local void @st_align64_float_float(i8* nocapture %ptr, float %str) {
6941 ; CHECK-P10-LABEL: st_align64_float_float:
6942 ; CHECK-P10: # %bb.0: # %entry
6943 ; CHECK-P10-NEXT: pli r4, 244140625
6944 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
6945 ; CHECK-P10-NEXT: stfsx f1, r3, r4
6946 ; CHECK-P10-NEXT: blr
6948 ; CHECK-PREP10-LABEL: st_align64_float_float:
6949 ; CHECK-PREP10: # %bb.0: # %entry
6950 ; CHECK-PREP10-NEXT: lis r4, 3725
6951 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
6952 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
6953 ; CHECK-PREP10-NEXT: stfsx f1, r3, r4
6954 ; CHECK-PREP10-NEXT: blr
6956 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
6957 %0 = bitcast i8* %add.ptr to float*
6958 store float %str, float* %0, align 4
6962 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6963 define dso_local void @st_reg_float_float(i8* nocapture %ptr, i64 %off, float %str) {
6964 ; CHECK-LABEL: st_reg_float_float:
6965 ; CHECK: # %bb.0: # %entry
6966 ; CHECK-NEXT: stfsx f1, r3, r4
6969 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
6970 %0 = bitcast i8* %add.ptr to float*
6971 store float %str, float* %0, align 4
6975 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6976 define dso_local void @st_or1_float_float(i64 %ptr, i8 zeroext %off, float %str) {
6977 ; CHECK-LABEL: st_or1_float_float:
6978 ; CHECK: # %bb.0: # %entry
6979 ; CHECK-NEXT: or r3, r4, r3
6980 ; CHECK-NEXT: stfs f1, 0(r3)
6983 %conv = zext i8 %off to i64
6984 %or = or i64 %conv, %ptr
6985 %0 = inttoptr i64 %or to float*
6986 store float %str, float* %0, align 4
6990 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
6991 define dso_local void @st_not_disjoint16_float_float(i64 %ptr, float %str) {
6992 ; CHECK-LABEL: st_not_disjoint16_float_float:
6993 ; CHECK: # %bb.0: # %entry
6994 ; CHECK-NEXT: ori r3, r3, 6
6995 ; CHECK-NEXT: stfs f1, 0(r3)
6998 %or = or i64 %ptr, 6
6999 %0 = inttoptr i64 %or to float*
7000 store float %str, float* %0, align 4
7004 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7005 define dso_local void @st_disjoint_align16_float_float(i64 %ptr, float %str) {
7006 ; CHECK-LABEL: st_disjoint_align16_float_float:
7007 ; CHECK: # %bb.0: # %entry
7008 ; CHECK-NEXT: rldicr r3, r3, 0, 51
7009 ; CHECK-NEXT: stfs f1, 24(r3)
7012 %and = and i64 %ptr, -4096
7013 %or = or i64 %and, 24
7014 %0 = inttoptr i64 %or to float*
7015 store float %str, float* %0, align 8
7019 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7020 define dso_local void @st_not_disjoint32_float_float(i64 %ptr, float %str) {
7021 ; CHECK-LABEL: st_not_disjoint32_float_float:
7022 ; CHECK: # %bb.0: # %entry
7023 ; CHECK-NEXT: ori r3, r3, 34463
7024 ; CHECK-NEXT: oris r3, r3, 1
7025 ; CHECK-NEXT: stfs f1, 0(r3)
7028 %or = or i64 %ptr, 99999
7029 %0 = inttoptr i64 %or to float*
7030 store float %str, float* %0, align 4
7034 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7035 define dso_local void @st_disjoint_align32_float_float(i64 %ptr, float %str) {
7036 ; CHECK-P10-LABEL: st_disjoint_align32_float_float:
7037 ; CHECK-P10: # %bb.0: # %entry
7038 ; CHECK-P10-NEXT: lis r4, -15264
7039 ; CHECK-P10-NEXT: and r3, r3, r4
7040 ; CHECK-P10-NEXT: pli r4, 999990000
7041 ; CHECK-P10-NEXT: stfsx f1, r3, r4
7042 ; CHECK-P10-NEXT: blr
7044 ; CHECK-P9-LABEL: st_disjoint_align32_float_float:
7045 ; CHECK-P9: # %bb.0: # %entry
7046 ; CHECK-P9-NEXT: lis r4, -15264
7047 ; CHECK-P9-NEXT: and r3, r3, r4
7048 ; CHECK-P9-NEXT: lis r4, 15258
7049 ; CHECK-P9-NEXT: ori r4, r4, 41712
7050 ; CHECK-P9-NEXT: stfsx f1, r3, r4
7051 ; CHECK-P9-NEXT: blr
7053 ; CHECK-P8-LABEL: st_disjoint_align32_float_float:
7054 ; CHECK-P8: # %bb.0: # %entry
7055 ; CHECK-P8-NEXT: lis r4, -15264
7056 ; CHECK-P8-NEXT: lis r5, 15258
7057 ; CHECK-P8-NEXT: and r3, r3, r4
7058 ; CHECK-P8-NEXT: ori r4, r5, 41712
7059 ; CHECK-P8-NEXT: stfsx f1, r3, r4
7060 ; CHECK-P8-NEXT: blr
7062 %and = and i64 %ptr, -1000341504
7063 %or = or i64 %and, 999990000
7064 %0 = inttoptr i64 %or to float*
7065 store float %str, float* %0, align 16
7069 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7070 define dso_local void @st_not_disjoint64_float_float(i64 %ptr, float %str) {
7071 ; CHECK-P10-LABEL: st_not_disjoint64_float_float:
7072 ; CHECK-P10: # %bb.0: # %entry
7073 ; CHECK-P10-NEXT: pli r4, 232
7074 ; CHECK-P10-NEXT: pli r5, 3567587329
7075 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
7076 ; CHECK-P10-NEXT: or r3, r3, r5
7077 ; CHECK-P10-NEXT: stfs f1, 0(r3)
7078 ; CHECK-P10-NEXT: blr
7080 ; CHECK-PREP10-LABEL: st_not_disjoint64_float_float:
7081 ; CHECK-PREP10: # %bb.0: # %entry
7082 ; CHECK-PREP10-NEXT: li r4, 29
7083 ; CHECK-PREP10-NEXT: rldic r4, r4, 35, 24
7084 ; CHECK-PREP10-NEXT: oris r4, r4, 54437
7085 ; CHECK-PREP10-NEXT: ori r4, r4, 4097
7086 ; CHECK-PREP10-NEXT: or r3, r3, r4
7087 ; CHECK-PREP10-NEXT: stfs f1, 0(r3)
7088 ; CHECK-PREP10-NEXT: blr
7090 %or = or i64 %ptr, 1000000000001
7091 %0 = inttoptr i64 %or to float*
7092 store float %str, float* %0, align 4
7096 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7097 define dso_local void @st_disjoint_align64_float_float(i64 %ptr, float %str) {
7098 ; CHECK-P10-LABEL: st_disjoint_align64_float_float:
7099 ; CHECK-P10: # %bb.0: # %entry
7100 ; CHECK-P10-NEXT: pli r4, 244140625
7101 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
7102 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
7103 ; CHECK-P10-NEXT: stfsx f1, r3, r4
7104 ; CHECK-P10-NEXT: blr
7106 ; CHECK-PREP10-LABEL: st_disjoint_align64_float_float:
7107 ; CHECK-PREP10: # %bb.0: # %entry
7108 ; CHECK-PREP10-NEXT: lis r4, 3725
7109 ; CHECK-PREP10-NEXT: rldicr r3, r3, 0, 23
7110 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
7111 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
7112 ; CHECK-PREP10-NEXT: stfsx f1, r3, r4
7113 ; CHECK-PREP10-NEXT: blr
7115 %and = and i64 %ptr, -1099511627776
7116 %or = or i64 %and, 1000000000000
7117 %0 = inttoptr i64 %or to float*
7118 store float %str, float* %0, align 4096
7122 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7123 define dso_local void @st_cst_align16_float_float(float %str) {
7124 ; CHECK-LABEL: st_cst_align16_float_float:
7125 ; CHECK: # %bb.0: # %entry
7126 ; CHECK-NEXT: stfs f1, 4080(0)
7129 store float %str, float* inttoptr (i64 4080 to float*), align 16
7133 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7134 define dso_local void @st_cst_align32_float_float(float %str) {
7135 ; CHECK-LABEL: st_cst_align32_float_float:
7136 ; CHECK: # %bb.0: # %entry
7137 ; CHECK-NEXT: lis r3, 153
7138 ; CHECK-NEXT: stfs f1, -27108(r3)
7141 store float %str, float* inttoptr (i64 9999900 to float*), align 4
7145 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7146 define dso_local void @st_cst_align64_float_float(float %str) {
7147 ; CHECK-P10-LABEL: st_cst_align64_float_float:
7148 ; CHECK-P10: # %bb.0: # %entry
7149 ; CHECK-P10-NEXT: pli r3, 244140625
7150 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
7151 ; CHECK-P10-NEXT: stfs f1, 0(r3)
7152 ; CHECK-P10-NEXT: blr
7154 ; CHECK-PREP10-LABEL: st_cst_align64_float_float:
7155 ; CHECK-PREP10: # %bb.0: # %entry
7156 ; CHECK-PREP10-NEXT: lis r3, 3725
7157 ; CHECK-PREP10-NEXT: ori r3, r3, 19025
7158 ; CHECK-PREP10-NEXT: rldic r3, r3, 12, 24
7159 ; CHECK-PREP10-NEXT: stfs f1, 0(r3)
7160 ; CHECK-PREP10-NEXT: blr
7162 store float %str, float* inttoptr (i64 1000000000000 to float*), align 4096
7166 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7167 define dso_local void @st_0_float_double(i64 %ptr, float %str) {
7168 ; CHECK-LABEL: st_0_float_double:
7169 ; CHECK: # %bb.0: # %entry
7170 ; CHECK-NEXT: stfd f1, 0(r3)
7173 %conv = fpext float %str to double
7174 %0 = inttoptr i64 %ptr to double*
7175 store double %conv, double* %0, align 8
7179 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7180 define dso_local void @st_align16_float_double(i8* nocapture %ptr, float %str) {
7181 ; CHECK-LABEL: st_align16_float_double:
7182 ; CHECK: # %bb.0: # %entry
7183 ; CHECK-NEXT: stfd f1, 8(r3)
7186 %conv = fpext float %str to double
7187 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 8
7188 %0 = bitcast i8* %add.ptr to double*
7189 store double %conv, double* %0, align 8
7193 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7194 define dso_local void @st_align32_float_double(i8* nocapture %ptr, float %str) {
7195 ; CHECK-P10-LABEL: st_align32_float_double:
7196 ; CHECK-P10: # %bb.0: # %entry
7197 ; CHECK-P10-NEXT: pli r4, 99999000
7198 ; CHECK-P10-NEXT: stfdx f1, r3, r4
7199 ; CHECK-P10-NEXT: blr
7201 ; CHECK-PREP10-LABEL: st_align32_float_double:
7202 ; CHECK-PREP10: # %bb.0: # %entry
7203 ; CHECK-PREP10-NEXT: lis r4, 1525
7204 ; CHECK-PREP10-NEXT: ori r4, r4, 56600
7205 ; CHECK-PREP10-NEXT: stfdx f1, r3, r4
7206 ; CHECK-PREP10-NEXT: blr
7208 %conv = fpext float %str to double
7209 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 99999000
7210 %0 = bitcast i8* %add.ptr to double*
7211 store double %conv, double* %0, align 8
7215 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7216 define dso_local void @st_align64_float_double(i8* nocapture %ptr, float %str) {
7217 ; CHECK-P10-LABEL: st_align64_float_double:
7218 ; CHECK-P10: # %bb.0: # %entry
7219 ; CHECK-P10-NEXT: pli r4, 244140625
7220 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
7221 ; CHECK-P10-NEXT: stfdx f1, r3, r4
7222 ; CHECK-P10-NEXT: blr
7224 ; CHECK-PREP10-LABEL: st_align64_float_double:
7225 ; CHECK-PREP10: # %bb.0: # %entry
7226 ; CHECK-PREP10-NEXT: lis r4, 3725
7227 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
7228 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
7229 ; CHECK-PREP10-NEXT: stfdx f1, r3, r4
7230 ; CHECK-PREP10-NEXT: blr
7232 %conv = fpext float %str to double
7233 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 1000000000000
7234 %0 = bitcast i8* %add.ptr to double*
7235 store double %conv, double* %0, align 8
7239 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7240 define dso_local void @st_reg_float_double(i8* nocapture %ptr, i64 %off, float %str) {
7241 ; CHECK-LABEL: st_reg_float_double:
7242 ; CHECK: # %bb.0: # %entry
7243 ; CHECK-NEXT: stfdx f1, r3, r4
7246 %conv = fpext float %str to double
7247 %add.ptr = getelementptr inbounds i8, i8* %ptr, i64 %off
7248 %0 = bitcast i8* %add.ptr to double*
7249 store double %conv, double* %0, align 8
7253 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7254 define dso_local void @st_or1_float_double(i64 %ptr, i8 zeroext %off, float %str) {
7255 ; CHECK-LABEL: st_or1_float_double:
7256 ; CHECK: # %bb.0: # %entry
7257 ; CHECK-NEXT: or r3, r4, r3
7258 ; CHECK-NEXT: stfd f1, 0(r3)
7261 %conv = fpext float %str to double
7262 %conv1 = zext i8 %off to i64
7263 %or = or i64 %conv1, %ptr
7264 %0 = inttoptr i64 %or to double*
7265 store double %conv, double* %0, align 8
7269 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7270 define dso_local void @st_not_disjoint16_float_double(i64 %ptr, float %str) {
7271 ; CHECK-LABEL: st_not_disjoint16_float_double:
7272 ; CHECK: # %bb.0: # %entry
7273 ; CHECK-NEXT: ori r3, r3, 6
7274 ; CHECK-NEXT: stfd f1, 0(r3)
7277 %conv = fpext float %str to double
7278 %or = or i64 %ptr, 6
7279 %0 = inttoptr i64 %or to double*
7280 store double %conv, double* %0, align 8
7284 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7285 define dso_local void @st_disjoint_align16_float_double(i64 %ptr, float %str) {
7286 ; CHECK-LABEL: st_disjoint_align16_float_double:
7287 ; CHECK: # %bb.0: # %entry
7288 ; CHECK-NEXT: rldicr r3, r3, 0, 51
7289 ; CHECK-NEXT: stfd f1, 24(r3)
7292 %and = and i64 %ptr, -4096
7293 %conv = fpext float %str to double
7294 %or = or i64 %and, 24
7295 %0 = inttoptr i64 %or to double*
7296 store double %conv, double* %0, align 8
7300 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7301 define dso_local void @st_not_disjoint32_float_double(i64 %ptr, float %str) {
7302 ; CHECK-LABEL: st_not_disjoint32_float_double:
7303 ; CHECK: # %bb.0: # %entry
7304 ; CHECK-NEXT: ori r3, r3, 34463
7305 ; CHECK-NEXT: oris r3, r3, 1
7306 ; CHECK-NEXT: stfd f1, 0(r3)
7309 %conv = fpext float %str to double
7310 %or = or i64 %ptr, 99999
7311 %0 = inttoptr i64 %or to double*
7312 store double %conv, double* %0, align 8
7316 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7317 define dso_local void @st_disjoint_align32_float_double(i64 %ptr, float %str) {
7318 ; CHECK-P10-LABEL: st_disjoint_align32_float_double:
7319 ; CHECK-P10: # %bb.0: # %entry
7320 ; CHECK-P10-NEXT: lis r4, -15264
7321 ; CHECK-P10-NEXT: and r3, r3, r4
7322 ; CHECK-P10-NEXT: pli r4, 999990000
7323 ; CHECK-P10-NEXT: stfdx f1, r3, r4
7324 ; CHECK-P10-NEXT: blr
7326 ; CHECK-P9-LABEL: st_disjoint_align32_float_double:
7327 ; CHECK-P9: # %bb.0: # %entry
7328 ; CHECK-P9-NEXT: lis r4, -15264
7329 ; CHECK-P9-NEXT: and r3, r3, r4
7330 ; CHECK-P9-NEXT: lis r4, 15258
7331 ; CHECK-P9-NEXT: ori r4, r4, 41712
7332 ; CHECK-P9-NEXT: stfdx f1, r3, r4
7333 ; CHECK-P9-NEXT: blr
7335 ; CHECK-P8-LABEL: st_disjoint_align32_float_double:
7336 ; CHECK-P8: # %bb.0: # %entry
7337 ; CHECK-P8-NEXT: lis r4, -15264
7338 ; CHECK-P8-NEXT: lis r5, 15258
7339 ; CHECK-P8-NEXT: and r3, r3, r4
7340 ; CHECK-P8-NEXT: ori r4, r5, 41712
7341 ; CHECK-P8-NEXT: stfdx f1, r3, r4
7342 ; CHECK-P8-NEXT: blr
7344 %and = and i64 %ptr, -1000341504
7345 %conv = fpext float %str to double
7346 %or = or i64 %and, 999990000
7347 %0 = inttoptr i64 %or to double*
7348 store double %conv, double* %0, align 16
7352 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7353 define dso_local void @st_not_disjoint64_float_double(i64 %ptr, float %str) {
7354 ; CHECK-P10-LABEL: st_not_disjoint64_float_double:
7355 ; CHECK-P10: # %bb.0: # %entry
7356 ; CHECK-P10-NEXT: pli r4, 232
7357 ; CHECK-P10-NEXT: pli r5, 3567587329
7358 ; CHECK-P10-NEXT: rldimi r5, r4, 32, 0
7359 ; CHECK-P10-NEXT: or r3, r3, r5
7360 ; CHECK-P10-NEXT: stfd f1, 0(r3)
7361 ; CHECK-P10-NEXT: blr
7363 ; CHECK-PREP10-LABEL: st_not_disjoint64_float_double:
7364 ; CHECK-PREP10: # %bb.0: # %entry
7365 ; CHECK-PREP10-NEXT: li r4, 29
7366 ; CHECK-PREP10-NEXT: rldic r4, r4, 35, 24
7367 ; CHECK-PREP10-NEXT: oris r4, r4, 54437
7368 ; CHECK-PREP10-NEXT: ori r4, r4, 4097
7369 ; CHECK-PREP10-NEXT: or r3, r3, r4
7370 ; CHECK-PREP10-NEXT: stfd f1, 0(r3)
7371 ; CHECK-PREP10-NEXT: blr
7373 %conv = fpext float %str to double
7374 %or = or i64 %ptr, 1000000000001
7375 %0 = inttoptr i64 %or to double*
7376 store double %conv, double* %0, align 8
7380 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7381 define dso_local void @st_disjoint_align64_float_double(i64 %ptr, float %str) {
7382 ; CHECK-P10-LABEL: st_disjoint_align64_float_double:
7383 ; CHECK-P10: # %bb.0: # %entry
7384 ; CHECK-P10-NEXT: pli r4, 244140625
7385 ; CHECK-P10-NEXT: rldicr r3, r3, 0, 23
7386 ; CHECK-P10-NEXT: rldic r4, r4, 12, 24
7387 ; CHECK-P10-NEXT: stfdx f1, r3, r4
7388 ; CHECK-P10-NEXT: blr
7390 ; CHECK-PREP10-LABEL: st_disjoint_align64_float_double:
7391 ; CHECK-PREP10: # %bb.0: # %entry
7392 ; CHECK-PREP10-NEXT: lis r4, 3725
7393 ; CHECK-PREP10-NEXT: rldicr r3, r3, 0, 23
7394 ; CHECK-PREP10-NEXT: ori r4, r4, 19025
7395 ; CHECK-PREP10-NEXT: rldic r4, r4, 12, 24
7396 ; CHECK-PREP10-NEXT: stfdx f1, r3, r4
7397 ; CHECK-PREP10-NEXT: blr
7399 %and = and i64 %ptr, -1099511627776
7400 %conv = fpext float %str to double
7401 %or = or i64 %and, 1000000000000
7402 %0 = inttoptr i64 %or to double*
7403 store double %conv, double* %0, align 4096
7407 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7408 define dso_local void @st_cst_align16_float_double(float %str) {
7409 ; CHECK-LABEL: st_cst_align16_float_double:
7410 ; CHECK: # %bb.0: # %entry
7411 ; CHECK-NEXT: stfd f1, 4080(0)
7414 %conv = fpext float %str to double
7415 store double %conv, double* inttoptr (i64 4080 to double*), align 16
7419 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7420 define dso_local void @st_cst_align32_float_double(float %str) {
7421 ; CHECK-LABEL: st_cst_align32_float_double:
7422 ; CHECK: # %bb.0: # %entry
7423 ; CHECK-NEXT: lis r3, 153
7424 ; CHECK-NEXT: stfd f1, -27108(r3)
7427 %conv = fpext float %str to double
7428 store double %conv, double* inttoptr (i64 9999900 to double*), align 8
7432 ; Function Attrs: nofree norecurse nounwind uwtable willreturn writeonly
7433 define dso_local void @st_cst_align64_float_double(float %str) {
7434 ; CHECK-P10-LABEL: st_cst_align64_float_double:
7435 ; CHECK-P10: # %bb.0: # %entry
7436 ; CHECK-P10-NEXT: pli r3, 244140625
7437 ; CHECK-P10-NEXT: rldic r3, r3, 12, 24
7438 ; CHECK-P10-NEXT: stfd f1, 0(r3)
7439 ; CHECK-P10-NEXT: blr
7441 ; CHECK-PREP10-LABEL: st_cst_align64_float_double:
7442 ; CHECK-PREP10: # %bb.0: # %entry
7443 ; CHECK-PREP10-NEXT: lis r3, 3725
7444 ; CHECK-PREP10-NEXT: ori r3, r3, 19025
7445 ; CHECK-PREP10-NEXT: rldic r3, r3, 12, 24
7446 ; CHECK-PREP10-NEXT: stfd f1, 0(r3)
7447 ; CHECK-PREP10-NEXT: blr
7449 %conv = fpext float %str to double
7450 store double %conv, double* inttoptr (i64 1000000000000 to double*), align 4096