// File: /workspace/github_c_makefile_star2_O0/PoulinV[P]AxiCLASS/build/../source/thermodynamics.c
// Function: thermodynamics_calculate_opticals
int thermodynamics_calculate_opticals(
                                      struct precision* ppr,
                                      struct thermodynamics* pth
                                      ) {

  /** Summary: */

  /** Define local quantities */
  /* Visibility function value */
  double g;
  /* kappa derivative values*/
  double dkappa,ddkappa,dddkappa,expmkappa;
  int index_tau;

  /** - --> second derivative with respect to tau of dkappa (in view of of spline interpolation) */
  class_call(array_spline_table_line_to_line(pth->tau_table,
                                             pth->tt_size,
                                             pth->thermodynamics_table,
                                             pth->th_size,
                                             pth->index_th_dkappa,
                                             pth->index_th_dddkappa,
                                             _SPLINE_EST_DERIV_,
                                             pth->error_message),
             pth->error_message,
             pth->error_message);

  /** - --> first derivative with respect to tau of dkappa (using spline interpolation) */
  class_call(array_derive_spline_table_line_to_line(pth->tau_table,
                                                    pth->tt_size,
                                                    pth->thermodynamics_table,
                                                    pth->th_size,
                                                    pth->index_th_dkappa,
                                                    pth->index_th_dddkappa,
                                                    pth->index_th_ddkappa,
                                                    pth->error_message),
             pth->error_message,
             pth->error_message);

  /** - --> compute -kappa = [int_{tau_today}^{tau} dtau dkappa/dtau], store temporarily in column "g" */
  class_call(array_integrate_spline_table_line_to_line(pth->tau_table,
                                                       pth->tt_size,
                                                       pth->thermodynamics_table,
                                                       pth->th_size,
                                                       pth->index_th_dkappa,
                                                       pth->index_th_dddkappa,
                                                       pth->index_th_g,
                                                       pth->error_message),
             pth->error_message,
             pth->error_message);


  /** if there is idm_g, calculate its optical contributions */
  if (pth->has_idm_g == _TRUE_) {
    /** - --> second derivative with respect to tau of dmu (in view of of spline interpolation) */
    class_call(array_spline_table_line_to_line(pth->tau_table,
                                               pth->tt_size,
                                               pth->thermodynamics_table,
                                               pth->th_size,
                                               pth->index_th_dmu_idm_g,
                                               pth->index_th_dddmu_idm_g,
                                               _SPLINE_EST_DERIV_,
                                               pth->error_message),
               pth->error_message,
               pth->error_message);

    /** - --> first derivative with respect to tau of dmu (using spline interpolation) */
    class_call(array_derive_spline_table_line_to_line(pth->tau_table,
                                                      pth->tt_size,
                                                      pth->thermodynamics_table,
                                                      pth->th_size,
                                                      pth->index_th_dmu_idm_g,
                                                      pth->index_th_dddmu_idm_g,
                                                      pth->index_th_ddmu_idm_g,
                                                      pth->error_message),
               pth->error_message,
               pth->error_message);

    /** - --> compute -mu = [int_{tau_today}^{tau} dtau dmu/dtau], store temporarily in column "exp_mu_idm_g" */
    class_call(array_integrate_spline_table_line_to_line(pth->tau_table,
                                                         pth->tt_size,
                                                         pth->thermodynamics_table,
                                                         pth->th_size,
                                                         pth->index_th_dmu_idm_g,
                                                         pth->index_th_dddmu_idm_g,
                                                         pth->index_th_exp_mu_idm_g,
                                                         pth->error_message),
               pth->error_message,
               pth->error_message);

  }
  /** - --> compute visibility: \f$ g= (d \kappa/d \tau) e^{- \kappa} \f$ */

  /* loop on z (decreasing z, increasing time) */
  for (index_tau=pth->tt_size-1; index_tau>=0; index_tau--) {

    dkappa = pth->thermodynamics_table[index_tau*pth->th_size+pth->index_th_dkappa];
    ddkappa = pth->thermodynamics_table[index_tau*pth->th_size+pth->index_th_ddkappa];
    dddkappa = pth->thermodynamics_table[index_tau*pth->th_size+pth->index_th_dddkappa];
    expmkappa = exp(pth->thermodynamics_table[index_tau*pth->th_size+pth->index_th_g]);

    /* This would be the rate without accounting for idm_g : */
    /* pth->thermodynamics_table[index_tau*pth->th_size+pth->index_th_rate] = */
    /*   sqrt(pow(dkappa,2)+pow(ddkappa/dkappa,2)+fabs(dddkappa/dkappa)); */

    pth->thermodynamics_table[index_tau*pth->th_size+pth->index_th_exp_m_kappa] = expmkappa;

    /* presence of idm_g modifies visibility function */
    if (pth->has_idm_g == _TRUE_) {
      dkappa += pth->thermodynamics_table[index_tau*pth->th_size + pth->index_th_dmu_idm_g];
      ddkappa += pth->thermodynamics_table[index_tau*pth->th_size+pth->index_th_ddmu_idm_g];
      dddkappa += pth->thermodynamics_table[index_tau*pth->th_size+pth->index_th_dddmu_idm_g];
      pth->thermodynamics_table[index_tau*pth->th_size+pth->index_th_exp_mu_idm_g] =
        exp(pth->thermodynamics_table[index_tau*pth->th_size+pth->index_th_exp_mu_idm_g]); /* we previously calculated -mu_idm_g and stored it here */
      expmkappa *= pth->thermodynamics_table[index_tau*pth->th_size+pth->index_th_exp_mu_idm_g];
    }

    /** - ---> compute g */
    g = dkappa * expmkappa;

    /* for some very extreme models, in the last line, the exponential of a large negative number could go beyond
     * the range covered by the "double" representation numbers, and be set to zero. To avoid a division by zero in
     * the next steps, it is then better to set it to the minimum non-zero double (this has no impact on observables). */
    if (g==0.) g=DBL_MIN;

    /** - ---> compute g' (the plus sign of the second term is correct, see def of -kappa in thermodynamics module!) */
    pth->thermodynamics_table[index_tau*pth->th_size+pth->index_th_dg] =
      (ddkappa + dkappa * dkappa) * expmkappa;

    /** - ---> compute g''  */
    pth->thermodynamics_table[index_tau*pth->th_size+pth->index_th_ddg] =
      (dddkappa + dkappa * ddkappa * 3. + dkappa * dkappa * dkappa ) * expmkappa;

    /** - ---> store g */
    pth->thermodynamics_table[index_tau*pth->th_size+pth->index_th_g] = g;

    /** - ---> compute variation rate */
    class_test(pth->thermodynamics_table[index_tau*pth->th_size+pth->index_th_dkappa] == 0.,
               pth->error_message,
               "variation rate diverges");

    pth->thermodynamics_table[index_tau*pth->th_size+pth->index_th_rate] =
      sqrt(pow(dkappa,2)+pow(ddkappa/dkappa,2)+fabs(dddkappa/dkappa));

  }

  /** - smooth the rate (details of smoothing unimportant: only the
      order of magnitude of the rate matters) */
  class_call(array_smooth(pth->thermodynamics_table,
                          pth->th_size,
                          pth->tt_size,
                          pth->index_th_rate,
                          ppr->thermo_rate_smoothing_radius,
                          pth->error_message),
             pth->error_message,
             pth->error_message);

  /** - --> derivatives of baryon sound speed (only computed if some non-minimal tight-coupling schemes is requested) */
  if (pth->compute_cb2_derivatives == _TRUE_) {

    /** - ---> second derivative with respect to tau of cb2 */
    class_call(array_spline_table_line_to_line(pth->tau_table,
                                               pth->tt_size,
                                               pth->thermodynamics_table,
                                               pth->th_size,
                                               pth->index_th_cb2,
                                               pth->index_th_ddcb2,
                                               _SPLINE_EST_DERIV_,
                                               pth->error_message),
               pth->error_message,
               pth->error_message);

    /** - ---> first derivative with respect to tau of cb2 (using spline interpolation) */
    class_call(array_derive_spline_table_line_to_line(pth->tau_table,
                                                      pth->tt_size,
                                                      pth->thermodynamics_table,
                                                      pth->th_size,
                                                      pth->index_th_cb2,
                                                      pth->index_th_ddcb2,
                                                      pth->index_th_dcb2,
                                                      pth->error_message),
               pth->error_message,
               pth->error_message);
  }

  return _SUCCESS_;
}

// Assembly:
subq $0x5868, %rsp           # imm = 0x5868
movq %rdi, 0x5858(%rsp)
movq %rsi, 0x5850(%rsp)
movq 0x5850(%rsp), %rax
movq 0xf18(%rax), %rdi
movq 0x5850(%rsp), %rax
movl 0xf08(%rax), %esi
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rdx
movq 0x5850(%rsp), %rax
movl 0xf04(%rax), %ecx
movq 0x5850(%rsp), %rax
movl 0xe80(%rax), %r8d
movq 0x5850(%rsp), %rax
movl 0xe8c(%rax), %r9d
movq 0x5850(%rsp), %rax
addq $0x1064, %rax           # imm = 0x1064
movl $0x1, (%rsp)
movq %rax, 0x8(%rsp)
callq 0x1c1c0
cmpl $0x1, %eax
jne 0xc0b10
leaq 0x5020(%rsp), %rdi
movq 0x5850(%rsp), %rcx
addq $0x1064, %rcx           # imm = 0x1064
leaq 0x111917(%rip), %rsi    # 0x1d23d8
leaq 0x133f21(%rip), %rdx    # 0x1f49e9
movb $0x0, %al
callq 0x5b9c0
movq 0x5850(%rsp), %rdi
addq $0x1064, %rdi           # imm = 0x1064
leaq 0x5020(%rsp), %r8
leaq 0x111547(%rip), %rsi    # 0x1d2034
leaq 0x133fa1(%rip), %rdx    # 0x1f4a95
movl $0xd32, %ecx            # imm = 0xD32
movb $0x0, %al
callq 0x5b9c0
movl $0x1, 0x5864(%rsp)
jmp 0xc18ea
movq 0x5850(%rsp), %rax
movq 0xf18(%rax), %rdi
movq 0x5850(%rsp), %rax
movl 0xf08(%rax), %esi
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rdx
movq 0x5850(%rsp), %rax
movl 0xf04(%rax), %ecx
movq 0x5850(%rsp), %rax
movl 0xe80(%rax), %r8d
movq 0x5850(%rsp), %rax
movl 0xe8c(%rax), %r9d
movq 0x5850(%rsp), %rax
movl 0xe88(%rax), %r10d
movq 0x5850(%rsp), %rax
addq $0x1064, %rax           # imm = 0x1064
movl %r10d, (%rsp)
movq %rax, 0x8(%rsp)
callq 0x19c50
cmpl $0x1, %eax
jne 0xc0c05
leaq 0x4820(%rsp), %rdi
movq 0x5850(%rsp), %rcx
addq $0x1064, %rcx           # imm = 0x1064
leaq 0x111822(%rip), %rsi    # 0x1d23d8
leaq 0x133efa(%rip), %rdx    # 0x1f4ab7
movb $0x0, %al
callq 0x5b9c0
movq 0x5850(%rsp), %rdi
addq $0x1064, %rdi           # imm = 0x1064
leaq 0x4820(%rsp), %r8
leaq 0x111452(%rip), %rsi    # 0x1d2034
leaq 0x133eac(%rip), %rdx    # 0x1f4a95
movl $0xd3e, %ecx            # imm = 0xD3E
movb $0x0, %al
callq 0x5b9c0
movl $0x1, 0x5864(%rsp)
jmp 0xc18ea
movq 0x5850(%rsp), %rax
movq 0xf18(%rax), %rdi
movq 0x5850(%rsp), %rax
movl 0xf08(%rax), %esi
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rdx
movq 0x5850(%rsp), %rax
movl 0xf04(%rax), %ecx
movq 0x5850(%rsp), %rax
movl 0xe80(%rax), %r8d
movq 0x5850(%rsp), %rax
movl 0xe8c(%rax), %r9d
movq 0x5850(%rsp), %rax
movl 0xe94(%rax), %r10d
movq 0x5850(%rsp), %rax
addq $0x1064, %rax           # imm = 0x1064
movl %r10d, (%rsp)
movq %rax, 0x8(%rsp)
callq 0x1ac60
cmpl $0x1, %eax
jne 0xc0cfa
leaq 0x4020(%rsp), %rdi
movq 0x5850(%rsp), %rcx
addq $0x1064, %rcx           # imm = 0x1064
leaq 0x11172d(%rip), %rsi    # 0x1d23d8
leaq 0x133ecc(%rip), %rdx    # 0x1f4b7e
movb $0x0, %al
callq 0x5b9c0
movq 0x5850(%rsp), %rdi
addq $0x1064, %rdi           # imm = 0x1064
leaq 0x4020(%rsp), %r8
leaq 0x11135d(%rip), %rsi    # 0x1d2034
leaq 0x133db7(%rip), %rdx    # 0x1f4a95
movl $0xd4a, %ecx            # imm = 0xD4A
movb $0x0, %al
callq 0x5b9c0
movl $0x1, 0x5864(%rsp)
jmp 0xc18ea
movq 0x5850(%rsp), %rax
movswl 0x36(%rax), %eax
cmpl $0x1, %eax
jne 0xc0fe4
movq 0x5850(%rsp), %rax
movq 0xf18(%rax), %rdi
movq 0x5850(%rsp), %rax
movl 0xf08(%rax), %esi
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rdx
movq 0x5850(%rsp), %rax
movl 0xf04(%rax), %ecx
movq 0x5850(%rsp), %rax
movl 0xec8(%rax), %r8d
movq 0x5850(%rsp), %rax
movl 0xed0(%rax), %r9d
movq 0x5850(%rsp), %rax
addq $0x1064, %rax           # imm = 0x1064
movl $0x1, (%rsp)
movq %rax, 0x8(%rsp)
callq 0x1c1c0
cmpl $0x1, %eax
jne 0xc0df8
leaq 0x3820(%rsp), %rdi
movq 0x5850(%rsp), %rcx
addq $0x1064, %rcx           # imm = 0x1064
leaq 0x11162f(%rip), %rsi    # 0x1d23d8
leaq 0x133e92(%rip), %rdx    # 0x1f4c42
movb $0x0, %al
callq 0x5b9c0
movq 0x5850(%rsp), %rdi
addq $0x1064, %rdi           # imm = 0x1064
leaq 0x3820(%rsp), %r8
leaq 0x11125f(%rip), %rsi    # 0x1d2034
leaq 0x133cb9(%rip), %rdx    # 0x1f4a95
movl $0xd59, %ecx            # imm = 0xD59
movb $0x0, %al
callq 0x5b9c0
movl $0x1, 0x5864(%rsp)
jmp 0xc18ea
movq 0x5850(%rsp), %rax
movq 0xf18(%rax), %rdi
movq 0x5850(%rsp), %rax
movl 0xf08(%rax), %esi
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rdx
movq 0x5850(%rsp), %rax
movl 0xf04(%rax), %ecx
movq 0x5850(%rsp), %rax
movl 0xec8(%rax), %r8d
movq 0x5850(%rsp), %rax
movl 0xed0(%rax), %r9d
movq 0x5850(%rsp), %rax
movl 0xecc(%rax), %r10d
movq 0x5850(%rsp), %rax
addq $0x1064, %rax           # imm = 0x1064
movl %r10d, (%rsp)
movq %rax, 0x8(%rsp)
callq 0x19c50
cmpl $0x1, %eax
jne 0xc0eed
leaq 0x3020(%rsp), %rdi
movq 0x5850(%rsp), %rcx
addq $0x1064, %rcx           # imm = 0x1064
leaq 0x11153a(%rip), %rsi    # 0x1d23d8
leaq 0x133e4f(%rip), %rdx    # 0x1f4cf4
movb $0x0, %al
callq 0x5b9c0
movq 0x5850(%rsp), %rdi
addq $0x1064, %rdi           # imm = 0x1064
leaq 0x3020(%rsp), %r8
leaq 0x11116a(%rip), %rsi    # 0x1d2034
leaq 0x133bc4(%rip), %rdx    # 0x1f4a95
movl $0xd65, %ecx            # imm = 0xD65
movb $0x0, %al
callq 0x5b9c0
movl $0x1, 0x5864(%rsp)
jmp 0xc18ea
movq 0x5850(%rsp), %rax
movq 0xf18(%rax), %rdi
movq 0x5850(%rsp), %rax
movl 0xf08(%rax), %esi
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rdx
movq 0x5850(%rsp), %rax
movl 0xf04(%rax), %ecx
movq 0x5850(%rsp), %rax
movl 0xec8(%rax), %r8d
movq 0x5850(%rsp), %rax
movl 0xed0(%rax), %r9d
movq 0x5850(%rsp), %rax
movl 0xed4(%rax), %r10d
movq 0x5850(%rsp), %rax
addq $0x1064, %rax           # imm = 0x1064
movl %r10d, (%rsp)
movq %rax, 0x8(%rsp)
callq 0x1ac60
cmpl $0x1, %eax
jne 0xc0fe2
leaq 0x2820(%rsp), %rdi
movq 0x5850(%rsp), %rcx
addq $0x1064, %rcx           # imm = 0x1064
leaq 0x111445(%rip), %rsi    # 0x1d23d8
leaq 0x133e2a(%rip), %rdx    # 0x1f4dc4
movb $0x0, %al
callq 0x5b9c0
movq 0x5850(%rsp), %rdi
addq $0x1064, %rdi           # imm = 0x1064
leaq 0x2820(%rsp), %r8
leaq 0x111075(%rip), %rsi    # 0x1d2034
leaq 0x133acf(%rip), %rdx    # 0x1f4a95
movl $0xd71, %ecx            # imm = 0xD71
movb $0x0, %al
callq 0x5b9c0
movl $0x1, 0x5864(%rsp)
jmp 0xc18ea
jmp 0xc0fe4
movq 0x5850(%rsp), %rax
movl 0xf08(%rax), %eax
subl $0x1, %eax
movl %eax, 0x5824(%rsp)
cmpl $0x0, 0x5824(%rsp)
jl 0xc1625
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rax
movl 0x5824(%rsp), %ecx
movq 0x5850(%rsp), %rdx
imull 0xf04(%rdx), %ecx
movq 0x5850(%rsp), %rdx
addl 0xe80(%rdx), %ecx
movslq %ecx, %rcx
movsd (%rax,%rcx,8), %xmm0
movsd %xmm0, 0x5840(%rsp)
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rax
movl 0x5824(%rsp), %ecx
movq 0x5850(%rsp), %rdx
imull 0xf04(%rdx), %ecx
movq 0x5850(%rsp), %rdx
addl 0xe88(%rdx), %ecx
movslq %ecx, %rcx
movsd (%rax,%rcx,8), %xmm0
movsd %xmm0, 0x5838(%rsp)
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rax
movl 0x5824(%rsp), %ecx
movq 0x5850(%rsp), %rdx
imull 0xf04(%rdx), %ecx
movq 0x5850(%rsp), %rdx
addl 0xe8c(%rdx), %ecx
movslq %ecx, %rcx
movsd (%rax,%rcx,8), %xmm0
movsd %xmm0, 0x5830(%rsp)
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rax
movl 0x5824(%rsp), %ecx
movq 0x5850(%rsp), %rdx
imull 0xf04(%rdx), %ecx
movq 0x5850(%rsp), %rdx
addl 0xe94(%rdx), %ecx
movslq %ecx, %rcx
movsd (%rax,%rcx,8), %xmm0
callq 0x8670
movsd %xmm0, 0x5828(%rsp)
movsd 0x5828(%rsp), %xmm0
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rax
movl 0x5824(%rsp), %ecx
movq 0x5850(%rsp), %rdx
imull 0xf04(%rdx), %ecx
movq 0x5850(%rsp), %rdx
addl 0xe90(%rdx), %ecx
movslq %ecx, %rcx
movsd %xmm0, (%rax,%rcx,8)
movq 0x5850(%rsp), %rax
movswl 0x36(%rax), %eax
cmpl $0x1, %eax
jne 0xc1327
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rax
movl 0x5824(%rsp), %ecx
movq 0x5850(%rsp), %rdx
imull 0xf04(%rdx), %ecx
movq 0x5850(%rsp), %rdx
addl 0xec8(%rdx), %ecx
movslq %ecx, %rcx
movsd (%rax,%rcx,8), %xmm0
addsd 0x5840(%rsp), %xmm0
movsd %xmm0, 0x5840(%rsp)
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rax
movl 0x5824(%rsp), %ecx
movq 0x5850(%rsp), %rdx
imull 0xf04(%rdx), %ecx
movq 0x5850(%rsp), %rdx
addl 0xecc(%rdx), %ecx
movslq %ecx, %rcx
movsd (%rax,%rcx,8), %xmm0
addsd 0x5838(%rsp), %xmm0
movsd %xmm0, 0x5838(%rsp)
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rax
movl 0x5824(%rsp), %ecx
movq 0x5850(%rsp), %rdx
imull 0xf04(%rdx), %ecx
movq 0x5850(%rsp), %rdx
addl 0xed0(%rdx), %ecx
movslq %ecx, %rcx
movsd (%rax,%rcx,8), %xmm0
addsd 0x5830(%rsp), %xmm0
movsd %xmm0, 0x5830(%rsp)
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rax
movl 0x5824(%rsp), %ecx
movq 0x5850(%rsp), %rdx
imull 0xf04(%rdx), %ecx
movq 0x5850(%rsp), %rdx
addl 0xed4(%rdx), %ecx
movslq %ecx, %rcx
movsd (%rax,%rcx,8), %xmm0
callq 0x8670
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rax
movl 0x5824(%rsp), %ecx
movq 0x5850(%rsp), %rdx
imull 0xf04(%rdx), %ecx
movq 0x5850(%rsp), %rdx
addl 0xed4(%rdx), %ecx
movslq %ecx, %rcx
movsd %xmm0, (%rax,%rcx,8)
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rax
movl 0x5824(%rsp), %ecx
movq 0x5850(%rsp), %rdx
imull 0xf04(%rdx), %ecx
movq 0x5850(%rsp), %rdx
addl 0xed4(%rdx), %ecx
movslq %ecx, %rcx
movsd (%rax,%rcx,8), %xmm0
mulsd 0x5828(%rsp), %xmm0
movsd %xmm0, 0x5828(%rsp)
movsd 0x5840(%rsp), %xmm0
mulsd 0x5828(%rsp), %xmm0
movsd %xmm0, 0x5848(%rsp)
movsd 0x5848(%rsp), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0xc1367
jp 0xc1367
movsd 0x130232(%rip), %xmm0   # 0x1f1590
movsd %xmm0, 0x5848(%rsp)
movsd 0x5838(%rsp), %xmm1
movsd 0x5840(%rsp), %xmm0
movsd 0x5840(%rsp), %xmm2
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
mulsd 0x5828(%rsp), %xmm0
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rax
movl 0x5824(%rsp), %ecx
movq 0x5850(%rsp), %rdx
imull 0xf04(%rdx), %ecx
movq 0x5850(%rsp), %rdx
addl 0xe98(%rdx), %ecx
movslq %ecx, %rcx
movsd %xmm0, (%rax,%rcx,8)
movsd 0x5830(%rsp), %xmm0
movsd 0x5840(%rsp), %xmm1
mulsd 0x5838(%rsp), %xmm1
movsd 0x1122a7(%rip), %xmm2   # 0x1d3698
mulsd %xmm2, %xmm1
addsd %xmm0, %xmm1
movsd 0x5840(%rsp), %xmm0
mulsd 0x5840(%rsp), %xmm0
movsd 0x5840(%rsp), %xmm2
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
mulsd 0x5828(%rsp), %xmm0
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rax
movl 0x5824(%rsp), %ecx
movq 0x5850(%rsp), %rdx
imull 0xf04(%rdx), %ecx
movq 0x5850(%rsp), %rdx
addl 0xe9c(%rdx), %ecx
movslq %ecx, %rcx
movsd %xmm0, (%rax,%rcx,8)
movsd 0x5848(%rsp), %xmm0
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rax
movl 0x5824(%rsp), %ecx
movq 0x5850(%rsp), %rdx
imull 0xf04(%rdx), %ecx
movq 0x5850(%rsp), %rdx
addl 0xe94(%rdx), %ecx
movslq %ecx, %rcx
movsd %xmm0, (%rax,%rcx,8)
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rax
movl 0x5824(%rsp), %ecx
movq 0x5850(%rsp), %rdx
imull 0xf04(%rdx), %ecx
movq 0x5850(%rsp), %rdx
addl 0xe80(%rdx), %ecx
movslq %ecx, %rcx
movsd (%rax,%rcx,8), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0xc1566
jp 0xc1566
leaq 0x2020(%rsp), %rdi
leaq 0x1339a0(%rip), %rsi    # 0x1f4e99
movb $0x0, %al
callq 0x5b9c0
leaq 0x1820(%rsp), %rdi
leaq 0x2020(%rsp), %rcx
leaq 0x110b6b(%rip), %rsi    # 0x1d2082
leaq 0x133993(%rip), %rdx    # 0x1f4eb1
movb $0x0, %al
callq 0x5b9c0
movq 0x5850(%rsp), %rdi
addq $0x1064, %rdi           # imm = 0x1064
leaq 0x1820(%rsp), %r8
leaq 0x110af1(%rip), %rsi    # 0x1d2034
leaq 0x13354b(%rip), %rdx    # 0x1f4a95
movl $0xda4, %ecx            # imm = 0xDA4
movb $0x0, %al
callq 0x5b9c0
movl $0x1, 0x5864(%rsp)
jmp 0xc18ea
movsd 0x5840(%rsp), %xmm0
movsd 0x111709(%rip), %xmm1   # 0x1d2c80
callq 0x8610
movsd %xmm0, 0x18(%rsp)
movsd 0x5838(%rsp), %xmm0
divsd 0x5840(%rsp), %xmm0
movsd 0x1116e4(%rip), %xmm1   # 0x1d2c80
callq 0x8610
movaps %xmm0, %xmm1
movsd 0x18(%rsp), %xmm0
addsd %xmm1, %xmm0
movsd 0x5830(%rsp), %xmm1
divsd 0x5840(%rsp), %xmm1
movaps 0x110c69(%rip), %xmm2   # 0x1d2230
pand %xmm2, %xmm1
addsd %xmm1, %xmm0
callq 0x82e0
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rax
movl 0x5824(%rsp), %ecx
movq 0x5850(%rsp), %rdx
imull 0xf04(%rdx), %ecx
movq 0x5850(%rsp), %rdx
addl 0xefc(%rdx), %ecx
movslq %ecx, %rcx
movsd %xmm0, (%rax,%rcx,8)
movl 0x5824(%rsp), %eax
addl $-0x1, %eax
movl %eax, 0x5824(%rsp)
jmp 0xc0ffc
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rdi
movq 0x5850(%rsp), %rax
movl 0xf04(%rax), %esi
movq 0x5850(%rsp), %rax
movl 0xf08(%rax), %edx
movq 0x5850(%rsp), %rax
movl 0xefc(%rax), %ecx
movq 0x5858(%rsp), %rax
movl 0x1c8(%rax), %r8d
movq 0x5850(%rsp), %r9
addq $0x1064, %r9            # imm = 0x1064
callq 0x2a6b0
cmpl $0x1, %eax
jne 0xc16f3
leaq 0x1020(%rsp), %rdi
movq 0x5850(%rsp), %rcx
addq $0x1064, %rcx           # imm = 0x1064
leaq 0x110d34(%rip), %rsi    # 0x1d23d8
leaq 0x133853(%rip), %rdx    # 0x1f4efe
movb $0x0, %al
callq 0x5b9c0
movq 0x5850(%rsp), %rdi
addq $0x1064, %rdi           # imm = 0x1064
leaq 0x1020(%rsp), %r8
leaq 0x110964(%rip), %rsi    # 0x1d2034
leaq 0x1333be(%rip), %rdx    # 0x1f4a95
movl $0xdb4, %ecx            # imm = 0xDB4
movb $0x0, %al
callq 0x5b9c0
movl $0x1, 0x5864(%rsp)
jmp 0xc18ea
movq 0x5850(%rsp), %rax
movswl 0x30(%rax), %eax
cmpl $0x1, %eax
jne 0xc18df
movq 0x5850(%rsp), %rax
movq 0xf18(%rax), %rdi
movq 0x5850(%rsp), %rax
movl 0xf08(%rax), %esi
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rdx
movq 0x5850(%rsp), %rax
movl 0xf04(%rax), %ecx
movq 0x5850(%rsp), %rax
movl 0xef0(%rax), %r8d
movq 0x5850(%rsp), %rax
movl 0xef8(%rax), %r9d
movq 0x5850(%rsp), %rax
addq $0x1064, %rax           # imm = 0x1064
movl $0x1, (%rsp)
movq %rax, 0x8(%rsp)
callq 0x1c1c0
cmpl $0x1, %eax
jne 0xc17f1
leaq 0x820(%rsp), %rdi
movq 0x5850(%rsp), %rcx
addq $0x1064, %rcx           # imm = 0x1064
leaq 0x110c36(%rip), %rsi    # 0x1d23d8
leaq 0x1337e4(%rip), %rdx    # 0x1f4f8d
movb $0x0, %al
callq 0x5b9c0
movq 0x5850(%rsp), %rdi
addq $0x1064, %rdi           # imm = 0x1064
leaq 0x820(%rsp), %r8
leaq 0x110866(%rip), %rsi    # 0x1d2034
leaq 0x1332c0(%rip), %rdx    # 0x1f4a95
movl $0xdc3, %ecx            # imm = 0xDC3
movb $0x0, %al
callq 0x5b9c0
movl $0x1, 0x5864(%rsp)
jmp 0xc18ea
movq 0x5850(%rsp), %rax
movq 0xf18(%rax), %rdi
movq 0x5850(%rsp), %rax
movl 0xf08(%rax), %esi
movq 0x5850(%rsp), %rax
movq 0xf20(%rax), %rdx
movq 0x5850(%rsp), %rax
movl 0xf04(%rax), %ecx
movq 0x5850(%rsp), %rax
movl 0xef0(%rax), %r8d
movq 0x5850(%rsp), %rax
movl 0xef8(%rax), %r9d
movq 0x5850(%rsp), %rax
movl 0xef4(%rax), %r10d
movq 0x5850(%rsp), %rax
addq $0x1064, %rax           # imm = 0x1064
movl %r10d, (%rsp)
movq %rax, 0x8(%rsp)
callq 0x19c50
cmpl $0x1, %eax
jne 0xc18dd
leaq 0x20(%rsp), %rdi
movq 0x5850(%rsp), %rcx
addq $0x1064, %rcx           # imm = 0x1064
leaq 0x110b44(%rip), %rsi    # 0x1d23d8
leaq 0x133798(%rip), %rdx    # 0x1f5033
movb $0x0, %al
callq 0x5b9c0
movq 0x5850(%rsp), %rdi
addq $0x1064, %rdi           # imm = 0x1064
leaq 0x20(%rsp), %r8
leaq 0x110777(%rip), %rsi    # 0x1d2034
leaq 0x1331d1(%rip), %rdx    # 0x1f4a95
movl $0xdcf, %ecx            # imm = 0xDCF
movb $0x0, %al
callq 0x5b9c0
movl $0x1, 0x5864(%rsp)
jmp 0xc18ea
jmp 0xc18df
movl $0x0, 0x5864(%rsp)
movl 0x5864(%rsp), %eax
addq $0x5868, %rsp           # imm = 0x5868
retq
nopl (%rax)