#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 pow(double, int);
double reff(double sft_length, double radius) {
  double ret;
  double eta = 2.0 * radius / sft_length;
  if (eta < 1.0) {
    ret = (224. + eta * eta * (-224. + eta * (70. + eta * (48. - eta * 21.)))) *
          2.e0 / (35.0 * pow(sft_length, 3));
  } else if (eta < 2.0) {
    ret =
        (12. / (eta * eta) - 224. +
         eta * (896. +
                eta * (-840. +
                       eta * (224. + eta * (70. + eta * (-48. + eta * 7.)))))) *
        2.e0 / (35.0 * eta * pow(sft_length, 3));
  } else {
    ret = 1.0 / pow(radius, 3);
  }
  return ret;
}


x86 assembly (clang, -O0):
<reff>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
movsd  0xede(%rip),%xmm0
mulsd  -0x10(%rbp),%xmm0
divsd  -0x8(%rbp),%xmm0
movsd  %xmm0,-0x20(%rbp)
movsd  0xebf(%rip),%xmm0
ucomisd -0x20(%rbp),%xmm0
jbe    1206 <reff+0xf6>
movsd  -0x20(%rbp),%xmm0
mulsd  -0x20(%rbp),%xmm0
movsd  -0x20(%rbp),%xmm1
movsd  -0x20(%rbp),%xmm2
movsd  -0x20(%rbp),%xmm3
movq   %xmm3,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm3
movsd  0xed4(%rip),%xmm4
mulsd  %xmm4,%xmm3
movsd  0xed0(%rip),%xmm4
addsd  %xmm4,%xmm3
mulsd  %xmm3,%xmm2
movsd  0xe90(%rip),%xmm3
addsd  %xmm3,%xmm2
mulsd  %xmm2,%xmm1
movsd  0xea0(%rip),%xmm2
addsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
movsd  0xe68(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  0xe3c(%rip),%xmm1
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x28(%rbp)
movsd  -0x8(%rbp),%xmm0
mov    $0x3,%edi
call   1030 <pow@plt>
movaps %xmm0,%xmm2
movsd  -0x28(%rbp),%xmm0
movsd  0xe1c(%rip),%xmm1
mulsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x18(%rbp)
jmp    1332 <reff+0x222>
movsd  0xdfa(%rip),%xmm0
ucomisd -0x20(%rbp),%xmm0
jbe    130a <reff+0x1fa>
movsd  -0x20(%rbp),%xmm0
mulsd  -0x20(%rbp),%xmm0
movsd  0xe1d(%rip),%xmm1
divsd  %xmm0,%xmm1
movsd  0xdf1(%rip),%xmm0
subsd  %xmm0,%xmm1
movsd  -0x20(%rbp),%xmm0
movsd  -0x20(%rbp),%xmm2
movsd  -0x20(%rbp),%xmm3
movsd  -0x20(%rbp),%xmm4
movsd  -0x20(%rbp),%xmm5
movsd  -0x20(%rbp),%xmm6
movsd  0xdd7(%rip),%xmm7
mulsd  %xmm7,%xmm6
movsd  0xdd3(%rip),%xmm7
addsd  %xmm7,%xmm6
mulsd  %xmm6,%xmm5
movsd  0xdb3(%rip),%xmm6
addsd  %xmm6,%xmm5
mulsd  %xmm5,%xmm4
movsd  0xd9b(%rip),%xmm5
addsd  %xmm5,%xmm4
mulsd  %xmm4,%xmm3
movsd  0xd83(%rip),%xmm4
addsd  %xmm4,%xmm3
mulsd  %xmm3,%xmm2
movsd  0xd6b(%rip),%xmm3
addsd  %xmm3,%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  0xd47(%rip),%xmm1
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x30(%rbp)
movsd  0xd3e(%rip),%xmm0
mulsd  -0x20(%rbp),%xmm0
movsd  %xmm0,-0x38(%rbp)
movsd  -0x8(%rbp),%xmm0
mov    $0x3,%edi
call   1030 <pow@plt>
movsd  -0x38(%rbp),%xmm1
movaps %xmm0,%xmm2
movsd  -0x30(%rbp),%xmm0
mulsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x18(%rbp)
jmp    132d <reff+0x21d>
movsd  -0x10(%rbp),%xmm0
mov    $0x3,%edi
call   1030 <pow@plt>
movaps %xmm0,%xmm1
movsd  0xcdc(%rip),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x18(%rbp)
jmp    1332 <reff+0x222>
movsd  -0x18(%rbp),%xmm0
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<reff>:
sub    $0x18,%rsp
movapd %xmm1,%xmm3
addsd  %xmm1,%xmm3
divsd  %xmm0,%xmm3
movsd  0xed8(%rip),%xmm2
ucomisd %xmm3,%xmm2
jbe    1195 <reff+0x85>
movsd  0xf22(%rip),%xmm2
mulsd  %xmm3,%xmm2
addsd  0xf1e(%rip),%xmm2
movapd %xmm3,%xmm1
mulsd  %xmm3,%xmm2
addsd  0xede(%rip),%xmm2
mulsd  %xmm3,%xmm1
mulsd  %xmm3,%xmm2
addsd  0xeb6(%rip),%xmm2
mulsd  %xmm1,%xmm2
addsd  0xeca(%rip),%xmm2
addsd  %xmm2,%xmm2
movsd  %xmm2,0x8(%rsp)
mov    $0x3,%edi
call   1030 <pow@plt>
movsd  0x8(%rsp),%xmm1
mulsd  0xec0(%rip),%xmm0
jmp    1255 <reff+0x145>
movsd  0xe6b(%rip),%xmm2
ucomisd %xmm3,%xmm2
jbe    123f <reff+0x12f>
movapd %xmm3,%xmm1
mulsd  %xmm3,%xmm1
movsd  0xe59(%rip),%xmm2
divsd  %xmm1,%xmm2
addsd  0xe55(%rip),%xmm2
movsd  0xe55(%rip),%xmm1
mulsd  %xmm3,%xmm1
addsd  0xe51(%rip),%xmm1
mulsd  %xmm3,%xmm1
addsd  0xe4d(%rip),%xmm1
mulsd  %xmm3,%xmm1
addsd  0xe49(%rip),%xmm1
mulsd  %xmm3,%xmm1
addsd  0xe45(%rip),%xmm1
mulsd  %xmm3,%xmm1
addsd  0xe41(%rip),%xmm1
mulsd  %xmm3,%xmm1
addsd  %xmm2,%xmm1
addsd  %xmm1,%xmm1
movsd  %xmm1,0x8(%rsp)
mulsd  0xe2f(%rip),%xmm3
movsd  %xmm3,0x10(%rsp)
mov    $0x3,%edi
call   1030 <pow@plt>
movsd  0x8(%rsp),%xmm1
mulsd  0x10(%rsp),%xmm0
jmp    1255 <reff+0x145>
movapd %xmm1,%xmm0
mov    $0x3,%edi
call   1030 <pow@plt>
movsd  0xdab(%rip),%xmm1
divsd  %xmm0,%xmm1
movapd %xmm1,%xmm0
add    $0x18,%rsp
ret

LLVM IR (-O0):
define double @reff(double %0, double %1) {
%3 = alloca double
%4 = alloca double
%5 = alloca double
%6 = alloca double
store double %0, double* %3
store double %1, double* %4
%7 = load double, double* %4
%8 = fmul double 2.000000e+00, %7
%9 = load double, double* %3
%10 = fdiv double %8, %9
store double %10, double* %6
%11 = load double, double* %6
%12 = fcmp olt double %11, 1.000000e+00
br i1 %12, label %13, label %30
13: ; preds = %2
%14 = load double, double* %6
%15 = load double, double* %6
%16 = fmul double %14, %15
%17 = load double, double* %6
%18 = load double, double* %6
%19 = load double, double* %6
%20 = fneg double %19
%21 = call double @llvm.fmuladd.f64(double %20, double 2.100000e+01, double 4.800000e+01)
%22 = call double @llvm.fmuladd.f64(double %18, double %21, double 7.000000e+01)
%23 = call double @llvm.fmuladd.f64(double %17, double %22, double -2.240000e+02)
%24 = call double @llvm.fmuladd.f64(double %16, double %23, double 2.240000e+02)
%25 = fmul double %24, 2.000000e+00
%26 = load double, double* %3
%27 = call double @pow(double %26, i32 3)
%28 = fmul double 3.500000e+01, %27
%29 = fdiv double %25, %28
store double %29, double* %5
br label %63
30: ; preds = %2
%31 = load double, double* %6
%32 = fcmp olt double %31, 2.000000e+00
br i1 %32, label %33, label %58
33: ; preds = %30
%34 = load double, double* %6
%35 = load double, double* %6
%36 = fmul double %34, %35
%37 = fdiv double 1.200000e+01, %36
%38 = fsub double %37, 2.240000e+02
%39 = load double, double* %6
%40 = load double, double* %6
%41 = load double, double* %6
%42 = load double, double* %6
%43 = load double, double* %6
%44 = load double, double* %6
%45 = call double @llvm.fmuladd.f64(double %44, double 7.000000e+00, double -4.800000e+01)
%46 = call double @llvm.fmuladd.f64(double %43, double %45, double 7.000000e+01)
%47 = call double @llvm.fmuladd.f64(double %42, double %46, double 2.240000e+02)
%48 = call double @llvm.fmuladd.f64(double %41, double %47, double -8.400000e+02)
%49 = call double @llvm.fmuladd.f64(double %40, double %48, double 8.960000e+02)
%50 = call double @llvm.fmuladd.f64(double %39, double %49, double %38)
%51 = fmul double %50, 2.000000e+00
%52 = load double, double* %6
%53 = fmul double 3.500000e+01, %52
%54 = load double, double* %3
%55 = call double @pow(double %54, i32 3)
%56 = fmul double %53, %55
%57 = fdiv double %51, %56
store double %57, double* %5
br label %62
58: ; preds = %30
%59 = load double, double* %4
%60 = call double @pow(double %59, i32 3)
%61 = fdiv double 1.000000e+00, %60
store double %61, double* %5
br label %62
62: ; preds = %58, %33
br label %63
63: ; preds = %62, %13
%64 = load double, double* %5
ret double %64
}

LLVM IR (-O2):
define double @reff(double %0, double %1) {
%3 = fmul double %1, 2.000000e+00
%4 = fdiv double %3, %0
%5 = fcmp olt double %4, 1.000000e+00
br i1 %5, label %6, label %17
6: ; preds = %2
%7 = fmul double %4, %4
%8 = fneg double %4
%9 = tail call double @llvm.fmuladd.f64(double %8, double 2.100000e+01, double 4.800000e+01)
%10 = tail call double @llvm.fmuladd.f64(double %4, double %9, double 7.000000e+01)
%11 = tail call double @llvm.fmuladd.f64(double %4, double %10, double -2.240000e+02)
%12 = tail call double @llvm.fmuladd.f64(double %7, double %11, double 2.240000e+02)
%13 = fmul double %12, 2.000000e+00
%14 = tail call double @pow(double %0, i32 3)
%15 = fmul double %14, 3.500000e+01
%16 = fdiv double %13, %15
br label %37
17: ; preds = %2
%18 = fcmp olt double %4, 2.000000e+00
br i1 %18, label %19, label %34
19: ; preds = %17
%20 = fmul double %4, %4
%21 = fdiv double 1.200000e+01, %20
%22 = fadd double %21, -2.240000e+02
%23 = tail call double @llvm.fmuladd.f64(double %4, double 7.000000e+00, double -4.800000e+01)
%24 = tail call double @llvm.fmuladd.f64(double %4, double %23, double 7.000000e+01)
%25 = tail call double @llvm.fmuladd.f64(double %4, double %24, double 2.240000e+02)
%26 = tail call double @llvm.fmuladd.f64(double %4, double %25, double -8.400000e+02)
%27 = tail call double @llvm.fmuladd.f64(double %4, double %26, double 8.960000e+02)
%28 = tail call double @llvm.fmuladd.f64(double %4, double %27, double %22)
%29 = fmul double %28, 2.000000e+00
%30 = fmul double %4, 3.500000e+01
%31 = tail call double @pow(double %0, i32 3)
%32 = fmul double %30, %31
%33 = fdiv double %29, %32
br label %37
34: ; preds = %17
%35 = tail call double @pow(double %1, i32 3)
%36 = fdiv double 1.000000e+00, %35
br label %37
37: ; preds = %19, %34, %6
%38 = phi double [ %16, %6 ], [ %33, %19 ], [ %36, %34 ]
ret double %38
}