#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 acos(double);
double cos(double);
int fabs(double);
double pow(double, double);
int sqrt(double);
void ch_evals3(double H[3][3], double *eval1, double *eval2, double *eval3) {
  double mat[3][3] = {{0.0}};
  double a1, a2, a3;
  double q, r;
  double q3, r2;
  double theta;
  double root1, root2, root3;
  double tol = 1.0e-6;
  double xmax;
  int i, j;
  double determinant();
  xmax = 0.0;
  for (i = 0; i < 3; i++) {
    for (j = i; j < 3; j++) {
      if (fabs(H[i][j]) > xmax) {
        xmax = fabs(H[i][j]);
      }
    }
  }
  if (xmax != 0) {
    for (i = 0; i < 3; i++) {
      for (j = 0; j < 3; j++) {
        mat[i][j] = H[i][j] / xmax;
      }
    }
  }
  a1 = -(mat[0][0] + mat[1][1] + mat[2][2]);
  a2 = (mat[0][0] * mat[1][1] - mat[0][1] * mat[1][0]) +
       (mat[0][0] * mat[2][2] - mat[0][2] * mat[2][0]) +
       (mat[1][1] * mat[2][2] - mat[1][2] * mat[2][1]);
  a3 = -determinant(mat, 3);
  if (a3 == 0) {
    root1 = 0;
    q = -.5 * (a1 + ((a1) < 0 ? -1 : 1) * sqrt(a1 * a1 - 4 * a2));
    root2 = q;
    root3 = a2 / q;
  } else {
    q = (a1 * a1 - 3 * a2) / 9;
    r = (2 * a1 * a1 * a1 - 9 * a1 * a2 + 27 * a3) / 54;
    q3 = q * q * q;
    r2 = r * r;
    if ((q3 < r2) && fabs(q3 - r2) < tol * (fabs(q3) + fabs(r2))) {
      q3 = r2;
    }
    if (q3 >= r2) {
      if (r == 0) {
        theta = 1.570796326794896;
      } else {
        q3 = sqrt(q3);
        if (q3 < fabs(r)) {
          q3 = fabs(r);
        }
        theta = acos(r / q3);
      }
      q = -2 * sqrt(q);
      root1 = q * cos(theta / 3) - a1 / 3;
      root2 = q * cos((theta + 6.283185307179586) / 3) - a1 / 3;
      root3 = q * cos((theta + 2 * 6.283185307179586) / 3) - a1 / 3;
    } else {
      theta = sqrt(r2 - q3) + fabs(r);
      theta = pow(theta, 1.0 / 3.0);
      root1 = root2 = root3 =
          -((r) < 0 ? -1 : 1) * (theta + q / theta) - a1 / 3;
    }
  }
  root1 *= xmax;
  root2 *= xmax;
  root3 *= xmax;
  *eval1 = ((root1) < (root2) ? (root1) : (root2));
  *eval1 = ((*eval1) < (root3) ? (*eval1) : (root3));
  *eval3 = ((root1) > (root2) ? (root1) : (root2));
  *eval3 = ((*eval3) > (root3) ? (*eval3) : (root3));
  if (root1 != *eval1 && root1 != *eval3) {
    *eval2 = root1;
  } else if (root2 != *eval1 && root2 != *eval3) {
    *eval2 = root2;
  } else {
    *eval2 = root3;
  }
}


x86 assembly (clang, -O0):
<ch_evals3>:
push   %rbp
mov    %rsp,%rbp
sub    $0x150,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
lea    -0x70(%rbp),%rdi
xor    %esi,%esi
mov    $0x48,%edx
call   1040 <memset@plt>
movsd  0xe5d(%rip),%xmm0
movsd  %xmm0,-0xd0(%rbp)
ff
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xd8(%rbp)
ff
movl   $0x0,-0xdc(%rbp)
cmpl   $0x3,-0xdc(%rbp)
jge    127c <ch_evals3+0x10c>
mov    -0xdc(%rbp),%eax
mov    %eax,-0xe0(%rbp)
cmpl   $0x3,-0xe0(%rbp)
jge    1263 <ch_evals3+0xf3>
mov    -0x8(%rbp),%rax
movslq -0xdc(%rbp),%rcx
imul   $0x18,%rcx,%rcx
add    %rcx,%rax
movslq -0xe0(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
call   1050 <fabs@plt>
cvtsi2sd %eax,%xmm0
ucomisd -0xd8(%rbp),%xmm0
ff
jbe    124a <ch_evals3+0xda>
mov    -0x8(%rbp),%rax
movslq -0xdc(%rbp),%rcx
imul   $0x18,%rcx,%rcx
add    %rcx,%rax
movslq -0xe0(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
call   1050 <fabs@plt>
cvtsi2sd %eax,%xmm0
movsd  %xmm0,-0xd8(%rbp)
ff
jmp    124f <ch_evals3+0xdf>
mov    -0xe0(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xe0(%rbp)
jmp    11d9 <ch_evals3+0x69>
jmp    1268 <ch_evals3+0xf8>
mov    -0xdc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xdc(%rbp)
jmp    11c0 <ch_evals3+0x50>
movsd  -0xd8(%rbp),%xmm0
ff
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jne    129c <ch_evals3+0x12c>
jp     129c <ch_evals3+0x12c>
jmp    1340 <ch_evals3+0x1d0>
movl   $0x0,-0xdc(%rbp)
cmpl   $0x3,-0xdc(%rbp)
jge    133b <ch_evals3+0x1cb>
movl   $0x0,-0xe0(%rbp)
cmpl   $0x3,-0xe0(%rbp)
jge    1322 <ch_evals3+0x1b2>
mov    -0x8(%rbp),%rax
movslq -0xdc(%rbp),%rcx
imul   $0x18,%rcx,%rcx
add    %rcx,%rax
movslq -0xe0(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
divsd  -0xd8(%rbp),%xmm0
ff
movslq -0xdc(%rbp),%rcx
lea    -0x70(%rbp),%rax
imul   $0x18,%rcx,%rcx
add    %rcx,%rax
movslq -0xe0(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0xe0(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xe0(%rbp)
jmp    12bd <ch_evals3+0x14d>
jmp    1327 <ch_evals3+0x1b7>
mov    -0xdc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xdc(%rbp)
jmp    12a6 <ch_evals3+0x136>
jmp    1340 <ch_evals3+0x1d0>
movsd  -0x70(%rbp),%xmm0
addsd  -0x50(%rbp),%xmm0
addsd  -0x30(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  %xmm0,-0x78(%rbp)
movsd  -0x70(%rbp),%xmm0
movsd  -0x50(%rbp),%xmm2
movsd  -0x68(%rbp),%xmm1
mulsd  -0x58(%rbp),%xmm1
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  -0x70(%rbp),%xmm1
movsd  -0x30(%rbp),%xmm3
movsd  -0x60(%rbp),%xmm2
mulsd  -0x40(%rbp),%xmm2
movq   %xmm2,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm2
mulsd  %xmm3,%xmm1
addsd  %xmm2,%xmm1
addsd  %xmm1,%xmm0
movsd  -0x50(%rbp),%xmm1
movsd  -0x30(%rbp),%xmm3
movsd  -0x48(%rbp),%xmm2
mulsd  -0x38(%rbp),%xmm2
movq   %xmm2,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm2
mulsd  %xmm3,%xmm1
addsd  %xmm2,%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x80(%rbp)
lea    -0x70(%rbp),%rdi
mov    $0x3,%esi
mov    $0x0,%al
call   1070 <determinant@plt>
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  %xmm0,-0x88(%rbp)
ff
movsd  -0x88(%rbp),%xmm0
ff
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jne    1526 <ch_evals3+0x3b6>
jp     1526 <ch_evals3+0x3b6>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xb8(%rbp)
ff
movsd  -0x78(%rbp),%xmm0
movsd  %xmm0,-0xf0(%rbp)
ff
movsd  -0x78(%rbp),%xmm1
xorps  %xmm0,%xmm0
mov    $0x1,%eax
mov    $0xffffffff,%ecx
ucomisd %xmm1,%xmm0
cmova  %ecx,%eax
mov    %eax,-0xe4(%rbp)
movsd  -0x78(%rbp),%xmm0
movsd  -0x78(%rbp),%xmm2
movsd  0xbb4(%rip),%xmm1
mulsd  -0x80(%rbp),%xmm1
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
call   1090 <sqrt@plt>
movsd  -0xf0(%rbp),%xmm1
ff
mov    %eax,%ecx
mov    -0xe4(%rbp),%eax
imul   %ecx,%eax
cvtsi2sd %eax,%xmm0
addsd  %xmm0,%xmm1
movsd  0xb60(%rip),%xmm0
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x90(%rbp)
ff
movsd  -0x90(%rbp),%xmm0
ff
movsd  %xmm0,-0xc0(%rbp)
ff
movsd  -0x80(%rbp),%xmm0
divsd  -0x90(%rbp),%xmm0
ff
movsd  %xmm0,-0xc8(%rbp)
ff
jmp    19eb <ch_evals3+0x87b>
movsd  -0x78(%rbp),%xmm0
movsd  -0x78(%rbp),%xmm2
movsd  0xaf0(%rip),%xmm1
mulsd  -0x80(%rbp),%xmm1
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  0xab4(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x90(%rbp)
ff
movsd  0xaa8(%rip),%xmm1
mulsd  -0x78(%rbp),%xmm1
mulsd  -0x78(%rbp),%xmm1
movsd  -0x78(%rbp),%xmm2
movsd  0xa89(%rip),%xmm0
mulsd  -0x78(%rbp),%xmm0
mulsd  -0x80(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
movsd  -0x88(%rbp),%xmm0
ff
movsd  0xa48(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  0xa30(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x98(%rbp)
ff
movsd  -0x90(%rbp),%xmm0
ff
mulsd  -0x90(%rbp),%xmm0
ff
mulsd  -0x90(%rbp),%xmm0
ff
movsd  %xmm0,-0xa0(%rbp)
ff
movsd  -0x98(%rbp),%xmm0
ff
mulsd  -0x98(%rbp),%xmm0
ff
movsd  %xmm0,-0xa8(%rbp)
ff
movsd  -0xa0(%rbp),%xmm1
ff
movsd  -0xa8(%rbp),%xmm0
ff
ucomisd %xmm1,%xmm0
jbe    16c3 <ch_evals3+0x553>
movsd  -0xa0(%rbp),%xmm0
ff
subsd  -0xa8(%rbp),%xmm0
ff
call   1050 <fabs@plt>
cvtsi2sd %eax,%xmm0
movsd  %xmm0,-0x100(%rbp)
ff
movsd  -0xd0(%rbp),%xmm0
ff
movsd  %xmm0,-0x108(%rbp)
ff
movsd  -0xa0(%rbp),%xmm0
ff
call   1050 <fabs@plt>
mov    %eax,-0xf4(%rbp)
movsd  -0xa8(%rbp),%xmm0
ff
call   1050 <fabs@plt>
movsd  -0x108(%rbp),%xmm0
ff
movsd  -0x100(%rbp),%xmm1
ff
mov    %eax,%ecx
mov    -0xf4(%rbp),%eax
add    %ecx,%eax
cvtsi2sd %eax,%xmm2
mulsd  %xmm2,%xmm0
ucomisd %xmm1,%xmm0
jbe    16c3 <ch_evals3+0x553>
movsd  -0xa8(%rbp),%xmm0
ff
movsd  %xmm0,-0xa0(%rbp)
ff
movsd  -0xa0(%rbp),%xmm0
ff
ucomisd -0xa8(%rbp),%xmm0
ff
jb     1903 <ch_evals3+0x793>
movsd  -0x98(%rbp),%xmm0
ff
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jne    1709 <ch_evals3+0x599>
jp     1709 <ch_evals3+0x599>
movsd  0x93c(%rip),%xmm0
movsd  %xmm0,-0xb0(%rbp)
ff
jmp    178b <ch_evals3+0x61b>
movsd  -0xa0(%rbp),%xmm0
ff
call   1090 <sqrt@plt>
cvtsi2sd %eax,%xmm0
movsd  %xmm0,-0xa0(%rbp)
ff
movsd  -0xa0(%rbp),%xmm0
ff
movsd  %xmm0,-0x110(%rbp)
ff
movsd  -0x98(%rbp),%xmm0
ff
call   1050 <fabs@plt>
movsd  -0x110(%rbp),%xmm1
ff
cvtsi2sd %eax,%xmm0
ucomisd %xmm1,%xmm0
jbe    176e <ch_evals3+0x5fe>
movsd  -0x98(%rbp),%xmm0
ff
call   1050 <fabs@plt>
cvtsi2sd %eax,%xmm0
movsd  %xmm0,-0xa0(%rbp)
ff
movsd  -0x98(%rbp),%xmm0
ff
divsd  -0xa0(%rbp),%xmm0
ff
call   1030 <acos@plt>
movsd  %xmm0,-0xb0(%rbp)
ff
movsd  -0x90(%rbp),%xmm0
ff
call   1090 <sqrt@plt>
imul   $0xfffffffe,%eax,%eax
cvtsi2sd %eax,%xmm0
movsd  %xmm0,-0x90(%rbp)
ff
movsd  -0x90(%rbp),%xmm0
ff
movsd  %xmm0,-0x128(%rbp)
ff
movsd  -0xb0(%rbp),%xmm0
ff
movsd  0x85e(%rip),%xmm1
divsd  %xmm1,%xmm0
call   1060 <cos@plt>
movaps %xmm0,%xmm2
movsd  -0x128(%rbp),%xmm0
ff
movsd  -0x78(%rbp),%xmm1
movsd  0x83d(%rip),%xmm3
divsd  %xmm3,%xmm1
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xb8(%rbp)
ff
movsd  -0x90(%rbp),%xmm0
ff
movsd  %xmm0,-0x120(%rbp)
ff
movsd  0x81a(%rip),%xmm0
addsd  -0xb0(%rbp),%xmm0
ff
movsd  0x7ea(%rip),%xmm1
divsd  %xmm1,%xmm0
call   1060 <cos@plt>
movaps %xmm0,%xmm2
movsd  -0x120(%rbp),%xmm0
ff
movsd  -0x78(%rbp),%xmm1
movsd  0x7c9(%rip),%xmm3
divsd  %xmm3,%xmm1
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xc0(%rbp)
ff
movsd  -0x90(%rbp),%xmm0
ff
movsd  %xmm0,-0x118(%rbp)
ff
movsd  0x79e(%rip),%xmm0
addsd  -0xb0(%rbp),%xmm0
ff
movsd  0x776(%rip),%xmm1
divsd  %xmm1,%xmm0
call   1060 <cos@plt>
movaps %xmm0,%xmm2
movsd  -0x118(%rbp),%xmm0
ff
movsd  -0x78(%rbp),%xmm1
movsd  0x755(%rip),%xmm3
divsd  %xmm3,%xmm1
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xc8(%rbp)
ff
jmp    19e6 <ch_evals3+0x876>
movsd  -0xa8(%rbp),%xmm0
ff
subsd  -0xa0(%rbp),%xmm0
ff
call   1090 <sqrt@plt>
mov    %eax,-0x12c(%rbp)
movsd  -0x98(%rbp),%xmm0
ff
call   1050 <fabs@plt>
mov    %eax,%ecx
mov    -0x12c(%rbp),%eax
add    %ecx,%eax
cvtsi2sd %eax,%xmm0
movsd  %xmm0,-0xb0(%rbp)
ff
movsd  -0xb0(%rbp),%xmm0
ff
movsd  0x6df(%rip),%xmm1
call   1080 <pow@plt>
movsd  %xmm0,-0xb0(%rbp)
ff
movsd  -0x98(%rbp),%xmm1
ff
xorps  %xmm0,%xmm0
mov    $0x1,%ecx
mov    $0xffffffff,%eax
ucomisd %xmm1,%xmm0
cmova  %eax,%ecx
xor    %eax,%eax
sub    %ecx,%eax
cvtsi2sd %eax,%xmm0
movsd  -0xb0(%rbp),%xmm2
ff
movsd  -0x90(%rbp),%xmm1
ff
divsd  -0xb0(%rbp),%xmm1
ff
addsd  %xmm1,%xmm2
movsd  -0x78(%rbp),%xmm1
movsd  0x67d(%rip),%xmm3
divsd  %xmm3,%xmm1
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xc8(%rbp)
ff
movsd  %xmm0,-0xc0(%rbp)
ff
movsd  %xmm0,-0xb8(%rbp)
ff
jmp    19eb <ch_evals3+0x87b>
movsd  -0xd8(%rbp),%xmm0
ff
mulsd  -0xb8(%rbp),%xmm0
ff
movsd  %xmm0,-0xb8(%rbp)
ff
movsd  -0xd8(%rbp),%xmm0
ff
mulsd  -0xc0(%rbp),%xmm0
ff
movsd  %xmm0,-0xc0(%rbp)
ff
movsd  -0xd8(%rbp),%xmm0
ff
mulsd  -0xc8(%rbp),%xmm0
ff
movsd  %xmm0,-0xc8(%rbp)
ff
movsd  -0xb8(%rbp),%xmm1
ff
movsd  -0xc0(%rbp),%xmm0
ff
ucomisd %xmm1,%xmm0
jbe    1a62 <ch_evals3+0x8f2>
movsd  -0xb8(%rbp),%xmm0
ff
movsd  %xmm0,-0x138(%rbp)
ff
jmp    1a72 <ch_evals3+0x902>
movsd  -0xc0(%rbp),%xmm0
ff
movsd  %xmm0,-0x138(%rbp)
ff
movsd  -0x138(%rbp),%xmm0
ff
mov    -0x10(%rbp),%rax
movsd  %xmm0,(%rax)
mov    -0x10(%rbp),%rax
movsd  (%rax),%xmm1
movsd  -0xc8(%rbp),%xmm0
ff
ucomisd %xmm1,%xmm0
jbe    1ab1 <ch_evals3+0x941>
mov    -0x10(%rbp),%rax
movsd  (%rax),%xmm0
movsd  %xmm0,-0x140(%rbp)
ff
jmp    1ac1 <ch_evals3+0x951>
movsd  -0xc8(%rbp),%xmm0
ff
movsd  %xmm0,-0x140(%rbp)
ff
movsd  -0x140(%rbp),%xmm0
ff
mov    -0x10(%rbp),%rax
movsd  %xmm0,(%rax)
movsd  -0xb8(%rbp),%xmm0
ff
ucomisd -0xc0(%rbp),%xmm0
ff
jbe    1afc <ch_evals3+0x98c>
movsd  -0xb8(%rbp),%xmm0
ff
movsd  %xmm0,-0x148(%rbp)
ff
jmp    1b0c <ch_evals3+0x99c>
movsd  -0xc0(%rbp),%xmm0
ff
movsd  %xmm0,-0x148(%rbp)
ff
movsd  -0x148(%rbp),%xmm0
ff
mov    -0x20(%rbp),%rax
movsd  %xmm0,(%rax)
mov    -0x20(%rbp),%rax
movsd  (%rax),%xmm0
ucomisd -0xc8(%rbp),%xmm0
ff
jbe    1b47 <ch_evals3+0x9d7>
mov    -0x20(%rbp),%rax
movsd  (%rax),%xmm0
movsd  %xmm0,-0x150(%rbp)
ff
jmp    1b57 <ch_evals3+0x9e7>
movsd  -0xc8(%rbp),%xmm0
ff
movsd  %xmm0,-0x150(%rbp)
ff
movsd  -0x150(%rbp),%xmm0
ff
mov    -0x20(%rbp),%rax
movsd  %xmm0,(%rax)
movsd  -0xb8(%rbp),%xmm0
ff
mov    -0x10(%rbp),%rax
ucomisd (%rax),%xmm0
jne    1b88 <ch_evals3+0xa18>
jp     1b88 <ch_evals3+0xa18>
jmp    1bbe <ch_evals3+0xa4e>
movsd  -0xb8(%rbp),%xmm0
ff
mov    -0x20(%rbp),%rax
ucomisd (%rax),%xmm0
jne    1ba9 <ch_evals3+0xa39>
jp     1ba9 <ch_evals3+0xa39>
jmp    1bbe <ch_evals3+0xa4e>
movsd  -0xb8(%rbp),%xmm0
ff
mov    -0x18(%rbp),%rax
movsd  %xmm0,(%rax)
jmp    1c2a <ch_evals3+0xaba>
movsd  -0xc0(%rbp),%xmm0
ff
mov    -0x10(%rbp),%rax
ucomisd (%rax),%xmm0
jne    1bdf <ch_evals3+0xa6f>
jp     1bdf <ch_evals3+0xa6f>
jmp    1c15 <ch_evals3+0xaa5>
movsd  -0xc0(%rbp),%xmm0
ff
mov    -0x20(%rbp),%rax
ucomisd (%rax),%xmm0
jne    1c00 <ch_evals3+0xa90>
jp     1c00 <ch_evals3+0xa90>
jmp    1c15 <ch_evals3+0xaa5>
movsd  -0xc0(%rbp),%xmm0
ff
mov    -0x18(%rbp),%rax
movsd  %xmm0,(%rax)
jmp    1c25 <ch_evals3+0xab5>
movsd  -0xc8(%rbp),%xmm0
ff
mov    -0x18(%rbp),%rax
movsd  %xmm0,(%rax)
jmp    1c2a <ch_evals3+0xaba>
add    $0x150,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ch_evals3>:
push   %rbp
push   %r15
push   %r14
push   %r12
push   %rbx
sub    $0xc0,%rsp
mov    %rcx,%r15
mov    %rdx,%r14
mov    %rsi,%r12
mov    %rdi,%rbx
xorps  %xmm0,%xmm0
movaps %xmm0,0xa0(%rsp)
movaps %xmm0,0x90(%rsp)
movaps %xmm0,0x80(%rsp)
movaps %xmm0,0x70(%rsp)
movq   $0x0,0xb0(%rsp)
movsd  (%rdi),%xmm0
call   1040 <fabs@plt>
test   %eax,%eax
jle    11c6 <ch_evals3+0x66>
movsd  (%rbx),%xmm0
call   1040 <fabs@plt>
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
jmp    11ca <ch_evals3+0x6a>
xorpd  %xmm0,%xmm0
movapd %xmm0,(%rsp)
movsd  0x8(%rbx),%xmm0
call   1040 <fabs@plt>
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
movapd (%rsp),%xmm1
ucomisd %xmm1,%xmm0
movapd %xmm1,%xmm0
jbe    1200 <ch_evals3+0xa0>
movsd  0x8(%rbx),%xmm0
call   1040 <fabs@plt>
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
movapd %xmm0,(%rsp)
movsd  0x10(%rbx),%xmm0
call   1040 <fabs@plt>
movapd (%rsp),%xmm1
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
ucomisd %xmm1,%xmm0
jbe    1232 <ch_evals3+0xd2>
movsd  0x10(%rbx),%xmm0
call   1040 <fabs@plt>
xorps  %xmm1,%xmm1
cvtsi2sd %eax,%xmm1
movapd %xmm1,(%rsp)
movsd  0x20(%rbx),%xmm0
call   1040 <fabs@plt>
movapd (%rsp),%xmm1
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
ucomisd %xmm1,%xmm0
jbe    1264 <ch_evals3+0x104>
movsd  0x20(%rbx),%xmm0
call   1040 <fabs@plt>
xorps  %xmm1,%xmm1
cvtsi2sd %eax,%xmm1
movapd %xmm1,(%rsp)
movsd  0x28(%rbx),%xmm0
call   1040 <fabs@plt>
movapd (%rsp),%xmm1
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
ucomisd %xmm1,%xmm0
jbe    1296 <ch_evals3+0x136>
movsd  0x28(%rbx),%xmm0
call   1040 <fabs@plt>
xorps  %xmm1,%xmm1
cvtsi2sd %eax,%xmm1
movapd %xmm1,(%rsp)
movsd  0x40(%rbx),%xmm0
call   1040 <fabs@plt>
movapd (%rsp),%xmm5
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
ucomisd %xmm5,%xmm0
jbe    12c8 <ch_evals3+0x168>
movsd  0x40(%rbx),%xmm0
call   1040 <fabs@plt>
xorps  %xmm5,%xmm5
cvtsi2sd %eax,%xmm5
xorpd  %xmm0,%xmm0
ucomisd %xmm0,%xmm5
movapd %xmm5,(%rsp)
jne    12d9 <ch_evals3+0x179>
jnp    1332 <ch_evals3+0x1d2>
movsd  (%rbx),%xmm0
divsd  %xmm5,%xmm0
movsd  %xmm0,0x70(%rsp)
movupd 0x8(%rbx),%xmm2
movupd 0x18(%rbx),%xmm4
movupd 0x28(%rbx),%xmm3
movupd 0x38(%rbx),%xmm1
unpcklpd %xmm5,%xmm5
divpd  %xmm5,%xmm1
divpd  %xmm5,%xmm3
divpd  %xmm5,%xmm4
divpd  %xmm5,%xmm2
movupd %xmm2,0x78(%rsp)
movupd %xmm4,0x88(%rsp)
movupd %xmm3,0x98(%rsp)
movupd %xmm1,0xa8(%rsp)
jmp    1346 <ch_evals3+0x1e6>
xorpd  %xmm2,%xmm2
xorpd  %xmm0,%xmm0
xorpd  %xmm4,%xmm4
xorpd  %xmm3,%xmm3
xorpd  %xmm1,%xmm1
movapd %xmm4,%xmm5
unpckhpd %xmm4,%xmm5
movapd %xmm0,%xmm6
addsd  %xmm5,%xmm6
movapd %xmm1,%xmm7
unpckhpd %xmm1,%xmm7
addsd  %xmm7,%xmm6
movapd %xmm6,0x40(%rsp)
mulsd  %xmm2,%xmm4
movapd %xmm0,%xmm6
mulsd  %xmm5,%xmm6
subsd  %xmm4,%xmm6
unpckhpd %xmm2,%xmm2
mulsd  %xmm3,%xmm1
unpckhpd %xmm3,%xmm3
mulsd  %xmm2,%xmm3
mulsd  %xmm7,%xmm0
subsd  %xmm3,%xmm0
addsd  %xmm6,%xmm0
mulsd  %xmm5,%xmm7
subsd  %xmm1,%xmm7
addsd  %xmm0,%xmm7
movapd %xmm7,0x20(%rsp)
lea    0x70(%rsp),%rdi
mov    $0x3,%esi
xor    %eax,%eax
call   1060 <determinant@plt>
ucomisd 0xcd9(%rip),%xmm0
jne    141b <ch_evals3+0x2bb>
jp     141b <ch_evals3+0x2bb>
movsd  0xcbd(%rip),%xmm1
mulsd  0x20(%rsp),%xmm1
movapd 0x40(%rsp),%xmm0
mulsd  %xmm0,%xmm0
addsd  %xmm1,%xmm0
call   1080 <sqrt@plt>
movapd 0x20(%rsp),%xmm0
mov    %eax,%ecx
neg    %ecx
xorpd  %xmm4,%xmm4
movapd 0x40(%rsp),%xmm1
ucomisd %xmm4,%xmm1
cmovbe %eax,%ecx
xorps  %xmm6,%xmm6
cvtsi2sd %ecx,%xmm6
subsd  %xmm1,%xmm6
mulsd  0xc7e(%rip),%xmm6
divsd  %xmm6,%xmm0
jmp    16d9 <ch_evals3+0x579>
movapd 0xbdd(%rip),%xmm1
movapd 0x40(%rsp),%xmm6
xorpd  %xmm6,%xmm1
xorpd  0xbcb(%rip),%xmm0
movsd  0xc03(%rip),%xmm2
movapd 0x20(%rsp),%xmm5
mulsd  %xmm5,%xmm2
movsd  0xbf9(%rip),%xmm3
mulsd  %xmm6,%xmm3
mulsd  %xmm1,%xmm3
movsd  0xbf1(%rip),%xmm4
mulsd  %xmm6,%xmm4
mulsd  %xmm5,%xmm4
mulsd  %xmm1,%xmm3
addsd  %xmm4,%xmm3
unpcklpd %xmm3,%xmm2
movapd %xmm6,%xmm1
unpcklpd %xmm0,%xmm1
movapd 0xb8d(%rip),%xmm3
movsd  %xmm6,%xmm3
mulpd  %xmm1,%xmm3
addpd  %xmm2,%xmm3
divpd  0xb89(%rip),%xmm3
movapd %xmm3,%xmm0
unpckhpd %xmm3,%xmm0
movapd %xmm3,%xmm2
mulsd  %xmm3,%xmm2
mulpd  %xmm3,%xmm2
movapd %xmm2,%xmm1
unpckhpd %xmm2,%xmm1
ucomisd %xmm2,%xmm1
movapd %xmm3,0x20(%rsp)
movapd %xmm0,0x10(%rsp)
jbe    152a <ch_evals3+0x3ca>
movapd %xmm2,%xmm0
subsd  %xmm1,%xmm0
movapd %xmm2,0x30(%rsp)
movapd %xmm1,0x50(%rsp)
call   1040 <fabs@plt>
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
movsd  %xmm0,0x68(%rsp)
movaps 0x30(%rsp),%xmm0
call   1040 <fabs@plt>
mov    %eax,%ebx
movaps 0x50(%rsp),%xmm0
call   1040 <fabs@plt>
movapd 0x50(%rsp),%xmm1
movapd 0x30(%rsp),%xmm2
add    %ebx,%eax
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
mulsd  0xb3a(%rip),%xmm0
ucomisd 0x68(%rsp),%xmm0
jbe    152a <ch_evals3+0x3ca>
movapd %xmm1,%xmm2
ucomisd %xmm1,%xmm2
jae    15a6 <ch_evals3+0x446>
subsd  %xmm2,%xmm1
movapd %xmm1,%xmm0
call   1080 <sqrt@plt>
mov    %eax,%ebp
xorpd  %xmm1,%xmm1
xor    %ebx,%ebx
movapd 0x10(%rsp),%xmm0
ucomisd %xmm0,%xmm1
seta   %bl
call   1040 <fabs@plt>
add    %ebp,%eax
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
movsd  0xb18(%rip),%xmm1
call   1070 <pow@plt>
movapd 0x20(%rsp),%xmm4
divsd  %xmm0,%xmm4
addsd  %xmm0,%xmm4
movapd 0x40(%rsp),%xmm0
divsd  0xadf(%rip),%xmm0
lea    0xaa0(%rip),%rax
mulsd  (%rax,%rbx,8),%xmm4
addsd  %xmm0,%xmm4
movapd %xmm4,%xmm6
movapd %xmm4,%xmm0
jmp    16d9 <ch_evals3+0x579>
xorpd  %xmm0,%xmm0
movapd 0x10(%rsp),%xmm1
ucomisd %xmm0,%xmm1
movaps 0x20(%rsp),%xmm0
jne    15cd <ch_evals3+0x46d>
jp     15cd <ch_evals3+0x46d>
movsd  0xa9b(%rip),%xmm1
movsd  %xmm1,0x10(%rsp)
jmp    162c <ch_evals3+0x4cc>
movapd %xmm2,%xmm0
call   1080 <sqrt@plt>
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
movsd  %xmm0,0x30(%rsp)
movaps 0x10(%rsp),%xmm0
call   1040 <fabs@plt>
movsd  0x30(%rsp),%xmm1
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
ucomisd %xmm1,%xmm0
jbe    1612 <ch_evals3+0x4b2>
movapd 0x10(%rsp),%xmm0
call   1040 <fabs@plt>
xorps  %xmm1,%xmm1
cvtsi2sd %eax,%xmm1
movapd 0x10(%rsp),%xmm0
divsd  %xmm1,%xmm0
call   1030 <acos@plt>
movsd  %xmm0,0x10(%rsp)
movaps 0x20(%rsp),%xmm0
call   1080 <sqrt@plt>
add    %eax,%eax
neg    %eax
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
movsd  %xmm0,0x30(%rsp)
movsd  0x10(%rsp),%xmm0
divsd  0xa18(%rip),%xmm0
call   1050 <cos@plt>
movapd 0x40(%rsp),%xmm2
movsd  0xa05(%rip),%xmm1
divsd  %xmm1,%xmm2
movapd %xmm2,0x40(%rsp)
mulsd  0x30(%rsp),%xmm0
addsd  %xmm2,%xmm0
movapd %xmm0,0x20(%rsp)
movsd  0x9eb(%rip),%xmm0
addsd  0x10(%rsp),%xmm0
divsd  %xmm1,%xmm0
call   1050 <cos@plt>
mulsd  0x30(%rsp),%xmm0
addsd  0x40(%rsp),%xmm0
movapd %xmm0,0x50(%rsp)
movsd  0x10(%rsp),%xmm0
addsd  0x9c4(%rip),%xmm0
divsd  0x9ac(%rip),%xmm0
call   1050 <cos@plt>
movapd 0x50(%rsp),%xmm6
movapd 0x20(%rsp),%xmm4
mulsd  0x30(%rsp),%xmm0
addsd  0x40(%rsp),%xmm0
movapd (%rsp),%xmm1
mulsd  %xmm1,%xmm4
mulsd  %xmm1,%xmm6
mulsd  %xmm1,%xmm0
movapd %xmm4,%xmm1
minsd  %xmm6,%xmm1
minsd  %xmm0,%xmm1
movsd  %xmm1,(%r12)
movapd %xmm4,%xmm5
maxsd  %xmm6,%xmm5
maxsd  %xmm0,%xmm5
movsd  %xmm5,(%r15)
movsd  (%r12),%xmm1
movapd %xmm6,%xmm2
cmpneqsd %xmm5,%xmm2
movapd %xmm2,%xmm3
andpd  %xmm6,%xmm3
andnpd %xmm0,%xmm2
orpd   %xmm3,%xmm2
cmpneqsd %xmm1,%xmm6
andpd  %xmm6,%xmm2
andnpd %xmm0,%xmm6
orpd   %xmm2,%xmm6
cmpneqsd %xmm4,%xmm1
cmpneqsd %xmm4,%xmm5
movapd %xmm5,%xmm2
andnpd %xmm6,%xmm2
andpd  %xmm4,%xmm5
orpd   %xmm2,%xmm5
andpd  %xmm1,%xmm5
andnpd %xmm6,%xmm1
orpd   %xmm1,%xmm5
movlpd %xmm5,(%r14)
add    $0xc0,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
define void @ch_evals3([3 x double]* %0, double* %1, double* %2, double* %3) {
%5 = alloca [3 x double]*
%6 = alloca double*
%7 = alloca double*
%8 = alloca double*
%9 = alloca [3 x [3 x double]]
%10 = alloca double
%11 = alloca double
%12 = alloca double
%13 = alloca double
%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 i32
%24 = alloca i32
store [3 x double]* %0, [3 x double]** %5
store double* %1, double** %6
store double* %2, double** %7
store double* %3, double** %8
%25 = bitcast [3 x [3 x double]]* %9 to i8*
store double 0x3EB0C6F7A0B5ED8D, double* %21
store double 0.000000e+00, double* %22
store i32 0, i32* %23
br label %26
26: ; preds = %63, %4
%27 = load i32, i32* %23
%28 = icmp slt i32 %27, 3
br i1 %28, label %29, label %66
29: ; preds = %26
%30 = load i32, i32* %23
store i32 %30, i32* %24
br label %31
31: ; preds = %59, %29
%32 = load i32, i32* %24
%33 = icmp slt i32 %32, 3
br i1 %33, label %34, label %62
34: ; preds = %31
%35 = load [3 x double]*, [3 x double]** %5
%36 = load i32, i32* %23
%37 = sext i32 %36 to i64
%38 = getelementptr inbounds [3 x double], [3 x double]* %35, i64 %37
%39 = load i32, i32* %24
%40 = sext i32 %39 to i64
%41 = getelementptr inbounds [3 x double], [3 x double]* %38, i64 0, i64 %40
%42 = load double, double* %41
%43 = call i32 @fabs(double %42)
%44 = sitofp i32 %43 to double
%45 = load double, double* %22
%46 = fcmp ogt double %44, %45
br i1 %46, label %47, label %58
47: ; preds = %34
%48 = load [3 x double]*, [3 x double]** %5
%49 = load i32, i32* %23
%50 = sext i32 %49 to i64
%51 = getelementptr inbounds [3 x double], [3 x double]* %48, i64 %50
%52 = load i32, i32* %24
%53 = sext i32 %52 to i64
%54 = getelementptr inbounds [3 x double], [3 x double]* %51, i64 0, i64 %53
%55 = load double, double* %54
%56 = call i32 @fabs(double %55)
%57 = sitofp i32 %56 to double
store double %57, double* %22
br label %58
58: ; preds = %47, %34
br label %59
59: ; preds = %58
%60 = load i32, i32* %24
%61 = add nsw i32 %60, 1
store i32 %61, i32* %24
br label %31
62: ; preds = %31
br label %63
63: ; preds = %62
%64 = load i32, i32* %23
%65 = add nsw i32 %64, 1
store i32 %65, i32* %23
br label %26
66: ; preds = %26
%67 = load double, double* %22
%68 = fcmp une double %67, 0.000000e+00
br i1 %68, label %69, label %102
69: ; preds = %66
store i32 0, i32* %23
br label %70
70: ; preds = %98, %69
%71 = load i32, i32* %23
%72 = icmp slt i32 %71, 3
br i1 %72, label %73, label %101
73: ; preds = %70
store i32 0, i32* %24
br label %74
74: ; preds = %94, %73
%75 = load i32, i32* %24
%76 = icmp slt i32 %75, 3
br i1 %76, label %77, label %97
77: ; preds = %74
%78 = load [3 x double]*, [3 x double]** %5
%79 = load i32, i32* %23
%80 = sext i32 %79 to i64
%81 = getelementptr inbounds [3 x double], [3 x double]* %78, i64 %80
%82 = load i32, i32* %24
%83 = sext i32 %82 to i64
%84 = getelementptr inbounds [3 x double], [3 x double]* %81, i64 0, i64 %83
%85 = load double, double* %84
%86 = load double, double* %22
%87 = fdiv double %85, %86
%88 = load i32, i32* %23
%89 = sext i32 %88 to i64
%90 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %9, i64 0, i64 %89
%91 = load i32, i32* %24
%92 = sext i32 %91 to i64
%93 = getelementptr inbounds [3 x double], [3 x double]* %90, i64 0, i64 %92
store double %87, double* %93
br label %94
94: ; preds = %77
%95 = load i32, i32* %24
%96 = add nsw i32 %95, 1
store i32 %96, i32* %24
br label %74
97: ; preds = %74
br label %98
98: ; preds = %97
%99 = load i32, i32* %23
%100 = add nsw i32 %99, 1
store i32 %100, i32* %23
br label %70
101: ; preds = %70
br label %102
102: ; preds = %101, %66
%103 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %9, i64 0, i64 0
%104 = getelementptr inbounds [3 x double], [3 x double]* %103, i64 0, i64 0
%105 = load double, double* %104
%106 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %9, i64 0, i64 1
%107 = getelementptr inbounds [3 x double], [3 x double]* %106, i64 0, i64 1
%108 = load double, double* %107
%109 = fadd double %105, %108
%110 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %9, i64 0, i64 2
%111 = getelementptr inbounds [3 x double], [3 x double]* %110, i64 0, i64 2
%112 = load double, double* %111
%113 = fadd double %109, %112
%114 = fneg double %113
store double %114, double* %10
%115 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %9, i64 0, i64 0
%116 = getelementptr inbounds [3 x double], [3 x double]* %115, i64 0, i64 0
%117 = load double, double* %116
%118 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %9, i64 0, i64 1
%119 = getelementptr inbounds [3 x double], [3 x double]* %118, i64 0, i64 1
%120 = load double, double* %119
%121 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %9, i64 0, i64 0
%122 = getelementptr inbounds [3 x double], [3 x double]* %121, i64 0, i64 1
%123 = load double, double* %122
%124 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %9, i64 0, i64 1
%125 = getelementptr inbounds [3 x double], [3 x double]* %124, i64 0, i64 0
%126 = load double, double* %125
%127 = fmul double %123, %126
%128 = fneg double %127
%129 = call double @llvm.fmuladd.f64(double %117, double %120, double %128)
%130 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %9, i64 0, i64 0
%131 = getelementptr inbounds [3 x double], [3 x double]* %130, i64 0, i64 0
%132 = load double, double* %131
%133 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %9, i64 0, i64 2
%134 = getelementptr inbounds [3 x double], [3 x double]* %133, i64 0, i64 2
%135 = load double, double* %134
%136 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %9, i64 0, i64 0
%137 = getelementptr inbounds [3 x double], [3 x double]* %136, i64 0, i64 2
%138 = load double, double* %137
%139 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %9, i64 0, i64 2
%140 = getelementptr inbounds [3 x double], [3 x double]* %139, i64 0, i64 0
%141 = load double, double* %140
%142 = fmul double %138, %141
%143 = fneg double %142
%144 = call double @llvm.fmuladd.f64(double %132, double %135, double %143)
%145 = fadd double %129, %144
%146 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %9, i64 0, i64 1
%147 = getelementptr inbounds [3 x double], [3 x double]* %146, i64 0, i64 1
%148 = load double, double* %147
%149 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %9, i64 0, i64 2
%150 = getelementptr inbounds [3 x double], [3 x double]* %149, i64 0, i64 2
%151 = load double, double* %150
%152 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %9, i64 0, i64 1
%153 = getelementptr inbounds [3 x double], [3 x double]* %152, i64 0, i64 2
%154 = load double, double* %153
%155 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %9, i64 0, i64 2
%156 = getelementptr inbounds [3 x double], [3 x double]* %155, i64 0, i64 1
%157 = load double, double* %156
%158 = fmul double %154, %157
%159 = fneg double %158
%160 = call double @llvm.fmuladd.f64(double %148, double %151, double %159)
%161 = fadd double %145, %160
store double %161, double* %11
%162 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %9, i64 0, i64 0
%163 = call double ([3 x double]*, i32, ...) bitcast (double (...)* @determinant to double ([3 x double]*, i32, ...)*)([3 x double]* %162, i32 3)
%164 = fneg double %163
store double %164, double* %12
%165 = load double, double* %12
%166 = fcmp oeq double %165, 0.000000e+00
br i1 %166, label %167, label %188
167: ; preds = %102
store double 0.000000e+00, double* %18
%168 = load double, double* %10
%169 = load double, double* %10
%170 = fcmp olt double %169, 0.000000e+00
%171 = zext i1 %170 to i64
%172 = select i1 %170, i32 -1, i32 1
%173 = load double, double* %10
%174 = load double, double* %10
%175 = load double, double* %11
%176 = fmul double 4.000000e+00, %175
%177 = fneg double %176
%178 = call double @llvm.fmuladd.f64(double %173, double %174, double %177)
%179 = call i32 @sqrt(double %178)
%180 = mul nsw i32 %172, %179
%181 = sitofp i32 %180 to double
%182 = fadd double %168, %181
%183 = fmul double -5.000000e-01, %182
store double %183, double* %13
%184 = load double, double* %13
store double %184, double* %19
%185 = load double, double* %11
%186 = load double, double* %13
%187 = fdiv double %185, %186
store double %187, double* %20
br label %322
188: ; preds = %102
%189 = load double, double* %10
%190 = load double, double* %10
%191 = load double, double* %11
%192 = fmul double 3.000000e+00, %191
%193 = fneg double %192
%194 = call double @llvm.fmuladd.f64(double %189, double %190, double %193)
%195 = fdiv double %194, 9.000000e+00
store double %195, double* %13
%196 = load double, double* %10
%197 = fmul double 2.000000e+00, %196
%198 = load double, double* %10
%199 = fmul double %197, %198
%200 = load double, double* %10
%201 = load double, double* %10
%202 = fmul double 9.000000e+00, %201
%203 = load double, double* %11
%204 = fmul double %202, %203
%205 = fneg double %204
%206 = call double @llvm.fmuladd.f64(double %199, double %200, double %205)
%207 = load double, double* %12
%208 = call double @llvm.fmuladd.f64(double 2.700000e+01, double %207, double %206)
%209 = fdiv double %208, 5.400000e+01
store double %209, double* %14
%210 = load double, double* %13
%211 = load double, double* %13
%212 = fmul double %210, %211
%213 = load double, double* %13
%214 = fmul double %212, %213
store double %214, double* %15
%215 = load double, double* %14
%216 = load double, double* %14
%217 = fmul double %215, %216
store double %217, double* %16
%218 = load double, double* %15
%219 = load double, double* %16
%220 = fcmp olt double %218, %219
br i1 %220, label %221, label %238
221: ; preds = %188
%222 = load double, double* %15
%223 = load double, double* %16
%224 = fsub double %222, %223
%225 = call i32 @fabs(double %224)
%226 = sitofp i32 %225 to double
%227 = load double, double* %21
%228 = load double, double* %15
%229 = call i32 @fabs(double %228)
%230 = load double, double* %16
%231 = call i32 @fabs(double %230)
%232 = add nsw i32 %229, %231
%233 = sitofp i32 %232 to double
%234 = fmul double %227, %233
%235 = fcmp olt double %226, %234
br i1 %235, label %236, label %238
236: ; preds = %221
%237 = load double, double* %16
store double %237, double* %15
br label %238
238: ; preds = %236, %221, %188
%239 = load double, double* %15
%240 = load double, double* %16
%241 = fcmp oge double %239, %240
br i1 %241, label %242, label %295
242: ; preds = %238
%243 = load double, double* %14
%244 = fcmp oeq double %243, 0.000000e+00
br i1 %244, label %245, label %246
245: ; preds = %242
store double 0x3FF921FB54442D15, double* %17
br label %264
246: ; preds = %242
%247 = load double, double* %15
%248 = call i32 @sqrt(double %247)
%249 = sitofp i32 %248 to double
store double %249, double* %15
%250 = load double, double* %15
%251 = load double, double* %14
%252 = call i32 @fabs(double %251)
%253 = sitofp i32 %252 to double
%254 = fcmp olt double %250, %253
br i1 %254, label %255, label %259
255: ; preds = %246
%256 = load double, double* %14
%257 = call i32 @fabs(double %256)
%258 = sitofp i32 %257 to double
store double %258, double* %15
br label %259
259: ; preds = %255, %246
%260 = load double, double* %14
%261 = load double, double* %15
%262 = fdiv double %260, %261
%263 = call double @acos(double %262)
store double %263, double* %17
br label %264
264: ; preds = %259, %245
%265 = load double, double* %13
%266 = call i32 @sqrt(double %265)
%267 = mul nsw i32 -2, %266
%268 = sitofp i32 %267 to double
store double %268, double* %13
%269 = load double, double* %13
%270 = load double, double* %17
%271 = fdiv double %270, 3.000000e+00
%272 = call double @cos(double %271)
%273 = load double, double* %10
%274 = fdiv double %273, 3.000000e+00
%275 = fneg double %274
%276 = call double @llvm.fmuladd.f64(double %269, double %272, double %275)
store double %276, double* %18
%277 = load double, double* %13
%278 = load double, double* %17
%279 = fadd double %278, 0x401921FB54442D18
%280 = fdiv double %279, 3.000000e+00
%281 = call double @cos(double %280)
%282 = load double, double* %10
%283 = fdiv double %282, 3.000000e+00
%284 = fneg double %283
%285 = call double @llvm.fmuladd.f64(double %277, double %281, double %284)
store double %285, double* %19
%286 = load double, double* %13
%287 = load double, double* %17
%288 = fadd double %287, 0x402921FB54442D18
%289 = fdiv double %288, 3.000000e+00
%290 = call double @cos(double %289)
%291 = load double, double* %10
%292 = fdiv double %291, 3.000000e+00
%293 = fneg double %292
%294 = call double @llvm.fmuladd.f64(double %286, double %290, double %293)
store double %294, double* %20
br label %321
295: ; preds = %238
%296 = load double, double* %16
%297 = load double, double* %15
%298 = fsub double %296, %297
%299 = call i32 @sqrt(double %298)
%300 = load double, double* %14
%301 = call i32 @fabs(double %300)
%302 = add nsw i32 %299, %301
%303 = sitofp i32 %302 to double
store double %303, double* %17
%304 = load double, double* %17
%305 = call double @pow(double %304, double 0x3FD5555555555555)
store double %305, double* %17
%306 = load double, double* %14
%307 = fcmp olt double %306, 0.000000e+00
%308 = zext i1 %307 to i64
%309 = select i1 %307, i32 -1, i32 1
%310 = sub nsw i32 0, %309
%311 = sitofp i32 %310 to double
%312 = load double, double* %17
%313 = load double, double* %13
%314 = load double, double* %17
%315 = fdiv double %313, %314
%316 = fadd double %312, %315
%317 = load double, double* %10
%318 = fdiv double %317, 3.000000e+00
%319 = fneg double %318
%320 = call double @llvm.fmuladd.f64(double %311, double %316, double %319)
store double %320, double* %20
store double %320, double* %19
store double %320, double* %18
br label %321
321: ; preds = %295, %264
br label %322
322: ; preds = %321, %167
%323 = load double, double* %22
%324 = load double, double* %18
%325 = fmul double %324, %323
store double %325, double* %18
%326 = load double, double* %22
%327 = load double, double* %19
%328 = fmul double %327, %326
store double %328, double* %19
%329 = load double, double* %22
%330 = load double, double* %20
%331 = fmul double %330, %329
store double %331, double* %20
%332 = load double, double* %18
%333 = load double, double* %19
%334 = fcmp olt double %332, %333
br i1 %334, label %335, label %337
335: ; preds = %322
%336 = load double, double* %18
br label %339
337: ; preds = %322
%338 = load double, double* %19
br label %339
339: ; preds = %337, %335
%340 = phi double [ %336, %335 ], [ %338, %337 ]
%341 = load double*, double** %6
store double %340, double* %341
%342 = load double*, double** %6
%343 = load double, double* %342
%344 = load double, double* %20
%345 = fcmp olt double %343, %344
br i1 %345, label %346, label %349
346: ; preds = %339
%347 = load double*, double** %6
%348 = load double, double* %347
br label %351
349: ; preds = %339
%350 = load double, double* %20
br label %351
351: ; preds = %349, %346
%352 = phi double [ %348, %346 ], [ %350, %349 ]
%353 = load double*, double** %6
store double %352, double* %353
%354 = load double, double* %18
%355 = load double, double* %19
%356 = fcmp ogt double %354, %355
br i1 %356, label %357, label %359
357: ; preds = %351
%358 = load double, double* %18
br label %361
359: ; preds = %351
%360 = load double, double* %19
br label %361
361: ; preds = %359, %357
%362 = phi double [ %358, %357 ], [ %360, %359 ]
%363 = load double*, double** %8
store double %362, double* %363
%364 = load double*, double** %8
%365 = load double, double* %364
%366 = load double, double* %20
%367 = fcmp ogt double %365, %366
br i1 %367, label %368, label %371
368: ; preds = %361
%369 = load double*, double** %8
%370 = load double, double* %369
br label %373
371: ; preds = %361
%372 = load double, double* %20
br label %373
373: ; preds = %371, %368
%374 = phi double [ %370, %368 ], [ %372, %371 ]
%375 = load double*, double** %8
store double %374, double* %375
%376 = load double, double* %18
%377 = load double*, double** %6
%378 = load double, double* %377
%379 = fcmp une double %376, %378
br i1 %379, label %380, label %388
380: ; preds = %373
%381 = load double, double* %18
%382 = load double*, double** %8
%383 = load double, double* %382
%384 = fcmp une double %381, %383
br i1 %384, label %385, label %388
385: ; preds = %380
%386 = load double, double* %18
%387 = load double*, double** %7
store double %386, double* %387
br label %405
388: ; preds = %380, %373
%389 = load double, double* %19
%390 = load double*, double** %6
%391 = load double, double* %390
%392 = fcmp une double %389, %391
br i1 %392, label %393, label %401
393: ; preds = %388
%394 = load double, double* %19
%395 = load double*, double** %8
%396 = load double, double* %395
%397 = fcmp une double %394, %396
br i1 %397, label %398, label %401
398: ; preds = %393
%399 = load double, double* %19
%400 = load double*, double** %7
store double %399, double* %400
br label %404
401: ; preds = %393, %388
%402 = load double, double* %20
%403 = load double*, double** %7
store double %402, double* %403
br label %404
404: ; preds = %401, %398
br label %405
405: ; preds = %404, %385
ret void
}

LLVM IR (-O2):
define void @ch_evals3([3 x double]* nocapture %0, double* nocapture %1, double* nocapture writeonly %2, double* nocapture %3) {
%5 = alloca [3 x [3 x double]]
%6 = bitcast [3 x [3 x double]]* %5 to i8*
%7 = getelementptr inbounds [3 x double], [3 x double]* %0, i64 0, i64 0
%8 = load double, double* %7
%9 = tail call i32 @fabs(double %8)
%10 = icmp sgt i32 %9, 0
br i1 %10, label %11, label %15
11: ; preds = %4
%12 = load double, double* %7
%13 = tail call i32 @fabs(double %12)
%14 = sitofp i32 %13 to double
br label %15
15: ; preds = %4, %11
%16 = phi double [ %14, %11 ], [ 0.000000e+00, %4 ]
%17 = getelementptr inbounds [3 x double], [3 x double]* %0, i64 0, i64 1
%18 = load double, double* %17
%19 = tail call i32 @fabs(double %18)
%20 = sitofp i32 %19 to double
%21 = fcmp olt double %16, %20
br i1 %21, label %22, label %26
22: ; preds = %15
%23 = load double, double* %17
%24 = tail call i32 @fabs(double %23)
%25 = sitofp i32 %24 to double
br label %26
26: ; preds = %22, %15
%27 = phi double [ %25, %22 ], [ %16, %15 ]
%28 = getelementptr inbounds [3 x double], [3 x double]* %0, i64 0, i64 2
%29 = load double, double* %28
%30 = tail call i32 @fabs(double %29)
%31 = sitofp i32 %30 to double
%32 = fcmp olt double %27, %31
br i1 %32, label %33, label %37
33: ; preds = %26
%34 = load double, double* %28
%35 = tail call i32 @fabs(double %34)
%36 = sitofp i32 %35 to double
br label %37
37: ; preds = %33, %26
%38 = phi double [ %36, %33 ], [ %27, %26 ]
%39 = getelementptr inbounds [3 x double], [3 x double]* %0, i64 1, i64 1
%40 = load double, double* %39
%41 = tail call i32 @fabs(double %40)
%42 = sitofp i32 %41 to double
%43 = fcmp olt double %38, %42
br i1 %43, label %44, label %48
44: ; preds = %37
%45 = load double, double* %39
%46 = tail call i32 @fabs(double %45)
%47 = sitofp i32 %46 to double
br label %48
48: ; preds = %44, %37
%49 = phi double [ %47, %44 ], [ %38, %37 ]
%50 = getelementptr inbounds [3 x double], [3 x double]* %0, i64 1, i64 2
%51 = load double, double* %50
%52 = tail call i32 @fabs(double %51)
%53 = sitofp i32 %52 to double
%54 = fcmp olt double %49, %53
br i1 %54, label %55, label %59
55: ; preds = %48
%56 = load double, double* %50
%57 = tail call i32 @fabs(double %56)
%58 = sitofp i32 %57 to double
br label %59
59: ; preds = %55, %48
%60 = phi double [ %58, %55 ], [ %49, %48 ]
%61 = getelementptr inbounds [3 x double], [3 x double]* %0, i64 2, i64 2
%62 = load double, double* %61
%63 = tail call i32 @fabs(double %62)
%64 = sitofp i32 %63 to double
%65 = fcmp olt double %60, %64
br i1 %65, label %66, label %70
66: ; preds = %59
%67 = load double, double* %61
%68 = tail call i32 @fabs(double %67)
%69 = sitofp i32 %68 to double
br label %70
70: ; preds = %59, %66
%71 = phi double [ %69, %66 ], [ %60, %59 ]
%72 = fcmp une double %71, 0.000000e+00
br i1 %72, label %73, label %96
73: ; preds = %70
%74 = getelementptr inbounds [3 x double], [3 x double]* %0, i64 0, i64 0
%75 = load double, double* %74
%76 = fdiv double %75, %71
%77 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %5, i64 0, i64 0, i64 0
store double %76, double* %77
%78 = getelementptr inbounds [3 x double], [3 x double]* %0, i64 0, i64 1
%79 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %5, i64 0, i64 0, i64 1
%80 = bitcast double* %78 to <8 x double>*
%81 = load <8 x double>, <8 x double>* %80
%82 = insertelement <8 x double> poison, double %71, i64 0
%83 = shufflevector <8 x double> %82, <8 x double> poison, <8 x i32> zeroinitializer
%84 = fdiv <8 x double> %81, %83
%85 = shufflevector <8 x double> %84, <8 x double> undef, <2 x i32> <i32 0, i32 1>
%86 = bitcast double* %79 to <2 x double>*
store <2 x double> %85, <2 x double>* %86
%87 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %5, i64 0, i64 1, i64 0
%88 = shufflevector <8 x double> %84, <8 x double> undef, <2 x i32> <i32 2, i32 3>
%89 = bitcast double* %87 to <2 x double>*
store <2 x double> %88, <2 x double>* %89
%90 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %5, i64 0, i64 1, i64 2
%91 = shufflevector <8 x double> %84, <8 x double> undef, <2 x i32> <i32 4, i32 5>
%92 = bitcast double* %90 to <2 x double>*
store <2 x double> %91, <2 x double>* %92
%93 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %5, i64 0, i64 2, i64 1
%94 = shufflevector <8 x double> %84, <8 x double> undef, <2 x i32> <i32 6, i32 7>
%95 = bitcast double* %93 to <2 x double>*
store <2 x double> %94, <2 x double>* %95
br label %96
96: ; preds = %73, %70
%97 = phi double [ %76, %73 ], [ 0.000000e+00, %70 ]
%98 = phi <8 x double> [ %84, %73 ], [ zeroinitializer, %70 ]
%99 = getelementptr inbounds [3 x [3 x double]], [3 x [3 x double]]* %5, i64 0, i64 0
%100 = extractelement <8 x double> %98, i64 3
%101 = fadd double %97, %100
%102 = extractelement <8 x double> %98, i64 7
%103 = fadd double %101, %102
%104 = fneg double %103
%105 = extractelement <8 x double> %98, i64 0
%106 = fneg double %105
%107 = extractelement <8 x double> %98, i64 2
%108 = fmul double %107, %106
%109 = tail call double @llvm.fmuladd.f64(double %97, double %100, double %108)
%110 = extractelement <8 x double> %98, i64 1
%111 = fneg double %110
%112 = extractelement <8 x double> %98, i64 5
%113 = fmul double %112, %111
%114 = tail call double @llvm.fmuladd.f64(double %97, double %102, double %113)
%115 = fadd double %109, %114
%116 = extractelement <8 x double> %98, i64 4
%117 = fneg double %116
%118 = extractelement <8 x double> %98, i64 6
%119 = fmul double %118, %117
%120 = tail call double @llvm.fmuladd.f64(double %100, double %102, double %119)
%121 = fadd double %115, %120
%122 = call double ([3 x double]*, i32, ...) bitcast (double (...)* @determinant to double ([3 x double]*, i32, ...)*)([3 x double]* %99, i32 3)
%123 = fcmp oeq double %122, 0.000000e+00
br i1 %123, label %124, label %135
124: ; preds = %96
%125 = fcmp ogt double %103, 0.000000e+00
%126 = fmul double %121, -4.000000e+00
%127 = call double @llvm.fmuladd.f64(double %103, double %103, double %126)
%128 = call i32 @sqrt(double %127)
%129 = sub nsw i32 0, %128
%130 = select i1 %125, i32 %129, i32 %128
%131 = sitofp i32 %130 to double
%132 = fsub double %131, %103
%133 = fmul double %132, -5.000000e-01
%134 = fdiv double %121, %133
br label %217
135: ; preds = %96
%136 = fneg double %122
%137 = fmul double %121, -3.000000e+00
%138 = fmul double %103, -2.000000e+00
%139 = fmul double %138, %104
%140 = fmul double %103, 9.000000e+00
%141 = fmul double %140, %121
%142 = call double @llvm.fmuladd.f64(double %139, double %104, double %141)
%143 = insertelement <2 x double> poison, double %103, i64 0
%144 = insertelement <2 x double> %143, double %136, i64 1
%145 = insertelement <2 x double> <double poison, double 2.700000e+01>, double %103, i64 0
%146 = insertelement <2 x double> poison, double %137, i64 0
%147 = insertelement <2 x double> %146, double %142, i64 1
%148 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %144, <2 x double> %145, <2 x double> %147)
%149 = fdiv <2 x double> %148, <double 9.000000e+00, double 5.400000e+01>
%150 = extractelement <2 x double> %149, i64 0
%151 = fmul <2 x double> %149, %149
%152 = extractelement <2 x double> %149, i64 1
%153 = shufflevector <2 x double> %151, <2 x double> %149, <2 x i32> <i32 0, i32 3>
%154 = fmul <2 x double> %149, %153
%155 = extractelement <2 x double> %154, i64 0
%156 = extractelement <2 x double> %154, i64 1
%157 = fcmp olt double %155, %156
br i1 %157, label %158, label %169
158: ; preds = %135
%159 = fsub double %155, %156
%160 = call i32 @fabs(double %159)
%161 = sitofp i32 %160 to double
%162 = call i32 @fabs(double %155)
%163 = call i32 @fabs(double %156)
%164 = add nsw i32 %163, %162
%165 = sitofp i32 %164 to double
%166 = fmul double %165, 0x3EB0C6F7A0B5ED8D
%167 = fcmp ogt double %166, %161
br i1 %167, label %168, label %169
168: ; preds = %158
br label %169
169: ; preds = %168, %158, %135
%170 = phi double [ %156, %168 ], [ %155, %158 ], [ %155, %135 ]
%171 = fcmp ult double %170, %156
br i1 %171, label %204, label %172
172: ; preds = %169
%173 = fcmp oeq double %152, 0.000000e+00
br i1 %173, label %187, label %174
174: ; preds = %172
%175 = call i32 @sqrt(double %170)
%176 = sitofp i32 %175 to double
%177 = call i32 @fabs(double %152)
%178 = sitofp i32 %177 to double
%179 = fcmp olt double %176, %178
br i1 %179, label %180, label %183
180: ; preds = %174
%181 = call i32 @fabs(double %152)
%182 = sitofp i32 %181 to double
br label %183
183: ; preds = %180, %174
%184 = phi double [ %182, %180 ], [ %176, %174 ]
%185 = fdiv double %152, %184
%186 = call double @acos(double %185)
br label %187
187: ; preds = %172, %183
%188 = phi double [ %186, %183 ], [ 0x3FF921FB54442D15, %172 ]
%189 = call i32 @sqrt(double %150)
%190 = mul nsw i32 %189, -2
%191 = sitofp i32 %190 to double
%192 = fdiv double %188, 3.000000e+00
%193 = call double @cos(double %192)
%194 = fdiv double %103, 3.000000e+00
%195 = call double @llvm.fmuladd.f64(double %191, double %193, double %194)
%196 = fadd double %188, 0x401921FB54442D18
%197 = fdiv double %196, 3.000000e+00
%198 = call double @cos(double %197)
%199 = call double @llvm.fmuladd.f64(double %191, double %198, double %194)
%200 = fadd double %188, 0x402921FB54442D18
%201 = fdiv double %200, 3.000000e+00
%202 = call double @cos(double %201)
%203 = call double @llvm.fmuladd.f64(double %191, double %202, double %194)
br label %217
204: ; preds = %169
%205 = fsub double %156, %170
%206 = call i32 @sqrt(double %205)
%207 = call i32 @fabs(double %152)
%208 = add nsw i32 %207, %206
%209 = sitofp i32 %208 to double
%210 = call double @pow(double %209, double 0x3FD5555555555555)
%211 = fcmp olt double %152, 0.000000e+00
%212 = select i1 %211, double 1.000000e+00, double -1.000000e+00
%213 = fdiv double %150, %210
%214 = fadd double %210, %213
%215 = fdiv double %103, 3.000000e+00
%216 = call double @llvm.fmuladd.f64(double %212, double %214, double %215)
br label %217
217: ; preds = %187, %204, %124
%218 = phi double [ 0.000000e+00, %124 ], [ %195, %187 ], [ %216, %204 ]
%219 = phi double [ %133, %124 ], [ %199, %187 ], [ %216, %204 ]
%220 = phi double [ %134, %124 ], [ %203, %187 ], [ %216, %204 ]
%221 = fmul double %71, %218
%222 = fmul double %71, %219
%223 = fmul double %71, %220
%224 = fcmp olt double %221, %222
%225 = select i1 %224, double %221, double %222
%226 = fcmp olt double %225, %223
%227 = select i1 %226, double %225, double %223
store double %227, double* %1
%228 = fcmp ogt double %221, %222
%229 = select i1 %228, double %221, double %222
%230 = fcmp ogt double %229, %223
%231 = select i1 %230, double %229, double %223
store double %231, double* %3
%232 = load double, double* %1
%233 = fcmp une double %221, %232
%234 = fcmp une double %221, %231
%235 = select i1 %233, i1 %234, i1 false
%236 = fcmp une double %222, %232
%237 = fcmp une double %222, %231
%238 = select i1 %236, i1 %237, i1 false
%239 = select i1 %238, double %222, double %223
%240 = select i1 %235, double %221, double %239
store double %240, double* %2
ret void
}