void conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation(
    const int nSimplex, const int nPointsPerSimplex, const int nSpace,
    double linear_break, const int *rowptr, const int *colind,
    const int *materialTypes, const double rho, const double beta,
    const double *gravity, const double *alpha, const double *n,
    const double *thetaR, const double *thetaSR, const double *KWs, double *u,
    double *mass, double *dmass, double *f, double *df, double *a, double *da,
    double *vol_frac) {
  int i, j, k, I, matID, ii;
  const int nSpace2 = nSpace * nSpace;
  register double psiC, pcBarStar, sBarStar, KWrStar, pcBar, pcBar_n, pcBar_nM1,
      pcBar_nM2, onePlus_pcBar_n, sBar, sqrt_sBar, DsBar_DpsiC, thetaW,
      DthetaW_DpsiC, vBar, vBar2, DvBar_DpsiC, KWr, DKWr_DpsiC,
      rho2 = rho * rho, thetaS, rhom, drhom, m, betauStar;
  const int nnz = rowptr[nSpace];
  pcBarStar = linear_break;
  for (i = 0; i < nSimplex; i++) {
    matID = materialTypes[i];
    for (j = 0; j < nPointsPerSimplex; j++) {
      k = i * nPointsPerSimplex + j;
      psiC = -u[k];
      m = 1.0 - 1.0 / n[matID];
      thetaS = thetaR[matID] + thetaSR[matID];
      if (psiC > 0.0) {
        pcBar = alpha[matID] * psiC;
        if (psiC <= pcBarStar) {
          pcBar_nM2 = pow(pcBarStar, n[matID] - 2.);
          pcBar_nM1 = pcBar_nM2 * pcBar;
          pcBar_n = pcBar_nM1 * pcBar;
          onePlus_pcBar_n = 1.0 + pcBar_n;
          sBar = pow(onePlus_pcBar_n, -m);
          DsBar_DpsiC = alpha[matID] * (1.0 - n[matID]) *
                        (sBar / onePlus_pcBar_n) * pcBar_nM1;
          vBar = 1.0 - pcBar_nM1 * sBar;
          vBar2 = vBar * vBar;
          DvBar_DpsiC = -alpha[matID] * (n[matID] - 1.0) * pcBar_nM2 * sBar -
                        pcBar_nM1 * DsBar_DpsiC;
          sBarStar = sBar;
          sqrt_sBar = sqrt(sBar);
          KWrStar = sqrt_sBar * vBar2;
          DsBar_DpsiC = (sBarStar - 1.0) / (pcBarStar - 0.0);
          sBar = DsBar_DpsiC * (psiC - 0.0) + 1.0;
          thetaW = thetaSR[matID] * sBar + thetaR[matID];
          DthetaW_DpsiC = thetaSR[matID] * DsBar_DpsiC;
          DKWr_DpsiC = (KWrStar - 1.0) / (pcBarStar - 0.0);
          KWr = DKWr_DpsiC * (psiC - 0.0) + 1.0;
        } else {
          pcBar = alpha[matID] * psiC;
          pcBarStar = fmax(pcBar, 1.0e-8);
          pcBar_nM2 = pow(pcBarStar, n[matID] - 2);
          pcBar_nM1 = pcBar_nM2 * pcBar;
          pcBar_n = pcBar_nM1 * pcBar;
          onePlus_pcBar_n = 1.0 + pcBar_n;
          sBar = pow(onePlus_pcBar_n, -m);
          DsBar_DpsiC = alpha[matID] * (1.0 - n[matID]) *
                        (sBar / onePlus_pcBar_n) * pcBar_nM1;
          vBar = 1.0 - pcBar_nM1 * sBar;
          vBar2 = vBar * vBar;
          DvBar_DpsiC = -alpha[matID] * (n[matID] - 1.0) * pcBar_nM2 * sBar -
                        pcBar_nM1 * DsBar_DpsiC;
          thetaW = thetaSR[matID] * sBar + thetaR[matID];
          DthetaW_DpsiC = thetaSR[matID] * DsBar_DpsiC;
          sqrt_sBar = sqrt(sBar);
          KWr = sqrt_sBar * vBar2;
          DKWr_DpsiC = ((0.5 / sqrt_sBar) * DsBar_DpsiC * vBar2 +
                        2.0 * sqrt_sBar * vBar * DvBar_DpsiC);
        }
      } else {
        thetaW = thetaS;
        DthetaW_DpsiC = 0.0;
        KWr = 1.0;
        DKWr_DpsiC = 0.0;
      }
      betauStar = fmin(beta * u[k], 1000.0);
      rhom = rho * exp(betauStar);
      drhom = beta * rhom;
      mass[k] = rhom * thetaW;
      dmass[k] = -rhom * DthetaW_DpsiC + drhom * thetaW;
      vol_frac[k] = thetaW;
      for (I = 0; I < nSpace; I++) {
        f[k * nSpace + I] = 0.0;
        df[k * nSpace + I] = 0.0;
        for (ii = rowptr[I]; ii < rowptr[I + 1]; ii++) {
          f[k * nSpace + I] +=
              rho2 * KWr * KWs[matID * nnz + ii] * gravity[colind[ii]];
          df[k * nSpace + I] +=
              -rho2 * DKWr_DpsiC * KWs[matID * nnz + ii] * gravity[colind[ii]];
          a[k * nnz + ii] = rho * KWr * KWs[matID * nnz + ii];
          da[k * nnz + ii] = -rho * DKWr_DpsiC * KWs[matID * nnz + ii];
        }
      }
    }
  }
}


x86 assembly (clang, -O0):
<conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation>:
push   %rbp
mov    %rsp,%rbp
sub    $0x140,%rsp
mov    0x78(%rbp),%rax
mov    0x70(%rbp),%rax
mov    0x68(%rbp),%rax
mov    0x60(%rbp),%rax
mov    0x58(%rbp),%rax
mov    0x50(%rbp),%rax
mov    0x48(%rbp),%rax
mov    0x40(%rbp),%rax
mov    0x38(%rbp),%rax
mov    0x30(%rbp),%rax
mov    0x28(%rbp),%rax
mov    0x20(%rbp),%rax
mov    0x18(%rbp),%rax
mov    0x10(%rbp),%rax
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
movsd  %xmm0,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
mov    %r9,-0x30(%rbp)
movsd  %xmm1,-0x38(%rbp)
movsd  %xmm2,-0x40(%rbp)
mov    -0xc(%rbp),%eax
imul   -0xc(%rbp),%eax
mov    %eax,-0x5c(%rbp)
movsd  -0x38(%rbp),%xmm0
mulsd  -0x38(%rbp),%xmm0
movsd  %xmm0,-0x100(%rbp)
ff
mov    -0x20(%rbp),%rax
movslq -0xc(%rbp),%rcx
mov    (%rax,%rcx,4),%eax
mov    %eax,-0x12c(%rbp)
movsd  -0x18(%rbp),%xmm0
movsd  %xmm0,-0x70(%rbp)
movl   $0x0,-0x44(%rbp)
mov    -0x44(%rbp),%eax
cmp    -0x4(%rbp),%eax
jge    1bdd <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0xaad>
mov    -0x30(%rbp),%rax
movslq -0x44(%rbp),%rcx
mov    (%rax,%rcx,4),%eax
mov    %eax,-0x54(%rbp)
movl   $0x0,-0x48(%rbp)
mov    -0x48(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    1bca <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0xa9a>
mov    -0x44(%rbp),%eax
imul   -0x8(%rbp),%eax
add    -0x48(%rbp),%eax
mov    %eax,-0x4c(%rbp)
mov    0x40(%rbp),%rax
movslq -0x4c(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  %xmm0,-0x68(%rbp)
mov    0x20(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  0xdb8(%rip),%xmm1
divsd  (%rax,%rcx,8),%xmm1
movsd  0xdab(%rip),%xmm0
subsd  %xmm1,%xmm0
movsd  %xmm0,-0x120(%rbp)
ff
mov    0x28(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x30(%rbp),%rax
movslq -0x54(%rbp),%rcx
addsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0x108(%rbp)
ff
movsd  -0x68(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jbe    189c <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x76c>
mov    0x18(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mulsd  -0x68(%rbp),%xmm0
movsd  %xmm0,-0x88(%rbp)
ff
movsd  -0x68(%rbp),%xmm1
movsd  -0x70(%rbp),%xmm0
ucomisd %xmm1,%xmm0
jb     15c8 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x498>
movsd  -0x70(%rbp),%xmm0
mov    0x20(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm1
movsd  0xd2b(%rip),%xmm2
subsd  %xmm2,%xmm1
call   1040 <pow@plt>
movsd  %xmm0,-0xa0(%rbp)
ff
movsd  -0xa0(%rbp),%xmm0
ff
mulsd  -0x88(%rbp),%xmm0
ff
movsd  %xmm0,-0x98(%rbp)
ff
movsd  -0x98(%rbp),%xmm0
ff
mulsd  -0x88(%rbp),%xmm0
ff
movsd  %xmm0,-0x90(%rbp)
ff
movsd  0xcda(%rip),%xmm0
addsd  -0x90(%rbp),%xmm0
ff
movsd  %xmm0,-0xa8(%rbp)
ff
movsd  -0xa8(%rbp),%xmm0
ff
movsd  -0x120(%rbp),%xmm1
ff
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
call   1040 <pow@plt>
movsd  %xmm0,-0xb0(%rbp)
ff
mov    0x18(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x20(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  0xc79(%rip),%xmm1
subsd  (%rax,%rcx,8),%xmm1
mulsd  %xmm1,%xmm0
movsd  -0xb0(%rbp),%xmm1
ff
divsd  -0xa8(%rbp),%xmm1
ff
mulsd  %xmm1,%xmm0
mulsd  -0x98(%rbp),%xmm0
ff
movsd  %xmm0,-0xc0(%rbp)
ff
movsd  -0x98(%rbp),%xmm0
ff
movsd  -0xb0(%rbp),%xmm1
ff
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm1,%xmm0
movsd  0xc19(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xd8(%rbp)
ff
movsd  -0xd8(%rbp),%xmm0
ff
mulsd  -0xd8(%rbp),%xmm0
ff
movsd  %xmm0,-0xe0(%rbp)
ff
mov    0x18(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mov    0x20(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm1
movsd  0xbbc(%rip),%xmm2
subsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
mulsd  -0xa0(%rbp),%xmm0
ff
movsd  -0xb0(%rbp),%xmm2
ff
movsd  -0x98(%rbp),%xmm1
ff
mulsd  -0xc0(%rbp),%xmm1
ff
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xe8(%rbp)
ff
movsd  -0xb0(%rbp),%xmm0
ff
movsd  %xmm0,-0x78(%rbp)
movsd  -0xb0(%rbp),%xmm0
ff
call   1050 <sqrt@plt>
movsd  %xmm0,-0xb8(%rbp)
ff
movsd  -0xb8(%rbp),%xmm0
ff
mulsd  -0xe0(%rbp),%xmm0
ff
movsd  %xmm0,-0x80(%rbp)
movsd  -0x78(%rbp),%xmm0
movsd  0xb29(%rip),%xmm1
subsd  %xmm1,%xmm0
movsd  -0x70(%rbp),%xmm1
xorps  %xmm2,%xmm2
subsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xc0(%rbp)
ff
movsd  -0xc0(%rbp),%xmm0
ff
movsd  -0x68(%rbp),%xmm1
xorps  %xmm2,%xmm2
subsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
movsd  0xaed(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xb0(%rbp)
ff
mov    0x30(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  -0xb0(%rbp),%xmm2
ff
mov    0x28(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xc8(%rbp)
ff
mov    0x30(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mulsd  -0xc0(%rbp),%xmm0
ff
movsd  %xmm0,-0xd0(%rbp)
ff
movsd  -0x80(%rbp),%xmm0
movsd  0xa85(%rip),%xmm1
subsd  %xmm1,%xmm0
movsd  -0x70(%rbp),%xmm1
xorps  %xmm2,%xmm2
subsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0xf8(%rbp)
ff
movsd  -0xf8(%rbp),%xmm0
ff
movsd  -0x68(%rbp),%xmm1
xorps  %xmm2,%xmm2
subsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
movsd  0xa49(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xf0(%rbp)
ff
jmp    1897 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x767>
mov    0x18(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mulsd  -0x68(%rbp),%xmm0
movsd  %xmm0,-0x88(%rbp)
ff
movsd  -0x88(%rbp),%xmm0
ff
movsd  0xa26(%rip),%xmm1
maxsd  %xmm1,%xmm0
movsd  %xmm0,-0x70(%rbp)
movsd  -0x70(%rbp),%xmm0
mov    0x20(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm1
movsd  0x9f3(%rip),%xmm2
subsd  %xmm2,%xmm1
call   1040 <pow@plt>
movsd  %xmm0,-0xa0(%rbp)
ff
movsd  -0xa0(%rbp),%xmm0
ff
mulsd  -0x88(%rbp),%xmm0
ff
movsd  %xmm0,-0x98(%rbp)
ff
movsd  -0x98(%rbp),%xmm0
ff
mulsd  -0x88(%rbp),%xmm0
ff
movsd  %xmm0,-0x90(%rbp)
ff
movsd  0x9a2(%rip),%xmm0
addsd  -0x90(%rbp),%xmm0
ff
movsd  %xmm0,-0xa8(%rbp)
ff
movsd  -0xa8(%rbp),%xmm0
ff
movsd  -0x120(%rbp),%xmm1
ff
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
call   1040 <pow@plt>
movsd  %xmm0,-0xb0(%rbp)
ff
mov    0x18(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x20(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  0x941(%rip),%xmm1
subsd  (%rax,%rcx,8),%xmm1
mulsd  %xmm1,%xmm0
movsd  -0xb0(%rbp),%xmm1
ff
divsd  -0xa8(%rbp),%xmm1
ff
mulsd  %xmm1,%xmm0
mulsd  -0x98(%rbp),%xmm0
ff
movsd  %xmm0,-0xc0(%rbp)
ff
movsd  -0x98(%rbp),%xmm0
ff
movsd  -0xb0(%rbp),%xmm1
ff
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm1,%xmm0
movsd  0x8e1(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xd8(%rbp)
ff
movsd  -0xd8(%rbp),%xmm0
ff
mulsd  -0xd8(%rbp),%xmm0
ff
movsd  %xmm0,-0xe0(%rbp)
ff
mov    0x18(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mov    0x20(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm1
movsd  0x884(%rip),%xmm2
subsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
mulsd  -0xa0(%rbp),%xmm0
ff
movsd  -0xb0(%rbp),%xmm2
ff
movsd  -0x98(%rbp),%xmm1
ff
mulsd  -0xc0(%rbp),%xmm1
ff
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xe8(%rbp)
ff
mov    0x30(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  -0xb0(%rbp),%xmm2
ff
mov    0x28(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xc8(%rbp)
ff
mov    0x30(%rbp),%rax
movslq -0x54(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mulsd  -0xc0(%rbp),%xmm0
ff
movsd  %xmm0,-0xd0(%rbp)
ff
movsd  -0xb0(%rbp),%xmm0
ff
call   1050 <sqrt@plt>
movsd  %xmm0,-0xb8(%rbp)
ff
movsd  -0xb8(%rbp),%xmm0
ff
mulsd  -0xe0(%rbp),%xmm0
ff
movsd  %xmm0,-0xf0(%rbp)
ff
movsd  0x7c1(%rip),%xmm0
divsd  -0xb8(%rbp),%xmm0
ff
mulsd  -0xc0(%rbp),%xmm0
ff
movsd  -0xe0(%rbp),%xmm2
ff
movsd  0x799(%rip),%xmm1
mulsd  -0xb8(%rbp),%xmm1
ff
mulsd  -0xd8(%rbp),%xmm1
ff
mulsd  -0xe8(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xf8(%rbp)
ff
jmp    18d2 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x7a2>
movsd  -0x108(%rbp),%xmm0
ff
movsd  %xmm0,-0xc8(%rbp)
ff
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xd0(%rbp)
ff
movsd  0x741(%rip),%xmm0
movsd  %xmm0,-0xf0(%rbp)
ff
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xf8(%rbp)
ff
movsd  -0x40(%rbp),%xmm0
mov    0x40(%rbp),%rax
movslq -0x4c(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm0
movsd  0x734(%rip),%xmm1
minsd  %xmm1,%xmm0
movsd  %xmm0,-0x128(%rbp)
ff
movsd  -0x38(%rbp),%xmm0
movsd  %xmm0,-0x138(%rbp)
ff
movsd  -0x128(%rbp),%xmm0
ff
call   1030 <exp@plt>
movaps %xmm0,%xmm1
movsd  -0x138(%rbp),%xmm0
ff
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x110(%rbp)
ff
movsd  -0x40(%rbp),%xmm0
mulsd  -0x110(%rbp),%xmm0
ff
movsd  %xmm0,-0x118(%rbp)
ff
movsd  -0x110(%rbp),%xmm0
ff
mulsd  -0xc8(%rbp),%xmm0
ff
mov    0x48(%rbp),%rax
movslq -0x4c(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0x110(%rbp),%xmm0
ff
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  -0xd0(%rbp),%xmm2
ff
movsd  -0x118(%rbp),%xmm1
ff
mulsd  -0xc8(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    0x50(%rbp),%rax
movslq -0x4c(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0xc8(%rbp),%xmm0
ff
mov    0x78(%rbp),%rax
movslq -0x4c(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
movl   $0x0,-0x50(%rbp)
mov    -0x50(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    1bb7 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0xa87>
mov    0x58(%rbp),%rax
mov    -0x4c(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x50(%rbp),%ecx
movslq %ecx,%rcx
xorps  %xmm0,%xmm0
movsd  %xmm0,(%rax,%rcx,8)
mov    0x60(%rbp),%rax
mov    -0x4c(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x50(%rbp),%ecx
movslq %ecx,%rcx
xorps  %xmm0,%xmm0
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x20(%rbp),%rax
movslq -0x50(%rbp),%rcx
mov    (%rax,%rcx,4),%eax
mov    %eax,-0x58(%rbp)
mov    -0x58(%rbp),%eax
mov    -0x20(%rbp),%rcx
mov    -0x50(%rbp),%edx
add    $0x1,%edx
movslq %edx,%rdx
cmp    (%rcx,%rdx,4),%eax
jge    1ba4 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0xa74>
movsd  -0x100(%rbp),%xmm0
ff
mulsd  -0xf0(%rbp),%xmm0
ff
mov    0x38(%rbp),%rax
mov    -0x54(%rbp),%ecx
imul   -0x12c(%rbp),%ecx
add    -0x58(%rbp),%ecx
movslq %ecx,%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    0x10(%rbp),%rax
mov    -0x28(%rbp),%rcx
movslq -0x58(%rbp),%rdx
movslq (%rcx,%rdx,4),%rcx
movsd  (%rax,%rcx,8),%xmm2
mov    0x58(%rbp),%rax
mov    -0x4c(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x50(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0x100(%rbp),%xmm0
ff
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  -0xf8(%rbp),%xmm0
ff
mov    0x38(%rbp),%rax
mov    -0x54(%rbp),%ecx
imul   -0x12c(%rbp),%ecx
add    -0x58(%rbp),%ecx
movslq %ecx,%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    0x10(%rbp),%rax
mov    -0x28(%rbp),%rcx
movslq -0x58(%rbp),%rdx
movslq (%rcx,%rdx,4),%rcx
movsd  (%rax,%rcx,8),%xmm2
mov    0x60(%rbp),%rax
mov    -0x4c(%rbp),%ecx
imul   -0xc(%rbp),%ecx
add    -0x50(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0x38(%rbp),%xmm0
mulsd  -0xf0(%rbp),%xmm0
ff
mov    0x38(%rbp),%rax
mov    -0x54(%rbp),%ecx
imul   -0x12c(%rbp),%ecx
add    -0x58(%rbp),%ecx
movslq %ecx,%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    0x68(%rbp),%rax
mov    -0x4c(%rbp),%ecx
imul   -0x12c(%rbp),%ecx
add    -0x58(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
movsd  -0x38(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  -0xf8(%rbp),%xmm0
ff
mov    0x38(%rbp),%rax
mov    -0x54(%rbp),%ecx
imul   -0x12c(%rbp),%ecx
add    -0x58(%rbp),%ecx
movslq %ecx,%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    0x70(%rbp),%rax
mov    -0x4c(%rbp),%ecx
imul   -0x12c(%rbp),%ecx
add    -0x58(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x58(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x58(%rbp)
jmp    1a0f <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x8df>
jmp    1ba9 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0xa79>
mov    -0x50(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x50(%rbp)
jmp    19c3 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x893>
jmp    1bbc <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0xa8c>
mov    -0x48(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x48(%rbp)
jmp    11f6 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0xc6>
jmp    1bcf <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0xa9f>
mov    -0x44(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x44(%rbp)
jmp    11d5 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0xa5>
add    $0x140,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x168,%rsp
movsd  %xmm2,0x58(%rsp)
movapd %xmm1,0x70(%rsp)
mov    %r9,0x98(%rsp)
mov    %rcx,0x48(%rsp)
mov    %edx,0x1c(%rsp)
mov    %esi,0x18(%rsp)
test   %edi,%edi
jle    18a8 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x778>
mov    0x200(%rsp),%rcx
mov    0x1f8(%rsp),%rdx
mov    0x1f0(%rsp),%r14
mov    0x1e8(%rsp),%r12
mov    0x1d0(%rsp),%rbx
movapd 0x70(%rsp),%xmm1
movapd %xmm1,%xmm2
mulsd  %xmm1,%xmm2
movslq 0x1c(%rsp),%rsi
mov    0x48(%rsp),%rax
movslq (%rax,%rsi,4),%rax
movapd 0xe4a(%rip),%xmm3
movapd %xmm2,0x150(%rsp)
xorpd  %xmm3,%xmm2
movapd %xmm2,0x140(%rsp)
xorpd  %xmm3,%xmm1
movapd %xmm1,0x130(%rsp)
movslq 0x18(%rsp),%rbp
mov    %edi,%edi
mov    %rdi,0xa8(%rsp)
mov    %rax,%rdi
imul   %rbp,%rdi
shl    $0x3,%rdi
mov    %rdi,0xa0(%rsp)
movapd 0xdfd(%rip),%xmm2
movsd  0xe05(%rip),%xmm3
mov    0x1a0(%rsp),%r13
mov    %rbp,0x88(%rsp)
mov    %ebp,%edi
mov    %rdi,0xf0(%rsp)
mov    %rsi,0xe0(%rsp)
mov    %esi,%esi
mov    %rsi,0x118(%rsp)
mov    %rax,0x90(%rsp)
lea    0x0(,%rax,8),%rax
mov    %rax,0xe8(%rsp)
xor    %esi,%esi
mov    %r8,0xf8(%rsp)
jmp    1298 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x168>
nopl   0x0(%rax,%rax,1)
mov    0xb0(%rsp),%rsi
add    $0x1,%rsi
mov    0xb8(%rsp),%rdx
mov    0xa0(%rsp),%rax
add    %rax,%rdx
mov    0xc0(%rsp),%rcx
add    %rax,%rcx
cmp    0xa8(%rsp),%rsi
je     18a8 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x778>
cmpl   $0x0,0x18(%rsp)
mov    %rcx,0xc0(%rsp)
mov    %rdx,0xb8(%rsp)
mov    %rsi,0xb0(%rsp)
jle    1260 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x130>
mov    0x98(%rsp),%rax
movslq (%rax,%rsi,4),%rdi
imul   0x88(%rsp),%rsi
mov    %rsi,0x100(%rsp)
mov    0x90(%rsp),%rax
imul   %edi,%eax
cltq
mov    %rax,0x110(%rsp)
mov    %rcx,0x68(%rsp)
mov    %rdx,0x60(%rsp)
xor    %ecx,%ecx
mov    %rdi,0x40(%rsp)
jmp    134f <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x21f>
nopl   0x0(%rax)
mov    0x108(%rsp),%rcx
add    $0x1,%rcx
mov    0xe8(%rsp),%rax
add    %rax,0x60(%rsp)
add    %rax,0x68(%rsp)
cmp    0xf0(%rsp),%rcx
movsd  0x10(%rsp),%xmm0
mov    0x1d0(%rsp),%rbx
movapd 0xcc4(%rip),%xmm2
movsd  0xccc(%rip),%xmm3
mov    0x40(%rsp),%rdi
je     1260 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x130>
mov    0x100(%rsp),%rax
lea    (%rcx,%rax,1),%r15
movsd  (%rbx,%r15,8),%xmm5
xorpd  %xmm1,%xmm1
ucomisd %xmm5,%xmm1
mov    %rcx,0x108(%rsp)
jbe    1490 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x360>
xorpd  %xmm2,%xmm5
mov    0x1b0(%rsp),%rax
movsd  (%rax,%rdi,8),%xmm1
movapd %xmm3,%xmm2
divsd  %xmm1,%xmm2
movapd %xmm3,%xmm6
subsd  %xmm2,%xmm6
mov    0x1a8(%rsp),%rbp
movsd  0x0(%rbp,%rdi,8),%xmm2
mulsd  %xmm5,%xmm2
ucomisd %xmm5,%xmm0
movapd %xmm6,0x20(%rsp)
movsd  %xmm2,(%rsp)
jae    14e0 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x3b0>
movapd %xmm2,%xmm0
maxsd  0xc5d(%rip),%xmm0
addsd  0xc45(%rip),%xmm1
movsd  %xmm0,0x10(%rsp)
call   1040 <pow@plt>
movsd  (%rsp),%xmm2
movapd %xmm2,%xmm1
movsd  %xmm0,0x30(%rsp)
mulsd  %xmm0,%xmm1
movsd  %xmm1,0x50(%rsp)
mulsd  %xmm1,%xmm2
addsd  0xc0d(%rip),%xmm2
movaps 0x20(%rsp),%xmm1
xorps  0xbf1(%rip),%xmm1
movsd  %xmm2,(%rsp)
movapd %xmm2,%xmm0
call   1040 <pow@plt>
mov    0x40(%rsp),%rcx
movapd %xmm0,%xmm5
movsd  0x0(%rbp,%rcx,8),%xmm9
mov    0x1b0(%rsp),%rax
movsd  (%rax,%rcx,8),%xmm2
movapd %xmm2,%xmm10
addsd  0xbd8(%rip),%xmm10
mov    0x1c0(%rsp),%rax
movsd  (%rax,%rcx,8),%xmm8
movapd %xmm8,%xmm0
mulsd  %xmm5,%xmm0
mov    0x1b8(%rsp),%rax
addsd  (%rax,%rcx,8),%xmm0
ucomisd 0xbcc(%rip),%xmm5
movsd  %xmm0,0x8(%rsp)
jb     1547 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x417>
xorps  %xmm0,%xmm0
sqrtsd %xmm5,%xmm0
jmp    15aa <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x47a>
nopl   0x0(%rax)
movsd  %xmm0,0x10(%rsp)
mov    0x1b8(%rsp),%rax
movsd  (%rax,%rdi,8),%xmm0
mov    0x1c0(%rsp),%rax
addsd  (%rax,%rdi,8),%xmm0
movsd  %xmm0,0x8(%rsp)
xorpd  %xmm0,%xmm0
movsd  %xmm0,0x20(%rsp)
movapd %xmm3,%xmm4
movapd %xmm3,0x30(%rsp)
xorpd  %xmm0,%xmm0
movsd  %xmm0,(%rsp)
jmp    1704 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x5d4>
nopl   0x0(%rax,%rax,1)
movapd %xmm5,0x30(%rsp)
addsd  0xb2a(%rip),%xmm1
movsd  %xmm0,0x10(%rsp)
call   1040 <pow@plt>
movsd  (%rsp),%xmm1
mulsd  %xmm1,%xmm0
movsd  %xmm0,0x8(%rsp)
mulsd  %xmm0,%xmm1
addsd  0xafc(%rip),%xmm1
movapd %xmm1,%xmm0
movaps 0x20(%rsp),%xmm1
xorps  0xadc(%rip),%xmm1
call   1040 <pow@plt>
movapd %xmm0,%xmm6
ucomisd 0xb0b(%rip),%xmm0
jb     1657 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x527>
xorps  %xmm0,%xmm0
sqrtsd %xmm6,%xmm0
jmp    166c <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x53c>
movapd %xmm5,%xmm0
movsd  %xmm8,0x20(%rsp)
movsd  %xmm5,0xd8(%rsp)
movapd %xmm9,0x120(%rsp)
movsd  %xmm10,0xd0(%rsp)
movsd  %xmm2,0xc8(%rsp)
call   1050 <sqrt@plt>
movsd  0xc8(%rsp),%xmm2
movsd  0xd0(%rsp),%xmm10
movapd 0x120(%rsp),%xmm9
movsd  0xd8(%rsp),%xmm5
movsd  0x20(%rsp),%xmm8
movsd  0xa5e(%rip),%xmm3
movsd  0x30(%rsp),%xmm6
movsd  (%rsp),%xmm4
movsd  0x50(%rsp),%xmm7
movapd %xmm3,%xmm1
subsd  %xmm2,%xmm1
mulsd  %xmm9,%xmm1
movapd %xmm5,%xmm2
divsd  %xmm4,%xmm2
mulsd  %xmm1,%xmm2
mulsd  %xmm7,%xmm2
mulsd  %xmm2,%xmm8
movsd  %xmm8,0x20(%rsp)
movsd  0xa3c(%rip),%xmm4
divsd  %xmm0,%xmm4
mulsd  %xmm2,%xmm4
mulsd  %xmm7,%xmm2
mulsd  %xmm5,%xmm7
movapd %xmm3,%xmm1
subsd  %xmm7,%xmm1
movapd %xmm1,%xmm3
mulsd  %xmm1,%xmm3
xorpd  0x9e3(%rip),%xmm9
mulsd  %xmm9,%xmm10
mulsd  %xmm10,%xmm6
mulsd  %xmm5,%xmm6
subsd  %xmm2,%xmm6
mulsd  %xmm3,%xmm4
mulsd  %xmm0,%xmm3
movapd %xmm3,0x30(%rsp)
addsd  %xmm0,%xmm0
mulsd  %xmm1,%xmm0
mulsd  %xmm6,%xmm0
addsd  %xmm0,%xmm4
movsd  %xmm4,(%rsp)
jmp    1704 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x5d4>
movapd %xmm6,%xmm0
movsd  %xmm6,0x20(%rsp)
call   1050 <sqrt@plt>
movsd  0x20(%rsp),%xmm6
movsd  0x10(%rsp),%xmm1
movsd  0x996(%rip),%xmm2
mov    0x40(%rsp),%rcx
movapd 0x30(%rsp),%xmm4
movsd  0x8(%rsp),%xmm3
mulsd  %xmm6,%xmm3
movapd %xmm2,%xmm5
subsd  %xmm3,%xmm5
mulsd  %xmm5,%xmm5
mulsd  %xmm0,%xmm5
movsd  0x979(%rip),%xmm3
addsd  %xmm3,%xmm6
divsd  %xmm1,%xmm6
movapd %xmm6,%xmm7
mulsd  %xmm4,%xmm7
addsd  %xmm2,%xmm7
mov    0x1c0(%rsp),%rax
movsd  (%rax,%rcx,8),%xmm0
mulsd  %xmm0,%xmm7
mov    0x1b8(%rsp),%rax
addsd  (%rax,%rcx,8),%xmm7
movsd  %xmm7,0x8(%rsp)
mulsd  %xmm0,%xmm6
movsd  %xmm6,0x20(%rsp)
addsd  %xmm3,%xmm5
divsd  %xmm1,%xmm5
movsd  %xmm5,(%rsp)
mulsd  %xmm5,%xmm4
addsd  %xmm2,%xmm4
movapd %xmm4,0x30(%rsp)
movsd  (%rbx,%r15,8),%xmm0
mulsd  0x58(%rsp),%xmm0
minsd  0x920(%rip),%xmm0
call   1030 <exp@plt>
mulsd  0x70(%rsp),%xmm0
movapd %xmm0,%xmm1
mulsd  0x58(%rsp),%xmm1
movsd  0x8(%rsp),%xmm3
movapd %xmm3,%xmm2
mulsd  %xmm0,%xmm2
mov    0x1d8(%rsp),%rax
movsd  %xmm2,(%rax,%r15,8)
mulsd  %xmm3,%xmm1
mulsd  0x20(%rsp),%xmm0
subsd  %xmm0,%xmm1
mov    0x1e0(%rsp),%rax
movsd  %xmm1,(%rax,%r15,8)
mov    0x208(%rsp),%rax
movsd  %xmm3,(%rax,%r15,8)
cmpl   $0x0,0x1c(%rsp)
mov    0xf8(%rsp),%r11
movapd 0x30(%rsp),%xmm3
movsd  (%rsp),%xmm4
jle    1300 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x1d0>
imul   0xe0(%rsp),%r15
movapd 0x150(%rsp),%xmm0
mulsd  %xmm3,%xmm0
movapd %xmm4,%xmm1
mulsd  0x140(%rsp),%xmm1
mulsd  0x70(%rsp),%xmm3
mulsd  0x130(%rsp),%xmm4
mov    0x48(%rsp),%rax
mov    (%rax),%r8d
xor    %r9d,%r9d
jmp    17de <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x6ae>
cmp    0x118(%rsp),%r9
je     1300 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x1d0>
mov    %r8d,%eax
lea    (%r9,%r15,1),%rdx
movq   $0x0,(%r12,%rdx,8)
movq   $0x0,(%r14,%rdx,8)
mov    0x48(%rsp),%rcx
mov    0x4(%rcx,%r9,4),%r8d
add    $0x1,%r9
cmp    %r8d,%eax
jge    17d0 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x6a0>
movslq %r8d,%rsi
cltq
mov    0x60(%rsp),%rcx
lea    (%rcx,%rax,8),%r10
mov    0x68(%rsp),%rcx
lea    (%rcx,%rax,8),%rbx
lea    (%r11,%rax,4),%rbp
mov    0x110(%rsp),%rcx
add    %rax,%rcx
mov    0x1c8(%rsp),%rdi
lea    (%rdi,%rcx,8),%rcx
sub    %rax,%rsi
xor    %eax,%eax
nop
movsd  (%rcx,%rax,8),%xmm2
mulsd  %xmm0,%xmm2
movslq 0x0(%rbp,%rax,4),%rdi
mulsd  0x0(%r13,%rdi,8),%xmm2
addsd  (%r12,%rdx,8),%xmm2
movsd  %xmm2,(%r12,%rdx,8)
movsd  (%rcx,%rax,8),%xmm2
mulsd  %xmm1,%xmm2
mulsd  0x0(%r13,%rdi,8),%xmm2
addsd  (%r14,%rdx,8),%xmm2
movsd  %xmm2,(%r14,%rdx,8)
movsd  (%rcx,%rax,8),%xmm2
mulsd  %xmm3,%xmm2
movsd  %xmm2,(%r10,%rax,8)
movsd  (%rcx,%rax,8),%xmm2
mulsd  %xmm4,%xmm2
movsd  %xmm2,(%rbx,%rax,8)
add    $0x1,%rax
cmp    %rax,%rsi
jne    1840 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x710>
jmp    17d0 <conservativeHeadRichardsMualemVanGenuchten_sd_het_linearized_at_saturation+0x6a0>
add    $0x168,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

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

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