const char *CG_GetStringForTimer(int timer) {
  switch (timer) {
  case 272:
    return "ui_roundtimerworld";
  case 273:
    return "ui_viptimer";
  case 274:
    return "ui_assaulttimer1";
  case 295:
    return "ui_assaulttimer2";
  case 296:
    return "ui_assaulttimer3";
  case 297:
    return "ui_assaulttimer4";
  case 298:
    return "ui_bombtimer";
  default:
    return "ui_roundtimerworld";
  }
}


x86 assembly (clang, -O0):
<CG_GetStringForTimer>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0xc(%rbp)
mov    -0xc(%rbp),%eax
add    $0xfffffef0,%eax
mov    %eax,%ecx
mov    %rcx,-0x18(%rbp)
sub    $0x1a,%eax
ja     11a2 <CG_GetStringForTimer+0xa2>
mov    -0x18(%rbp),%rax
lea    0xed7(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
lea    0xf33(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    11ad <CG_GetStringForTimer+0xad>
lea    0xf36(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    11ad <CG_GetStringForTimer+0xad>
lea    0xf32(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    11ad <CG_GetStringForTimer+0xad>
lea    0xf33(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    11ad <CG_GetStringForTimer+0xad>
lea    0xf34(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    11ad <CG_GetStringForTimer+0xad>
lea    0xf35(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    11ad <CG_GetStringForTimer+0xad>
lea    0xf36(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    11ad <CG_GetStringForTimer+0xad>
lea    0xec3(%rip),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<CG_GetStringForTimer>:
lea    0xf61(%rip),%rax
add    $0xfffffeef,%edi
cmp    $0x19,%edi
ja     1151 <CG_GetStringForTimer+0x51>
lea    0xee7(%rip),%rcx
movslq (%rcx,%rdi,4),%rdx
add    %rcx,%rdx
jmp    *%rdx
lea    0xf52(%rip),%rax
ret
lea    0xf56(%rip),%rax
ret
lea    0xf5f(%rip),%rax
ret
lea    0xf68(%rip),%rax
ret
lea    0xf71(%rip),%rax
ret
lea    0xf7a(%rip),%rax
ret

LLVM IR (-O0):
@.str = [19 x i8] c"ui_roundtimerworld\00"
@.str.1 = [12 x i8] c"ui_viptimer\00"
@.str.2 = [17 x i8] c"ui_assaulttimer1\00"
@.str.3 = [17 x i8] c"ui_assaulttimer2\00"
@.str.4 = [17 x i8] c"ui_assaulttimer3\00"
@.str.5 = [17 x i8] c"ui_assaulttimer4\00"
@.str.6 = [13 x i8] c"ui_bombtimer\00"
define i8* @CG_GetStringForTimer(i32 %0) {
%2 = alloca i8*
%3 = alloca i32
store i32 %0, i32* %3
%4 = load i32, i32* %3
switch i32 %4, label %12 [
i32 272, label %5
i32 273, label %6
i32 274, label %7
i32 295, label %8
i32 296, label %9
i32 297, label %10
i32 298, label %11
]
5: ; preds = %1
store i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0), i8** %2
br label %13
6: ; preds = %1
store i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i8** %2
br label %13
7: ; preds = %1
store i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.2, i64 0, i64 0), i8** %2
br label %13
8: ; preds = %1
store i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.3, i64 0, i64 0), i8** %2
br label %13
9: ; preds = %1
store i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.4, i64 0, i64 0), i8** %2
br label %13
10: ; preds = %1
store i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.5, i64 0, i64 0), i8** %2
br label %13
11: ; preds = %1
store i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.6, i64 0, i64 0), i8** %2
br label %13
12: ; preds = %1
store i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0), i8** %2
br label %13
13: ; preds = %12, %11, %10, %9, %8, %7, %6, %5
%14 = load i8*, i8** %2
ret i8* %14
}

LLVM IR (-O2):
@.str = [19 x i8] c"ui_roundtimerworld\00"
@.str.1 = [12 x i8] c"ui_viptimer\00"
@.str.2 = [17 x i8] c"ui_assaulttimer1\00"
@.str.3 = [17 x i8] c"ui_assaulttimer2\00"
@.str.4 = [17 x i8] c"ui_assaulttimer3\00"
@.str.5 = [17 x i8] c"ui_assaulttimer4\00"
@.str.6 = [13 x i8] c"ui_bombtimer\00"
define i8* @CG_GetStringForTimer(i32 %0) {
switch i32 %0, label %8 [
i32 298, label %7
i32 273, label %2
i32 274, label %3
i32 295, label %4
i32 296, label %5
i32 297, label %6
]
2: ; preds = %1
br label %8
3: ; preds = %1
br label %8
4: ; preds = %1
br label %8
5: ; preds = %1
br label %8
6: ; preds = %1
br label %8
7: ; preds = %1
br label %8
8: ; preds = %1, %7, %6, %5, %4, %3, %2
%9 = phi i8* [ getelementptr inbounds ([13 x i8], [13 x i8]* @.str.6, i64 0, i64 0), %7 ], [ getelementptr inbounds ([17 x i8], [17 x i8]* @.str.5, i64 0, i64 0), %6 ], [ getelementptr inbounds ([17 x i8], [17 x i8]* @.str.4, i64 0, i64 0), %5 ], [ getelementptr inbounds ([17 x i8], [17 x i8]* @.str.3, i64 0, i64 0), %4 ], [ getelementptr inbounds ([17 x i8], [17 x i8]* @.str.2, i64 0, i64 0), %3 ], [ getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), %2 ], [ getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0), %1 ]
ret i8* %9
}