// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: find_moto_cmd(int, int)
int find_moto_cmd(int cmd1, int cmd2)
{
   // !!!!! lookup Motorola binary command and return message length
   if     ((cmd1 == 'A') && (cmd2 == '@')) return (-1);

   else if((cmd1 == 'A') && (cmd2 == 'a')) return (10-7);
   else if((cmd1 == 'A') && (cmd2 == 'A')) return (8-7);
   else if((cmd1 == 'A') && (cmd2 == 'b')) return (10-7);
   else if((cmd1 == 'A') && (cmd2 == 'B')) return (8-7);
   else if((cmd1 == 'A') && (cmd2 == 'c')) return (11-7);
   else if((cmd1 == 'A') && (cmd2 == 'C')) return (9-7);
   else if((cmd1 == 'A') && (cmd2 == 'd')) return 11-7;
   else if((cmd1 == 'A') && (cmd2 == 'D')) return (9-7);
   else if((cmd1 == 'A') && (cmd2 == 'e')) return 11-7;
   else if((cmd1 == 'A') && (cmd2 == 'E')) return (8-7);
   else if((cmd1 == 'A') && (cmd2 == 'f')) return 15-7;
   else if((cmd1 == 'A') && (cmd2 == 'g')) return 8-7;
   else if((cmd1 == 'A') && (cmd2 == 'h')) return (8-7);
   else if((cmd1 == 'A') && (cmd2 == 'i')) return (9-7);
   else if((cmd1 == 'A') && (cmd2 == 'j')) return (8-7);
   else if((cmd1 == 'A') && (cmd2 == 'k')) return (9-7);
   else if((cmd1 == 'A') && (cmd2 == 'l')) return (9-7);
   else if((cmd1 == 'A') && (cmd2 == 'm')) return 12-7;
   else if((cmd1 == 'A') && (cmd2 == 'M')) return 11-7;
   else if((cmd1 == 'A') && (cmd2 == 'n')) return (8-7);
   else if((cmd1 == 'A') && (cmd2 == 'N')) return 8-7;
   else if((cmd1 == 'A') && (cmd2 == 'o')) return 25-7;
   else if((cmd1 == 'A') && (cmd2 == 'O')) return 8-7;
   else if((cmd1 == 'A') && (cmd2 == 'p')) return 25-7;
   else if((cmd1 == 'A') && (cmd2 == 'P')) return 8-7;
   else if((cmd1 == 'A') && (cmd2 == 'q')) return 8-7;
   else if((cmd1 == 'A') && (cmd2 == 'Q')) return 8-7;
   else if((cmd1 == 'A') && (cmd2 == 'r')) return (8-7);
   else if((cmd1 == 'A') && (cmd2 == 's')) return (20-7);
   else if((cmd1 == 'A') && (cmd2 == 't')) return (8-7);
   else if((cmd1 == 'A') && (cmd2 == 'u')) return (12-7);
   else if((cmd1 == 'A') && (cmd2 == 'v')) return (8-7);
   else if((cmd1 == 'A') && (cmd2 == 'w')) return 8-7;
   else if((cmd1 == 'A') && (cmd2 == 'x')) return (9-7);
   else if((cmd1 == 'A') && (cmd2 == 'y')) return 11-7;
   else if((cmd1 == 'A') && (cmd2 == 'z')) return 11-7;

   else if((cmd1 == 'B') && (cmd2 == 'a')) return 68-7;
   else if((cmd1 == 'B') && (cmd2 == 'b')) return 92-7;
   else if((cmd1 == 'B') && (cmd2 == 'c')) return 82-7;
   else if((cmd1 == 'B') && (cmd2 == 'd')) return 23-7;
   else if((cmd1 == 'B') && (cmd2 == 'e')) return 33-7;
   else if((cmd1 == 'B') && (cmd2 == 'f')) return 80-7;
   else if((cmd1 == 'B') && (cmd2 == 'g')) return 122-7;
   else if((cmd1 == 'B') && (cmd2 == 'h')) return 52-7;
   else if((cmd1 == 'B') && (cmd2 == 'i')) return 80-7;
   else if((cmd1 == 'B') && (cmd2 == 'j')) return 8-7;
   else if((cmd1 == 'B') && (cmd2 == 'k')) return 69-7;
   else if((cmd1 == 'B') && (cmd2 == 'l')) return 41-7;
   else if((cmd1 == 'B') && (cmd2 == 'n')) return 59-7;
   else if((cmd1 == 'B') && (cmd2 == 'o')) return 8-7;
   else if((cmd1 == 'B') && (cmd2 == 'p')) return 29-7;

   else if((cmd1 == 'C') && (cmd2 == 'a')) return 9-7;
   else if((cmd1 == 'C') && (cmd2 == 'b')) return 9-7;
   else if((cmd1 == 'C') && (cmd2 == 'd')) return 171-7;
   else if((cmd1 == 'C') && (cmd2 == 'e')) return 7-7;
   else if((cmd1 == 'C') && (cmd2 == 'f')) return 7-7;
   else if((cmd1 == 'C') && (cmd2 == 'g')) return 8-7;
   else if((cmd1 == 'C') && (cmd2 == 'h')) return 9-7;
   else if((cmd1 == 'C') && (cmd2 == 'i')) return 8-7;   // actually msg has no response
   else if((cmd1 == 'C') && (cmd2 == 'j')) return 294-7;
   else if((cmd1 == 'C') && (cmd2 == 'k')) return 7-7;
   else if((cmd1 == 'C') && (cmd2 == 'o')) return 29-7;

   else if((cmd1 == 'E') && (cmd2 == 'a')) return 76-7;
   else if((cmd1 == 'E') && (cmd2 == 'c')) return 82-7;
   else if((cmd1 == 'E') && (cmd2 == 'g')) return 158-7;
   else if((cmd1 == 'E') && (cmd2 == 'k')) return 71-7;
   else if((cmd1 == 'E') && (cmd2 == 'n')) return 69-7;
   else if((cmd1 == 'E') && (cmd2 == 'q')) return 96-9;  // !!!! BASTARD format

   else if((cmd1 == 'F') && (cmd2 == 'a')) return 9-7;
   else if((cmd1 == 'F') && (cmd2 == 'd')) return 189-7;

   else if((cmd1 == 'G') && (cmd2 == 'a')) return 20-7;
   else if((cmd1 == 'G') && (cmd2 == 'b')) return 17-7;
   else if((cmd1 == 'G') && (cmd2 == 'c')) return 8-7;
   else if((cmd1 == 'G') && (cmd2 == 'd')) return 8-7;
   else if((cmd1 == 'G') && (cmd2 == 'e')) return 8-7;
   else if((cmd1 == 'G') && (cmd2 == 'f')) return 9-7;
   else if((cmd1 == 'G') && (cmd2 == 'j')) return 21-7;
   else if((cmd1 == 'G') && (cmd2 == 'k')) return 13-7;

   else if((cmd1 == 'H') && (cmd2 == 'a')) return 154-7;
   else if((cmd1 == 'H') && (cmd2 == 'b')) return 54-7;
   else if((cmd1 == 'H') && (cmd2 == 'n')) return 78-7;
   else if((cmd1 == 'H') && (cmd2 == 'r')) return 170-7;

   else if((cmd1 == 'I') && (cmd2 == 'a')) return 10-7;

   else if((cmd1 == 'S') && (cmd2 == 'z')) return 8-7;

   else if((cmd1 == 'W') && (cmd2 == 'b')) return 8-7;

   return (-1);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movl %edi, %r14d
xorl $0x41, %edi
movl %esi, %ecx
xorl $0x40, %ecx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
orl %edi, %ecx
je 0x9c959
movl %esi, %edx
xorl $0x61, %edx
movl $0x3, %eax
movl %edi, %ecx
orl %edx, %ecx
je 0x9c959
movl %esi, %ecx
xorl $0x41, %ecx
orl %edi, %ecx
jne 0x9c923
movl $0x1, %eax
jmp 0x9c959
movl %esi, %ecx
xorl $0x62, %ecx
movl %edi, %r8d
orl %ecx, %r8d
je 0x9c959
movl %esi, %eax
xorl $0x42, %eax
orl %edi, %eax
je 0x9c91c
movl %esi, %ebx
xorl $0x63, %ebx
movl %edi, %eax
orl %ebx, %eax
jne 0x9c94b
movl $0x4, %eax
jmp 0x9c959
movl %esi, %eax
xorl $0x43, %eax
orl %edi, %eax
jne 0x9c964
movl $0x2, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl %esi, %r9d
xorl $0x64, %r9d
movl %edi, %eax
orl %r9d, %eax
je 0x9c944
movl %esi, %eax
xorl $0x44, %eax
orl %edi, %eax
je 0x9c954
movl %esi, %r10d
xorl $0x65, %r10d
movl %edi, %eax
orl %r10d, %eax
je 0x9c944
movl %esi, %eax
xorl $0x45, %eax
orl %edi, %eax
je 0x9c91c
movl %esi, %r8d
xorl $0x66, %r8d
movl $0x8, %eax
movl %edi, %r11d
orl %r8d, %r11d
je 0x9c959
movl %esi, %r15d
xorl $0x67, %r15d
movl %edi, %eax
orl %r15d, %eax
je 0x9c91c
movl %esi, %r13d
xorl $0x68, %r13d
movl %edi, %eax
orl %r13d, %eax
je 0x9c91c
movl %esi, %r12d
xorl $0x69, %r12d
movl %edi, %eax
orl %r12d, %eax
je 0x9c954
movl %esi, %r11d
xorl $0x6a, %r11d
movl %edi, %eax
movl %r11d, -0x38(%rbp)
orl %r11d, %eax
je 0x9c91c
movl %esi, %r11d
xorl $0x6b, %r11d
movl %edi, %eax
movl %r11d, -0x2c(%rbp)
orl %r11d, %eax
je 0x9c954
movl %esi, %r11d
xorl $0x6c, %r11d
movl %edi, %eax
movl %r11d, -0x34(%rbp)
orl %r11d, %eax
je 0x9c954
movl %esi, %r11d
xorl $0x6d, %r11d
movl $0x5, %eax
orl %edi, %r11d
je 0x9c959
movl %esi, %eax
xorl $0x4d, %eax
orl %edi, %eax
je 0x9c944
leal -0x4e(%rsi), %eax
testl $0xffffffdf, %eax       # imm = 0xFFFFFFDF
sete %al
cmpl $0x41, %r14d
jne 0x9ca59
testb %al, %al
jne 0x9c91c
movl %esi, %eax
xorl $0x6f, %eax
movl %eax, -0x30(%rbp)
movl $0x12, %eax
movl %edi, %r11d
orl -0x30(%rbp), %r11d
je 0x9c959
movl %esi, %r11d
xorl $0x4f, %r11d
orl %edi, %r11d
je 0x9c91c
movl %esi, %r11d
xorl $0x70, %r11d
movl %r11d, -0x3c(%rbp)
movl %edi, %r11d
orl -0x3c(%rbp), %r11d
je 0x9c959
movl %esi, %eax
xorl $0x50, %eax
orl %edi, %eax
je 0x9c91c
leal -0x51(%rsi), %eax
testl $0xffffffdf, %eax       # imm = 0xFFFFFFDF
sete %al
cmpl $0x41, %r14d
jne 0x9cac1
testb %al, %al
jne 0x9c91c
movl %esi, %r11d
xorl $0x72, %r11d
movl %edi, %eax
movl %r11d, -0x44(%rbp)
orl %r11d, %eax
je 0x9c91c
movl %esi, %r11d
xorl $0x73, %r11d
movl $0xd, %eax
orl %edi, %r11d
je 0x9c959
movl %esi, %eax
xorl $0x74, %eax
orl %edi, %eax
je 0x9c91c
movl %esi, %eax
xorl $0x75, %eax
orl %edi, %eax
movl $0x5, %eax
je 0x9c959
movl %esi, %eax
andl $-0x2, %eax
xorl $0x76, %eax
orl %edi, %eax
je 0x9c91c
movl %esi, %eax
xorl $0x78, %eax
orl %edi, %eax
je 0x9c954
movl %esi, %eax
xorl $0x79, %eax
orl %edi, %eax
je 0x9c944
movl %esi, %eax
xorl $0x7a, %eax
movl %eax, -0x40(%rbp)
orl %eax, %edi
movl $0x4, %eax
je 0x9c959
movl %r14d, %edi
xorl $0x42, %edi
movl $0x3d, %eax
movl %edi, %r11d
orl %edx, %r11d
je 0x9c959
movl $0x55, %eax
movl %edi, %r11d
orl %ecx, %r11d
je 0x9c959
movl $0x4b, %eax
movl %edi, %r11d
orl %ebx, %r11d
je 0x9c959
movl $0x10, %eax
movl %edi, %r11d
orl %r9d, %r11d
je 0x9c959
movl $0x1a, %eax
orl %edi, %r10d
je 0x9c959
movl $0x49, %eax
movl %edi, %r10d
orl %r8d, %r10d
je 0x9c959
movl $0x73, %eax
movl %edi, %r10d
orl %r15d, %r10d
je 0x9c959
movl $0x2d, %eax
movl %edi, %r10d
orl %r13d, %r10d
je 0x9c959
movl %edi, %eax
orl %r12d, %eax
movl $0x49, %eax
je 0x9c959
movl %edi, %eax
orl -0x38(%rbp), %eax
je 0x9c91c
movl $0x3e, %eax
movl %edi, %r10d
orl -0x2c(%rbp), %r10d
je 0x9c959
movl $0x22, %eax
orl %edi, -0x34(%rbp)
je 0x9c959
movl %esi, %r10d
xorl $0x6e, %r10d
movl $0x34, %eax
movl %edi, %r11d
orl %r10d, %r11d
je 0x9c959
movl %edi, %eax
orl -0x30(%rbp), %eax
je 0x9c91c
movl $0x16, %eax
orl -0x3c(%rbp), %edi
je 0x9c959
cmpl $0x43, %r14d
sete %al
leal -0x61(%rsi), %edi
cmpl $0x2, %edi
setb %dil
testb %dil, %al
jne 0x9c954
movl %r14d, %edi
xorl $0x43, %edi
movl $0xa4, %eax
movl %edi, %r11d
orl %r9d, %r11d
je 0x9c959
cmpl $0x43, %r14d
sete -0x34(%rbp)
leal -0x65(%rsi), %eax
cmpl $0x2, %eax
setb %r11b
xorl %eax, %eax
testb %r11b, -0x34(%rbp)
jne 0x9c959
movl %edi, %eax
orl %r15d, %eax
je 0x9c91c
orl %edi, %r13d
je 0x9c954
orl %edi, %r12d
je 0x9c91c
movl $0x11f, %eax            # imm = 0x11F
movl %edi, %r11d
orl -0x38(%rbp), %r11d
je 0x9c959
movl %edi, %eax
orl -0x2c(%rbp), %eax
movl $0x0, %eax
je 0x9c959
orl -0x30(%rbp), %edi
movl $0x16, %eax
je 0x9c959
movl %r14d, %edi
xorl $0x45, %edi
movl $0x45, %eax
movl %edi, %r11d
orl %edx, %r11d
je 0x9c959
orl %edi, %ebx
movl $0x4b, %eax
je 0x9c959
movl $0x97, %eax
orl %edi, %r15d
je 0x9c959
movl $0x40, %eax
movl %edi, %r11d
orl -0x2c(%rbp), %r11d
je 0x9c959
movl %edi, %eax
orl %r10d, %eax
movl $0x3e, %eax
je 0x9c959
movl %esi, %r11d
xorl $0x71, %r11d
movl $0x57, %eax
orl %r11d, %edi
je 0x9c959
movl %r14d, %edi
xorl $0x46, %edi
movl %edi, %eax
orl %edx, %eax
je 0x9c954
movl $0xb6, %eax
orl %r9d, %edi
je 0x9c959
movl %r14d, %edi
xorl $0x47, %edi
movl %edi, %eax
orl %edx, %eax
movl $0xd, %eax
je 0x9c959
movl $0xa, %eax
movl %edi, %r9d
orl %ecx, %r9d
je 0x9c959
cmpl $0x47, %r14d
sete %al
addl $-0x63, %esi
cmpl $0x3, %esi
setb %sil
testb %sil, %al
jne 0x9c91c
orl %edi, %r8d
movl $0x2, %eax
je 0x9c959
movl $0xe, %eax
orl %edi, -0x38(%rbp)
je 0x9c959
movl $0x6, %eax
orl -0x2c(%rbp), %edi
je 0x9c959
movl %r14d, %esi
xorl $0x48, %esi
movl $0x93, %eax
movl %esi, %edi
orl %edx, %edi
je 0x9c959
movl $0x2f, %eax
movl %esi, %edi
orl %ecx, %edi
je 0x9c959
movl $0x47, %eax
orl %esi, %r10d
je 0x9c959
movl $0xa3, %eax
orl -0x44(%rbp), %esi
je 0x9c959
movl %r14d, %eax
xorl $0x49, %eax
orl %edx, %eax
movl $0x3, %eax
je 0x9c959
movl %r14d, %eax
xorl $0x53, %eax
orl -0x40(%rbp), %eax
movl $0x1, %eax
je 0x9c959
xorl $0x57, %r14d
xorl %eax, %eax
orl %ecx, %r14d
sete %al
leal -0x1(,%rax,2), %eax
jmp 0x9c959