void calculateSubgridError_ADR_Sangalli_tau(
    int nElements_global, int nQuadraturePoints_element, int nSpace,
    double *inverseJ, double *dmt, double *df, double *a, double *da,
    double *grad_phi, double *dphi, double *dr, double *pe, double *cfl,
    double *tau, double *tau_gradient) {
  int eN, k, I, J, K, nSpace2 = nSpace * nSpace;
  double Vlin, Alin, A_II, cfl1, cfl2, Pe, Da, vlin[3], G_IJ, v_dot_Gv,
      CI_nu2_G_ddot_G, Gv_I, CI = 36.0 * 36.0, g_I, g_dot_g;
  double h_e, tau_00, tau_11, t_00, t_11, coshGamma;
  for (eN = 0; eN < nElements_global; eN++) {
    for (k = 0; k < nQuadraturePoints_element; k++) {
      Vlin = 0.0;
      Alin = 0.0;
      for (I = 0; I < nSpace; I++) {
        vlin[I] = df[eN * nQuadraturePoints_element * nSpace + k * nSpace + I];
        for (J = 0; J < nSpace; J++) {
          vlin[I] -= da[eN * nQuadraturePoints_element * nSpace2 + k * nSpace2 +
                        I * nSpace + J] *
                     grad_phi[eN * nQuadraturePoints_element * nSpace +
                              k * nSpace + J];
        }
      }
      v_dot_Gv = 0.0;
      CI_nu2_G_ddot_G = 0.0;
      g_dot_g = 0.0;
      for (I = 0; I < nSpace; I++) {
        Gv_I = 0.0;
        g_I = 0.0;
        for (J = 0; J < nSpace; J++) {
          G_IJ = 0.0;
          for (K = 0; K < nSpace; K++)
            G_IJ += inverseJ[eN * nQuadraturePoints_element * nSpace2 +
                             k * nSpace2 + K * nSpace + I] *
                    inverseJ[eN * nQuadraturePoints_element * nSpace2 +
                             k * nSpace2 + K * nSpace + J];
          Gv_I += G_IJ * vlin[J];
          CI_nu2_G_ddot_G += G_IJ * G_IJ;
          g_I += inverseJ[eN * nQuadraturePoints_element * nSpace2 +
                          k * nSpace2 + J * nSpace + I];
        }
        g_dot_g += g_I * g_I;
        v_dot_Gv += vlin[I] * Gv_I;
      }
      for (I = 0; I < nSpace; I++) {
        A_II = a[eN * nQuadraturePoints_element * nSpace2 + k * nSpace2 +
                 I * nSpace + I];
        Alin = (A_II > Alin) ? A_II : Alin;
      }
      Alin *= dphi[eN * nQuadraturePoints_element + k];
      CI_nu2_G_ddot_G *= CI * Alin * Alin;
      h_e = sqrt(g_dot_g);
      cfl1 = 0.5 * sqrt(v_dot_Gv);
      cfl2 = 0.25 * sqrt(CI_nu2_G_ddot_G);
      Pe = sqrt(v_dot_Gv) / sqrt(CI_nu2_G_ddot_G);
      Da = (dmt[eN * nQuadraturePoints_element + k] +
            dr[eN * nQuadraturePoints_element + k]) /
           (cfl1 + 1.0e-12);
      if (fabs(Da) < 1.0e-8) {
        tau_11 = 0.0;
        tau_00 = 1.0 / sqrt(v_dot_Gv + CI_nu2_G_ddot_G + +1.0e-8);
      } else if (Da > Pe * 10.0) {
        tau_00 = 0.5 / dmt[eN * nQuadraturePoints_element + k];
        tau_11 = h_e * h_e / (12.0 * dmt[eN * nQuadraturePoints_element + k]);
      } else if (cfl1 < 1.0e-8) {
        if (Pe * (2.0 * Da + Pe) < 0.0)
          coshGamma = cos(sqrt(Pe * (-2.0 * Da - Pe)));
        else if (Pe * (2.0 * Da + Pe) > 1000.0)
          coshGamma = cosh(100.0);
        else
          coshGamma = cosh(sqrt(Pe * (2.0 * Da + Pe)));
        tau_00 = -1.0 / dmt[eN * nQuadraturePoints_element + k] * 1.0 /
                 (-2.0 - Pe * Da / (coshGamma - 1.0 - 2.0 * Pe * Da) + 1.0e-8);
        tau_11 = -h_e * h_e / (dmt[eN * nQuadraturePoints_element + k] * 6.0) *
                 (-1.0 - 6.0 / (2.0 * Pe * Da) + 3.0 * coshGamma -
                  Pe * Da / (-2.0 + 2.0 * coshGamma - Pe * Da));
      } else {
        t_00 = fmin(Pe / 6.0, fmin(0.5 / Da, 0.5));
        t_11 = fmin(Pe / 60.0, fmin(-1.0 / (12.0 * Da), 1.0 / 24.0));
        t_11 *= -1.0;
        tau_00 = t_00 / cfl1;
        tau_11 = t_11 / cfl1 / (h_e * h_e);
      }
      assert(tau_11 <= 0.0);
      assert(tau_00 >= 0.0);
      tau[eN * nQuadraturePoints_element + k] = tau_00;
      tau_gradient[eN * nQuadraturePoints_element + k] = tau_11;
      if (cfl1 > cfl2)
        cfl[eN * nQuadraturePoints_element + k] = cfl1;
      else
        cfl[eN * nQuadraturePoints_element + k] = cfl2;
      pe[eN * nQuadraturePoints_element + k] =
          sqrt(v_dot_Gv) / sqrt(CI_nu2_G_ddot_G);
    }
  }
}


x86 assembly (clang, -O0):
<calculateSubgridError_ADR_Sangalli_tau>:
push   %rbp
mov    %rsp,%rbp
sub    $0x110,%rsp
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)
mov    %edx,-0xc(%rbp)
mov    %rcx,-0x18(%rbp)
mov    %r8,-0x20(%rbp)
mov    %r9,-0x28(%rbp)
mov    -0xc(%rbp),%eax
imul   -0xc(%rbp),%eax
mov    %eax,-0x40(%rbp)
movsd  0xe6a(%rip),%xmm0
movsd  %xmm0,-0xb8(%rbp)
ff
movl   $0x0,-0x2c(%rbp)
mov    -0x2c(%rbp),%eax
cmp    -0x4(%rbp),%eax
jge    1c14 <calculateSubgridError_ADR_Sangalli_tau+0xad4>
movl   $0x0,-0x30(%rbp)
mov    -0x30(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    1c01 <calculateSubgridError_ADR_Sangalli_tau+0xac1>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x48(%rbp)
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x50(%rbp)
movl   $0x0,-0x34(%rbp)
mov    -0x34(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    12cf <calculateSubgridError_ADR_Sangalli_tau+0x18f>
mov    -0x28(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0xc(%rbp),%ecx
mov    -0x30(%rbp),%edx
imul   -0xc(%rbp),%edx
add    %edx,%ecx
add    -0x34(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
movslq -0x34(%rbp),%rax
movsd  %xmm0,-0x90(%rbp,%rax,8)
ff ff
movl   $0x0,-0x38(%rbp)
mov    -0x38(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    12bc <calculateSubgridError_ADR_Sangalli_tau+0x17c>
mov    0x18(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0x40(%rbp),%ecx
mov    -0x30(%rbp),%edx
imul   -0x40(%rbp),%edx
add    %edx,%ecx
mov    -0x34(%rbp),%edx
imul   -0xc(%rbp),%edx
add    %edx,%ecx
add    -0x38(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x20(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0xc(%rbp),%ecx
mov    -0x30(%rbp),%edx
imul   -0xc(%rbp),%edx
add    %edx,%ecx
add    -0x38(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm2
movslq -0x34(%rbp),%rax
movsd  -0x90(%rbp,%rax,8),%xmm1
ff ff
movq   %xmm0,%rcx
movabs $0x8000000000000000,%rdx
xor    %rdx,%rcx
movq   %rcx,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x90(%rbp,%rax,8)
ff ff
mov    -0x38(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x38(%rbp)
jmp    121e <calculateSubgridError_ADR_Sangalli_tau+0xde>
jmp    12c1 <calculateSubgridError_ADR_Sangalli_tau+0x181>
mov    -0x34(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x34(%rbp)
jmp    11db <calculateSubgridError_ADR_Sangalli_tau+0x9b>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xa0(%rbp)
ff
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xa8(%rbp)
ff
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xc8(%rbp)
ff
movl   $0x0,-0x34(%rbp)
mov    -0x34(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    14ca <calculateSubgridError_ADR_Sangalli_tau+0x38a>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xb0(%rbp)
ff
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xc0(%rbp)
ff
movl   $0x0,-0x38(%rbp)
mov    -0x38(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    1467 <calculateSubgridError_ADR_Sangalli_tau+0x327>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x98(%rbp)
ff
movl   $0x0,-0x3c(%rbp)
mov    -0x3c(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    13c8 <calculateSubgridError_ADR_Sangalli_tau+0x288>
mov    -0x18(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0x40(%rbp),%ecx
mov    -0x30(%rbp),%edx
imul   -0x40(%rbp),%edx
add    %edx,%ecx
mov    -0x3c(%rbp),%edx
imul   -0xc(%rbp),%edx
add    %edx,%ecx
add    -0x34(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x18(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0x40(%rbp),%ecx
mov    -0x30(%rbp),%edx
imul   -0x40(%rbp),%edx
add    %edx,%ecx
mov    -0x3c(%rbp),%edx
imul   -0xc(%rbp),%edx
add    %edx,%ecx
add    -0x38(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm2
movsd  -0x98(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x98(%rbp)
ff
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
jmp    133e <calculateSubgridError_ADR_Sangalli_tau+0x1fe>
movsd  -0x98(%rbp),%xmm0
ff
movslq -0x38(%rbp),%rax
movsd  -0x90(%rbp,%rax,8),%xmm2
ff ff
movsd  -0xb0(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xb0(%rbp)
ff
movsd  -0x98(%rbp),%xmm0
ff
movsd  -0x98(%rbp),%xmm2
ff
movsd  -0xa8(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xa8(%rbp)
ff
mov    -0x18(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0x40(%rbp),%ecx
mov    -0x30(%rbp),%edx
imul   -0x40(%rbp),%edx
add    %edx,%ecx
mov    -0x38(%rbp),%edx
imul   -0xc(%rbp),%edx
add    %edx,%ecx
add    -0x34(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
addsd  -0xc0(%rbp),%xmm0
ff
movsd  %xmm0,-0xc0(%rbp)
ff
mov    -0x38(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x38(%rbp)
jmp    1320 <calculateSubgridError_ADR_Sangalli_tau+0x1e0>
movsd  -0xc0(%rbp),%xmm0
ff
movsd  -0xc0(%rbp),%xmm2
ff
movsd  -0xc8(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xc8(%rbp)
ff
movslq -0x34(%rbp),%rax
movsd  -0x90(%rbp,%rax,8),%xmm0
ff ff
movsd  -0xb0(%rbp),%xmm2
ff
movsd  -0xa0(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xa0(%rbp)
ff
mov    -0x34(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x34(%rbp)
jmp    12f7 <calculateSubgridError_ADR_Sangalli_tau+0x1b7>
movl   $0x0,-0x34(%rbp)
mov    -0x34(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    1558 <calculateSubgridError_ADR_Sangalli_tau+0x418>
mov    0x10(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0x40(%rbp),%ecx
mov    -0x30(%rbp),%edx
imul   -0x40(%rbp),%edx
add    %edx,%ecx
mov    -0x34(%rbp),%edx
imul   -0xc(%rbp),%edx
add    %edx,%ecx
add    -0x34(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0x58(%rbp)
movsd  -0x58(%rbp),%xmm0
ucomisd -0x50(%rbp),%xmm0
jbe    1530 <calculateSubgridError_ADR_Sangalli_tau+0x3f0>
movsd  -0x58(%rbp),%xmm0
movsd  %xmm0,-0x100(%rbp)
ff
jmp    153d <calculateSubgridError_ADR_Sangalli_tau+0x3fd>
movsd  -0x50(%rbp),%xmm0
movsd  %xmm0,-0x100(%rbp)
ff
movsd  -0x100(%rbp),%xmm0
ff
movsd  %xmm0,-0x50(%rbp)
mov    -0x34(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x34(%rbp)
jmp    14d1 <calculateSubgridError_ADR_Sangalli_tau+0x391>
mov    0x28(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mulsd  -0x50(%rbp),%xmm0
movsd  %xmm0,-0x50(%rbp)
movsd  -0xb8(%rbp),%xmm0
ff
mulsd  -0x50(%rbp),%xmm0
mulsd  -0x50(%rbp),%xmm0
mulsd  -0xa8(%rbp),%xmm0
ff
movsd  %xmm0,-0xa8(%rbp)
ff
movsd  -0xc8(%rbp),%xmm0
ff
call   1060 <sqrt@plt>
movsd  %xmm0,-0xd0(%rbp)
ff
movsd  -0xa0(%rbp),%xmm0
ff
call   1060 <sqrt@plt>
movaps %xmm0,%xmm1
movsd  0xa59(%rip),%xmm0
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x60(%rbp)
movsd  -0xa8(%rbp),%xmm0
ff
call   1060 <sqrt@plt>
movaps %xmm0,%xmm1
movsd  0xa30(%rip),%xmm0
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x68(%rbp)
movsd  -0xa0(%rbp),%xmm0
ff
call   1060 <sqrt@plt>
movsd  %xmm0,-0x108(%rbp)
ff
movsd  -0xa8(%rbp),%xmm0
ff
call   1060 <sqrt@plt>
movaps %xmm0,%xmm1
movsd  -0x108(%rbp),%xmm0
ff
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x70(%rbp)
mov    -0x20(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x30(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
addsd  (%rax,%rcx,8),%xmm0
movsd  0x9b5(%rip),%xmm1
addsd  -0x60(%rbp),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x78(%rbp)
movsd  -0x78(%rbp),%xmm1
movaps 0xa1b(%rip),%xmm0
pand   %xmm0,%xmm1
movsd  0x987(%rip),%xmm0
ucomisd %xmm1,%xmm0
jbe    16d3 <calculateSubgridError_ADR_Sangalli_tau+0x593>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xe0(%rbp)
ff
movsd  -0xa0(%rbp),%xmm0
ff
addsd  -0xa8(%rbp),%xmm0
ff
movsd  0x95a(%rip),%xmm1
addsd  %xmm1,%xmm0
call   1060 <sqrt@plt>
movaps %xmm0,%xmm1
movsd  0x9be(%rip),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xd8(%rbp)
ff
jmp    1aed <calculateSubgridError_ADR_Sangalli_tau+0x9ad>
movsd  -0x78(%rbp),%xmm0
movsd  0x948(%rip),%xmm1
mulsd  -0x70(%rbp),%xmm1
ucomisd %xmm1,%xmm0
jbe    1754 <calculateSubgridError_ADR_Sangalli_tau+0x614>
mov    -0x20(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  0x918(%rip),%xmm0
divsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0xd8(%rbp)
ff
movsd  -0xd0(%rbp),%xmm0
ff
mulsd  -0xd0(%rbp),%xmm0
ff
mov    -0x20(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  0x902(%rip),%xmm1
mulsd  (%rax,%rcx,8),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xe0(%rbp)
ff
jmp    1ae8 <calculateSubgridError_ADR_Sangalli_tau+0x9a8>
movsd  0x8ac(%rip),%xmm0
ucomisd -0x60(%rbp),%xmm0
jbe    19e1 <calculateSubgridError_ADR_Sangalli_tau+0x8a1>
movsd  -0x70(%rbp),%xmm1
movsd  -0x78(%rbp),%xmm0
movsd  -0x70(%rbp),%xmm2
addsd  %xmm0,%xmm0
addsd  %xmm2,%xmm0
mulsd  %xmm0,%xmm1
xorps  %xmm0,%xmm0
ucomisd %xmm1,%xmm0
jbe    17d8 <calculateSubgridError_ADR_Sangalli_tau+0x698>
movsd  -0x70(%rbp),%xmm0
movsd  -0x78(%rbp),%xmm2
movsd  -0x70(%rbp),%xmm1
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
addsd  %xmm2,%xmm2
subsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
call   1060 <sqrt@plt>
call   1050 <cos@plt>
movsd  %xmm0,-0xf8(%rbp)
ff
jmp    1851 <calculateSubgridError_ADR_Sangalli_tau+0x711>
movsd  -0x70(%rbp),%xmm0
movsd  -0x78(%rbp),%xmm1
movsd  -0x70(%rbp),%xmm2
addsd  %xmm1,%xmm1
addsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
movsd  0x85d(%rip),%xmm1
ucomisd %xmm1,%xmm0
jbe    181f <calculateSubgridError_ADR_Sangalli_tau+0x6df>
movsd  0x853(%rip),%xmm0
call   1030 <cosh@plt>
movsd  %xmm0,-0xf8(%rbp)
ff
jmp    184c <calculateSubgridError_ADR_Sangalli_tau+0x70c>
movsd  -0x70(%rbp),%xmm0
movsd  -0x78(%rbp),%xmm1
movsd  -0x70(%rbp),%xmm2
addsd  %xmm1,%xmm1
addsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
call   1060 <sqrt@plt>
call   1030 <cosh@plt>
movsd  %xmm0,-0xf8(%rbp)
ff
jmp    1851 <calculateSubgridError_ADR_Sangalli_tau+0x711>
mov    -0x20(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  0x7c6(%rip),%xmm0
divsd  (%rax,%rcx,8),%xmm0
movsd  0x809(%rip),%xmm1
mulsd  %xmm1,%xmm0
movsd  -0x70(%rbp),%xmm2
mulsd  -0x78(%rbp),%xmm2
movsd  -0xf8(%rbp),%xmm3
ff
movsd  0x7eb(%rip),%xmm1
subsd  %xmm1,%xmm3
movsd  0x7d7(%rip),%xmm1
mulsd  -0x70(%rbp),%xmm1
movsd  -0x78(%rbp),%xmm4
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm4,%xmm1
addsd  %xmm3,%xmm1
divsd  %xmm1,%xmm2
movsd  0x792(%rip),%xmm1
subsd  %xmm2,%xmm1
movsd  0x726(%rip),%xmm2
addsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xd8(%rbp)
ff
movsd  -0xd0(%rbp),%xmm0
ff
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  -0xd0(%rbp),%xmm0
ff
mov    -0x20(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  0x71e(%rip),%xmm1
mulsd  (%rax,%rcx,8),%xmm1
divsd  %xmm1,%xmm0
movsd  0x735(%rip),%xmm2
mulsd  -0x70(%rbp),%xmm2
mulsd  -0x78(%rbp),%xmm2
movsd  0x6fb(%rip),%xmm1
divsd  %xmm2,%xmm1
movsd  0x6cf(%rip),%xmm2
subsd  %xmm1,%xmm2
movsd  -0xf8(%rbp),%xmm1
ff
movsd  0x6fb(%rip),%xmm3
mulsd  %xmm3,%xmm1
addsd  %xmm2,%xmm1
movsd  -0x70(%rbp),%xmm2
mulsd  -0x78(%rbp),%xmm2
movsd  -0xf8(%rbp),%xmm4
ff
addsd  %xmm4,%xmm4
movsd  0x6cd(%rip),%xmm3
addsd  %xmm3,%xmm4
movsd  -0x70(%rbp),%xmm3
movsd  -0x78(%rbp),%xmm5
movq   %xmm3,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm3
mulsd  %xmm5,%xmm3
addsd  %xmm4,%xmm3
divsd  %xmm3,%xmm2
subsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0xe0(%rbp)
ff
jmp    1ae3 <calculateSubgridError_ADR_Sangalli_tau+0x9a3>
movsd  -0x70(%rbp),%xmm3
movsd  0x662(%rip),%xmm0
divsd  %xmm0,%xmm3
movsd  0x626(%rip),%xmm2
divsd  -0x78(%rbp),%xmm2
movsd  0x619(%rip),%xmm0
minsd  %xmm0,%xmm2
movaps %xmm2,%xmm4
movaps %xmm3,%xmm0
cmpunordsd %xmm0,%xmm0
movaps %xmm0,%xmm1
pand   %xmm4,%xmm1
minsd  %xmm3,%xmm2
pandn  %xmm2,%xmm0
por    %xmm1,%xmm0
movsd  %xmm0,-0xe8(%rbp)
ff
movsd  -0x70(%rbp),%xmm3
movsd  0x60a(%rip),%xmm0
divsd  %xmm0,%xmm3
movsd  0x5f6(%rip),%xmm0
mulsd  -0x78(%rbp),%xmm0
movsd  0x5d9(%rip),%xmm2
divsd  %xmm0,%xmm2
movsd  0x5d5(%rip),%xmm0
minsd  %xmm0,%xmm2
movaps %xmm2,%xmm4
movaps %xmm3,%xmm0
cmpunordsd %xmm0,%xmm0
movaps %xmm0,%xmm1
pand   %xmm4,%xmm1
minsd  %xmm3,%xmm2
pandn  %xmm2,%xmm0
por    %xmm1,%xmm0
movsd  %xmm0,-0xf0(%rbp)
ff
movsd  0x59b(%rip),%xmm0
mulsd  -0xf0(%rbp),%xmm0
ff
movsd  %xmm0,-0xf0(%rbp)
ff
movsd  -0xe8(%rbp),%xmm0
ff
divsd  -0x60(%rbp),%xmm0
movsd  %xmm0,-0xd8(%rbp)
ff
movsd  -0xf0(%rbp),%xmm0
ff
divsd  -0x60(%rbp),%xmm0
movsd  -0xd0(%rbp),%xmm1
ff
mulsd  -0xd0(%rbp),%xmm1
ff
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xe0(%rbp)
ff
jmp    1ae8 <calculateSubgridError_ADR_Sangalli_tau+0x9a8>
jmp    1aed <calculateSubgridError_ADR_Sangalli_tau+0x9ad>
xorps  %xmm0,%xmm0
ucomisd -0xe0(%rbp),%xmm0
ff
setae  %al
and    $0x1,%al
movzbl %al,%edi
mov    $0x0,%al
call   1040 <assert@plt>
movsd  -0xd8(%rbp),%xmm0
ff
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
setae  %al
and    $0x1,%al
movzbl %al,%edi
mov    $0x0,%al
call   1040 <assert@plt>
movsd  -0xd8(%rbp),%xmm0
ff
mov    0x48(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0xe0(%rbp),%xmm0
ff
mov    0x50(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0x60(%rbp),%xmm0
ucomisd -0x68(%rbp),%xmm0
jbe    1b91 <calculateSubgridError_ADR_Sangalli_tau+0xa51>
movsd  -0x60(%rbp),%xmm0
mov    0x40(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
jmp    1bac <calculateSubgridError_ADR_Sangalli_tau+0xa6c>
movsd  -0x68(%rbp),%xmm0
mov    0x40(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0xa0(%rbp),%xmm0
ff
call   1060 <sqrt@plt>
movsd  %xmm0,-0x110(%rbp)
ff
movsd  -0xa8(%rbp),%xmm0
ff
call   1060 <sqrt@plt>
movaps %xmm0,%xmm1
movsd  -0x110(%rbp),%xmm0
ff
divsd  %xmm1,%xmm0
mov    0x38(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x30(%rbp)
jmp    11b8 <calculateSubgridError_ADR_Sangalli_tau+0x78>
jmp    1c06 <calculateSubgridError_ADR_Sangalli_tau+0xac6>
mov    -0x2c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x2c(%rbp)
jmp    11a5 <calculateSubgridError_ADR_Sangalli_tau+0x65>
add    $0x110,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<calculateSubgridError_ADR_Sangalli_tau>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x128,%rsp
mov    %r8,0xb8(%rsp)
mov    %esi,0x2c(%rsp)
test   %edi,%edi
jle    1c17 <calculateSubgridError_ADR_Sangalli_tau+0xad7>
mov    %rcx,%r15
mov    %edx,%ebx
mov    0x170(%rsp),%r8
mov    %edx,%ebp
imul   %ebx,%ebp
movslq %edx,%rcx
mov    %edi,%eax
mov    %rax,0xe8(%rsp)
mov    %ecx,%r13d
mov    %r13d,%r12d
and    $0xfffffffe,%r12d
mov    %ebp,%edx
mov    0x2c(%rsp),%eax
imul   %eax,%edx
mov    %edx,0x98(%rsp)
mov    %ebx,%edx
imul   %eax,%edx
mov    %edx,0x94(%rsp)
mov    %rcx,%r14
shl    $0x4,%r14
xorpd  %xmm11,%xmm11
mov    0x168(%rsp),%r11
cltq
mov    %rax,0xe0(%rsp)
mov    %eax,%eax
mov    %rax,0x100(%rsp)
lea    -0x1(%r13),%rax
mov    %rax,0x88(%rsp)
lea    0x8(%r11),%rax
mov    %rax,0xf8(%rsp)
lea    0x0(,%rcx,8),%rax
mov    %rax,0xc0(%rsp)
lea    0x8(%r8),%rax
mov    %rax,0xf0(%rsp)
lea    0x1(%rcx),%eax
mov    %eax,0x34(%rsp)
mov    %rcx,0xc8(%rsp)
lea    0x2(%rcx,%rcx,1),%eax
mov    %eax,0x9c(%rsp)
movl   $0x0,0x10(%rsp)
movl   $0x0,0x30(%rsp)
xor    %eax,%eax
mov    %rax,0x80(%rsp)
mov    %r9,0xb0(%rsp)
mov    %ebp,0xc(%rsp)
jmp    1293 <calculateSubgridError_ADR_Sangalli_tau+0x153>
nopl   0x0(%rax,%rax,1)
mov    0x80(%rsp),%rdx
add    $0x1,%rdx
mov    0x98(%rsp),%eax
add    %eax,0x30(%rsp)
mov    0x10(%rsp),%ecx
add    0x94(%rsp),%ecx
mov    %ecx,0x10(%rsp)
add    %eax,0x34(%rsp)
mov    %rdx,%rax
mov    %rdx,0x80(%rsp)
cmp    0xe8(%rsp),%rdx
je     1c17 <calculateSubgridError_ADR_Sangalli_tau+0xad7>
cmpl   $0x0,0x2c(%rsp)
jle    1250 <calculateSubgridError_ADR_Sangalli_tau+0x110>
mov    0x80(%rsp),%rax
imul   0xe0(%rsp),%rax
mov    %rax,0x58(%rsp)
mov    0x34(%rsp),%eax
mov    %eax,0x38(%rsp)
mov    0x10(%rsp),%edx
mov    0x30(%rsp),%ecx
xor    %eax,%eax
mov    %rax,0x20(%rsp)
jmp    1340 <calculateSubgridError_ADR_Sangalli_tau+0x200>
nopl   0x0(%rax)
movsd  %xmm1,(%rsp)
call   1060 <sqrt@plt>
movsd  (%rsp),%xmm1
xorpd  %xmm11,%xmm11
mov    0xb0(%rsp),%r9
mov    0x170(%rsp),%r8
mov    0x168(%rsp),%r11
mov    0x3c(%rsp),%edx
mov    0x14(%rsp),%ecx
divsd  %xmm0,%xmm1
mov    0x188(%rsp),%rax
movsd  %xmm1,(%rax,%rbp,8)
mov    0x20(%rsp),%rsi
add    $0x1,%rsi
mov    0xc(%rsp),%ebp
add    %ebp,%ecx
add    %ebx,%edx
add    %ebp,0x38(%rsp)
mov    %rsi,%rax
mov    %rsi,0x20(%rsp)
cmp    0x100(%rsp),%rsi
je     1250 <calculateSubgridError_ADR_Sangalli_tau+0x110>
xorpd  %xmm5,%xmm5
xorpd  %xmm4,%xmm4
test   %ebx,%ebx
mov    %edx,0x3c(%rsp)
mov    %ecx,0x14(%rsp)
jle    1670 <calculateSubgridError_ADR_Sangalli_tau+0x530>
movslq %ecx,%rax
lea    0x0(,%rax,8),%rcx
mov    %rcx,(%rsp)
mov    0xc0(%rsp),%rcx
lea    (%rcx,%rax,8),%rcx
mov    %rcx,0x40(%rsp)
mov    0xf8(%rsp),%rcx
lea    (%rcx,%rax,8),%rax
movslq %edx,%rcx
mov    0xf0(%rsp),%rdx
lea    (%rdx,%rcx,8),%rcx
mov    0x58(%rsp),%rdx
mov    0x20(%rsp),%rsi
add    %edx,%esi
mov    %esi,%edx
mov    %ebx,%r10d
imul   %ebx,%edx
imul   %ebp,%esi
movslq %edx,%rdx
movslq %esi,%rsi
xor    %ebx,%ebx
jmp    13de <calculateSubgridError_ADR_Sangalli_tau+0x29e>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
movsd  %xmm0,0x110(%rsp,%rbx,8)
add    $0x1,%rbx
add    0xc0(%rsp),%rax
cmp    %r13,%rbx
je     1470 <calculateSubgridError_ADR_Sangalli_tau+0x330>
lea    (%rbx,%rdx,1),%rbp
movsd  (%r9,%rbp,8),%xmm0
cmpq   $0x0,0x88(%rsp)
je     1430 <calculateSubgridError_ADR_Sangalli_tau+0x2f0>
xor    %ebp,%ebp
cs nopw 0x0(%rax,%rax,1)
nop
movsd  -0x8(%rax,%rbp,8),%xmm1
movsd  (%rax,%rbp,8),%xmm2
mulsd  -0x8(%rcx,%rbp,8),%xmm1
mulsd  (%rcx,%rbp,8),%xmm2
subsd  %xmm1,%xmm0
subsd  %xmm2,%xmm0
add    $0x2,%rbp
cmp    %rbp,%r12
jne    1400 <calculateSubgridError_ADR_Sangalli_tau+0x2c0>
test   $0x1,%r13b
je     13c0 <calculateSubgridError_ADR_Sangalli_tau+0x280>
jmp    1438 <calculateSubgridError_ADR_Sangalli_tau+0x2f8>
nop
xor    %ebp,%ebp
test   $0x1,%r13b
je     13c0 <calculateSubgridError_ADR_Sangalli_tau+0x280>
mov    %rbx,%rdi
imul   0xc8(%rsp),%rdi
add    %rsi,%rdi
add    %rbp,%rdi
movsd  (%r11,%rdi,8),%xmm1
add    %rdx,%rbp
mulsd  (%r8,%rbp,8),%xmm1
subsd  %xmm1,%xmm0
jmp    13c0 <calculateSubgridError_ADR_Sangalli_tau+0x280>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
xorpd  %xmm1,%xmm1
mov    %r10d,%ebx
test   %r10d,%r10d
mov    0xc(%rsp),%ebp
jle    1674 <calculateSubgridError_ADR_Sangalli_tau+0x534>
mov    0x58(%rsp),%rax
mov    0x20(%rsp),%rcx
add    %ecx,%eax
imul   %ebp,%eax
mov    %rax,0x70(%rsp)
movslq %eax,%r11
xorpd  %xmm1,%xmm1
xorpd  %xmm4,%xmm4
mov    (%rsp),%rdi
mov    0x40(%rsp),%rcx
xor    %eax,%eax
jmp    14e2 <calculateSubgridError_ADR_Sangalli_tau+0x3a2>
movapd %xmm5,%xmm2
movhpd 0x110(%rsp,%rax,8),%xmm2
unpcklpd %xmm1,%xmm5
mulpd  %xmm2,%xmm5
movapd %xmm5,%xmm1
addpd  %xmm0,%xmm1
add    $0x1,%rax
add    $0x8,%rcx
add    $0x8,%rdi
cmp    %r13,%rax
je     15f0 <calculateSubgridError_ADR_Sangalli_tau+0x4b0>
movapd %xmm1,%xmm0
mov    0x70(%rsp),%rdx
add    %eax,%edx
mov    (%rsp),%rbp
mov    0x40(%rsp),%rsi
xor    %r8d,%r8d
xorpd  %xmm5,%xmm5
xorpd  %xmm1,%xmm1
jmp    1551 <calculateSubgridError_ADR_Sangalli_tau+0x411>
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
movsd  0x110(%rsp,%r8,8),%xmm3
mulsd  %xmm2,%xmm3
addsd  %xmm3,%xmm1
mulsd  %xmm2,%xmm2
addsd  %xmm2,%xmm4
mov    %r8d,%ebx
imul   %r10d,%ebx
add    %edx,%ebx
movslq %ebx,%rbx
addsd  (%r15,%rbx,8),%xmm5
add    $0x1,%r8
add    $0x8,%rsi
add    $0x8,%rbp
cmp    %r13,%r8
je     14b0 <calculateSubgridError_ADR_Sangalli_tau+0x370>
cmpq   $0x0,0x88(%rsp)
je     15b0 <calculateSubgridError_ADR_Sangalli_tau+0x470>
xorpd  %xmm2,%xmm2
mov    %r15,%rbx
xor    %r9d,%r9d
cs nopw 0x0(%rax,%rax,1)
movsd  (%rbx,%rdi,1),%xmm3
mulsd  (%rbx,%rbp,1),%xmm3
addsd  %xmm2,%xmm3
movsd  (%rbx,%rcx,1),%xmm2
mulsd  (%rbx,%rsi,1),%xmm2
addsd  %xmm3,%xmm2
add    $0x2,%r9
add    %r14,%rbx
cmp    %r9,%r12
jne    1570 <calculateSubgridError_ADR_Sangalli_tau+0x430>
test   $0x1,%r13b
je     1510 <calculateSubgridError_ADR_Sangalli_tau+0x3d0>
jmp    15c1 <calculateSubgridError_ADR_Sangalli_tau+0x481>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
xorpd  %xmm2,%xmm2
xor    %r9d,%r9d
test   $0x1,%r13b
je     1510 <calculateSubgridError_ADR_Sangalli_tau+0x3d0>
imul   0xc8(%rsp),%r9
add    %r11,%r9
lea    (%r9,%rax,1),%rbx
movsd  (%r15,%rbx,8),%xmm3
add    %r8,%r9
mulsd  (%r15,%r9,8),%xmm3
addsd  %xmm3,%xmm2
jmp    1510 <calculateSubgridError_ADR_Sangalli_tau+0x3d0>
nopl   0x0(%rax)
addpd  %xmm0,%xmm5
mov    %r10d,%ebx
test   %r10d,%r10d
jle    1670 <calculateSubgridError_ADR_Sangalli_tau+0x530>
cmpq   $0x0,0x88(%rsp)
je     19b9 <calculateSubgridError_ADR_Sangalli_tau+0x879>
xorpd  %xmm1,%xmm1
mov    0x14(%rsp),%eax
mov    %eax,%ecx
mov    0x38(%rsp),%eax
mov    %eax,%edx
xor    %eax,%eax
mov    0xc(%rsp),%ebp
mov    0x160(%rsp),%rsi
mov    0x9c(%rsp),%edi
movslq %ecx,%rcx
movsd  (%rsi,%rcx,8),%xmm0
maxsd  %xmm1,%xmm0
movslq %edx,%rdx
movsd  (%rsi,%rdx,8),%xmm1
maxsd  %xmm0,%xmm1
add    $0x2,%rax
add    %edi,%edx
add    %edi,%ecx
cmp    %rax,%r12
jne    1630 <calculateSubgridError_ADR_Sangalli_tau+0x4f0>
test   $0x1,%r13b
jne    19d5 <calculateSubgridError_ADR_Sangalli_tau+0x895>
jmp    1674 <calculateSubgridError_ADR_Sangalli_tau+0x534>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
xorpd  %xmm1,%xmm1
mov    0x58(%rsp),%rax
mov    0x20(%rsp),%rcx
add    %rax,%rcx
mov    0x178(%rsp),%rax
mov    %rcx,%rbp
mulsd  (%rax,%rcx,8),%xmm1
movapd %xmm1,%xmm0
mulsd  0x963(%rip),%xmm0
ucomisd %xmm11,%xmm5
movsd  %xmm4,(%rsp)
movsd  %xmm1,0x18(%rsp)
movsd  %xmm0,0x60(%rsp)
jb     16c0 <calculateSubgridError_ADR_Sangalli_tau+0x580>
xorps  %xmm0,%xmm0
sqrtsd %xmm5,%xmm0
jmp    16da <calculateSubgridError_ADR_Sangalli_tau+0x59a>
xchg   %ax,%ax
movapd %xmm5,%xmm0
movapd %xmm5,0x40(%rsp)
call   1060 <sqrt@plt>
movapd 0x40(%rsp),%xmm5
xorpd  %xmm11,%xmm11
unpckhpd %xmm5,%xmm5
ucomisd %xmm11,%xmm5
movapd %xmm5,0x40(%rsp)
movapd %xmm0,0x70(%rsp)
jb     1700 <calculateSubgridError_ADR_Sangalli_tau+0x5c0>
xorps  %xmm1,%xmm1
sqrtsd %xmm5,%xmm1
jmp    1712 <calculateSubgridError_ADR_Sangalli_tau+0x5d2>
nopw   0x0(%rax,%rax,1)
movapd %xmm5,%xmm0
call   1060 <sqrt@plt>
xorpd  %xmm11,%xmm11
movapd %xmm0,%xmm1
movsd  (%rsp),%xmm0
movsd  0x18(%rsp),%xmm2
movsd  0x60(%rsp),%xmm3
mulsd  %xmm3,%xmm2
mulsd  %xmm2,%xmm0
mulsd  0x8d5(%rip),%xmm1
movsd  %xmm1,0x18(%rsp)
ucomisd %xmm11,%xmm0
movsd  %xmm0,(%rsp)
jb     1750 <calculateSubgridError_ADR_Sangalli_tau+0x610>
xorps  %xmm1,%xmm1
sqrtsd %xmm0,%xmm1
jmp    175e <calculateSubgridError_ADR_Sangalli_tau+0x61e>
xchg   %ax,%ax
call   1060 <sqrt@plt>
xorpd  %xmm11,%xmm11
movapd %xmm0,%xmm1
movapd 0x40(%rsp),%xmm0
mulsd  0x8a4(%rip),%xmm1
ucomisd %xmm11,%xmm0
movsd  %xmm1,0x108(%rsp)
jb     1790 <calculateSubgridError_ADR_Sangalli_tau+0x650>
xorps  %xmm4,%xmm4
sqrtsd %xmm0,%xmm4
jmp    179e <calculateSubgridError_ADR_Sangalli_tau+0x65e>
cs nopw 0x0(%rax,%rax,1)
nop
call   1060 <sqrt@plt>
xorpd  %xmm11,%xmm11
movapd %xmm0,%xmm4
movsd  (%rsp),%xmm3
ucomisd %xmm11,%xmm3
jb     17c0 <calculateSubgridError_ADR_Sangalli_tau+0x680>
xorps  %xmm0,%xmm0
sqrtsd %xmm3,%xmm0
jmp    17e5 <calculateSubgridError_ADR_Sangalli_tau+0x6a5>
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
movapd %xmm3,%xmm0
movapd %xmm4,0xa0(%rsp)
call   1060 <sqrt@plt>
movapd 0xa0(%rsp),%xmm4
movsd  (%rsp),%xmm3
xorpd  %xmm11,%xmm11
movsd  0x833(%rip),%xmm7
movsd  0x18(%rsp),%xmm5
mov    0xb8(%rsp),%rax
mov    %rbp,%rcx
movsd  (%rax,%rbp,8),%xmm1
mov    0x180(%rsp),%rax
movsd  (%rax,%rbp,8),%xmm6
addsd  %xmm1,%xmm6
movapd %xmm5,%xmm2
addsd  0x7f8(%rip),%xmm2
divsd  %xmm2,%xmm6
movapd %xmm6,%xmm2
andpd  0x860(%rip),%xmm2
ucomisd %xmm2,%xmm7
jbe    1860 <calculateSubgridError_ADR_Sangalli_tau+0x720>
movapd 0x40(%rsp),%xmm0
addsd  %xmm3,%xmm0
addsd  %xmm7,%xmm0
ucomisd %xmm11,%xmm0
jb     18b0 <calculateSubgridError_ADR_Sangalli_tau+0x770>
sqrtsd %xmm0,%xmm0
jmp    18ba <calculateSubgridError_ADR_Sangalli_tau+0x77a>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
divsd  %xmm0,%xmm4
movapd %xmm4,%xmm0
mulsd  0x7b8(%rip),%xmm0
ucomisd %xmm0,%xmm6
jbe    18e0 <calculateSubgridError_ADR_Sangalli_tau+0x7a0>
movsd  0x78a(%rip),%xmm0
divsd  %xmm1,%xmm0
movapd %xmm0,0x60(%rsp)
movapd 0x70(%rsp),%xmm3
mulsd  %xmm3,%xmm3
mulsd  0x7a6(%rip),%xmm1
divsd  %xmm1,%xmm3
jmp    1b50 <calculateSubgridError_ADR_Sangalli_tau+0xa10>
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
call   1060 <sqrt@plt>
xorpd  %xmm11,%xmm11
movsd  0x7b6(%rip),%xmm1
divsd  %xmm0,%xmm1
movapd %xmm1,0x60(%rsp)
xorpd  %xmm3,%xmm3
jmp    1b50 <calculateSubgridError_ADR_Sangalli_tau+0xa10>
cs nopw 0x0(%rax,%rax,1)
nop
ucomisd %xmm5,%xmm7
jbe    1940 <calculateSubgridError_ADR_Sangalli_tau+0x800>
movapd %xmm6,%xmm1
addsd  %xmm6,%xmm1
addsd  %xmm4,%xmm1
mulsd  %xmm4,%xmm1
ucomisd %xmm1,%xmm11
jbe    19ff <calculateSubgridError_ADR_Sangalli_tau+0x8bf>
movapd %xmm6,%xmm0
mulsd  0x75b(%rip),%xmm0
subsd  %xmm4,%xmm0
mulsd  %xmm4,%xmm0
ucomisd %xmm11,%xmm0
movapd %xmm4,0xa0(%rsp)
movapd %xmm6,0xd0(%rsp)
jb     1a33 <calculateSubgridError_ADR_Sangalli_tau+0x8f3>
sqrtsd %xmm0,%xmm0
call   1050 <cos@plt>
jmp    1a4d <calculateSubgridError_ADR_Sangalli_tau+0x90d>
movapd %xmm4,%xmm2
divsd  0x6e4(%rip),%xmm2
movsd  0x6b4(%rip),%xmm1
movapd %xmm1,%xmm0
divsd  %xmm6,%xmm0
minsd  %xmm1,%xmm0
minsd  %xmm0,%xmm2
divsd  0x6cc(%rip),%xmm4
mulsd  0x6cc(%rip),%xmm6
movsd  0x6cc(%rip),%xmm0
divsd  %xmm6,%xmm0
minsd  0x6c8(%rip),%xmm0
minsd  %xmm0,%xmm4
xorpd  0x70c(%rip),%xmm4
divsd  %xmm5,%xmm2
movapd %xmm2,0x60(%rsp)
divsd  %xmm5,%xmm4
movapd 0x70(%rsp),%xmm0
mulsd  %xmm0,%xmm0
divsd  %xmm0,%xmm4
movapd %xmm4,%xmm3
jmp    1b50 <calculateSubgridError_ADR_Sangalli_tau+0xa10>
xorpd  %xmm1,%xmm1
xor    %eax,%eax
mov    0xc(%rsp),%ebp
mov    0x160(%rsp),%rsi
test   $0x1,%r13b
je     1674 <calculateSubgridError_ADR_Sangalli_tau+0x534>
mov    0x58(%rsp),%rcx
mov    0x20(%rsp),%rdx
add    %edx,%ecx
imul   %ebp,%ecx
add    %eax,%ecx
imul   %ebx,%eax
add    %ecx,%eax
cltq
movsd  (%rsi,%rax,8),%xmm0
maxsd  %xmm1,%xmm0
movapd %xmm0,%xmm1
jmp    1674 <calculateSubgridError_ADR_Sangalli_tau+0x534>
ucomisd 0x659(%rip),%xmm1
movsd  0x649(%rip),%xmm0
ja     1a6c <calculateSubgridError_ADR_Sangalli_tau+0x92c>
movapd %xmm6,0xd0(%rsp)
movapd %xmm4,0xa0(%rsp)
ucomisd %xmm11,%xmm1
jb     1a3f <calculateSubgridError_ADR_Sangalli_tau+0x8ff>
xorps  %xmm0,%xmm0
sqrtsd %xmm1,%xmm0
jmp    1a48 <calculateSubgridError_ADR_Sangalli_tau+0x908>
call   1060 <sqrt@plt>
call   1050 <cos@plt>
jmp    1a4d <calculateSubgridError_ADR_Sangalli_tau+0x90d>
movapd %xmm1,%xmm0
call   1060 <sqrt@plt>
call   1030 <cosh@plt>
xorpd  %xmm11,%xmm11
movsd  0x5c6(%rip),%xmm7
movapd 0xa0(%rsp),%xmm4
movapd 0xd0(%rsp),%xmm6
mov    0xb8(%rsp),%rax
movsd  (%rax,%rbp,8),%xmm10
movsd  0x5c5(%rip),%xmm9
movapd %xmm9,%xmm12
divsd  %xmm10,%xmm12
movapd %xmm0,%xmm3
addsd  %xmm9,%xmm3
movapd %xmm4,%xmm1
addsd  %xmm4,%xmm1
mulsd  %xmm6,%xmm1
subsd  %xmm1,%xmm3
movapd 0x70(%rsp),%xmm5
movapd %xmm5,%xmm2
xorpd  0x5e8(%rip),%xmm2
unpcklpd %xmm4,%xmm5
unpcklpd %xmm6,%xmm2
mulpd  %xmm5,%xmm2
movapd %xmm2,%xmm5
unpckhpd %xmm2,%xmm5
divsd  %xmm3,%xmm5
movsd  0x58f(%rip),%xmm8
movapd %xmm8,%xmm3
subsd  %xmm5,%xmm3
addsd  %xmm7,%xmm3
divsd  %xmm3,%xmm12
movapd %xmm12,0x60(%rsp)
movsd  0x536(%rip),%xmm3
mulsd  %xmm3,%xmm10
divsd  %xmm1,%xmm3
movapd %xmm9,%xmm1
subsd  %xmm3,%xmm1
movapd %xmm0,%xmm3
mulsd  0x558(%rip),%xmm3
addsd  %xmm1,%xmm3
addsd  %xmm0,%xmm0
addsd  %xmm8,%xmm0
mulsd  %xmm6,%xmm4
subsd  %xmm4,%xmm0
unpcklpd %xmm0,%xmm10
divpd  %xmm10,%xmm2
movapd %xmm2,%xmm0
unpckhpd %xmm2,%xmm0
subsd  %xmm0,%xmm3
mulsd  %xmm2,%xmm3
nopw   0x0(%rax,%rax,1)
movapd %xmm3,0x70(%rsp)
xor    %edi,%edi
ucomisd %xmm3,%xmm11
setae  %dil
xor    %eax,%eax
call   1040 <assert@plt>
xor    %edi,%edi
movapd 0x60(%rsp),%xmm0
ucomisd 0x508(%rip),%xmm0
setae  %dil
xor    %eax,%eax
call   1040 <assert@plt>
xorpd  %xmm11,%xmm11
mov    0x198(%rsp),%rax
mov    %rbp,%rcx
movaps 0x60(%rsp),%xmm0
movsd  %xmm0,(%rax,%rbp,8)
mov    0x1a0(%rsp),%rax
movaps 0x70(%rsp),%xmm0
movsd  %xmm0,(%rax,%rbp,8)
movsd  0x18(%rsp),%xmm0
maxsd  0x108(%rsp),%xmm0
mov    0x190(%rsp),%rax
movsd  %xmm0,(%rax,%rbp,8)
movapd 0x40(%rsp),%xmm0
ucomisd %xmm11,%xmm0
jb     1bf0 <calculateSubgridError_ADR_Sangalli_tau+0xab0>
xorps  %xmm1,%xmm1
sqrtsd %xmm0,%xmm1
jmp    1bfe <calculateSubgridError_ADR_Sangalli_tau+0xabe>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
call   1060 <sqrt@plt>
xorpd  %xmm11,%xmm11
movapd %xmm0,%xmm1
movsd  (%rsp),%xmm0
ucomisd %xmm11,%xmm0
jb     12d0 <calculateSubgridError_ADR_Sangalli_tau+0x190>
sqrtsd %xmm0,%xmm0
jmp    12e4 <calculateSubgridError_ADR_Sangalli_tau+0x1a4>
add    $0x128,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

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

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