1 ; RUN: llc -mtriple x86_64-windows < %s | FileCheck %s
3 declare double @llvm.powi.f64.i32(double, i32)
4 declare float @llvm.powi.f32.i32(float, i32)
6 define double @d(double %d, i32 %i) {
8 %0 = tail call double @llvm.powi.f64.i32(double %d, i32 %i)
13 ; CHECK: cvtsi2sd %edx, %xmm1
16 define float @f(float %f, i32 %i) {
18 %0 = tail call float @llvm.powi.f32.i32(float %f, i32 %i)
23 ; CHECK: cvtsi2ss %edx, %xmm1
24 ; CHECK-NEXT: jmp powf
26 define float @g(double %d, i32 %i) {
28 %0 = tail call double @llvm.powi.f64.i32(double %d, i32 %i)
29 %conv = fptrunc double %0 to float
34 ; CHECK: cvtsi2sd %edx, %xmm1
35 ; CHECK-NEXT: callq pow
37 define double @h(float %f, i32 %i) {
39 %0 = tail call float @llvm.powi.f32.i32(float %f, i32 %i)
40 %conv = fpext float %0 to double
45 ; CHECK: cvtsi2ss %edx, %xmm1
46 ; CHECK-NEXT: callq powf