// File: /workspace/github_c_makefile_star2_O3/ugobas[P]tnm/read.c
// Function: Read_ligand
int Read_ligand(char *pdb_name, int *nmr, struct residue *seq, atom *atoms,
	       char *chain_to_read, int *ANISOU)
{
  int N_res=0, n_exo=0, Compression=0, start=0;
  FILE *file_in;
  char string[200], command[200];
  atom *atom_ptr=atoms, *first_atom=NULL;

  short i_atom=0, alternative=0;
  int hetatm=0, hetatm_old=0;
  int i, j, res_num, res_num_old=10000;
  char altloc, altloc_sel=' ';
  char chain_old='#', chain=' ';
  char res_type[5], res_type_old[5], icode=' ', icode_old='U';
  float x, y, z;
  char file_name[500];
  int nchains=1, ic, ichain=0, ini_chain=0;
  n_atom=0;

  /* Open file */
  Compression=Get_compression(pdb_name);
  if(Compression){
    sprintf(command, "%s %s > %s\n", PDBCAT, pdb_name, PDBTMP);
    system(command); strcpy(file_name, PDBTMP);
  }else{
    sprintf(file_name, "%s", pdb_name);
  }
  file_in=fopen(file_name, "r");
  if(file_in==NULL){
    printf("\nERROR, %s not found\n", file_name); return(0);
  }

  // Count chains to read
  for(i=0; i<sizeof(chain_to_read); i++){
    nchains=i; if(chain_to_read[i]=='\0')break;
  }
  nchains++; if(nchains==0)nchains=1;

  *nmr=0;
  strcpy(res_type_old,"xxx");
  while(fgets(string, sizeof(string), file_in)!=NULL){

    if(strncmp(string,"ATOM", 4)==0){
      /* Standard residue or DNA basis */
      hetatm=0; if(ini_chain==0)ini_chain=1;
    }else if(strncmp(string,"HETATM", 6)==0){
      if(ini_chain==0)continue;
      hetatm=1;
      /* Cofactor or exotic residue */

    }else if(strncmp(string,"EXPDTA", 6)==0){
      if(strncmp(string+10, "NMR", 3)==0)*nmr=1;
      continue;
      /* NMR structure */

    }else if((strncmp(string,"TER",3)==0)&&(N_res>0)){
      Next_residue(&N_res, &start, seq, first_atom, &i_atom,
		   res_type_old, &res_num_old, &icode_old,
		   &chain_old, &hetatm_old, n_exo,
		   res_type, res_num, icode, chain, hetatm);
      ini_chain=0;
      continue;

    }else if(strncmp(string,"MODRES", 6)==0){
      res_exo[n_exo][0]=string[12]; res_std[n_exo][0]=string[24];
      res_exo[n_exo][1]=string[13]; res_std[n_exo][1]=string[25];
      res_exo[n_exo][2]=string[14]; res_std[n_exo][2]=string[26];
      for(j=0; j<n_exo; j++){
	if(strncmp(res_exo[j],res_exo[n_exo],3)==0)break;
      }
      if(j==n_exo)n_exo++;
      continue;

    }else if(strncmp(string,"ENDMDL", 6)==0){
      break;                                    /* end model */
    }else if(strncmp(string,"ANISOU", 6)==0){
      // Anisotropic structure factor
      int i, j;
      if(*ANISOU==0)*ANISOU=1;
      sscanf(string+28, "%f %f %f %f %f %f",
	     &(atom_ptr->anisou[0][0]), &(atom_ptr->anisou[1][1]),
	     &(atom_ptr->anisou[2][2]), &(atom_ptr->anisou[0][1]),
	     &(atom_ptr->anisou[0][2]), &(atom_ptr->anisou[1][2]));
      for(i=0; i<3; i++){
	for(j=i; j<3; j++){
	  atom_ptr->anisou[i][j]*=0.0001;
	  if(j!=i)atom_ptr->anisou[j][i]=atom_ptr->anisou[i][j];
	}
      }
      // Check
      //for(i=0; i<3; i++)B+=aniso[i][i]; B*=26.319; // 8pi^2/2
      //printf("B= %.2f %.2f %d\n", atom_ptr->B_factor, B, n_atom);
      continue;

      /*}else if(strncmp(string,"HELIX ", 6)==0){
	Read_sec_str(string, chain, 'H'); continue;
	}else if(strncmp(string,"SHEET ", 6)==0){
	Read_sec_str(string, chain, 'E'); continue;
	}else if(strncmp(string,"TURN ", 5)==0){
	Read_sec_str(string, chain, 'T'); continue;*/
    }else{
      continue;
    }

    chain=string[21];
    if(*chain_to_read!='*'){
      if((*chain_to_read==' ')||(*chain_to_read=='\0'))*chain_to_read=chain;
      for(ic=0; ic<nchains; ic++)if(chain==chain_to_read[ic])goto read;
      continue;
    }

  read:
    /* Read atom name */
    if((string[13]=='H')||(string[12]=='H') ||
       (string[13]=='D') ||(string[12]=='D'))continue;

    /* Read residue; check if water molecule */
    res_type[0]=string[17]; res_type[1]=string[18]; res_type[2]=string[19];
    res_type[3]='\0';
    if((hetatm==1)&&((strncmp(res_type,"HOH",3)==0)||
		     (strncmp(res_type,"DOD",3)==0)))continue;

    icode=string[26]; string[26]=' ';


    /* Read coordinates */
    sscanf(string+22,"%d %f %f %f", &res_num, &x, &y, &z);

    /* Check if alternative conformation */
    if((string[72]=='A')&&(string[73]=='L')&&(string[74]=='T')&&
       (string[75]!='1')&&(string[75]!=' '))continue;

    altloc=string[16];
    if(altloc!=' '){
      if(altloc_sel==' ')altloc_sel=altloc;
      if(altloc!=altloc_sel)continue;
    }

    if((icode!=icode_old)&&(res_num==res_num_old)){
      if(alternative==1){
	continue;
      }else{
	atom *atom_old=first_atom;
	float dx, dy, dz;
	dx=x-atom_old->r[0]; dy=y-atom_old->r[1]; dz=z-atom_old->r[2];
	if((dx*dx+dy*dy+dz*dz)<.5){
	  alternative=1; continue;
	}
      }
    }

    /* New residue */
    if((res_num!=res_num_old)||(icode!=icode_old)||
       (strncmp(res_type, res_type_old, 3)!=0)){
      Next_residue(&N_res, &start, seq, first_atom, &i_atom,
		   res_type_old, &res_num_old, &icode_old,
		   &chain_old, &hetatm_old, n_exo,
		   res_type, res_num, icode, chain, hetatm);
    }
    atom_ptr=atoms+n_atom;

    if(i_atom==0)first_atom=atom_ptr;
    i_atom++; n_atom++;
    atom_ptr->r[0] = x;
    atom_ptr->r[1] = y;
    atom_ptr->r[2] = z;
    if(string[12]!=' '){ // Hydrogen atoms
      for(ic=0; ic<4; ic++)atom_ptr->name[ic]=string[12+ic];
    }else{
      for(ic=0; ic<3; ic++)atom_ptr->name[ic]=string[13+ic];
      atom_ptr->name[3]=' ';
    }
    sscanf(string+56, "%f", &atom_ptr->occupancy);
    sscanf(string+60, "%f", &atom_ptr->B_factor);
    atom_ptr->chain=ichain;
  }
  Next_residue(&N_res, &start, seq, first_atom, &i_atom,
	       res_type_old, &res_num_old, &icode_old,
	       &chain_old, &hetatm_old, n_exo,
	       res_type, res_num, icode, chain, hetatm);
  if(N_res > L_MAX){
    printf("\n ERROR, more than %d residues found\n", L_MAX); exit(8);
  }
  fclose(file_in);
  if(Verbose)printf("%3d residues\n", N_res);
  if(Compression){
    sprintf(command, "rm -f %s\n", PDBTMP); system(command);
  }
  return(N_res);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x438, %rsp            # imm = 0x438
movq %r9, %r12
movq %r8, %r15
movq %rcx, 0x98(%rsp)
movq %rdx, 0x70(%rsp)
movq %rsi, %r13
movq %rdi, %rcx
xorl %eax, %eax
movl %eax, 0x24(%rsp)
movl %eax, 0x4c(%rsp)
movw $0x0, 0x4(%rsp)
movl %eax, 0x48(%rsp)
movl $0x2710, 0x20(%rsp)     # imm = 0x2710
movb $0x23, 0x3(%rsp)
movb $0x55, 0x2(%rsp)
movl %eax, 0x5b9f6(%rip)     # 0x69f78
leaq 0x2(%rdi), %rax
movzbl -0x2(%rax), %edx
cmpl $0x2e, %edx
je 0xe595
testl %edx, %edx
jne 0xe5a0
jmp 0xe5a5
cmpb $0x67, -0x1(%rax)
jne 0xe5a0
cmpb $0x7a, (%rax)
je 0xe5ba
incq %rax
jmp 0xe586
leaq 0x240(%rsp), %rdi
movq %rcx, %rsi
callq 0x2080
movb $0x1, %bpl
jmp 0xe5fd
leaq 0x47846(%rip), %rsi     # 0x55e07
leaq 0x4784b(%rip), %rdx     # 0x55e13
leaq 0x47849(%rip), %r8      # 0x55e18
xorl %ebp, %ebp
leaq 0x170(%rsp), %rbx
movq %rbx, %rdi
xorl %eax, %eax
callq 0x2270
movq %rbx, %rdi
callq 0x20e0
movabsq $0x7461642e626470, %rax # imm = 0x7461642E626470
movq %rax, 0x240(%rsp)
leaq 0x4b87a(%rip), %rsi     # 0x59e7e
leaq 0x240(%rsp), %rdi
callq 0x2220
movq %rax, 0x80(%rsp)
testq %rax, %rax
je 0xed97
xorl %eax, %eax
movq %rax, %r14
cmpb $0x0, (%r15,%rax)
je 0xe638
leaq 0x1(%r14), %rax
cmpq $0x7, %r14
jb 0xe624
movl %ebp, 0x8c(%rsp)
movl $0x0, (%r13)
movl $0x787878, 0x3c(%rsp)   # imm = 0x787878
leaq 0xa0(%rsp), %rdi
movl $0xc8, %esi
movq 0x80(%rsp), %rdx
callq 0x2170
testq %rax, %rax
je 0xedb4
movq %r12, 0x90(%rsp)
movb $0x20, 0x1(%rsp)
movb $0x20, %r12b
movq $0x0, 0x28(%rsp)
movq 0x98(%rsp), %rbp
movl $0x0, 0xc(%rsp)
movq $0x0, 0x30(%rsp)
movb $0x20, %al
movl %eax, 0x1c(%rsp)
movq $0x0, 0x68(%rsp)
movq $0x0, 0x10(%rsp)
movq %r13, 0x50(%rsp)
movl 0xa0(%rsp), %eax
movl $0x0, %ebx
cmpl $0x4d4f5441, %eax       # imm = 0x4D4F5441
jne 0xe71c
movb 0xb5(%rsp), %r12b
movzbl (%r15), %ecx
testl %ecx, %ecx
je 0xe6f2
cmpl $0x2a, %ecx
je 0xe7f3
cmpl $0x20, %ecx
jne 0xe6f5
movb %r12b, (%r15)
movq $-0x1, %rcx
cmpb 0x1(%r15,%rcx), %r12b
je 0xe7f3
incq %rcx
cmpq %rcx, %r14
jne 0xe6fc
movl $0x1, 0xc(%rsp)
jmp 0xe821
movl 0xa0(%rsp), %ecx
movl $0x41544548, %edx       # imm = 0x41544548
xorl %edx, %ecx
movzwl 0xa4(%rsp), %edx
xorl $0x4d54, %edx           # imm = 0x4D54
orl %ecx, %edx
je 0xe82b
movl 0xa0(%rsp), %eax
movl $0x44505845, %ecx       # imm = 0x44505845
xorl %ecx, %eax
movzwl 0xa4(%rsp), %ecx
xorl $0x4154, %ecx           # imm = 0x4154
orl %eax, %ecx
je 0xe938
movl 0xa0(%rsp), %eax
movl $0x4554, %ecx           # imm = 0x4554
xorl %ecx, %eax
movzbl 0xa2(%rsp), %ecx
xorl $0x52, %ecx
orw %ax, %cx
jne 0xe966
cmpl $0x0, 0x24(%rsp)
jle 0xe966
movl 0x44(%rsp), %eax
movsbl %r12b, %r10d
movsbl 0x1(%rsp), %r11d
leaq 0x24(%rsp), %rdi
leaq 0x4c(%rsp), %rsi
movq 0x70(%rsp), %rdx
movq 0x30(%rsp), %rcx
leaq 0x4(%rsp), %r8
leaq 0x3c(%rsp), %r9
pushq 0x10(%rsp)
pushq %r10
pushq %r11
pushq %rax
leaq 0x27(%rsp), %rax
pushq %rax
pushq 0x50(%rsp)
leaq 0x78(%rsp), %rax
pushq %rax
leaq 0x3b(%rsp), %rax
pushq %rax
leaq 0x42(%rsp), %rax
pushq %rax
leaq 0x68(%rsp), %rax
pushq %rax
callq 0xe2ab
addq $0x50, %rsp
jmp 0xe83b
movd 0xac(%rsp), %xmm0
punpcklbw %xmm0, %xmm0    # xmm0 = xmm0[0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7]
pshuflw $0x5, %xmm0, %xmm0      # xmm0 = xmm0[1,1,0,0,4,5,6,7]
pshufd $0x44, %xmm0, %xmm0     # xmm0 = xmm0[0,1,0,1]
pcmpeqb 0x4739e(%rip), %xmm0    # 0x55bb0
movmskps %xmm0, %ecx
movl $0x1, 0xc(%rsp)
testl %ecx, %ecx
je 0xe848
movq %rbx, 0x10(%rsp)
jmp 0xed72
movl $0x1, %ebx
cmpl $0x0, 0xc(%rsp)
jne 0xe6d4
movl $0x0, 0xc(%rsp)
jmp 0xed72
movb 0xb1(%rsp), %cl
movb %cl, 0x7(%rsp)
movzwl 0xb2(%rsp), %ecx
movw %cx, 0x8(%rsp)
movb $0x0, 0xa(%rsp)
cmpl $0x4d4f5441, %eax       # imm = 0x4D4F5441
je 0xe8ac
movzwl 0x7(%rsp), %eax
xorl $0x4f48, %eax           # imm = 0x4F48
movzbl 0x9(%rsp), %ecx
xorl $0x48, %ecx
movl $0x1, %edx
movq %rdx, 0x10(%rsp)
orw %ax, %cx
je 0xea82
movzwl 0x7(%rsp), %eax
xorl $0x4f44, %eax           # imm = 0x4F44
movzbl 0x9(%rsp), %ecx
xorl $0x44, %ecx
orw %ax, %cx
je 0xea82
movb 0xba(%rsp), %al
movb %al, 0x1(%rsp)
movb $0x20, 0xba(%rsp)
leaq 0xb6(%rsp), %rdi
leaq 0x4741d(%rip), %rsi     # 0x55ceb
leaq 0x44(%rsp), %rdx
leaq 0x64(%rsp), %rcx
leaq 0x60(%rsp), %r8
leaq 0x5c(%rsp), %r9
xorl %eax, %eax
callq 0x2200
cmpb $0x41, 0xe8(%rsp)
jne 0xe91a
cmpb $0x4c, 0xe9(%rsp)
jne 0xe91a
cmpb $0x54, 0xea(%rsp)
jne 0xe91a
movb 0xeb(%rsp), %al
cmpb $0x31, %al
je 0xe91a
cmpb $0x20, %al
jne 0xe821
movb 0xb0(%rsp), %r13b
cmpb $0x20, %r13b
movl 0x1c(%rsp), %ecx
jne 0xeb32
movl %ecx, %r13d
jmp 0xeb48
movzwl 0xaa(%rsp), %eax
xorl $0x4d4e, %eax           # imm = 0x4D4E
movzbl 0xac(%rsp), %ecx
xorl $0x52, %ecx
orw %ax, %cx
jne 0xed72
movl $0x1, (%r13)
jmp 0xed72
movl 0xa0(%rsp), %eax
movl $0x52444f4d, %ecx       # imm = 0x52444F4D
xorl %ecx, %eax
movzwl 0xa4(%rsp), %ecx
xorl $0x5345, %ecx           # imm = 0x5345
orl %eax, %ecx
je 0xea8f
movl 0xa0(%rsp), %eax
movl $0x4d444e45, %ecx       # imm = 0x4D444E45
xorl %ecx, %eax
movzwl 0xa4(%rsp), %ecx
xorl $0x4c44, %ecx           # imm = 0x4C44
orl %eax, %ecx
je 0xedd7
movl 0xa0(%rsp), %eax
movl $0x53494e41, %ecx       # imm = 0x53494E41
xorl %ecx, %eax
movzwl 0xa4(%rsp), %ecx
xorl $0x554f, %ecx           # imm = 0x554F
orl %eax, %ecx
jne 0xed72
movq 0x90(%rsp), %rax
cmpl $0x0, (%rax)
jne 0xe9ed
movq 0x90(%rsp), %rax
movl $0x1, (%rax)
leaq 0x20(%rbp), %rdx
leaq 0x30(%rbp), %rcx
leaq 0x40(%rbp), %r8
leaq 0x24(%rbp), %r9
leaq 0x28(%rbp), %r10
leaq 0x34(%rbp), %r11
leaq 0xbc(%rsp), %rdi
leaq 0x47382(%rip), %rsi     # 0x55d96
xorl %eax, %eax
pushq %r11
pushq %r10
callq 0x2200
addq $0x10, %rsp
movl $0x20, %eax
xorl %ecx, %ecx
movsd 0x47196(%rip), %xmm1    # 0x55bc8
movl $0x3, %edx
movq %rax, %rsi
movq %rax, %rdi
xorps %xmm0, %xmm0
cvtss2sd (%rbp,%rdi), %xmm0
mulsd %xmm1, %xmm0
cvtsd2ss %xmm0, %xmm0
movss %xmm0, (%rbp,%rdi)
cmpq $0x3, %rdx
je 0xea60
movss %xmm0, (%rbp,%rsi)
decq %rdx
addq $0x4, %rdi
addq $0xc, %rsi
cmpq %rdx, %rcx
jne 0xea3d
incq %rcx
addq $0x10, %rax
cmpq $0x3, %rcx
jne 0xea32
jmp 0xed72
movl $0x1, 0xc(%rsp)
jmp 0xed72
movb 0xac(%rsp), %al
movslq 0x28(%rsp), %rdx
leaq (%rdx,%rdx,4), %rsi
leaq 0x5b4da(%rip), %rbx     # 0x69f80
movb %al, (%rbx,%rsi)
movb 0xb8(%rsp), %al
leaq 0x5bc99(%rip), %rcx     # 0x6a750
movb %al, (%rcx,%rsi)
movb 0xad(%rsp), %al
movb %al, 0x1(%rbx,%rsi)
movb 0xb9(%rsp), %al
movb %al, 0x1(%rcx,%rsi)
movb 0xae(%rsp), %al
movb %al, 0x2(%rbx,%rsi)
movb 0xba(%rsp), %al
movb %al, 0x2(%rcx,%rsi)
movq %rdx, 0x78(%rsp)
testl %edx, %edx
jle 0xebb2
movb %r12b, 0x6(%rsp)
addq %rbx, %rsi
xorl %r13d, %r13d
movl $0x3, %edx
movq %rbx, %rdi
movq %rsi, %r12
callq 0x2070
testl %eax, %eax
je 0xeb28
incq %r13
addq $0x5, %rbx
cmpq %r13, 0x78(%rsp)
movq %r12, %rsi
jne 0xeafe
movq 0x28(%rsp), %r13
movb 0x6(%rsp), %r12b
jmp 0xebb5
cmpb $0x20, %cl
movzbl %r13b, %eax
movzbl %cl, %ecx
cmovel %eax, %ecx
cmpb %cl, %r13b
jne 0xebce
movl 0x44(%rsp), %r11d
movl 0x20(%rsp), %eax
movb 0x1(%rsp), %cl
cmpb 0x2(%rsp), %cl
jne 0xeb8b
cmpl %eax, %r11d
jne 0xec35
movl $0x3, %edx
leaq 0x7(%rsp), %rdi
leaq 0x3c(%rsp), %rsi
movq %r11, %rbp
callq 0x2070
movq %rbp, %r11
testl %eax, %eax
jne 0xec35
jmp 0xec8e
cmpl %eax, %r11d
jne 0xec35
cmpw $0x1, 0x68(%rsp)
jne 0xebdc
movq %rbx, 0x10(%rsp)
movw $0x1, %ax
movq %rax, 0x68(%rsp)
movl %r13d, %eax
jmp 0xed69
xorl %r13d, %r13d
xorl %eax, %eax
movq 0x28(%rsp), %rcx
cmpl %ecx, %r13d
sete %al
addl %ecx, %eax
movq %rax, 0x28(%rsp)
jmp 0xed6d
movl %ecx, 0x1c(%rsp)
movq %rbx, 0x10(%rsp)
jmp 0xed6d
xorps %xmm0, %xmm0
cvtss2sd 0x64(%rsp), %xmm0
movq 0x30(%rsp), %rax
subsd (%rax), %xmm0
cvtsd2ss %xmm0, %xmm0
cvtss2sd 0x60(%rsp), %xmm1
subsd 0x8(%rax), %xmm1
cvtsd2ss %xmm1, %xmm1
cvtss2sd 0x5c(%rsp), %xmm2
subsd 0x10(%rax), %xmm2
cvtsd2ss %xmm2, %xmm2
mulss %xmm1, %xmm1
mulss %xmm0, %xmm0
addss %xmm1, %xmm0
mulss %xmm2, %xmm2
addss %xmm0, %xmm2
movss 0x46f98(%rip), %xmm0    # 0x55bc4
ucomiss %xmm2, %xmm0
ja 0xeb9c
movsbl %r12b, %eax
movsbl 0x1(%rsp), %r10d
leaq 0x24(%rsp), %rdi
leaq 0x4c(%rsp), %rsi
movq 0x70(%rsp), %rdx
movq 0x30(%rsp), %rcx
leaq 0x4(%rsp), %r8
leaq 0x3c(%rsp), %r9
pushq %rbx
pushq %rax
pushq %r10
pushq %r11
leaq 0x27(%rsp), %rax
pushq %rax
pushq 0x50(%rsp)
leaq 0x78(%rsp), %rax
pushq %rax
leaq 0x3b(%rsp), %rax
pushq %rax
leaq 0x42(%rsp), %rax
pushq %rax
leaq 0x68(%rsp), %rax
pushq %rax
callq 0xe2ab
addq $0x50, %rsp
movslq 0x5b2e3(%rip), %rax     # 0x69f78
imulq $0x70, %rax, %rcx
movq 0x98(%rsp), %rsi
leaq (%rsi,%rcx), %rbp
movzwl 0x4(%rsp), %edx
testw %dx, %dx
movq 0x30(%rsp), %rdi
cmoveq %rbp, %rdi
movq %rdi, 0x30(%rsp)
incl %edx
movw %dx, 0x4(%rsp)
incl %eax
movl %eax, 0x5b2ae(%rip)     # 0x69f78
movss 0x60(%rsp), %xmm0
movss 0x64(%rsp), %xmm1
unpcklps %xmm0, %xmm1            # xmm1 = xmm1[0],xmm0[0],xmm1[1],xmm0[1]
cvtps2pd %xmm1, %xmm0
leaq 0x18(%rsi,%rcx), %rax
movups %xmm0, -0x18(%rax)
xorps %xmm0, %xmm0
cvtss2sd 0x5c(%rsp), %xmm0
movsd %xmm0, -0x8(%rax)
cmpb $0x20, 0xac(%rsp)
movb %r13b, 0x78(%rsp)
jne 0xed1d
leaq 0xbc(%rsp), %rdx
movb -0xd(%rdx), %cl
movb %cl, 0x2(%rax)
movzwl -0xf(%rdx), %ecx
movw %cx, (%rax)
movb $0x20, 0x1b(%rbp)
jmp 0xed26
movl 0xac(%rsp), %ecx
movl %ecx, (%rax)
leaq 0x44(%rbp), %rdx
leaq 0xd8(%rsp), %rdi
leaq 0x46fbb(%rip), %r13     # 0x55cf4
movq %r13, %rsi
xorl %eax, %eax
callq 0x2200
leaq 0x1c(%rbp), %rdx
leaq 0xdc(%rsp), %rdi
movq %r13, %rsi
xorl %eax, %eax
callq 0x2200
movl $0x0, 0x6c(%rbp)
movq %rbx, 0x10(%rsp)
movb 0x78(%rsp), %al
movl %eax, 0x1c(%rsp)
movq 0x50(%rsp), %r13
leaq 0xa0(%rsp), %rdi
movl $0xc8, %esi
movq 0x80(%rsp), %rdx
callq 0x2170
testq %rax, %rax
jne 0xe6c1
jmp 0xedd7
leaq 0x47082(%rip), %rdi     # 0x55e20
xorl %ebx, %ebx
leaq 0x240(%rsp), %rsi
xorl %eax, %eax
callq 0x20f0
jmp 0xeeab
movb $0x20, %r12b
movq $0x0, 0x10(%rsp)
movb $0x20, 0x1(%rsp)
movq $0x0, 0x30(%rsp)
movq $0x0, 0x28(%rsp)
movl 0x44(%rsp), %r14d
movsbl %r12b, %r12d
movsbl 0x1(%rsp), %r13d
leaq 0x7(%rsp), %rbp
leaq 0x48(%rsp), %rbx
leaq 0x3(%rsp), %r11
leaq 0x2(%rsp), %r10
leaq 0x20(%rsp), %rax
leaq 0x24(%rsp), %r15
leaq 0x4c(%rsp), %rsi
leaq 0x4(%rsp), %r8
leaq 0x3c(%rsp), %r9
movq %r15, %rdi
movq 0x70(%rsp), %rdx
movq 0x30(%rsp), %rcx
pushq 0x10(%rsp)
pushq %r12
pushq %r13
pushq %r14
pushq %rbp
pushq 0x50(%rsp)
pushq %rbx
pushq %r11
pushq %r10
pushq %rax
callq 0xe2ab
addq $0x50, %rsp
movl (%r15), %ebx
leaq 0x5b048(%rip), %rax     # 0x69e90
movl (%rax), %esi
cmpl %esi, %ebx
jg 0xeebf
movq 0x80(%rsp), %rdi
callq 0x20c0
leaq 0x5a296(%rip), %rax     # 0x690f8
cmpl $0x0, (%rax)
movl 0x8c(%rsp), %ebp
je 0xee7e
leaq 0x46e82(%rip), %rdi     # 0x55cf7
movl %ebx, %esi
xorl %eax, %eax
callq 0x20f0
testb %bpl, %bpl
jne 0xeeab
leaq 0x46fac(%rip), %rsi     # 0x55e36
leaq 0x46f87(%rip), %rdx     # 0x55e18
leaq 0x170(%rsp), %r14
movq %r14, %rdi
xorl %eax, %eax
callq 0x2270
movq %r14, %rdi
callq 0x20e0
movl %ebx, %eax
addq $0x438, %rsp            # imm = 0x438
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x46ef4(%rip), %rdi     # 0x55dba
xorl %eax, %eax
callq 0x20f0
movl $0x8, %edi
callq 0x2280