void calculateSubgridError_ADR_Sangalli_tau_sd(
    int nElements_global, int nQuadraturePoints_element, int nSpace,
    int *rowptr, int *colind, 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, m, nnz = rowptr[nSpace], nSpace2 = nSpace * nSpace;
  double Vlin, Alin, A_II, cfl1, cfl2, 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 Da, h_e, tau_00, tau_11, t_00, t_11, coshGamma, Pe, sinhAlpha,
      coshAlpha, PeEval, gamma2, gam2Eval, DaEval;
  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 (m = rowptr[I]; m < rowptr[I + 1]; m++) {
          vlin[I] -= da[eN * nQuadraturePoints_element * nnz + k * nnz + m] *
                     grad_phi[eN * nQuadraturePoints_element * nSpace +
                              k * nSpace + colind[m]];
        }
      }
      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++) {
        for (m = rowptr[I]; m < rowptr[I + 1]; m++) {
          if (I == colind[m]) {
            A_II = a[eN * nQuadraturePoints_element * nnz + k * nnz + m];
            Alin = (A_II > Alin) ? A_II : Alin;
          }
        }
      }
      Alin *= dphi[eN * nQuadraturePoints_element + k];
      CI_nu2_G_ddot_G *= CI * Alin * Alin;
      h_e = 1.0 / sqrt(g_dot_g);
      cfl1 = sqrt(v_dot_Gv);
      cfl2 = 0.25 * sqrt(CI_nu2_G_ddot_G);
      Pe = sqrt(v_dot_Gv) / (sqrt(CI_nu2_G_ddot_G) + 1.0e-12);
      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] +
                        dr[eN * nQuadraturePoints_element + k]);
        tau_11 = -h_e * h_e /
                 (12.0 * (dmt[eN * nQuadraturePoints_element + k] +
                          dr[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 if (Da >= 0.0 && 0) {
        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 = h_e * h_e * t_11 / cfl1;
        printf(
            "Sangalli general reduced formula Da= %12.5e Pe=%12.5e cfl=%12.5e "
            "t_11=%12.5e tau_11=%12.5e t_00=%12.5e tau_00=%12.5e \n",
            Da, Pe, cfl1, t_11, tau_11, t_00, tau_00);
      } else {
        PeEval = fmin(Pe, 10.0);
        DaEval = -Da;
        if (DaEval < -10.0)
          DaEval = -10.0;
        if (DaEval > 10.0)
          DaEval = 10.0;
        gamma2 = PeEval * (-2.0 * DaEval + PeEval);
        if (gamma2 < 0.0)
          coshGamma = cos(sqrt(PeEval * (2.0 * DaEval - PeEval)));
        else
          coshGamma = cosh(sqrt(gamma2));
        sinhAlpha = sinh(PeEval);
        coshAlpha = cosh(PeEval);
        t_00 = 1.0 / (-2.0 * DaEval +
                      DaEval * DaEval * sinhAlpha /
                          (-coshAlpha + coshGamma + DaEval * sinhAlpha));
        t_11 = (-3.0 - DaEval * DaEval + 3.0 * DaEval / (PeEval + 1.0e-12) +
                DaEval *
                    (3.0 * DaEval * coshGamma +
                     sinhAlpha * (-3.0 + DaEval * DaEval)) /
                    (-2.0 * coshAlpha + 2.0 * coshGamma + DaEval * sinhAlpha)) /
               (6.0 * DaEval * DaEval * DaEval + 1.0e-12);
        tau_00 = t_00 / cfl1;
        tau_11 = h_e * h_e * t_11 / cfl1;
        printf("\t Sangalli general h_e= %12.5e Da= %12.5e DaEval= %12.5e "
               "Pe=%12.5e PeEval= %12.5e cfl=%12.5e \n\t gamma2= %12.5e  "
               "coshGamma=%12.5e sinhAlpha=%12.5e coshAlpha=%12.5e \n\t "
               "t_11=%12.5e tau_11=%12.5e t_00= %12.5e tau_00=%12.5e \n",
               h_e, Da, DaEval, Pe, PeEval, cfl1, gamma2, coshGamma, sinhAlpha,
               coshAlpha, t_11, tau_11, t_00, tau_00);
      }
      if (tau_11 > 0.0) {
        printf("Sangalli tau_11 = %12.5e > 0 switching ", tau_11);
        t_11 = fmin(Pe / 60.0, fmin(1.0 / (12.0 * Da), 1.0 / 24.0));
        t_11 *= -1.0;
        tau_11 = h_e * h_e * t_11 / cfl1;
        printf("tau_11 = %12.5e \n", tau_11);
      }
      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_sd>:
push   %rbp
mov    %rsp,%rbp
sub    $0x180,%rsp
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)
mov    %edx,-0xc(%rbp)
mov    %rcx,-0x18(%rbp)
mov    %r8,-0x20(%rbp)
mov    %r9,-0x28(%rbp)
mov    -0x18(%rbp),%rax
movslq -0xc(%rbp),%rcx
mov    (%rax,%rcx,4),%eax
mov    %eax,-0x44(%rbp)
mov    -0xc(%rbp),%eax
imul   -0xc(%rbp),%eax
mov    %eax,-0x48(%rbp)
movsd  0x1e34(%rip),%xmm0
movsd  %xmm0,-0xb8(%rbp)
ff
movl   $0x0,-0x2c(%rbp)
mov    -0x2c(%rbp),%eax
cmp    -0x4(%rbp),%eax
jge    22a4 <calculateSubgridError_ADR_Sangalli_tau_sd+0x1144>
movl   $0x0,-0x30(%rbp)
mov    -0x30(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    2291 <calculateSubgridError_ADR_Sangalli_tau_sd+0x1131>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x50(%rbp)
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x58(%rbp)
movl   $0x0,-0x34(%rbp)
mov    -0x34(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    1318 <calculateSubgridError_ADR_Sangalli_tau_sd+0x1b8>
mov    0x18(%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
mov    -0x18(%rbp),%rax
movslq -0x34(%rbp),%rcx
mov    (%rax,%rcx,4),%eax
mov    %eax,-0x40(%rbp)
mov    -0x40(%rbp),%eax
mov    -0x18(%rbp),%rcx
mov    -0x34(%rbp),%edx
add    $0x1,%edx
movslq %edx,%rdx
cmp    (%rcx,%rdx,4),%eax
jge    1305 <calculateSubgridError_ADR_Sangalli_tau_sd+0x1a5>
mov    0x28(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0x44(%rbp),%ecx
mov    -0x30(%rbp),%edx
imul   -0x44(%rbp),%edx
add    %edx,%ecx
add    -0x40(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x30(%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
mov    -0x20(%rbp),%rdx
movslq -0x40(%rbp),%rsi
add    (%rdx,%rsi,4),%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    -0x40(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x40(%rbp)
jmp    125b <calculateSubgridError_ADR_Sangalli_tau_sd+0xfb>
jmp    130a <calculateSubgridError_ADR_Sangalli_tau_sd+0x1aa>
mov    -0x34(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x34(%rbp)
jmp    1211 <calculateSubgridError_ADR_Sangalli_tau_sd+0xb1>
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    1513 <calculateSubgridError_ADR_Sangalli_tau_sd+0x3b3>
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    14b0 <calculateSubgridError_ADR_Sangalli_tau_sd+0x350>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x98(%rbp)
ff
movl   $0x0,-0x3c(%rbp)
mov    -0x3c(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    1411 <calculateSubgridError_ADR_Sangalli_tau_sd+0x2b1>
mov    -0x28(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0x48(%rbp),%ecx
mov    -0x30(%rbp),%edx
imul   -0x48(%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    -0x28(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0x48(%rbp),%ecx
mov    -0x30(%rbp),%edx
imul   -0x48(%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    1387 <calculateSubgridError_ADR_Sangalli_tau_sd+0x227>
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    -0x28(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0x48(%rbp),%ecx
mov    -0x30(%rbp),%edx
imul   -0x48(%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    1369 <calculateSubgridError_ADR_Sangalli_tau_sd+0x209>
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    1340 <calculateSubgridError_ADR_Sangalli_tau_sd+0x1e0>
movl   $0x0,-0x34(%rbp)
mov    -0x34(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    15eb <calculateSubgridError_ADR_Sangalli_tau_sd+0x48b>
mov    -0x18(%rbp),%rax
movslq -0x34(%rbp),%rcx
mov    (%rax,%rcx,4),%eax
mov    %eax,-0x40(%rbp)
mov    -0x40(%rbp),%eax
mov    -0x18(%rbp),%rcx
mov    -0x34(%rbp),%edx
add    $0x1,%edx
movslq %edx,%rdx
cmp    (%rcx,%rdx,4),%eax
jge    15d8 <calculateSubgridError_ADR_Sangalli_tau_sd+0x478>
mov    -0x34(%rbp),%eax
mov    -0x20(%rbp),%rcx
movslq -0x40(%rbp),%rdx
cmp    (%rcx,%rdx,4),%eax
jne    15c5 <calculateSubgridError_ADR_Sangalli_tau_sd+0x465>
mov    0x20(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
imul   -0x44(%rbp),%ecx
mov    -0x30(%rbp),%edx
imul   -0x44(%rbp),%edx
add    %edx,%ecx
add    -0x40(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0x60(%rbp)
movsd  -0x60(%rbp),%xmm0
ucomisd -0x58(%rbp),%xmm0
jbe    15ab <calculateSubgridError_ADR_Sangalli_tau_sd+0x44b>
movsd  -0x60(%rbp),%xmm0
movsd  %xmm0,-0x140(%rbp)
ff
jmp    15b8 <calculateSubgridError_ADR_Sangalli_tau_sd+0x458>
movsd  -0x58(%rbp),%xmm0
movsd  %xmm0,-0x140(%rbp)
ff
movsd  -0x140(%rbp),%xmm0
ff
movsd  %xmm0,-0x58(%rbp)
jmp    15ca <calculateSubgridError_ADR_Sangalli_tau_sd+0x46a>
mov    -0x40(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x40(%rbp)
jmp    1534 <calculateSubgridError_ADR_Sangalli_tau_sd+0x3d4>
jmp    15dd <calculateSubgridError_ADR_Sangalli_tau_sd+0x47d>
mov    -0x34(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x34(%rbp)
jmp    151a <calculateSubgridError_ADR_Sangalli_tau_sd+0x3ba>
mov    0x38(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mulsd  -0x58(%rbp),%xmm0
movsd  %xmm0,-0x58(%rbp)
movsd  -0xb8(%rbp),%xmm0
ff
mulsd  -0x58(%rbp),%xmm0
mulsd  -0x58(%rbp),%xmm0
mulsd  -0xa8(%rbp),%xmm0
ff
movsd  %xmm0,-0xa8(%rbp)
ff
movsd  -0xc8(%rbp),%xmm0
ff
call   1080 <sqrt@plt>
movaps %xmm0,%xmm1
movsd  0x19db(%rip),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xd8(%rbp)
ff
movsd  -0xa0(%rbp),%xmm0
ff
call   1080 <sqrt@plt>
movsd  %xmm0,-0x68(%rbp)
movsd  -0xa8(%rbp),%xmm0
ff
call   1080 <sqrt@plt>
movaps %xmm0,%xmm1
movsd  0x199d(%rip),%xmm0
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x70(%rbp)
movsd  -0xa0(%rbp),%xmm0
ff
call   1080 <sqrt@plt>
movsd  %xmm0,-0x148(%rbp)
ff
movsd  -0xa8(%rbp),%xmm0
ff
call   1080 <sqrt@plt>
movaps %xmm0,%xmm1
movsd  -0x148(%rbp),%xmm0
ff
movsd  0x1957(%rip),%xmm2
addsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x108(%rbp)
ff
mov    0x10(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x40(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
addsd  (%rax,%rcx,8),%xmm0
movsd  0x1913(%rip),%xmm1
addsd  -0x68(%rbp),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xd0(%rbp)
ff
movsd  -0xd0(%rbp),%xmm1
ff
movaps 0x1983(%rip),%xmm0
pand   %xmm0,%xmm1
movsd  0x18df(%rip),%xmm0
ucomisd %xmm1,%xmm0
jbe    177b <calculateSubgridError_ADR_Sangalli_tau_sd+0x61b>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xe8(%rbp)
ff
movsd  -0xa0(%rbp),%xmm0
ff
addsd  -0xa8(%rbp),%xmm0
ff
movsd  0x18b2(%rip),%xmm1
addsd  %xmm1,%xmm0
call   1080 <sqrt@plt>
movaps %xmm0,%xmm1
movsd  0x18b6(%rip),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xe0(%rbp)
ff
jmp    209d <calculateSubgridError_ADR_Sangalli_tau_sd+0xf3d>
movsd  -0xd0(%rbp),%xmm0
ff
movsd  0x189d(%rip),%xmm1
mulsd  -0x108(%rbp),%xmm1
ff
ucomisd %xmm1,%xmm0
jbe    184d <calculateSubgridError_ADR_Sangalli_tau_sd+0x6ed>
mov    0x10(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm1
mov    0x40(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
addsd  (%rax,%rcx,8),%xmm1
movsd  0x18a7(%rip),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xe0(%rbp)
ff
movsd  -0xd8(%rbp),%xmm0
ff
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  -0xd8(%rbp),%xmm0
ff
mov    0x10(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm2
mov    0x40(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
addsd  (%rax,%rcx,8),%xmm2
movsd  0x1830(%rip),%xmm1
mulsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xe8(%rbp)
ff
jmp    2098 <calculateSubgridError_ADR_Sangalli_tau_sd+0xf38>
movsd  0x17b3(%rip),%xmm0
ucomisd -0x68(%rbp),%xmm0
jbe    1b1c <calculateSubgridError_ADR_Sangalli_tau_sd+0x9bc>
movsd  -0x108(%rbp),%xmm1
ff
movsd  -0xd0(%rbp),%xmm0
ff
movsd  -0x108(%rbp),%xmm2
ff
addsd  %xmm0,%xmm0
addsd  %xmm2,%xmm0
mulsd  %xmm0,%xmm1
xorps  %xmm0,%xmm0
ucomisd %xmm1,%xmm0
jbe    18e3 <calculateSubgridError_ADR_Sangalli_tau_sd+0x783>
movsd  -0x108(%rbp),%xmm0
ff
movsd  -0xd0(%rbp),%xmm2
ff
movsd  -0x108(%rbp),%xmm1
ff
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
addsd  %xmm2,%xmm2
subsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
call   1080 <sqrt@plt>
call   1070 <cos@plt>
movsd  %xmm0,-0x100(%rbp)
ff
jmp    196e <calculateSubgridError_ADR_Sangalli_tau_sd+0x80e>
movsd  -0x108(%rbp),%xmm0
ff
movsd  -0xd0(%rbp),%xmm1
ff
movsd  -0x108(%rbp),%xmm2
ff
addsd  %xmm1,%xmm1
addsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
movsd  0x1771(%rip),%xmm1
ucomisd %xmm1,%xmm0
jbe    1933 <calculateSubgridError_ADR_Sangalli_tau_sd+0x7d3>
movsd  0x1767(%rip),%xmm0
call   1040 <cosh@plt>
movsd  %xmm0,-0x100(%rbp)
ff
jmp    1969 <calculateSubgridError_ADR_Sangalli_tau_sd+0x809>
movsd  -0x108(%rbp),%xmm0
ff
movsd  -0xd0(%rbp),%xmm1
ff
movsd  -0x108(%rbp),%xmm2
ff
addsd  %xmm1,%xmm1
addsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
call   1080 <sqrt@plt>
call   1040 <cosh@plt>
movsd  %xmm0,-0x100(%rbp)
ff
jmp    196e <calculateSubgridError_ADR_Sangalli_tau_sd+0x80e>
mov    0x10(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  0x16d1(%rip),%xmm0
divsd  (%rax,%rcx,8),%xmm0
movsd  0x168c(%rip),%xmm1
mulsd  %xmm1,%xmm0
movsd  -0x108(%rbp),%xmm2
ff
mulsd  -0xd0(%rbp),%xmm2
ff
movsd  -0x100(%rbp),%xmm3
ff
movsd  0x1668(%rip),%xmm1
subsd  %xmm1,%xmm3
movsd  0x167c(%rip),%xmm1
mulsd  -0x108(%rbp),%xmm1
ff
movsd  -0xd0(%rbp),%xmm4
ff
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm4,%xmm1
addsd  %xmm3,%xmm1
divsd  %xmm1,%xmm2
movsd  0x1691(%rip),%xmm1
subsd  %xmm2,%xmm1
movsd  0x15fd(%rip),%xmm2
addsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xe0(%rbp)
ff
movsd  -0xd8(%rbp),%xmm0
ff
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  -0xd8(%rbp),%xmm0
ff
mov    0x10(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  0x15dd(%rip),%xmm1
mulsd  (%rax,%rcx,8),%xmm1
divsd  %xmm1,%xmm0
movsd  0x15d4(%rip),%xmm2
mulsd  -0x108(%rbp),%xmm2
ff
mulsd  -0xd0(%rbp),%xmm2
ff
movsd  0x15b4(%rip),%xmm1
divsd  %xmm2,%xmm1
movsd  0x15c8(%rip),%xmm2
subsd  %xmm1,%xmm2
movsd  -0x100(%rbp),%xmm1
ff
movsd  0x15ac(%rip),%xmm3
mulsd  %xmm3,%xmm1
addsd  %xmm2,%xmm1
movsd  -0x108(%rbp),%xmm2
ff
mulsd  -0xd0(%rbp),%xmm2
ff
movsd  -0x100(%rbp),%xmm4
ff
addsd  %xmm4,%xmm4
movsd  0x15c0(%rip),%xmm3
addsd  %xmm3,%xmm4
movsd  -0x108(%rbp),%xmm3
ff
movsd  -0xd0(%rbp),%xmm5
ff
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,-0xe8(%rbp)
ff
jmp    2093 <calculateSubgridError_ADR_Sangalli_tau_sd+0xf33>
movsd  -0xd0(%rbp),%xmm0
ff
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jb     1c92 <calculateSubgridError_ADR_Sangalli_tau_sd+0xb32>
xor    %eax,%eax
test   $0x1,%al
jne    1b40 <calculateSubgridError_ADR_Sangalli_tau_sd+0x9e0>
jmp    1c92 <calculateSubgridError_ADR_Sangalli_tau_sd+0xb32>
movsd  -0x108(%rbp),%xmm3
ff
movsd  0x14e8(%rip),%xmm0
divsd  %xmm0,%xmm3
movsd  0x151c(%rip),%xmm2
divsd  -0xd0(%rbp),%xmm2
ff
movsd  0x150c(%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  -0x108(%rbp),%xmm3
ff
movsd  0x14ca(%rip),%xmm0
divsd  %xmm0,%xmm3
movsd  0x14b6(%rip),%xmm0
mulsd  -0xd0(%rbp),%xmm0
ff
movsd  0x145e(%rip),%xmm2
divsd  %xmm0,%xmm2
movsd  0x1492(%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,-0xf8(%rbp)
ff
movsd  0x1458(%rip),%xmm0
mulsd  -0xf8(%rbp),%xmm0
ff
movsd  %xmm0,-0xf8(%rbp)
ff
movsd  -0xf0(%rbp),%xmm0
ff
divsd  -0x68(%rbp),%xmm0
movsd  %xmm0,-0xe0(%rbp)
ff
movsd  -0xd8(%rbp),%xmm0
ff
mulsd  -0xd8(%rbp),%xmm0
ff
mulsd  -0xf8(%rbp),%xmm0
ff
divsd  -0x68(%rbp),%xmm0
movsd  %xmm0,-0xe8(%rbp)
ff
movsd  -0xd0(%rbp),%xmm0
ff
movsd  -0x108(%rbp),%xmm1
ff
movsd  -0x68(%rbp),%xmm2
movsd  -0xf8(%rbp),%xmm3
ff
movsd  -0xe8(%rbp),%xmm4
ff
movsd  -0xf0(%rbp),%xmm5
ff
movsd  -0xe0(%rbp),%xmm6
ff
lea    0x142a(%rip),%rdi
mov    $0x7,%al
call   1050 <printf@plt>
jmp    208e <calculateSubgridError_ADR_Sangalli_tau_sd+0xf2e>
movsd  -0x108(%rbp),%xmm0
ff
movsd  0x1386(%rip),%xmm1
minsd  %xmm1,%xmm0
movsd  %xmm0,-0x120(%rbp)
ff
movsd  -0xd0(%rbp),%xmm0
ff
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  %xmm0,-0x138(%rbp)
ff
movsd  0x1353(%rip),%xmm0
ucomisd -0x138(%rbp),%xmm0
ff
jbe    1cfb <calculateSubgridError_ADR_Sangalli_tau_sd+0xb9b>
movsd  0x133d(%rip),%xmm0
movsd  %xmm0,-0x138(%rbp)
ff
movsd  -0x138(%rbp),%xmm0
ff
movsd  0x131d(%rip),%xmm1
ucomisd %xmm1,%xmm0
jbe    1d25 <calculateSubgridError_ADR_Sangalli_tau_sd+0xbc5>
movsd  0x130b(%rip),%xmm0
movsd  %xmm0,-0x138(%rbp)
ff
movsd  -0x120(%rbp),%xmm0
ff
movsd  -0x138(%rbp),%xmm2
ff
movsd  -0x120(%rbp),%xmm1
ff
addsd  %xmm2,%xmm2
subsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x128(%rbp)
ff
xorps  %xmm0,%xmm0
ucomisd -0x128(%rbp),%xmm0
ff
jbe    1db4 <calculateSubgridError_ADR_Sangalli_tau_sd+0xc54>
movsd  -0x120(%rbp),%xmm0
ff
movsd  -0x138(%rbp),%xmm1
ff
movsd  -0x120(%rbp),%xmm2
ff
movq   %xmm2,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm2
addsd  %xmm1,%xmm1
addsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
call   1080 <sqrt@plt>
call   1070 <cos@plt>
movsd  %xmm0,-0x100(%rbp)
ff
jmp    1dce <calculateSubgridError_ADR_Sangalli_tau_sd+0xc6e>
movsd  -0x128(%rbp),%xmm0
ff
call   1080 <sqrt@plt>
call   1040 <cosh@plt>
movsd  %xmm0,-0x100(%rbp)
ff
movsd  -0x120(%rbp),%xmm0
ff
call   1030 <sinh@plt>
movsd  %xmm0,-0x110(%rbp)
ff
movsd  -0x120(%rbp),%xmm0
ff
call   1040 <cosh@plt>
movsd  %xmm0,-0x118(%rbp)
ff
movsd  -0x138(%rbp),%xmm0
ff
movsd  -0x138(%rbp),%xmm1
ff
mulsd  -0x138(%rbp),%xmm1
ff
mulsd  -0x110(%rbp),%xmm1
ff
movsd  -0x118(%rbp),%xmm2
ff
movq   %xmm2,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm3
addsd  -0x100(%rbp),%xmm3
ff
movsd  -0x138(%rbp),%xmm2
ff
movsd  -0x110(%rbp),%xmm4
ff
mulsd  %xmm4,%xmm2
addsd  %xmm3,%xmm2
divsd  %xmm2,%xmm1
addsd  %xmm0,%xmm0
subsd  %xmm0,%xmm1
movsd  0x11b5(%rip),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xf0(%rbp)
ff
movsd  -0x138(%rbp),%xmm0
ff
movsd  -0x138(%rbp),%xmm1
ff
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm1,%xmm0
movsd  0x119e(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  0x119a(%rip),%xmm1
mulsd  -0x138(%rbp),%xmm1
ff
movsd  0x114a(%rip),%xmm2
addsd  -0x120(%rbp),%xmm2
ff
divsd  %xmm2,%xmm1
addsd  %xmm1,%xmm0
movsd  -0x138(%rbp),%xmm1
ff
movsd  0x116a(%rip),%xmm2
mulsd  -0x138(%rbp),%xmm2
ff
movsd  -0x100(%rbp),%xmm4
ff
movsd  -0x110(%rbp),%xmm3
ff
movsd  -0x138(%rbp),%xmm5
ff
movsd  -0x138(%rbp),%xmm6
ff
mulsd  %xmm6,%xmm5
movsd  0x112e(%rip),%xmm6
addsd  %xmm6,%xmm5
mulsd  %xmm5,%xmm3
mulsd  %xmm4,%xmm2
addsd  %xmm3,%xmm2
mulsd  %xmm2,%xmm1
movsd  -0x118(%rbp),%xmm2
ff
movsd  0x1102(%rip),%xmm3
mulsd  -0x100(%rbp),%xmm3
ff
addsd  %xmm2,%xmm2
subsd  %xmm2,%xmm3
movsd  -0x138(%rbp),%xmm2
ff
movsd  -0x110(%rbp),%xmm4
ff
mulsd  %xmm4,%xmm2
addsd  %xmm3,%xmm2
divsd  %xmm2,%xmm1
addsd  %xmm1,%xmm0
movsd  0x10c2(%rip),%xmm1
mulsd  -0x138(%rbp),%xmm1
ff
mulsd  -0x138(%rbp),%xmm1
ff
movsd  -0x138(%rbp),%xmm2
ff
mulsd  %xmm2,%xmm1
movsd  0x1076(%rip),%xmm2
addsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xf8(%rbp)
ff
movsd  -0xf0(%rbp),%xmm0
ff
divsd  -0x68(%rbp),%xmm0
movsd  %xmm0,-0xe0(%rbp)
ff
movsd  -0xd8(%rbp),%xmm0
ff
mulsd  -0xd8(%rbp),%xmm0
ff
mulsd  -0xf8(%rbp),%xmm0
ff
divsd  -0x68(%rbp),%xmm0
movsd  %xmm0,-0xe8(%rbp)
ff
movsd  -0xd8(%rbp),%xmm0
ff
movsd  -0xd0(%rbp),%xmm1
ff
movsd  -0x138(%rbp),%xmm2
ff
movsd  -0x108(%rbp),%xmm3
movsd  -0x120(%rbp),%xmm4
movsd  -0x68(%rbp),%xmm5
movsd  -0x128(%rbp),%xmm6
ff
movsd  -0x100(%rbp),%xmm7
ff
movsd  -0x110(%rbp),%xmm13
ff ff
movsd  -0x118(%rbp),%xmm12
ff ff
movsd  -0xf8(%rbp),%xmm11
ff ff
movsd  -0xe8(%rbp),%xmm10
ff ff
movsd  -0xf0(%rbp),%xmm9
ff ff
movsd  -0xe0(%rbp),%xmm8
ff ff
lea    0x10c9(%rip),%rdi
movsd  %xmm13,(%rsp)
movsd  %xmm12,0x8(%rsp)
movsd  %xmm11,0x10(%rsp)
movsd  %xmm10,0x18(%rsp)
movsd  %xmm9,0x20(%rsp)
movsd  %xmm8,0x28(%rsp)
mov    $0x8,%al
call   1050 <printf@plt>
jmp    2093 <calculateSubgridError_ADR_Sangalli_tau_sd+0xf33>
jmp    2098 <calculateSubgridError_ADR_Sangalli_tau_sd+0xf38>
jmp    209d <calculateSubgridError_ADR_Sangalli_tau_sd+0xf3d>
movsd  -0xe8(%rbp),%xmm0
ff
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jbe    217d <calculateSubgridError_ADR_Sangalli_tau_sd+0x101d>
movsd  -0xe8(%rbp),%xmm0
ff
lea    0x1143(%rip),%rdi
mov    $0x1,%al
call   1050 <printf@plt>
movsd  -0x108(%rbp),%xmm3
ff
movsd  0xf98(%rip),%xmm0
divsd  %xmm0,%xmm3
movsd  0xf84(%rip),%xmm0
mulsd  -0xd0(%rbp),%xmm0
ff
movsd  0xf2c(%rip),%xmm2
divsd  %xmm0,%xmm2
movsd  0xf60(%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,-0xf8(%rbp)
ff
movsd  0xf26(%rip),%xmm0
mulsd  -0xf8(%rbp),%xmm0
ff
movsd  %xmm0,-0xf8(%rbp)
ff
movsd  -0xd8(%rbp),%xmm0
ff
mulsd  -0xd8(%rbp),%xmm0
ff
mulsd  -0xf8(%rbp),%xmm0
ff
divsd  -0x68(%rbp),%xmm0
movsd  %xmm0,-0xe8(%rbp)
ff
movsd  -0xe8(%rbp),%xmm0
ff
lea    0x10b6(%rip),%rdi
mov    $0x1,%al
call   1050 <printf@plt>
xorps  %xmm0,%xmm0
ucomisd -0xe8(%rbp),%xmm0
ff
setae  %al
and    $0x1,%al
movzbl %al,%edi
mov    $0x0,%al
call   1060 <assert@plt>
movsd  -0xe0(%rbp),%xmm0
ff
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
setae  %al
and    $0x1,%al
movzbl %al,%edi
mov    $0x0,%al
call   1060 <assert@plt>
movsd  -0xe0(%rbp),%xmm0
ff
mov    0x58(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0xe8(%rbp),%xmm0
ff
mov    0x60(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0x68(%rbp),%xmm0
ucomisd -0x70(%rbp),%xmm0
jbe    2221 <calculateSubgridError_ADR_Sangalli_tau_sd+0x10c1>
movsd  -0x68(%rbp),%xmm0
mov    0x50(%rbp),%rax
mov    -0x2c(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x30(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
jmp    223c <calculateSubgridError_ADR_Sangalli_tau_sd+0x10dc>
movsd  -0x70(%rbp),%xmm0
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  -0xa0(%rbp),%xmm0
ff
call   1080 <sqrt@plt>
movsd  %xmm0,-0x150(%rbp)
ff
movsd  -0xa8(%rbp),%xmm0
ff
call   1080 <sqrt@plt>
movaps %xmm0,%xmm1
movsd  -0x150(%rbp),%xmm0
ff
divsd  %xmm1,%xmm0
mov    0x48(%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    11ee <calculateSubgridError_ADR_Sangalli_tau_sd+0x8e>
jmp    2296 <calculateSubgridError_ADR_Sangalli_tau_sd+0x1136>
mov    -0x2c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x2c(%rbp)
jmp    11db <calculateSubgridError_ADR_Sangalli_tau_sd+0x7b>
add    $0x180,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<calculateSubgridError_ADR_Sangalli_tau_sd>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x188,%rsp
mov    %rcx,0x68(%rsp)
mov    %esi,0x70(%rsp)
test   %edi,%edi
jle    1f78 <calculateSubgridError_ADR_Sangalli_tau_sd+0xe18>
mov    %r9,%r14
movslq %edx,%rcx
mov    0x68(%rsp),%rax
mov    (%rax,%rcx,4),%eax
mov    %edi,%esi
mov    %rsi,0x120(%rsp)
mov    %ecx,%r15d
mov    %ecx,%esi
imul   %ecx,%esi
mov    %r15d,%r12d
and    $0xfffffffe,%r12d
mov    %eax,0x48(%rsp)
mov    %eax,%edi
mov    0x70(%rsp),%eax
imul   %eax,%edi
mov    %edi,0xcc(%rsp)
mov    %esi,0x74(%rsp)
imul   %eax,%esi
mov    %esi,0xc8(%rsp)
mov    %rcx,%r13
shl    $0x4,%r13
xorpd  %xmm11,%xmm11
mov    0x1d8(%rsp),%rsi
mov    0x1d0(%rsp),%rdi
cltq
mov    %rax,0x118(%rsp)
mov    %eax,%eax
mov    %rax,0x158(%rsp)
lea    0x8(%rsi),%rax
mov    %rax,0x150(%rsp)
mov    %rcx,0x168(%rsp)
lea    0x0(,%rcx,8),%rax
mov    %rax,0x148(%rsp)
lea    0x8(%rdi),%rax
mov    %rax,0x140(%rsp)
movl   $0x0,0x44(%rsp)
movl   $0x0,0x40(%rsp)
xor    %eax,%eax
mov    %rax,0xb8(%rsp)
mov    %r8,0xc0(%rsp)
mov    %edx,0x4c(%rsp)
jmp    12a3 <calculateSubgridError_ADR_Sangalli_tau_sd+0x143>
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
mov    0xb8(%rsp),%rcx
add    $0x1,%rcx
mov    0x40(%rsp),%eax
add    0xcc(%rsp),%eax
mov    %eax,0x40(%rsp)
mov    0x44(%rsp),%eax
add    0xc8(%rsp),%eax
mov    %eax,0x44(%rsp)
mov    %rcx,%rax
mov    %rcx,0xb8(%rsp)
cmp    0x120(%rsp),%rcx
je     1f78 <calculateSubgridError_ADR_Sangalli_tau_sd+0xe18>
cmpl   $0x0,0x70(%rsp)
jle    1260 <calculateSubgridError_ADR_Sangalli_tau_sd+0x100>
mov    0xb8(%rsp),%rax
imul   0x118(%rsp),%rax
mov    %rax,0x98(%rsp)
mov    0x44(%rsp),%ecx
mov    0x40(%rsp),%esi
xor    %r10d,%r10d
jmp    1322 <calculateSubgridError_ADR_Sangalli_tau_sd+0x1c2>
movsd  %xmm1,0x30(%rsp)
call   1080 <sqrt@plt>
movsd  0x30(%rsp),%xmm1
xorpd  %xmm11,%xmm11
mov    0x4c(%rsp),%edx
mov    0x7c(%rsp),%ecx
mov    0x78(%rsp),%esi
mov    0x60(%rsp),%r10
divsd  %xmm0,%xmm1
mov    0x1f8(%rsp),%rax
movsd  %xmm1,(%rax,%rbp,8)
add    $0x1,%r10
add    0x48(%rsp),%esi
add    0x74(%rsp),%ecx
cmp    0x158(%rsp),%r10
je     1260 <calculateSubgridError_ADR_Sangalli_tau_sd+0x100>
xorpd  %xmm5,%xmm5
xorpd  %xmm4,%xmm4
test   %edx,%edx
mov    %r10,0x60(%rsp)
mov    %ecx,0x7c(%rsp)
mov    %esi,0x78(%rsp)
jle    1740 <calculateSubgridError_ADR_Sangalli_tau_sd+0x5e0>
movslq %ecx,%rdi
movslq %esi,%rax
mov    0x140(%rsp),%rcx
lea    (%rcx,%rax,8),%rcx
mov    %rcx,0x50(%rsp)
mov    0x148(%rsp),%rcx
lea    (%rcx,%rdi,8),%rcx
mov    %rcx,0xa0(%rsp)
shl    $0x3,%rdi
mov    %rdi,0x30(%rsp)
mov    0x150(%rsp),%rcx
lea    (%rcx,%rax,8),%rax
mov    0x98(%rsp),%rcx
add    %r10d,%ecx
mov    %ecx,%esi
imul   %edx,%esi
imul   0x48(%rsp),%ecx
movslq %ecx,%rcx
mov    %rcx,0x38(%rsp)
movslq %esi,%rdi
mov    0x68(%rsp),%rbx
mov    (%rbx),%r10d
xor    %r9d,%r9d
jmp    13c8 <calculateSubgridError_ADR_Sangalli_tau_sd+0x268>
nopl   0x0(%rax)
movsd  %xmm0,0x170(%rsp,%r11,8)
mov    0x68(%rsp),%rbx
cmp    %r15,%r9
je     14b0 <calculateSubgridError_ADR_Sangalli_tau_sd+0x350>
mov    %r9,%r11
mov    %r10d,%ecx
lea    (%r9,%rdi,1),%rsi
mov    0x1c8(%rsp),%rbp
movsd  0x0(%rbp,%rsi,8),%xmm0
movsd  %xmm0,0x170(%rsp,%r9,8)
add    $0x1,%r9
mov    0x4(%rbx,%r11,4),%r10d
cmp    %r10d,%ecx
jge    13bf <calculateSubgridError_ADR_Sangalli_tau_sd+0x25f>
movslq %ecx,%rsi
mov    %r10d,%ebp
sub    %ecx,%ebp
test   $0x1,%bpl
jne    1410 <calculateSubgridError_ADR_Sangalli_tau_sd+0x2b0>
mov    %rsi,%rcx
jmp    144b <calculateSubgridError_ADR_Sangalli_tau_sd+0x2eb>
nopl   0x0(%rax,%rax,1)
mov    0x38(%rsp),%rcx
add    %rsi,%rcx
mov    0x1d8(%rsp),%rbp
movsd  0x0(%rbp,%rcx,8),%xmm1
mov    0xc0(%rsp),%rcx
movslq (%rcx,%rsi,4),%rcx
add    %rdi,%rcx
mov    0x1e0(%rsp),%rbp
mulsd  0x0(%rbp,%rcx,8),%xmm1
subsd  %xmm1,%xmm0
lea    0x1(%rsi),%rcx
movslq %r10d,%rbp
not    %rsi
add    %rbp,%rsi
mov    0xc0(%rsp),%rbx
mov    0x1e0(%rsp),%r8
je     13b0 <calculateSubgridError_ADR_Sangalli_tau_sd+0x250>
nopw   0x0(%rax,%rax,1)
movslq (%rbx,%rcx,4),%rsi
add    %rdi,%rsi
movsd  -0x8(%rax,%rcx,8),%xmm1
movsd  (%rax,%rcx,8),%xmm2
mulsd  (%r8,%rsi,8),%xmm1
movslq 0x4(%rbx,%rcx,4),%rsi
add    %rdi,%rsi
mulsd  (%r8,%rsi,8),%xmm2
subsd  %xmm1,%xmm0
subsd  %xmm2,%xmm0
add    $0x2,%rcx
cmp    %rcx,%rbp
jne    1470 <calculateSubgridError_ADR_Sangalli_tau_sd+0x310>
jmp    13b0 <calculateSubgridError_ADR_Sangalli_tau_sd+0x250>
nopl   0x0(%rax)
xorpd  %xmm1,%xmm1
test   %edx,%edx
mov    0x60(%rsp),%r10
jle    1750 <calculateSubgridError_ADR_Sangalli_tau_sd+0x5f0>
mov    0x98(%rsp),%rax
add    %r10d,%eax
imul   0x74(%rsp),%eax
mov    %rax,0x38(%rsp)
movslq %eax,%rdi
xorpd  %xmm1,%xmm1
xorpd  %xmm4,%xmm4
mov    0x30(%rsp),%rcx
mov    0xa0(%rsp),%rbx
xor    %esi,%esi
jmp    1532 <calculateSubgridError_ADR_Sangalli_tau_sd+0x3d2>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
movsd  0x170(%rsp,%rsi,8),%xmm2
unpcklpd %xmm1,%xmm2
unpcklpd %xmm1,%xmm5
mulpd  %xmm2,%xmm5
movapd %xmm5,%xmm1
addpd  %xmm0,%xmm1
add    $0x1,%rsi
add    $0x8,%rbx
add    $0x8,%rcx
cmp    %r15,%rsi
je     1630 <calculateSubgridError_ADR_Sangalli_tau_sd+0x4d0>
movapd %xmm1,%xmm0
mov    0x38(%rsp),%rax
add    %esi,%eax
mov    0x30(%rsp),%r9
mov    0xa0(%rsp),%r8
xor    %r10d,%r10d
xorpd  %xmm1,%xmm1
xorpd  %xmm5,%xmm5
jmp    15a4 <calculateSubgridError_ADR_Sangalli_tau_sd+0x444>
nopw   0x0(%rax,%rax,1)
movsd  0x170(%rsp,%r10,8),%xmm3
mulsd  %xmm2,%xmm3
addsd  %xmm3,%xmm5
mulsd  %xmm2,%xmm2
addsd  %xmm2,%xmm4
mov    %r10d,%ebp
mov    0x4c(%rsp),%edx
imul   %edx,%ebp
add    %eax,%ebp
movslq %ebp,%rbp
addsd  (%r14,%rbp,8),%xmm1
add    $0x1,%r10
add    $0x8,%r8
add    $0x8,%r9
cmp    %r15,%r10
je     1500 <calculateSubgridError_ADR_Sangalli_tau_sd+0x3a0>
xorpd  %xmm2,%xmm2
cmp    $0x1,%edx
jne    15c0 <calculateSubgridError_ADR_Sangalli_tau_sd+0x460>
xor    %r11d,%r11d
jmp    15fe <calculateSubgridError_ADR_Sangalli_tau_sd+0x49e>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
mov    %r14,%rbp
xor    %r11d,%r11d
cs nopw 0x0(%rax,%rax,1)
movsd  0x0(%rbp,%rcx,1),%xmm3
mulsd  0x0(%rbp,%r9,1),%xmm3
addsd  %xmm2,%xmm3
movsd  0x0(%rbp,%rbx,1),%xmm2
mulsd  0x0(%rbp,%r8,1),%xmm2
addsd  %xmm3,%xmm2
add    $0x2,%r11
add    %r13,%rbp
cmp    %r11,%r12
jne    15d0 <calculateSubgridError_ADR_Sangalli_tau_sd+0x470>
test   $0x1,%r15b
je     1560 <calculateSubgridError_ADR_Sangalli_tau_sd+0x400>
imul   0x168(%rsp),%r11
add    %rdi,%r11
lea    (%r11,%rsi,1),%rbp
movsd  (%r14,%rbp,8),%xmm3
add    %r10,%r11
mulsd  (%r14,%r11,8),%xmm3
addsd  %xmm3,%xmm2
jmp    1560 <calculateSubgridError_ADR_Sangalli_tau_sd+0x400>
addpd  %xmm0,%xmm5
test   %edx,%edx
jle    1746 <calculateSubgridError_ADR_Sangalli_tau_sd+0x5e6>
mov    0x98(%rsp),%rax
mov    0x60(%rsp),%r10
add    %r10d,%eax
imul   0x48(%rsp),%eax
movslq %eax,%r8
mov    0x68(%rsp),%rax
mov    (%rax),%ecx
xorpd  %xmm1,%xmm1
xor    %r9d,%r9d
mov    0xc0(%rsp),%rbp
mov    0x50(%rsp),%rbx
jmp    1689 <calculateSubgridError_ADR_Sangalli_tau_sd+0x529>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
cmp    %r15,%r9
je     1750 <calculateSubgridError_ADR_Sangalli_tau_sd+0x5f0>
mov    %r9,%rsi
mov    %ecx,%eax
add    $0x1,%r9
mov    0x68(%rsp),%rcx
mov    0x4(%rcx,%rsi,4),%ecx
cmp    %ecx,%eax
jge    1680 <calculateSubgridError_ADR_Sangalli_tau_sd+0x520>
movslq %eax,%rdx
mov    %ecx,%edi
sub    %eax,%edi
test   $0x1,%dil
jne    16c0 <calculateSubgridError_ADR_Sangalli_tau_sd+0x560>
mov    %rdx,%rdi
jmp    16e6 <calculateSubgridError_ADR_Sangalli_tau_sd+0x586>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
mov    0x0(%rbp,%rdx,4),%eax
cmp    %rax,%rsi
jne    16e2 <calculateSubgridError_ADR_Sangalli_tau_sd+0x582>
lea    (%rdx,%r8,1),%rax
mov    0x1d0(%rsp),%rdi
movsd  (%rdi,%rax,8),%xmm0
maxsd  %xmm1,%xmm0
movapd %xmm0,%xmm1
lea    0x1(%rdx),%rdi
movslq %ecx,%rax
not    %rdx
add    %rax,%rdx
jne    170d <calculateSubgridError_ADR_Sangalli_tau_sd+0x5ad>
jmp    1680 <calculateSubgridError_ADR_Sangalli_tau_sd+0x520>
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
add    $0x2,%rdi
cmp    %rdi,%rax
je     1680 <calculateSubgridError_ADR_Sangalli_tau_sd+0x520>
mov    0x0(%rbp,%rdi,4),%edx
cmp    %rdx,%rsi
jne    1724 <calculateSubgridError_ADR_Sangalli_tau_sd+0x5c4>
movsd  -0x8(%rbx,%rdi,8),%xmm0
maxsd  %xmm1,%xmm0
movapd %xmm0,%xmm1
mov    0x4(%rbp,%rdi,4),%edx
cmp    %rdx,%rsi
jne    1700 <calculateSubgridError_ADR_Sangalli_tau_sd+0x5a0>
movsd  (%rbx,%rdi,8),%xmm0
maxsd  %xmm1,%xmm0
movapd %xmm0,%xmm1
jmp    1700 <calculateSubgridError_ADR_Sangalli_tau_sd+0x5a0>
nopl   0x0(%rax)
xorpd  %xmm1,%xmm1
jmp    1750 <calculateSubgridError_ADR_Sangalli_tau_sd+0x5f0>
xorpd  %xmm1,%xmm1
mov    0x60(%rsp),%r10
nop
mov    0x98(%rsp),%rax
lea    (%r10,%rax,1),%rbp
mov    0x1e8(%rsp),%rax
mulsd  (%rax,%rbp,8),%xmm1
movapd %xmm1,%xmm2
mulsd  0x88b(%rip),%xmm2
movapd %xmm5,%xmm0
unpckhpd %xmm5,%xmm0
ucomisd %xmm11,%xmm0
movapd %xmm5,0xa0(%rsp)
movsd  %xmm4,0x30(%rsp)
movsd  %xmm1,0x50(%rsp)
movsd  %xmm2,0xd0(%rsp)
jb     17b0 <calculateSubgridError_ADR_Sangalli_tau_sd+0x650>
sqrtsd %xmm0,%xmm0
jmp    17c3 <calculateSubgridError_ADR_Sangalli_tau_sd+0x663>
nopl   0x0(%rax,%rax,1)
call   1080 <sqrt@plt>
movapd 0xa0(%rsp),%xmm5
xorpd  %xmm11,%xmm11
movapd %xmm0,0x80(%rsp)
ucomisd %xmm11,%xmm5
jb     17e0 <calculateSubgridError_ADR_Sangalli_tau_sd+0x680>
xorps  %xmm0,%xmm0
sqrtsd %xmm5,%xmm0
jmp    17ee <calculateSubgridError_ADR_Sangalli_tau_sd+0x68e>
nopl   0x0(%rax)
movapd %xmm5,%xmm0
call   1080 <sqrt@plt>
xorpd  %xmm11,%xmm11
movsd  %xmm0,0x38(%rsp)
movsd  0x30(%rsp),%xmm0
movsd  0x50(%rsp),%xmm1
movsd  0xd0(%rsp),%xmm2
mulsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
ucomisd %xmm11,%xmm0
movsd  %xmm0,0x30(%rsp)
jb     1830 <calculateSubgridError_ADR_Sangalli_tau_sd+0x6d0>
xorps  %xmm1,%xmm1
sqrtsd %xmm0,%xmm1
jmp    183e <calculateSubgridError_ADR_Sangalli_tau_sd+0x6de>
nopw   0x0(%rax,%rax,1)
call   1080 <sqrt@plt>
xorpd  %xmm11,%xmm11
movapd %xmm0,%xmm1
movapd 0xa0(%rsp),%xmm0
mulsd  0x7b9(%rip),%xmm1
ucomisd %xmm11,%xmm0
movsd  %xmm1,0x160(%rsp)
jb     1870 <calculateSubgridError_ADR_Sangalli_tau_sd+0x710>
xorps  %xmm4,%xmm4
sqrtsd %xmm0,%xmm4
jmp    187e <calculateSubgridError_ADR_Sangalli_tau_sd+0x71e>
nopl   0x0(%rax,%rax,1)
call   1080 <sqrt@plt>
xorpd  %xmm11,%xmm11
movapd %xmm0,%xmm4
movsd  0x30(%rsp),%xmm0
ucomisd %xmm11,%xmm0
jb     18a0 <calculateSubgridError_ADR_Sangalli_tau_sd+0x740>
sqrtsd %xmm0,%xmm0
jmp    18b6 <calculateSubgridError_ADR_Sangalli_tau_sd+0x756>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
movapd %xmm4,0x50(%rsp)
call   1080 <sqrt@plt>
movapd 0x50(%rsp),%xmm4
xorpd  %xmm11,%xmm11
movsd  0x752(%rip),%xmm3
movsd  0x752(%rip),%xmm7
mov    0x1c0(%rsp),%rax
movsd  (%rax,%rbp,8),%xmm1
mov    0x1f0(%rsp),%rax
addsd  (%rax,%rbp,8),%xmm1
movsd  0x38(%rsp),%xmm2
addsd  %xmm3,%xmm2
movapd %xmm1,%xmm6
divsd  %xmm2,%xmm6
movapd %xmm6,%xmm2
andpd  0x7b2(%rip),%xmm2
ucomisd %xmm2,%xmm7
jbe    1930 <calculateSubgridError_ADR_Sangalli_tau_sd+0x7d0>
movapd 0xa0(%rsp),%xmm0
addsd  0x30(%rsp),%xmm0
addsd  %xmm7,%xmm0
ucomisd %xmm11,%xmm0
jb     19b0 <calculateSubgridError_ADR_Sangalli_tau_sd+0x850>
sqrtsd %xmm0,%xmm0
jmp    19ba <calculateSubgridError_ADR_Sangalli_tau_sd+0x85a>
nopl   0x0(%rax,%rax,1)
addsd  %xmm3,%xmm0
movapd 0x80(%rsp),%xmm3
unpcklpd %xmm0,%xmm3
movapd 0x757(%rip),%xmm2
unpcklpd %xmm4,%xmm2
divpd  %xmm3,%xmm2
movapd %xmm2,%xmm12
unpckhpd %xmm2,%xmm12
movapd %xmm12,%xmm0
mulsd  0x6b8(%rip),%xmm0
ucomisd %xmm0,%xmm6
movapd %xmm2,0x80(%rsp)
movapd %xmm6,0x100(%rsp)
movapd %xmm12,0xf0(%rsp)
jbe    19e0 <calculateSubgridError_ADR_Sangalli_tau_sd+0x880>
movsd  0x6de(%rip),%xmm4
divsd  %xmm1,%xmm4
movapd %xmm2,%xmm7
mulsd  %xmm2,%xmm7
mulsd  0x6d2(%rip),%xmm1
divsd  %xmm1,%xmm7
jmp    1e14 <calculateSubgridError_ADR_Sangalli_tau_sd+0xcb4>
nop
call   1080 <sqrt@plt>
xorpd  %xmm11,%xmm11
movsd  0x66e(%rip),%xmm1
divsd  %xmm0,%xmm1
movsd  %xmm1,0x50(%rsp)
xorpd  %xmm7,%xmm7
jmp    1eb5 <calculateSubgridError_ADR_Sangalli_tau_sd+0xd55>
cs nopw 0x0(%rax,%rax,1)
nop
ucomisd 0x38(%rsp),%xmm7
jbe    1a34 <calculateSubgridError_ADR_Sangalli_tau_sd+0x8d4>
movapd %xmm6,%xmm1
addsd  %xmm6,%xmm1
addsd  %xmm12,%xmm1
mulsd  %xmm12,%xmm1
ucomisd %xmm1,%xmm11
jbe    1ad0 <calculateSubgridError_ADR_Sangalli_tau_sd+0x970>
movapd %xmm6,%xmm0
mulsd  0x64f(%rip),%xmm0
subsd  %xmm12,%xmm0
mulsd  %xmm12,%xmm0
ucomisd %xmm11,%xmm0
jb     1b0d <calculateSubgridError_ADR_Sangalli_tau_sd+0x9ad>
sqrtsd %xmm0,%xmm0
call   1070 <cos@plt>
jmp    1d18 <calculateSubgridError_ADR_Sangalli_tau_sd+0xbb8>
movapd %xmm12,%xmm7
movsd  0x5df(%rip),%xmm3
minsd  %xmm3,%xmm7
movapd %xmm6,%xmm0
xorpd  0x66f(%rip),%xmm0
movapd %xmm3,%xmm1
cmpltsd %xmm6,%xmm1
movapd %xmm1,%xmm5
movsd  0x5c2(%rip),%xmm4
andpd  %xmm4,%xmm5
andnpd %xmm0,%xmm1
orpd   %xmm5,%xmm1
minsd  %xmm1,%xmm3
movapd %xmm3,%xmm4
addsd  %xmm3,%xmm4
movapd %xmm7,%xmm1
subsd  %xmm4,%xmm1
mulsd  %xmm7,%xmm1
ucomisd %xmm1,%xmm11
movsd  %xmm7,0x90(%rsp)
movsd  %xmm3,0x138(%rsp)
movsd  %xmm1,0x130(%rsp)
movsd  %xmm4,0x50(%rsp)
jbe    1afd <calculateSubgridError_ADR_Sangalli_tau_sd+0x99d>
movapd %xmm4,%xmm0
subsd  %xmm7,%xmm0
mulsd  %xmm7,%xmm0
ucomisd %xmm11,%xmm0
jb     1b1c <calculateSubgridError_ADR_Sangalli_tau_sd+0x9bc>
sqrtsd %xmm0,%xmm0
call   1070 <cos@plt>
jmp    1b36 <calculateSubgridError_ADR_Sangalli_tau_sd+0x9d6>
ucomisd 0x580(%rip),%xmm1
movsd  0x570(%rip),%xmm0
ja     1d41 <calculateSubgridError_ADR_Sangalli_tau_sd+0xbe1>
ucomisd %xmm11,%xmm1
jb     1d0a <calculateSubgridError_ADR_Sangalli_tau_sd+0xbaa>
xorps  %xmm0,%xmm0
sqrtsd %xmm1,%xmm0
jmp    1d13 <calculateSubgridError_ADR_Sangalli_tau_sd+0xbb3>
ucomisd %xmm11,%xmm1
jb     1b28 <calculateSubgridError_ADR_Sangalli_tau_sd+0x9c8>
xorps  %xmm0,%xmm0
sqrtsd %xmm1,%xmm0
jmp    1b31 <calculateSubgridError_ADR_Sangalli_tau_sd+0x9d1>
call   1080 <sqrt@plt>
call   1070 <cos@plt>
jmp    1d18 <calculateSubgridError_ADR_Sangalli_tau_sd+0xbb8>
call   1080 <sqrt@plt>
call   1070 <cos@plt>
jmp    1b36 <calculateSubgridError_ADR_Sangalli_tau_sd+0x9d6>
movapd %xmm1,%xmm0
call   1080 <sqrt@plt>
call   1040 <cosh@plt>
movsd  %xmm0,0xe8(%rsp)
movsd  0x90(%rsp),%xmm0
call   1030 <sinh@plt>
movsd  %xmm0,0x128(%rsp)
movsd  0x90(%rsp),%xmm0
call   1040 <cosh@plt>
movsd  0x138(%rsp),%xmm8
movapd %xmm8,%xmm4
mulsd  %xmm8,%xmm4
movapd %xmm4,%xmm1
movsd  0x128(%rsp),%xmm10
mulsd  %xmm10,%xmm1
movsd  0xe8(%rsp),%xmm7
movapd %xmm7,%xmm2
subsd  %xmm0,%xmm2
movapd %xmm8,%xmm3
mulsd  %xmm10,%xmm3
addsd  %xmm3,%xmm2
divsd  %xmm2,%xmm1
subsd  0x50(%rsp),%xmm1
movsd  0x473(%rip),%xmm11
divsd  %xmm1,%xmm11
movsd  0x46e(%rip),%xmm5
movapd %xmm5,%xmm9
subsd  %xmm4,%xmm9
movapd %xmm8,%xmm1
mulsd  0x45f(%rip),%xmm1
addsd  %xmm5,%xmm4
mulsd  %xmm10,%xmm4
movapd %xmm1,%xmm5
mulsd  %xmm7,%xmm5
addsd  %xmm4,%xmm5
movapd %xmm7,%xmm2
addsd  %xmm7,%xmm2
movapd %xmm0,%xmm6
addsd  %xmm0,%xmm6
subsd  %xmm6,%xmm2
addsd  %xmm3,%xmm2
movsd  0x90(%rsp),%xmm4
movapd %xmm4,%xmm3
movsd  0x3ed(%rip),%xmm6
addsd  %xmm6,%xmm3
unpcklpd %xmm2,%xmm3
mulsd  %xmm8,%xmm5
unpcklpd %xmm5,%xmm1
divpd  %xmm3,%xmm1
addsd  %xmm1,%xmm9
unpckhpd %xmm1,%xmm1
addsd  %xmm9,%xmm1
movapd %xmm8,%xmm2
mulsd  0x3f5(%rip),%xmm2
mulsd  %xmm8,%xmm2
mulsd  %xmm8,%xmm2
addsd  %xmm6,%xmm2
divsd  %xmm2,%xmm1
movapd 0x80(%rsp),%xmm2
movapd %xmm2,%xmm3
mulsd  %xmm2,%xmm3
mulsd  %xmm1,%xmm3
movsd  0x38(%rsp),%xmm5
divsd  %xmm5,%xmm3
movapd %xmm3,0xd0(%rsp)
movsd  %xmm0,0x8(%rsp)
movsd  %xmm10,(%rsp)
movsd  %xmm11,0x20(%rsp)
divsd  %xmm5,%xmm11
movsd  %xmm11,0x50(%rsp)
movsd  %xmm11,0x28(%rsp)
movsd  %xmm1,0x10(%rsp)
movsd  %xmm3,0x18(%rsp)
lea    0x40a(%rip),%rdi
movapd %xmm2,%xmm0
movapd 0x100(%rsp),%xmm1
movapd %xmm8,%xmm2
movapd 0xf0(%rsp),%xmm3
movsd  0x130(%rsp),%xmm6
mov    $0x8,%al
call   1050 <printf@plt>
movapd 0xd0(%rsp),%xmm7
movsd  0x50(%rsp),%xmm4
xorpd  %xmm11,%xmm11
jmp    1e14 <calculateSubgridError_ADR_Sangalli_tau_sd+0xcb4>
movapd %xmm1,%xmm0
call   1080 <sqrt@plt>
call   1040 <cosh@plt>
xorpd  %xmm11,%xmm11
movsd  0x2f3(%rip),%xmm7
movapd 0x80(%rsp),%xmm2
movapd 0x100(%rsp),%xmm6
movapd 0xf0(%rsp),%xmm12
mov    0x1c0(%rsp),%rax
movsd  (%rax,%rbp,8),%xmm10
movsd  0x310(%rip),%xmm9
movapd %xmm9,%xmm4
divsd  %xmm10,%xmm4
movapd %xmm0,%xmm3
addsd  %xmm9,%xmm3
movapd %xmm12,%xmm13
addsd  %xmm12,%xmm13
mulsd  %xmm6,%xmm13
subsd  %xmm13,%xmm3
movapd %xmm2,%xmm1
xorpd  0x335(%rip),%xmm1
unpcklpd %xmm6,%xmm1
mulpd  %xmm2,%xmm1
movapd %xmm1,%xmm5
unpckhpd %xmm1,%xmm5
divsd  %xmm3,%xmm5
movsd  0x2b8(%rip),%xmm8
movapd %xmm8,%xmm3
subsd  %xmm5,%xmm3
addsd  %xmm7,%xmm3
divsd  %xmm3,%xmm4
movsd  0x287(%rip),%xmm3
mulsd  %xmm3,%xmm10
divsd  %xmm13,%xmm3
movapd %xmm9,%xmm5
subsd  %xmm3,%xmm5
movapd %xmm0,%xmm7
mulsd  0x260(%rip),%xmm7
addsd  %xmm5,%xmm7
addsd  %xmm0,%xmm0
addsd  %xmm8,%xmm0
movapd %xmm12,%xmm3
mulsd  %xmm6,%xmm3
subsd  %xmm3,%xmm0
unpcklpd %xmm0,%xmm10
divpd  %xmm10,%xmm1
movapd %xmm1,%xmm0
unpckhpd %xmm1,%xmm0
subsd  %xmm0,%xmm7
mulsd  %xmm1,%xmm7
ucomisd %xmm11,%xmm7
movsd  %xmm4,0x50(%rsp)
jbe    1eb5 <calculateSubgridError_ADR_Sangalli_tau_sd+0xd55>
lea    0x381(%rip),%rdi
movapd %xmm7,%xmm0
mov    $0x1,%al
call   1050 <printf@plt>
movapd 0xf0(%rsp),%xmm1
divsd  0x238(%rip),%xmm1
movapd 0x100(%rsp),%xmm2
mulsd  0x22f(%rip),%xmm2
movsd  0x1cf(%rip),%xmm0
divsd  %xmm2,%xmm0
minsd  0x223(%rip),%xmm0
minsd  %xmm0,%xmm1
xorpd  0x247(%rip),%xmm1
movapd 0x80(%rsp),%xmm0
mulsd  %xmm0,%xmm0
mulsd  %xmm1,%xmm0
divsd  0x38(%rsp),%xmm0
movapd %xmm0,0x80(%rsp)
lea    0x335(%rip),%rdi
mov    $0x1,%al
call   1050 <printf@plt>
xorpd  %xmm11,%xmm11
movapd 0x80(%rsp),%xmm7
movapd %xmm7,0xd0(%rsp)
xor    %edi,%edi
ucomisd %xmm7,%xmm11
setae  %dil
xor    %eax,%eax
call   1060 <assert@plt>
xor    %edi,%edi
movsd  0x50(%rsp),%xmm0
ucomisd 0x1b8(%rip),%xmm0
setae  %dil
xor    %eax,%eax
call   1060 <assert@plt>
xorpd  %xmm11,%xmm11
mov    0x208(%rsp),%rax
movsd  0x50(%rsp),%xmm0
movsd  %xmm0,(%rax,%rbp,8)
mov    0x210(%rsp),%rax
movaps 0xd0(%rsp),%xmm0
movsd  %xmm0,(%rax,%rbp,8)
movsd  0x38(%rsp),%xmm0
maxsd  0x160(%rsp),%xmm0
mov    0x200(%rsp),%rax
movsd  %xmm0,(%rax,%rbp,8)
movapd 0xa0(%rsp),%xmm0
ucomisd %xmm11,%xmm0
jb     1f50 <calculateSubgridError_ADR_Sangalli_tau_sd+0xdf0>
xorps  %xmm1,%xmm1
sqrtsd %xmm0,%xmm1
jmp    1f5e <calculateSubgridError_ADR_Sangalli_tau_sd+0xdfe>
nopl   (%rax)
call   1080 <sqrt@plt>
xorpd  %xmm11,%xmm11
movapd %xmm0,%xmm1
movsd  0x30(%rsp),%xmm0
ucomisd %xmm11,%xmm0
jb     12d0 <calculateSubgridError_ADR_Sangalli_tau_sd+0x170>
sqrtsd %xmm0,%xmm0
jmp    12e6 <calculateSubgridError_ADR_Sangalli_tau_sd+0x186>
add    $0x188,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [119 x i8] c"Sangalli general reduced formula Da= %12.5e Pe=%12.5e cfl=%12.5e t_11=%12.5e tau_11=%12.5e t_00=%12.5e tau_00=%12.5e \0A\00"
@.str.1 = [221 x i8] c"\09 Sangalli general h_e= %12.5e Da= %12.5e DaEval= %12.5e Pe=%12.5e PeEval= %12.5e cfl=%12.5e \0A\09 gamma2= %12.5e coshGamma=%12.5e sinhAlpha=%12.5e coshAlpha=%12.5e \0A\09 t_11=%12.5e tau_11=%12.5e t_00= %12.5e tau_00=%12.5e \0A\00"
@.str.2 = [40 x i8] c"Sangalli tau_11 = %12.5e > 0 switching \00"
@.str.3 = [18 x i8] c"tau_11 = %12.5e \0A\00"
define void @calculateSubgridError_ADR_Sangalli_tau_sd(i32 %0, i32 %1, i32 %2, i32* %3, i32* %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) {
%18 = alloca i32
%19 = alloca i32
%20 = alloca i32
%21 = alloca i32*
%22 = alloca i32*
%23 = alloca double*
%24 = alloca double*
%25 = alloca double*
%26 = alloca double*
%27 = alloca double*
%28 = alloca double*
%29 = alloca double*
%30 = alloca double*
%31 = alloca double*
%32 = alloca double*
%33 = alloca double*
%34 = alloca double*
%35 = alloca i32
%36 = alloca i32
%37 = alloca i32
%38 = alloca i32
%39 = alloca i32
%40 = alloca i32
%41 = alloca i32
%42 = alloca i32
%43 = alloca double
%44 = alloca double
%45 = alloca double
%46 = alloca double
%47 = alloca double
%48 = alloca [3 x 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
store i32 %0, i32* %18
store i32 %1, i32* %19
store i32 %2, i32* %20
store i32* %3, i32** %21
store i32* %4, i32** %22
store double* %5, double** %23
store double* %6, double** %24
store double* %7, double** %25
store double* %8, double** %26
store double* %9, double** %27
store double* %10, double** %28
store double* %11, double** %29
store double* %12, double** %30
store double* %13, double** %31
store double* %14, double** %32
store double* %15, double** %33
store double* %16, double** %34
%70 = load i32*, i32** %21
%71 = load i32, i32* %20
%72 = sext i32 %71 to i64
%73 = getelementptr inbounds i32, i32* %70, i64 %72
%74 = load i32, i32* %73
store i32 %74, i32* %41
%75 = load i32, i32* %20
%76 = load i32, i32* %20
%77 = mul nsw i32 %75, %76
store i32 %77, i32* %42
store double 1.296000e+03, double* %53
store i32 0, i32* %35
br label %78
78: ; preds = %807, %17
%79 = load i32, i32* %35
%80 = load i32, i32* %18
%81 = icmp slt i32 %79, %80
br i1 %81, label %82, label %810
82: ; preds = %78
store i32 0, i32* %36
br label %83
83: ; preds = %803, %82
%84 = load i32, i32* %36
%85 = load i32, i32* %19
%86 = icmp slt i32 %84, %85
br i1 %86, label %87, label %806
87: ; preds = %83
store double 0.000000e+00, double* %43
store double 0.000000e+00, double* %44
store i32 0, i32* %37
br label %88
88: ; preds = %170, %87
%89 = load i32, i32* %37
%90 = load i32, i32* %20
%91 = icmp slt i32 %89, %90
br i1 %91, label %92, label %173
92: ; preds = %88
%93 = load double*, double** %25
%94 = load i32, i32* %35
%95 = load i32, i32* %19
%96 = mul nsw i32 %94, %95
%97 = load i32, i32* %20
%98 = mul nsw i32 %96, %97
%99 = load i32, i32* %36
%100 = load i32, i32* %20
%101 = mul nsw i32 %99, %100
%102 = add nsw i32 %98, %101
%103 = load i32, i32* %37
%104 = add nsw i32 %102, %103
%105 = sext i32 %104 to i64
%106 = getelementptr inbounds double, double* %93, i64 %105
%107 = load double, double* %106
%108 = load i32, i32* %37
%109 = sext i32 %108 to i64
%110 = getelementptr inbounds [3 x double], [3 x double]* %48, i64 0, i64 %109
store double %107, double* %110
%111 = load i32*, i32** %21
%112 = load i32, i32* %37
%113 = sext i32 %112 to i64
%114 = getelementptr inbounds i32, i32* %111, i64 %113
%115 = load i32, i32* %114
store i32 %115, i32* %40
br label %116
116: ; preds = %166, %92
%117 = load i32, i32* %40
%118 = load i32*, i32** %21
%119 = load i32, i32* %37
%120 = add nsw i32 %119, 1
%121 = sext i32 %120 to i64
%122 = getelementptr inbounds i32, i32* %118, i64 %121
%123 = load i32, i32* %122
%124 = icmp slt i32 %117, %123
br i1 %124, label %125, label %169
125: ; preds = %116
%126 = load double*, double** %27
%127 = load i32, i32* %35
%128 = load i32, i32* %19
%129 = mul nsw i32 %127, %128
%130 = load i32, i32* %41
%131 = mul nsw i32 %129, %130
%132 = load i32, i32* %36
%133 = load i32, i32* %41
%134 = mul nsw i32 %132, %133
%135 = add nsw i32 %131, %134
%136 = load i32, i32* %40
%137 = add nsw i32 %135, %136
%138 = sext i32 %137 to i64
%139 = getelementptr inbounds double, double* %126, i64 %138
%140 = load double, double* %139
%141 = load double*, double** %28
%142 = load i32, i32* %35
%143 = load i32, i32* %19
%144 = mul nsw i32 %142, %143
%145 = load i32, i32* %20
%146 = mul nsw i32 %144, %145
%147 = load i32, i32* %36
%148 = load i32, i32* %20
%149 = mul nsw i32 %147, %148
%150 = add nsw i32 %146, %149
%151 = load i32*, i32** %22
%152 = load i32, i32* %40
%153 = sext i32 %152 to i64
%154 = getelementptr inbounds i32, i32* %151, i64 %153
%155 = load i32, i32* %154
%156 = add nsw i32 %150, %155
%157 = sext i32 %156 to i64
%158 = getelementptr inbounds double, double* %141, i64 %157
%159 = load double, double* %158
%160 = load i32, i32* %37
%161 = sext i32 %160 to i64
%162 = getelementptr inbounds [3 x double], [3 x double]* %48, i64 0, i64 %161
%163 = load double, double* %162
%164 = fneg double %140
%165 = call double @llvm.fmuladd.f64(double %164, double %159, double %163)
store double %165, double* %162
br label %166
166: ; preds = %125
%167 = load i32, i32* %40
%168 = add nsw i32 %167, 1
store i32 %168, i32* %40
br label %116
169: ; preds = %116
br label %170
170: ; preds = %169
%171 = load i32, i32* %37
%172 = add nsw i32 %171, 1
store i32 %172, i32* %37
br label %88
173: ; preds = %88
store double 0.000000e+00, double* %50
store double 0.000000e+00, double* %51
store double 0.000000e+00, double* %55
store i32 0, i32* %37
br label %174
174: ; preds = %280, %173
%175 = load i32, i32* %37
%176 = load i32, i32* %20
%177 = icmp slt i32 %175, %176
br i1 %177, label %178, label %283
178: ; preds = %174
store double 0.000000e+00, double* %52
store double 0.000000e+00, double* %54
store i32 0, i32* %38
br label %179
179: ; preds = %265, %178
%180 = load i32, i32* %38
%181 = load i32, i32* %20
%182 = icmp slt i32 %180, %181
br i1 %182, label %183, label %268
183: ; preds = %179
store double 0.000000e+00, double* %49
store i32 0, i32* %39
br label %184
184: ; preds = %229, %183
%185 = load i32, i32* %39
%186 = load i32, i32* %20
%187 = icmp slt i32 %185, %186
br i1 %187, label %188, label %232
188: ; preds = %184
%189 = load double*, double** %23
%190 = load i32, i32* %35
%191 = load i32, i32* %19
%192 = mul nsw i32 %190, %191
%193 = load i32, i32* %42
%194 = mul nsw i32 %192, %193
%195 = load i32, i32* %36
%196 = load i32, i32* %42
%197 = mul nsw i32 %195, %196
%198 = add nsw i32 %194, %197
%199 = load i32, i32* %39
%200 = load i32, i32* %20
%201 = mul nsw i32 %199, %200
%202 = add nsw i32 %198, %201
%203 = load i32, i32* %37
%204 = add nsw i32 %202, %203
%205 = sext i32 %204 to i64
%206 = getelementptr inbounds double, double* %189, i64 %205
%207 = load double, double* %206
%208 = load double*, double** %23
%209 = load i32, i32* %35
%210 = load i32, i32* %19
%211 = mul nsw i32 %209, %210
%212 = load i32, i32* %42
%213 = mul nsw i32 %211, %212
%214 = load i32, i32* %36
%215 = load i32, i32* %42
%216 = mul nsw i32 %214, %215
%217 = add nsw i32 %213, %216
%218 = load i32, i32* %39
%219 = load i32, i32* %20
%220 = mul nsw i32 %218, %219
%221 = add nsw i32 %217, %220
%222 = load i32, i32* %38
%223 = add nsw i32 %221, %222
%224 = sext i32 %223 to i64
%225 = getelementptr inbounds double, double* %208, i64 %224
%226 = load double, double* %225
%227 = load double, double* %49
%228 = call double @llvm.fmuladd.f64(double %207, double %226, double %227)
store double %228, double* %49
br label %229
229: ; preds = %188
%230 = load i32, i32* %39
%231 = add nsw i32 %230, 1
store i32 %231, i32* %39
br label %184
232: ; preds = %184
%233 = load double, double* %49
%234 = load i32, i32* %38
%235 = sext i32 %234 to i64
%236 = getelementptr inbounds [3 x double], [3 x double]* %48, i64 0, i64 %235
%237 = load double, double* %236
%238 = load double, double* %52
%239 = call double @llvm.fmuladd.f64(double %233, double %237, double %238)
store double %239, double* %52
%240 = load double, double* %49
%241 = load double, double* %49
%242 = load double, double* %51
%243 = call double @llvm.fmuladd.f64(double %240, double %241, double %242)
store double %243, double* %51
%244 = load double*, double** %23
%245 = load i32, i32* %35
%246 = load i32, i32* %19
%247 = mul nsw i32 %245, %246
%248 = load i32, i32* %42
%249 = mul nsw i32 %247, %248
%250 = load i32, i32* %36
%251 = load i32, i32* %42
%252 = mul nsw i32 %250, %251
%253 = add nsw i32 %249, %252
%254 = load i32, i32* %38
%255 = load i32, i32* %20
%256 = mul nsw i32 %254, %255
%257 = add nsw i32 %253, %256
%258 = load i32, i32* %37
%259 = add nsw i32 %257, %258
%260 = sext i32 %259 to i64
%261 = getelementptr inbounds double, double* %244, i64 %260
%262 = load double, double* %261
%263 = load double, double* %54
%264 = fadd double %263, %262
store double %264, double* %54
br label %265
265: ; preds = %232
%266 = load i32, i32* %38
%267 = add nsw i32 %266, 1
store i32 %267, i32* %38
br label %179
268: ; preds = %179
%269 = load double, double* %54
%270 = load double, double* %54
%271 = load double, double* %55
%272 = call double @llvm.fmuladd.f64(double %269, double %270, double %271)
store double %272, double* %55
%273 = load i32, i32* %37
%274 = sext i32 %273 to i64
%275 = getelementptr inbounds [3 x double], [3 x double]* %48, i64 0, i64 %274
%276 = load double, double* %275
%277 = load double, double* %52
%278 = load double, double* %50
%279 = call double @llvm.fmuladd.f64(double %276, double %277, double %278)
store double %279, double* %50
br label %280
280: ; preds = %268
%281 = load i32, i32* %37
%282 = add nsw i32 %281, 1
store i32 %282, i32* %37
br label %174
283: ; preds = %174
store i32 0, i32* %37
br label %284
284: ; preds = %341, %283
%285 = load i32, i32* %37
%286 = load i32, i32* %20
%287 = icmp slt i32 %285, %286
br i1 %287, label %288, label %344
288: ; preds = %284
%289 = load i32*, i32** %21
%290 = load i32, i32* %37
%291 = sext i32 %290 to i64
%292 = getelementptr inbounds i32, i32* %289, i64 %291
%293 = load i32, i32* %292
store i32 %293, i32* %40
br label %294
294: ; preds = %337, %288
%295 = load i32, i32* %40
%296 = load i32*, i32** %21
%297 = load i32, i32* %37
%298 = add nsw i32 %297, 1
%299 = sext i32 %298 to i64
%300 = getelementptr inbounds i32, i32* %296, i64 %299
%301 = load i32, i32* %300
%302 = icmp slt i32 %295, %301
br i1 %302, label %303, label %340
303: ; preds = %294
%304 = load i32, i32* %37
%305 = load i32*, i32** %22
%306 = load i32, i32* %40
%307 = sext i32 %306 to i64
%308 = getelementptr inbounds i32, i32* %305, i64 %307
%309 = load i32, i32* %308
%310 = icmp eq i32 %304, %309
br i1 %310, label %311, label %336
311: ; preds = %303
%312 = load double*, double** %26
%313 = load i32, i32* %35
%314 = load i32, i32* %19
%315 = mul nsw i32 %313, %314
%316 = load i32, i32* %41
%317 = mul nsw i32 %315, %316
%318 = load i32, i32* %36
%319 = load i32, i32* %41
%320 = mul nsw i32 %318, %319
%321 = add nsw i32 %317, %320
%322 = load i32, i32* %40
%323 = add nsw i32 %321, %322
%324 = sext i32 %323 to i64
%325 = getelementptr inbounds double, double* %312, i64 %324
%326 = load double, double* %325
store double %326, double* %45
%327 = load double, double* %45
%328 = load double, double* %44
%329 = fcmp ogt double %327, %328
br i1 %329, label %330, label %332
330: ; preds = %311
%331 = load double, double* %45
br label %334
332: ; preds = %311
%333 = load double, double* %44
br label %334
334: ; preds = %332, %330
%335 = phi double [ %331, %330 ], [ %333, %332 ]
store double %335, double* %44
br label %336
336: ; preds = %334, %303
br label %337
337: ; preds = %336
%338 = load i32, i32* %40
%339 = add nsw i32 %338, 1
store i32 %339, i32* %40
br label %294
340: ; preds = %294
br label %341
341: ; preds = %340
%342 = load i32, i32* %37
%343 = add nsw i32 %342, 1
store i32 %343, i32* %37
br label %284
344: ; preds = %284
%345 = load double*, double** %29
%346 = load i32, i32* %35
%347 = load i32, i32* %19
%348 = mul nsw i32 %346, %347
%349 = load i32, i32* %36
%350 = add nsw i32 %348, %349
%351 = sext i32 %350 to i64
%352 = getelementptr inbounds double, double* %345, i64 %351
%353 = load double, double* %352
%354 = load double, double* %44
%355 = fmul double %354, %353
store double %355, double* %44
%356 = load double, double* %53
%357 = load double, double* %44
%358 = fmul double %356, %357
%359 = load double, double* %44
%360 = fmul double %358, %359
%361 = load double, double* %51
%362 = fmul double %361, %360
store double %362, double* %51
%363 = load double, double* %55
%364 = call double @sqrt(double %363)
%365 = fdiv double 1.000000e+00, %364
store double %365, double* %57
%366 = load double, double* %50
%367 = call double @sqrt(double %366)
store double %367, double* %46
%368 = load double, double* %51
%369 = call double @sqrt(double %368)
%370 = fmul double 2.500000e-01, %369
store double %370, double* %47
%371 = load double, double* %50
%372 = call double @sqrt(double %371)
%373 = load double, double* %51
%374 = call double @sqrt(double %373)
%375 = fadd double %374, 0x3D719799812DEA11
%376 = fdiv double %372, %375
store double %376, double* %63
%377 = load double*, double** %24
%378 = load i32, i32* %35
%379 = load i32, i32* %19
%380 = mul nsw i32 %378, %379
%381 = load i32, i32* %36
%382 = add nsw i32 %380, %381
%383 = sext i32 %382 to i64
%384 = getelementptr inbounds double, double* %377, i64 %383
%385 = load double, double* %384
%386 = load double*, double** %30
%387 = load i32, i32* %35
%388 = load i32, i32* %19
%389 = mul nsw i32 %387, %388
%390 = load i32, i32* %36
%391 = add nsw i32 %389, %390
%392 = sext i32 %391 to i64
%393 = getelementptr inbounds double, double* %386, i64 %392
%394 = load double, double* %393
%395 = fadd double %385, %394
%396 = load double, double* %46
%397 = fadd double %396, 0x3D719799812DEA11
%398 = fdiv double %395, %397
store double %398, double* %56
%399 = load double, double* %56
%400 = call double @llvm.fabs.f64(double %399)
%401 = fcmp olt double %400, 1.000000e-08
br i1 %401, label %402, label %409
402: ; preds = %344
store double 0.000000e+00, double* %59
%403 = load double, double* %50
%404 = load double, double* %51
%405 = fadd double %403, %404
%406 = fadd double %405, 1.000000e-08
%407 = call double @sqrt(double %406)
%408 = fdiv double 1.000000e+00, %407
store double %408, double* %58
br label %715
409: ; preds = %344
%410 = load double, double* %56
%411 = load double, double* %63
%412 = fmul double %411, 1.000000e+01
%413 = fcmp ogt double %410, %412
br i1 %413, label %414, label %460
414: ; preds = %409
%415 = load double*, double** %24
%416 = load i32, i32* %35
%417 = load i32, i32* %19
%418 = mul nsw i32 %416, %417
%419 = load i32, i32* %36
%420 = add nsw i32 %418, %419
%421 = sext i32 %420 to i64
%422 = getelementptr inbounds double, double* %415, i64 %421
%423 = load double, double* %422
%424 = load double*, double** %30
%425 = load i32, i32* %35
%426 = load i32, i32* %19
%427 = mul nsw i32 %425, %426
%428 = load i32, i32* %36
%429 = add nsw i32 %427, %428
%430 = sext i32 %429 to i64
%431 = getelementptr inbounds double, double* %424, i64 %430
%432 = load double, double* %431
%433 = fadd double %423, %432
%434 = fdiv double 5.000000e-01, %433
store double %434, double* %58
%435 = load double, double* %57
%436 = fneg double %435
%437 = load double, double* %57
%438 = fmul double %436, %437
%439 = load double*, double** %24
%440 = load i32, i32* %35
%441 = load i32, i32* %19
%442 = mul nsw i32 %440, %441
%443 = load i32, i32* %36
%444 = add nsw i32 %442, %443
%445 = sext i32 %444 to i64
%446 = getelementptr inbounds double, double* %439, i64 %445
%447 = load double, double* %446
%448 = load double*, double** %30
%449 = load i32, i32* %35
%450 = load i32, i32* %19
%451 = mul nsw i32 %449, %450
%452 = load i32, i32* %36
%453 = add nsw i32 %451, %452
%454 = sext i32 %453 to i64
%455 = getelementptr inbounds double, double* %448, i64 %454
%456 = load double, double* %455
%457 = fadd double %447, %456
%458 = fmul double 1.200000e+01, %457
%459 = fdiv double %438, %458
store double %459, double* %59
br label %714
460: ; preds = %409
%461 = load double, double* %46
%462 = fcmp olt double %461, 1.000000e-08
br i1 %462, label %463, label %558
463: ; preds = %460
%464 = load double, double* %63
%465 = load double, double* %56
%466 = load double, double* %63
%467 = call double @llvm.fmuladd.f64(double 2.000000e+00, double %465, double %466)
%468 = fmul double %464, %467
%469 = fcmp olt double %468, 0.000000e+00
br i1 %469, label %470, label %479
470: ; preds = %463
%471 = load double, double* %63
%472 = load double, double* %56
%473 = load double, double* %63
%474 = fneg double %473
%475 = call double @llvm.fmuladd.f64(double -2.000000e+00, double %472, double %474)
%476 = fmul double %471, %475
%477 = call double @sqrt(double %476)
%478 = call double @cos(double %477)
store double %478, double* %62
br label %497
479: ; preds = %463
%480 = load double, double* %63
%481 = load double, double* %56
%482 = load double, double* %63
%483 = call double @llvm.fmuladd.f64(double 2.000000e+00, double %481, double %482)
%484 = fmul double %480, %483
%485 = fcmp ogt double %484, 1.000000e+03
br i1 %485, label %486, label %488
486: ; preds = %479
%487 = call double @cosh(double 1.000000e+02)
store double %487, double* %62
br label %496
488: ; preds = %479
%489 = load double, double* %63
%490 = load double, double* %56
%491 = load double, double* %63
%492 = call double @llvm.fmuladd.f64(double 2.000000e+00, double %490, double %491)
%493 = fmul double %489, %492
%494 = call double @sqrt(double %493)
%495 = call double @cosh(double %494)
store double %495, double* %62
br label %496
496: ; preds = %488, %486
br label %497
497: ; preds = %496, %470
%498 = load double*, double** %24
%499 = load i32, i32* %35
%500 = load i32, i32* %19
%501 = mul nsw i32 %499, %500
%502 = load i32, i32* %36
%503 = add nsw i32 %501, %502
%504 = sext i32 %503 to i64
%505 = getelementptr inbounds double, double* %498, i64 %504
%506 = load double, double* %505
%507 = fdiv double -1.000000e+00, %506
%508 = fmul double %507, 1.000000e+00
%509 = load double, double* %63
%510 = load double, double* %56
%511 = fmul double %509, %510
%512 = load double, double* %62
%513 = fsub double %512, 1.000000e+00
%514 = load double, double* %63
%515 = fmul double 2.000000e+00, %514
%516 = load double, double* %56
%517 = fneg double %515
%518 = call double @llvm.fmuladd.f64(double %517, double %516, double %513)
%519 = fdiv double %511, %518
%520 = fsub double -2.000000e+00, %519
%521 = fadd double %520, 1.000000e-08
%522 = fdiv double %508, %521
store double %522, double* %58
%523 = load double, double* %57
%524 = fneg double %523
%525 = load double, double* %57
%526 = fmul double %524, %525
%527 = load double*, double** %24
%528 = load i32, i32* %35
%529 = load i32, i32* %19
%530 = mul nsw i32 %528, %529
%531 = load i32, i32* %36
%532 = add nsw i32 %530, %531
%533 = sext i32 %532 to i64
%534 = getelementptr inbounds double, double* %527, i64 %533
%535 = load double, double* %534
%536 = fmul double %535, 6.000000e+00
%537 = fdiv double %526, %536
%538 = load double, double* %63
%539 = fmul double 2.000000e+00, %538
%540 = load double, double* %56
%541 = fmul double %539, %540
%542 = fdiv double 6.000000e+00, %541
%543 = fsub double -1.000000e+00, %542
%544 = load double, double* %62
%545 = call double @llvm.fmuladd.f64(double 3.000000e+00, double %544, double %543)
%546 = load double, double* %63
%547 = load double, double* %56
%548 = fmul double %546, %547
%549 = load double, double* %62
%550 = call double @llvm.fmuladd.f64(double 2.000000e+00, double %549, double -2.000000e+00)
%551 = load double, double* %63
%552 = load double, double* %56
%553 = fneg double %551
%554 = call double @llvm.fmuladd.f64(double %553, double %552, double %550)
%555 = fdiv double %548, %554
%556 = fsub double %545, %555
%557 = fmul double %537, %556
store double %557, double* %59
br label %713
558: ; preds = %460
%559 = load double, double* %56
%560 = fcmp oge double %559, 0.000000e+00
br i1 %560, label %561, label %596
561: ; preds = %558
br i1 false, label %562, label %596
562: ; preds = %561
%563 = load double, double* %63
%564 = fdiv double %563, 6.000000e+00
%565 = load double, double* %56
%566 = fdiv double 5.000000e-01, %565
%567 = call double @llvm.minnum.f64(double %566, double 5.000000e-01)
%568 = call double @llvm.minnum.f64(double %564, double %567)
store double %568, double* %60
%569 = load double, double* %63
%570 = fdiv double %569, 6.000000e+01
%571 = load double, double* %56
%572 = fmul double 1.200000e+01, %571
%573 = fdiv double 1.000000e+00, %572
%574 = call double @llvm.minnum.f64(double %573, double 0x3FA5555555555555)
%575 = call double @llvm.minnum.f64(double %570, double %574)
store double %575, double* %61
%576 = load double, double* %61
%577 = fmul double %576, -1.000000e+00
store double %577, double* %61
%578 = load double, double* %60
%579 = load double, double* %46
%580 = fdiv double %578, %579
store double %580, double* %58
%581 = load double, double* %57
%582 = load double, double* %57
%583 = fmul double %581, %582
%584 = load double, double* %61
%585 = fmul double %583, %584
%586 = load double, double* %46
%587 = fdiv double %585, %586
store double %587, double* %59
%588 = load double, double* %56
%589 = load double, double* %63
%590 = load double, double* %46
%591 = load double, double* %61
%592 = load double, double* %59
%593 = load double, double* %60
%594 = load double, double* %58
%595 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([119 x i8], [119 x i8]* @.str, i64 0, i64 0), double %588, double %589, double %590, double %591, double %592, double %593, double %594)
br label %712
596: ; preds = %561, %558
%597 = load double, double* %63
%598 = call double @llvm.minnum.f64(double %597, double 1.000000e+01)
store double %598, double* %66
%599 = load double, double* %56
%600 = fneg double %599
store double %600, double* %69
%601 = load double, double* %69
%602 = fcmp olt double %601, -1.000000e+01
br i1 %602, label %603, label %604
603: ; preds = %596
store double -1.000000e+01, double* %69
br label %604
604: ; preds = %603, %596
%605 = load double, double* %69
%606 = fcmp ogt double %605, 1.000000e+01
br i1 %606, label %607, label %608
607: ; preds = %604
store double 1.000000e+01, double* %69
br label %608
608: ; preds = %607, %604
%609 = load double, double* %66
%610 = load double, double* %69
%611 = load double, double* %66
%612 = call double @llvm.fmuladd.f64(double -2.000000e+00, double %610, double %611)
%613 = fmul double %609, %612
store double %613, double* %67
%614 = load double, double* %67
%615 = fcmp olt double %614, 0.000000e+00
br i1 %615, label %616, label %625
616: ; preds = %608
%617 = load double, double* %66
%618 = load double, double* %69
%619 = load double, double* %66
%620 = fneg double %619
%621 = call double @llvm.fmuladd.f64(double 2.000000e+00, double %618, double %620)
%622 = fmul double %617, %621
%623 = call double @sqrt(double %622)
%624 = call double @cos(double %623)
store double %624, double* %62
br label %629
625: ; preds = %608
%626 = load double, double* %67
%627 = call double @sqrt(double %626)
%628 = call double @cosh(double %627)
store double %628, double* %62
br label %629
629: ; preds = %625, %616
%630 = load double, double* %66
%631 = call double @sinh(double %630)
store double %631, double* %64
%632 = load double, double* %66
%633 = call double @cosh(double %632)
store double %633, double* %65
%634 = load double, double* %69
%635 = load double, double* %69
%636 = load double, double* %69
%637 = fmul double %635, %636
%638 = load double, double* %64
%639 = fmul double %637, %638
%640 = load double, double* %65
%641 = fneg double %640
%642 = load double, double* %62
%643 = fadd double %641, %642
%644 = load double, double* %69
%645 = load double, double* %64
%646 = call double @llvm.fmuladd.f64(double %644, double %645, double %643)
%647 = fdiv double %639, %646
%648 = call double @llvm.fmuladd.f64(double -2.000000e+00, double %634, double %647)
%649 = fdiv double 1.000000e+00, %648
store double %649, double* %60
%650 = load double, double* %69
%651 = load double, double* %69
%652 = fneg double %650
%653 = call double @llvm.fmuladd.f64(double %652, double %651, double -3.000000e+00)
%654 = load double, double* %69
%655 = fmul double 3.000000e+00, %654
%656 = load double, double* %66
%657 = fadd double %656, 0x3D719799812DEA11
%658 = fdiv double %655, %657
%659 = fadd double %653, %658
%660 = load double, double* %69
%661 = load double, double* %69
%662 = fmul double 3.000000e+00, %661
%663 = load double, double* %62
%664 = load double, double* %64
%665 = load double, double* %69
%666 = load double, double* %69
%667 = call double @llvm.fmuladd.f64(double %665, double %666, double -3.000000e+00)
%668 = fmul double %664, %667
%669 = call double @llvm.fmuladd.f64(double %662, double %663, double %668)
%670 = fmul double %660, %669
%671 = load double, double* %65
%672 = load double, double* %62
%673 = fmul double 2.000000e+00, %672
%674 = call double @llvm.fmuladd.f64(double -2.000000e+00, double %671, double %673)
%675 = load double, double* %69
%676 = load double, double* %64
%677 = call double @llvm.fmuladd.f64(double %675, double %676, double %674)
%678 = fdiv double %670, %677
%679 = fadd double %659, %678
%680 = load double, double* %69
%681 = fmul double 6.000000e+00, %680
%682 = load double, double* %69
%683 = fmul double %681, %682
%684 = load double, double* %69
%685 = call double @llvm.fmuladd.f64(double %683, double %684, double 0x3D719799812DEA11)
%686 = fdiv double %679, %685
store double %686, double* %61
%687 = load double, double* %60
%688 = load double, double* %46
%689 = fdiv double %687, %688
store double %689, double* %58
%690 = load double, double* %57
%691 = load double, double* %57
%692 = fmul double %690, %691
%693 = load double, double* %61
%694 = fmul double %692, %693
%695 = load double, double* %46
%696 = fdiv double %694, %695
store double %696, double* %59
%697 = load double, double* %57
%698 = load double, double* %56
%699 = load double, double* %69
%700 = load double, double* %63
%701 = load double, double* %66
%702 = load double, double* %46
%703 = load double, double* %67
%704 = load double, double* %62
%705 = load double, double* %64
%706 = load double, double* %65
%707 = load double, double* %61
%708 = load double, double* %59
%709 = load double, double* %60
%710 = load double, double* %58
%711 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([221 x i8], [221 x i8]* @.str.1, i64 0, i64 0), double %697, double %698, double %699, double %700, double %701, double %702, double %703, double %704, double %705, double %706, double %707, double %708, double %709, double %710)
br label %712
712: ; preds = %629, %562
br label %713
713: ; preds = %712, %497
br label %714
714: ; preds = %713, %414
br label %715
715: ; preds = %714, %402
%716 = load double, double* %59
%717 = fcmp ogt double %716, 0.000000e+00
br i1 %717, label %718, label %739
718: ; preds = %715
%719 = load double, double* %59
%720 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str.2, i64 0, i64 0), double %719)
%721 = load double, double* %63
%722 = fdiv double %721, 6.000000e+01
%723 = load double, double* %56
%724 = fmul double 1.200000e+01, %723
%725 = fdiv double 1.000000e+00, %724
%726 = call double @llvm.minnum.f64(double %725, double 0x3FA5555555555555)
%727 = call double @llvm.minnum.f64(double %722, double %726)
store double %727, double* %61
%728 = load double, double* %61
%729 = fmul double %728, -1.000000e+00
store double %729, double* %61
%730 = load double, double* %57
%731 = load double, double* %57
%732 = fmul double %730, %731
%733 = load double, double* %61
%734 = fmul double %732, %733
%735 = load double, double* %46
%736 = fdiv double %734, %735
store double %736, double* %59
%737 = load double, double* %59
%738 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.3, i64 0, i64 0), double %737)
br label %739
739: ; preds = %718, %715
%740 = load double, double* %59
%741 = fcmp ole double %740, 0.000000e+00
%742 = zext i1 %741 to i32
%743 = call i32 (i32, ...) bitcast (i32 (...)* @assert to i32 (i32, ...)*)(i32 %742)
%744 = load double, double* %58
%745 = fcmp oge double %744, 0.000000e+00
%746 = zext i1 %745 to i32
%747 = call i32 (i32, ...) bitcast (i32 (...)* @assert to i32 (i32, ...)*)(i32 %746)
%748 = load double, double* %58
%749 = load double*, double** %33
%750 = load i32, i32* %35
%751 = load i32, i32* %19
%752 = mul nsw i32 %750, %751
%753 = load i32, i32* %36
%754 = add nsw i32 %752, %753
%755 = sext i32 %754 to i64
%756 = getelementptr inbounds double, double* %749, i64 %755
store double %748, double* %756
%757 = load double, double* %59
%758 = load double*, double** %34
%759 = load i32, i32* %35
%760 = load i32, i32* %19
%761 = mul nsw i32 %759, %760
%762 = load i32, i32* %36
%763 = add nsw i32 %761, %762
%764 = sext i32 %763 to i64
%765 = getelementptr inbounds double, double* %758, i64 %764
store double %757, double* %765
%766 = load double, double* %46
%767 = load double, double* %47
%768 = fcmp ogt double %766, %767
br i1 %768, label %769, label %779
769: ; preds = %739
%770 = load double, double* %46
%771 = load double*, double** %32
%772 = load i32, i32* %35
%773 = load i32, i32* %19
%774 = mul nsw i32 %772, %773
%775 = load i32, i32* %36
%776 = add nsw i32 %774, %775
%777 = sext i32 %776 to i64
%778 = getelementptr inbounds double, double* %771, i64 %777
store double %770, double* %778
br label %789
779: ; preds = %739
%780 = load double, double* %47
%781 = load double*, double** %32
%782 = load i32, i32* %35
%783 = load i32, i32* %19
%784 = mul nsw i32 %782, %783
%785 = load i32, i32* %36
%786 = add nsw i32 %784, %785
%787 = sext i32 %786 to i64
%788 = getelementptr inbounds double, double* %781, i64 %787
store double %780, double* %788
br label %789
789: ; preds = %779, %769
%790 = load double, double* %50
%791 = call double @sqrt(double %790)
%792 = load double, double* %51
%793 = call double @sqrt(double %792)
%794 = fdiv double %791, %793
%795 = load double*, double** %31
%796 = load i32, i32* %35
%797 = load i32, i32* %19
%798 = mul nsw i32 %796, %797
%799 = load i32, i32* %36
%800 = add nsw i32 %798, %799
%801 = sext i32 %800 to i64
%802 = getelementptr inbounds double, double* %795, i64 %801
store double %794, double* %802
br label %803
803: ; preds = %789
%804 = load i32, i32* %36
%805 = add nsw i32 %804, 1
store i32 %805, i32* %36
br label %83
806: ; preds = %83
br label %807
807: ; preds = %806
%808 = load i32, i32* %35
%809 = add nsw i32 %808, 1
store i32 %809, i32* %35
br label %78
810: ; preds = %78
ret void
}

LLVM IR (-O2):
@.str.1 = [221 x i8] c"\09 Sangalli general h_e= %12.5e Da= %12.5e DaEval= %12.5e Pe=%12.5e PeEval= %12.5e cfl=%12.5e \0A\09 gamma2= %12.5e coshGamma=%12.5e sinhAlpha=%12.5e coshAlpha=%12.5e \0A\09 t_11=%12.5e tau_11=%12.5e t_00= %12.5e tau_00=%12.5e \0A\00"
@.str.2 = [40 x i8] c"Sangalli tau_11 = %12.5e > 0 switching \00"
@.str.3 = [18 x i8] c"tau_11 = %12.5e \0A\00"
define void @calculateSubgridError_ADR_Sangalli_tau_sd(i32 %0, i32 %1, i32 %2, i32* nocapture %3, i32* nocapture %4, double* nocapture %5, double* nocapture %6, double* nocapture %7, double* nocapture %8, double* nocapture %9, double* nocapture %10, double* nocapture %11, double* nocapture %12, double* nocapture writeonly %13, double* nocapture writeonly %14, double* nocapture writeonly %15, double* nocapture writeonly %16) {
%18 = alloca [3 x double]
%19 = sext i32 %2 to i64
%20 = getelementptr inbounds i32, i32* %3, i64 %19
%21 = load i32, i32* %20
%22 = mul nsw i32 %2, %2
%23 = bitcast [3 x double]* %18 to i8*
%24 = icmp sgt i32 %0, 0
br i1 %24, label %25, label %482
25: ; preds = %17
%26 = icmp sgt i32 %1, 0
%27 = icmp sgt i32 %2, 0
%28 = sext i32 %1 to i64
%29 = zext i32 %0 to i64
%30 = zext i32 %1 to i64
%31 = zext i32 %2 to i64
%32 = zext i32 %2 to i64
%33 = zext i32 %2 to i64
%34 = and i64 %31, 1
%35 = icmp eq i32 %2, 1
%36 = and i64 %31, 4294967294
%37 = icmp eq i64 %34, 0
br label %38
38: ; preds = %25, %479
%39 = phi i64 [ 0, %25 ], [ %480, %479 ]
br i1 %26, label %40, label %479
40: ; preds = %38
%41 = mul nsw i64 %39, %28
%42 = trunc i64 %41 to i32
%43 = trunc i64 %41 to i32
%44 = trunc i64 %41 to i32
br label %45
45: ; preds = %40, %459
%46 = phi i64 [ 0, %40 ], [ %477, %459 ]
br i1 %27, label %47, label %282
47: ; preds = %45
%48 = trunc i64 %46 to i32
%49 = add i32 %48, %42
%50 = mul i32 %49, %2
%51 = mul i32 %49, %21
%52 = sext i32 %51 to i64
%53 = sext i32 %50 to i64
%54 = load i32, i32* %3
br label %65
55: ; preds = %102, %96
%56 = phi double [ %97, %96 ], [ %127, %102 ]
store double %56, double* %71
br label %57
57: ; preds = %55, %65
%58 = icmp eq i64 %72, %31
br i1 %58, label %59, label %65
59: ; preds = %57
br i1 %27, label %60, label %282
60: ; preds = %59
%61 = trunc i64 %46 to i32
%62 = add i32 %61, %43
%63 = mul i32 %62, %22
%64 = sext i32 %63 to i64
br label %138
65: ; preds = %47, %57
%66 = phi i32 [ %54, %47 ], [ %74, %57 ]
%67 = phi i64 [ 0, %47 ], [ %72, %57 ]
%68 = add nsw i64 %67, %53
%69 = getelementptr inbounds double, double* %7, i64 %68
%70 = load double, double* %69
%71 = getelementptr inbounds [3 x double], [3 x double]* %18, i64 0, i64 %67
store double %70, double* %71
%72 = add nuw nsw i64 %67, 1
%73 = getelementptr inbounds i32, i32* %3, i64 %72
%74 = load i32, i32* %73
%75 = icmp slt i32 %66, %74
br i1 %75, label %76, label %57
76: ; preds = %65
%77 = sext i32 %66 to i64
%78 = sext i32 %74 to i64
%79 = sub nsw i64 %78, %77
%80 = xor i64 %77, -1
%81 = and i64 %79, 1
%82 = icmp eq i64 %81, 0
br i1 %82, label %96, label %83
83: ; preds = %76
%84 = add nsw i64 %77, %52
%85 = getelementptr inbounds double, double* %9, i64 %84
%86 = load double, double* %85
%87 = getelementptr inbounds i32, i32* %4, i64 %77
%88 = load i32, i32* %87
%89 = add nsw i32 %88, %50
%90 = sext i32 %89 to i64
%91 = getelementptr inbounds double, double* %10, i64 %90
%92 = load double, double* %91
%93 = fneg double %86
%94 = tail call double @llvm.fmuladd.f64(double %93, double %92, double %70)
%95 = add nsw i64 %77, 1
br label %96
96: ; preds = %83, %76
%97 = phi double [ undef, %76 ], [ %94, %83 ]
%98 = phi i64 [ %77, %76 ], [ %95, %83 ]
%99 = phi double [ %70, %76 ], [ %94, %83 ]
%100 = sub nsw i64 0, %78
%101 = icmp eq i64 %80, %100
br i1 %101, label %55, label %102
102: ; preds = %96, %102
%103 = phi i64 [ %128, %102 ], [ %98, %96 ]
%104 = phi double [ %127, %102 ], [ %99, %96 ]
%105 = add nsw i64 %103, %52
%106 = getelementptr inbounds double, double* %9, i64 %105
%107 = load double, double* %106
%108 = getelementptr inbounds i32, i32* %4, i64 %103
%109 = load i32, i32* %108
%110 = add nsw i32 %109, %50
%111 = sext i32 %110 to i64
%112 = getelementptr inbounds double, double* %10, i64 %111
%113 = load double, double* %112
%114 = fneg double %107
%115 = tail call double @llvm.fmuladd.f64(double %114, double %113, double %104)
%116 = add nsw i64 %103, 1
%117 = add nsw i64 %116, %52
%118 = getelementptr inbounds double, double* %9, i64 %117
%119 = load double, double* %118
%120 = getelementptr inbounds i32, i32* %4, i64 %116
%121 = load i32, i32* %120
%122 = add nsw i32 %121, %50
%123 = sext i32 %122 to i64
%124 = getelementptr inbounds double, double* %10, i64 %123
%125 = load double, double* %124
%126 = fneg double %119
%127 = tail call double @llvm.fmuladd.f64(double %126, double %125, double %115)
%128 = add nsw i64 %103, 2
%129 = icmp eq i64 %128, %78
br i1 %129, label %55, label %102
130: ; preds = %204
%131 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %208, <2 x double> %210, <2 x double> %141)
br i1 %27, label %132, label %282
132: ; preds = %130
%133 = trunc i64 %46 to i32
%134 = add i32 %133, %44
%135 = mul i32 %134, %21
%136 = sext i32 %135 to i64
%137 = load i32, i32* %3
br label %217
138: ; preds = %204, %60
%139 = phi i64 [ 0, %60 ], [ %212, %204 ]
%140 = phi double [ 0.000000e+00, %60 ], [ %194, %204 ]
%141 = phi <2 x double> [ zeroinitializer, %60 ], [ %211, %204 ]
%142 = trunc i64 %139 to i32
%143 = add i32 %63, %142
br label %144
144: ; preds = %189, %138
%145 = phi i64 [ 0, %138 ], [ %202, %189 ]
%146 = phi double [ 0.000000e+00, %138 ], [ %201, %189 ]
%147 = phi double [ %140, %138 ], [ %194, %189 ]
%148 = phi double [ 0.000000e+00, %138 ], [ %193, %189 ]
br i1 %35, label %175, label %149
149: ; preds = %144, %149
%150 = phi i64 [ %172, %149 ], [ 0, %144 ]
%151 = phi double [ %171, %149 ], [ 0.000000e+00, %144 ]
%152 = phi i64 [ %173, %149 ], [ 0, %144 ]
%153 = mul nsw i64 %150, %19
%154 = add nsw i64 %153, %64
%155 = add nsw i64 %154, %139
%156 = getelementptr inbounds double, double* %5, i64 %155
%157 = load double, double* %156
%158 = add nsw i64 %154, %145
%159 = getelementptr inbounds double, double* %5, i64 %158
%160 = load double, double* %159
%161 = tail call double @llvm.fmuladd.f64(double %157, double %160, double %151)
%162 = or i64 %150, 1
%163 = mul nsw i64 %162, %19
%164 = add nsw i64 %163, %64
%165 = add nsw i64 %164, %139
%166 = getelementptr inbounds double, double* %5, i64 %165
%167 = load double, double* %166
%168 = add nsw i64 %164, %145
%169 = getelementptr inbounds double, double* %5, i64 %168
%170 = load double, double* %169
%171 = tail call double @llvm.fmuladd.f64(double %167, double %170, double %161)
%172 = add nuw nsw i64 %150, 2
%173 = add i64 %152, 2
%174 = icmp eq i64 %173, %36
br i1 %174, label %175, label %149
175: ; preds = %149, %144
%176 = phi double [ undef, %144 ], [ %171, %149 ]
%177 = phi i64 [ 0, %144 ], [ %172, %149 ]
%178 = phi double [ 0.000000e+00, %144 ], [ %171, %149 ]
br i1 %37, label %189, label %179
179: ; preds = %175
%180 = mul nsw i64 %177, %19
%181 = add nsw i64 %180, %64
%182 = add nsw i64 %181, %139
%183 = getelementptr inbounds double, double* %5, i64 %182
%184 = load double, double* %183
%185 = add nsw i64 %181, %145
%186 = getelementptr inbounds double, double* %5, i64 %185
%187 = load double, double* %186
%188 = tail call double @llvm.fmuladd.f64(double %184, double %187, double %178)
br label %189
189: ; preds = %175, %179
%190 = phi double [ %176, %175 ], [ %188, %179 ]
%191 = getelementptr inbounds [3 x double], [3 x double]* %18, i64 0, i64 %145
%192 = load double, double* %191
%193 = tail call double @llvm.fmuladd.f64(double %190, double %192, double %148)
%194 = tail call double @llvm.fmuladd.f64(double %190, double %190, double %147)
%195 = trunc i64 %145 to i32
%196 = mul i32 %195, %2
%197 = add i32 %143, %196
%198 = sext i32 %197 to i64
%199 = getelementptr inbounds double, double* %5, i64 %198
%200 = load double, double* %199
%201 = fadd double %146, %200
%202 = add nuw nsw i64 %145, 1
%203 = icmp eq i64 %202, %32
br i1 %203, label %204, label %144
204: ; preds = %189
%205 = getelementptr inbounds [3 x double], [3 x double]* %18, i64 0, i64 %139
%206 = load double, double* %205
%207 = insertelement <2 x double> poison, double %206, i64 0
%208 = insertelement <2 x double> %207, double %201, i64 1
%209 = insertelement <2 x double> poison, double %193, i64 0
%210 = insertelement <2 x double> %209, double %201, i64 1
%211 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %208, <2 x double> %210, <2 x double> %141)
%212 = add nuw nsw i64 %139, 1
%213 = icmp eq i64 %212, %32
br i1 %213, label %130, label %138
214: ; preds = %246, %278, %217
%215 = phi double [ %220, %217 ], [ %247, %246 ], [ %279, %278 ]
%216 = icmp eq i64 %221, %33
br i1 %216, label %282, label %217
217: ; preds = %132, %214
%218 = phi i32 [ %137, %132 ], [ %223, %214 ]
%219 = phi i64 [ 0, %132 ], [ %221, %214 ]
%220 = phi double [ 0.000000e+00, %132 ], [ %215, %214 ]
%221 = add nuw nsw i64 %219, 1
%222 = getelementptr inbounds i32, i32* %3, i64 %221
%223 = load i32, i32* %222
%224 = icmp slt i32 %218, %223
br i1 %224, label %225, label %214
225: ; preds = %217
%226 = sext i32 %218 to i64
%227 = sext i32 %223 to i64
%228 = sub nsw i64 %227, %226
%229 = xor i64 %226, -1
%230 = and i64 %228, 1
%231 = icmp eq i64 %230, 0
br i1 %231, label %246, label %232
232: ; preds = %225
%233 = getelementptr inbounds i32, i32* %4, i64 %226
%234 = load i32, i32* %233
%235 = zext i32 %234 to i64
%236 = icmp eq i64 %219, %235
br i1 %236, label %237, label %243
237: ; preds = %232
%238 = add nsw i64 %226, %136
%239 = getelementptr inbounds double, double* %8, i64 %238
%240 = load double, double* %239
%241 = fcmp ogt double %240, %220
%242 = select i1 %241, double %240, double %220
br label %243
243: ; preds = %237, %232
%244 = phi double [ %242, %237 ], [ %220, %232 ]
%245 = add nsw i64 %226, 1
br label %246
246: ; preds = %243, %225
%247 = phi double [ undef, %225 ], [ %244, %243 ]
%248 = phi i64 [ %226, %225 ], [ %245, %243 ]
%249 = phi double [ %220, %225 ], [ %244, %243 ]
%250 = sub nsw i64 0, %227
%251 = icmp eq i64 %229, %250
br i1 %251, label %214, label %252
252: ; preds = %246, %278
%253 = phi i64 [ %280, %278 ], [ %248, %246 ]
%254 = phi double [ %279, %278 ], [ %249, %246 ]
%255 = getelementptr inbounds i32, i32* %4, i64 %253
%256 = load i32, i32* %255
%257 = zext i32 %256 to i64
%258 = icmp eq i64 %219, %257
br i1 %258, label %259, label %265
259: ; preds = %252
%260 = add nsw i64 %253, %136
%261 = getelementptr inbounds double, double* %8, i64 %260
%262 = load double, double* %261
%263 = fcmp ogt double %262, %254
%264 = select i1 %263, double %262, double %254
br label %265
265: ; preds = %252, %259
%266 = phi double [ %264, %259 ], [ %254, %252 ]
%267 = add nsw i64 %253, 1
%268 = getelementptr inbounds i32, i32* %4, i64 %267
%269 = load i32, i32* %268
%270 = zext i32 %269 to i64
%271 = icmp eq i64 %219, %270
br i1 %271, label %272, label %278
272: ; preds = %265
%273 = add nsw i64 %267, %136
%274 = getelementptr inbounds double, double* %8, i64 %273
%275 = load double, double* %274
%276 = fcmp ogt double %275, %266
%277 = select i1 %276, double %275, double %266
br label %278
278: ; preds = %272, %265
%279 = phi double [ %277, %272 ], [ %266, %265 ]
%280 = add nsw i64 %253, 2
%281 = icmp eq i64 %280, %227
br i1 %281, label %214, label %252
282: ; preds = %214, %45, %59, %130
%283 = phi double [ %194, %130 ], [ 0.000000e+00, %59 ], [ 0.000000e+00, %45 ], [ %194, %214 ]
%284 = phi double [ 0.000000e+00, %130 ], [ 0.000000e+00, %59 ], [ 0.000000e+00, %45 ], [ %215, %214 ]
%285 = phi <2 x double> [ %131, %130 ], [ zeroinitializer, %59 ], [ zeroinitializer, %45 ], [ %131, %214 ]
%286 = add nsw i64 %46, %41
%287 = getelementptr inbounds double, double* %11, i64 %286
%288 = load double, double* %287
%289 = fmul double %284, %288
%290 = fmul double %289, 1.296000e+03
%291 = fmul double %289, %290
%292 = fmul double %283, %291
%293 = extractelement <2 x double> %285, i64 1
%294 = tail call double @sqrt(double %293)
%295 = extractelement <2 x double> %285, i64 0
%296 = tail call double @sqrt(double %295)
%297 = tail call double @sqrt(double %292)
%298 = fmul double %297, 2.500000e-01
%299 = tail call double @sqrt(double %295)
%300 = tail call double @sqrt(double %292)
%301 = fadd double %300, 0x3D719799812DEA11
%302 = insertelement <2 x double> <double 1.000000e+00, double poison>, double %299, i64 1
%303 = insertelement <2 x double> poison, double %294, i64 0
%304 = insertelement <2 x double> %303, double %301, i64 1
%305 = fdiv <2 x double> %302, %304
%306 = getelementptr inbounds double, double* %6, i64 %286
%307 = load double, double* %306
%308 = getelementptr inbounds double, double* %12, i64 %286
%309 = load double, double* %308
%310 = fadd double %307, %309
%311 = fadd double %296, 0x3D719799812DEA11
%312 = fdiv double %310, %311
%313 = tail call double @llvm.fabs.f64(double %312)
%314 = fcmp olt double %313, 1.000000e-08
br i1 %314, label %315, label %320
315: ; preds = %282
%316 = fadd double %295, %292
%317 = fadd double %316, 1.000000e-08
%318 = tail call double @sqrt(double %317)
%319 = fdiv double 1.000000e+00, %318
br label %459
320: ; preds = %282
%321 = extractelement <2 x double> %305, i64 1
%322 = fmul double %321, 1.000000e+01
%323 = fcmp ogt double %312, %322
br i1 %323, label %324, label %331
324: ; preds = %320
%325 = fdiv double 5.000000e-01, %310
%326 = extractelement <2 x double> %305, i64 0
%327 = fneg double %326
%328 = fmul double %326, %327
%329 = fmul double %310, 1.200000e+01
%330 = fdiv double %328, %329
br label %442
331: ; preds = %320
%332 = fcmp olt double %296, 1.000000e-08
br i1 %332, label %333, label %381
333: ; preds = %331
%334 = tail call double @llvm.fmuladd.f64(double %312, double 2.000000e+00, double %321)
%335 = fmul double %321, %334
%336 = fcmp olt double %335, 0.000000e+00
br i1 %336, label %337, label %343
337: ; preds = %333
%338 = fneg double %321
%339 = tail call double @llvm.fmuladd.f64(double %312, double -2.000000e+00, double %338)
%340 = fmul double %321, %339
%341 = tail call double @sqrt(double %340)
%342 = tail call double @cos(double %341)
br label %348
343: ; preds = %333
%344 = fcmp ogt double %335, 1.000000e+03
br i1 %344, label %348, label %345
345: ; preds = %343
%346 = tail call double @sqrt(double %335)
%347 = tail call double @cosh(double %346)
br label %348
348: ; preds = %343, %345, %337
%349 = phi double [ %342, %337 ], [ %347, %345 ], [ 0x48E3494A9B171BF5, %343 ]
%350 = load double, double* %306
%351 = fdiv double -1.000000e+00, %350
%352 = fadd double %349, -1.000000e+00
%353 = fmul double %321, 2.000000e+00
%354 = fneg double %353
%355 = tail call double @llvm.fmuladd.f64(double %354, double %312, double %352)
%356 = extractelement <2 x double> %305, i64 0
%357 = fneg double %356
%358 = insertelement <2 x double> poison, double %357, i64 0
%359 = insertelement <2 x double> %358, double %312, i64 1
%360 = fmul <2 x double> %305, %359
%361 = extractelement <2 x double> %360, i64 1
%362 = fdiv double %361, %355
%363 = fsub double -2.000000e+00, %362
%364 = fadd double %363, 1.000000e-08
%365 = fdiv double %351, %364
%366 = fmul double %350, 6.000000e+00
%367 = fmul double %353, %312
%368 = fdiv double 6.000000e+00, %367
%369 = fsub double -1.000000e+00, %368
%370 = tail call double @llvm.fmuladd.f64(double %349, double 3.000000e+00, double %369)
%371 = tail call double @llvm.fmuladd.f64(double %349, double 2.000000e+00, double -2.000000e+00)
%372 = fneg double %321
%373 = tail call double @llvm.fmuladd.f64(double %372, double %312, double %371)
%374 = insertelement <2 x double> poison, double %366, i64 0
%375 = insertelement <2 x double> %374, double %373, i64 1
%376 = fdiv <2 x double> %360, %375
%377 = extractelement <2 x double> %376, i64 1
%378 = fsub double %370, %377
%379 = extractelement <2 x double> %376, i64 0
%380 = fmul double %379, %378
br label %442
381: ; preds = %331
%382 = tail call double @llvm.minnum.f64(double %321, double 1.000000e+01)
%383 = fneg double %312
%384 = fcmp ogt double %312, 1.000000e+01
%385 = select i1 %384, double -1.000000e+01, double %383
%386 = fcmp ogt double %385, 1.000000e+01
%387 = select i1 %386, double 1.000000e+01, double %385
%388 = tail call double @llvm.fmuladd.f64(double %387, double -2.000000e+00, double %382)
%389 = fmul double %382, %388
%390 = fcmp olt double %389, 0.000000e+00
br i1 %390, label %391, label %397
391: ; preds = %381
%392 = fneg double %382
%393 = tail call double @llvm.fmuladd.f64(double %387, double 2.000000e+00, double %392)
%394 = fmul double %382, %393
%395 = tail call double @sqrt(double %394)
%396 = tail call double @cos(double %395)
br label %400
397: ; preds = %381
%398 = tail call double @sqrt(double %389)
%399 = tail call double @cosh(double %398)
br label %400
400: ; preds = %397, %391
%401 = phi double [ %396, %391 ], [ %399, %397 ]
%402 = tail call double @sinh(double %382)
%403 = tail call double @cosh(double %382)
%404 = fmul double %387, %387
%405 = fmul double %404, %402
%406 = fsub double %401, %403
%407 = tail call double @llvm.fmuladd.f64(double %387, double %402, double %406)
%408 = fdiv double %405, %407
%409 = tail call double @llvm.fmuladd.f64(double %387, double -2.000000e+00, double %408)
%410 = fdiv double 1.000000e+00, %409
%411 = fneg double %387
%412 = tail call double @llvm.fmuladd.f64(double %411, double %387, double -3.000000e+00)
%413 = fmul double %387, 3.000000e+00
%414 = fadd double %382, 0x3D719799812DEA11
%415 = tail call double @llvm.fmuladd.f64(double %387, double %387, double -3.000000e+00)
%416 = fmul double %415, %402
%417 = tail call double @llvm.fmuladd.f64(double %413, double %401, double %416)
%418 = fmul double %387, %417
%419 = fmul double %401, 2.000000e+00
%420 = tail call double @llvm.fmuladd.f64(double %403, double -2.000000e+00, double %419)
%421 = tail call double @llvm.fmuladd.f64(double %387, double %402, double %420)
%422 = insertelement <2 x double> poison, double %413, i64 0
%423 = insertelement <2 x double> %422, double %418, i64 1
%424 = insertelement <2 x double> poison, double %414, i64 0
%425 = insertelement <2 x double> %424, double %421, i64 1
%426 = fdiv <2 x double> %423, %425
%427 = extractelement <2 x double> %426, i64 0
%428 = fadd double %412, %427
%429 = extractelement <2 x double> %426, i64 1
%430 = fadd double %428, %429
%431 = fmul double %387, 6.000000e+00
%432 = fmul double %387, %431
%433 = tail call double @llvm.fmuladd.f64(double %432, double %387, double 0x3D719799812DEA11)
%434 = fdiv double %430, %433
%435 = fdiv double %410, %296
%436 = extractelement <2 x double> %305, i64 0
%437 = fmul <2 x double> %305, %305
%438 = extractelement <2 x double> %437, i64 0
%439 = fmul double %438, %434
%440 = fdiv double %439, %296
%441 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([221 x i8], [221 x i8]* @.str.1, i64 0, i64 0), double %436, double %312, double %387, double %321, double %382, double %296, double %389, double %401, double %402, double %403, double %434, double %440, double %410, double %435)
br label %442
442: ; preds = %324, %400, %348
%443 = phi double [ %325, %324 ], [ %365, %348 ], [ %435, %400 ]
%444 = phi double [ %330, %324 ], [ %380, %348 ], [ %440, %400 ]
%445 = fcmp ogt double %444, 0.000000e+00
br i1 %445, label %446, label %459
446: ; preds = %442
%447 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([40 x i8], [40 x i8]* @.str.2, i64 0, i64 0), double %444)
%448 = fdiv double %321, 6.000000e+01
%449 = fmul double %312, 1.200000e+01
%450 = fdiv double 1.000000e+00, %449
%451 = tail call double @llvm.minnum.f64(double %450, double 0x3FA5555555555555)
%452 = tail call double @llvm.minnum.f64(double %448, double %451)
%453 = fneg double %452
%454 = fmul <2 x double> %305, %305
%455 = extractelement <2 x double> %454, i64 0
%456 = fmul double %455, %453
%457 = fdiv double %456, %296
%458 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @.str.3, i64 0, i64 0), double %457)
br label %459
459: ; preds = %315, %446, %442
%460 = phi double [ %443, %446 ], [ %443, %442 ], [ %319, %315 ]
%461 = phi double [ %457, %446 ], [ %444, %442 ], [ 0.000000e+00, %315 ]
%462 = fcmp ole double %461, 0.000000e+00
%463 = zext i1 %462 to i32
%464 = tail call i32 (i32, ...) bitcast (i32 (...)* @assert to i32 (i32, ...)*)(i32 %463)
%465 = fcmp oge double %460, 0.000000e+00
%466 = zext i1 %465 to i32
%467 = tail call i32 (i32, ...) bitcast (i32 (...)* @assert to i32 (i32, ...)*)(i32 %466)
%468 = getelementptr inbounds double, double* %15, i64 %286
store double %460, double* %468
%469 = getelementptr inbounds double, double* %16, i64 %286
store double %461, double* %469
%470 = fcmp ogt double %296, %298
%471 = select i1 %470, double %296, double %298
%472 = getelementptr inbounds double, double* %14, i64 %286
store double %471, double* %472
%473 = tail call double @sqrt(double %295)
%474 = tail call double @sqrt(double %292)
%475 = fdiv double %473, %474
%476 = getelementptr inbounds double, double* %13, i64 %286
store double %475, double* %476
%477 = add nuw nsw i64 %46, 1
%478 = icmp eq i64 %477, %30
br i1 %478, label %479, label %45
479: ; preds = %459, %38
%480 = add nuw nsw i64 %39, 1
%481 = icmp eq i64 %480, %29
br i1 %481, label %482, label %38
482: ; preds = %479, %17
ret void
}