#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 exp(double);
double sqrt(double);
double airBesselI0(double x) {
  double b, ax, y;
  ax = ((x) > 0.0f ? (x) : -(x));
  if (ax < 5.664804810929075) {
    y = x / 5.7;
    y *= y;
    b = (0.9999999996966272 +
         y * (7.7095783675529646 +
              y * (13.211021909077445 +
                   y * (8.648398832703904 +
                        (2.5427099920536578 + 0.3103650754941674 * y) * y)))) /
        (1 + y * (-0.41292170755003793 +
                  (0.07122966874756179 - 0.005182728492608365 * y) * y));
  } else {
    y = 5.7 / ax;
    b = (0.398942280546057 +
         y * (-0.749709626164583 +
              y * (0.507462772839054 +
                   y * (-0.0918770649691261 +
                        (-0.00135238228377743 - 0.0000897561853670307 * y) *
                            y)))) /
        (1 + y * (-1.90117313211089 +
                  (1.31154807540649 - 0.255339661975509 * y) * y));
    b *= (exp(ax) / sqrt(ax));
  }
  return b;
}


x86 assembly (clang, -O0):
<airBesselI0>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movsd  %xmm0,-0x8(%rbp)
movsd  -0x8(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jbe    114e <airBesselI0+0x2e>
movsd  -0x8(%rbp),%xmm0
movsd  %xmm0,-0x28(%rbp)
jmp    116f <airBesselI0+0x4f>
movsd  -0x8(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  %xmm0,-0x28(%rbp)
movsd  -0x28(%rbp),%xmm0
movsd  %xmm0,-0x18(%rbp)
movsd  0xe7f(%rip),%xmm0
ucomisd -0x18(%rbp),%xmm0
jbe    1277 <airBesselI0+0x157>
movsd  -0x8(%rbp),%xmm0
movsd  0xebf(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x20(%rbp)
movsd  -0x20(%rbp),%xmm0
mulsd  -0x20(%rbp),%xmm0
movsd  %xmm0,-0x20(%rbp)
movsd  -0x20(%rbp),%xmm0
movsd  -0x20(%rbp),%xmm1
movsd  -0x20(%rbp),%xmm2
movsd  -0x20(%rbp),%xmm3
movsd  0xecb(%rip),%xmm4
mulsd  %xmm4,%xmm3
movsd  0xec7(%rip),%xmm4
addsd  %xmm4,%xmm3
movsd  -0x20(%rbp),%xmm4
mulsd  %xmm4,%xmm3
movsd  0xea2(%rip),%xmm4
addsd  %xmm4,%xmm3
mulsd  %xmm3,%xmm2
movsd  0xe8a(%rip),%xmm3
addsd  %xmm3,%xmm2
mulsd  %xmm2,%xmm1
movsd  0xe72(%rip),%xmm2
addsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
movsd  0xe5a(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  -0x20(%rbp),%xmm1
movsd  -0x20(%rbp),%xmm2
movsd  0xe34(%rip),%xmm3
mulsd  %xmm3,%xmm2
movsd  0xe30(%rip),%xmm3
addsd  %xmm3,%xmm2
movsd  -0x20(%rbp),%xmm3
mulsd  %xmm3,%xmm2
movsd  0xe0b(%rip),%xmm3
addsd  %xmm3,%xmm2
mulsd  %xmm2,%xmm1
movsd  0xda3(%rip),%xmm2
addsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x10(%rbp)
jmp    1379 <airBesselI0+0x259>
movsd  0xdd9(%rip),%xmm0
divsd  -0x18(%rbp),%xmm0
movsd  %xmm0,-0x20(%rbp)
movsd  -0x20(%rbp),%xmm0
movsd  -0x20(%rbp),%xmm1
movsd  -0x20(%rbp),%xmm2
movsd  -0x20(%rbp),%xmm3
movsd  0xda3(%rip),%xmm4
mulsd  %xmm4,%xmm3
movsd  0xd9f(%rip),%xmm4
addsd  %xmm4,%xmm3
movsd  -0x20(%rbp),%xmm4
mulsd  %xmm4,%xmm3
movsd  0xd7a(%rip),%xmm4
addsd  %xmm4,%xmm3
mulsd  %xmm3,%xmm2
movsd  0xd62(%rip),%xmm3
addsd  %xmm3,%xmm2
mulsd  %xmm2,%xmm1
movsd  0xd4a(%rip),%xmm2
addsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
movsd  0xd32(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  -0x20(%rbp),%xmm1
movsd  -0x20(%rbp),%xmm2
movsd  0xd0c(%rip),%xmm3
mulsd  %xmm3,%xmm2
movsd  0xd08(%rip),%xmm3
addsd  %xmm3,%xmm2
movsd  -0x20(%rbp),%xmm3
mulsd  %xmm3,%xmm2
movsd  0xce3(%rip),%xmm3
addsd  %xmm3,%xmm2
mulsd  %xmm2,%xmm1
movsd  0xccb(%rip),%xmm2
addsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x10(%rbp)
movsd  -0x18(%rbp),%xmm0
call   1030 <exp@plt>
movsd  %xmm0,-0x30(%rbp)
movsd  -0x18(%rbp),%xmm0
call   1040 <sqrt@plt>
movaps %xmm0,%xmm1
movsd  -0x30(%rbp),%xmm0
divsd  %xmm1,%xmm0
mulsd  -0x10(%rbp),%xmm0
movsd  %xmm0,-0x10(%rbp)
movsd  -0x10(%rbp),%xmm0
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<airBesselI0>:
sub    $0x38,%rsp
movapd 0xed4(%rip),%xmm1
xorpd  %xmm0,%xmm1
xorpd  %xmm3,%xmm3
cmpltsd %xmm0,%xmm3
movapd %xmm3,%xmm2
andpd  %xmm0,%xmm2
andnpd %xmm1,%xmm3
orpd   %xmm2,%xmm3
movsd  0xedf(%rip),%xmm1
ucomisd %xmm3,%xmm1
jbe    11e0 <airBesselI0+0xc0>
divsd  0xed5(%rip),%xmm0
mulsd  %xmm0,%xmm0
movsd  0xf21(%rip),%xmm1
mulsd  %xmm0,%xmm1
addsd  0xf1d(%rip),%xmm1
mulsd  %xmm0,%xmm1
addsd  0xf19(%rip),%xmm1
mulsd  %xmm0,%xmm1
addsd  0xf15(%rip),%xmm1
movsd  0xf15(%rip),%xmm2
mulsd  %xmm0,%xmm2
addsd  0xf11(%rip),%xmm2
movapd %xmm0,%xmm3
unpcklpd %xmm2,%xmm3
unpcklpd %xmm0,%xmm1
mulpd  %xmm3,%xmm1
addpd  0xe51(%rip),%xmm1
unpcklpd %xmm0,%xmm0
mulpd  %xmm1,%xmm0
addpd  0xe51(%rip),%xmm0
movapd %xmm0,%xmm1
unpckhpd %xmm0,%xmm1
divsd  %xmm1,%xmm0
add    $0x38,%rsp
ret
movsd  0xe50(%rip),%xmm0
divsd  %xmm3,%xmm0
movsd  0xe4c(%rip),%xmm1
mulsd  %xmm0,%xmm1
addsd  0xe48(%rip),%xmm1
mulsd  %xmm0,%xmm1
addsd  0xe44(%rip),%xmm1
mulsd  %xmm0,%xmm1
addsd  0xe40(%rip),%xmm1
mulsd  %xmm0,%xmm1
addsd  0xe3c(%rip),%xmm1
mulsd  %xmm0,%xmm1
addsd  0xe38(%rip),%xmm1
movapd %xmm1,0x20(%rsp)
movsd  0xe32(%rip),%xmm1
mulsd  %xmm0,%xmm1
addsd  0xe2e(%rip),%xmm1
mulsd  %xmm0,%xmm1
addsd  0xe2a(%rip),%xmm1
mulsd  %xmm0,%xmm1
addsd  0xe26(%rip),%xmm1
movapd %xmm1,0x10(%rsp)
movapd %xmm3,%xmm0
movapd %xmm3,(%rsp)
call   1030 <exp@plt>
movapd (%rsp),%xmm1
movapd %xmm0,%xmm3
ucomisd 0xe39(%rip),%xmm1
jb     1292 <airBesselI0+0x172>
xorps  %xmm0,%xmm0
sqrtsd %xmm1,%xmm0
jmp    12a5 <airBesselI0+0x185>
movapd %xmm1,%xmm0
movapd %xmm3,(%rsp)
call   1040 <sqrt@plt>
movapd (%rsp),%xmm3
movapd 0x10(%rsp),%xmm2
unpcklpd %xmm0,%xmm2
movapd 0x20(%rsp),%xmm1
unpcklpd %xmm3,%xmm1
divpd  %xmm2,%xmm1
movapd %xmm1,%xmm0
unpckhpd %xmm1,%xmm0
mulsd  %xmm1,%xmm0
add    $0x38,%rsp
ret

LLVM IR (-O0):
define double @airBesselI0(double %0) {
%2 = alloca double
%3 = alloca double
%4 = alloca double
%5 = alloca double
store double %0, double* %2
%6 = load double, double* %2
%7 = fcmp ogt double %6, 0.000000e+00
br i1 %7, label %8, label %10
8: ; preds = %1
%9 = load double, double* %2
br label %13
10: ; preds = %1
%11 = load double, double* %2
%12 = fneg double %11
br label %13
13: ; preds = %10, %8
%14 = phi double [ %9, %8 ], [ %12, %10 ]
store double %14, double* %4
%15 = load double, double* %4
%16 = fcmp olt double %15, 0x4016A8C297A4A7C6
br i1 %16, label %17, label %40
17: ; preds = %13
%18 = load double, double* %2
%19 = fdiv double %18, 5.700000e+00
store double %19, double* %5
%20 = load double, double* %5
%21 = load double, double* %5
%22 = fmul double %21, %20
store double %22, double* %5
%23 = load double, double* %5
%24 = load double, double* %5
%25 = load double, double* %5
%26 = load double, double* %5
%27 = call double @llvm.fmuladd.f64(double 0x3FD3DD057A445A71, double %26, double 0x400457785618A9BD)
%28 = load double, double* %5
%29 = call double @llvm.fmuladd.f64(double %27, double %28, double 0x40214BFAEE8A74A8)
%30 = call double @llvm.fmuladd.f64(double %25, double %29, double 0x402A6C0B104C7448)
%31 = call double @llvm.fmuladd.f64(double %24, double %30, double 0x401ED69BB62A5B30)
%32 = call double @llvm.fmuladd.f64(double %23, double %31, double 0x3FEFFFFFFFD64E05)
%33 = load double, double* %5
%34 = load double, double* %5
%35 = call double @llvm.fmuladd.f64(double 0xBF753A7C1613A97C, double %34, double 0x3FB23C1B89C693B2)
%36 = load double, double* %5
%37 = call double @llvm.fmuladd.f64(double %35, double %36, double 0xBFDA6D4F2B6F18CF)
%38 = call double @llvm.fmuladd.f64(double %33, double %37, double 1.000000e+00)
%39 = fdiv double %32, %38
store double %39, double* %3
br label %67
40: ; preds = %13
%41 = load double, double* %4
%42 = fdiv double 5.700000e+00, %41
store double %42, double* %5
%43 = load double, double* %5
%44 = load double, double* %5
%45 = load double, double* %5
%46 = load double, double* %5
%47 = call double @llvm.fmuladd.f64(double 0xBF17876F85E74A06, double %46, double 0xBF56284D6B8D89FA)
%48 = load double, double* %5
%49 = call double @llvm.fmuladd.f64(double %47, double %48, double 0xBFB785415D4B7C32)
%50 = call double @llvm.fmuladd.f64(double %45, double %49, double 0x3FE03D2291A8FFB5)
%51 = call double @llvm.fmuladd.f64(double %44, double %50, double 0xBFE7FD9F0ABBF1D4)
%52 = call double @llvm.fmuladd.f64(double %43, double %51, double 0x3FD9884533FBF759)
%53 = load double, double* %5
%54 = load double, double* %5
%55 = call double @llvm.fmuladd.f64(double 0xBFD0577C2A639DCB, double %54, double 0x3FF4FC19D5B00AB8)
%56 = load double, double* %5
%57 = call double @llvm.fmuladd.f64(double %55, double %56, double 0xBFFE6B3484A733DB)
%58 = call double @llvm.fmuladd.f64(double %53, double %57, double 1.000000e+00)
%59 = fdiv double %52, %58
store double %59, double* %3
%60 = load double, double* %4
%61 = call double @exp(double %60)
%62 = load double, double* %4
%63 = call double @sqrt(double %62)
%64 = fdiv double %61, %63
%65 = load double, double* %3
%66 = fmul double %65, %64
store double %66, double* %3
br label %67
67: ; preds = %40, %17
%68 = load double, double* %3
ret double %68
}

LLVM IR (-O2):
define double @airBesselI0(double %0) {
%2 = fcmp ogt double %0, 0.000000e+00
%3 = fneg double %0
%4 = select i1 %2, double %0, double %3
%5 = fcmp olt double %4, 0x4016A8C297A4A7C6
br i1 %5, label %6, label %23
6: ; preds = %1
%7 = fdiv double %0, 5.700000e+00
%8 = fmul double %7, %7
%9 = tail call double @llvm.fmuladd.f64(double %8, double 0x3FD3DD057A445A71, double 0x400457785618A9BD)
%10 = tail call double @llvm.fmuladd.f64(double %9, double %8, double 0x40214BFAEE8A74A8)
%11 = tail call double @llvm.fmuladd.f64(double %8, double %10, double 0x402A6C0B104C7448)
%12 = tail call double @llvm.fmuladd.f64(double %8, double 0xBF753A7C1613A97C, double 0x3FB23C1B89C693B2)
%13 = insertelement <2 x double> poison, double %8, i64 0
%14 = insertelement <2 x double> %13, double %12, i64 1
%15 = insertelement <2 x double> poison, double %11, i64 0
%16 = insertelement <2 x double> %15, double %8, i64 1
%17 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %14, <2 x double> %16, <2 x double> <double 0x401ED69BB62A5B30, double 0xBFDA6D4F2B6F18CF>)
%18 = shufflevector <2 x double> %13, <2 x double> poison, <2 x i32> zeroinitializer
%19 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %18, <2 x double> %17, <2 x double> <double 0x3FEFFFFFFFD64E05, double 1.000000e+00>)
%20 = extractelement <2 x double> %19, i64 0
%21 = extractelement <2 x double> %19, i64 1
%22 = fdiv double %20, %21
br label %43
23: ; preds = %1
%24 = fdiv double 5.700000e+00, %4
%25 = tail call double @llvm.fmuladd.f64(double %24, double 0xBF17876F85E74A06, double 0xBF56284D6B8D89FA)
%26 = tail call double @llvm.fmuladd.f64(double %25, double %24, double 0xBFB785415D4B7C32)
%27 = tail call double @llvm.fmuladd.f64(double %24, double %26, double 0x3FE03D2291A8FFB5)
%28 = tail call double @llvm.fmuladd.f64(double %24, double %27, double 0xBFE7FD9F0ABBF1D4)
%29 = tail call double @llvm.fmuladd.f64(double %24, double %28, double 0x3FD9884533FBF759)
%30 = tail call double @llvm.fmuladd.f64(double %24, double 0xBFD0577C2A639DCB, double 0x3FF4FC19D5B00AB8)
%31 = tail call double @llvm.fmuladd.f64(double %30, double %24, double 0xBFFE6B3484A733DB)
%32 = tail call double @llvm.fmuladd.f64(double %24, double %31, double 1.000000e+00)
%33 = tail call double @exp(double %4)
%34 = tail call double @sqrt(double %4)
%35 = insertelement <2 x double> poison, double %29, i64 0
%36 = insertelement <2 x double> %35, double %33, i64 1
%37 = insertelement <2 x double> poison, double %32, i64 0
%38 = insertelement <2 x double> %37, double %34, i64 1
%39 = fdiv <2 x double> %36, %38
%40 = shufflevector <2 x double> %39, <2 x double> poison, <2 x i32> <i32 1, i32 undef>
%41 = fmul <2 x double> %39, %40
%42 = extractelement <2 x double> %41, i64 0
br label %43
43: ; preds = %23, %6
%44 = phi double [ %22, %6 ], [ %42, %23 ]
ret double %44
}