#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 exp(double);
int /*<<< orphan*/ gcor2(double, double, double, double, double, double, double,
                         double *, double *);
double log(double);
double sqrt(double);
void corpbe(double rs, double t, int lgga, int lpot, double *ec, double *vc,
            double *h__, double *dvc, double *dv2rho) {
  double b, b2, q4, t2, q5, t4, ep, eu, pon, eurs, rtrs;
  double tmp1, tmp2, tmp3;
  rtrs = sqrt(rs);
  gcor2(.0310907, .2137, 7.5957, 3.5876, 1.6382, .49294, rtrs, &eu, &eurs);
  *ec = eu;
  *vc = eu - rs * eurs / 3.;
  if (lgga == 0) {
    return;
  }
  pon = -eu / 0.03109069086965489503494086371273;
  b = (0.06672455060314922 / 0.03109069086965489503494086371273) /
      (exp(pon) - 1.);
  b2 = b * b;
  t2 = t * t;
  t4 = t2 * t2;
  q4 = b * t2 + 1.;
  q5 = b * t2 + 1. + b2 * t4;
  *h__ = 0.03109069086965489503494086371273 *
         log(q4 * (0.06672455060314922 / 0.03109069086965489503494086371273) *
                 t2 / q5 +
             1.);
  if (lpot == 0) {
    return;
  }
  tmp1 = q4 / q5;
  tmp2 = b2 * t4 * (1. + q4) / (q5 * q5);
  tmp3 = 1. / (1. + (0.06672455060314922 / 0.03109069086965489503494086371273) *
                        t2 * tmp1);
  *dvc = *h__ - 0.06672455060314922 * t2 *
                    (7. / 3. * tmp1 +
                     tmp2 * ((b + (0.06672455060314922 /
                                   0.03109069086965489503494086371273)) *
                                 (*vc - eu) / 0.06672455060314922 -
                             7. / 3.)) *
                    tmp3;
  *dv2rho = 0.5 * 0.06672455060314922 * 0.409240950261429630406974844266531 *
            rs * (tmp1 - tmp2) * tmp3;
}


x86 assembly (clang, -O0):
<corpbe>:
push   %rbp
mov    %rsp,%rbp
sub    $0xb0,%rsp
mov    0x10(%rbp),%rax
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
mov    %edi,-0x14(%rbp)
mov    %esi,-0x18(%rbp)
mov    %rdx,-0x20(%rbp)
mov    %rcx,-0x28(%rbp)
mov    %r8,-0x30(%rbp)
mov    %r9,-0x38(%rbp)
movsd  -0x8(%rbp),%xmm0
call   1060 <sqrt@plt>
movsd  %xmm0,-0x90(%rbp)
ff
movsd  -0x90(%rbp),%xmm6
ff
movsd  0xe77(%rip),%xmm0
movsd  0xe77(%rip),%xmm1
movsd  0xe77(%rip),%xmm2
movsd  0xe77(%rip),%xmm3
movsd  0xe77(%rip),%xmm4
movsd  0xe77(%rip),%xmm5
lea    -0x78(%rbp),%rdi
lea    -0x88(%rbp),%rsi
call   1030 <gcor2@plt>
movsd  -0x78(%rbp),%xmm0
mov    -0x20(%rbp),%rax
movsd  %xmm0,(%rax)
movsd  -0x78(%rbp),%xmm0
movsd  -0x8(%rbp),%xmm1
mulsd  -0x88(%rbp),%xmm1
ff
movsd  0xe10(%rip),%xmm2
divsd  %xmm2,%xmm1
subsd  %xmm1,%xmm0
mov    -0x28(%rbp),%rax
movsd  %xmm0,(%rax)
cmpl   $0x0,-0x14(%rbp)
jne    120f <corpbe+0xcf>
jmp    1481 <corpbe+0x341>
movsd  -0x78(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  0xe05(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x80(%rbp)
movsd  -0x80(%rbp),%xmm0
call   1040 <exp@plt>
cvtsi2sd %eax,%xmm1
movsd  0xdee(%rip),%xmm0
subsd  %xmm0,%xmm1
movsd  0xdea(%rip),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x40(%rbp)
movsd  -0x40(%rbp),%xmm0
mulsd  -0x40(%rbp),%xmm0
movsd  %xmm0,-0x48(%rbp)
movsd  -0x10(%rbp),%xmm0
mulsd  -0x10(%rbp),%xmm0
movsd  %xmm0,-0x58(%rbp)
movsd  -0x58(%rbp),%xmm0
mulsd  -0x58(%rbp),%xmm0
movsd  %xmm0,-0x68(%rbp)
movsd  -0x40(%rbp),%xmm0
movsd  -0x58(%rbp),%xmm1
mulsd  %xmm1,%xmm0
movsd  0xd96(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
movsd  -0x40(%rbp),%xmm1
movsd  -0x58(%rbp),%xmm0
mulsd  %xmm0,%xmm1
movsd  0xd77(%rip),%xmm0
addsd  %xmm0,%xmm1
movsd  -0x48(%rbp),%xmm0
movsd  -0x68(%rbp),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x60(%rbp)
movsd  0xd5c(%rip),%xmm0
mulsd  -0x50(%rbp),%xmm0
mulsd  -0x58(%rbp),%xmm0
divsd  -0x60(%rbp),%xmm0
movsd  0xd3d(%rip),%xmm1
addsd  %xmm1,%xmm0
call   1050 <log@plt>
movaps %xmm0,%xmm1
movsd  0xd21(%rip),%xmm0
mulsd  %xmm1,%xmm0
mov    -0x30(%rbp),%rax
movsd  %xmm0,(%rax)
cmpl   $0x0,-0x18(%rbp)
jne    1332 <corpbe+0x1f2>
jmp    1481 <corpbe+0x341>
movsd  -0x50(%rbp),%xmm0
divsd  -0x60(%rbp),%xmm0
movsd  %xmm0,-0x98(%rbp)
ff
movsd  -0x48(%rbp),%xmm0
mulsd  -0x68(%rbp),%xmm0
movsd  0xcea(%rip),%xmm1
addsd  -0x50(%rbp),%xmm1
mulsd  %xmm1,%xmm0
movsd  -0x60(%rbp),%xmm1
mulsd  -0x60(%rbp),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xa0(%rbp)
ff
movsd  0xccb(%rip),%xmm1
mulsd  -0x58(%rbp),%xmm1
movsd  -0x98(%rbp),%xmm0
ff
mulsd  %xmm0,%xmm1
movsd  0xcaa(%rip),%xmm0
addsd  %xmm0,%xmm1
movsd  0xc9e(%rip),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xa8(%rbp)
ff
mov    -0x30(%rbp),%rax
movsd  (%rax),%xmm1
movsd  0xca2(%rip),%xmm0
mulsd  -0x58(%rbp),%xmm0
movsd  -0x98(%rbp),%xmm2
ff
movsd  -0xa0(%rbp),%xmm3
ff
movsd  0xc6d(%rip),%xmm4
addsd  -0x40(%rbp),%xmm4
mov    -0x28(%rbp),%rax
movsd  (%rax),%xmm5
subsd  -0x78(%rbp),%xmm5
mulsd  %xmm5,%xmm4
movsd  0xc67(%rip),%xmm5
divsd  %xmm5,%xmm4
movsd  0xc53(%rip),%xmm5
subsd  %xmm5,%xmm4
mulsd  %xmm4,%xmm3
movsd  0xc43(%rip),%xmm4
mulsd  %xmm4,%xmm2
addsd  %xmm3,%xmm2
mulsd  %xmm2,%xmm0
movsd  -0xa8(%rbp),%xmm2
ff
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    -0x38(%rbp),%rax
movsd  %xmm0,(%rax)
movsd  0xbf8(%rip),%xmm0
mulsd  -0x8(%rbp),%xmm0
movsd  -0x98(%rbp),%xmm1
ff
subsd  -0xa0(%rbp),%xmm1
ff
mulsd  %xmm1,%xmm0
mulsd  -0xa8(%rbp),%xmm0
ff
mov    0x10(%rbp),%rax
movsd  %xmm0,(%rax)
add    $0xb0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<corpbe>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x48,%rsp
mov    %r9,%r14
mov    %r8,%r15
mov    %rcx,%r13
mov    %rdx,%rbx
mov    %esi,%r12d
mov    %edi,%ebp
movsd  %xmm1,0x8(%rsp)
xorpd  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
movsd  %xmm0,0x10(%rsp)
jb     117b <corpbe+0x3b>
sqrtsd %xmm0,%xmm6
jmp    1184 <corpbe+0x44>
call   1060 <sqrt@plt>
movapd %xmm0,%xmm6
movsd  0xe74(%rip),%xmm0
movsd  0xe74(%rip),%xmm1
movsd  0xe74(%rip),%xmm2
movsd  0xe74(%rip),%xmm3
movsd  0xe74(%rip),%xmm4
movsd  0xe74(%rip),%xmm5
lea    0x18(%rsp),%rdi
lea    0x40(%rsp),%rsi
call   1030 <gcor2@plt>
movsd  0x18(%rsp),%xmm0
movsd  %xmm0,(%rbx)
movsd  0x40(%rsp),%xmm1
movsd  0x10(%rsp),%xmm2
mulsd  %xmm2,%xmm1
divsd  0xe4b(%rip),%xmm1
addsd  %xmm0,%xmm1
movsd  %xmm1,0x0(%r13)
test   %ebp,%ebp
je     1376 <corpbe+0x236>
divsd  0xe39(%rip),%xmm0
call   1040 <exp@plt>
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
addsd  0xe2d(%rip),%xmm0
movsd  0xe2d(%rip),%xmm4
movapd %xmm4,%xmm3
divsd  %xmm0,%xmm3
movapd %xmm3,%xmm0
mulsd  %xmm3,%xmm0
movsd  0x8(%rsp),%xmm1
mulsd  %xmm1,%xmm1
movapd %xmm1,%xmm2
mulsd  %xmm1,%xmm2
mulsd  %xmm0,%xmm2
movsd  %xmm3,0x30(%rsp)
movapd %xmm3,%xmm0
mulsd  %xmm1,%xmm0
movsd  0xdf9(%rip),%xmm3
addsd  %xmm3,%xmm0
movsd  %xmm2,0x38(%rsp)
addsd  %xmm0,%xmm2
movsd  %xmm0,0x28(%rsp)
mulsd  %xmm4,%xmm0
movsd  %xmm1,0x8(%rsp)
mulsd  %xmm1,%xmm0
movsd  %xmm2,0x20(%rsp)
divsd  %xmm2,%xmm0
addsd  %xmm3,%xmm0
call   1050 <log@plt>
movsd  0x10(%rsp),%xmm4
mulsd  0xdbe(%rip),%xmm0
movsd  %xmm0,(%r15)
test   %r12d,%r12d
je     1376 <corpbe+0x236>
mov    0x80(%rsp),%rax
movsd  0x28(%rsp),%xmm2
movapd %xmm2,%xmm1
movsd  0x20(%rsp),%xmm3
divsd  %xmm3,%xmm1
movsd  0xd84(%rip),%xmm7
addsd  %xmm7,%xmm2
movsd  0x38(%rsp),%xmm6
mulsd  %xmm2,%xmm6
mulsd  %xmm3,%xmm3
divsd  %xmm3,%xmm6
movsd  0x8(%rsp),%xmm5
movapd %xmm5,%xmm2
movsd  0xd53(%rip),%xmm8
mulsd  %xmm8,%xmm2
mulsd  %xmm1,%xmm2
addsd  %xmm7,%xmm2
divsd  %xmm2,%xmm7
movsd  0x30(%rsp),%xmm3
addsd  %xmm8,%xmm3
movsd  0x0(%r13),%xmm2
subsd  0x18(%rsp),%xmm2
mulsd  %xmm3,%xmm2
divsd  0xd37(%rip),%xmm2
addsd  0xd37(%rip),%xmm2
mulsd  %xmm6,%xmm2
movsd  0xd33(%rip),%xmm3
mulsd  %xmm1,%xmm3
addsd  %xmm2,%xmm3
mulsd  0xd2b(%rip),%xmm5
mulsd  %xmm3,%xmm5
mulsd  %xmm7,%xmm5
addsd  %xmm0,%xmm5
movsd  %xmm5,(%r14)
mulsd  0xd1a(%rip),%xmm4
subsd  %xmm6,%xmm1
mulsd  %xmm4,%xmm1
mulsd  %xmm7,%xmm1
movsd  %xmm1,(%rax)
add    $0x48,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
define void @corpbe(double %0, double %1, i32 %2, i32 %3, double* %4, double* %5, double* %6, double* %7, double* %8) {
%10 = alloca double
%11 = alloca double
%12 = alloca i32
%13 = alloca i32
%14 = alloca double*
%15 = alloca double*
%16 = alloca double*
%17 = alloca double*
%18 = alloca double*
%19 = alloca double
%20 = alloca double
%21 = alloca double
%22 = alloca double
%23 = alloca double
%24 = alloca double
%25 = alloca double
%26 = alloca double
%27 = alloca double
%28 = alloca double
%29 = alloca double
%30 = alloca double
%31 = alloca double
%32 = alloca double
store double %0, double* %10
store double %1, double* %11
store i32 %2, i32* %12
store i32 %3, i32* %13
store double* %4, double** %14
store double* %5, double** %15
store double* %6, double** %16
store double* %7, double** %17
store double* %8, double** %18
%33 = load double, double* %10
%34 = call double @sqrt(double %33)
store double %34, double* %29
%35 = load double, double* %29
%36 = call i32 @gcor2(double 3.109070e-02, double 2.137000e-01, double 0x401E61FF2E48E8A7, double 3.587600e+00, double 1.638200e+00, double 4.929400e-01, double %35, double* %26, double* %28)
%37 = load double, double* %26
%38 = load double*, double** %14
store double %37, double* %38
%39 = load double, double* %26
%40 = load double, double* %10
%41 = load double, double* %28
%42 = fmul double %40, %41
%43 = fdiv double %42, 3.000000e+00
%44 = fsub double %39, %43
%45 = load double*, double** %15
store double %44, double* %45
%46 = load i32, i32* %12
%47 = icmp eq i32 %46, 0
br i1 %47, label %48, label %49
48: ; preds = %9
br label %139
49: ; preds = %9
%50 = load double, double* %26
%51 = fneg double %50
%52 = fdiv double %51, 0x3F9FD63CF1FB1944
store double %52, double* %27
%53 = load double, double* %27
%54 = call i32 @exp(double %53)
%55 = sitofp i32 %54 to double
%56 = fsub double %55, 1.000000e+00
%57 = fdiv double 0x40012B444959F3BB, %56
store double %57, double* %19
%58 = load double, double* %19
%59 = load double, double* %19
%60 = fmul double %58, %59
store double %60, double* %20
%61 = load double, double* %11
%62 = load double, double* %11
%63 = fmul double %61, %62
store double %63, double* %22
%64 = load double, double* %22
%65 = load double, double* %22
%66 = fmul double %64, %65
store double %66, double* %24
%67 = load double, double* %19
%68 = load double, double* %22
%69 = call double @llvm.fmuladd.f64(double %67, double %68, double 1.000000e+00)
store double %69, double* %21
%70 = load double, double* %19
%71 = load double, double* %22
%72 = call double @llvm.fmuladd.f64(double %70, double %71, double 1.000000e+00)
%73 = load double, double* %20
%74 = load double, double* %24
%75 = call double @llvm.fmuladd.f64(double %73, double %74, double %72)
store double %75, double* %23
%76 = load double, double* %21
%77 = fmul double %76, 0x40012B444959F3BB
%78 = load double, double* %22
%79 = fmul double %77, %78
%80 = load double, double* %23
%81 = fdiv double %79, %80
%82 = fadd double %81, 1.000000e+00
%83 = call double @log(double %82)
%84 = fmul double 0x3F9FD63CF1FB1944, %83
%85 = load double*, double** %16
store double %84, double* %85
%86 = load i32, i32* %13
%87 = icmp eq i32 %86, 0
br i1 %87, label %88, label %89
88: ; preds = %49
br label %139
89: ; preds = %49
%90 = load double, double* %21
%91 = load double, double* %23
%92 = fdiv double %90, %91
store double %92, double* %30
%93 = load double, double* %20
%94 = load double, double* %24
%95 = fmul double %93, %94
%96 = load double, double* %21
%97 = fadd double 1.000000e+00, %96
%98 = fmul double %95, %97
%99 = load double, double* %23
%100 = load double, double* %23
%101 = fmul double %99, %100
%102 = fdiv double %98, %101
store double %102, double* %31
%103 = load double, double* %22
%104 = fmul double 0x40012B444959F3BB, %103
%105 = load double, double* %30
%106 = call double @llvm.fmuladd.f64(double %104, double %105, double 1.000000e+00)
%107 = fdiv double 1.000000e+00, %106
store double %107, double* %32
%108 = load double*, double** %16
%109 = load double, double* %108
%110 = load double, double* %22
%111 = fmul double 0x3FB114DC32AE4A6A, %110
%112 = load double, double* %30
%113 = load double, double* %31
%114 = load double, double* %19
%115 = fadd double %114, 0x40012B444959F3BB
%116 = load double*, double** %15
%117 = load double, double* %116
%118 = load double, double* %26
%119 = fsub double %117, %118
%120 = fmul double %115, %119
%121 = fdiv double %120, 0x3FB114DC32AE4A6A
%122 = fsub double %121, 0x4002AAAAAAAAAAAB
%123 = fmul double %113, %122
%124 = call double @llvm.fmuladd.f64(double 0x4002AAAAAAAAAAAB, double %112, double %123)
%125 = fmul double %111, %124
%126 = load double, double* %32
%127 = fneg double %125
%128 = call double @llvm.fmuladd.f64(double %127, double %126, double %109)
%129 = load double*, double** %17
store double %128, double* %129
%130 = load double, double* %10
%131 = fmul double 0x3F8BF636B99EEB6F, %130
%132 = load double, double* %30
%133 = load double, double* %31
%134 = fsub double %132, %133
%135 = fmul double %131, %134
%136 = load double, double* %32
%137 = fmul double %135, %136
%138 = load double*, double** %18
store double %137, double* %138
br label %139
139: ; preds = %89, %88, %48
ret void
}

LLVM IR (-O2):
define void @corpbe(double %0, double %1, i32 %2, i32 %3, double* nocapture writeonly %4, double* nocapture %5, double* nocapture writeonly %6, double* nocapture writeonly %7, double* nocapture writeonly %8) {
%10 = alloca double
%11 = alloca double
%12 = bitcast double* %10 to i8*
%13 = bitcast double* %11 to i8*
%14 = tail call double @sqrt(double %0)
%15 = call i32 @gcor2(double 3.109070e-02, double 2.137000e-01, double 0x401E61FF2E48E8A7, double 3.587600e+00, double 1.638200e+00, double 4.929400e-01, double %14, double* %10, double* %11)
%16 = load double, double* %10
store double %16, double* %4
%17 = load double, double* %11
%18 = fmul double %17, %0
%19 = fdiv double %18, 3.000000e+00
%20 = fsub double %16, %19
store double %20, double* %5
%21 = icmp eq i32 %2, 0
br i1 %21, label %66, label %22
22: ; preds = %9
%23 = fdiv double %16, 0xBF9FD63CF1FB1944
%24 = call i32 @exp(double %23)
%25 = sitofp i32 %24 to double
%26 = fadd double %25, -1.000000e+00
%27 = fdiv double 0x40012B444959F3BB, %26
%28 = fmul double %27, %27
%29 = fmul double %1, %1
%30 = fmul double %29, %29
%31 = call double @llvm.fmuladd.f64(double %27, double %29, double 1.000000e+00)
%32 = call double @llvm.fmuladd.f64(double %28, double %30, double %31)
%33 = fmul double %31, 0x40012B444959F3BB
%34 = fmul double %29, %33
%35 = fdiv double %34, %32
%36 = fadd double %35, 1.000000e+00
%37 = call double @log(double %36)
%38 = fmul double %37, 0x3F9FD63CF1FB1944
store double %38, double* %6
%39 = icmp eq i32 %3, 0
br i1 %39, label %66, label %40
40: ; preds = %22
%41 = fdiv double %31, %32
%42 = fmul double %30, %28
%43 = fadd double %31, 1.000000e+00
%44 = fmul double %42, %43
%45 = fmul double %32, %32
%46 = fdiv double %44, %45
%47 = fmul double %29, 0x40012B444959F3BB
%48 = call double @llvm.fmuladd.f64(double %47, double %41, double 1.000000e+00)
%49 = fdiv double 1.000000e+00, %48
%50 = fadd double %27, 0x40012B444959F3BB
%51 = load double, double* %5
%52 = load double, double* %10
%53 = fsub double %51, %52
%54 = fmul double %50, %53
%55 = fdiv double %54, 0x3FB114DC32AE4A6A
%56 = fadd double %55, 0xC002AAAAAAAAAAAB
%57 = fmul double %46, %56
%58 = call double @llvm.fmuladd.f64(double %41, double 0x4002AAAAAAAAAAAB, double %57)
%59 = fmul double %29, 0xBFB114DC32AE4A6A
%60 = fmul double %59, %58
%61 = call double @llvm.fmuladd.f64(double %60, double %49, double %38)
store double %61, double* %7
%62 = fmul double %0, 0x3F8BF636B99EEB6F
%63 = fsub double %41, %46
%64 = fmul double %62, %63
%65 = fmul double %49, %64
store double %65, double* %8
br label %66
66: ; preds = %22, %9, %40
ret void
}