1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -O3 -mtriple powerpc-ibm-aix -verify-machineinstrs < %s | FileCheck --check-prefix=32BIT %s
3 ; RUN: llc -O3 -mtriple powerpc64-ibm-aix -verify-machineinstrs < %s | FileCheck --check-prefix=64BIT %s
5 ; Function Attrs: nounwind strictfp
6 define i64 @tester_s(double %d) local_unnamed_addr #0 {
7 ; 32BIT-LABEL: tester_s:
8 ; 32BIT: # %bb.0: # %entry
9 ; 32BIT-NEXT: xscvdpsxds 0, 1
10 ; 32BIT-NEXT: stfd 0, -8(1)
11 ; 32BIT-NEXT: lwz 3, -8(1)
12 ; 32BIT-NEXT: lwz 4, -4(1)
15 ; 64BIT-LABEL: tester_s:
16 ; 64BIT: # %bb.0: # %entry
17 ; 64BIT-NEXT: xscvdpsxds 0, 1
18 ; 64BIT-NEXT: stfd 0, -8(1)
19 ; 64BIT-NEXT: ld 3, -8(1)
22 %conv = tail call i64 @llvm.experimental.constrained.fptosi.i64.f64(double %d, metadata !"fpexcept.ignore") #2
26 ; Function Attrs: nounwind strictfp
27 define i64 @tester_u(double %d) local_unnamed_addr #0 {
28 ; 32BIT-LABEL: tester_u:
29 ; 32BIT: # %bb.0: # %entry
30 ; 32BIT-NEXT: xscvdpuxds 0, 1
31 ; 32BIT-NEXT: stfd 0, -8(1)
32 ; 32BIT-NEXT: lwz 3, -8(1)
33 ; 32BIT-NEXT: lwz 4, -4(1)
36 ; 64BIT-LABEL: tester_u:
37 ; 64BIT: # %bb.0: # %entry
38 ; 64BIT-NEXT: xscvdpuxds 0, 1
39 ; 64BIT-NEXT: stfd 0, -8(1)
40 ; 64BIT-NEXT: ld 3, -8(1)
43 %conv = tail call i64 @llvm.experimental.constrained.fptoui.i64.f64(double %d, metadata !"fpexcept.ignore") #2
47 ; Function Attrs: nounwind
48 declare i64 @llvm.experimental.constrained.fptosi.i64.f64(double, metadata) #1
49 declare i64 @llvm.experimental.constrained.fptoui.i64.f64(double, metadata) #1
51 attributes #0 = { nounwind strictfp "target-cpu"="pwr7" }
52 attributes #1 = { nounwind }