// File: /workspace/github_c_makefile_star2_O0/ugobas[P]tnm/NeedlemanWunsch.c
// Function: CalcMDMScoreUC
int CalcMDMScoreUC(char resa, char resb)
{
   int        i,j;
   static int NWarn = 0;
   int       Warned = 0;

   resa = (islower(resa)?toupper(resa):resa);
   resb = (islower(resb)?toupper(resb):resb);

   for(i=0;i<sMDMSize;i++)
   {
      if(resa==sMDM_AAList[i]) break;
   }
   if(i==sMDMSize)
   {
      if(NWarn < 10)
         printf("Residue %c not found in matrix\n",resa);
      else if(NWarn == 10)
         printf("More residues not found in matrix...\n");
      Warned = 1;
   }
   for(j=0;j<sMDMSize;j++)
   {
      if(resb==sMDM_AAList[j]) break;
   }
   if(j==sMDMSize)
   {
      if(NWarn < 10)
         printf("Residue %c not found in matrix\n",resb);
      else if(NWarn == 10)
         printf("More residues not found in matrix...\n");
      Warned = 1;
   }

   if(Warned)
   {
      NWarn++;
      return(0);
   }

   return(sMDMScore[i][j]);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movb %sil, %al
movb %dil, %cl
movb %cl, -0x5(%rbp)
movb %al, -0x6(%rbp)
movl $0x0, -0x14(%rbp)
callq 0x1250
movq (%rax), %rax
movsbl -0x5(%rbp), %ecx
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x200, %eax            # imm = 0x200
cmpl $0x0, %eax
je 0x70186
movsbl -0x5(%rbp), %edi
callq 0x1070
movl %eax, -0x18(%rbp)
jmp 0x7018d
movsbl -0x5(%rbp), %eax
movl %eax, -0x18(%rbp)
movl -0x18(%rbp), %eax
movb %al, -0x5(%rbp)
callq 0x1250
movq (%rax), %rax
movsbl -0x6(%rbp), %ecx
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x200, %eax            # imm = 0x200
cmpl $0x0, %eax
je 0x701be
movsbl -0x6(%rbp), %edi
callq 0x1070
movl %eax, -0x1c(%rbp)
jmp 0x701c5
movsbl -0x6(%rbp), %eax
movl %eax, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
movb %al, -0x6(%rbp)
movl $0x0, -0xc(%rbp)
movl -0xc(%rbp), %eax
cmpl 0x2d87d(%rip), %eax     # 0x9da58
jge 0x70203
movsbl -0x5(%rbp), %eax
movq 0x2d880(%rip), %rcx     # 0x9da68
movslq -0xc(%rbp), %rdx
movsbl (%rcx,%rdx), %ecx
cmpl %ecx, %eax
jne 0x701f6
jmp 0x70203
jmp 0x701f8
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x701d2
movl -0xc(%rbp), %eax
cmpl 0x2d84c(%rip), %eax     # 0x9da58
jne 0x7024b
cmpl $0xa, 0x2d85f(%rip)     # 0x9da74
jge 0x7022b
movsbl -0x5(%rbp), %esi
leaq 0x1343a(%rip), %rdi     # 0x8365c
movb $0x0, %al
callq 0x10d0
jmp 0x70244
cmpl $0xa, 0x2d842(%rip)     # 0x9da74
jne 0x70242
leaq 0x13441(%rip), %rdi     # 0x8367c
movb $0x0, %al
callq 0x10d0
jmp 0x70244
movl $0x1, -0x14(%rbp)
movl $0x0, -0x10(%rbp)
movl -0x10(%rbp), %eax
cmpl 0x2d7fd(%rip), %eax     # 0x9da58
jge 0x70283
movsbl -0x6(%rbp), %eax
movq 0x2d800(%rip), %rcx     # 0x9da68
movslq -0x10(%rbp), %rdx
movsbl (%rcx,%rdx), %ecx
cmpl %ecx, %eax
jne 0x70276
jmp 0x70283
jmp 0x70278
movl -0x10(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x10(%rbp)
jmp 0x70252
movl -0x10(%rbp), %eax
cmpl 0x2d7cc(%rip), %eax     # 0x9da58
jne 0x702cb
cmpl $0xa, 0x2d7df(%rip)     # 0x9da74
jge 0x702ab
movsbl -0x6(%rbp), %esi
leaq 0x133ba(%rip), %rdi     # 0x8365c
movb $0x0, %al
callq 0x10d0
jmp 0x702c4
cmpl $0xa, 0x2d7c2(%rip)     # 0x9da74
jne 0x702c2
leaq 0x133c1(%rip), %rdi     # 0x8367c
movb $0x0, %al
callq 0x10d0
jmp 0x702c4
movl $0x1, -0x14(%rbp)
cmpl $0x0, -0x14(%rbp)
je 0x702e9
movl 0x2d79d(%rip), %eax     # 0x9da74
addl $0x1, %eax
movl %eax, 0x2d794(%rip)     # 0x9da74
movl $0x0, -0x4(%rbp)
jmp 0x70302
movq 0x2d770(%rip), %rax     # 0x9da60
movslq -0xc(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movslq -0x10(%rbp), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax,%rax)