#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 /*<<< orphan*/ DriveDistance(int, int);
int /*<<< orphan*/ DriveTime(int, int /*<<< orphan*/, int);
int /*<<< orphan*/ allMotorsOff();
int /*<<< orphan*/ clearLCDLine(int);
int /*<<< orphan*/ displayLCDCenteredString(int, char *);
int /*<<< orphan*/ driveDegreesLeft(int, int);
int /*<<< orphan*/ driveDegreesRight(int, int);
int /*<<< orphan*/ pointTurnLeft(int, int);
int /*<<< orphan*/ pointTurnRight(int, int);
int /*<<< orphan*/ setClaw(int);
int /*<<< orphan*/ setLift(int);
int /*<<< orphan*/ wait1Msec(int);
void auton(int field) {
  switch (field) {
  case 1:
    clearLCDLine(1);
    displayLCDCenteredString(1, "BLUE SKY 1");
    setLift(127 / 2.15);
    wait1Msec(1000);
    setLift(0);
    driveDegreesRight(50, 360);
    DriveTime(-10, 0, 150);
    {
      setClaw(-127 / 2.5);
      wait1Msec(500);
      setLift(127 / 1.7);
      wait1Msec(650);
      setLift(0);
      setClaw(-30);
    }
    pointTurnRight(50, 35);
    DriveDistance(-128 / 3, 360 / 2);
    pointTurnRight(127 / 3, 165);
    DriveTime(127 / 3, 0, 1250);
    wait1Msec(750);
    setLift(-127);
    wait1Msec(1000);
    setLift(0);
    setClaw(127 / 3);
    wait1Msec(750);
    setClaw(127 / 6);
    DriveTime(-127 / 4, 0, 750 / 2 + 50);
    break;
  case 2:
    clearLCDLine(1);
    displayLCDCenteredString(1, "BLUE BOX");
    setClaw(-127 / 6);
    DriveDistance(-127 / 4, 90);
    wait1Msec(500);
    DriveDistance(127 / 4, 110);
    setClaw(127 / 3);
    wait1Msec(500);
    setClaw(127 / 6);
    setLift(127);
    wait1Msec(2600);
    setLift(0);
    pointTurnRight(127 / 4, 125);
    DriveTime(127 / 4, 0, 1100);
    setLift(-127 / 2);
    wait1Msec(1000);
    setLift(0);
    setClaw(-127 / 4);
    wait1Msec(500);
    setClaw(0);
    DriveTime(-127 / 4, 0, 750);
    break;
  case 3:
    clearLCDLine(1);
    displayLCDCenteredString(1, "RED SKY");
    setLift(127 / 2.25);
    wait1Msec(1000);
    setLift(0);
    driveDegreesLeft(50, 420);
    DriveTime(127 / 5, 0, 150);
    DriveTime(-10, 0, 150);
    setClaw(-127 / 2.5);
    wait1Msec(500);
    setLift(127 / 1.7);
    wait1Msec(750);
    setLift(0);
    setClaw(-30);
    pointTurnLeft(127 / 2, 40);
    DriveDistance(-128 / 3, 360 / 2);
    pointTurnLeft(127 / 3, 210);
    DriveTime(127 / 3.5, 0, 1250);
    wait1Msec(750);
    setLift(-127);
    wait1Msec(1000);
    setLift(0);
    setClaw(127 / 3);
    wait1Msec(750);
    setClaw(127 / 6);
    DriveTime(-127 / 4, 0, 750 / 2);
    break;
  case 4:
    clearLCDLine(1);
    displayLCDCenteredString(1, "RED BOX");
    setClaw(-127 / 6);
    DriveDistance(-127 / 4, 90);
    wait1Msec(500);
    DriveDistance(127 / 4, 110);
    setClaw(127 / 3);
    wait1Msec(500);
    setClaw(127 / 6);
    setLift(127);
    wait1Msec(2600);
    setLift(0);
    pointTurnLeft(127 / 4, 125);
    DriveTime(127 / 4, 0, 1100);
    setLift(-127 / 2);
    wait1Msec(1000);
    setLift(0);
    setClaw(-127 / 4);
    wait1Msec(500);
    setClaw(0);
    DriveTime(-127 / 4, 0, 750);
    break;
  default:
    clearLCDLine(1);
    displayLCDCenteredString(1, "DEFAULT");
    DriveDistance(127 / 3, 360);
    break;
  }
  allMotorsOff();
}


x86 assembly (clang, -O0):
<auton>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,%ecx
mov    %rcx,-0x10(%rbp)
sub    $0x3,%eax
ja     1635 <auton+0x475>
mov    -0x10(%rbp),%rax
lea    0xe15(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
mov    $0x1,%edi
call   1040 <clearLCDLine@plt>
mov    $0x1,%edi
lea    0xe06(%rip),%rsi
call   10d0 <displayLCDCenteredString@plt>
mov    $0x3b,%edi
call   10a0 <setLift@plt>
mov    $0x3e8,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0x32,%edi
mov    $0x168,%esi
call   10b0 <driveDegreesRight@plt>
mov    $0xfffffff6,%edi
xor    %esi,%esi
mov    $0x96,%edx
call   10e0 <DriveTime@plt>
mov    $0xffffffce,%edi
call   1080 <setClaw@plt>
mov    $0x1f4,%edi
call   1070 <wait1Msec@plt>
mov    $0x4a,%edi
call   10a0 <setLift@plt>
mov    $0x28a,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0xffffffe2,%edi
call   1080 <setClaw@plt>
mov    $0x32,%edi
mov    $0x23,%esi
call   1030 <pointTurnRight@plt>
mov    $0xffffffd6,%edi
mov    $0xb4,%esi
call   1090 <DriveDistance@plt>
mov    $0x2a,%edi
mov    $0xa5,%esi
call   1030 <pointTurnRight@plt>
mov    $0x2a,%edi
xor    %esi,%esi
mov    $0x4e2,%edx
call   10e0 <DriveTime@plt>
mov    $0x2ee,%edi
call   1070 <wait1Msec@plt>
mov    $0xffffff81,%edi
call   10a0 <setLift@plt>
mov    $0x3e8,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0x2a,%edi
call   1080 <setClaw@plt>
mov    $0x2ee,%edi
call   1070 <wait1Msec@plt>
mov    $0x15,%edi
call   1080 <setClaw@plt>
mov    $0xffffffe1,%edi
xor    %esi,%esi
mov    $0x1a9,%edx
call   10e0 <DriveTime@plt>
jmp    165f <auton+0x49f>
mov    $0x1,%edi
call   1040 <clearLCDLine@plt>
mov    $0x1,%edi
lea    0xceb(%rip),%rsi
call   10d0 <displayLCDCenteredString@plt>
mov    $0xffffffeb,%edi
call   1080 <setClaw@plt>
mov    $0xffffffe1,%edi
mov    $0x5a,%esi
call   1090 <DriveDistance@plt>
mov    $0x1f4,%edi
call   1070 <wait1Msec@plt>
mov    $0x1f,%edi
mov    $0x6e,%esi
call   1090 <DriveDistance@plt>
mov    $0x2a,%edi
call   1080 <setClaw@plt>
mov    $0x1f4,%edi
call   1070 <wait1Msec@plt>
mov    $0x15,%edi
call   1080 <setClaw@plt>
mov    $0x7f,%edi
call   10a0 <setLift@plt>
mov    $0xa28,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0x1f,%edi
mov    $0x7d,%esi
call   1030 <pointTurnRight@plt>
mov    $0x1f,%edi
xor    %esi,%esi
mov    $0x44c,%edx
call   10e0 <DriveTime@plt>
mov    $0xffffffc1,%edi
call   10a0 <setLift@plt>
mov    $0x3e8,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0xffffffe1,%edi
call   1080 <setClaw@plt>
mov    $0x1f4,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   1080 <setClaw@plt>
mov    $0xffffffe1,%edi
xor    %esi,%esi
mov    $0x2ee,%edx
call   10e0 <DriveTime@plt>
jmp    165f <auton+0x49f>
mov    $0x1,%edi
call   1040 <clearLCDLine@plt>
mov    $0x1,%edi
lea    0xc02(%rip),%rsi
call   10d0 <displayLCDCenteredString@plt>
mov    $0x38,%edi
call   10a0 <setLift@plt>
mov    $0x3e8,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0x32,%edi
mov    $0x1a4,%esi
call   1050 <driveDegreesLeft@plt>
mov    $0x19,%edi
xor    %esi,%esi
mov    $0x96,%edx
call   10e0 <DriveTime@plt>
mov    $0xfffffff6,%edi
xor    %esi,%esi
mov    $0x96,%edx
call   10e0 <DriveTime@plt>
mov    $0xffffffce,%edi
call   1080 <setClaw@plt>
mov    $0x1f4,%edi
call   1070 <wait1Msec@plt>
mov    $0x4a,%edi
call   10a0 <setLift@plt>
mov    $0x2ee,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0xffffffe2,%edi
call   1080 <setClaw@plt>
mov    $0x3f,%edi
mov    $0x28,%esi
call   10c0 <pointTurnLeft@plt>
mov    $0xffffffd6,%edi
mov    $0xb4,%esi
call   1090 <DriveDistance@plt>
mov    $0x2a,%edi
mov    $0xd2,%esi
call   10c0 <pointTurnLeft@plt>
mov    $0x24,%edi
xor    %esi,%esi
mov    $0x4e2,%edx
call   10e0 <DriveTime@plt>
mov    $0x2ee,%edi
call   1070 <wait1Msec@plt>
mov    $0xffffff81,%edi
call   10a0 <setLift@plt>
mov    $0x3e8,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0x2a,%edi
call   1080 <setClaw@plt>
mov    $0x2ee,%edi
call   1070 <wait1Msec@plt>
mov    $0x15,%edi
call   1080 <setClaw@plt>
mov    $0xffffffe1,%edi
xor    %esi,%esi
mov    $0x177,%edx
call   10e0 <DriveTime@plt>
jmp    165f <auton+0x49f>
mov    $0x1,%edi
call   1040 <clearLCDLine@plt>
mov    $0x1,%edi
lea    0xad3(%rip),%rsi
call   10d0 <displayLCDCenteredString@plt>
mov    $0xffffffeb,%edi
call   1080 <setClaw@plt>
mov    $0xffffffe1,%edi
mov    $0x5a,%esi
call   1090 <DriveDistance@plt>
mov    $0x1f4,%edi
call   1070 <wait1Msec@plt>
mov    $0x1f,%edi
mov    $0x6e,%esi
call   1090 <DriveDistance@plt>
mov    $0x2a,%edi
call   1080 <setClaw@plt>
mov    $0x1f4,%edi
call   1070 <wait1Msec@plt>
mov    $0x15,%edi
call   1080 <setClaw@plt>
mov    $0x7f,%edi
call   10a0 <setLift@plt>
mov    $0xa28,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0x1f,%edi
mov    $0x7d,%esi
call   10c0 <pointTurnLeft@plt>
mov    $0x1f,%edi
xor    %esi,%esi
mov    $0x44c,%edx
call   10e0 <DriveTime@plt>
mov    $0xffffffc1,%edi
call   10a0 <setLift@plt>
mov    $0x3e8,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0xffffffe1,%edi
call   1080 <setClaw@plt>
mov    $0x1f4,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   1080 <setClaw@plt>
mov    $0xffffffe1,%edi
xor    %esi,%esi
mov    $0x2ee,%edx
call   10e0 <DriveTime@plt>
jmp    165f <auton+0x49f>
mov    $0x1,%edi
call   1040 <clearLCDLine@plt>
mov    $0x1,%edi
lea    0x9e9(%rip),%rsi
call   10d0 <displayLCDCenteredString@plt>
mov    $0x2a,%edi
mov    $0x168,%esi
call   1090 <DriveDistance@plt>
mov    $0x0,%al
call   1060 <allMotorsOff@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<auton>:
push   %rax
add    $0xffffffff,%edi
cmp    $0x3,%edi
ja     12fe <auton+0x13e>
lea    0xe2c(%rip),%rax
movslq (%rax,%rdi,4),%rcx
add    %rax,%rcx
jmp    *%rcx
mov    $0x1,%edi
call   1040 <clearLCDLine@plt>
lea    0xe22(%rip),%rsi
mov    $0x1,%edi
call   10d0 <displayLCDCenteredString@plt>
mov    $0x3b,%edi
call   10a0 <setLift@plt>
mov    $0x3e8,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0x32,%edi
mov    $0x168,%esi
call   10b0 <driveDegreesRight@plt>
mov    $0xfffffff6,%edi
xor    %esi,%esi
mov    $0x96,%edx
call   10e0 <DriveTime@plt>
mov    $0xffffffce,%edi
call   1080 <setClaw@plt>
mov    $0x1f4,%edi
call   1070 <wait1Msec@plt>
mov    $0x4a,%edi
call   10a0 <setLift@plt>
mov    $0x28a,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0xffffffe2,%edi
call   1080 <setClaw@plt>
mov    $0x32,%edi
mov    $0x23,%esi
call   1030 <pointTurnRight@plt>
mov    $0xffffffd6,%edi
mov    $0xb4,%esi
call   1090 <DriveDistance@plt>
mov    $0x2a,%edi
mov    $0xa5,%esi
call   1030 <pointTurnRight@plt>
mov    $0x2a,%edi
xor    %esi,%esi
mov    $0x4e2,%edx
call   10e0 <DriveTime@plt>
mov    $0x2ee,%edi
call   1070 <wait1Msec@plt>
mov    $0xffffff81,%edi
call   10a0 <setLift@plt>
mov    $0x3e8,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0x2a,%edi
call   1080 <setClaw@plt>
mov    $0x2ee,%edi
call   1070 <wait1Msec@plt>
mov    $0x15,%edi
call   1080 <setClaw@plt>
mov    $0xffffffe1,%edi
xor    %esi,%esi
mov    $0x1a9,%edx
jmp    15e1 <auton+0x421>
mov    $0x1,%edi
call   1040 <clearLCDLine@plt>
lea    0xd25(%rip),%rsi
mov    $0x1,%edi
call   10d0 <displayLCDCenteredString@plt>
mov    $0x2a,%edi
mov    $0x168,%esi
call   1090 <DriveDistance@plt>
jmp    15e6 <auton+0x426>
mov    $0x1,%edi
call   1040 <clearLCDLine@plt>
lea    0xcdd(%rip),%rsi
mov    $0x1,%edi
call   10d0 <displayLCDCenteredString@plt>
mov    $0xffffffeb,%edi
call   1080 <setClaw@plt>
mov    $0xffffffe1,%edi
mov    $0x5a,%esi
call   1090 <DriveDistance@plt>
mov    $0x1f4,%edi
call   1070 <wait1Msec@plt>
mov    $0x1f,%edi
mov    $0x6e,%esi
call   1090 <DriveDistance@plt>
mov    $0x2a,%edi
call   1080 <setClaw@plt>
mov    $0x1f4,%edi
call   1070 <wait1Msec@plt>
mov    $0x15,%edi
call   1080 <setClaw@plt>
mov    $0x7f,%edi
call   10a0 <setLift@plt>
mov    $0xa28,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0x1f,%edi
mov    $0x7d,%esi
call   1030 <pointTurnRight@plt>
jmp    158e <auton+0x3ce>
mov    $0x1,%edi
call   1040 <clearLCDLine@plt>
lea    0xc4c(%rip),%rsi
mov    $0x1,%edi
call   10d0 <displayLCDCenteredString@plt>
mov    $0x38,%edi
call   10a0 <setLift@plt>
mov    $0x3e8,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0x32,%edi
mov    $0x1a4,%esi
call   1050 <driveDegreesLeft@plt>
mov    $0x19,%edi
xor    %esi,%esi
mov    $0x96,%edx
call   10e0 <DriveTime@plt>
mov    $0xfffffff6,%edi
xor    %esi,%esi
mov    $0x96,%edx
call   10e0 <DriveTime@plt>
mov    $0xffffffce,%edi
call   1080 <setClaw@plt>
mov    $0x1f4,%edi
call   1070 <wait1Msec@plt>
mov    $0x4a,%edi
call   10a0 <setLift@plt>
mov    $0x2ee,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0xffffffe2,%edi
call   1080 <setClaw@plt>
mov    $0x3f,%edi
mov    $0x28,%esi
call   10c0 <pointTurnLeft@plt>
mov    $0xffffffd6,%edi
mov    $0xb4,%esi
call   1090 <DriveDistance@plt>
mov    $0x2a,%edi
mov    $0xd2,%esi
call   10c0 <pointTurnLeft@plt>
mov    $0x24,%edi
xor    %esi,%esi
mov    $0x4e2,%edx
call   10e0 <DriveTime@plt>
mov    $0x2ee,%edi
call   1070 <wait1Msec@plt>
mov    $0xffffff81,%edi
call   10a0 <setLift@plt>
mov    $0x3e8,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0x2a,%edi
call   1080 <setClaw@plt>
mov    $0x2ee,%edi
call   1070 <wait1Msec@plt>
mov    $0x15,%edi
call   1080 <setClaw@plt>
mov    $0xffffffe1,%edi
xor    %esi,%esi
mov    $0x177,%edx
jmp    15e1 <auton+0x421>
mov    $0x1,%edi
call   1040 <clearLCDLine@plt>
lea    0xb22(%rip),%rsi
mov    $0x1,%edi
call   10d0 <displayLCDCenteredString@plt>
mov    $0xffffffeb,%edi
call   1080 <setClaw@plt>
mov    $0xffffffe1,%edi
mov    $0x5a,%esi
call   1090 <DriveDistance@plt>
mov    $0x1f4,%edi
call   1070 <wait1Msec@plt>
mov    $0x1f,%edi
mov    $0x6e,%esi
call   1090 <DriveDistance@plt>
mov    $0x2a,%edi
call   1080 <setClaw@plt>
mov    $0x1f4,%edi
call   1070 <wait1Msec@plt>
mov    $0x15,%edi
call   1080 <setClaw@plt>
mov    $0x7f,%edi
call   10a0 <setLift@plt>
mov    $0xa28,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0x1f,%edi
mov    $0x7d,%esi
call   10c0 <pointTurnLeft@plt>
mov    $0x1f,%edi
xor    %esi,%esi
mov    $0x44c,%edx
call   10e0 <DriveTime@plt>
mov    $0xffffffc1,%edi
call   10a0 <setLift@plt>
mov    $0x3e8,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   10a0 <setLift@plt>
mov    $0xffffffe1,%edi
call   1080 <setClaw@plt>
mov    $0x1f4,%edi
call   1070 <wait1Msec@plt>
xor    %edi,%edi
call   1080 <setClaw@plt>
mov    $0xffffffe1,%edi
xor    %esi,%esi
mov    $0x2ee,%edx
call   10e0 <DriveTime@plt>
xor    %eax,%eax
pop    %rcx
jmp    1060 <allMotorsOff@plt>

LLVM IR (-O0):
@.str = [11 x i8] c"BLUE SKY 1\00"
@.str.1 = [9 x i8] c"BLUE BOX\00"
@.str.2 = [8 x i8] c"RED SKY\00"
@.str.3 = [8 x i8] c"RED BOX\00"
@.str.4 = [8 x i8] c"DEFAULT\00"
define void @auton(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
switch i32 %3, label %101 [
i32 1, label %4
i32 2, label %30
i32 3, label %52
i32 4, label %79
]
4: ; preds = %1
%5 = call i32 @clearLCDLine(i32 1)
%6 = call i32 @displayLCDCenteredString(i32 1, i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0))
%7 = call i32 @setLift(i32 59)
%8 = call i32 @wait1Msec(i32 1000)
%9 = call i32 @setLift(i32 0)
%10 = call i32 @driveDegreesRight(i32 50, i32 360)
%11 = call i32 @DriveTime(i32 -10, i32 0, i32 150)
%12 = call i32 @setClaw(i32 -50)
%13 = call i32 @wait1Msec(i32 500)
%14 = call i32 @setLift(i32 74)
%15 = call i32 @wait1Msec(i32 650)
%16 = call i32 @setLift(i32 0)
%17 = call i32 @setClaw(i32 -30)
%18 = call i32 @pointTurnRight(i32 50, i32 35)
%19 = call i32 @DriveDistance(i32 -42, i32 180)
%20 = call i32 @pointTurnRight(i32 42, i32 165)
%21 = call i32 @DriveTime(i32 42, i32 0, i32 1250)
%22 = call i32 @wait1Msec(i32 750)
%23 = call i32 @setLift(i32 -127)
%24 = call i32 @wait1Msec(i32 1000)
%25 = call i32 @setLift(i32 0)
%26 = call i32 @setClaw(i32 42)
%27 = call i32 @wait1Msec(i32 750)
%28 = call i32 @setClaw(i32 21)
%29 = call i32 @DriveTime(i32 -31, i32 0, i32 425)
br label %105
30: ; preds = %1
%31 = call i32 @clearLCDLine(i32 1)
%32 = call i32 @displayLCDCenteredString(i32 1, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0))
%33 = call i32 @setClaw(i32 -21)
%34 = call i32 @DriveDistance(i32 -31, i32 90)
%35 = call i32 @wait1Msec(i32 500)
%36 = call i32 @DriveDistance(i32 31, i32 110)
%37 = call i32 @setClaw(i32 42)
%38 = call i32 @wait1Msec(i32 500)
%39 = call i32 @setClaw(i32 21)
%40 = call i32 @setLift(i32 127)
%41 = call i32 @wait1Msec(i32 2600)
%42 = call i32 @setLift(i32 0)
%43 = call i32 @pointTurnRight(i32 31, i32 125)
%44 = call i32 @DriveTime(i32 31, i32 0, i32 1100)
%45 = call i32 @setLift(i32 -63)
%46 = call i32 @wait1Msec(i32 1000)
%47 = call i32 @setLift(i32 0)
%48 = call i32 @setClaw(i32 -31)
%49 = call i32 @wait1Msec(i32 500)
%50 = call i32 @setClaw(i32 0)
%51 = call i32 @DriveTime(i32 -31, i32 0, i32 750)
br label %105
52: ; preds = %1
%53 = call i32 @clearLCDLine(i32 1)
%54 = call i32 @displayLCDCenteredString(i32 1, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.2, i64 0, i64 0))
%55 = call i32 @setLift(i32 56)
%56 = call i32 @wait1Msec(i32 1000)
%57 = call i32 @setLift(i32 0)
%58 = call i32 @driveDegreesLeft(i32 50, i32 420)
%59 = call i32 @DriveTime(i32 25, i32 0, i32 150)
%60 = call i32 @DriveTime(i32 -10, i32 0, i32 150)
%61 = call i32 @setClaw(i32 -50)
%62 = call i32 @wait1Msec(i32 500)
%63 = call i32 @setLift(i32 74)
%64 = call i32 @wait1Msec(i32 750)
%65 = call i32 @setLift(i32 0)
%66 = call i32 @setClaw(i32 -30)
%67 = call i32 @pointTurnLeft(i32 63, i32 40)
%68 = call i32 @DriveDistance(i32 -42, i32 180)
%69 = call i32 @pointTurnLeft(i32 42, i32 210)
%70 = call i32 @DriveTime(i32 36, i32 0, i32 1250)
%71 = call i32 @wait1Msec(i32 750)
%72 = call i32 @setLift(i32 -127)
%73 = call i32 @wait1Msec(i32 1000)
%74 = call i32 @setLift(i32 0)
%75 = call i32 @setClaw(i32 42)
%76 = call i32 @wait1Msec(i32 750)
%77 = call i32 @setClaw(i32 21)
%78 = call i32 @DriveTime(i32 -31, i32 0, i32 375)
br label %105
79: ; preds = %1
%80 = call i32 @clearLCDLine(i32 1)
%81 = call i32 @displayLCDCenteredString(i32 1, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.3, i64 0, i64 0))
%82 = call i32 @setClaw(i32 -21)
%83 = call i32 @DriveDistance(i32 -31, i32 90)
%84 = call i32 @wait1Msec(i32 500)
%85 = call i32 @DriveDistance(i32 31, i32 110)
%86 = call i32 @setClaw(i32 42)
%87 = call i32 @wait1Msec(i32 500)
%88 = call i32 @setClaw(i32 21)
%89 = call i32 @setLift(i32 127)
%90 = call i32 @wait1Msec(i32 2600)
%91 = call i32 @setLift(i32 0)
%92 = call i32 @pointTurnLeft(i32 31, i32 125)
%93 = call i32 @DriveTime(i32 31, i32 0, i32 1100)
%94 = call i32 @setLift(i32 -63)
%95 = call i32 @wait1Msec(i32 1000)
%96 = call i32 @setLift(i32 0)
%97 = call i32 @setClaw(i32 -31)
%98 = call i32 @wait1Msec(i32 500)
%99 = call i32 @setClaw(i32 0)
%100 = call i32 @DriveTime(i32 -31, i32 0, i32 750)
br label %105
101: ; preds = %1
%102 = call i32 @clearLCDLine(i32 1)
%103 = call i32 @displayLCDCenteredString(i32 1, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.4, i64 0, i64 0))
%104 = call i32 @DriveDistance(i32 42, i32 360)
br label %105
105: ; preds = %101, %79, %52, %30, %4
%106 = call i32 (...) @allMotorsOff()
ret void
}

LLVM IR (-O2):
@.str = [11 x i8] c"BLUE SKY 1\00"
@.str.1 = [9 x i8] c"BLUE BOX\00"
@.str.2 = [8 x i8] c"RED SKY\00"
@.str.3 = [8 x i8] c"RED BOX\00"
@.str.4 = [8 x i8] c"DEFAULT\00"
define void @auton(i32 %0) {
switch i32 %0, label %99 [
i32 1, label %2
i32 2, label %28
i32 3, label %50
i32 4, label %77
]
2: ; preds = %1
%3 = tail call i32 @clearLCDLine(i32 1)
%4 = tail call i32 @displayLCDCenteredString(i32 1, i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0))
%5 = tail call i32 @setLift(i32 59)
%6 = tail call i32 @wait1Msec(i32 1000)
%7 = tail call i32 @setLift(i32 0)
%8 = tail call i32 @driveDegreesRight(i32 50, i32 360)
%9 = tail call i32 @DriveTime(i32 -10, i32 0, i32 150)
%10 = tail call i32 @setClaw(i32 -50)
%11 = tail call i32 @wait1Msec(i32 500)
%12 = tail call i32 @setLift(i32 74)
%13 = tail call i32 @wait1Msec(i32 650)
%14 = tail call i32 @setLift(i32 0)
%15 = tail call i32 @setClaw(i32 -30)
%16 = tail call i32 @pointTurnRight(i32 50, i32 35)
%17 = tail call i32 @DriveDistance(i32 -42, i32 180)
%18 = tail call i32 @pointTurnRight(i32 42, i32 165)
%19 = tail call i32 @DriveTime(i32 42, i32 0, i32 1250)
%20 = tail call i32 @wait1Msec(i32 750)
%21 = tail call i32 @setLift(i32 -127)
%22 = tail call i32 @wait1Msec(i32 1000)
%23 = tail call i32 @setLift(i32 0)
%24 = tail call i32 @setClaw(i32 42)
%25 = tail call i32 @wait1Msec(i32 750)
%26 = tail call i32 @setClaw(i32 21)
%27 = tail call i32 @DriveTime(i32 -31, i32 0, i32 425)
br label %103
28: ; preds = %1
%29 = tail call i32 @clearLCDLine(i32 1)
%30 = tail call i32 @displayLCDCenteredString(i32 1, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0))
%31 = tail call i32 @setClaw(i32 -21)
%32 = tail call i32 @DriveDistance(i32 -31, i32 90)
%33 = tail call i32 @wait1Msec(i32 500)
%34 = tail call i32 @DriveDistance(i32 31, i32 110)
%35 = tail call i32 @setClaw(i32 42)
%36 = tail call i32 @wait1Msec(i32 500)
%37 = tail call i32 @setClaw(i32 21)
%38 = tail call i32 @setLift(i32 127)
%39 = tail call i32 @wait1Msec(i32 2600)
%40 = tail call i32 @setLift(i32 0)
%41 = tail call i32 @pointTurnRight(i32 31, i32 125)
%42 = tail call i32 @DriveTime(i32 31, i32 0, i32 1100)
%43 = tail call i32 @setLift(i32 -63)
%44 = tail call i32 @wait1Msec(i32 1000)
%45 = tail call i32 @setLift(i32 0)
%46 = tail call i32 @setClaw(i32 -31)
%47 = tail call i32 @wait1Msec(i32 500)
%48 = tail call i32 @setClaw(i32 0)
%49 = tail call i32 @DriveTime(i32 -31, i32 0, i32 750)
br label %103
50: ; preds = %1
%51 = tail call i32 @clearLCDLine(i32 1)
%52 = tail call i32 @displayLCDCenteredString(i32 1, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.2, i64 0, i64 0))
%53 = tail call i32 @setLift(i32 56)
%54 = tail call i32 @wait1Msec(i32 1000)
%55 = tail call i32 @setLift(i32 0)
%56 = tail call i32 @driveDegreesLeft(i32 50, i32 420)
%57 = tail call i32 @DriveTime(i32 25, i32 0, i32 150)
%58 = tail call i32 @DriveTime(i32 -10, i32 0, i32 150)
%59 = tail call i32 @setClaw(i32 -50)
%60 = tail call i32 @wait1Msec(i32 500)
%61 = tail call i32 @setLift(i32 74)
%62 = tail call i32 @wait1Msec(i32 750)
%63 = tail call i32 @setLift(i32 0)
%64 = tail call i32 @setClaw(i32 -30)
%65 = tail call i32 @pointTurnLeft(i32 63, i32 40)
%66 = tail call i32 @DriveDistance(i32 -42, i32 180)
%67 = tail call i32 @pointTurnLeft(i32 42, i32 210)
%68 = tail call i32 @DriveTime(i32 36, i32 0, i32 1250)
%69 = tail call i32 @wait1Msec(i32 750)
%70 = tail call i32 @setLift(i32 -127)
%71 = tail call i32 @wait1Msec(i32 1000)
%72 = tail call i32 @setLift(i32 0)
%73 = tail call i32 @setClaw(i32 42)
%74 = tail call i32 @wait1Msec(i32 750)
%75 = tail call i32 @setClaw(i32 21)
%76 = tail call i32 @DriveTime(i32 -31, i32 0, i32 375)
br label %103
77: ; preds = %1
%78 = tail call i32 @clearLCDLine(i32 1)
%79 = tail call i32 @displayLCDCenteredString(i32 1, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.3, i64 0, i64 0))
%80 = tail call i32 @setClaw(i32 -21)
%81 = tail call i32 @DriveDistance(i32 -31, i32 90)
%82 = tail call i32 @wait1Msec(i32 500)
%83 = tail call i32 @DriveDistance(i32 31, i32 110)
%84 = tail call i32 @setClaw(i32 42)
%85 = tail call i32 @wait1Msec(i32 500)
%86 = tail call i32 @setClaw(i32 21)
%87 = tail call i32 @setLift(i32 127)
%88 = tail call i32 @wait1Msec(i32 2600)
%89 = tail call i32 @setLift(i32 0)
%90 = tail call i32 @pointTurnLeft(i32 31, i32 125)
%91 = tail call i32 @DriveTime(i32 31, i32 0, i32 1100)
%92 = tail call i32 @setLift(i32 -63)
%93 = tail call i32 @wait1Msec(i32 1000)
%94 = tail call i32 @setLift(i32 0)
%95 = tail call i32 @setClaw(i32 -31)
%96 = tail call i32 @wait1Msec(i32 500)
%97 = tail call i32 @setClaw(i32 0)
%98 = tail call i32 @DriveTime(i32 -31, i32 0, i32 750)
br label %103
99: ; preds = %1
%100 = tail call i32 @clearLCDLine(i32 1)
%101 = tail call i32 @displayLCDCenteredString(i32 1, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.4, i64 0, i64 0))
%102 = tail call i32 @DriveDistance(i32 42, i32 360)
br label %103
103: ; preds = %99, %77, %50, %28, %2
%104 = tail call i32 (...) @allMotorsOff()
ret void
}