// File: /workspace/github_c_makefile_star2_O3/taeguk[P]Compiler-Proj-Cminus/src/util.c
// Function: printToken
void
printToken(TokenType token, const char* tokenString)
{
  switch (token)
    {
    case ENDFILE: fprintf(listing,"EOF\n"); break;
    case ERROR:   fprintf(listing,
                          "ERROR\t\t\t%s\n",
                          tokenString); break;

    case ID:      fprintf(listing,
                          "ID\t\t\t%s\n",
                          tokenString); break;
    case NUM:     fprintf(listing,
                          "NUM\t\t\t%s\n",
                          tokenString); break;

    case ELSE:    fprintf(listing,
                          "ELSE\t\t\t%s\n",
                          tokenString); break;
    case IF:      fprintf(listing,
                          "IF\t\t\t%s\n",
                          tokenString); break;
    case INT:     fprintf(listing,
                          "INT\t\t\t%s\n",
                          tokenString); break;
    case RETURN:  fprintf(listing,
                          "RETURN\t\t\t%s\n",
                          tokenString); break;
    case VOID:    fprintf(listing,
                          "VOID\t\t\t%s\n",
                          tokenString); break;
    case WHILE:   fprintf(listing,
                          "WHILE\t\t\t%s\n",
                          tokenString); break;

    case PLUS:    fprintf(listing,
                          "PLUS\t\t\t%s\n",
                          tokenString); break;
    case MINUS:   fprintf(listing,
                          "MINUS\t\t\t%s\n",
                          tokenString); break;
    case TIMES:   fprintf(listing,
                          "TIMES\t\t\t%s\n",
                          tokenString); break;
    case OVER:    fprintf(listing,
                          "OVER\t\t\t%s\n",
                          tokenString); break;

    case LT:      fprintf(listing,
                          "<\t\t\t%s\n",
                          tokenString); break;
    case LE:      fprintf(listing,
                          "<=\t\t\t%s\n",
                          tokenString); break;
    case GT:      fprintf(listing,
                          ">\t\t\t%s\n",
                          tokenString); break;
    case GE:      fprintf(listing,
                          ">=\t\t\t%s\n",
                          tokenString); break;
    case EQ:      fprintf(listing,
                          "==\t\t\t%s\n",
                          tokenString); break;
    case NE:      fprintf(listing,
                          "!=\t\t\t%s\n",
                          tokenString); break;

    case ASSIGN:  fprintf(listing,
                          "=\t\t\t%s\n",
                          tokenString); break;
    case SEMI:    fprintf(listing,
                          ";\t\t\t%s\n",
                          tokenString); break;
    case COMMA:   fprintf(listing,
                          ",\t\t\t%s\n",
                          tokenString); break;

    case LPAREN:   fprintf(listing,
                          "(\t\t\t%s\n",
                          tokenString); break;
    case RPAREN:   fprintf(listing,
                          ")\t\t\t%s\n",
                          tokenString); break;
    case LBRACK:   fprintf(listing,
                          "[\t\t\t%s\n",
                          tokenString); break;
    case RBRACK:   fprintf(listing,
                          "]\t\t\t%s\n",
                          tokenString); break;
    case LBRACE:   fprintf(listing,
                          "{\t\t\t%s\n",
                          tokenString); break;
    case RBRACE:   fprintf(listing,
                          "}\t\t\t%s\n",
                          tokenString); break;

    default:       /* should never happen */
           DONT_OCCUR_PRINT; 
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
addl $0xfffffefd, %edi       # imm = 0xFFFFFEFD
cmpl $0x1c, %edi
ja 0x52fb
movq %rsi, %rdx
leaq 0x29df(%rip), %rax      # 0x7a70
movslq (%rax,%rdi,4), %rcx
addq %rax, %rcx
jmpq *%rcx
leaq 0x615f(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2b09(%rip), %rsi      # 0x7bb4
jmp 0x530e
leaq 0x6149(%rip), %rax      # 0xb200
movq (%rax), %rcx
leaq 0x2aab(%rip), %rdi      # 0x7b6c
movl $0x4, %esi
movl $0x1, %edx
popq %rbp
jmp 0x11c0
leaq 0x6128(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2b37(%rip), %rsi      # 0x7c19
jmp 0x530e
leaq 0x6112(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2b10(%rip), %rsi      # 0x7c08
jmp 0x530e
leaq 0x60fc(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2ade(%rip), %rsi      # 0x7bec
jmp 0x530e
leaq 0x60e6(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2a77(%rip), %rsi      # 0x7b9b
jmp 0x530e
leaq 0x60d0(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2abd(%rip), %rsi      # 0x7bf7
jmp 0x530e
leaq 0x60ba(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2a84(%rip), %rsi      # 0x7bd4
jmp 0x530e
leaq 0x60a4(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2af5(%rip), %rsi      # 0x7c5b
jmp 0x530e
leaq 0x608e(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2ad7(%rip), %rsi      # 0x7c53
jmp 0x530e
leaq 0x6078(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x29f5(%rip), %rsi      # 0x7b87
jmp 0x530e
leaq 0x6062(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2a68(%rip), %rsi      # 0x7c10
jmp 0x530e
leaq 0x604c(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x29d4(%rip), %rsi      # 0x7b92
jmp 0x530e
leaq 0x6036(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x29e9(%rip), %rsi      # 0x7bbd
jmp 0x530e
leaq 0x6020(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2993(%rip), %rsi      # 0x7b7d
jmp 0x530e
leaq 0x600a(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2a22(%rip), %rsi      # 0x7c22
jmp 0x530e
leaq 0x5ff4(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2a1d(%rip), %rsi      # 0x7c33
jmp 0x530e
leaq 0x5fde(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2979(%rip), %rsi      # 0x7ba5
jmp 0x530e
leaq 0x5fc8(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x29f9(%rip), %rsi      # 0x7c3b
jmp 0x530e
leaq 0x5fb2(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x29a7(%rip), %rsi      # 0x7bff
jmp 0x530e
leaq 0x5f9c(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2944(%rip), %rsi      # 0x7bb2
jmp 0x530e
leaq 0x5f86(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x299f(%rip), %rsi      # 0x7c23
jmp 0x530e
leaq 0x5f70(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2946(%rip), %rsi      # 0x7be0
jmp 0x530e
leaq 0x5f5d(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x291c(%rip), %rsi      # 0x7bc9
jmp 0x530e
leaq 0x5f4a(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2983(%rip), %rsi      # 0x7c43
jmp 0x530e
leaq 0x5f37(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2958(%rip), %rsi      # 0x7c2b
jmp 0x530e
leaq 0x5f24(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2965(%rip), %rsi      # 0x7c4b
jmp 0x530e
leaq 0x5f11(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2878(%rip), %rsi      # 0x7b71
jmp 0x530e
popq %rbp
retq
leaq 0x5efc(%rip), %rax      # 0xb200
movq (%rax), %rdi
leaq 0x2955(%rip), %rsi      # 0x7c63
xorl %eax, %eax
popq %rbp
jmp 0x1120