// File: /workspace/github_c_makefile_star2_O0/josch[P]stride/hydrbond.c
// Function: FindAcc
int FindAcc(CHAIN *Chain, ACCEPTOR **Acc, int *NAcc, COMMAND *Cmd)
{

  int Res, ac;
  char Rsd[RES_FIELD];
  
  ac = *NAcc;

  for( Res=0; Res<Chain->NRes; Res++ ) {
    strcpy(Rsd,Chain->Rsd[Res]->ResType);

    DefineAcceptor(Chain,Acc,&ac,Res,Osp2,Peptide,1.60,0);

    if( !Cmd->SideChainHBond ) continue;

    if( !strcmp(Rsd,"HIS") ) {
      DefineAcceptor(Chain,Acc,&ac,Res,Nsp2,His,1.60,0);
      DefineAcceptor(Chain,Acc,&ac,Res,Nsp2,His,1.60,0);
    }
    else if( !strcmp(Rsd,"SER") ) DefineAcceptor(Chain,Acc,&ac,Res,Osp3,Ser,1.70,0);
    else if( !strcmp(Rsd,"THR") ) DefineAcceptor(Chain,Acc,&ac,Res,Osp3,Thr,1.70,0);
    else if( !strcmp(Rsd,"ASN") ) DefineAcceptor(Chain,Acc,&ac,Res,Osp2,Asn,1.60,0);
    else if( !strcmp(Rsd,"GLN") ) DefineAcceptor(Chain,Acc,&ac,Res,Osp2,Gln,1.60,0);
    else if( !strcmp(Rsd,"ASP") ) {
      DefineAcceptor(Chain,Acc,&ac,Res,Osp2,Asp,1.60,1);
      DefineAcceptor(Chain,Acc,&ac,Res,Osp2,Asp,1.60,2);
    }
    else if( !strcmp(Rsd,"GLU") ) {
      DefineAcceptor(Chain,Acc,&ac,Res,Osp2,Glu,1.60,1);
      DefineAcceptor(Chain,Acc,&ac,Res,Osp2,Glu,1.60,2);
    }
    else if( !strcmp(Rsd,"TYR") ) DefineAcceptor(Chain,Acc,&ac,Res,Osp2,Tyr,1.70,0);
    else if( !strcmp(Rsd,"MET") ) DefineAcceptor(Chain,Acc,&ac,Res,Ssp3,Met,1.95,0);
    else if( !strcmp(Rsd,"CYS") ) DefineAcceptor(Chain,Acc,&ac,Res,Ssp3,Cys,1.70,0);
    }

  *NAcc = ac;
  return(ac);
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movq %rsi, 0x28(%rsp)
movq %rdx, 0x20(%rsp)
movq %rcx, 0x18(%rsp)
movq 0x20(%rsp), %rax
movl (%rax), %eax
movl %eax, 0x10(%rsp)
movl $0x0, 0x14(%rsp)
movl 0x14(%rsp), %eax
movq 0x30(%rsp), %rcx
cmpl (%rcx), %eax
jge 0xdba5
leaq 0xa(%rsp), %rdi
movq 0x30(%rsp), %rax
movq 0x68(%rax), %rax
movslq 0x14(%rsp), %rcx
movq (%rax,%rcx,8), %rsi
addq $0xa, %rsi
callq 0x2060
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl 0x14(%rsp), %ecx
leaq 0x10(%rsp), %rdx
movl $0x2, %r8d
xorl %r9d, %r9d
movss 0x1e638(%rip), %xmm0    # 0x2bdf8
movl $0x0, (%rsp)
callq 0xdbc0
movq 0x18(%rsp), %rax
cmpl $0x0, 0x1d48(%rax)
jne 0xd7df
jmp 0xdb95
leaq 0xa(%rsp), %rdi
leaq 0x1e09d(%rip), %rsi     # 0x2b888
callq 0x2130
cmpl $0x0, %eax
jne 0xd85a
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl 0x14(%rsp), %ecx
leaq 0x10(%rsp), %rdx
xorl %r8d, %r8d
movl $0x5, %r9d
movss 0x1e5df(%rip), %xmm0    # 0x2bdf8
movl $0x0, (%rsp)
callq 0xdbc0
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl 0x14(%rsp), %ecx
leaq 0x10(%rsp), %rdx
xorl %r8d, %r8d
movl $0x5, %r9d
movss 0x1e5af(%rip), %xmm0    # 0x2bdf8
movl $0x0, (%rsp)
callq 0xdbc0
jmp 0xdb93
leaq 0xa(%rsp), %rdi
leaq 0x1e03e(%rip), %rsi     # 0x2b8a4
callq 0x2130
cmpl $0x0, %eax
jne 0xd8aa
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl 0x14(%rsp), %ecx
leaq 0x10(%rsp), %rdx
movl $0x3, %r8d
movl $0x7, %r9d
movss 0x1e55d(%rip), %xmm0    # 0x2bdf4
xorl %eax, %eax
movl $0x0, (%rsp)
callq 0xdbc0
jmp 0xdb91
leaq 0xa(%rsp), %rdi
leaq 0x1dff2(%rip), %rsi     # 0x2b8a8
callq 0x2130
cmpl $0x0, %eax
jne 0xd8fa
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl 0x14(%rsp), %ecx
leaq 0x10(%rsp), %rdx
movl $0x3, %r8d
movl $0x8, %r9d
movss 0x1e50d(%rip), %xmm0    # 0x2bdf4
xorl %eax, %eax
movl $0x0, (%rsp)
callq 0xdbc0
jmp 0xdb8f
leaq 0xa(%rsp), %rdi
leaq 0x1df62(%rip), %rsi     # 0x2b868
callq 0x2130
cmpl $0x0, %eax
jne 0xd947
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl 0x14(%rsp), %ecx
leaq 0x10(%rsp), %rdx
movl $0x2, %r9d
movss 0x1e4c7(%rip), %xmm0    # 0x2bdf8
xorl %eax, %eax
movl %r9d, %r8d
movl $0x0, (%rsp)
callq 0xdbc0
jmp 0xdb8d
leaq 0xa(%rsp), %rdi
leaq 0x1df25(%rip), %rsi     # 0x2b878
callq 0x2130
cmpl $0x0, %eax
jne 0xd997
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl 0x14(%rsp), %ecx
leaq 0x10(%rsp), %rdx
movl $0x2, %r8d
movl $0x3, %r9d
movss 0x1e474(%rip), %xmm0    # 0x2bdf8
xorl %eax, %eax
movl $0x0, (%rsp)
callq 0xdbc0
jmp 0xdb8b
leaq 0xa(%rsp), %rdi
leaq 0x1dec9(%rip), %rsi     # 0x2b86c
callq 0x2130
cmpl $0x0, %eax
jne 0xda18
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl 0x14(%rsp), %ecx
leaq 0x10(%rsp), %rdx
movl $0x2, %r8d
movl $0xa, %r9d
movss 0x1e424(%rip), %xmm0    # 0x2bdf8
movl $0x1, (%rsp)
callq 0xdbc0
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl 0x14(%rsp), %ecx
leaq 0x10(%rsp), %rdx
movl $0x2, %r8d
movl $0xa, %r9d
movss 0x1e3f1(%rip), %xmm0    # 0x2bdf8
movl $0x2, (%rsp)
callq 0xdbc0
jmp 0xdb89
leaq 0xa(%rsp), %rdi
leaq 0x1de58(%rip), %rsi     # 0x2b87c
callq 0x2130
cmpl $0x0, %eax
jne 0xda99
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl 0x14(%rsp), %ecx
leaq 0x10(%rsp), %rdx
movl $0x2, %r8d
movl $0xb, %r9d
movss 0x1e3a3(%rip), %xmm0    # 0x2bdf8
movl $0x1, (%rsp)
callq 0xdbc0
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl 0x14(%rsp), %ecx
leaq 0x10(%rsp), %rdx
movl $0x2, %r8d
movl $0xb, %r9d
movss 0x1e370(%rip), %xmm0    # 0x2bdf8
movl $0x2, (%rsp)
callq 0xdbc0
jmp 0xdb87
leaq 0xa(%rsp), %rdi
leaq 0x1de0b(%rip), %rsi     # 0x2b8b0
callq 0x2130
cmpl $0x0, %eax
jne 0xdae9
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl 0x14(%rsp), %ecx
leaq 0x10(%rsp), %rdx
movl $0x2, %r8d
movl $0x9, %r9d
movss 0x1e31e(%rip), %xmm0    # 0x2bdf4
xorl %eax, %eax
movl $0x0, (%rsp)
callq 0xdbc0
jmp 0xdb85
leaq 0xa(%rsp), %rdi
leaq 0x1dda3(%rip), %rsi     # 0x2b898
callq 0x2130
cmpl $0x0, %eax
jne 0xdb36
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl 0x14(%rsp), %ecx
leaq 0x10(%rsp), %rdx
movl $0x4, %r8d
movl $0xc, %r9d
movss 0x1e2d6(%rip), %xmm0    # 0x2bdfc
xorl %eax, %eax
movl $0x0, (%rsp)
callq 0xdbc0
jmp 0xdb83
leaq 0xa(%rsp), %rdi
leaq 0x1dd32(%rip), %rsi     # 0x2b874
callq 0x2130
cmpl $0x0, %eax
jne 0xdb81
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl 0x14(%rsp), %ecx
leaq 0x10(%rsp), %rdx
movl $0x4, %r8d
movl $0xd, %r9d
movss 0x1e281(%rip), %xmm0    # 0x2bdf4
xorl %eax, %eax
movl $0x0, (%rsp)
callq 0xdbc0
jmp 0xdb83
jmp 0xdb85
jmp 0xdb87
jmp 0xdb89
jmp 0xdb8b
jmp 0xdb8d
jmp 0xdb8f
jmp 0xdb91
jmp 0xdb93
jmp 0xdb95
movl 0x14(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x14(%rsp)
jmp 0xd76b
movl 0x10(%rsp), %ecx
movq 0x20(%rsp), %rax
movl %ecx, (%rax)
movl 0x10(%rsp), %eax
addq $0x38, %rsp
retq
nopl (%rax)