#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 */
float expf(float);
float hy1f1af(float, float, float, float *);
float hy1f1pf(float, float, float, float *);
int /*<<< orphan*/ mtherr(char *, int);
float hypergf(float aa, float bb, float xx) {
  float a, b, x, asum, psum, acanc, pcanc, temp;
  a = aa;
  b = bb;
  x = xx;
  temp = b - a;
  if (((temp) < 0 ? -(temp) : (temp)) < 0.001 * ((a) < 0 ? -(a) : (a)))
    return (expf(x) * hypergf(temp, b, -x));
  psum = hy1f1pf(a, b, x, &pcanc);
  if (pcanc < 1.0e-6)
    goto done;
  asum = hy1f1af(a, b, x, &acanc);
  if (acanc < pcanc) {
    pcanc = acanc;
    psum = asum;
  }
done:
  if (pcanc > 1.0e-3)
    mtherr("hyperg", 6);
  return (psum);
}


x86 assembly (clang, -O0):
<hypergf>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
movss  %xmm0,-0x8(%rbp)
movss  %xmm1,-0xc(%rbp)
movss  %xmm2,-0x10(%rbp)
movss  -0x8(%rbp),%xmm0
movss  %xmm0,-0x14(%rbp)
movss  -0xc(%rbp),%xmm0
movss  %xmm0,-0x18(%rbp)
movss  -0x10(%rbp),%xmm0
movss  %xmm0,-0x1c(%rbp)
movss  -0x18(%rbp),%xmm0
subss  -0x14(%rbp),%xmm0
movss  %xmm0,-0x30(%rbp)
xorps  %xmm0,%xmm0
ucomiss -0x30(%rbp),%xmm0
jbe    11bd <hypergf+0x6d>
movss  -0x30(%rbp),%xmm0
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
movss  %xmm0,-0x34(%rbp)
jmp    11c7 <hypergf+0x77>
movss  -0x30(%rbp),%xmm0
movss  %xmm0,-0x34(%rbp)
movss  -0x34(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,-0x40(%rbp)
xorps  %xmm0,%xmm0
ucomiss -0x14(%rbp),%xmm0
jbe    11fe <hypergf+0xae>
movss  -0x14(%rbp),%xmm0
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
movss  %xmm0,-0x44(%rbp)
jmp    1208 <hypergf+0xb8>
movss  -0x14(%rbp),%xmm0
movss  %xmm0,-0x44(%rbp)
movsd  -0x40(%rbp),%xmm1
movss  -0x44(%rbp),%xmm0
cvtss2sd %xmm0,%xmm2
movsd  0xde2(%rip),%xmm0
mulsd  %xmm2,%xmm0
ucomisd %xmm1,%xmm0
jbe    1272 <hypergf+0x122>
movss  -0x1c(%rbp),%xmm0
call   1040 <expf@plt>
movss  %xmm0,-0x48(%rbp)
movss  -0x30(%rbp),%xmm0
movss  -0x18(%rbp),%xmm1
movss  -0x1c(%rbp),%xmm2
movd   %xmm2,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm2
call   1030 <hypergf@plt>
movaps %xmm0,%xmm1
movss  -0x48(%rbp),%xmm0
mulss  %xmm1,%xmm0
movss  %xmm0,-0x4(%rbp)
jmp    132e <hypergf+0x1de>
movss  -0x14(%rbp),%xmm0
movss  -0x18(%rbp),%xmm1
movss  -0x1c(%rbp),%xmm2
lea    -0x2c(%rbp),%rdi
call   1060 <hy1f1pf@plt>
movss  %xmm0,-0x24(%rbp)
movss  -0x2c(%rbp),%xmm0
cvtss2sd %xmm0,%xmm1
movsd  0xd68(%rip),%xmm0
ucomisd %xmm1,%xmm0
jbe    12af <hypergf+0x15f>
jmp    12f8 <hypergf+0x1a8>
movss  -0x14(%rbp),%xmm0
movss  -0x18(%rbp),%xmm1
movss  -0x1c(%rbp),%xmm2
lea    -0x28(%rbp),%rdi
call   1050 <hy1f1af@plt>
movss  %xmm0,-0x20(%rbp)
movss  -0x28(%rbp),%xmm1
movss  -0x2c(%rbp),%xmm0
ucomiss %xmm1,%xmm0
jbe    12f3 <hypergf+0x1a3>
movss  -0x28(%rbp),%xmm0
movss  %xmm0,-0x2c(%rbp)
movss  -0x20(%rbp),%xmm0
movss  %xmm0,-0x24(%rbp)
jmp    12f8 <hypergf+0x1a8>
movss  -0x2c(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  0xcf7(%rip),%xmm1
ucomisd %xmm1,%xmm0
jbe    1324 <hypergf+0x1d4>
lea    0xcf6(%rip),%rdi
mov    $0x6,%esi
call   1070 <mtherr@plt>
movss  -0x24(%rbp),%xmm0
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
add    $0x50,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<hypergf>:
sub    $0x48,%rsp
movaps %xmm1,%xmm7
subss  %xmm0,%xmm7
movaps 0xe9e(%rip),%xmm6
movaps %xmm7,%xmm5
xorps  %xmm6,%xmm5
xorps  %xmm4,%xmm4
movaps %xmm7,%xmm3
cmpltss %xmm4,%xmm3
andps  %xmm3,%xmm5
andnps %xmm7,%xmm3
orps   %xmm5,%xmm3
xorps  %xmm5,%xmm5
cvtss2sd %xmm3,%xmm5
xorps  %xmm0,%xmm6
movaps %xmm0,%xmm3
cmpltss %xmm4,%xmm3
andps  %xmm3,%xmm6
andnps %xmm0,%xmm3
orps   %xmm6,%xmm3
cvtss2sd %xmm3,%xmm3
mulsd  0xe6d(%rip),%xmm3
ucomisd %xmm5,%xmm3
movaps %xmm2,0x10(%rsp)
movss  %xmm1,0x8(%rsp)
jbe    11f1 <hypergf+0xa1>
movaps %xmm2,%xmm0
movaps %xmm7,0x30(%rsp)
call   1040 <expf@plt>
movss  %xmm0,0x20(%rsp)
movaps 0x10(%rsp),%xmm2
xorps  0xe2d(%rip),%xmm2
movaps 0x30(%rsp),%xmm0
movss  0x8(%rsp),%xmm1
call   1030 <hypergf@plt>
movaps %xmm0,%xmm3
mulss  0x20(%rsp),%xmm3
jmp    128f <hypergf+0x13f>
lea    0x4(%rsp),%rdi
movaps %xmm0,0x20(%rsp)
call   1060 <hy1f1pf@plt>
movaps %xmm0,%xmm3
movss  0x4(%rsp),%xmm1
xorps  %xmm0,%xmm0
cvtss2sd %xmm1,%xmm0
movsd  0xe00(%rip),%xmm2
ucomisd %xmm0,%xmm2
ja     1261 <hypergf+0x111>
lea    0xc(%rsp),%rdi
movaps 0x20(%rsp),%xmm0
movss  0x8(%rsp),%xmm1
movaps 0x10(%rsp),%xmm2
movss  %xmm3,0x10(%rsp)
call   1050 <hy1f1af@plt>
movss  0x10(%rsp),%xmm3
movss  0xc(%rsp),%xmm2
movss  0x4(%rsp),%xmm1
ucomiss %xmm2,%xmm1
jbe    1261 <hypergf+0x111>
movss  %xmm2,0x4(%rsp)
movaps %xmm2,%xmm1
movaps %xmm0,%xmm3
xorps  %xmm0,%xmm0
cvtss2sd %xmm1,%xmm0
ucomisd 0xda0(%rip),%xmm0
jbe    128f <hypergf+0x13f>
lea    0xda7(%rip),%rdi
mov    $0x6,%esi
movss  %xmm3,0x10(%rsp)
call   1070 <mtherr@plt>
movss  0x10(%rsp),%xmm3
movaps %xmm3,%xmm0
add    $0x48,%rsp
ret

LLVM IR (-O0):
@.str = [7 x i8] c"hyperg\00"
define float @hypergf(float %0, float %1, float %2) {
%4 = alloca float
%5 = alloca float
%6 = alloca float
%7 = alloca float
%8 = alloca float
%9 = alloca float
%10 = alloca float
%11 = alloca float
%12 = alloca float
%13 = alloca float
%14 = alloca float
%15 = alloca float
store float %0, float* %5
store float %1, float* %6
store float %2, float* %7
%16 = load float, float* %5
store float %16, float* %8
%17 = load float, float* %6
store float %17, float* %9
%18 = load float, float* %7
store float %18, float* %10
%19 = load float, float* %9
%20 = load float, float* %8
%21 = fsub float %19, %20
store float %21, float* %15
%22 = load float, float* %15
%23 = fcmp olt float %22, 0.000000e+00
br i1 %23, label %24, label %27
24: ; preds = %3
%25 = load float, float* %15
%26 = fneg float %25
br label %29
27: ; preds = %3
%28 = load float, float* %15
br label %29
29: ; preds = %27, %24
%30 = phi float [ %26, %24 ], [ %28, %27 ]
%31 = fpext float %30 to double
%32 = load float, float* %8
%33 = fcmp olt float %32, 0.000000e+00
br i1 %33, label %34, label %37
34: ; preds = %29
%35 = load float, float* %8
%36 = fneg float %35
br label %39
37: ; preds = %29
%38 = load float, float* %8
br label %39
39: ; preds = %37, %34
%40 = phi float [ %36, %34 ], [ %38, %37 ]
%41 = fpext float %40 to double
%42 = fmul double 1.000000e-03, %41
%43 = fcmp olt double %31, %42
br i1 %43, label %44, label %53
44: ; preds = %39
%45 = load float, float* %10
%46 = call float @expf(float %45)
%47 = load float, float* %15
%48 = load float, float* %9
%49 = load float, float* %10
%50 = fneg float %49
%51 = call float @hypergf(float %47, float %48, float %50)
%52 = fmul float %46, %51
store float %52, float* %4
br label %82
53: ; preds = %39
%54 = load float, float* %8
%55 = load float, float* %9
%56 = load float, float* %10
%57 = call float @hy1f1pf(float %54, float %55, float %56, float* %14)
store float %57, float* %12
%58 = load float, float* %14
%59 = fpext float %58 to double
%60 = fcmp olt double %59, 0x3EB0C6F7A0B5ED8D
br i1 %60, label %61, label %62
61: ; preds = %53
br label %74
62: ; preds = %53
%63 = load float, float* %8
%64 = load float, float* %9
%65 = load float, float* %10
%66 = call float @hy1f1af(float %63, float %64, float %65, float* %13)
store float %66, float* %11
%67 = load float, float* %13
%68 = load float, float* %14
%69 = fcmp olt float %67, %68
br i1 %69, label %70, label %73
70: ; preds = %62
%71 = load float, float* %13
store float %71, float* %14
%72 = load float, float* %11
store float %72, float* %12
br label %73
73: ; preds = %70, %62
br label %74
74: ; preds = %73, %61
%75 = load float, float* %14
%76 = fpext float %75 to double
%77 = fcmp ogt double %76, 1.000000e-03
br i1 %77, label %78, label %80
78: ; preds = %74
%79 = call i32 @mtherr(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i32 6)
br label %80
80: ; preds = %78, %74
%81 = load float, float* %12
store float %81, float* %4
br label %82
82: ; preds = %80, %44
%83 = load float, float* %4
ret float %83
}

LLVM IR (-O2):
@.str = [7 x i8] c"hyperg\00"
define float @hypergf(float %0, float %1, float %2) {
%4 = alloca float
%5 = alloca float
%6 = bitcast float* %4 to i8*
%7 = bitcast float* %5 to i8*
%8 = fsub float %1, %0
%9 = fcmp olt float %8, 0.000000e+00
%10 = fneg float %8
%11 = select i1 %9, float %10, float %8
%12 = fpext float %11 to double
%13 = fcmp olt float %0, 0.000000e+00
%14 = fneg float %0
%15 = select i1 %13, float %14, float %0
%16 = fpext float %15 to double
%17 = fmul double %16, 1.000000e-03
%18 = fcmp ogt double %17, %12
br i1 %18, label %19, label %24
19: ; preds = %3
%20 = tail call float @expf(float %2)
%21 = fneg float %2
%22 = tail call float @hypergf(float %8, float %1, float %21)
%23 = fmul float %20, %22
br label %42
24: ; preds = %3
%25 = call float @hy1f1pf(float %0, float %1, float %2, float* %5)
%26 = load float, float* %5
%27 = fpext float %26 to double
%28 = fcmp olt double %27, 0x3EB0C6F7A0B5ED8D
br i1 %28, label %35, label %29
29: ; preds = %24
%30 = call float @hy1f1af(float %0, float %1, float %2, float* %4)
%31 = load float, float* %4
%32 = load float, float* %5
%33 = fcmp olt float %31, %32
br i1 %33, label %34, label %35
34: ; preds = %29
store float %31, float* %5
br label %35
35: ; preds = %29, %34, %24
%36 = phi float [ %26, %24 ], [ %31, %34 ], [ %32, %29 ]
%37 = phi float [ %25, %24 ], [ %30, %34 ], [ %25, %29 ]
%38 = fpext float %36 to double
%39 = fcmp ogt double %38, 1.000000e-03
br i1 %39, label %40, label %42
40: ; preds = %35
%41 = call i32 @mtherr(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i32 6)
br label %42
42: ; preds = %35, %40, %19
%43 = phi float [ %23, %19 ], [ %37, %40 ], [ %37, %35 ]
ret float %43
}