void kEpsilon_2D_Evaluate(
    int nPoints, int nSpace, double sigma_k, double sigma_e, double c_1,
    double c_2, double c_mu, double c_e, double nu, double *velocity,
    double *gradu, double *gradv, double *k, double *epsilon, double *m_k,
    double *dm_k, double *m_e, double *dm_e, double *phi_k, double *dphi_k,
    double *phi_e, double *dphi_e, double *f_k, double *df_k, double *f_e,
    double *df_e, double *a_k, double *da_k_dk, double *da_k_de, double *a_e,
    double *da_e_dk, double *da_e_de, double *r_k, double *dr_k_dk,
    double *dr_k_de, double *r_e, double *dr_e_dk, double *dr_e_de) {
  int i, I;
  double nu_t, dnu_t_dk, dnu_t_de, PiD4, eval, kval, disp, ddisp_dk, ddisp_de;
  const double div_eps = 1.0e-6;
  for (i = 0; i < nPoints; i++) {
    eval = epsilon[i] >= 0.0 ? epsilon[i] : 0.0;
    kval = k[i] >= 0.0 ? k[i] : 0.0;
    nu_t = c_mu * k[i] * k[i] / (epsilon[i] + div_eps);
    dnu_t_dk = 2.0 * c_mu * k[i] / (epsilon[i] + div_eps);
    dnu_t_de = -c_mu * k[i] * k[i] / (epsilon[i] * epsilon[i] + div_eps);
    if (nu_t < 0.0) {
      nu_t = 0.0;
      dnu_t_dk = 0.0;
      dnu_t_de = 0.0;
    }
    m_k[i] = k[i];
    dm_k[i] = 1.0;
    m_e[i] = epsilon[i];
    dm_e[i] = 1.0;
    for (I = 0; I < nSpace; I++) {
      f_k[i * nSpace + I] = k[i] * velocity[i * nSpace + I];
      df_k[i * nSpace + I] = velocity[i * nSpace + I];
      f_e[i * nSpace + I] = epsilon[i] * velocity[i * nSpace + I];
      df_e[i * nSpace + I] = velocity[i * nSpace + I];
    }
    phi_k[i] = k[i];
    dphi_k[i] = 1.0;
    phi_e[i] = epsilon[i];
    dphi_e[i] = 1.0;
    for (I = 0; I < nSpace; I++) {
      a_k[i * nSpace * nSpace + I * nSpace + I] = nu_t / sigma_k + nu;
      da_k_dk[i * nSpace * nSpace + I * nSpace + I] = dnu_t_dk / sigma_k;
      da_k_de[i * nSpace * nSpace + I * nSpace + I] = dnu_t_de / sigma_k;
      a_e[i * nSpace * nSpace + I * nSpace + I] = nu_t / sigma_e + nu;
      da_e_dk[i * nSpace * nSpace + I * nSpace + I] = dnu_t_dk / sigma_e;
      da_e_de[i * nSpace * nSpace + I * nSpace + I] = dnu_t_de / sigma_e;
    }
    PiD4 = 2.0 * (gradu[i * nSpace + 0] * gradu[i * nSpace + 0] +
                  gradv[i * nSpace + 1] * gradv[i * nSpace + 1]) +
           (gradu[i * nSpace + 1] + gradv[i * nSpace + 0]) *
               (gradu[i * nSpace + 1] + gradv[i * nSpace + 0]);
    r_k[i] = -nu_t * PiD4 + epsilon[i];
    dr_k_dk[i] = -dnu_t_dk * PiD4;
    dr_k_de[i] = -dnu_t_de * PiD4 + 1.0;
    disp = c_2 * epsilon[i] * epsilon[i] / (k[i] + div_eps);
    ddisp_dk = -c_2 * epsilon[i] * epsilon[i] / (k[i] * k[i] + div_eps);
    ddisp_de = 2.0 * c_2 * epsilon[i] / (k[i] + div_eps);
    if (disp < 0.0) {
      disp = 0.0;
      ddisp_dk = 0.0;
      ddisp_de = 0.0;
    }
    r_e[i] = -c_1 * k[i] * PiD4 + disp;
    dr_e_dk[i] = -c_1 * PiD4 + ddisp_dk;
    dr_e_de[i] = ddisp_de;
  }
}


x86 assembly (clang, -O0):
<kEpsilon_2D_Evaluate>:
push   %rbp
mov    %rsp,%rbp
sub    $0x48,%rsp
mov    0xd0(%rbp),%rax
mov    0xc8(%rbp),%rax
mov    0xc0(%rbp),%rax
mov    0xb8(%rbp),%rax
mov    0xb0(%rbp),%rax
mov    0xa8(%rbp),%rax
mov    0xa0(%rbp),%rax
mov    0x98(%rbp),%rax
mov    0x90(%rbp),%rax
mov    0x88(%rbp),%rax
mov    0x80(%rbp),%rax
mov    0x78(%rbp),%rax
mov    0x70(%rbp),%rax
mov    0x68(%rbp),%rax
mov    0x60(%rbp),%rax
mov    0x58(%rbp),%rax
mov    0x50(%rbp),%rax
mov    0x48(%rbp),%rax
mov    0x40(%rbp),%rax
mov    0x38(%rbp),%rax
mov    0x30(%rbp),%rax
mov    0x28(%rbp),%rax
mov    0x20(%rbp),%rax
mov    0x18(%rbp),%rax
mov    0x10(%rbp),%rax
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
movsd  %xmm0,-0x10(%rbp)
movsd  %xmm1,-0x18(%rbp)
movsd  %xmm2,-0x20(%rbp)
movsd  %xmm3,-0x28(%rbp)
movsd  %xmm4,-0x30(%rbp)
movsd  %xmm5,-0x38(%rbp)
movsd  %xmm6,-0x40(%rbp)
mov    %rdx,-0x48(%rbp)
mov    %rcx,-0x50(%rbp)
mov    %r8,-0x58(%rbp)
mov    %r9,-0x60(%rbp)
movsd  0xe32(%rip),%xmm0
movsd  %xmm0,-0xb8(%rbp)
ff
movl   $0x0,-0x64(%rbp)
mov    -0x64(%rbp),%eax
cmp    -0x4(%rbp),%eax
jge    19e5 <kEpsilon_2D_Evaluate+0x8e5>
mov    0x10(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jb     121d <kEpsilon_2D_Evaluate+0x11d>
mov    0x10(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0xc0(%rbp)
ff
jmp    122d <kEpsilon_2D_Evaluate+0x12d>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xc0(%rbp)
ff
jmp    122d <kEpsilon_2D_Evaluate+0x12d>
movsd  -0xc0(%rbp),%xmm0
ff
movsd  %xmm0,-0x90(%rbp)
ff
mov    -0x60(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jb     1271 <kEpsilon_2D_Evaluate+0x171>
mov    -0x60(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0xc8(%rbp)
ff
jmp    1281 <kEpsilon_2D_Evaluate+0x181>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xc8(%rbp)
ff
jmp    1281 <kEpsilon_2D_Evaluate+0x181>
movsd  -0xc8(%rbp),%xmm0
ff
movsd  %xmm0,-0x98(%rbp)
ff
movsd  -0x30(%rbp),%xmm0
mov    -0x60(%rbp),%rax
movslq -0x64(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    -0x60(%rbp),%rax
movslq -0x64(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    0x10(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  0xd40(%rip),%xmm1
addsd  (%rax,%rcx,8),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x70(%rbp)
movsd  0xd32(%rip),%xmm0
mulsd  -0x30(%rbp),%xmm0
mov    -0x60(%rbp),%rax
movslq -0x64(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    0x10(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  0xd08(%rip),%xmm1
addsd  (%rax,%rcx,8),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x78(%rbp)
movsd  -0x30(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mov    -0x60(%rbp),%rax
movslq -0x64(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    -0x60(%rbp),%rax
movslq -0x64(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    0x10(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm1
mov    0x10(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm2
mulsd  %xmm2,%xmm1
movsd  0xc9e(%rip),%xmm2
addsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x80(%rbp)
xorps  %xmm0,%xmm0
ucomisd -0x70(%rbp),%xmm0
jbe    1395 <kEpsilon_2D_Evaluate+0x295>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x70(%rbp)
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x78(%rbp)
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x80(%rbp)
mov    -0x60(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x18(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    0x20(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  0xc51(%rip),%xmm0
movsd  %xmm0,(%rax,%rcx,8)
mov    0x10(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x28(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    0x30(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  0xc22(%rip),%xmm0
movsd  %xmm0,(%rax,%rcx,8)
movl   $0x0,-0x68(%rbp)
mov    -0x68(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    14de <kEpsilon_2D_Evaluate+0x3de>
mov    -0x60(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x48(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x68(%rbp),%ecx
movslq %ecx,%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    0x58(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x68(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x48(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x68(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x60(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x68(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    0x10(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x48(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x68(%rbp),%ecx
movslq %ecx,%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    0x68(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x68(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x48(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x68(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x70(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x68(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x68(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x68(%rbp)
jmp    13fa <kEpsilon_2D_Evaluate+0x2fa>
mov    -0x60(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x38(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    0x40(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  0xb08(%rip),%xmm0
movsd  %xmm0,(%rax,%rcx,8)
mov    0x10(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x48(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    0x50(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  0xad9(%rip),%xmm0
movsd  %xmm0,(%rax,%rcx,8)
movl   $0x0,-0x68(%rbp)
mov    -0x68(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    1684 <kEpsilon_2D_Evaluate+0x584>
movsd  -0x70(%rbp),%xmm0
divsd  -0x10(%rbp),%xmm0
addsd  -0x40(%rbp),%xmm0
mov    0x78(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0x8(%rbp),%ecx
mov    -0x68(%rbp),%edx
imul   -0x8(%rbp),%edx
add    %edx,%ecx
add    -0x68(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0x78(%rbp),%xmm0
divsd  -0x10(%rbp),%xmm0
mov    0x80(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0x8(%rbp),%ecx
mov    -0x68(%rbp),%edx
imul   -0x8(%rbp),%edx
add    %edx,%ecx
add    -0x68(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0x80(%rbp),%xmm0
divsd  -0x10(%rbp),%xmm0
mov    0x88(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0x8(%rbp),%ecx
mov    -0x68(%rbp),%edx
imul   -0x8(%rbp),%edx
add    %edx,%ecx
add    -0x68(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0x70(%rbp),%xmm0
divsd  -0x18(%rbp),%xmm0
addsd  -0x40(%rbp),%xmm0
mov    0x90(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0x8(%rbp),%ecx
mov    -0x68(%rbp),%edx
imul   -0x8(%rbp),%edx
add    %edx,%ecx
add    -0x68(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0x78(%rbp),%xmm0
divsd  -0x18(%rbp),%xmm0
mov    0x98(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0x8(%rbp),%ecx
mov    -0x68(%rbp),%edx
imul   -0x8(%rbp),%edx
add    %edx,%ecx
add    -0x68(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0x80(%rbp),%xmm0
divsd  -0x18(%rbp),%xmm0
mov    0xa0(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0x8(%rbp),%ecx
mov    -0x68(%rbp),%edx
imul   -0x8(%rbp),%edx
add    %edx,%ecx
add    -0x68(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x68(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x68(%rbp)
jmp    1543 <kEpsilon_2D_Evaluate+0x443>
mov    -0x50(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    $0x0,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x50(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    $0x0,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm2
mov    -0x58(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm1
mov    -0x58(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
mulsd  (%rax,%rcx,8),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    -0x50(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm1
mov    -0x58(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    $0x0,%ecx
movslq %ecx,%rcx
addsd  (%rax,%rcx,8),%xmm1
mov    -0x50(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm2
mov    -0x58(%rbp),%rax
mov    -0x64(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    $0x0,%ecx
movslq %ecx,%rcx
addsd  (%rax,%rcx,8),%xmm2
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x88(%rbp)
ff
movsd  -0x70(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  -0x88(%rbp),%xmm2
ff
mov    0x10(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    0xa8(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0x78(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  -0x88(%rbp),%xmm0
ff
mov    0xb0(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0x80(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  -0x88(%rbp),%xmm1
ff
mulsd  %xmm1,%xmm0
movsd  0x813(%rip),%xmm1
addsd  %xmm1,%xmm0
mov    0xb8(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0x28(%rbp),%xmm0
mov    0x10(%rbp),%rax
movslq -0x64(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    0x10(%rbp),%rax
movslq -0x64(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    -0x60(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  0x7c0(%rip),%xmm1
addsd  (%rax,%rcx,8),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xa0(%rbp)
ff
movsd  -0x28(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mov    0x10(%rbp),%rax
movslq -0x64(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    0x10(%rbp),%rax
movslq -0x64(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    -0x60(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm1
mov    -0x60(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm2
mulsd  %xmm2,%xmm1
movsd  0x753(%rip),%xmm2
addsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xa8(%rbp)
ff
movsd  0x743(%rip),%xmm0
mulsd  -0x28(%rbp),%xmm0
mov    0x10(%rbp),%rax
movslq -0x64(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    -0x60(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  0x719(%rip),%xmm1
addsd  (%rax,%rcx,8),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xb0(%rbp)
ff
xorps  %xmm0,%xmm0
ucomisd -0xa0(%rbp),%xmm0
ff
jbe    192a <kEpsilon_2D_Evaluate+0x82a>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xa0(%rbp)
ff
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xa8(%rbp)
ff
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xb0(%rbp)
ff
movsd  -0x20(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mov    -0x60(%rbp),%rax
movslq -0x64(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm0
movsd  -0x88(%rbp),%xmm2
ff
movsd  -0xa0(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    0xc0(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0x20(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  -0x88(%rbp),%xmm2
ff
movsd  -0xa8(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    0xc8(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0xb0(%rbp),%xmm0
ff
mov    0xd0(%rbp),%rax
movslq -0x64(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x64(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x64(%rbp)
jmp    11dd <kEpsilon_2D_Evaluate+0xdd>
add    $0x48,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<kEpsilon_2D_Evaluate>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x38,%rsp
movsd  %xmm6,-0x28(%rsp)
movsd  %xmm1,-0x30(%rsp)
movsd  %xmm0,-0x38(%rsp)
mov    %esi,-0x7c(%rsp)
test   %edi,%edi
jle    16b7 <kEpsilon_2D_Evaluate+0x5b7>
mov    %r9,%rax
movapd %xmm3,%xmm12
mov    0x130(%rsp),%r9
mov    0x128(%rsp),%r14
movapd %xmm4,%xmm15
addsd  %xmm4,%xmm15
movapd 0xeaa(%rip),%xmm3
movapd %xmm4,%xmm0
xorpd  %xmm3,%xmm0
movapd %xmm0,0x20(%rsp)
movapd %xmm12,%xmm14
xorpd  %xmm3,%xmm14
movapd %xmm12,%xmm5
addsd  %xmm12,%xmm5
movapd %xmm5,0x10(%rsp)
xorpd  %xmm3,%xmm2
movslq -0x7c(%rsp),%rsi
mov    %edi,%edi
mov    %rdi,-0x10(%rsp)
mov    %esi,%edi
imul   %esi,%edi
mov    %edi,-0x6c(%rsp)
movsd  0xe71(%rip),%xmm1
movapd 0xe59(%rip),%xmm0
mov    0xd0(%rsp),%rbp
mov    0xc8(%rsp),%r13
mov    0xc0(%rsp),%r10
mov    0xb8(%rsp),%rdi
mov    0x70(%rsp),%r15
mov    %esi,%r11d
mov    %rsi,-0x68(%rsp)
lea    0x0(,%rsi,8),%rsi
mov    %rsi,-0x18(%rsp)
xor    %esi,%esi
mov    %rsi,-0x78(%rsp)
movabs $0x3ff0000000000000,%rsi
xor    %r12d,%r12d
mov    %r8,-0x40(%rsp)
mov    %rcx,-0x48(%rsp)
mov    %rax,-0x50(%rsp)
movapd %xmm2,(%rsp)
mov    %r11,-0x58(%rsp)
jmp    12c1 <kEpsilon_2D_Evaluate+0x1c1>
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
movapd %xmm6,%xmm3
mulsd  %xmm14,%xmm3
mulsd  %xmm6,%xmm3
movapd %xmm7,%xmm6
mulsd  %xmm7,%xmm6
addsd  %xmm1,%xmm6
divsd  %xmm6,%xmm3
xorpd  %xmm6,%xmm6
maxsd  %xmm5,%xmm6
cmpltsd %xmm9,%xmm5
andnpd %xmm3,%xmm5
mulsd  %xmm2,%xmm7
mulsd  %xmm11,%xmm7
addsd  %xmm6,%xmm7
mov    0x120(%rsp),%rbp
movsd  %xmm7,0x0(%rbp,%r12,8)
mulsd  %xmm2,%xmm11
addsd  %xmm5,%xmm11
movsd  %xmm11,(%r14,%r12,8)
movsd  %xmm8,(%r9,%r12,8)
add    $0x1,%r12
mov    -0x18(%rsp),%rsi
add    %rsi,%rdx
add    %rsi,%rdi
add    %rsi,%r10
add    %rsi,%r13
mov    -0x8(%rsp),%rbp
add    %rsi,%rbp
mov    -0x78(%rsp),%rsi
add    -0x6c(%rsp),%esi
mov    %rsi,-0x78(%rsp)
cmp    -0x10(%rsp),%r12
movabs $0x3ff0000000000000,%rsi
je     16b7 <kEpsilon_2D_Evaluate+0x5b7>
movsd  (%r15,%r12,8),%xmm3
movsd  (%rax,%r12,8),%xmm5
movapd %xmm5,%xmm7
mulsd  %xmm4,%xmm7
mulsd  %xmm5,%xmm7
movapd %xmm3,%xmm6
addsd  %xmm1,%xmm6
divsd  %xmm6,%xmm7
xorpd  %xmm9,%xmm9
ucomisd %xmm7,%xmm9
xorpd  %xmm13,%xmm13
ja     1314 <kEpsilon_2D_Evaluate+0x214>
movapd %xmm5,%xmm13
mulsd  0x20(%rsp),%xmm13
mulsd  %xmm5,%xmm13
mulsd  %xmm3,%xmm3
addsd  %xmm1,%xmm3
divsd  %xmm3,%xmm13
movapd %xmm15,%xmm3
mulsd  %xmm5,%xmm3
divsd  %xmm6,%xmm3
movapd %xmm7,%xmm10
cmpltsd %xmm9,%xmm10
andnpd %xmm3,%xmm10
maxsd  %xmm7,%xmm9
mov    0x78(%rsp),%rbx
movsd  %xmm5,(%rbx,%r12,8)
mov    0x80(%rsp),%rbx
mov    %rsi,(%rbx,%r12,8)
movsd  (%r15,%r12,8),%xmm3
mov    0x88(%rsp),%rbx
movsd  %xmm3,(%rbx,%r12,8)
mov    0x90(%rsp),%rbx
mov    %rsi,(%rbx,%r12,8)
cmpl   $0x0,-0x7c(%rsp)
mov    %rbp,-0x8(%rsp)
mov    %rdi,-0x60(%rsp)
jle    1580 <kEpsilon_2D_Evaluate+0x480>
mov    %r14,%rsi
mov    %r9,%r14
mov    %rbp,%r9
xor    %ebp,%ebp
mov    %r10,%rbx
movsd  (%rax,%r12,8),%xmm3
mulsd  (%rdx,%rbp,8),%xmm3
movsd  %xmm3,(%rdi,%rbp,8)
movsd  (%rdx,%rbp,8),%xmm3
movsd  %xmm3,(%rbx,%rbp,8)
movsd  (%r15,%r12,8),%xmm3
mulsd  (%rdx,%rbp,8),%xmm3
movsd  %xmm3,0x0(%r13,%rbp,8)
movsd  (%rdx,%rbp,8),%xmm3
movsd  %xmm3,(%r9,%rbp,8)
add    $0x1,%rbp
cmp    %rbp,%r11
jne    1390 <kEpsilon_2D_Evaluate+0x290>
mov    %r13,%rdi
movsd  (%rax,%r12,8),%xmm3
mov    0x98(%rsp),%rbp
movsd  %xmm3,0x0(%rbp,%r12,8)
mov    0xa0(%rsp),%rbp
movabs $0x3ff0000000000000,%rbx
mov    %rbx,0x0(%rbp,%r12,8)
movsd  (%r15,%r12,8),%xmm3
mov    0xa8(%rsp),%rbp
movsd  %xmm3,0x0(%rbp,%r12,8)
mov    0xb0(%rsp),%rbp
mov    %rbx,0x0(%rbp,%r12,8)
cmpl   $0x0,-0x7c(%rsp)
mov    %r14,%r9
mov    %rsi,%r14
jle    15c3 <kEpsilon_2D_Evaluate+0x4c3>
movapd %xmm1,%xmm2
movapd %xmm15,%xmm0
movapd %xmm12,%xmm6
movapd %xmm9,%xmm11
movsd  -0x38(%rsp),%xmm1
divsd  %xmm1,%xmm11
movsd  -0x28(%rsp),%xmm3
addsd  %xmm3,%xmm11
mov    %r12,%rax
imul   -0x68(%rsp),%rax
mov    %rax,-0x20(%rsp)
movapd %xmm10,%xmm7
divsd  %xmm1,%xmm7
movapd %xmm13,%xmm5
divsd  %xmm1,%xmm5
movapd %xmm9,%xmm12
movsd  -0x30(%rsp),%xmm1
divsd  %xmm1,%xmm12
addsd  %xmm3,%xmm12
movapd %xmm10,%xmm8
divsd  %xmm1,%xmm8
movapd %xmm13,%xmm15
divsd  %xmm1,%xmm15
mov    %r11,%r8
mov    -0x78(%rsp),%rcx
xor    %r14d,%r14d
mov    -0x7c(%rsp),%esi
mov    0xf0(%rsp),%rbp
mov    0xf8(%rsp),%rbx
mov    0x100(%rsp),%r13
mov    0xd8(%rsp),%r15
mov    0xe0(%rsp),%rax
mov    0xe8(%rsp),%r9
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
movslq %ecx,%rcx
lea    (%r14,%rcx,1),%r11
movsd  %xmm11,(%r15,%r11,8)
movsd  %xmm7,(%rax,%r11,8)
movsd  %xmm5,(%r9,%r11,8)
movsd  %xmm12,0x0(%rbp,%r11,8)
movsd  %xmm8,(%rbx,%r11,8)
movsd  %xmm15,0x0(%r13,%r11,8)
add    $0x1,%r14
add    %esi,%ecx
add    $0xffffffffffffffff,%r8
jne    14f0 <kEpsilon_2D_Evaluate+0x3f0>
mov    -0x40(%rsp),%r8
mov    -0x48(%rsp),%rcx
movapd %xmm6,%xmm12
mov    0x130(%rsp),%r9
mov    0x128(%rsp),%r14
mov    -0x50(%rsp),%rax
movapd %xmm0,%xmm15
movapd %xmm2,%xmm1
movapd (%rsp),%xmm2
movapd 0xa9d(%rip),%xmm0
mov    %rdi,%r13
mov    -0x60(%rsp),%rdi
mov    0x70(%rsp),%r15
mov    -0x58(%rsp),%r11
mov    -0x20(%rsp),%rsi
jmp    15d9 <kEpsilon_2D_Evaluate+0x4d9>
nopl   0x0(%rax)
mov    %r13,%rdi
movsd  (%rax,%r12,8),%xmm3
mov    0x98(%rsp),%rbx
movsd  %xmm3,(%rbx,%r12,8)
mov    0xa0(%rsp),%rbx
mov    %rsi,(%rbx,%r12,8)
movsd  (%r15,%r12,8),%xmm3
mov    0xa8(%rsp),%rbx
movsd  %xmm3,(%rbx,%r12,8)
mov    0xb0(%rsp),%rbx
mov    %rsi,(%rbx,%r12,8)
mov    %r12,%rsi
imul   -0x68(%rsp),%rsi
mov    %rdi,%r13
mov    -0x60(%rsp),%rdi
mov    0x70(%rsp),%r15
movsd  0x8(%r8,%rsi,8),%xmm3
mulsd  %xmm3,%xmm3
movsd  (%rcx,%rsi,8),%xmm11
movsd  0x8(%rcx,%rsi,8),%xmm5
mulsd  %xmm11,%xmm11
addsd  (%r8,%rsi,8),%xmm5
addsd  %xmm3,%xmm11
mulsd  %xmm5,%xmm5
addsd  %xmm11,%xmm11
addsd  %xmm5,%xmm11
movsd  (%r15,%r12,8),%xmm3
mulsd  %xmm11,%xmm9
subsd  %xmm9,%xmm3
mov    0x108(%rsp),%rbp
movsd  %xmm3,0x0(%rbp,%r12,8)
xorpd  %xmm0,%xmm10
mulsd  %xmm11,%xmm10
mov    0x110(%rsp),%rbp
movsd  %xmm10,0x0(%rbp,%r12,8)
mulsd  %xmm11,%xmm13
movsd  0x9c5(%rip),%xmm3
subsd  %xmm13,%xmm3
mov    0x118(%rsp),%rbp
movsd  %xmm3,0x0(%rbp,%r12,8)
movsd  (%r15,%r12,8),%xmm6
movapd %xmm6,%xmm5
mulsd  %xmm12,%xmm5
mulsd  %xmm6,%xmm5
movsd  (%rax,%r12,8),%xmm7
movapd %xmm7,%xmm3
addsd  %xmm1,%xmm3
divsd  %xmm3,%xmm5
xorpd  %xmm9,%xmm9
ucomisd %xmm5,%xmm9
xorpd  %xmm8,%xmm8
ja     1220 <kEpsilon_2D_Evaluate+0x120>
movapd 0x10(%rsp),%xmm8
mulsd  %xmm6,%xmm8
divsd  %xmm3,%xmm8
jmp    1220 <kEpsilon_2D_Evaluate+0x120>
add    $0x38,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
define void @kEpsilon_2D_Evaluate(i32 %0, i32 %1, double %2, double %3, double %4, double %5, double %6, double %7, double %8, double* %9, double* %10, double* %11, double* %12, double* %13, double* %14, double* %15, double* %16, double* %17, double* %18, double* %19, double* %20, double* %21, double* %22, double* %23, double* %24, double* %25, double* %26, double* %27, double* %28, double* %29, double* %30, double* %31, double* %32, double* %33, double* %34, double* %35, double* %36, double* %37) {
%39 = alloca i32
%40 = alloca i32
%41 = alloca double
%42 = alloca double
%43 = alloca double
%44 = alloca double
%45 = alloca double
%46 = alloca double
%47 = alloca double
%48 = alloca double*
%49 = alloca double*
%50 = alloca double*
%51 = alloca double*
%52 = alloca double*
%53 = alloca double*
%54 = alloca double*
%55 = alloca double*
%56 = alloca double*
%57 = alloca double*
%58 = alloca double*
%59 = alloca double*
%60 = alloca double*
%61 = alloca double*
%62 = alloca double*
%63 = alloca double*
%64 = alloca double*
%65 = alloca double*
%66 = alloca double*
%67 = alloca double*
%68 = alloca double*
%69 = alloca double*
%70 = alloca double*
%71 = alloca double*
%72 = alloca double*
%73 = alloca double*
%74 = alloca double*
%75 = alloca double*
%76 = alloca double*
%77 = alloca i32
%78 = alloca i32
%79 = alloca double
%80 = alloca double
%81 = alloca double
%82 = alloca double
%83 = alloca double
%84 = alloca double
%85 = alloca double
%86 = alloca double
%87 = alloca double
%88 = alloca double
store i32 %0, i32* %39
store i32 %1, i32* %40
store double %2, double* %41
store double %3, double* %42
store double %4, double* %43
store double %5, double* %44
store double %6, double* %45
store double %7, double* %46
store double %8, double* %47
store double* %9, double** %48
store double* %10, double** %49
store double* %11, double** %50
store double* %12, double** %51
store double* %13, double** %52
store double* %14, double** %53
store double* %15, double** %54
store double* %16, double** %55
store double* %17, double** %56
store double* %18, double** %57
store double* %19, double** %58
store double* %20, double** %59
store double* %21, double** %60
store double* %22, double** %61
store double* %23, double** %62
store double* %24, double** %63
store double* %25, double** %64
store double* %26, double** %65
store double* %27, double** %66
store double* %28, double** %67
store double* %29, double** %68
store double* %30, double** %69
store double* %31, double** %70
store double* %32, double** %71
store double* %33, double** %72
store double* %34, double** %73
store double* %35, double** %74
store double* %36, double** %75
store double* %37, double** %76
store double 0x3EB0C6F7A0B5ED8D, double* %88
store i32 0, i32* %77
br label %89
89: ; preds = %638, %38
%90 = load i32, i32* %77
%91 = load i32, i32* %39
%92 = icmp slt i32 %90, %91
br i1 %92, label %93, label %641
93: ; preds = %89
%94 = load double*, double** %52
%95 = load i32, i32* %77
%96 = sext i32 %95 to i64
%97 = getelementptr inbounds double, double* %94, i64 %96
%98 = load double, double* %97
%99 = fcmp oge double %98, 0.000000e+00
br i1 %99, label %100, label %106
100: ; preds = %93
%101 = load double*, double** %52
%102 = load i32, i32* %77
%103 = sext i32 %102 to i64
%104 = getelementptr inbounds double, double* %101, i64 %103
%105 = load double, double* %104
br label %107
106: ; preds = %93
br label %107
107: ; preds = %106, %100
%108 = phi double [ %105, %100 ], [ 0.000000e+00, %106 ]
store double %108, double* %83
%109 = load double*, double** %51
%110 = load i32, i32* %77
%111 = sext i32 %110 to i64
%112 = getelementptr inbounds double, double* %109, i64 %111
%113 = load double, double* %112
%114 = fcmp oge double %113, 0.000000e+00
br i1 %114, label %115, label %121
115: ; preds = %107
%116 = load double*, double** %51
%117 = load i32, i32* %77
%118 = sext i32 %117 to i64
%119 = getelementptr inbounds double, double* %116, i64 %118
%120 = load double, double* %119
br label %122
121: ; preds = %107
br label %122
122: ; preds = %121, %115
%123 = phi double [ %120, %115 ], [ 0.000000e+00, %121 ]
store double %123, double* %84
%124 = load double, double* %45
%125 = load double*, double** %51
%126 = load i32, i32* %77
%127 = sext i32 %126 to i64
%128 = getelementptr inbounds double, double* %125, i64 %127
%129 = load double, double* %128
%130 = fmul double %124, %129
%131 = load double*, double** %51
%132 = load i32, i32* %77
%133 = sext i32 %132 to i64
%134 = getelementptr inbounds double, double* %131, i64 %133
%135 = load double, double* %134
%136 = fmul double %130, %135
%137 = load double*, double** %52
%138 = load i32, i32* %77
%139 = sext i32 %138 to i64
%140 = getelementptr inbounds double, double* %137, i64 %139
%141 = load double, double* %140
%142 = fadd double %141, 0x3EB0C6F7A0B5ED8D
%143 = fdiv double %136, %142
store double %143, double* %79
%144 = load double, double* %45
%145 = fmul double 2.000000e+00, %144
%146 = load double*, double** %51
%147 = load i32, i32* %77
%148 = sext i32 %147 to i64
%149 = getelementptr inbounds double, double* %146, i64 %148
%150 = load double, double* %149
%151 = fmul double %145, %150
%152 = load double*, double** %52
%153 = load i32, i32* %77
%154 = sext i32 %153 to i64
%155 = getelementptr inbounds double, double* %152, i64 %154
%156 = load double, double* %155
%157 = fadd double %156, 0x3EB0C6F7A0B5ED8D
%158 = fdiv double %151, %157
store double %158, double* %80
%159 = load double, double* %45
%160 = fneg double %159
%161 = load double*, double** %51
%162 = load i32, i32* %77
%163 = sext i32 %162 to i64
%164 = getelementptr inbounds double, double* %161, i64 %163
%165 = load double, double* %164
%166 = fmul double %160, %165
%167 = load double*, double** %51
%168 = load i32, i32* %77
%169 = sext i32 %168 to i64
%170 = getelementptr inbounds double, double* %167, i64 %169
%171 = load double, double* %170
%172 = fmul double %166, %171
%173 = load double*, double** %52
%174 = load i32, i32* %77
%175 = sext i32 %174 to i64
%176 = getelementptr inbounds double, double* %173, i64 %175
%177 = load double, double* %176
%178 = load double*, double** %52
%179 = load i32, i32* %77
%180 = sext i32 %179 to i64
%181 = getelementptr inbounds double, double* %178, i64 %180
%182 = load double, double* %181
%183 = call double @llvm.fmuladd.f64(double %177, double %182, double 0x3EB0C6F7A0B5ED8D)
%184 = fdiv double %172, %183
store double %184, double* %81
%185 = load double, double* %79
%186 = fcmp olt double %185, 0.000000e+00
br i1 %186, label %187, label %188
187: ; preds = %122
store double 0.000000e+00, double* %79
store double 0.000000e+00, double* %80
store double 0.000000e+00, double* %81
br label %188
188: ; preds = %187, %122
%189 = load double*, double** %51
%190 = load i32, i32* %77
%191 = sext i32 %190 to i64
%192 = getelementptr inbounds double, double* %189, i64 %191
%193 = load double, double* %192
%194 = load double*, double** %53
%195 = load i32, i32* %77
%196 = sext i32 %195 to i64
%197 = getelementptr inbounds double, double* %194, i64 %196
store double %193, double* %197
%198 = load double*, double** %54
%199 = load i32, i32* %77
%200 = sext i32 %199 to i64
%201 = getelementptr inbounds double, double* %198, i64 %200
store double 1.000000e+00, double* %201
%202 = load double*, double** %52
%203 = load i32, i32* %77
%204 = sext i32 %203 to i64
%205 = getelementptr inbounds double, double* %202, i64 %204
%206 = load double, double* %205
%207 = load double*, double** %55
%208 = load i32, i32* %77
%209 = sext i32 %208 to i64
%210 = getelementptr inbounds double, double* %207, i64 %209
store double %206, double* %210
%211 = load double*, double** %56
%212 = load i32, i32* %77
%213 = sext i32 %212 to i64
%214 = getelementptr inbounds double, double* %211, i64 %213
store double 1.000000e+00, double* %214
store i32 0, i32* %78
br label %215
215: ; preds = %300, %188
%216 = load i32, i32* %78
%217 = load i32, i32* %40
%218 = icmp slt i32 %216, %217
br i1 %218, label %219, label %303
219: ; preds = %215
%220 = load double*, double** %51
%221 = load i32, i32* %77
%222 = sext i32 %221 to i64
%223 = getelementptr inbounds double, double* %220, i64 %222
%224 = load double, double* %223
%225 = load double*, double** %48
%226 = load i32, i32* %77
%227 = load i32, i32* %40
%228 = mul nsw i32 %226, %227
%229 = load i32, i32* %78
%230 = add nsw i32 %228, %229
%231 = sext i32 %230 to i64
%232 = getelementptr inbounds double, double* %225, i64 %231
%233 = load double, double* %232
%234 = fmul double %224, %233
%235 = load double*, double** %61
%236 = load i32, i32* %77
%237 = load i32, i32* %40
%238 = mul nsw i32 %236, %237
%239 = load i32, i32* %78
%240 = add nsw i32 %238, %239
%241 = sext i32 %240 to i64
%242 = getelementptr inbounds double, double* %235, i64 %241
store double %234, double* %242
%243 = load double*, double** %48
%244 = load i32, i32* %77
%245 = load i32, i32* %40
%246 = mul nsw i32 %244, %245
%247 = load i32, i32* %78
%248 = add nsw i32 %246, %247
%249 = sext i32 %248 to i64
%250 = getelementptr inbounds double, double* %243, i64 %249
%251 = load double, double* %250
%252 = load double*, double** %62
%253 = load i32, i32* %77
%254 = load i32, i32* %40
%255 = mul nsw i32 %253, %254
%256 = load i32, i32* %78
%257 = add nsw i32 %255, %256
%258 = sext i32 %257 to i64
%259 = getelementptr inbounds double, double* %252, i64 %258
store double %251, double* %259
%260 = load double*, double** %52
%261 = load i32, i32* %77
%262 = sext i32 %261 to i64
%263 = getelementptr inbounds double, double* %260, i64 %262
%264 = load double, double* %263
%265 = load double*, double** %48
%266 = load i32, i32* %77
%267 = load i32, i32* %40
%268 = mul nsw i32 %266, %267
%269 = load i32, i32* %78
%270 = add nsw i32 %268, %269
%271 = sext i32 %270 to i64
%272 = getelementptr inbounds double, double* %265, i64 %271
%273 = load double, double* %272
%274 = fmul double %264, %273
%275 = load double*, double** %63
%276 = load i32, i32* %77
%277 = load i32, i32* %40
%278 = mul nsw i32 %276, %277
%279 = load i32, i32* %78
%280 = add nsw i32 %278, %279
%281 = sext i32 %280 to i64
%282 = getelementptr inbounds double, double* %275, i64 %281
store double %274, double* %282
%283 = load double*, double** %48
%284 = load i32, i32* %77
%285 = load i32, i32* %40
%286 = mul nsw i32 %284, %285
%287 = load i32, i32* %78
%288 = add nsw i32 %286, %287
%289 = sext i32 %288 to i64
%290 = getelementptr inbounds double, double* %283, i64 %289
%291 = load double, double* %290
%292 = load double*, double** %64
%293 = load i32, i32* %77
%294 = load i32, i32* %40
%295 = mul nsw i32 %293, %294
%296 = load i32, i32* %78
%297 = add nsw i32 %295, %296
%298 = sext i32 %297 to i64
%299 = getelementptr inbounds double, double* %292, i64 %298
store double %291, double* %299
br label %300
300: ; preds = %219
%301 = load i32, i32* %78
%302 = add nsw i32 %301, 1
store i32 %302, i32* %78
br label %215
303: ; preds = %215
%304 = load double*, double** %51
%305 = load i32, i32* %77
%306 = sext i32 %305 to i64
%307 = getelementptr inbounds double, double* %304, i64 %306
%308 = load double, double* %307
%309 = load double*, double** %57
%310 = load i32, i32* %77
%311 = sext i32 %310 to i64
%312 = getelementptr inbounds double, double* %309, i64 %311
store double %308, double* %312
%313 = load double*, double** %58
%314 = load i32, i32* %77
%315 = sext i32 %314 to i64
%316 = getelementptr inbounds double, double* %313, i64 %315
store double 1.000000e+00, double* %316
%317 = load double*, double** %52
%318 = load i32, i32* %77
%319 = sext i32 %318 to i64
%320 = getelementptr inbounds double, double* %317, i64 %319
%321 = load double, double* %320
%322 = load double*, double** %59
%323 = load i32, i32* %77
%324 = sext i32 %323 to i64
%325 = getelementptr inbounds double, double* %322, i64 %324
store double %321, double* %325
%326 = load double*, double** %60
%327 = load i32, i32* %77
%328 = sext i32 %327 to i64
%329 = getelementptr inbounds double, double* %326, i64 %328
store double 1.000000e+00, double* %329
store i32 0, i32* %78
br label %330
330: ; preds = %441, %303
%331 = load i32, i32* %78
%332 = load i32, i32* %40
%333 = icmp slt i32 %331, %332
br i1 %333, label %334, label %444
334: ; preds = %330
%335 = load double, double* %79
%336 = load double, double* %41
%337 = fdiv double %335, %336
%338 = load double, double* %47
%339 = fadd double %337, %338
%340 = load double*, double** %65
%341 = load i32, i32* %77
%342 = load i32, i32* %40
%343 = mul nsw i32 %341, %342
%344 = load i32, i32* %40
%345 = mul nsw i32 %343, %344
%346 = load i32, i32* %78
%347 = load i32, i32* %40
%348 = mul nsw i32 %346, %347
%349 = add nsw i32 %345, %348
%350 = load i32, i32* %78
%351 = add nsw i32 %349, %350
%352 = sext i32 %351 to i64
%353 = getelementptr inbounds double, double* %340, i64 %352
store double %339, double* %353
%354 = load double, double* %80
%355 = load double, double* %41
%356 = fdiv double %354, %355
%357 = load double*, double** %66
%358 = load i32, i32* %77
%359 = load i32, i32* %40
%360 = mul nsw i32 %358, %359
%361 = load i32, i32* %40
%362 = mul nsw i32 %360, %361
%363 = load i32, i32* %78
%364 = load i32, i32* %40
%365 = mul nsw i32 %363, %364
%366 = add nsw i32 %362, %365
%367 = load i32, i32* %78
%368 = add nsw i32 %366, %367
%369 = sext i32 %368 to i64
%370 = getelementptr inbounds double, double* %357, i64 %369
store double %356, double* %370
%371 = load double, double* %81
%372 = load double, double* %41
%373 = fdiv double %371, %372
%374 = load double*, double** %67
%375 = load i32, i32* %77
%376 = load i32, i32* %40
%377 = mul nsw i32 %375, %376
%378 = load i32, i32* %40
%379 = mul nsw i32 %377, %378
%380 = load i32, i32* %78
%381 = load i32, i32* %40
%382 = mul nsw i32 %380, %381
%383 = add nsw i32 %379, %382
%384 = load i32, i32* %78
%385 = add nsw i32 %383, %384
%386 = sext i32 %385 to i64
%387 = getelementptr inbounds double, double* %374, i64 %386
store double %373, double* %387
%388 = load double, double* %79
%389 = load double, double* %42
%390 = fdiv double %388, %389
%391 = load double, double* %47
%392 = fadd double %390, %391
%393 = load double*, double** %68
%394 = load i32, i32* %77
%395 = load i32, i32* %40
%396 = mul nsw i32 %394, %395
%397 = load i32, i32* %40
%398 = mul nsw i32 %396, %397
%399 = load i32, i32* %78
%400 = load i32, i32* %40
%401 = mul nsw i32 %399, %400
%402 = add nsw i32 %398, %401
%403 = load i32, i32* %78
%404 = add nsw i32 %402, %403
%405 = sext i32 %404 to i64
%406 = getelementptr inbounds double, double* %393, i64 %405
store double %392, double* %406
%407 = load double, double* %80
%408 = load double, double* %42
%409 = fdiv double %407, %408
%410 = load double*, double** %69
%411 = load i32, i32* %77
%412 = load i32, i32* %40
%413 = mul nsw i32 %411, %412
%414 = load i32, i32* %40
%415 = mul nsw i32 %413, %414
%416 = load i32, i32* %78
%417 = load i32, i32* %40
%418 = mul nsw i32 %416, %417
%419 = add nsw i32 %415, %418
%420 = load i32, i32* %78
%421 = add nsw i32 %419, %420
%422 = sext i32 %421 to i64
%423 = getelementptr inbounds double, double* %410, i64 %422
store double %409, double* %423
%424 = load double, double* %81
%425 = load double, double* %42
%426 = fdiv double %424, %425
%427 = load double*, double** %70
%428 = load i32, i32* %77
%429 = load i32, i32* %40
%430 = mul nsw i32 %428, %429
%431 = load i32, i32* %40
%432 = mul nsw i32 %430, %431
%433 = load i32, i32* %78
%434 = load i32, i32* %40
%435 = mul nsw i32 %433, %434
%436 = add nsw i32 %432, %435
%437 = load i32, i32* %78
%438 = add nsw i32 %436, %437
%439 = sext i32 %438 to i64
%440 = getelementptr inbounds double, double* %427, i64 %439
store double %426, double* %440
br label %441
441: ; preds = %334
%442 = load i32, i32* %78
%443 = add nsw i32 %442, 1
store i32 %443, i32* %78
br label %330
444: ; preds = %330
%445 = load double*, double** %49
%446 = load i32, i32* %77
%447 = load i32, i32* %40
%448 = mul nsw i32 %446, %447
%449 = add nsw i32 %448, 0
%450 = sext i32 %449 to i64
%451 = getelementptr inbounds double, double* %445, i64 %450
%452 = load double, double* %451
%453 = load double*, double** %49
%454 = load i32, i32* %77
%455 = load i32, i32* %40
%456 = mul nsw i32 %454, %455
%457 = add nsw i32 %456, 0
%458 = sext i32 %457 to i64
%459 = getelementptr inbounds double, double* %453, i64 %458
%460 = load double, double* %459
%461 = load double*, double** %50
%462 = load i32, i32* %77
%463 = load i32, i32* %40
%464 = mul nsw i32 %462, %463
%465 = add nsw i32 %464, 1
%466 = sext i32 %465 to i64
%467 = getelementptr inbounds double, double* %461, i64 %466
%468 = load double, double* %467
%469 = load double*, double** %50
%470 = load i32, i32* %77
%471 = load i32, i32* %40
%472 = mul nsw i32 %470, %471
%473 = add nsw i32 %472, 1
%474 = sext i32 %473 to i64
%475 = getelementptr inbounds double, double* %469, i64 %474
%476 = load double, double* %475
%477 = fmul double %468, %476
%478 = call double @llvm.fmuladd.f64(double %452, double %460, double %477)
%479 = load double*, double** %49
%480 = load i32, i32* %77
%481 = load i32, i32* %40
%482 = mul nsw i32 %480, %481
%483 = add nsw i32 %482, 1
%484 = sext i32 %483 to i64
%485 = getelementptr inbounds double, double* %479, i64 %484
%486 = load double, double* %485
%487 = load double*, double** %50
%488 = load i32, i32* %77
%489 = load i32, i32* %40
%490 = mul nsw i32 %488, %489
%491 = add nsw i32 %490, 0
%492 = sext i32 %491 to i64
%493 = getelementptr inbounds double, double* %487, i64 %492
%494 = load double, double* %493
%495 = fadd double %486, %494
%496 = load double*, double** %49
%497 = load i32, i32* %77
%498 = load i32, i32* %40
%499 = mul nsw i32 %497, %498
%500 = add nsw i32 %499, 1
%501 = sext i32 %500 to i64
%502 = getelementptr inbounds double, double* %496, i64 %501
%503 = load double, double* %502
%504 = load double*, double** %50
%505 = load i32, i32* %77
%506 = load i32, i32* %40
%507 = mul nsw i32 %505, %506
%508 = add nsw i32 %507, 0
%509 = sext i32 %508 to i64
%510 = getelementptr inbounds double, double* %504, i64 %509
%511 = load double, double* %510
%512 = fadd double %503, %511
%513 = fmul double %495, %512
%514 = call double @llvm.fmuladd.f64(double 2.000000e+00, double %478, double %513)
store double %514, double* %82
%515 = load double, double* %79
%516 = fneg double %515
%517 = load double, double* %82
%518 = load double*, double** %52
%519 = load i32, i32* %77
%520 = sext i32 %519 to i64
%521 = getelementptr inbounds double, double* %518, i64 %520
%522 = load double, double* %521
%523 = call double @llvm.fmuladd.f64(double %516, double %517, double %522)
%524 = load double*, double** %71
%525 = load i32, i32* %77
%526 = sext i32 %525 to i64
%527 = getelementptr inbounds double, double* %524, i64 %526
store double %523, double* %527
%528 = load double, double* %80
%529 = fneg double %528
%530 = load double, double* %82
%531 = fmul double %529, %530
%532 = load double*, double** %72
%533 = load i32, i32* %77
%534 = sext i32 %533 to i64
%535 = getelementptr inbounds double, double* %532, i64 %534
store double %531, double* %535
%536 = load double, double* %81
%537 = fneg double %536
%538 = load double, double* %82
%539 = call double @llvm.fmuladd.f64(double %537, double %538, double 1.000000e+00)
%540 = load double*, double** %73
%541 = load i32, i32* %77
%542 = sext i32 %541 to i64
%543 = getelementptr inbounds double, double* %540, i64 %542
store double %539, double* %543
%544 = load double, double* %44
%545 = load double*, double** %52
%546 = load i32, i32* %77
%547 = sext i32 %546 to i64
%548 = getelementptr inbounds double, double* %545, i64 %547
%549 = load double, double* %548
%550 = fmul double %544, %549
%551 = load double*, double** %52
%552 = load i32, i32* %77
%553 = sext i32 %552 to i64
%554 = getelementptr inbounds double, double* %551, i64 %553
%555 = load double, double* %554
%556 = fmul double %550, %555
%557 = load double*, double** %51
%558 = load i32, i32* %77
%559 = sext i32 %558 to i64
%560 = getelementptr inbounds double, double* %557, i64 %559
%561 = load double, double* %560
%562 = fadd double %561, 0x3EB0C6F7A0B5ED8D
%563 = fdiv double %556, %562
store double %563, double* %85
%564 = load double, double* %44
%565 = fneg double %564
%566 = load double*, double** %52
%567 = load i32, i32* %77
%568 = sext i32 %567 to i64
%569 = getelementptr inbounds double, double* %566, i64 %568
%570 = load double, double* %569
%571 = fmul double %565, %570
%572 = load double*, double** %52
%573 = load i32, i32* %77
%574 = sext i32 %573 to i64
%575 = getelementptr inbounds double, double* %572, i64 %574
%576 = load double, double* %575
%577 = fmul double %571, %576
%578 = load double*, double** %51
%579 = load i32, i32* %77
%580 = sext i32 %579 to i64
%581 = getelementptr inbounds double, double* %578, i64 %580
%582 = load double, double* %581
%583 = load double*, double** %51
%584 = load i32, i32* %77
%585 = sext i32 %584 to i64
%586 = getelementptr inbounds double, double* %583, i64 %585
%587 = load double, double* %586
%588 = call double @llvm.fmuladd.f64(double %582, double %587, double 0x3EB0C6F7A0B5ED8D)
%589 = fdiv double %577, %588
store double %589, double* %86
%590 = load double, double* %44
%591 = fmul double 2.000000e+00, %590
%592 = load double*, double** %52
%593 = load i32, i32* %77
%594 = sext i32 %593 to i64
%595 = getelementptr inbounds double, double* %592, i64 %594
%596 = load double, double* %595
%597 = fmul double %591, %596
%598 = load double*, double** %51
%599 = load i32, i32* %77
%600 = sext i32 %599 to i64
%601 = getelementptr inbounds double, double* %598, i64 %600
%602 = load double, double* %601
%603 = fadd double %602, 0x3EB0C6F7A0B5ED8D
%604 = fdiv double %597, %603
store double %604, double* %87
%605 = load double, double* %85
%606 = fcmp olt double %605, 0.000000e+00
br i1 %606, label %607, label %608
607: ; preds = %444
store double 0.000000e+00, double* %85
store double 0.000000e+00, double* %86
store double 0.000000e+00, double* %87
br label %608
608: ; preds = %607, %444
%609 = load double, double* %43
%610 = fneg double %609
%611 = load double*, double** %51
%612 = load i32, i32* %77
%613 = sext i32 %612 to i64
%614 = getelementptr inbounds double, double* %611, i64 %613
%615 = load double, double* %614
%616 = fmul double %610, %615
%617 = load double, double* %82
%618 = load double, double* %85
%619 = call double @llvm.fmuladd.f64(double %616, double %617, double %618)
%620 = load double*, double** %74
%621 = load i32, i32* %77
%622 = sext i32 %621 to i64
%623 = getelementptr inbounds double, double* %620, i64 %622
store double %619, double* %623
%624 = load double, double* %43
%625 = fneg double %624
%626 = load double, double* %82
%627 = load double, double* %86
%628 = call double @llvm.fmuladd.f64(double %625, double %626, double %627)
%629 = load double*, double** %75
%630 = load i32, i32* %77
%631 = sext i32 %630 to i64
%632 = getelementptr inbounds double, double* %629, i64 %631
store double %628, double* %632
%633 = load double, double* %87
%634 = load double*, double** %76
%635 = load i32, i32* %77
%636 = sext i32 %635 to i64
%637 = getelementptr inbounds double, double* %634, i64 %636
store double %633, double* %637
br label %638
638: ; preds = %608
%639 = load i32, i32* %77
%640 = add nsw i32 %639, 1
store i32 %640, i32* %77
br label %89
641: ; preds = %89
ret void
}

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