// File: /workspace/github_c_makefile_star2_O3/ugobas[P]tnm/simulation.c
// Function: Torsional_confchange_1angle_old
void Torsional_confchange_1angle_old(struct bond *bonds, int natoms1,
				     int naxes, struct Reference Ref1,
				     float *coord_ref_1, float *coord_ref_2,
				     int N_Cart, atom *atoms1,FILE *file_rmsd,
				     struct Para_simul Para_simul)
{
  printf("Changing %d internal coordinates one by one\n", naxes);
  fprintf(file_rmsd, "# Changing %d internal coordinates one by one\n",naxes);

  float coord_all[3*natoms1];
  Put_coord(coord_all, bonds, natoms1);
  struct bond bonds2[natoms1];
  int N_ref=Ref1.N_ref;
  float coord1[N_Cart], coord2[N_Cart];
  Write_ref_coord(coord1, N_ref, coord_all, Ref1.atom_num);
  Write_ref_coord(coord2, N_ref, coord_all, Ref1.atom_num);
  float *coord_new=coord1, *coord_old=coord2;
  
  float *mass_ref=Ref1.mass_atom;
  float RMSD_opt=rmsd_mclachlan_f(coord_ref_2, coord_new, mass_ref, N_ref);
  float RMSD_kf, RMSD_ki, RMSD_step, Ene;

  for(int iter=0; iter<Para_simul.NSTEPS; iter++){ //ITER_MAX_1
    
    int i, j;
    double diff_tors[naxes]; for(j=0; j<naxes; j++)diff_tors[j]=0;
    float RMSD_min=10000000;
    int i_min=-1, dir_min=0, accept=1;

    for(i=0; i<naxes; i++){

      // Change internal coordinate i in positive direction
      diff_tors[i]=Para_simul.ANGLE;
      Copy_bonds(bonds2, bonds, natoms1);
      Build_up(bonds2, natoms1, diff_tors, naxes);
      Put_coord(coord_all, bonds2, natoms1);
      Write_ref_coord(coord_new, N_ref, coord_all, Ref1.atom_num);
      RMSD_kf=rmsd_mclachlan_f(coord_ref_2, coord_new, mass_ref, N_ref);
      if(RMSD_kf<RMSD_min){i_min=i; dir_min=1; RMSD_min=RMSD_kf;}

      // Change internal coordinate i in negative direction
      diff_tors[i]=-Para_simul.ANGLE;
      Copy_bonds(bonds2, bonds, natoms1);
      Build_up(bonds2, natoms1, diff_tors, naxes);
      Put_coord(coord_all, bonds2, natoms1);
      Write_ref_coord(coord_new, N_ref, coord_all, Ref1.atom_num);
      RMSD_kf=rmsd_mclachlan_f(coord_ref_2, coord_new, mass_ref, N_ref);
      if(RMSD_kf<RMSD_min){i_min=i; dir_min=-1; RMSD_min=RMSD_kf;}

      diff_tors[i]=0;
    }

    if(i_min<0){
      printf("\nERROR, internal coordinate %d does not exist\n", i_min);
      return;
    }

    float d_max=Para_simul.ANGLE;
    RMSD_kf=1000;
    while(1){
      diff_tors[i_min]=dir_min*d_max;
      Copy_bonds(bonds2, bonds, natoms1);
      Build_up(bonds2, natoms1, diff_tors, naxes);
      Put_coord(coord_all, bonds2, natoms1);
      Write_ref_coord(coord_new, N_ref, coord_all, Ref1.atom_num);
      RMSD_kf=rmsd_mclachlan_f(coord_ref_2, coord_new, mass_ref, N_ref);
      RMSD_step=rmsd_mclachlan_f(coord_old, coord_new, mass_ref, N_ref);
      RMSD_ki=rmsd_mclachlan_f(coord_ref_1, coord_new, mass_ref, N_ref);
      printf("iter= %d RMSD_kf= %.3f step= %.3f angle= %.2g\n",
	     iter+1, RMSD_kf, RMSD_step, d_max);
      Ene=Energy_clashes(coord_all, natoms1);
      fprintf(file_rmsd, "%.3f\t%.3f\t%.3f\t%.2g\t%.2g\t%d\n",
	      RMSD_ki, RMSD_kf, RMSD_step, d_max, Ene, accept);
      fflush(file_rmsd);
      if(isnan(RMSD_step)||isnan(RMSD_kf)||isnan(RMSD_ki))return;

      if(RMSD_kf < RMSD_opt){
	if(RMSD_step<Para_simul.STEP_MAX){
	  RMSD_opt=RMSD_kf; accept=1;
	  Copy_bonds(bonds, bonds2, natoms1);
	  break;
	}else{
	  accept=0; d_max*=0.98*(Para_simul.STEP_MAX/RMSD_step);
	  if(RMSD_step<Para_simul.STEP_MIN)break;
	}
      }else{
	if(RMSD_step<Para_simul.STEP_MIN)break;
	accept=0; d_max/=2;  // Reduce step
	printf("Reducing max. step to %.2g \n", d_max);
      }
      if(d_max<0.0001)break;
    }

    if((accept==0)||(RMSD_kf < RMSD_TOL))break;


  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
movl %r9d, -0x2c(%rbp)
movq %r8, -0x98(%rbp)
movq %rcx, -0xe0(%rbp)
movl %edx, %ebx
movl %esi, %r15d
movq %rdi, %r13
movq 0x48(%rbp), %r14
leaq 0x10(%rbp), %r12
leaq 0x24621(%rip), %rdi     # 0x5b4e5
movl %edx, %esi
xorl %eax, %eax
callq 0x20f0
leaq 0x2460f(%rip), %rsi     # 0x5b4e3
movq %r14, %rdi
movl %ebx, -0x30(%rbp)
movl %ebx, %edx
xorl %eax, %eax
callq 0x21a0
leal (%r15,%r15,2), %eax
leaq 0xf(,%rax,4), %rax
andq $-0x10, %rax
movq %rsp, %r14
subq %rax, %r14
movq %r14, %rsp
movl %r15d, %edi
movq %r15, -0x58(%rbp)
testl %r15d, %r15d
jle 0x36f4b
leaq 0x8(%r13), %rax
xorl %ecx, %ecx
movq %r14, %rdx
leaq (%rcx,%rcx,2), %rsi
shlq $0x6, %rsi
cmpl $0x0, 0x20(%r13,%rsi)
js 0x36f4b
xorl %esi, %esi
xorps %xmm0, %xmm0
cvtsd2ss (%rax,%rsi,2), %xmm0
movss %xmm0, (%rdx,%rsi)
addq $0x4, %rsi
cmpq $0xc, %rsi
jne 0x36f23
incq %rcx
addq $0xc0, %rax
addq %rsi, %rdx
cmpq %rdi, %rcx
jne 0x36f11
leaq 0x50(%rbp), %r15
movq %rsp, %rbx
movq %rdi, %rax
shlq $0x6, %rax
leaq (%rax,%rax,2), %rax
subq %rax, %rbx
movq %rbx, %rsp
movslq (%r12), %rcx
movl -0x2c(%rbp), %eax
movq %rsp, %rsi
leaq 0xf(,%rax,4), %rax
andq $-0x10, %rax
subq %rax, %rsi
movq %rsi, %rsp
movq %rsp, %rdx
subq %rax, %rdx
movq %rdx, -0xc8(%rbp)
movq %rdx, %rsp
movq 0x28(%r12), %r9
testq %rcx, %rcx
jle 0x37007
xorl %eax, %eax
movq %rsi, %r8
movl (%r9,%rax,4), %edx
leal (%rdx,%rdx,2), %edx
movslq %edx, %rdx
leaq (%r14,%rdx,4), %r10
xorl %edx, %edx
movss (%r10,%rdx), %xmm0
movss %xmm0, (%r8,%rdx)
addq $0x4, %rdx
cmpl $0xc, %edx
jne 0x36fae
incq %rax
addq %rdx, %r8
cmpq %rcx, %rax
jne 0x36f9e
xorl %eax, %eax
movq -0xc8(%rbp), %r8
movl (%r9,%rax,4), %edx
leal (%rdx,%rdx,2), %edx
movslq %edx, %rdx
leaq (%r14,%rdx,4), %r10
xorl %edx, %edx
movss (%r10,%rdx), %xmm0
movss %xmm0, (%r8,%rdx)
addq $0x4, %rdx
cmpl $0xc, %edx
jne 0x36fe7
incq %rax
addq %rdx, %r8
cmpq %rcx, %rax
jne 0x36fd7
movq %r9, -0x80(%rbp)
movq %rdi, -0xa8(%rbp)
movq 0x10(%r12), %rdx
movq -0x98(%rbp), %rdi
movq %rdx, -0xb0(%rbp)
movq %rcx, -0x50(%rbp)
movq %rsi, %r12
callq 0x4dfa0
movl 0x10(%r15), %eax
movl %eax, -0xb4(%rbp)
testl %eax, %eax
movq -0x58(%rbp), %rax
jle 0x3787c
cvtsd2ss %xmm0, %xmm0
movss %xmm0, -0x6c(%rbp)
movl -0x30(%rbp), %ecx
leaq (,%rcx,8), %rdx
movq %rdx, -0xd0(%rbp)
leaq 0x8(%rbx), %rdx
movq %rdx, -0xa0(%rbp)
movq $0x0, -0x88(%rbp)
movq %rcx, -0x100(%rbp)
leaq 0xf(,%rcx,8), %rcx
andq $-0x10, %rcx
movq %rcx, -0xd8(%rbp)
movq %rax, %r15
movq %r14, -0x78(%rbp)
movq %r12, -0x48(%rbp)
movq %rsp, -0xc0(%rbp)
movq %rsp, %rdi
subq -0xd8(%rbp), %rdi
movq %rdi, %rsp
cmpl $0x0, -0x30(%rbp)
jle 0x37862
xorl %esi, %esi
movq %rdi, -0x68(%rbp)
movq -0xd0(%rbp), %rdx
callq 0x2110
movq -0x68(%rbp), %rdx
xorl %ecx, %ecx
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
xorl %eax, %eax
movss 0x23ca6(%rip), %xmm0    # 0x5ad88
movss %xmm0, -0x2c(%rbp)
movl %eax, -0x34(%rbp)
movl %esi, -0x90(%rbp)
leaq 0x50(%rbp), %rax
xorps %xmm0, %xmm0
cvtss2sd 0xc(%rax), %xmm0
movq %rcx, -0x60(%rbp)
movsd %xmm0, (%rdx,%rcx,8)
movq $0x0, 0x28(%rbx)
movq -0x58(%rbp), %rsi
testl %esi, %esi
jle 0x371de
xorl %r12d, %r12d
xorl %r14d, %r14d
leaq (%r12,%r13), %rsi
leaq (%rbx,%r12), %rdi
movl $0xc0, %edx
callq 0x21b0
testl %r14d, %r14d
je 0x3715a
movq 0x28(%r13,%r12), %rax
subq %r13, %rax
shrq $0x6, %rax
imull $0xaaaaaaab, %eax, %eax # imm = 0xAAAAAAAB
cltq
leaq (%rax,%rax,2), %rax
shlq $0x6, %rax
addq %rbx, %rax
movq %rax, 0x28(%rbx,%r12)
incl %r14d
addq $0xc0, %r12
cmpl %r14d, %r15d
jne 0x3711f
movq %rbx, %rdi
movq %r15, %rsi
movq -0x68(%rbp), %rdx
movl -0x30(%rbp), %ecx
callq 0x15083
movq -0xa0(%rbp), %rax
xorl %r8d, %r8d
movq -0x78(%rbp), %r14
movq %r14, %rdx
movq -0xa8(%rbp), %rdi
movq -0x50(%rbp), %rcx
movq -0x48(%rbp), %r12
movq -0x80(%rbp), %r9
leaq (%r8,%r8,2), %r10
shlq $0x6, %r10
cmpl $0x0, 0x20(%rbx,%r10)
js 0x371f1
xorl %r10d, %r10d
xorps %xmm0, %xmm0
cvtsd2ss (%rax,%r10,2), %xmm0
movss %xmm0, (%rdx,%r10)
addq $0x4, %r10
cmpq $0xc, %r10
jne 0x371b2
incq %r8
addq $0xc0, %rax
addq %r10, %rdx
cmpq %rdi, %r8
jne 0x3719f
jmp 0x371f1
movq %rbx, %rdi
movl -0x30(%rbp), %ecx
callq 0x15083
movq -0x50(%rbp), %rcx
movq -0x80(%rbp), %r9
testl %ecx, %ecx
jle 0x37229
xorl %eax, %eax
movq %r12, %rdi
movl (%r9,%rax,4), %edx
leal (%rdx,%rdx,2), %edx
movslq %edx, %rdx
leaq (%r14,%rdx,4), %r8
xorl %edx, %edx
movss (%r8,%rdx), %xmm0
movss %xmm0, (%rdi,%rdx)
addq $0x4, %rdx
cmpl $0xc, %edx
jne 0x3720a
incq %rax
addq %rdx, %rdi
cmpq %rcx, %rax
jne 0x371fa
movq -0x98(%rbp), %rdi
movq %r12, %rsi
movq -0xb0(%rbp), %rdx
callq 0x4dfa0
xorps %xmm1, %xmm1
cvtsd2ss %xmm0, %xmm1
movss -0x2c(%rbp), %xmm0
movss %xmm1, -0x3c(%rbp)
ucomiss %xmm1, %xmm0
movl $0x1, %eax
movl -0x34(%rbp), %ecx
cmoval %eax, %ecx
movl %ecx, -0x34(%rbp)
leaq 0x50(%rbp), %rax
movss 0xc(%rax), %xmm0
xorps 0x19dbf(%rip), %xmm0    # 0x51030
cvtss2sd %xmm0, %xmm0
movq -0x60(%rbp), %rax
movq -0x68(%rbp), %rdx
movsd %xmm0, (%rdx,%rax,8)
movq $0x0, 0x28(%rbx)
movq -0x58(%rbp), %rsi
testl %esi, %esi
jle 0x3735b
xorl %r12d, %r12d
xorl %r14d, %r14d
leaq (%r12,%r13), %rsi
leaq (%rbx,%r12), %rdi
movl $0xc0, %edx
callq 0x21b0
testl %r14d, %r14d
je 0x372d7
movq 0x28(%r13,%r12), %rax
subq %r13, %rax
shrq $0x6, %rax
imull $0xaaaaaaab, %eax, %eax # imm = 0xAAAAAAAB
cltq
leaq (%rax,%rax,2), %rax
shlq $0x6, %rax
addq %rbx, %rax
movq %rax, 0x28(%rbx,%r12)
incl %r14d
addq $0xc0, %r12
cmpl %r14d, %r15d
jne 0x3729c
movq %rbx, %rdi
movq %r15, %rsi
movq -0x68(%rbp), %rdx
movl -0x30(%rbp), %ecx
callq 0x15083
movq -0xa0(%rbp), %rax
xorl %r8d, %r8d
movq -0x78(%rbp), %r14
movq %r14, %rdx
movq -0xa8(%rbp), %rdi
movq -0x50(%rbp), %rcx
movq -0x48(%rbp), %rsi
movq -0x80(%rbp), %r9
leaq (%r8,%r8,2), %r10
shlq $0x6, %r10
cmpl $0x0, 0x20(%rbx,%r10)
js 0x37371
xorl %r10d, %r10d
xorps %xmm0, %xmm0
cvtsd2ss (%rax,%r10,2), %xmm0
movss %xmm0, (%rdx,%r10)
addq $0x4, %r10
cmpq $0xc, %r10
jne 0x3732f
incq %r8
addq $0xc0, %rax
addq %r10, %rdx
cmpq %rdi, %r8
jne 0x3731c
jmp 0x37371
movq %rbx, %rdi
movl -0x30(%rbp), %ecx
callq 0x15083
movq -0x50(%rbp), %rcx
movq -0x80(%rbp), %r9
movq %r12, %rsi
testl %ecx, %ecx
jle 0x373a9
xorl %eax, %eax
movq %rsi, %rdi
movl (%r9,%rax,4), %edx
leal (%rdx,%rdx,2), %edx
movslq %edx, %rdx
leaq (%r14,%rdx,4), %r8
xorl %edx, %edx
movss (%r8,%rdx), %xmm0
movss %xmm0, (%rdi,%rdx)
addq $0x4, %rdx
cmpl $0xc, %edx
jne 0x3738a
incq %rax
addq %rdx, %rdi
cmpq %rcx, %rax
jne 0x3737a
movss -0x3c(%rbp), %xmm0
minss -0x2c(%rbp), %xmm0
movss %xmm0, -0x38(%rbp)
movq -0x98(%rbp), %rdi
movq %rsi, %r12
movq -0xb0(%rbp), %rdx
callq 0x4dfa0
cvtsd2ss %xmm0, %xmm0
movss -0x38(%rbp), %xmm1
ucomiss %xmm0, %xmm1
movl -0x90(%rbp), %esi
movq -0x60(%rbp), %rcx
cmoval %ecx, %esi
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
movl -0x34(%rbp), %edx
cmoval %eax, %edx
movl %edx, %eax
movss -0x2c(%rbp), %xmm2
ucomiss -0x3c(%rbp), %xmm2
minss %xmm1, %xmm0
cmoval %ecx, %esi
movq -0x68(%rbp), %rdx
movq $0x0, (%rdx,%rcx,8)
incq %rcx
movss %xmm0, -0x2c(%rbp)
cmpq -0x100(%rbp), %rcx
jne 0x370e7
testl %esi, %esi
js 0x37867
xorps %xmm0, %xmm0
cvtsi2ss %eax, %xmm0
movss %xmm0, -0xb8(%rbp)
leaq 0x50(%rbp), %rax
movss 0xc(%rax), %xmm0
movss %xmm0, -0x2c(%rbp)
movl %esi, %eax
movq %rax, -0xe8(%rbp)
movq -0x88(%rbp), %rax
incl %eax
movq %rax, -0x88(%rbp)
movl $0x1, -0x38(%rbp)
movss -0x2c(%rbp), %xmm0
mulss -0xb8(%rbp), %xmm0
cvtss2sd %xmm0, %xmm0
movq -0xe8(%rbp), %rax
movsd %xmm0, (%rdx,%rax,8)
movq $0x0, 0x28(%rbx)
movq -0x58(%rbp), %rsi
testl %esi, %esi
jle 0x37560
xorl %r12d, %r12d
xorl %r14d, %r14d
leaq (%r12,%r13), %rsi
leaq (%rbx,%r12), %rdi
movl $0xc0, %edx
callq 0x21b0
testl %r14d, %r14d
je 0x374dc
movq 0x28(%r13,%r12), %rax
subq %r13, %rax
shrq $0x6, %rax
imull $0xaaaaaaab, %eax, %eax # imm = 0xAAAAAAAB
cltq
leaq (%rax,%rax,2), %rax
shlq $0x6, %rax
addq %rbx, %rax
movq %rax, 0x28(%rbx,%r12)
incl %r14d
addq $0xc0, %r12
cmpl %r14d, %r15d
jne 0x374a1
movq %rbx, %rdi
movq %r15, %rsi
movq -0x68(%rbp), %rdx
movl -0x30(%rbp), %ecx
callq 0x15083
movq -0xa0(%rbp), %rax
xorl %r8d, %r8d
movq -0x78(%rbp), %r14
movq %r14, %rdx
movq -0xa8(%rbp), %rdi
movq -0x50(%rbp), %rcx
movq -0x48(%rbp), %rsi
movq -0x80(%rbp), %r9
leaq (%r8,%r8,2), %r10
shlq $0x6, %r10
cmpl $0x0, 0x20(%rbx,%r10)
js 0x37576
xorl %r10d, %r10d
xorps %xmm0, %xmm0
cvtsd2ss (%rax,%r10,2), %xmm0
movss %xmm0, (%rdx,%r10)
addq $0x4, %r10
cmpq $0xc, %r10
jne 0x37534
incq %r8
addq $0xc0, %rax
addq %r10, %rdx
cmpq %rdi, %r8
jne 0x37521
jmp 0x37576
movq %rbx, %rdi
movl -0x30(%rbp), %ecx
callq 0x15083
movq %r12, %rsi
movq -0x50(%rbp), %rcx
movq -0x80(%rbp), %r9
testl %ecx, %ecx
jle 0x375ae
xorl %eax, %eax
movq %rsi, %rdi
movl (%r9,%rax,4), %edx
leal (%rdx,%rdx,2), %edx
movslq %edx, %rdx
leaq (%r14,%rdx,4), %r8
xorl %edx, %edx
movss (%r8,%rdx), %xmm0
movss %xmm0, (%rdi,%rdx)
addq $0x4, %rdx
cmpl $0xc, %edx
jne 0x3758f
incq %rax
addq %rdx, %rdi
cmpq %rcx, %rax
jne 0x3757f
movq -0x98(%rbp), %rdi
movq -0xb0(%rbp), %r12
movq %r12, %rdx
callq 0x4dfa0
cvtsd2ss %xmm0, %xmm0
movss %xmm0, -0x34(%rbp)
movq -0xc8(%rbp), %rdi
movq -0x48(%rbp), %rsi
movq %r12, %rdx
movq -0x50(%rbp), %rcx
callq 0x4dfa0
cvtsd2ss %xmm0, %xmm0
movss %xmm0, -0x60(%rbp)
movq -0xe0(%rbp), %rdi
movq -0x48(%rbp), %rsi
movq %r12, %rdx
movq -0x50(%rbp), %rcx
callq 0x4dfa0
cvtsd2ss %xmm0, %xmm0
movss %xmm0, -0x3c(%rbp)
xorps %xmm0, %xmm0
cvtss2sd -0x34(%rbp), %xmm0
movsd %xmm0, -0xf8(%rbp)
xorps %xmm1, %xmm1
cvtss2sd -0x60(%rbp), %xmm1
movsd %xmm1, -0xf0(%rbp)
xorps %xmm2, %xmm2
cvtss2sd -0x2c(%rbp), %xmm2
movsd %xmm2, -0x90(%rbp)
leaq 0x23ece(%rip), %rdi     # 0x5b512
movq -0x88(%rbp), %rsi
movb $0x3, %al
callq 0x20f0
movq %r14, %rdi
movq -0x58(%rbp), %rsi
callq 0x3273e
xorps %xmm1, %xmm1
cvtss2sd -0x3c(%rbp), %xmm1
cvtss2sd %xmm0, %xmm4
movq 0x48(%rbp), %r14
movq %r14, %rdi
leaq 0x23b72(%rip), %rsi     # 0x5b1ea
movaps %xmm1, %xmm0
movsd -0xf8(%rbp), %xmm1
movsd -0xf0(%rbp), %xmm2
movsd -0x90(%rbp), %xmm3
movl -0x38(%rbp), %edx
movb $0x5, %al
callq 0x21a0
movq %r14, %rdi
callq 0x21f0
movss -0x60(%rbp), %xmm3
movss -0x34(%rbp), %xmm2
ucomiss %xmm3, %xmm3
jp 0x37875
ucomiss %xmm2, %xmm2
jp 0x37875
movss -0x3c(%rbp), %xmm0
ucomiss %xmm0, %xmm0
jp 0x37875
movss -0x6c(%rbp), %xmm0
ucomiss %xmm2, %xmm0
movq -0x68(%rbp), %rdx
leaq 0x50(%rbp), %rax
jbe 0x3772f
movss 0x4(%rax), %xmm0
ucomiss %xmm3, %xmm0
movq -0x78(%rbp), %r14
movq -0x48(%rbp), %r12
ja 0x377a0
movss 0x8(%rax), %xmm1
ucomiss %xmm3, %xmm1
ja 0x37820
divss %xmm3, %xmm0
cvtss2sd %xmm0, %xmm0
mulsd 0x23643(%rip), %xmm0    # 0x5ad58
mulsd -0x90(%rbp), %xmm0
cvtsd2ss %xmm0, %xmm0
movss %xmm0, -0x2c(%rbp)
xorps %xmm1, %xmm1
cvtss2sd %xmm0, %xmm1
jmp 0x37782
movss 0x8(%rax), %xmm0
ucomiss %xmm3, %xmm0
movq -0x78(%rbp), %r14
movq -0x48(%rbp), %r12
ja 0x37827
movss -0x2c(%rbp), %xmm0
mulss 0x1e472(%rip), %xmm0    # 0x55bc4
movss %xmm0, -0x2c(%rbp)
cvtss2sd %xmm0, %xmm0
movsd %xmm0, -0x60(%rbp)
leaq 0x23dda(%rip), %rdi     # 0x5b541
movb $0x1, %al
movq %rdx, %r12
callq 0x20f0
movsd -0x60(%rbp), %xmm1
movss -0x34(%rbp), %xmm2
movq %r12, %rdx
movq -0x48(%rbp), %r12
movl $0x0, -0x38(%rbp)
movsd 0x1e437(%rip), %xmm0    # 0x55bc8
ucomisd %xmm1, %xmm0
jbe 0x3746a
jmp 0x37827
xorl %ecx, %ecx
movq $0x0, 0x28(%r13)
movq -0x58(%rbp), %rax
testl %eax, %eax
jle 0x3785b
xorl %r14d, %r14d
leaq (%rbx,%r14), %rsi
leaq (%r14,%r13), %rdi
movl $0xc0, %edx
movq %rcx, %r12
callq 0x21b0
movq %r12, %rcx
testl %ecx, %ecx
je 0x377f9
movq 0x28(%rbx,%r14), %rax
subq %rbx, %rax
shrq $0x6, %rax
imull $0xaaaaaaab, %eax, %eax # imm = 0xAAAAAAAB
cltq
leaq (%rax,%rax,2), %rax
shlq $0x6, %rax
addq %r13, %rax
movq %rax, 0x28(%r13,%r14)
incl %ecx
addq $0xc0, %r14
movq -0x58(%rbp), %rax
cmpl %ecx, %eax
jne 0x377b9
xorl %ecx, %ecx
movss -0x34(%rbp), %xmm2
movss %xmm2, -0x6c(%rbp)
movq -0x78(%rbp), %r14
movq -0x48(%rbp), %r12
jmp 0x3782e
movl $0x0, -0x38(%rbp)
cmpl $0x0, -0x38(%rbp)
sete %cl
movq -0xc0(%rbp), %rsp
testb %cl, %cl
jne 0x3787c
movss 0x3167b(%rip), %xmm0    # 0x68ebc
ucomiss %xmm2, %xmm0
ja 0x3787c
movq -0x88(%rbp), %rcx
cmpl -0xb4(%rbp), %ecx
jne 0x3709d
jmp 0x3787c
movss %xmm2, -0x6c(%rbp)
jmp 0x3782e
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
leaq 0x23c46(%rip), %rdi     # 0x5b4b4
xorl %eax, %eax
callq 0x20f0
movq -0xc0(%rbp), %rsp
leaq -0x28(%rbp), %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq