#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 expl(long double);
double sqrtl(long double);
long double bessi0_spd_exponScaled(long double x) {
  long double y;
  if (x < 3.75) {
    y = x / 3.75, y = y * y;
    return expl(-x) *
           (1.0 + y * (3.5156229 +
                       y * (3.0899424 +
                            y * (1.2067492 +
                                 y * (0.2659732 +
                                      y * (0.360768e-1 + y * 0.45813e-2))))));
  } else {
    y = 3.75 / x;
    return ((0.39894228 +
             y * (0.1328592e-1 +
                  y * (0.225319e-2 +
                       y * (-0.157565e-2 +
                            y * (0.916281e-2 +
                                 y * (-0.2057706e-1 +
                                      y * (0.2635537e-1 +
                                           y * (-0.1647633e-1 +
                                                y * 0.392377e-2)))))))) /
            sqrtl(x));
  }
}


x86 assembly (clang, -O0):
<bessi0_spd_exponScaled>:
push   %rbp
mov    %rsp,%rbp
sub    $0x70,%rsp
fldt   0x10(%rbp)
fstpt  -0x20(%rbp)
fldt   -0x20(%rbp)
flds   0xec9(%rip)
fucomip %st(1),%st
fstp   %st(0)
jbe    11be <bessi0_spd_exponScaled+0x9e>
jmp    1146 <bessi0_spd_exponScaled+0x26>
fldt   -0x20(%rbp)
flds   0xeb1(%rip)
fdivrp %st,%st(1)
fstpt  -0x30(%rbp)
fldt   -0x30(%rbp)
fmul   %st,%st(0)
fstpt  -0x30(%rbp)
fldt   -0x20(%rbp)
fchs
mov    %rsp,%rax
fstpt  (%rax)
call   1030 <expl@plt>
movsd  %xmm0,-0x40(%rbp)
fldl   -0x40(%rbp)
fldt   -0x30(%rbp)
fldl   0xed4(%rip)
fmul   %st(1),%st
fldl   0xed4(%rip)
faddp  %st,%st(1)
fmul   %st(1),%st
fldl   0xed2(%rip)
faddp  %st,%st(1)
fmul   %st(1),%st
fldl   0xed0(%rip)
faddp  %st,%st(1)
fmul   %st(1),%st
fldl   0xece(%rip)
faddp  %st,%st(1)
fmul   %st(1),%st
fldl   0xecc(%rip)
faddp  %st,%st(1)
fmulp  %st,%st(1)
fld1
faddp  %st,%st(1)
fmulp  %st,%st(1)
fstpt  -0x10(%rbp)
jmp    124a <bessi0_spd_exponScaled+0x12a>
fldt   -0x20(%rbp)
flds   0xe39(%rip)
fdivp  %st,%st(1)
fstpt  -0x30(%rbp)
fldt   -0x30(%rbp)
fld    %st(0)
fstpt  -0x58(%rbp)
fldl   0xe2e(%rip)
fmul   %st(1),%st
fldl   0xe2e(%rip)
faddp  %st,%st(1)
fmul   %st(1),%st
fldl   0xe2c(%rip)
faddp  %st,%st(1)
fmul   %st(1),%st
fldl   0xe2a(%rip)
faddp  %st,%st(1)
fmul   %st(1),%st
fldl   0xe28(%rip)
faddp  %st,%st(1)
fmul   %st(1),%st
fldl   0xe26(%rip)
faddp  %st,%st(1)
fmul   %st(1),%st
fldl   0xe24(%rip)
faddp  %st,%st(1)
fmul   %st(1),%st
fldl   0xe22(%rip)
faddp  %st,%st(1)
fmulp  %st,%st(1)
fldl   0xe20(%rip)
faddp  %st,%st(1)
fstpt  -0x4c(%rbp)
fldt   -0x20(%rbp)
mov    %rsp,%rax
fstpt  (%rax)
call   1040 <sqrtl@plt>
fldt   -0x4c(%rbp)
movsd  %xmm0,-0x38(%rbp)
fldl   -0x38(%rbp)
fdivrp %st,%st(1)
fstpt  -0x10(%rbp)
fldt   -0x10(%rbp)
add    $0x70,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<bessi0_spd_exponScaled>:
sub    $0x38,%rsp
fldt   0x40(%rsp)
flds   0xed2(%rip)
fucomip %st(1),%st
jbe    1191 <bessi0_spd_exponScaled+0x71>
fld    %st(0)
fdivs  0xec6(%rip)
fmul   %st,%st(0)
fstpt  0x1c(%rsp)
fchs
fstpt  (%rsp)
call   1030 <expl@plt>
fldt   0x1c(%rsp)
fld    %st(0)
fmull  0xefa(%rip)
faddl  0xefc(%rip)
fmul   %st(1),%st
faddl  0xefc(%rip)
fmul   %st(1),%st
faddl  0xefc(%rip)
movsd  %xmm0,0x28(%rsp)
fmul   %st(1),%st
faddl  0xef6(%rip)
fmul   %st(1),%st
faddl  0xef6(%rip)
fmulp  %st,%st(1)
fld1
faddp  %st,%st(1)
fmull  0x28(%rsp)
add    $0x38,%rsp
ret
fld    %st(0)
fdivrs 0xe67(%rip)
fld    %st(0)
fmull  0xe67(%rip)
faddl  0xe69(%rip)
fmul   %st(1),%st
faddl  0xe69(%rip)
fmul   %st(1),%st
faddl  0xe69(%rip)
fmul   %st(1),%st
faddl  0xe69(%rip)
fmul   %st(1),%st
faddl  0xe69(%rip)
fmul   %st(1),%st
faddl  0xe69(%rip)
fmul   %st(1),%st
faddl  0xe69(%rip)
fmulp  %st,%st(1)
faddl  0xe69(%rip)
fstpt  0x1c(%rsp)
fstpt  (%rsp)
call   1040 <sqrtl@plt>
movsd  %xmm0,0x30(%rsp)
fldt   0x1c(%rsp)
fdivl  0x30(%rsp)
add    $0x38,%rsp
ret

LLVM IR (-O0):
define x86_fp80 @bessi0_spd_exponScaled(x86_fp80 %0) {
%2 = alloca x86_fp80
%3 = alloca x86_fp80
%4 = alloca x86_fp80
store x86_fp80 %0, x86_fp80* %3
%5 = load x86_fp80, x86_fp80* %3
%6 = fcmp olt x86_fp80 %5, 0xK4000F000000000000000
br i1 %6, label %7, label %30
7: ; preds = %1
%8 = load x86_fp80, x86_fp80* %3
%9 = fdiv x86_fp80 %8, 0xK4000F000000000000000
store x86_fp80 %9, x86_fp80* %4
%10 = load x86_fp80, x86_fp80* %4
%11 = load x86_fp80, x86_fp80* %4
%12 = fmul x86_fp80 %10, %11
store x86_fp80 %12, x86_fp80* %4
%13 = load x86_fp80, x86_fp80* %3
%14 = fneg x86_fp80 %13
%15 = call double @expl(x86_fp80 %14)
%16 = fpext double %15 to x86_fp80
%17 = load x86_fp80, x86_fp80* %4
%18 = load x86_fp80, x86_fp80* %4
%19 = load x86_fp80, x86_fp80* %4
%20 = load x86_fp80, x86_fp80* %4
%21 = load x86_fp80, x86_fp80* %4
%22 = load x86_fp80, x86_fp80* %4
%23 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %22, x86_fp80 0xK3FF7961EBAD62A43A000, x86_fp80 0xK3FFA93C544424F2FE800)
%24 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %21, x86_fp80 %23, x86_fp80 0xK3FFD882DA3A739955000)
%25 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %20, x86_fp80 %24, x86_fp80 0xK3FFF9A76C1FE3CB16000)
%26 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %19, x86_fp80 %25, x86_fp80 0xK4000C5C19DC4A1852000)
%27 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %18, x86_fp80 %26, x86_fp80 0xK4000E0FFF73124653800)
%28 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %17, x86_fp80 %27, x86_fp80 0xK3FFF8000000000000000)
%29 = fmul x86_fp80 %16, %28
store x86_fp80 %29, x86_fp80* %2
br label %53
30: ; preds = %1
%31 = load x86_fp80, x86_fp80* %3
%32 = fdiv x86_fp80 0xK4000F000000000000000, %31
store x86_fp80 %32, x86_fp80* %4
%33 = load x86_fp80, x86_fp80* %4
%34 = load x86_fp80, x86_fp80* %4
%35 = load x86_fp80, x86_fp80* %4
%36 = load x86_fp80, x86_fp80* %4
%37 = load x86_fp80, x86_fp80* %4
%38 = load x86_fp80, x86_fp80* %4
%39 = load x86_fp80, x86_fp80* %4
%40 = load x86_fp80, x86_fp80* %4
%41 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %40, x86_fp80 0xK3FF78092F7E9DBFC4000, x86_fp80 0xKBFF986F95E504262A800)
%42 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %39, x86_fp80 %41, x86_fp80 0xK3FF9D7E737872AD71800)
%43 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %38, x86_fp80 %42, x86_fp80 0xKBFF9A89138F7EE38B000)
%44 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %37, x86_fp80 %43, x86_fp80 0xK3FF8961F9C52868AA000)
%45 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %36, x86_fp80 %44, x86_fp80 0xKBFF5CE860A709C4A5000)
%46 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %35, x86_fp80 %45, x86_fp80 0xK3FF693AA415C96AED800)
%47 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %34, x86_fp80 %46, x86_fp80 0xK3FF8D9AD2FF96CE8E000)
%48 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %33, x86_fp80 %47, x86_fp80 0xK3FFDCC42299B2EF00000)
%49 = load x86_fp80, x86_fp80* %3
%50 = call double @sqrtl(x86_fp80 %49)
%51 = fpext double %50 to x86_fp80
%52 = fdiv x86_fp80 %48, %51
store x86_fp80 %52, x86_fp80* %2
br label %53
53: ; preds = %30, %7
%54 = load x86_fp80, x86_fp80* %2
ret x86_fp80 %54
}

LLVM IR (-O2):
define x86_fp80 @bessi0_spd_exponScaled(x86_fp80 %0) {
%2 = fcmp olt x86_fp80 %0, 0xK4000F000000000000000
br i1 %2, label %3, label %16
3: ; preds = %1
%4 = fdiv x86_fp80 %0, 0xK4000F000000000000000
%5 = fmul x86_fp80 %4, %4
%6 = fneg x86_fp80 %0
%7 = tail call double @expl(x86_fp80 %6)
%8 = fpext double %7 to x86_fp80
%9 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %5, x86_fp80 0xK3FF7961EBAD62A43A000, x86_fp80 0xK3FFA93C544424F2FE800)
%10 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %5, x86_fp80 %9, x86_fp80 0xK3FFD882DA3A739955000)
%11 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %5, x86_fp80 %10, x86_fp80 0xK3FFF9A76C1FE3CB16000)
%12 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %5, x86_fp80 %11, x86_fp80 0xK4000C5C19DC4A1852000)
%13 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %5, x86_fp80 %12, x86_fp80 0xK4000E0FFF73124653800)
%14 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %5, x86_fp80 %13, x86_fp80 0xK3FFF8000000000000000)
%15 = fmul x86_fp80 %14, %8
br label %29
16: ; preds = %1
%17 = fdiv x86_fp80 0xK4000F000000000000000, %0
%18 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %17, x86_fp80 0xK3FF78092F7E9DBFC4000, x86_fp80 0xKBFF986F95E504262A800)
%19 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %17, x86_fp80 %18, x86_fp80 0xK3FF9D7E737872AD71800)
%20 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %17, x86_fp80 %19, x86_fp80 0xKBFF9A89138F7EE38B000)
%21 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %17, x86_fp80 %20, x86_fp80 0xK3FF8961F9C52868AA000)
%22 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %17, x86_fp80 %21, x86_fp80 0xKBFF5CE860A709C4A5000)
%23 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %17, x86_fp80 %22, x86_fp80 0xK3FF693AA415C96AED800)
%24 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %17, x86_fp80 %23, x86_fp80 0xK3FF8D9AD2FF96CE8E000)
%25 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %17, x86_fp80 %24, x86_fp80 0xK3FFDCC42299B2EF00000)
%26 = tail call double @sqrtl(x86_fp80 %0)
%27 = fpext double %26 to x86_fp80
%28 = fdiv x86_fp80 %25, %27
br label %29
29: ; preds = %16, %3
%30 = phi x86_fp80 [ %15, %3 ], [ %28, %16 ]
ret x86_fp80 %30
}