1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
3 ; RUN: llc -mtriple=powerpc64le-unknown-linux-gnu -global-isel -ppc-vsr-nums-as-vr \
4 ; RUN: -ppc-asm-full-reg-names -verify-machineinstrs -o - < %s | FileCheck %s
6 define i64 @fptosi_float_i64(float %i) {
7 ; CHECK-LABEL: fptosi_float_i64:
8 ; CHECK: # %bb.0: # %entry
9 ; CHECK-NEXT: xscvdpsxds f0, f1
10 ; CHECK-NEXT: mffprd r3, f0
13 %conv = fptosi float %i to i64
17 define i64 @fptosi_double_i64(double %i) {
18 ; CHECK-LABEL: fptosi_double_i64:
19 ; CHECK: # %bb.0: # %entry
20 ; CHECK-NEXT: xscvdpsxds f0, f1
21 ; CHECK-NEXT: mffprd r3, f0
24 %conv = fptosi double %i to i64
28 define i64 @fptoui_float_i64(float %i) {
29 ; CHECK-LABEL: fptoui_float_i64:
30 ; CHECK: # %bb.0: # %entry
31 ; CHECK-NEXT: xscvdpuxds f0, f1
32 ; CHECK-NEXT: mffprd r3, f0
35 %conv = fptoui float %i to i64
39 define i64 @fptoui_double_i64(double %i) {
40 ; CHECK-LABEL: fptoui_double_i64:
41 ; CHECK: # %bb.0: # %entry
42 ; CHECK-NEXT: xscvdpuxds f0, f1
43 ; CHECK-NEXT: mffprd r3, f0
46 %conv = fptoui double %i to i64
50 define float @sitofp_i64_float(i64 %i) {
51 ; CHECK-LABEL: sitofp_i64_float:
52 ; CHECK: # %bb.0: # %entry
53 ; CHECK-NEXT: mtfprd f0, r3
54 ; CHECK-NEXT: xscvsxdsp f1, f0
57 %conv = sitofp i64 %i to float
61 define double @sitofp_i64_double(i64 %i) {
62 ; CHECK-LABEL: sitofp_i64_double:
63 ; CHECK: # %bb.0: # %entry
64 ; CHECK-NEXT: mtfprd f0, r3
65 ; CHECK-NEXT: xscvsxddp f1, f0
68 %conv = sitofp i64 %i to double
72 define float @uitofp_i64_float(i64 %i) {
73 ; CHECK-LABEL: uitofp_i64_float:
74 ; CHECK: # %bb.0: # %entry
75 ; CHECK-NEXT: mtfprd f0, r3
76 ; CHECK-NEXT: xscvuxdsp f1, f0
79 %conv = uitofp i64 %i to float
83 define double @uitofp_i64_double(i64 %i) {
84 ; CHECK-LABEL: uitofp_i64_double:
85 ; CHECK: # %bb.0: # %entry
86 ; CHECK-NEXT: mtfprd f0, r3
87 ; CHECK-NEXT: xscvuxddp f1, f0
90 %conv = uitofp i64 %i to double