#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 */
double atof(char *);
int atoi(char *);
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ gp2x_deinit();
int /*<<< orphan*/ set_FCLK(int);
int /*<<< orphan*/ set_add_FLCDCLK(int);
int /*<<< orphan*/ set_add_ULCDCLK(int);
int /*<<< orphan*/ set_gamma(double);
void fallback(int argc, char *argv[]) {
  if (argc == 3) {
    if (atoi(argv[1]) == 0) {
      if (atoi(argv[2]) > 36) {
        gp2x_deinit();
        exit(1);
      }
      if (atoi(argv[2]) < -20) {
        gp2x_deinit();
        exit(1);
      }
      set_add_FLCDCLK(atoi(argv[2]));
    } else {
      if (atoi(argv[2]) > 10) {
        gp2x_deinit();
        exit(1);
      }
      if (atoi(argv[2]) < -5) {
        gp2x_deinit();
        exit(1);
      }
      set_add_ULCDCLK(atoi(argv[2]));
    }
  }
  if (argc == 4) {
    if (atoi(argv[3]) > 320) {
      gp2x_deinit();
      exit(1);
    }
    if (atoi(argv[3]) < 33) {
      gp2x_deinit();
      exit(1);
    }
    if (atoi(argv[1]) == 0) {
      if (atoi(argv[2]) > 36) {
        gp2x_deinit();
        exit(1);
      }
      if (atoi(argv[2]) < -20) {
        gp2x_deinit();
        exit(1);
      }
      set_add_FLCDCLK(atoi(argv[2]));
    } else {
      if (atoi(argv[2]) > 10) {
        gp2x_deinit();
        exit(1);
      }
      if (atoi(argv[2]) < -5) {
        gp2x_deinit();
        exit(1);
      }
      set_add_ULCDCLK(atoi(argv[2]));
    }
    set_FCLK(atoi(argv[3]));
  }
  if (argc == 5) {
    if (atoi(argv[3]) > 320) {
      gp2x_deinit();
      exit(1);
    }
    if (atoi(argv[3]) < 33) {
      gp2x_deinit();
      exit(1);
    }
    if (atof(argv[4]) > 10) {
      gp2x_deinit();
      exit(1);
    }
    if (atof(argv[4]) < 0.02) {
      gp2x_deinit();
      exit(1);
    }
    if (atoi(argv[1]) == 0) {
      if (atoi(argv[2]) > 36) {
        gp2x_deinit();
        exit(1);
      }
      if (atoi(argv[2]) < -20) {
        gp2x_deinit();
        exit(1);
      }
      set_add_FLCDCLK(atoi(argv[2]));
    } else {
      if (atoi(argv[2]) > 10) {
        gp2x_deinit();
        exit(1);
      }
      if (atoi(argv[2]) < -5) {
        gp2x_deinit();
        exit(1);
      }
      set_add_ULCDCLK(atoi(argv[2]));
    }
    set_FCLK(atoi(argv[3]));
    set_gamma(atof(argv[4]));
  }
}


x86 assembly (clang, -O0):
<fallback>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
cmpl   $0x3,-0x4(%rbp)
jne    127d <fallback+0xfd>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0x0,%eax
jne    1216 <fallback+0x96>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0x24,%eax
jle    11d6 <fallback+0x56>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0xffffffec,%eax
jge    11fd <fallback+0x7d>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
mov    %eax,%edi
call   1070 <set_add_FLCDCLK@plt>
jmp    1278 <fallback+0xf8>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0xa,%eax
jle    123d <fallback+0xbd>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0xfffffffb,%eax
jge    1264 <fallback+0xe4>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
mov    %eax,%edi
call   1080 <set_add_ULCDCLK@plt>
jmp    127d <fallback+0xfd>
cmpl   $0x4,-0x4(%rbp)
jne    13ca <fallback+0x24a>
mov    -0x10(%rbp),%rax
mov    0x18(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0x140,%eax
jle    12b0 <fallback+0x130>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x18(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0x21,%eax
jge    12d7 <fallback+0x157>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0x0,%eax
jne    1354 <fallback+0x1d4>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0x24,%eax
jle    1314 <fallback+0x194>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0xffffffec,%eax
jge    133b <fallback+0x1bb>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
mov    %eax,%edi
call   1070 <set_add_FLCDCLK@plt>
jmp    13b6 <fallback+0x236>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0xa,%eax
jle    137b <fallback+0x1fb>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0xfffffffb,%eax
jge    13a2 <fallback+0x222>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
mov    %eax,%edi
call   1080 <set_add_ULCDCLK@plt>
mov    -0x10(%rbp),%rax
mov    0x18(%rax),%rdi
call   1090 <atoi@plt>
mov    %eax,%edi
call   1060 <set_FCLK@plt>
cmpl   $0x5,-0x4(%rbp)
jne    158c <fallback+0x40c>
mov    -0x10(%rbp),%rax
mov    0x18(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0x140,%eax
jle    13fd <fallback+0x27d>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x18(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0x21,%eax
jge    1424 <fallback+0x2a4>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x20(%rax),%rdi
call   1040 <atof@plt>
movsd  0xbc7(%rip),%xmm1
ucomisd %xmm1,%xmm0
jbe    1454 <fallback+0x2d4>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x20(%rax),%rdi
call   1040 <atof@plt>
movaps %xmm0,%xmm1
movsd  0xb9c(%rip),%xmm0
ucomisd %xmm1,%xmm0
jbe    1487 <fallback+0x307>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0x0,%eax
jne    1504 <fallback+0x384>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0x24,%eax
jle    14c4 <fallback+0x344>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0xffffffec,%eax
jge    14eb <fallback+0x36b>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
mov    %eax,%edi
call   1070 <set_add_FLCDCLK@plt>
jmp    1566 <fallback+0x3e6>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0xa,%eax
jle    152b <fallback+0x3ab>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
cmp    $0xfffffffb,%eax
jge    1552 <fallback+0x3d2>
mov    $0x0,%al
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1090 <atoi@plt>
mov    %eax,%edi
call   1080 <set_add_ULCDCLK@plt>
mov    -0x10(%rbp),%rax
mov    0x18(%rax),%rdi
call   1090 <atoi@plt>
mov    %eax,%edi
call   1060 <set_FCLK@plt>
mov    -0x10(%rbp),%rax
mov    0x20(%rax),%rdi
call   1040 <atof@plt>
call   1030 <set_gamma@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<fallback>:
push   %rbp
push   %rbx
push   %rax
mov    %rsi,%rbx
cmp    $0x5,%edi
je     11d8 <fallback+0x58>
cmp    $0x4,%edi
je     1255 <fallback+0xd5>
cmp    $0x3,%edi
jne    12a5 <fallback+0x125>
mov    0x8(%rbx),%rdi
call   1090 <atoi@plt>
mov    %eax,%ebp
mov    0x10(%rbx),%rdi
call   1090 <atoi@plt>
test   %ebp,%ebp
je     12ac <fallback+0x12c>
cmp    $0xb,%eax
jge    131f <fallback+0x19f>
cmp    $0xfffffffa,%eax
jle    131f <fallback+0x19f>
mov    %eax,%edi
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1080 <set_add_ULCDCLK@plt>
mov    0x18(%rbx),%rdi
call   1090 <atoi@plt>
cmp    $0x141,%eax
jge    131f <fallback+0x19f>
cmp    $0x20,%eax
jle    131f <fallback+0x19f>
mov    0x20(%rbx),%rdi
call   1040 <atof@plt>
ucomisd 0xdfa(%rip),%xmm0
ja     131f <fallback+0x19f>
movsd  0xdf4(%rip),%xmm1
ucomisd %xmm0,%xmm1
ja     131f <fallback+0x19f>
mov    0x8(%rbx),%rdi
call   1090 <atoi@plt>
mov    %eax,%ebp
mov    0x10(%rbx),%rdi
call   1090 <atoi@plt>
test   %ebp,%ebp
je     12c3 <fallback+0x143>
cmp    $0xb,%eax
jge    131f <fallback+0x19f>
cmp    $0xfffffffa,%eax
jle    131f <fallback+0x19f>
mov    %eax,%edi
call   1080 <set_add_ULCDCLK@plt>
jmp    12d4 <fallback+0x154>
mov    0x18(%rbx),%rdi
call   1090 <atoi@plt>
cmp    $0x141,%eax
jge    131f <fallback+0x19f>
cmp    $0x20,%eax
jle    131f <fallback+0x19f>
mov    0x8(%rbx),%rdi
call   1090 <atoi@plt>
mov    %eax,%ebp
mov    0x10(%rbx),%rdi
call   1090 <atoi@plt>
test   %ebp,%ebp
je     12f8 <fallback+0x178>
cmp    $0xb,%eax
jge    131f <fallback+0x19f>
cmp    $0xfffffffa,%eax
jle    131f <fallback+0x19f>
mov    %eax,%edi
call   1080 <set_add_ULCDCLK@plt>
jmp    1309 <fallback+0x189>
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret
cmp    $0x25,%eax
jge    131f <fallback+0x19f>
cmp    $0xffffffeb,%eax
jle    131f <fallback+0x19f>
mov    %eax,%edi
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1070 <set_add_FLCDCLK@plt>
cmp    $0x25,%eax
jge    131f <fallback+0x19f>
cmp    $0xffffffeb,%eax
jle    131f <fallback+0x19f>
mov    %eax,%edi
call   1070 <set_add_FLCDCLK@plt>
mov    0x18(%rbx),%rdi
call   1090 <atoi@plt>
mov    %eax,%edi
call   1060 <set_FCLK@plt>
mov    0x20(%rbx),%rdi
call   1040 <atof@plt>
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1030 <set_gamma@plt>
cmp    $0x25,%eax
jge    131f <fallback+0x19f>
cmp    $0xffffffeb,%eax
jle    131f <fallback+0x19f>
mov    %eax,%edi
call   1070 <set_add_FLCDCLK@plt>
mov    0x18(%rbx),%rdi
call   1090 <atoi@plt>
mov    %eax,%edi
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1060 <set_FCLK@plt>
xor    %eax,%eax
call   1050 <gp2x_deinit@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>

LLVM IR (-O0):
define void @fallback(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i8**
store i32 %0, i32* %3
store i8** %1, i8*** %4
%5 = load i32, i32* %3
%6 = icmp eq i32 %5, 3
br i1 %6, label %7, label %62
7: ; preds = %2
%8 = load i8**, i8*** %4
%9 = getelementptr inbounds i8*, i8** %8, i64 1
%10 = load i8*, i8** %9
%11 = call i32 @atoi(i8* %10)
%12 = icmp eq i32 %11, 0
br i1 %12, label %13, label %37
13: ; preds = %7
%14 = load i8**, i8*** %4
%15 = getelementptr inbounds i8*, i8** %14, i64 2
%16 = load i8*, i8** %15
%17 = call i32 @atoi(i8* %16)
%18 = icmp sgt i32 %17, 36
br i1 %18, label %19, label %22
19: ; preds = %13
%20 = call i32 (...) @gp2x_deinit()
%21 = call i32 @exit(i32 1)
unreachable
22: ; preds = %13
%23 = load i8**, i8*** %4
%24 = getelementptr inbounds i8*, i8** %23, i64 2
%25 = load i8*, i8** %24
%26 = call i32 @atoi(i8* %25)
%27 = icmp slt i32 %26, -20
br i1 %27, label %28, label %31
28: ; preds = %22
%29 = call i32 (...) @gp2x_deinit()
%30 = call i32 @exit(i32 1)
unreachable
31: ; preds = %22
%32 = load i8**, i8*** %4
%33 = getelementptr inbounds i8*, i8** %32, i64 2
%34 = load i8*, i8** %33
%35 = call i32 @atoi(i8* %34)
%36 = call i32 @set_add_FLCDCLK(i32 %35)
br label %61
37: ; preds = %7
%38 = load i8**, i8*** %4
%39 = getelementptr inbounds i8*, i8** %38, i64 2
%40 = load i8*, i8** %39
%41 = call i32 @atoi(i8* %40)
%42 = icmp sgt i32 %41, 10
br i1 %42, label %43, label %46
43: ; preds = %37
%44 = call i32 (...) @gp2x_deinit()
%45 = call i32 @exit(i32 1)
unreachable
46: ; preds = %37
%47 = load i8**, i8*** %4
%48 = getelementptr inbounds i8*, i8** %47, i64 2
%49 = load i8*, i8** %48
%50 = call i32 @atoi(i8* %49)
%51 = icmp slt i32 %50, -5
br i1 %51, label %52, label %55
52: ; preds = %46
%53 = call i32 (...) @gp2x_deinit()
%54 = call i32 @exit(i32 1)
unreachable
55: ; preds = %46
%56 = load i8**, i8*** %4
%57 = getelementptr inbounds i8*, i8** %56, i64 2
%58 = load i8*, i8** %57
%59 = call i32 @atoi(i8* %58)
%60 = call i32 @set_add_ULCDCLK(i32 %59)
br label %61
61: ; preds = %55, %31
br label %62
62: ; preds = %61, %2
%63 = load i32, i32* %3
%64 = icmp eq i32 %63, 4
br i1 %64, label %65, label %143
65: ; preds = %62
%66 = load i8**, i8*** %4
%67 = getelementptr inbounds i8*, i8** %66, i64 3
%68 = load i8*, i8** %67
%69 = call i32 @atoi(i8* %68)
%70 = icmp sgt i32 %69, 320
br i1 %70, label %71, label %74
71: ; preds = %65
%72 = call i32 (...) @gp2x_deinit()
%73 = call i32 @exit(i32 1)
unreachable
74: ; preds = %65
%75 = load i8**, i8*** %4
%76 = getelementptr inbounds i8*, i8** %75, i64 3
%77 = load i8*, i8** %76
%78 = call i32 @atoi(i8* %77)
%79 = icmp slt i32 %78, 33
br i1 %79, label %80, label %83
80: ; preds = %74
%81 = call i32 (...) @gp2x_deinit()
%82 = call i32 @exit(i32 1)
unreachable
83: ; preds = %74
%84 = load i8**, i8*** %4
%85 = getelementptr inbounds i8*, i8** %84, i64 1
%86 = load i8*, i8** %85
%87 = call i32 @atoi(i8* %86)
%88 = icmp eq i32 %87, 0
br i1 %88, label %89, label %113
89: ; preds = %83
%90 = load i8**, i8*** %4
%91 = getelementptr inbounds i8*, i8** %90, i64 2
%92 = load i8*, i8** %91
%93 = call i32 @atoi(i8* %92)
%94 = icmp sgt i32 %93, 36
br i1 %94, label %95, label %98
95: ; preds = %89
%96 = call i32 (...) @gp2x_deinit()
%97 = call i32 @exit(i32 1)
unreachable
98: ; preds = %89
%99 = load i8**, i8*** %4
%100 = getelementptr inbounds i8*, i8** %99, i64 2
%101 = load i8*, i8** %100
%102 = call i32 @atoi(i8* %101)
%103 = icmp slt i32 %102, -20
br i1 %103, label %104, label %107
104: ; preds = %98
%105 = call i32 (...) @gp2x_deinit()
%106 = call i32 @exit(i32 1)
unreachable
107: ; preds = %98
%108 = load i8**, i8*** %4
%109 = getelementptr inbounds i8*, i8** %108, i64 2
%110 = load i8*, i8** %109
%111 = call i32 @atoi(i8* %110)
%112 = call i32 @set_add_FLCDCLK(i32 %111)
br label %137
113: ; preds = %83
%114 = load i8**, i8*** %4
%115 = getelementptr inbounds i8*, i8** %114, i64 2
%116 = load i8*, i8** %115
%117 = call i32 @atoi(i8* %116)
%118 = icmp sgt i32 %117, 10
br i1 %118, label %119, label %122
119: ; preds = %113
%120 = call i32 (...) @gp2x_deinit()
%121 = call i32 @exit(i32 1)
unreachable
122: ; preds = %113
%123 = load i8**, i8*** %4
%124 = getelementptr inbounds i8*, i8** %123, i64 2
%125 = load i8*, i8** %124
%126 = call i32 @atoi(i8* %125)
%127 = icmp slt i32 %126, -5
br i1 %127, label %128, label %131
128: ; preds = %122
%129 = call i32 (...) @gp2x_deinit()
%130 = call i32 @exit(i32 1)
unreachable
131: ; preds = %122
%132 = load i8**, i8*** %4
%133 = getelementptr inbounds i8*, i8** %132, i64 2
%134 = load i8*, i8** %133
%135 = call i32 @atoi(i8* %134)
%136 = call i32 @set_add_ULCDCLK(i32 %135)
br label %137
137: ; preds = %131, %107
%138 = load i8**, i8*** %4
%139 = getelementptr inbounds i8*, i8** %138, i64 3
%140 = load i8*, i8** %139
%141 = call i32 @atoi(i8* %140)
%142 = call i32 @set_FCLK(i32 %141)
br label %143
143: ; preds = %137, %62
%144 = load i32, i32* %3
%145 = icmp eq i32 %144, 5
br i1 %145, label %146, label %247
146: ; preds = %143
%147 = load i8**, i8*** %4
%148 = getelementptr inbounds i8*, i8** %147, i64 3
%149 = load i8*, i8** %148
%150 = call i32 @atoi(i8* %149)
%151 = icmp sgt i32 %150, 320
br i1 %151, label %152, label %155
152: ; preds = %146
%153 = call i32 (...) @gp2x_deinit()
%154 = call i32 @exit(i32 1)
unreachable
155: ; preds = %146
%156 = load i8**, i8*** %4
%157 = getelementptr inbounds i8*, i8** %156, i64 3
%158 = load i8*, i8** %157
%159 = call i32 @atoi(i8* %158)
%160 = icmp slt i32 %159, 33
br i1 %160, label %161, label %164
161: ; preds = %155
%162 = call i32 (...) @gp2x_deinit()
%163 = call i32 @exit(i32 1)
unreachable
164: ; preds = %155
%165 = load i8**, i8*** %4
%166 = getelementptr inbounds i8*, i8** %165, i64 4
%167 = load i8*, i8** %166
%168 = call double @atof(i8* %167)
%169 = fcmp ogt double %168, 1.000000e+01
br i1 %169, label %170, label %173
170: ; preds = %164
%171 = call i32 (...) @gp2x_deinit()
%172 = call i32 @exit(i32 1)
unreachable
173: ; preds = %164
%174 = load i8**, i8*** %4
%175 = getelementptr inbounds i8*, i8** %174, i64 4
%176 = load i8*, i8** %175
%177 = call double @atof(i8* %176)
%178 = fcmp olt double %177, 2.000000e-02
br i1 %178, label %179, label %182
179: ; preds = %173
%180 = call i32 (...) @gp2x_deinit()
%181 = call i32 @exit(i32 1)
unreachable
182: ; preds = %173
%183 = load i8**, i8*** %4
%184 = getelementptr inbounds i8*, i8** %183, i64 1
%185 = load i8*, i8** %184
%186 = call i32 @atoi(i8* %185)
%187 = icmp eq i32 %186, 0
br i1 %187, label %188, label %212
188: ; preds = %182
%189 = load i8**, i8*** %4
%190 = getelementptr inbounds i8*, i8** %189, i64 2
%191 = load i8*, i8** %190
%192 = call i32 @atoi(i8* %191)
%193 = icmp sgt i32 %192, 36
br i1 %193, label %194, label %197
194: ; preds = %188
%195 = call i32 (...) @gp2x_deinit()
%196 = call i32 @exit(i32 1)
unreachable
197: ; preds = %188
%198 = load i8**, i8*** %4
%199 = getelementptr inbounds i8*, i8** %198, i64 2
%200 = load i8*, i8** %199
%201 = call i32 @atoi(i8* %200)
%202 = icmp slt i32 %201, -20
br i1 %202, label %203, label %206
203: ; preds = %197
%204 = call i32 (...) @gp2x_deinit()
%205 = call i32 @exit(i32 1)
unreachable
206: ; preds = %197
%207 = load i8**, i8*** %4
%208 = getelementptr inbounds i8*, i8** %207, i64 2
%209 = load i8*, i8** %208
%210 = call i32 @atoi(i8* %209)
%211 = call i32 @set_add_FLCDCLK(i32 %210)
br label %236
212: ; preds = %182
%213 = load i8**, i8*** %4
%214 = getelementptr inbounds i8*, i8** %213, i64 2
%215 = load i8*, i8** %214
%216 = call i32 @atoi(i8* %215)
%217 = icmp sgt i32 %216, 10
br i1 %217, label %218, label %221
218: ; preds = %212
%219 = call i32 (...) @gp2x_deinit()
%220 = call i32 @exit(i32 1)
unreachable
221: ; preds = %212
%222 = load i8**, i8*** %4
%223 = getelementptr inbounds i8*, i8** %222, i64 2
%224 = load i8*, i8** %223
%225 = call i32 @atoi(i8* %224)
%226 = icmp slt i32 %225, -5
br i1 %226, label %227, label %230
227: ; preds = %221
%228 = call i32 (...) @gp2x_deinit()
%229 = call i32 @exit(i32 1)
unreachable
230: ; preds = %221
%231 = load i8**, i8*** %4
%232 = getelementptr inbounds i8*, i8** %231, i64 2
%233 = load i8*, i8** %232
%234 = call i32 @atoi(i8* %233)
%235 = call i32 @set_add_ULCDCLK(i32 %234)
br label %236
236: ; preds = %230, %206
%237 = load i8**, i8*** %4
%238 = getelementptr inbounds i8*, i8** %237, i64 3
%239 = load i8*, i8** %238
%240 = call i32 @atoi(i8* %239)
%241 = call i32 @set_FCLK(i32 %240)
%242 = load i8**, i8*** %4
%243 = getelementptr inbounds i8*, i8** %242, i64 4
%244 = load i8*, i8** %243
%245 = call double @atof(i8* %244)
%246 = call i32 @set_gamma(double %245)
br label %247
247: ; preds = %236, %143
ret void
}

LLVM IR (-O2):
define void @fallback(i32 %0, i8** nocapture %1) {
switch i32 %0, label %149 [
i32 3, label %3
i32 4, label %35
i32 5, label %84
]
3: ; preds = %2
%4 = getelementptr inbounds i8*, i8** %1, i64 1
%5 = load i8*, i8** %4
%6 = tail call i32 @atoi(i8* %5)
%7 = icmp eq i32 %6, 0
%8 = getelementptr inbounds i8*, i8** %1, i64 2
%9 = load i8*, i8** %8
%10 = tail call i32 @atoi(i8* %9)
br i1 %7, label %11, label %23
11: ; preds = %3
%12 = icmp sgt i32 %10, 36
br i1 %12, label %13, label %16
13: ; preds = %11
%14 = tail call i32 (...) @gp2x_deinit()
%15 = tail call i32 @exit(i32 1)
unreachable
16: ; preds = %11
%17 = icmp slt i32 %10, -20
br i1 %17, label %18, label %21
18: ; preds = %16
%19 = tail call i32 (...) @gp2x_deinit()
%20 = tail call i32 @exit(i32 1)
unreachable
21: ; preds = %16
%22 = tail call i32 @set_add_FLCDCLK(i32 %10)
br label %149
23: ; preds = %3
%24 = icmp sgt i32 %10, 10
br i1 %24, label %25, label %28
25: ; preds = %23
%26 = tail call i32 (...) @gp2x_deinit()
%27 = tail call i32 @exit(i32 1)
unreachable
28: ; preds = %23
%29 = icmp slt i32 %10, -5
br i1 %29, label %30, label %33
30: ; preds = %28
%31 = tail call i32 (...) @gp2x_deinit()
%32 = tail call i32 @exit(i32 1)
unreachable
33: ; preds = %28
%34 = tail call i32 @set_add_ULCDCLK(i32 %10)
br label %149
35: ; preds = %2
%36 = getelementptr inbounds i8*, i8** %1, i64 3
%37 = load i8*, i8** %36
%38 = tail call i32 @atoi(i8* %37)
%39 = icmp sgt i32 %38, 320
br i1 %39, label %40, label %43
40: ; preds = %35
%41 = tail call i32 (...) @gp2x_deinit()
%42 = tail call i32 @exit(i32 1)
unreachable
43: ; preds = %35
%44 = icmp slt i32 %38, 33
br i1 %44, label %45, label %48
45: ; preds = %43
%46 = tail call i32 (...) @gp2x_deinit()
%47 = tail call i32 @exit(i32 1)
unreachable
48: ; preds = %43
%49 = getelementptr inbounds i8*, i8** %1, i64 1
%50 = load i8*, i8** %49
%51 = tail call i32 @atoi(i8* %50)
%52 = icmp eq i32 %51, 0
%53 = getelementptr inbounds i8*, i8** %1, i64 2
%54 = load i8*, i8** %53
%55 = tail call i32 @atoi(i8* %54)
br i1 %52, label %56, label %68
56: ; preds = %48
%57 = icmp sgt i32 %55, 36
br i1 %57, label %58, label %61
58: ; preds = %56
%59 = tail call i32 (...) @gp2x_deinit()
%60 = tail call i32 @exit(i32 1)
unreachable
61: ; preds = %56
%62 = icmp slt i32 %55, -20
br i1 %62, label %63, label %66
63: ; preds = %61
%64 = tail call i32 (...) @gp2x_deinit()
%65 = tail call i32 @exit(i32 1)
unreachable
66: ; preds = %61
%67 = tail call i32 @set_add_FLCDCLK(i32 %55)
br label %80
68: ; preds = %48
%69 = icmp sgt i32 %55, 10
br i1 %69, label %70, label %73
70: ; preds = %68
%71 = tail call i32 (...) @gp2x_deinit()
%72 = tail call i32 @exit(i32 1)
unreachable
73: ; preds = %68
%74 = icmp slt i32 %55, -5
br i1 %74, label %75, label %78
75: ; preds = %73
%76 = tail call i32 (...) @gp2x_deinit()
%77 = tail call i32 @exit(i32 1)
unreachable
78: ; preds = %73
%79 = tail call i32 @set_add_ULCDCLK(i32 %55)
br label %80
80: ; preds = %78, %66
%81 = load i8*, i8** %36
%82 = tail call i32 @atoi(i8* %81)
%83 = tail call i32 @set_FCLK(i32 %82)
br label %149
84: ; preds = %2
%85 = getelementptr inbounds i8*, i8** %1, i64 3
%86 = load i8*, i8** %85
%87 = tail call i32 @atoi(i8* %86)
%88 = icmp sgt i32 %87, 320
br i1 %88, label %89, label %92
89: ; preds = %84
%90 = tail call i32 (...) @gp2x_deinit()
%91 = tail call i32 @exit(i32 1)
unreachable
92: ; preds = %84
%93 = icmp slt i32 %87, 33
br i1 %93, label %94, label %97
94: ; preds = %92
%95 = tail call i32 (...) @gp2x_deinit()
%96 = tail call i32 @exit(i32 1)
unreachable
97: ; preds = %92
%98 = getelementptr inbounds i8*, i8** %1, i64 4
%99 = load i8*, i8** %98
%100 = tail call double @atof(i8* %99)
%101 = fcmp ogt double %100, 1.000000e+01
br i1 %101, label %102, label %105
102: ; preds = %97
%103 = tail call i32 (...) @gp2x_deinit()
%104 = tail call i32 @exit(i32 1)
unreachable
105: ; preds = %97
%106 = fcmp olt double %100, 2.000000e-02
br i1 %106, label %107, label %110
107: ; preds = %105
%108 = tail call i32 (...) @gp2x_deinit()
%109 = tail call i32 @exit(i32 1)
unreachable
110: ; preds = %105
%111 = getelementptr inbounds i8*, i8** %1, i64 1
%112 = load i8*, i8** %111
%113 = tail call i32 @atoi(i8* %112)
%114 = icmp eq i32 %113, 0
%115 = getelementptr inbounds i8*, i8** %1, i64 2
%116 = load i8*, i8** %115
%117 = tail call i32 @atoi(i8* %116)
br i1 %114, label %118, label %130
118: ; preds = %110
%119 = icmp sgt i32 %117, 36
br i1 %119, label %120, label %123
120: ; preds = %118
%121 = tail call i32 (...) @gp2x_deinit()
%122 = tail call i32 @exit(i32 1)
unreachable
123: ; preds = %118
%124 = icmp slt i32 %117, -20
br i1 %124, label %125, label %128
125: ; preds = %123
%126 = tail call i32 (...) @gp2x_deinit()
%127 = tail call i32 @exit(i32 1)
unreachable
128: ; preds = %123
%129 = tail call i32 @set_add_FLCDCLK(i32 %117)
br label %142
130: ; preds = %110
%131 = icmp sgt i32 %117, 10
br i1 %131, label %132, label %135
132: ; preds = %130
%133 = tail call i32 (...) @gp2x_deinit()
%134 = tail call i32 @exit(i32 1)
unreachable
135: ; preds = %130
%136 = icmp slt i32 %117, -5
br i1 %136, label %137, label %140
137: ; preds = %135
%138 = tail call i32 (...) @gp2x_deinit()
%139 = tail call i32 @exit(i32 1)
unreachable
140: ; preds = %135
%141 = tail call i32 @set_add_ULCDCLK(i32 %117)
br label %142
142: ; preds = %140, %128
%143 = load i8*, i8** %85
%144 = tail call i32 @atoi(i8* %143)
%145 = tail call i32 @set_FCLK(i32 %144)
%146 = load i8*, i8** %98
%147 = tail call double @atof(i8* %146)
%148 = tail call i32 @set_gamma(double %147)
br label %149
149: ; preds = %80, %33, %21, %2, %142
ret void
}