#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*/ exit(int);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, int);
int /*<<< orphan*/ stderr;
char Int2base(int base) {
  if (base == 1) {
    return 'A';
  } else if (base == 2) {
    return 'C';
  } else if (base == 3) {
    return 'G';
  } else if (base == 4) {
    return 'T';
  } else if (base == 4) {
    return 'U';
  } else if (base == 15) {
    return '+';
  } else {
    fprintf(stderr, "Error in Converting base %d!\n", base);
    exit(1);
    return '\0';
  }
}


x86 assembly (clang, -O0):
<Int2base>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x8(%rbp)
cmpl   $0x1,-0x8(%rbp)
jne    113e <Int2base+0x1e>
movb   $0x41,-0x1(%rbp)
jmp    11bf <Int2base+0x9f>
cmpl   $0x2,-0x8(%rbp)
jne    1151 <Int2base+0x31>
movb   $0x43,-0x1(%rbp)
jmp    11bf <Int2base+0x9f>
cmpl   $0x3,-0x8(%rbp)
jne    1164 <Int2base+0x44>
movb   $0x47,-0x1(%rbp)
jmp    11bf <Int2base+0x9f>
cmpl   $0x4,-0x8(%rbp)
jne    1177 <Int2base+0x57>
movb   $0x54,-0x1(%rbp)
jmp    11bf <Int2base+0x9f>
cmpl   $0x4,-0x8(%rbp)
jne    118a <Int2base+0x6a>
movb   $0x55,-0x1(%rbp)
jmp    11bf <Int2base+0x9f>
cmpl   $0xf,-0x8(%rbp)
jne    119d <Int2base+0x7d>
movb   $0x2b,-0x1(%rbp)
jmp    11bf <Int2base+0x9f>
mov    0x2e3c(%rip),%rax
mov    (%rax),%edi
mov    -0x8(%rbp),%edx
lea    0xe50(%rip),%rsi
call   1030 <fprintf@plt>
mov    $0x1,%edi
call   1040 <exit@plt>
movsbl -0x1(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<Int2base>:
push   %rax
mov    %edi,%edx
lea    -0x1(%rdx),%ecx
cmp    $0xe,%ecx
ja     114d <Int2base+0x2d>
mov    $0x41,%al
lea    0xecc(%rip),%rsi
movslq (%rsi,%rcx,4),%rcx
add    %rsi,%rcx
jmp    *%rcx
mov    $0x43,%al
pop    %rcx
ret
mov    $0x47,%al
pop    %rcx
ret
mov    $0x54,%al
pop    %rcx
ret
mov    $0x2b,%al
pop    %rcx
ret
mov    0x2e8c(%rip),%rax
mov    (%rax),%edi
lea    0xedf(%rip),%rsi
call   1030 <fprintf@plt>
mov    $0x1,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [30 x i8] c"Error in Converting base %d!\0A\00"
define signext i8 @Int2base(i32 %0) {
%2 = alloca i8
%3 = alloca i32
store i32 %0, i32* %3
%4 = load i32, i32* %3
%5 = icmp eq i32 %4, 1
br i1 %5, label %6, label %7
6: ; preds = %1
store i8 65, i8* %2
br label %32
7: ; preds = %1
%8 = load i32, i32* %3
%9 = icmp eq i32 %8, 2
br i1 %9, label %10, label %11
10: ; preds = %7
store i8 67, i8* %2
br label %32
11: ; preds = %7
%12 = load i32, i32* %3
%13 = icmp eq i32 %12, 3
br i1 %13, label %14, label %15
14: ; preds = %11
store i8 71, i8* %2
br label %32
15: ; preds = %11
%16 = load i32, i32* %3
%17 = icmp eq i32 %16, 4
br i1 %17, label %18, label %19
18: ; preds = %15
store i8 84, i8* %2
br label %32
19: ; preds = %15
%20 = load i32, i32* %3
%21 = icmp eq i32 %20, 4
br i1 %21, label %22, label %23
22: ; preds = %19
store i8 85, i8* %2
br label %32
23: ; preds = %19
%24 = load i32, i32* %3
%25 = icmp eq i32 %24, 15
br i1 %25, label %26, label %27
26: ; preds = %23
store i8 43, i8* %2
br label %32
27: ; preds = %23
%28 = load i32, i32* @stderr
%29 = load i32, i32* %3
%30 = call i32 @fprintf(i32 %28, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str, i64 0, i64 0), i32 %29)
%31 = call i32 @exit(i32 1)
unreachable
32: ; preds = %26, %22, %18, %14, %10, %6
%33 = load i8, i8* %2
ret i8 %33
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [30 x i8] c"Error in Converting base %d!\0A\00"
define signext i8 @Int2base(i32 %0) {
switch i32 %0, label %6 [
i32 1, label %10
i32 2, label %2
i32 3, label %3
i32 4, label %4
i32 15, label %5
]
2: ; preds = %1
br label %10
3: ; preds = %1
br label %10
4: ; preds = %1
br label %10
5: ; preds = %1
br label %10
6: ; preds = %1
%7 = load i32, i32* @stderr
%8 = tail call i32 @fprintf(i32 %7, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str, i64 0, i64 0), i32 %0)
%9 = tail call i32 @exit(i32 1)
unreachable
10: ; preds = %1, %5, %4, %3, %2
%11 = phi i8 [ 67, %2 ], [ 71, %3 ], [ 84, %4 ], [ 43, %5 ], [ 65, %1 ]
ret i8 %11
}