#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
int atoi(char *);
int /*<<< orphan*/ example00();
int /*<<< orphan*/ example01();
int /*<<< orphan*/ example02();
int /*<<< orphan*/ example03();
int /*<<< orphan*/ example04();
int /*<<< orphan*/ example05();
main(int argc, char **args) {
  if (argc < 2)
    return 0;
  int example = atoi(args[1]);
  switch (example) {
  case 0:
    example00();
    break;
  case 1:
    example01();
    break;
  case 2:
    example02();
    break;
  case 3:
    example03();
    break;
  case 4:
    example04();
    break;
  case 5:
    example05();
    break;
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpl   $0x2,-0x8(%rbp)
jge    119c <main+0x2c>
movl   $0x0,-0x4(%rbp)
jmp    121b <main+0xab>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
call   1090 <atoi@plt>
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%eax
mov    %rax,-0x20(%rbp)
sub    $0x5,%rax
ja     1214 <main+0xa4>
mov    -0x20(%rbp),%rax
lea    0xe38(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
mov    $0x0,%al
call   1060 <example00@plt>
jmp    1214 <main+0xa4>
mov    $0x0,%al
call   1030 <example01@plt>
jmp    1214 <main+0xa4>
mov    $0x0,%al
call   1070 <example02@plt>
jmp    1214 <main+0xa4>
mov    $0x0,%al
call   1040 <example03@plt>
jmp    1214 <main+0xa4>
mov    $0x0,%al
call   1080 <example04@plt>
jmp    1214 <main+0xa4>
mov    $0x0,%al
call   1050 <example05@plt>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
cmp    $0x2,%edi
jge    117a <main+0xa>
xor    %eax,%eax
pop    %rcx
ret
mov    0x8(%rsi),%rdi
call   1090 <atoi@plt>
cmp    $0x5,%eax
ja     1176 <main+0x6>
mov    %eax,%eax
lea    0xe6f(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
xor    %eax,%eax
call   1060 <example00@plt>
jmp    1176 <main+0x6>
xor    %eax,%eax
call   1030 <example01@plt>
jmp    1176 <main+0x6>
xor    %eax,%eax
call   1070 <example02@plt>
jmp    1176 <main+0x6>
xor    %eax,%eax
call   1040 <example03@plt>
jmp    1176 <main+0x6>
xor    %eax,%eax
call   1080 <example04@plt>
jmp    1176 <main+0x6>
xor    %eax,%eax
call   1050 <example05@plt>
jmp    1176 <main+0x6>

LLVM IR (-O0):
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%7 = load i32, i32* %4
%8 = icmp slt i32 %7, 2
br i1 %8, label %9, label %10
9: ; preds = %2
store i32 0, i32* %3
br label %29
10: ; preds = %2
%11 = load i8**, i8*** %5
%12 = getelementptr inbounds i8*, i8** %11, i64 1
%13 = load i8*, i8** %12
%14 = call i32 @atoi(i8* %13)
store i32 %14, i32* %6
%15 = load i32, i32* %6
switch i32 %15, label %28 [
i32 0, label %16
i32 1, label %18
i32 2, label %20
i32 3, label %22
i32 4, label %24
i32 5, label %26
]
16: ; preds = %10
%17 = call i32 (...) @example00()
br label %28
18: ; preds = %10
%19 = call i32 (...) @example01()
br label %28
20: ; preds = %10
%21 = call i32 (...) @example02()
br label %28
22: ; preds = %10
%23 = call i32 (...) @example03()
br label %28
24: ; preds = %10
%25 = call i32 (...) @example04()
br label %28
26: ; preds = %10
%27 = call i32 (...) @example05()
br label %28
28: ; preds = %10, %26, %24, %22, %20, %18, %16
store i32 0, i32* %3
br label %29
29: ; preds = %28, %9
%30 = load i32, i32* %3
ret i32 %30
}

LLVM IR (-O2):
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = icmp slt i32 %0, 2
br i1 %3, label %20, label %4
4: ; preds = %2
%5 = getelementptr inbounds i8*, i8** %1, i64 1
%6 = load i8*, i8** %5
%7 = tail call i32 @atoi(i8* %6)
switch i32 %7, label %20 [
i32 0, label %8
i32 1, label %10
i32 2, label %12
i32 3, label %14
i32 4, label %16
i32 5, label %18
]
8: ; preds = %4
%9 = tail call i32 (...) @example00()
br label %20
10: ; preds = %4
%11 = tail call i32 (...) @example01()
br label %20
12: ; preds = %4
%13 = tail call i32 (...) @example02()
br label %20
14: ; preds = %4
%15 = tail call i32 (...) @example03()
br label %20
16: ; preds = %4
%17 = tail call i32 (...) @example04()
br label %20
18: ; preds = %4
%19 = tail call i32 (...) @example05()
br label %20
20: ; preds = %8, %10, %12, %14, %16, %18, %4, %2
ret i32 0
}