#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 */
int /*<<< orphan*/ exit(int);
double pow(double, int);
double F(double rho_) {
  if (rho_ < 1.)
    return -2.28235 + .5 * 1.35535 * pow(rho_ - 1., 2.) +
           -1.27775 * pow(rho_ - 1., 3.) + -0.86074 * pow(rho_ - 1., 4.) +
           1.78804 * pow(rho_ - 1., 5.) + 2.97571 * pow(rho_ - 1., 6.);
  else if (rho_ > 1.)
    return (-2.28235 + .5 * 1.35535 * pow(rho_ - 1., 2.) +
            -1.27775 * pow(rho_ - 1., 3.) + 0.4 * pow(rho_ - 1., 4.)) /
           (1. + 0.3 * pow(rho_ - 1., 3.));
  else
    exit(-1);
}


x86 assembly (clang, -O0):
<F>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
movsd  %xmm0,-0x10(%rbp)
movsd  0xecb(%rip),%xmm0
ucomisd -0x10(%rbp),%xmm0
jbe    1251 <F+0x131>
movsd  -0x10(%rbp),%xmm0
movsd  0xeb3(%rip),%xmm1
subsd  %xmm1,%xmm0
mov    $0x2,%edi
call   1030 <pow@plt>
movsd  0xebd(%rip),%xmm1
mulsd  %xmm1,%xmm0
movsd  0xeb9(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x30(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  0xe7b(%rip),%xmm1
subsd  %xmm1,%xmm0
mov    $0x3,%edi
call   1030 <pow@plt>
movsd  -0x30(%rbp),%xmm1
movsd  0xe78(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x28(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  0xe46(%rip),%xmm1
subsd  %xmm1,%xmm0
mov    $0x4,%edi
call   1030 <pow@plt>
movsd  -0x28(%rbp),%xmm1
movsd  0xe6b(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x20(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  0xe11(%rip),%xmm1
subsd  %xmm1,%xmm0
mov    $0x5,%edi
call   1030 <pow@plt>
movsd  -0x20(%rbp),%xmm1
movsd  0xe2e(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x18(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  0xddc(%rip),%xmm1
subsd  %xmm1,%xmm0
mov    $0x6,%edi
call   1030 <pow@plt>
movsd  -0x18(%rbp),%xmm1
movsd  0xdf1(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x8(%rbp)
jmp    135d <F+0x23d>
movsd  -0x10(%rbp),%xmm0
movsd  0xda2(%rip),%xmm1
ucomisd %xmm1,%xmm0
jbe    1353 <F+0x233>
movsd  -0x10(%rbp),%xmm0
movsd  0xd8b(%rip),%xmm1
subsd  %xmm1,%xmm0
mov    $0x2,%edi
call   1030 <pow@plt>
movsd  0xd95(%rip),%xmm1
mulsd  %xmm1,%xmm0
movsd  0xd91(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x48(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  0xd53(%rip),%xmm1
subsd  %xmm1,%xmm0
mov    $0x3,%edi
call   1030 <pow@plt>
movsd  -0x48(%rbp),%xmm1
movsd  0xd50(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x40(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  0xd1e(%rip),%xmm1
subsd  %xmm1,%xmm0
mov    $0x4,%edi
call   1030 <pow@plt>
movsd  -0x40(%rbp),%xmm1
movsd  0xd13(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x38(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  0xce9(%rip),%xmm1
subsd  %xmm1,%xmm0
mov    $0x3,%edi
call   1030 <pow@plt>
movaps %xmm0,%xmm1
movsd  -0x38(%rbp),%xmm0
movsd  0xcd3(%rip),%xmm2
mulsd  %xmm2,%xmm1
movsd  0xcbf(%rip),%xmm2
addsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x8(%rbp)
jmp    135d <F+0x23d>
mov    $0xffffffff,%edi
call   1040 <exit@plt>
movsd  -0x8(%rbp),%xmm0
add    $0x50,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<F>:
sub    $0x38,%rsp
movsd  0xed4(%rip),%xmm1
ucomisd %xmm0,%xmm1
jbe    11f3 <F+0xd3>
addsd  0xeca(%rip),%xmm0
movsd  %xmm0,0x8(%rsp)
mov    $0x2,%edi
call   1030 <pow@plt>
mulsd  0xeba(%rip),%xmm0
addsd  0xeba(%rip),%xmm0
movsd  %xmm0,0x10(%rsp)
movsd  0x8(%rsp),%xmm0
mov    $0x3,%edi
call   1030 <pow@plt>
mulsd  0xea4(%rip),%xmm0
addsd  0x10(%rsp),%xmm0
movsd  %xmm0,0x10(%rsp)
movsd  0x8(%rsp),%xmm0
mov    $0x4,%edi
call   1030 <pow@plt>
mulsd  0xe88(%rip),%xmm0
addsd  0x10(%rsp),%xmm0
movsd  %xmm0,0x10(%rsp)
movsd  0x8(%rsp),%xmm0
mov    $0x5,%edi
call   1030 <pow@plt>
mulsd  0xe6c(%rip),%xmm0
addsd  0x10(%rsp),%xmm0
movsd  %xmm0,0x10(%rsp)
movsd  0x8(%rsp),%xmm0
mov    $0x6,%edi
call   1030 <pow@plt>
mulsd  0xe50(%rip),%xmm0
addsd  0x10(%rsp),%xmm0
add    $0x38,%rsp
ret
ucomisd 0xe05(%rip),%xmm0
jbe    12b2 <F+0x192>
addsd  0xdff(%rip),%xmm0
movsd  %xmm0,0x8(%rsp)
mov    $0x2,%edi
call   1030 <pow@plt>
mulsd  0xdef(%rip),%xmm0
addsd  0xdef(%rip),%xmm0
movsd  %xmm0,0x10(%rsp)
movsd  0x8(%rsp),%xmm0
mov    $0x3,%edi
call   1030 <pow@plt>
mulsd  0xdd9(%rip),%xmm0
addsd  0x10(%rsp),%xmm0
movapd %xmm0,0x10(%rsp)
movsd  0x8(%rsp),%xmm0
mov    $0x4,%edi
call   1030 <pow@plt>
movaps %xmm0,0x20(%rsp)
movsd  0x8(%rsp),%xmm0
mov    $0x3,%edi
call   1030 <pow@plt>
movapd 0x20(%rsp),%xmm1
unpcklpd %xmm0,%xmm1
movapd 0x10(%rsp),%xmm0
shufpd $0x2,0xdaf(%rip),%xmm0
mulpd  0xdb7(%rip),%xmm1
addpd  %xmm0,%xmm1
movapd %xmm1,%xmm0
unpckhpd %xmm1,%xmm0
divsd  %xmm0,%xmm1
movapd %xmm1,%xmm0
add    $0x38,%rsp
ret
mov    $0xffffffff,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
define double @F(double %0) {
%2 = alloca double
%3 = alloca double
store double %0, double* %3
%4 = load double, double* %3
%5 = fcmp olt double %4, 1.000000e+00
br i1 %5, label %6, label %27
6: ; preds = %1
%7 = load double, double* %3
%8 = fsub double %7, 1.000000e+00
%9 = call double @pow(double %8, i32 2)
%10 = call double @llvm.fmuladd.f64(double 6.776750e-01, double %9, double -2.282350e+00)
%11 = load double, double* %3
%12 = fsub double %11, 1.000000e+00
%13 = call double @pow(double %12, i32 3)
%14 = call double @llvm.fmuladd.f64(double -1.277750e+00, double %13, double %10)
%15 = load double, double* %3
%16 = fsub double %15, 1.000000e+00
%17 = call double @pow(double %16, i32 4)
%18 = call double @llvm.fmuladd.f64(double -8.607400e-01, double %17, double %14)
%19 = load double, double* %3
%20 = fsub double %19, 1.000000e+00
%21 = call double @pow(double %20, i32 5)
%22 = call double @llvm.fmuladd.f64(double 1.788040e+00, double %21, double %18)
%23 = load double, double* %3
%24 = fsub double %23, 1.000000e+00
%25 = call double @pow(double %24, i32 6)
%26 = call double @llvm.fmuladd.f64(double 2.975710e+00, double %25, double %22)
store double %26, double* %2
br label %50
27: ; preds = %1
%28 = load double, double* %3
%29 = fcmp ogt double %28, 1.000000e+00
br i1 %29, label %30, label %48
30: ; preds = %27
%31 = load double, double* %3
%32 = fsub double %31, 1.000000e+00
%33 = call double @pow(double %32, i32 2)
%34 = call double @llvm.fmuladd.f64(double 6.776750e-01, double %33, double -2.282350e+00)
%35 = load double, double* %3
%36 = fsub double %35, 1.000000e+00
%37 = call double @pow(double %36, i32 3)
%38 = call double @llvm.fmuladd.f64(double -1.277750e+00, double %37, double %34)
%39 = load double, double* %3
%40 = fsub double %39, 1.000000e+00
%41 = call double @pow(double %40, i32 4)
%42 = call double @llvm.fmuladd.f64(double 4.000000e-01, double %41, double %38)
%43 = load double, double* %3
%44 = fsub double %43, 1.000000e+00
%45 = call double @pow(double %44, i32 3)
%46 = call double @llvm.fmuladd.f64(double 3.000000e-01, double %45, double 1.000000e+00)
%47 = fdiv double %42, %46
store double %47, double* %2
br label %50
48: ; preds = %27
%49 = call i32 @exit(i32 -1)
unreachable
50: ; preds = %30, %6
%51 = load double, double* %2
ret double %51
}

LLVM IR (-O2):
define double @F(double %0) {
%2 = fcmp olt double %0, 1.000000e+00
br i1 %2, label %3, label %15
3: ; preds = %1
%4 = fadd double %0, -1.000000e+00
%5 = tail call double @pow(double %4, i32 2)
%6 = tail call double @llvm.fmuladd.f64(double %5, double 6.776750e-01, double -2.282350e+00)
%7 = tail call double @pow(double %4, i32 3)
%8 = tail call double @llvm.fmuladd.f64(double %7, double -1.277750e+00, double %6)
%9 = tail call double @pow(double %4, i32 4)
%10 = tail call double @llvm.fmuladd.f64(double %9, double -8.607400e-01, double %8)
%11 = tail call double @pow(double %4, i32 5)
%12 = tail call double @llvm.fmuladd.f64(double %11, double 1.788040e+00, double %10)
%13 = tail call double @pow(double %4, i32 6)
%14 = tail call double @llvm.fmuladd.f64(double %13, double 2.975710e+00, double %12)
br label %34
15: ; preds = %1
%16 = fcmp ogt double %0, 1.000000e+00
br i1 %16, label %17, label %32
17: ; preds = %15
%18 = fadd double %0, -1.000000e+00
%19 = tail call double @pow(double %18, i32 2)
%20 = tail call double @llvm.fmuladd.f64(double %19, double 6.776750e-01, double -2.282350e+00)
%21 = tail call double @pow(double %18, i32 3)
%22 = tail call double @llvm.fmuladd.f64(double %21, double -1.277750e+00, double %20)
%23 = tail call double @pow(double %18, i32 4)
%24 = tail call double @pow(double %18, i32 3)
%25 = insertelement <2 x double> poison, double %23, i64 0
%26 = insertelement <2 x double> %25, double %24, i64 1
%27 = insertelement <2 x double> <double poison, double 1.000000e+00>, double %22, i64 0
%28 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %26, <2 x double> <double 4.000000e-01, double 3.000000e-01>, <2 x double> %27)
%29 = extractelement <2 x double> %28, i64 0
%30 = extractelement <2 x double> %28, i64 1
%31 = fdiv double %29, %30
br label %34
32: ; preds = %15
%33 = tail call i32 @exit(i32 -1)
unreachable
34: ; preds = %17, %3
%35 = phi double [ %14, %3 ], [ %31, %17 ]
ret double %35
}