void evaluateGTRGAMMA_VECTOR(int *ex2, double *x2_start, double *v,
                             double *EIGN, double *gammaRates,
                             double *tipVector, double pz, char *tipX1,
                             int lower, int n) {
  double z, lz, term, ki;
  int i;
  double *diagptable, *diagptable_start;
  double *x1, *x2;
  z = pz;
  if (z < 1.0E-15)
    z = 1.0E-15;
  lz = log(z);
  diagptable = diagptable_start = (double *)malloc(sizeof(double) * 4 * 3);
  for (i = 0; i < 4; i++) {
    ki = gammaRates[i];
    *diagptable++ = exp(EIGN[0] * ki * lz);
    *diagptable++ = exp(EIGN[1] * ki * lz);
    *diagptable++ = exp(EIGN[2] * ki * lz);
  }
  for (i = lower; i < n; i++) {
    x1 = &(tipVector[4 * tipX1[i]]);
    x2 = &x2_start[16 * i];
    diagptable = diagptable_start;
    term = x1[0] * x2[0];
    term += x1[1] * x2[1] * *diagptable++;
    term += x1[2] * x2[2] * *diagptable++;
    term += x1[3] * x2[3] * *diagptable++;
    term += x1[0] * x2[4];
    term += x1[1] * x2[5] * *diagptable++;
    term += x1[2] * x2[6] * *diagptable++;
    term += x1[3] * x2[7] * *diagptable++;
    term += x1[0] * x2[8];
    term += x1[1] * x2[9] * *diagptable++;
    term += x1[2] * x2[10] * *diagptable++;
    term += x1[3] * x2[11] * *diagptable++;
    term += x1[0] * x2[12];
    term += x1[1] * x2[13] * *diagptable++;
    term += x1[2] * x2[14] * *diagptable++;
    term += x1[3] * x2[15] * *diagptable++;
    term =
        log(0.25 * term) +
        ex2[i] *
            log((
                1.0 /
                115792089237316195423570985008687907853269984665640564039457584007913129639936.0));
    v[i] = term;
  }
  free(diagptable_start);
}


x86 assembly (clang, -O0):
<evaluateGTRGAMMA_VECTOR>:
push   %rbp
mov    %rsp,%rbp
sub    $0x90,%rsp
mov    0x20(%rbp),%eax
mov    0x18(%rbp),%eax
mov    0x10(%rbp),%rax
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
mov    %r9,-0x30(%rbp)
movsd  %xmm0,-0x38(%rbp)
movsd  -0x38(%rbp),%xmm0
movsd  %xmm0,-0x40(%rbp)
movsd  0xe7c(%rip),%xmm0
ucomisd -0x40(%rbp),%xmm0
jbe    119c <evaluateGTRGAMMA_VECTOR+0x5c>
movsd  0xe69(%rip),%xmm0
movsd  %xmm0,-0x40(%rbp)
movsd  -0x40(%rbp),%xmm0
call   1060 <log@plt>
movsd  %xmm0,-0x48(%rbp)
mov    $0x60,%edi
call   1040 <malloc@plt>
mov    %rax,-0x70(%rbp)
mov    %rax,-0x68(%rbp)
movl   $0x0,-0x5c(%rbp)
cmpl   $0x4,-0x5c(%rbp)
jge    126e <evaluateGTRGAMMA_VECTOR+0x12e>
mov    -0x28(%rbp),%rax
movslq -0x5c(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0x58(%rbp)
mov    -0x20(%rbp),%rax
movsd  (%rax),%xmm0
mulsd  -0x58(%rbp),%xmm0
mulsd  -0x48(%rbp),%xmm0
call   1050 <exp@plt>
mov    -0x68(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,-0x68(%rbp)
movsd  %xmm0,(%rax)
mov    -0x20(%rbp),%rax
movsd  0x8(%rax),%xmm0
mulsd  -0x58(%rbp),%xmm0
mulsd  -0x48(%rbp),%xmm0
call   1050 <exp@plt>
mov    -0x68(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,-0x68(%rbp)
movsd  %xmm0,(%rax)
mov    -0x20(%rbp),%rax
movsd  0x10(%rax),%xmm0
mulsd  -0x58(%rbp),%xmm0
mulsd  -0x48(%rbp),%xmm0
call   1050 <exp@plt>
mov    -0x68(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,-0x68(%rbp)
movsd  %xmm0,(%rax)
mov    -0x5c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x5c(%rbp)
jmp    11c4 <evaluateGTRGAMMA_VECTOR+0x84>
mov    0x18(%rbp),%eax
mov    %eax,-0x5c(%rbp)
mov    -0x5c(%rbp),%eax
cmp    0x20(%rbp),%eax
jge    164f <evaluateGTRGAMMA_VECTOR+0x50f>
mov    -0x30(%rbp),%rax
mov    0x10(%rbp),%rcx
movslq -0x5c(%rbp),%rdx
movsbl (%rcx,%rdx,1),%ecx
shl    $0x2,%ecx
movslq %ecx,%rcx
shl    $0x3,%rcx
add    %rcx,%rax
mov    %rax,-0x78(%rbp)
mov    -0x10(%rbp),%rax
mov    -0x5c(%rbp),%ecx
shl    $0x4,%ecx
movslq %ecx,%rcx
shl    $0x3,%rcx
add    %rcx,%rax
mov    %rax,-0x80(%rbp)
mov    -0x70(%rbp),%rax
mov    %rax,-0x68(%rbp)
mov    -0x78(%rbp),%rax
movsd  (%rax),%xmm0
mov    -0x80(%rbp),%rax
mulsd  (%rax),%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x78(%rbp),%rax
movsd  0x8(%rax),%xmm0
mov    -0x80(%rbp),%rax
mulsd  0x8(%rax),%xmm0
mov    -0x68(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,-0x68(%rbp)
movsd  (%rax),%xmm2
movsd  -0x50(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x78(%rbp),%rax
movsd  0x10(%rax),%xmm0
mov    -0x80(%rbp),%rax
mulsd  0x10(%rax),%xmm0
mov    -0x68(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,-0x68(%rbp)
movsd  (%rax),%xmm2
movsd  -0x50(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x78(%rbp),%rax
movsd  0x18(%rax),%xmm0
mov    -0x80(%rbp),%rax
mulsd  0x18(%rax),%xmm0
mov    -0x68(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,-0x68(%rbp)
movsd  (%rax),%xmm2
movsd  -0x50(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x78(%rbp),%rax
movsd  (%rax),%xmm0
mov    -0x80(%rbp),%rax
movsd  0x20(%rax),%xmm2
movsd  -0x50(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x78(%rbp),%rax
movsd  0x8(%rax),%xmm0
mov    -0x80(%rbp),%rax
mulsd  0x28(%rax),%xmm0
mov    -0x68(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,-0x68(%rbp)
movsd  (%rax),%xmm2
movsd  -0x50(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x78(%rbp),%rax
movsd  0x10(%rax),%xmm0
mov    -0x80(%rbp),%rax
mulsd  0x30(%rax),%xmm0
mov    -0x68(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,-0x68(%rbp)
movsd  (%rax),%xmm2
movsd  -0x50(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x78(%rbp),%rax
movsd  0x18(%rax),%xmm0
mov    -0x80(%rbp),%rax
mulsd  0x38(%rax),%xmm0
mov    -0x68(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,-0x68(%rbp)
movsd  (%rax),%xmm2
movsd  -0x50(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x78(%rbp),%rax
movsd  (%rax),%xmm0
mov    -0x80(%rbp),%rax
movsd  0x40(%rax),%xmm2
movsd  -0x50(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x78(%rbp),%rax
movsd  0x8(%rax),%xmm0
mov    -0x80(%rbp),%rax
mulsd  0x48(%rax),%xmm0
mov    -0x68(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,-0x68(%rbp)
movsd  (%rax),%xmm2
movsd  -0x50(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x78(%rbp),%rax
movsd  0x10(%rax),%xmm0
mov    -0x80(%rbp),%rax
mulsd  0x50(%rax),%xmm0
mov    -0x68(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,-0x68(%rbp)
movsd  (%rax),%xmm2
movsd  -0x50(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x78(%rbp),%rax
movsd  0x18(%rax),%xmm0
mov    -0x80(%rbp),%rax
mulsd  0x58(%rax),%xmm0
mov    -0x68(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,-0x68(%rbp)
movsd  (%rax),%xmm2
movsd  -0x50(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x78(%rbp),%rax
movsd  (%rax),%xmm0
mov    -0x80(%rbp),%rax
movsd  0x60(%rax),%xmm2
movsd  -0x50(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x78(%rbp),%rax
movsd  0x8(%rax),%xmm0
mov    -0x80(%rbp),%rax
mulsd  0x68(%rax),%xmm0
mov    -0x68(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,-0x68(%rbp)
movsd  (%rax),%xmm2
movsd  -0x50(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x78(%rbp),%rax
movsd  0x10(%rax),%xmm0
mov    -0x80(%rbp),%rax
mulsd  0x70(%rax),%xmm0
mov    -0x68(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,-0x68(%rbp)
movsd  (%rax),%xmm2
movsd  -0x50(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x78(%rbp),%rax
movsd  0x18(%rax),%xmm0
mov    -0x80(%rbp),%rax
mulsd  0x78(%rax),%xmm0
mov    -0x68(%rbp),%rax
mov    %rax,%rcx
add    $0x8,%rcx
mov    %rcx,-0x68(%rbp)
movsd  (%rax),%xmm2
movsd  -0x50(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
movsd  0xa35(%rip),%xmm0
mulsd  -0x50(%rbp),%xmm0
call   1060 <log@plt>
movsd  %xmm0,-0x90(%rbp)
ff
mov    -0x8(%rbp),%rax
movslq -0x5c(%rbp),%rcx
cvtsi2sdl (%rax,%rcx,4),%xmm0
movsd  %xmm0,-0x88(%rbp)
ff
movsd  0x9fe(%rip),%xmm0
call   1060 <log@plt>
movsd  -0x90(%rbp),%xmm1
ff
movaps %xmm0,%xmm2
movsd  -0x88(%rbp),%xmm0
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
movsd  -0x50(%rbp),%xmm0
mov    -0x18(%rbp),%rax
movslq -0x5c(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x5c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x5c(%rbp)
jmp    1274 <evaluateGTRGAMMA_VECTOR+0x134>
mov    -0x70(%rbp),%rdi
call   1030 <free@plt>
add    $0x90,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<evaluateGTRGAMMA_VECTOR>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x78,%rsp
mov    %r9,%r15
mov    %r8,%r14
mov    %rcx,%r13
mov    %rdx,0x70(%rsp)
mov    %rsi,%rbx
mov    %rdi,%r12
mov    0xb8(%rsp),%ebp
movsd  0xeaf(%rip),%xmm1
maxsd  %xmm0,%xmm1
movapd %xmm1,%xmm0
call   1040 <log@plt>
movapd %xmm0,%xmm1
movsd  %xmm0,0x8(%rsp)
movsd  (%r14),%xmm2
movsd  %xmm2,0x20(%rsp)
movsd  0x0(%r13),%xmm0
mulsd  %xmm2,%xmm0
mulsd  %xmm1,%xmm0
call   1030 <exp@plt>
movsd  %xmm0,0x68(%rsp)
movsd  0x8(%r13),%xmm0
mulsd  0x20(%rsp),%xmm0
mulsd  0x8(%rsp),%xmm0
call   1030 <exp@plt>
movsd  %xmm0,0x60(%rsp)
movsd  0x20(%rsp),%xmm0
mulsd  0x10(%r13),%xmm0
mulsd  0x8(%rsp),%xmm0
call   1030 <exp@plt>
movsd  %xmm0,0x20(%rsp)
movsd  0x8(%r14),%xmm1
movsd  %xmm1,0x18(%rsp)
movsd  0x0(%r13),%xmm0
mulsd  %xmm1,%xmm0
mulsd  0x8(%rsp),%xmm0
call   1030 <exp@plt>
movsd  %xmm0,0x58(%rsp)
movsd  0x8(%r13),%xmm0
mulsd  0x18(%rsp),%xmm0
mulsd  0x8(%rsp),%xmm0
call   1030 <exp@plt>
movsd  %xmm0,0x50(%rsp)
movsd  0x18(%rsp),%xmm0
mulsd  0x10(%r13),%xmm0
mulsd  0x8(%rsp),%xmm0
call   1030 <exp@plt>
movsd  %xmm0,0x18(%rsp)
movsd  0x10(%r14),%xmm1
movsd  %xmm1,0x10(%rsp)
movsd  0x0(%r13),%xmm0
mulsd  %xmm1,%xmm0
mulsd  0x8(%rsp),%xmm0
call   1030 <exp@plt>
movsd  %xmm0,0x48(%rsp)
movsd  0x8(%r13),%xmm0
mulsd  0x10(%rsp),%xmm0
mulsd  0x8(%rsp),%xmm0
call   1030 <exp@plt>
movsd  %xmm0,0x40(%rsp)
movsd  0x10(%rsp),%xmm0
mulsd  0x10(%r13),%xmm0
mulsd  0x8(%rsp),%xmm0
call   1030 <exp@plt>
movsd  %xmm0,0x10(%rsp)
movsd  0x18(%r14),%xmm1
movsd  %xmm1,0x28(%rsp)
movsd  0x0(%r13),%xmm0
mulsd  %xmm1,%xmm0
mulsd  0x8(%rsp),%xmm0
call   1030 <exp@plt>
movsd  %xmm0,0x38(%rsp)
movsd  0x8(%r13),%xmm0
mulsd  0x28(%rsp),%xmm0
mulsd  0x8(%rsp),%xmm0
call   1030 <exp@plt>
movsd  %xmm0,0x30(%rsp)
movsd  0x28(%rsp),%xmm0
mulsd  0x10(%r13),%xmm0
mulsd  0x8(%rsp),%xmm0
call   1030 <exp@plt>
mov    0xc0(%rsp),%eax
cmp    %eax,%ebp
jge    1493 <evaluateGTRGAMMA_VECTOR+0x373>
movapd %xmm0,%xmm6
movslq %ebp,%r13
movslq %eax,%r14
shl    $0x4,%ebp
movsd  %xmm0,0x8(%rsp)
cs nopw 0x0(%rax,%rax,1)
nop
mov    0xb0(%rsp),%rax
movsbq (%rax,%r13,1),%rax
shl    $0x5,%rax
movslq %ebp,%rbp
movsd  (%r15,%rax,1),%xmm2
movsd  0x8(%r15,%rax,1),%xmm1
movsd  (%rbx,%rbp,8),%xmm0
mulsd  %xmm2,%xmm0
movsd  0x8(%rbx,%rbp,8),%xmm4
mulsd  %xmm1,%xmm4
mulsd  0x68(%rsp),%xmm4
addsd  %xmm0,%xmm4
movsd  0x10(%r15,%rax,1),%xmm3
movsd  0x10(%rbx,%rbp,8),%xmm5
mulsd  %xmm3,%xmm5
mulsd  0x60(%rsp),%xmm5
addsd  %xmm4,%xmm5
movsd  0x18(%r15,%rax,1),%xmm0
movsd  0x18(%rbx,%rbp,8),%xmm4
mulsd  %xmm0,%xmm4
mulsd  0x20(%rsp),%xmm4
addsd  %xmm5,%xmm4
movsd  0x20(%rbx,%rbp,8),%xmm5
mulsd  %xmm2,%xmm5
addsd  %xmm4,%xmm5
movsd  0x28(%rbx,%rbp,8),%xmm4
mulsd  %xmm1,%xmm4
mulsd  0x58(%rsp),%xmm4
addsd  %xmm5,%xmm4
movsd  0x30(%rbx,%rbp,8),%xmm5
mulsd  %xmm3,%xmm5
mulsd  0x50(%rsp),%xmm5
addsd  %xmm4,%xmm5
movsd  0x38(%rbx,%rbp,8),%xmm4
mulsd  %xmm0,%xmm4
mulsd  0x18(%rsp),%xmm4
addsd  %xmm5,%xmm4
movsd  0x40(%rbx,%rbp,8),%xmm5
mulsd  %xmm2,%xmm5
addsd  %xmm4,%xmm5
movsd  0x48(%rbx,%rbp,8),%xmm4
mulsd  %xmm1,%xmm4
mulsd  0x48(%rsp),%xmm4
addsd  %xmm5,%xmm4
movsd  0x50(%rbx,%rbp,8),%xmm5
mulsd  %xmm3,%xmm5
mulsd  0x40(%rsp),%xmm5
addsd  %xmm4,%xmm5
movsd  0x58(%rbx,%rbp,8),%xmm4
mulsd  %xmm0,%xmm4
mulsd  0x10(%rsp),%xmm4
addsd  %xmm5,%xmm4
mulsd  0x60(%rbx,%rbp,8),%xmm2
mulsd  0x68(%rbx,%rbp,8),%xmm1
addsd  %xmm4,%xmm2
mulsd  0x38(%rsp),%xmm1
mulsd  0x70(%rbx,%rbp,8),%xmm3
addsd  %xmm2,%xmm1
mulsd  0x30(%rsp),%xmm3
mulsd  0x78(%rbx,%rbp,8),%xmm0
addsd  %xmm1,%xmm3
mulsd  %xmm6,%xmm0
addsd  %xmm3,%xmm0
mulsd  0xbb0(%rip),%xmm0
call   1040 <log@plt>
movsd  0x8(%rsp),%xmm6
xorps  %xmm1,%xmm1
cvtsi2sdl (%r12,%r13,4),%xmm1
mulsd  0xb9c(%rip),%xmm1
addsd  %xmm0,%xmm1
mov    0x70(%rsp),%rax
movsd  %xmm1,(%rax,%r13,8)
add    $0x1,%r13
add    $0x10,%ebp
cmp    %r13,%r14
jne    1310 <evaluateGTRGAMMA_VECTOR+0x1f0>
add    $0x78,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
define void @evaluateGTRGAMMA_VECTOR(i32* %0, double* %1, double* %2, double* %3, double* %4, double* %5, double %6, i8* %7, i32 %8, i32 %9) {
%11 = alloca i32*
%12 = alloca double*
%13 = alloca double*
%14 = alloca double*
%15 = alloca double*
%16 = alloca double*
%17 = alloca double
%18 = alloca i8*
%19 = alloca i32
%20 = alloca i32
%21 = alloca double
%22 = alloca double
%23 = alloca double
%24 = alloca double
%25 = alloca i32
%26 = alloca double*
%27 = alloca double*
%28 = alloca double*
%29 = alloca double*
store i32* %0, i32** %11
store double* %1, double** %12
store double* %2, double** %13
store double* %3, double** %14
store double* %4, double** %15
store double* %5, double** %16
store double %6, double* %17
store i8* %7, i8** %18
store i32 %8, i32* %19
store i32 %9, i32* %20
%30 = load double, double* %17
store double %30, double* %21
%31 = load double, double* %21
%32 = fcmp olt double %31, 1.000000e-15
br i1 %32, label %33, label %34
33: ; preds = %10
store double 1.000000e-15, double* %21
br label %34
34: ; preds = %33, %10
%35 = load double, double* %21
%36 = call double @log(double %35)
store double %36, double* %22
%37 = call i8* @malloc(i64 96)
%38 = bitcast i8* %37 to double*
store double* %38, double** %27
store double* %38, double** %26
store i32 0, i32* %25
br label %39
39: ; preds = %78, %34
%40 = load i32, i32* %25
%41 = icmp slt i32 %40, 4
br i1 %41, label %42, label %81
42: ; preds = %39
%43 = load double*, double** %15
%44 = load i32, i32* %25
%45 = sext i32 %44 to i64
%46 = getelementptr inbounds double, double* %43, i64 %45
%47 = load double, double* %46
store double %47, double* %24
%48 = load double*, double** %14
%49 = getelementptr inbounds double, double* %48, i64 0
%50 = load double, double* %49
%51 = load double, double* %24
%52 = fmul double %50, %51
%53 = load double, double* %22
%54 = fmul double %52, %53
%55 = call double @exp(double %54)
%56 = load double*, double** %26
%57 = getelementptr inbounds double, double* %56, i32 1
store double* %57, double** %26
store double %55, double* %56
%58 = load double*, double** %14
%59 = getelementptr inbounds double, double* %58, i64 1
%60 = load double, double* %59
%61 = load double, double* %24
%62 = fmul double %60, %61
%63 = load double, double* %22
%64 = fmul double %62, %63
%65 = call double @exp(double %64)
%66 = load double*, double** %26
%67 = getelementptr inbounds double, double* %66, i32 1
store double* %67, double** %26
store double %65, double* %66
%68 = load double*, double** %14
%69 = getelementptr inbounds double, double* %68, i64 2
%70 = load double, double* %69
%71 = load double, double* %24
%72 = fmul double %70, %71
%73 = load double, double* %22
%74 = fmul double %72, %73
%75 = call double @exp(double %74)
%76 = load double*, double** %26
%77 = getelementptr inbounds double, double* %76, i32 1
store double* %77, double** %26
store double %75, double* %76
br label %78
78: ; preds = %42
%79 = load i32, i32* %25
%80 = add nsw i32 %79, 1
store i32 %80, i32* %25
br label %39
81: ; preds = %39
%82 = load i32, i32* %19
store i32 %82, i32* %25
br label %83
83: ; preds = %295, %81
%84 = load i32, i32* %25
%85 = load i32, i32* %20
%86 = icmp slt i32 %84, %85
br i1 %86, label %87, label %298
87: ; preds = %83
%88 = load double*, double** %16
%89 = load i8*, i8** %18
%90 = load i32, i32* %25
%91 = sext i32 %90 to i64
%92 = getelementptr inbounds i8, i8* %89, i64 %91
%93 = load i8, i8* %92
%94 = sext i8 %93 to i32
%95 = mul nsw i32 4, %94
%96 = sext i32 %95 to i64
%97 = getelementptr inbounds double, double* %88, i64 %96
store double* %97, double** %28
%98 = load double*, double** %12
%99 = load i32, i32* %25
%100 = mul nsw i32 16, %99
%101 = sext i32 %100 to i64
%102 = getelementptr inbounds double, double* %98, i64 %101
store double* %102, double** %29
%103 = load double*, double** %27
store double* %103, double** %26
%104 = load double*, double** %28
%105 = getelementptr inbounds double, double* %104, i64 0
%106 = load double, double* %105
%107 = load double*, double** %29
%108 = getelementptr inbounds double, double* %107, i64 0
%109 = load double, double* %108
%110 = fmul double %106, %109
store double %110, double* %23
%111 = load double*, double** %28
%112 = getelementptr inbounds double, double* %111, i64 1
%113 = load double, double* %112
%114 = load double*, double** %29
%115 = getelementptr inbounds double, double* %114, i64 1
%116 = load double, double* %115
%117 = fmul double %113, %116
%118 = load double*, double** %26
%119 = getelementptr inbounds double, double* %118, i32 1
store double* %119, double** %26
%120 = load double, double* %118
%121 = load double, double* %23
%122 = call double @llvm.fmuladd.f64(double %117, double %120, double %121)
store double %122, double* %23
%123 = load double*, double** %28
%124 = getelementptr inbounds double, double* %123, i64 2
%125 = load double, double* %124
%126 = load double*, double** %29
%127 = getelementptr inbounds double, double* %126, i64 2
%128 = load double, double* %127
%129 = fmul double %125, %128
%130 = load double*, double** %26
%131 = getelementptr inbounds double, double* %130, i32 1
store double* %131, double** %26
%132 = load double, double* %130
%133 = load double, double* %23
%134 = call double @llvm.fmuladd.f64(double %129, double %132, double %133)
store double %134, double* %23
%135 = load double*, double** %28
%136 = getelementptr inbounds double, double* %135, i64 3
%137 = load double, double* %136
%138 = load double*, double** %29
%139 = getelementptr inbounds double, double* %138, i64 3
%140 = load double, double* %139
%141 = fmul double %137, %140
%142 = load double*, double** %26
%143 = getelementptr inbounds double, double* %142, i32 1
store double* %143, double** %26
%144 = load double, double* %142
%145 = load double, double* %23
%146 = call double @llvm.fmuladd.f64(double %141, double %144, double %145)
store double %146, double* %23
%147 = load double*, double** %28
%148 = getelementptr inbounds double, double* %147, i64 0
%149 = load double, double* %148
%150 = load double*, double** %29
%151 = getelementptr inbounds double, double* %150, i64 4
%152 = load double, double* %151
%153 = load double, double* %23
%154 = call double @llvm.fmuladd.f64(double %149, double %152, double %153)
store double %154, double* %23
%155 = load double*, double** %28
%156 = getelementptr inbounds double, double* %155, i64 1
%157 = load double, double* %156
%158 = load double*, double** %29
%159 = getelementptr inbounds double, double* %158, i64 5
%160 = load double, double* %159
%161 = fmul double %157, %160
%162 = load double*, double** %26
%163 = getelementptr inbounds double, double* %162, i32 1
store double* %163, double** %26
%164 = load double, double* %162
%165 = load double, double* %23
%166 = call double @llvm.fmuladd.f64(double %161, double %164, double %165)
store double %166, double* %23
%167 = load double*, double** %28
%168 = getelementptr inbounds double, double* %167, i64 2
%169 = load double, double* %168
%170 = load double*, double** %29
%171 = getelementptr inbounds double, double* %170, i64 6
%172 = load double, double* %171
%173 = fmul double %169, %172
%174 = load double*, double** %26
%175 = getelementptr inbounds double, double* %174, i32 1
store double* %175, double** %26
%176 = load double, double* %174
%177 = load double, double* %23
%178 = call double @llvm.fmuladd.f64(double %173, double %176, double %177)
store double %178, double* %23
%179 = load double*, double** %28
%180 = getelementptr inbounds double, double* %179, i64 3
%181 = load double, double* %180
%182 = load double*, double** %29
%183 = getelementptr inbounds double, double* %182, i64 7
%184 = load double, double* %183
%185 = fmul double %181, %184
%186 = load double*, double** %26
%187 = getelementptr inbounds double, double* %186, i32 1
store double* %187, double** %26
%188 = load double, double* %186
%189 = load double, double* %23
%190 = call double @llvm.fmuladd.f64(double %185, double %188, double %189)
store double %190, double* %23
%191 = load double*, double** %28
%192 = getelementptr inbounds double, double* %191, i64 0
%193 = load double, double* %192
%194 = load double*, double** %29
%195 = getelementptr inbounds double, double* %194, i64 8
%196 = load double, double* %195
%197 = load double, double* %23
%198 = call double @llvm.fmuladd.f64(double %193, double %196, double %197)
store double %198, double* %23
%199 = load double*, double** %28
%200 = getelementptr inbounds double, double* %199, i64 1
%201 = load double, double* %200
%202 = load double*, double** %29
%203 = getelementptr inbounds double, double* %202, i64 9
%204 = load double, double* %203
%205 = fmul double %201, %204
%206 = load double*, double** %26
%207 = getelementptr inbounds double, double* %206, i32 1
store double* %207, double** %26
%208 = load double, double* %206
%209 = load double, double* %23
%210 = call double @llvm.fmuladd.f64(double %205, double %208, double %209)
store double %210, double* %23
%211 = load double*, double** %28
%212 = getelementptr inbounds double, double* %211, i64 2
%213 = load double, double* %212
%214 = load double*, double** %29
%215 = getelementptr inbounds double, double* %214, i64 10
%216 = load double, double* %215
%217 = fmul double %213, %216
%218 = load double*, double** %26
%219 = getelementptr inbounds double, double* %218, i32 1
store double* %219, double** %26
%220 = load double, double* %218
%221 = load double, double* %23
%222 = call double @llvm.fmuladd.f64(double %217, double %220, double %221)
store double %222, double* %23
%223 = load double*, double** %28
%224 = getelementptr inbounds double, double* %223, i64 3
%225 = load double, double* %224
%226 = load double*, double** %29
%227 = getelementptr inbounds double, double* %226, i64 11
%228 = load double, double* %227
%229 = fmul double %225, %228
%230 = load double*, double** %26
%231 = getelementptr inbounds double, double* %230, i32 1
store double* %231, double** %26
%232 = load double, double* %230
%233 = load double, double* %23
%234 = call double @llvm.fmuladd.f64(double %229, double %232, double %233)
store double %234, double* %23
%235 = load double*, double** %28
%236 = getelementptr inbounds double, double* %235, i64 0
%237 = load double, double* %236
%238 = load double*, double** %29
%239 = getelementptr inbounds double, double* %238, i64 12
%240 = load double, double* %239
%241 = load double, double* %23
%242 = call double @llvm.fmuladd.f64(double %237, double %240, double %241)
store double %242, double* %23
%243 = load double*, double** %28
%244 = getelementptr inbounds double, double* %243, i64 1
%245 = load double, double* %244
%246 = load double*, double** %29
%247 = getelementptr inbounds double, double* %246, i64 13
%248 = load double, double* %247
%249 = fmul double %245, %248
%250 = load double*, double** %26
%251 = getelementptr inbounds double, double* %250, i32 1
store double* %251, double** %26
%252 = load double, double* %250
%253 = load double, double* %23
%254 = call double @llvm.fmuladd.f64(double %249, double %252, double %253)
store double %254, double* %23
%255 = load double*, double** %28
%256 = getelementptr inbounds double, double* %255, i64 2
%257 = load double, double* %256
%258 = load double*, double** %29
%259 = getelementptr inbounds double, double* %258, i64 14
%260 = load double, double* %259
%261 = fmul double %257, %260
%262 = load double*, double** %26
%263 = getelementptr inbounds double, double* %262, i32 1
store double* %263, double** %26
%264 = load double, double* %262
%265 = load double, double* %23
%266 = call double @llvm.fmuladd.f64(double %261, double %264, double %265)
store double %266, double* %23
%267 = load double*, double** %28
%268 = getelementptr inbounds double, double* %267, i64 3
%269 = load double, double* %268
%270 = load double*, double** %29
%271 = getelementptr inbounds double, double* %270, i64 15
%272 = load double, double* %271
%273 = fmul double %269, %272
%274 = load double*, double** %26
%275 = getelementptr inbounds double, double* %274, i32 1
store double* %275, double** %26
%276 = load double, double* %274
%277 = load double, double* %23
%278 = call double @llvm.fmuladd.f64(double %273, double %276, double %277)
store double %278, double* %23
%279 = load double, double* %23
%280 = fmul double 2.500000e-01, %279
%281 = call double @log(double %280)
%282 = load i32*, i32** %11
%283 = load i32, i32* %25
%284 = sext i32 %283 to i64
%285 = getelementptr inbounds i32, i32* %282, i64 %284
%286 = load i32, i32* %285
%287 = sitofp i32 %286 to double
%288 = call double @log(double 0x2FF0000000000000)
%289 = call double @llvm.fmuladd.f64(double %287, double %288, double %281)
store double %289, double* %23
%290 = load double, double* %23
%291 = load double*, double** %13
%292 = load i32, i32* %25
%293 = sext i32 %292 to i64
%294 = getelementptr inbounds double, double* %291, i64 %293
store double %290, double* %294
br label %295
295: ; preds = %87
%296 = load i32, i32* %25
%297 = add nsw i32 %296, 1
store i32 %297, i32* %25
br label %83
298: ; preds = %83
%299 = load double*, double** %27
%300 = bitcast double* %299 to i8*
ret void
}

LLVM IR (-O2):
define void @evaluateGTRGAMMA_VECTOR(i32* nocapture %0, double* nocapture %1, double* nocapture writeonly %2, double* nocapture %3, double* nocapture %4, double* nocapture %5, double %6, i8* nocapture %7, i32 %8, i32 %9) {
%11 = fcmp olt double %6, 1.000000e-15
%12 = select i1 %11, double 1.000000e-15, double %6
%13 = tail call double @log(double %12)
%14 = getelementptr inbounds double, double* %3, i64 1
%15 = getelementptr inbounds double, double* %3, i64 2
%16 = load double, double* %4
%17 = load double, double* %3
%18 = fmul double %16, %17
%19 = fmul double %13, %18
%20 = tail call double @exp(double %19)
%21 = load double, double* %14
%22 = fmul double %16, %21
%23 = fmul double %13, %22
%24 = tail call double @exp(double %23)
%25 = load double, double* %15
%26 = fmul double %16, %25
%27 = fmul double %13, %26
%28 = tail call double @exp(double %27)
%29 = getelementptr inbounds double, double* %4, i64 1
%30 = load double, double* %29
%31 = load double, double* %3
%32 = fmul double %30, %31
%33 = fmul double %13, %32
%34 = tail call double @exp(double %33)
%35 = load double, double* %14
%36 = fmul double %30, %35
%37 = fmul double %13, %36
%38 = tail call double @exp(double %37)
%39 = load double, double* %15
%40 = fmul double %30, %39
%41 = fmul double %13, %40
%42 = tail call double @exp(double %41)
%43 = getelementptr inbounds double, double* %4, i64 2
%44 = load double, double* %43
%45 = load double, double* %3
%46 = fmul double %44, %45
%47 = fmul double %13, %46
%48 = tail call double @exp(double %47)
%49 = load double, double* %14
%50 = fmul double %44, %49
%51 = fmul double %13, %50
%52 = tail call double @exp(double %51)
%53 = load double, double* %15
%54 = fmul double %44, %53
%55 = fmul double %13, %54
%56 = tail call double @exp(double %55)
%57 = getelementptr inbounds double, double* %4, i64 3
%58 = load double, double* %57
%59 = load double, double* %3
%60 = fmul double %58, %59
%61 = fmul double %13, %60
%62 = tail call double @exp(double %61)
%63 = load double, double* %14
%64 = fmul double %58, %63
%65 = fmul double %13, %64
%66 = tail call double @exp(double %65)
%67 = load double, double* %15
%68 = fmul double %58, %67
%69 = fmul double %13, %68
%70 = tail call double @exp(double %69)
%71 = icmp slt i32 %8, %9
br i1 %71, label %72, label %162
72: ; preds = %10
%73 = sext i32 %8 to i64
%74 = sext i32 %9 to i64
br label %75
75: ; preds = %72, %75
%76 = phi i64 [ %73, %72 ], [ %160, %75 ]
%77 = trunc i64 %76 to i32
%78 = getelementptr inbounds i8, i8* %7, i64 %76
%79 = load i8, i8* %78
%80 = sext i8 %79 to i32
%81 = shl nsw i32 %80, 2
%82 = sext i32 %81 to i64
%83 = getelementptr inbounds double, double* %5, i64 %82
%84 = shl nsw i32 %77, 4
%85 = sext i32 %84 to i64
%86 = getelementptr inbounds double, double* %1, i64 %85
%87 = load double, double* %83
%88 = load double, double* %86
%89 = fmul double %87, %88
%90 = getelementptr inbounds double, double* %83, i64 1
%91 = load double, double* %90
%92 = getelementptr inbounds double, double* %86, i64 1
%93 = load double, double* %92
%94 = fmul double %91, %93
%95 = tail call double @llvm.fmuladd.f64(double %94, double %20, double %89)
%96 = getelementptr inbounds double, double* %83, i64 2
%97 = load double, double* %96
%98 = getelementptr inbounds double, double* %86, i64 2
%99 = load double, double* %98
%100 = fmul double %97, %99
%101 = tail call double @llvm.fmuladd.f64(double %100, double %24, double %95)
%102 = getelementptr inbounds double, double* %83, i64 3
%103 = load double, double* %102
%104 = getelementptr inbounds double, double* %86, i64 3
%105 = load double, double* %104
%106 = fmul double %103, %105
%107 = tail call double @llvm.fmuladd.f64(double %106, double %28, double %101)
%108 = getelementptr inbounds double, double* %86, i64 4
%109 = load double, double* %108
%110 = tail call double @llvm.fmuladd.f64(double %87, double %109, double %107)
%111 = getelementptr inbounds double, double* %86, i64 5
%112 = load double, double* %111
%113 = fmul double %91, %112
%114 = tail call double @llvm.fmuladd.f64(double %113, double %34, double %110)
%115 = getelementptr inbounds double, double* %86, i64 6
%116 = load double, double* %115
%117 = fmul double %97, %116
%118 = tail call double @llvm.fmuladd.f64(double %117, double %38, double %114)
%119 = getelementptr inbounds double, double* %86, i64 7
%120 = load double, double* %119
%121 = fmul double %103, %120
%122 = tail call double @llvm.fmuladd.f64(double %121, double %42, double %118)
%123 = getelementptr inbounds double, double* %86, i64 8
%124 = load double, double* %123
%125 = tail call double @llvm.fmuladd.f64(double %87, double %124, double %122)
%126 = getelementptr inbounds double, double* %86, i64 9
%127 = load double, double* %126
%128 = fmul double %91, %127
%129 = tail call double @llvm.fmuladd.f64(double %128, double %48, double %125)
%130 = getelementptr inbounds double, double* %86, i64 10
%131 = load double, double* %130
%132 = fmul double %97, %131
%133 = tail call double @llvm.fmuladd.f64(double %132, double %52, double %129)
%134 = getelementptr inbounds double, double* %86, i64 11
%135 = load double, double* %134
%136 = fmul double %103, %135
%137 = tail call double @llvm.fmuladd.f64(double %136, double %56, double %133)
%138 = getelementptr inbounds double, double* %86, i64 12
%139 = load double, double* %138
%140 = tail call double @llvm.fmuladd.f64(double %87, double %139, double %137)
%141 = getelementptr inbounds double, double* %86, i64 13
%142 = load double, double* %141
%143 = fmul double %91, %142
%144 = tail call double @llvm.fmuladd.f64(double %143, double %62, double %140)
%145 = getelementptr inbounds double, double* %86, i64 14
%146 = load double, double* %145
%147 = fmul double %97, %146
%148 = tail call double @llvm.fmuladd.f64(double %147, double %66, double %144)
%149 = getelementptr inbounds double, double* %86, i64 15
%150 = load double, double* %149
%151 = fmul double %103, %150
%152 = tail call double @llvm.fmuladd.f64(double %151, double %70, double %148)
%153 = fmul double %152, 2.500000e-01
%154 = tail call double @log(double %153)
%155 = getelementptr inbounds i32, i32* %0, i64 %76
%156 = load i32, i32* %155
%157 = sitofp i32 %156 to double
%158 = tail call double @llvm.fmuladd.f64(double %157, double 0xC0662E42FEFA39EF, double %154)
%159 = getelementptr inbounds double, double* %2, i64 %76
store double %158, double* %159
%160 = add nsw i64 %76, 1
%161 = icmp eq i64 %160, %74
br i1 %161, label %162, label %75
162: ; preds = %75, %10
ret void
}