#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
double powf(float, double);
float compute_wind_chill(float air_temperature_F, float wind_speed_MPH) {
  if ((air_temperature_F >= -50.0) && (air_temperature_F <= 50.0) &&
      (wind_speed_MPH >= 3.0) && (wind_speed_MPH <= 110.0)) {
    return (35.74 + (0.6215 * air_temperature_F) -
            (35.75 * powf(wind_speed_MPH, 0.16)) +
            (0.4275 * air_temperature_F * powf(wind_speed_MPH, 0.16)));
  } else {
    return (air_temperature_F - (1.5 * wind_speed_MPH));
  }
}


x86 assembly (clang, -O0):
<compute_wind_chill>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movss  %xmm0,-0x8(%rbp)
movss  %xmm1,-0xc(%rbp)
movss  -0x8(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  0xecd(%rip),%xmm1
ucomisd %xmm1,%xmm0
jb     122f <compute_wind_chill+0x11f>
movss  -0x8(%rbp),%xmm0
cvtss2sd %xmm0,%xmm1
movsd  0xeba(%rip),%xmm0
ucomisd %xmm1,%xmm0
jb     122f <compute_wind_chill+0x11f>
movss  -0xc(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  0xea7(%rip),%xmm1
ucomisd %xmm1,%xmm0
jb     122f <compute_wind_chill+0x11f>
movss  -0xc(%rbp),%xmm0
cvtss2sd %xmm0,%xmm1
movsd  0xe94(%rip),%xmm0
ucomisd %xmm1,%xmm0
jb     122f <compute_wind_chill+0x11f>
movss  -0x8(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  0xea1(%rip),%xmm1
mulsd  %xmm1,%xmm0
movsd  0xe9d(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x28(%rbp)
movss  -0xc(%rbp),%xmm0
movsd  0xe67(%rip),%xmm1
call   1030 <powf@plt>
movsd  -0x28(%rbp),%xmm1
movsd  0xe65(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x20(%rbp)
movss  -0x8(%rbp),%xmm0
cvtss2sd %xmm0,%xmm1
movsd  0xe3f(%rip),%xmm0
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x18(%rbp)
movss  -0xc(%rbp),%xmm0
movsd  0xe21(%rip),%xmm1
call   1030 <powf@plt>
movsd  -0x20(%rbp),%xmm1
movaps %xmm0,%xmm2
movsd  -0x18(%rbp),%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,-0x4(%rbp)
jmp    125a <compute_wind_chill+0x14a>
movss  -0x8(%rbp),%xmm0
cvtss2sd %xmm0,%xmm1
movss  -0xc(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  0xdd7(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<compute_wind_chill>:
sub    $0x18,%rsp
movaps %xmm1,%xmm3
cvtss2sd %xmm0,%xmm2
movss  0xedd(%rip),%xmm1
ucomiss %xmm3,%xmm1
jb     11ce <compute_wind_chill+0xbe>
ucomiss 0xed1(%rip),%xmm0
jb     11ce <compute_wind_chill+0xbe>
movss  0xec7(%rip),%xmm1
ucomiss %xmm0,%xmm1
jb     11ce <compute_wind_chill+0xbe>
ucomiss 0xebb(%rip),%xmm3
jb     11ce <compute_wind_chill+0xbe>
movsd  0xeb5(%rip),%xmm0
mulsd  %xmm2,%xmm0
addsd  0xeb1(%rip),%xmm0
movsd  %xmm0,(%rsp)
movsd  0xeac(%rip),%xmm1
movaps %xmm3,%xmm0
movsd  %xmm2,0x8(%rsp)
movss  %xmm3,0x14(%rsp)
call   1030 <powf@plt>
mulsd  0xe98(%rip),%xmm0
addsd  (%rsp),%xmm0
movsd  %xmm0,(%rsp)
movsd  0x8(%rsp),%xmm0
mulsd  0xe88(%rip),%xmm0
movsd  %xmm0,0x8(%rsp)
movss  0x14(%rsp),%xmm0
movsd  0xe64(%rip),%xmm1
call   1030 <powf@plt>
mulsd  0x8(%rsp),%xmm0
addsd  (%rsp),%xmm0
jmp    11e1 <compute_wind_chill+0xd1>
xorps  %xmm0,%xmm0
cvtss2sd %xmm3,%xmm0
mulsd  0xe5b(%rip),%xmm0
addsd  %xmm2,%xmm0
cvtsd2ss %xmm0,%xmm0
add    $0x18,%rsp
ret

LLVM IR (-O0):
define float @compute_wind_chill(float %0, float %1) {
%3 = alloca float
%4 = alloca float
%5 = alloca float
store float %0, float* %4
store float %1, float* %5
%6 = load float, float* %4
%7 = fpext float %6 to double
%8 = fcmp oge double %7, -5.000000e+01
br i1 %8, label %9, label %35
9: ; preds = %2
%10 = load float, float* %4
%11 = fpext float %10 to double
%12 = fcmp ole double %11, 5.000000e+01
br i1 %12, label %13, label %35
13: ; preds = %9
%14 = load float, float* %5
%15 = fpext float %14 to double
%16 = fcmp oge double %15, 3.000000e+00
br i1 %16, label %17, label %35
17: ; preds = %13
%18 = load float, float* %5
%19 = fpext float %18 to double
%20 = fcmp ole double %19, 1.100000e+02
br i1 %20, label %21, label %35
21: ; preds = %17
%22 = load float, float* %4
%23 = fpext float %22 to double
%24 = call double @llvm.fmuladd.f64(double 6.215000e-01, double %23, double 3.574000e+01)
%25 = load float, float* %5
%26 = call double @powf(float %25, double 1.600000e-01)
%27 = call double @llvm.fmuladd.f64(double -3.575000e+01, double %26, double %24)
%28 = load float, float* %4
%29 = fpext float %28 to double
%30 = fmul double 4.275000e-01, %29
%31 = load float, float* %5
%32 = call double @powf(float %31, double 1.600000e-01)
%33 = call double @llvm.fmuladd.f64(double %30, double %32, double %27)
%34 = fptrunc double %33 to float
store float %34, float* %3
br label %42
35: ; preds = %17, %13, %9, %2
%36 = load float, float* %4
%37 = fpext float %36 to double
%38 = load float, float* %5
%39 = fpext float %38 to double
%40 = call double @llvm.fmuladd.f64(double -1.500000e+00, double %39, double %37)
%41 = fptrunc double %40 to float
store float %41, float* %3
br label %42
42: ; preds = %35, %21
%43 = load float, float* %3
ret float %43
}

LLVM IR (-O2):
define float @compute_wind_chill(float %0, float %1) {
%3 = fpext float %0 to double
%4 = fcmp ult float %0, -5.000000e+01
%5 = fcmp ugt float %0, 5.000000e+01
%6 = or i1 %4, %5
%7 = fcmp ult float %1, 3.000000e+00
%8 = or i1 %6, %7
%9 = fcmp ugt float %1, 1.100000e+02
%10 = or i1 %9, %8
br i1 %10, label %18, label %11
11: ; preds = %2
%12 = tail call double @llvm.fmuladd.f64(double %3, double 6.215000e-01, double 3.574000e+01)
%13 = tail call double @powf(float %1, double 1.600000e-01)
%14 = tail call double @llvm.fmuladd.f64(double %13, double -3.575000e+01, double %12)
%15 = fmul double %3, 4.275000e-01
%16 = tail call double @powf(float %1, double 1.600000e-01)
%17 = tail call double @llvm.fmuladd.f64(double %15, double %16, double %14)
br label %21
18: ; preds = %2
%19 = fpext float %1 to double
%20 = tail call double @llvm.fmuladd.f64(double %19, double -1.500000e+00, double %3)
br label %21
21: ; preds = %18, %11
%22 = phi double [ %17, %11 ], [ %20, %18 ]
%23 = fptrunc double %22 to float
ret float %23
}