// File: /workspace/github_cpp_makefile_star2_O3/atfrank[P]PCASA/lib/PDB.cpp
// Function: PDB::formatCHARMMResName[abi:cxx11](Atom*)
std::string PDB::formatCHARMMResName (Atom* atmEntry){
  if (atmEntry->getResName().compare("HIE") == 0){
    return "HSE";
  }
  else if (atmEntry->getResName().compare("HID") == 0){
    return "HSD";
  }
  else if (atmEntry->getResName().compare("HIP") == 0){
    return "HSP";
  }
  else if (atmEntry->getResName().compare("AHE") == 0){
    return "CT2";
  }
  else if (atmEntry->getResName().compare("NME") == 0){
    return "CT3";
  }
  else if (atmEntry->getResName().compare("CYX") == 0){
    std::cerr << "Warning: " << atmEntry->getSummary() << " has a disulfide bond" << std::endl;
    return "CYS";
  }
  else if (atmEntry->getResName().compare("FOR") == 0 || atmEntry->getResName().compare("CSO") == 0 || atmEntry->getResName().compare("CME") == 0 ){
    std::cerr << "Warning: " << atmEntry->getSummary() << " has no matching residue name in CHARMM" << std::endl;
    return atmEntry->getResName();
  }
  else{
    return atmEntry->getResName();
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x14916
leaq 0xef6f(%rip), %rsi      # 0x3b53b
movq %rax, %rdi
callq 0x40e0
testl %eax, %eax
je 0x2c75e
movq %r14, %rdi
callq 0x14916
leaq 0xef4c(%rip), %rsi      # 0x3b537
movq %rax, %rdi
callq 0x40e0
testl %eax, %eax
je 0x2c778
movq %r14, %rdi
callq 0x14916
leaq 0xef35(%rip), %rsi      # 0x3b53f
movq %rax, %rdi
callq 0x40e0
testl %eax, %eax
je 0x2c792
movq %r14, %rdi
callq 0x14916
leaq 0xff1c(%rip), %rsi      # 0x3c545
movq %rax, %rdi
callq 0x40e0
testl %eax, %eax
je 0x2c7ac
movq %r14, %rdi
callq 0x14916
leaq 0xff01(%rip), %rsi      # 0x3c549
movq %rax, %rdi
callq 0x40e0
testl %eax, %eax
je 0x2c7c6
movq %r14, %rdi
callq 0x14916
leaq 0xfeba(%rip), %rsi      # 0x3c521
movq %rax, %rdi
callq 0x40e0
testl %eax, %eax
je 0x2c7e0
movq %r14, %rdi
callq 0x14916
leaq 0x108b9(%rip), %rsi     # 0x3cf3f
movq %rax, %rdi
callq 0x40e0
testl %eax, %eax
je 0x2c6c8
movq %r14, %rdi
callq 0x14916
leaq 0xfeb0(%rip), %rsi      # 0x3c551
movq %rax, %rdi
callq 0x40e0
testl %eax, %eax
je 0x2c6c8
movq %r14, %rdi
callq 0x14916
leaq 0xfe99(%rip), %rsi      # 0x3c555
movq %rax, %rdi
callq 0x40e0
testl %eax, %eax
jne 0x2c738
movq 0x3c3921(%rip), %r15    # 0x3efff0
leaq 0xfe4f(%rip), %rsi      # 0x3c525
movl $0x9, %edx
movq %r15, %rdi
callq 0x4340
movq %r14, %rdi
callq 0x14976
movq (%rax), %rsi
movq 0x8(%rax), %rdx
movq %r15, %rdi
callq 0x4340
movq %rax, %r15
leaq 0xfe55(%rip), %rsi      # 0x3c559
movl $0x27, %edx
movq %rax, %rdi
callq 0x4340
movq (%r15), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x42a0
movsbl %al, %esi
movq %r15, %rdi
callq 0x4040
movq %rax, %rdi
callq 0x41f0
movq %r14, %rdi
callq 0x14916
leaq 0x10(%rbx), %rcx
movq %rcx, (%rbx)
movq (%rax), %rsi
movq 0x8(%rax), %rdx
addq %rsi, %rdx
movq %rbx, %rdi
callq 0x647c
jmp 0x2c86d
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
leaq 0xed71(%rip), %rsi      # 0x3b4dd
leaq 0xed6d(%rip), %rdx      # 0x3b4e0
jmp 0x2c865
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
leaq 0xed53(%rip), %rsi      # 0x3b4d9
leaq 0xed4f(%rip), %rdx      # 0x3b4dc
jmp 0x2c865
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
leaq 0xed41(%rip), %rsi      # 0x3b4e1
leaq 0xed3d(%rip), %rdx      # 0x3b4e4
jmp 0x2c865
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
leaq 0xff2e(%rip), %rsi      # 0x3c6e8
leaq 0xff2a(%rip), %rdx      # 0x3c6eb
jmp 0x2c865
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
leaq 0xff18(%rip), %rsi      # 0x3c6ec
leaq 0xff14(%rip), %rdx      # 0x3c6ef
jmp 0x2c865
movq 0x3c3809(%rip), %r15    # 0x3efff0
leaq 0xfd37(%rip), %rsi      # 0x3c525
movl $0x9, %edx
movq %r15, %rdi
callq 0x4340
movq %r14, %rdi
callq 0x14976
movq (%rax), %rsi
movq 0x8(%rax), %rdx
movq %r15, %rdi
callq 0x4340
movq %rax, %r14
leaq 0xfd13(%rip), %rsi      # 0x3c52f
movl $0x15, %edx
movq %rax, %rdi
callq 0x4340
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x42a0
movsbl %al, %esi
movq %r14, %rdi
callq 0x4040
movq %rax, %rdi
callq 0x41f0
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
leaq 0xefaf(%rip), %rsi      # 0x3b80d
leaq 0xefab(%rip), %rdx      # 0x3b810
movq %rbx, %rdi
callq 0x6512
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq