char reserveWord(char in) {
  switch (in) {
  case '<':
    return 2;
  case '>':
    return 3;
  case '/':
    return 4;
  case '=':
    return 5;
  case '\"':
    return 6;
  case ' ':
    return 7;
  case '\n':
    return 8;
  case '\t':
    return 9;
  case '\0':
    return 10;
  case '\\':
    return 11;
  case '\'':
    return 12;
  default:
    break;
  }
  return 0;
}


x86 assembly (clang, -O0):
<reserveWord>:
push   %rbp
mov    %rsp,%rbp
mov    %dil,%al
mov    %al,-0x2(%rbp)
movsbl -0x2(%rbp),%eax
mov    %eax,%ecx
mov    %rcx,-0x10(%rbp)
sub    $0x5c,%eax
ja     1194 <reserveWord+0x94>
mov    -0x10(%rbp),%rax
lea    0xed8(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
movb   $0x2,-0x1(%rbp)
jmp    119d <reserveWord+0x9d>
movb   $0x3,-0x1(%rbp)
jmp    119d <reserveWord+0x9d>
movb   $0x4,-0x1(%rbp)
jmp    119d <reserveWord+0x9d>
movb   $0x5,-0x1(%rbp)
jmp    119d <reserveWord+0x9d>
movb   $0x6,-0x1(%rbp)
jmp    119d <reserveWord+0x9d>
movb   $0x7,-0x1(%rbp)
jmp    119d <reserveWord+0x9d>
movb   $0x8,-0x1(%rbp)
jmp    119d <reserveWord+0x9d>
movb   $0x9,-0x1(%rbp)
jmp    119d <reserveWord+0x9d>
movb   $0xa,-0x1(%rbp)
jmp    119d <reserveWord+0x9d>
movb   $0xb,-0x1(%rbp)
jmp    119d <reserveWord+0x9d>
movb   $0xc,-0x1(%rbp)
jmp    119d <reserveWord+0x9d>
jmp    1199 <reserveWord+0x99>
movb   $0x0,-0x1(%rbp)
movsbl -0x1(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<reserveWord>:
cmp    $0x5c,%edi
ja     111c <reserveWord+0x1c>
mov    $0x2,%al
mov    %edi,%ecx
lea    0xef0(%rip),%rdx
movslq (%rdx,%rcx,4),%rcx
add    %rdx,%rcx
jmp    *%rcx
mov    $0xa,%al
ret
xor    %eax,%eax
ret
mov    $0x9,%al
ret
mov    $0x8,%al
ret
mov    $0x7,%al
ret
mov    $0x6,%al
ret
mov    $0xc,%al
ret
mov    $0x4,%al
ret
mov    $0x5,%al
ret
mov    $0x3,%al
ret
mov    $0xb,%al
ret

LLVM IR (-O0):
define signext i8 @reserveWord(i8 signext %0) {
%2 = alloca i8
%3 = alloca i8
store i8 %0, i8* %3
%4 = load i8, i8* %3
%5 = sext i8 %4 to i32
switch i32 %5, label %17 [
i32 60, label %6
i32 62, label %7
i32 47, label %8
i32 61, label %9
i32 34, label %10
i32 32, label %11
i32 10, label %12
i32 9, label %13
i32 0, label %14
i32 92, label %15
i32 39, label %16
]
6: ; preds = %1
store i8 2, i8* %2
br label %19
7: ; preds = %1
store i8 3, i8* %2
br label %19
8: ; preds = %1
store i8 4, i8* %2
br label %19
9: ; preds = %1
store i8 5, i8* %2
br label %19
10: ; preds = %1
store i8 6, i8* %2
br label %19
11: ; preds = %1
store i8 7, i8* %2
br label %19
12: ; preds = %1
store i8 8, i8* %2
br label %19
13: ; preds = %1
store i8 9, i8* %2
br label %19
14: ; preds = %1
store i8 10, i8* %2
br label %19
15: ; preds = %1
store i8 11, i8* %2
br label %19
16: ; preds = %1
store i8 12, i8* %2
br label %19
17: ; preds = %1
br label %18
18: ; preds = %17
store i8 0, i8* %2
br label %19
19: ; preds = %18, %16, %15, %14, %13, %12, %11, %10, %9, %8, %7, %6
%20 = load i8, i8* %2
ret i8 %20
}

LLVM IR (-O2):
define signext i8 @reserveWord(i8 signext %0) {
%2 = sext i8 %0 to i32
switch i32 %2, label %13 [
i32 60, label %14
i32 62, label %3
i32 47, label %4
i32 61, label %5
i32 34, label %6
i32 32, label %7
i32 10, label %8
i32 9, label %9
i32 0, label %10
i32 92, label %11
i32 39, label %12
]
3: ; preds = %1
br label %14
4: ; preds = %1
br label %14
5: ; preds = %1
br label %14
6: ; preds = %1
br label %14
7: ; preds = %1
br label %14
8: ; preds = %1
br label %14
9: ; preds = %1
br label %14
10: ; preds = %1
br label %14
11: ; preds = %1
br label %14
12: ; preds = %1
br label %14
13: ; preds = %1
br label %14
14: ; preds = %1, %13, %12, %11, %10, %9, %8, %7, %6, %5, %4, %3
%15 = phi i8 [ 0, %13 ], [ 12, %12 ], [ 11, %11 ], [ 10, %10 ], [ 9, %9 ], [ 8, %8 ], [ 7, %7 ], [ 6, %6 ], [ 5, %5 ], [ 4, %4 ], [ 3, %3 ], [ 2, %1 ]
ret i8 %15
}