#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*/ db_close();
int /*<<< orphan*/ db_init(char *);
int /*<<< orphan*/ exit(int /*<<< orphan*/);
char *get_fakeroot();
int get_pkgid(char *, char *);
char *get_pkgname(char *);
char *get_pkgversion();
int /*<<< orphan*/ install_to_fakeroot(char *);
int /*<<< orphan*/ install_to_root(char *);
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ register_in_db(char *, int);
scalar_t__ strcmp(char *, char *);
int /*<<< orphan*/ unpack(int, char **);
int /*<<< orphan*/ usage();
int main(int argc, char **argv) {
  if (argc < 2) {
    usage();
    exit(0);
  }
  printf("Fakeroot: %s\n", get_fakeroot());
  printf("Package name: %s\n", get_pkgname(argv[2]));
  printf("Package version: %s\n", get_pkgversion());
  db_init("/var/local/ivepkg/ivepkg_db.sqlite3");
  if (strcmp(argv[1], "register") == 0) {
    printf("Register...\n");
    int pkgid = get_pkgid(get_pkgname(NULL), get_pkgversion());
    register_in_db(get_fakeroot(), pkgid);
  } else if (strcmp(argv[1], "fakeroot") == 0) {
    printf("Installing to fakeroot...\n");
    install_to_fakeroot(get_fakeroot());
  } else if (strcmp(argv[1], "root") == 0) {
    printf("Installing to root...\n");
    install_to_root(get_fakeroot());
  } else if (strcmp(argv[1], "install") == 0) {
    printf("Installing...\n");
    char *fakeroot = get_fakeroot();
    install_to_fakeroot(fakeroot);
    int pkgid = get_pkgid(get_pkgname(NULL), get_pkgversion());
    register_in_db(fakeroot, pkgid);
    install_to_root(fakeroot);
  } else if (strcmp(argv[1], "unpack") == 0) {
    printf("Unpacking...\n");
    if (argc < 3) {
      usage();
      exit(0);
    }
    unpack(argc, argv);
  } else
    usage();
  db_close();
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpl   $0x2,-0x8(%rbp)
jge    120e <main+0x2e>
mov    $0x0,%al
call   10d0 <usage@plt>
xor    %edi,%edi
call   10f0 <exit@plt>
mov    $0x0,%al
call   10e0 <get_fakeroot@plt>
mov    %rax,%rsi
lea    0xde1(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1070 <get_pkgname@plt>
mov    %rax,%rsi
lea    0xdd1(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
mov    $0x0,%al
call   10c0 <get_pkgversion@plt>
mov    %rax,%rsi
lea    0xdcb(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
lea    0xdd2(%rip),%rdi
call   1040 <db_init@plt>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
lea    0xde2(%rip),%rsi
call   10a0 <strcmp@plt>
cmp    $0x0,%rax
jne    12ce <main+0xee>
lea    0xdd5(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
xor    %eax,%eax
mov    %eax,%edi
call   1070 <get_pkgname@plt>
mov    %rax,-0x30(%rbp)
mov    $0x0,%al
call   10c0 <get_pkgversion@plt>
mov    -0x30(%rbp),%rdi
mov    %rax,%rsi
call   1100 <get_pkgid@plt>
mov    %eax,-0x14(%rbp)
mov    $0x0,%al
call   10e0 <get_fakeroot@plt>
mov    %rax,%rdi
mov    -0x14(%rbp),%esi
call   1090 <register_in_db@plt>
jmp    143b <main+0x25b>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
lea    0xd92(%rip),%rsi
call   10a0 <strcmp@plt>
cmp    $0x0,%rax
jne    130e <main+0x12e>
lea    0xd85(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
mov    $0x0,%al
call   10e0 <get_fakeroot@plt>
mov    %rax,%rdi
call   1030 <install_to_fakeroot@plt>
jmp    1436 <main+0x256>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
lea    0xd56(%rip),%rsi
call   10a0 <strcmp@plt>
cmp    $0x0,%rax
jne    134e <main+0x16e>
lea    0xd60(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
mov    $0x0,%al
call   10e0 <get_fakeroot@plt>
mov    %rax,%rdi
call   10b0 <install_to_root@plt>
jmp    1431 <main+0x251>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
lea    0xd4d(%rip),%rsi
call   10a0 <strcmp@plt>
cmp    $0x0,%rax
jne    13cb <main+0x1eb>
lea    0xd3f(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
mov    $0x0,%al
call   10e0 <get_fakeroot@plt>
mov    %rax,-0x20(%rbp)
mov    -0x20(%rbp),%rdi
call   1030 <install_to_fakeroot@plt>
xor    %eax,%eax
mov    %eax,%edi
call   1070 <get_pkgname@plt>
mov    %rax,-0x38(%rbp)
mov    $0x0,%al
call   10c0 <get_pkgversion@plt>
mov    -0x38(%rbp),%rdi
mov    %rax,%rsi
call   1100 <get_pkgid@plt>
mov    %eax,-0x24(%rbp)
mov    -0x20(%rbp),%rdi
mov    -0x24(%rbp),%esi
call   1090 <register_in_db@plt>
mov    -0x20(%rbp),%rdi
call   10b0 <install_to_root@plt>
jmp    142c <main+0x24c>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
lea    0xce7(%rip),%rsi
call   10a0 <strcmp@plt>
cmp    $0x0,%rax
jne    1420 <main+0x240>
lea    0xcd8(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
cmpl   $0x3,-0x8(%rbp)
jge    140f <main+0x22f>
mov    $0x0,%al
call   10d0 <usage@plt>
xor    %edi,%edi
call   10f0 <exit@plt>
mov    -0x8(%rbp),%edi
mov    -0x10(%rbp),%rsi
call   1080 <unpack@plt>
jmp    1427 <main+0x247>
mov    $0x0,%al
call   10d0 <usage@plt>
jmp    142c <main+0x24c>
jmp    1431 <main+0x251>
jmp    1436 <main+0x256>
jmp    143b <main+0x25b>
mov    $0x0,%al
call   1060 <db_close@plt>
xor    %eax,%eax
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %rbx
push   %rax
cmp    $0x1,%edi
jle    13d2 <main+0x1e2>
mov    %rsi,%rbx
mov    %edi,%ebp
xor    %eax,%eax
call   10f0 <get_fakeroot@plt>
lea    0xdf1(%rip),%rdi
mov    %rax,%rsi
xor    %eax,%eax
call   1060 <printf@plt>
mov    0x10(%rbx),%rdi
call   1080 <get_pkgname@plt>
lea    0xde5(%rip),%rdi
mov    %rax,%rsi
xor    %eax,%eax
call   1060 <printf@plt>
xor    %eax,%eax
call   10d0 <get_pkgversion@plt>
lea    0xddf(%rip),%rdi
mov    %rax,%rsi
xor    %eax,%eax
call   1060 <printf@plt>
lea    0xde3(%rip),%rdi
call   1050 <db_init@plt>
mov    0x8(%rbx),%rdi
lea    0xdf7(%rip),%rsi
call   10b0 <strcmp@plt>
test   %rax,%rax
je     12dc <main+0xec>
mov    0x8(%rbx),%rdi
lea    0xdeb(%rip),%rsi
call   10b0 <strcmp@plt>
test   %rax,%rax
je     131c <main+0x12c>
mov    0x8(%rbx),%rdi
lea    0xdd6(%rip),%rsi
call   10b0 <strcmp@plt>
test   %rax,%rax
je     133c <main+0x14c>
mov    0x8(%rbx),%rdi
lea    0xdc2(%rip),%rsi
call   10b0 <strcmp@plt>
test   %rax,%rax
je     1359 <main+0x169>
mov    0x8(%rbx),%rdi
lea    0xdb1(%rip),%rsi
call   10b0 <strcmp@plt>
test   %rax,%rax
je     13a7 <main+0x1b7>
xor    %eax,%eax
call   10e0 <usage@plt>
jmp    13c2 <main+0x1d2>
lea    0xde2(%rip),%rdi
call   1040 <puts@plt>
xor    %edi,%edi
call   1080 <get_pkgname@plt>
mov    %rax,%rbx
xor    %eax,%eax
call   10d0 <get_pkgversion@plt>
mov    %rbx,%rdi
mov    %rax,%rsi
call   1110 <get_pkgid@plt>
mov    %eax,%ebx
xor    %eax,%eax
call   10f0 <get_fakeroot@plt>
mov    %rax,%rdi
mov    %ebx,%esi
call   10a0 <register_in_db@plt>
jmp    13c2 <main+0x1d2>
lea    0xd88(%rip),%rdi
call   1040 <puts@plt>
xor    %eax,%eax
call   10f0 <get_fakeroot@plt>
mov    %rax,%rdi
call   1030 <install_to_fakeroot@plt>
jmp    13c2 <main+0x1d2>
lea    0xd52(%rip),%rdi
call   1040 <puts@plt>
xor    %eax,%eax
call   10f0 <get_fakeroot@plt>
mov    %rax,%rdi
call   10c0 <install_to_root@plt>
jmp    13c2 <main+0x1d2>
lea    0xd27(%rip),%rdi
call   1040 <puts@plt>
xor    %eax,%eax
call   10f0 <get_fakeroot@plt>
mov    %rax,%rbx
mov    %rax,%rdi
call   1030 <install_to_fakeroot@plt>
xor    %edi,%edi
call   1080 <get_pkgname@plt>
mov    %rax,%rbp
xor    %eax,%eax
call   10d0 <get_pkgversion@plt>
mov    %rbp,%rdi
mov    %rax,%rsi
call   1110 <get_pkgid@plt>
mov    %rbx,%rdi
mov    %eax,%esi
call   10a0 <register_in_db@plt>
mov    %rbx,%rdi
call   10c0 <install_to_root@plt>
jmp    13c2 <main+0x1d2>
lea    0xccc(%rip),%rdi
call   1040 <puts@plt>
cmp    $0x2,%ebp
jbe    13d2 <main+0x1e2>
mov    %ebp,%edi
mov    %rbx,%rsi
call   1090 <unpack@plt>
xor    %eax,%eax
call   1070 <db_close@plt>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret
xor    %eax,%eax
call   10e0 <usage@plt>
xor    %edi,%edi
call   1100 <exit@plt>

LLVM IR (-O0):
@.str = [14 x i8] c"Fakeroot: %s\0A\00"
@.str.1 = [18 x i8] c"Package name: %s\0A\00"
@.str.2 = [21 x i8] c"Package version: %s\0A\00"
@.str.3 = [36 x i8] c"/var/local/ivepkg/ivepkg_db.sqlite3\00"
@.str.4 = [9 x i8] c"register\00"
@.str.5 = [13 x i8] c"Register...\0A\00"
@.str.6 = [9 x i8] c"fakeroot\00"
@.str.7 = [27 x i8] c"Installing to fakeroot...\0A\00"
@.str.8 = [5 x i8] c"root\00"
@.str.9 = [23 x i8] c"Installing to root...\0A\00"
@.str.10 = [8 x i8] c"install\00"
@.str.11 = [15 x i8] c"Installing...\0A\00"
@.str.12 = [7 x i8] c"unpack\00"
@.str.13 = [14 x i8] c"Unpacking...\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
%7 = alloca i8*
%8 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%9 = load i32, i32* %4
%10 = icmp slt i32 %9, 2
br i1 %10, label %11, label %14
11: ; preds = %2
%12 = call i32 (...) @usage()
%13 = call i32 @exit(i32 0)
unreachable
14: ; preds = %2
%15 = call i8* (...) @get_fakeroot()
%16 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0), i8* %15)
%17 = load i8**, i8*** %5
%18 = getelementptr inbounds i8*, i8** %17, i64 2
%19 = load i8*, i8** %18
%20 = call i8* @get_pkgname(i8* %19)
%21 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.1, i64 0, i64 0), i8* %20)
%22 = call i8* (...) @get_pkgversion()
%23 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.2, i64 0, i64 0), i8* %22)
%24 = call i32 @db_init(i8* getelementptr inbounds ([36 x i8], [36 x i8]* @.str.3, i64 0, i64 0))
%25 = load i8**, i8*** %5
%26 = getelementptr inbounds i8*, i8** %25, i64 1
%27 = load i8*, i8** %26
%28 = call i64 @strcmp(i8* %27, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.4, i64 0, i64 0))
%29 = icmp eq i64 %28, 0
br i1 %29, label %30, label %38
30: ; preds = %14
%31 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.5, i64 0, i64 0))
%32 = call i8* @get_pkgname(i8* null)
%33 = call i8* (...) @get_pkgversion()
%34 = call i32 @get_pkgid(i8* %32, i8* %33)
store i32 %34, i32* %6
%35 = call i8* (...) @get_fakeroot()
%36 = load i32, i32* %6
%37 = call i32 @register_in_db(i8* %35, i32 %36)
br label %100
38: ; preds = %14
%39 = load i8**, i8*** %5
%40 = getelementptr inbounds i8*, i8** %39, i64 1
%41 = load i8*, i8** %40
%42 = call i64 @strcmp(i8* %41, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.6, i64 0, i64 0))
%43 = icmp eq i64 %42, 0
br i1 %43, label %44, label %48
44: ; preds = %38
%45 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.7, i64 0, i64 0))
%46 = call i8* (...) @get_fakeroot()
%47 = call i32 @install_to_fakeroot(i8* %46)
br label %99
48: ; preds = %38
%49 = load i8**, i8*** %5
%50 = getelementptr inbounds i8*, i8** %49, i64 1
%51 = load i8*, i8** %50
%52 = call i64 @strcmp(i8* %51, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.8, i64 0, i64 0))
%53 = icmp eq i64 %52, 0
br i1 %53, label %54, label %58
54: ; preds = %48
%55 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.9, i64 0, i64 0))
%56 = call i8* (...) @get_fakeroot()
%57 = call i32 @install_to_root(i8* %56)
br label %98
58: ; preds = %48
%59 = load i8**, i8*** %5
%60 = getelementptr inbounds i8*, i8** %59, i64 1
%61 = load i8*, i8** %60
%62 = call i64 @strcmp(i8* %61, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.10, i64 0, i64 0))
%63 = icmp eq i64 %62, 0
br i1 %63, label %64, label %77
64: ; preds = %58
%65 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.11, i64 0, i64 0))
%66 = call i8* (...) @get_fakeroot()
store i8* %66, i8** %7
%67 = load i8*, i8** %7
%68 = call i32 @install_to_fakeroot(i8* %67)
%69 = call i8* @get_pkgname(i8* null)
%70 = call i8* (...) @get_pkgversion()
%71 = call i32 @get_pkgid(i8* %69, i8* %70)
store i32 %71, i32* %8
%72 = load i8*, i8** %7
%73 = load i32, i32* %8
%74 = call i32 @register_in_db(i8* %72, i32 %73)
%75 = load i8*, i8** %7
%76 = call i32 @install_to_root(i8* %75)
br label %97
77: ; preds = %58
%78 = load i8**, i8*** %5
%79 = getelementptr inbounds i8*, i8** %78, i64 1
%80 = load i8*, i8** %79
%81 = call i64 @strcmp(i8* %80, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.12, i64 0, i64 0))
%82 = icmp eq i64 %81, 0
br i1 %82, label %83, label %94
83: ; preds = %77
%84 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.13, i64 0, i64 0))
%85 = load i32, i32* %4
%86 = icmp slt i32 %85, 3
br i1 %86, label %87, label %90
87: ; preds = %83
%88 = call i32 (...) @usage()
%89 = call i32 @exit(i32 0)
unreachable
90: ; preds = %83
%91 = load i32, i32* %4
%92 = load i8**, i8*** %5
%93 = call i32 @unpack(i32 %91, i8** %92)
br label %96
94: ; preds = %77
%95 = call i32 (...) @usage()
br label %96
96: ; preds = %94, %90
br label %97
97: ; preds = %96, %64
br label %98
98: ; preds = %97, %54
br label %99
99: ; preds = %98, %44
br label %100
100: ; preds = %99, %30
%101 = call i32 (...) @db_close()
ret i32 0
}

LLVM IR (-O2):
@.str = [14 x i8] c"Fakeroot: %s\0A\00"
@.str.1 = [18 x i8] c"Package name: %s\0A\00"
@.str.2 = [21 x i8] c"Package version: %s\0A\00"
@.str.3 = [36 x i8] c"/var/local/ivepkg/ivepkg_db.sqlite3\00"
@.str.4 = [9 x i8] c"register\00"
@.str.6 = [9 x i8] c"fakeroot\00"
@.str.8 = [5 x i8] c"root\00"
@.str.10 = [8 x i8] c"install\00"
@.str.12 = [7 x i8] c"unpack\00"
@str = [13 x i8] c"Unpacking...\00"
@str.14 = [14 x i8] c"Installing...\00"
@str.15 = [22 x i8] c"Installing to root...\00"
@str.16 = [26 x i8] c"Installing to fakeroot...\00"
@str.17 = [12 x i8] c"Register...\00"
define i32 @main(i32 %0, i8** %1) {
%3 = icmp slt i32 %0, 2
br i1 %3, label %4, label %7
4: ; preds = %2
%5 = tail call i32 (...) @usage()
%6 = tail call i32 @exit(i32 0)
unreachable
7: ; preds = %2
%8 = tail call i8* (...) @get_fakeroot()
%9 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0), i8* %8)
%10 = getelementptr inbounds i8*, i8** %1, i64 2
%11 = load i8*, i8** %10
%12 = tail call i8* @get_pkgname(i8* %11)
%13 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @.str.1, i64 0, i64 0), i8* %12)
%14 = tail call i8* (...) @get_pkgversion()
%15 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([21 x i8], [21 x i8]* @.str.2, i64 0, i64 0), i8* %14)
%16 = tail call i32 @db_init(i8* getelementptr inbounds ([36 x i8], [36 x i8]* @.str.3, i64 0, i64 0))
%17 = getelementptr inbounds i8*, i8** %1, i64 1
%18 = load i8*, i8** %17
%19 = tail call i64 @strcmp(i8* %18, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.4, i64 0, i64 0))
%20 = icmp eq i64 %19, 0
br i1 %20, label %21, label %28
21: ; preds = %7
%22 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @str.17, i64 0, i64 0))
%23 = tail call i8* @get_pkgname(i8* null)
%24 = tail call i8* (...) @get_pkgversion()
%25 = tail call i32 @get_pkgid(i8* %23, i8* %24)
%26 = tail call i8* (...) @get_fakeroot()
%27 = tail call i32 @register_in_db(i8* %26, i32 %25)
br label %71
28: ; preds = %7
%29 = load i8*, i8** %17
%30 = tail call i64 @strcmp(i8* %29, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.6, i64 0, i64 0))
%31 = icmp eq i64 %30, 0
br i1 %31, label %32, label %36
32: ; preds = %28
%33 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([26 x i8], [26 x i8]* @str.16, i64 0, i64 0))
%34 = tail call i8* (...) @get_fakeroot()
%35 = tail call i32 @install_to_fakeroot(i8* %34)
br label %71
36: ; preds = %28
%37 = load i8*, i8** %17
%38 = tail call i64 @strcmp(i8* %37, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.8, i64 0, i64 0))
%39 = icmp eq i64 %38, 0
br i1 %39, label %40, label %44
40: ; preds = %36
%41 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([22 x i8], [22 x i8]* @str.15, i64 0, i64 0))
%42 = tail call i8* (...) @get_fakeroot()
%43 = tail call i32 @install_to_root(i8* %42)
br label %71
44: ; preds = %36
%45 = load i8*, i8** %17
%46 = tail call i64 @strcmp(i8* %45, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.10, i64 0, i64 0))
%47 = icmp eq i64 %46, 0
br i1 %47, label %48, label %57
48: ; preds = %44
%49 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([14 x i8], [14 x i8]* @str.14, i64 0, i64 0))
%50 = tail call i8* (...) @get_fakeroot()
%51 = tail call i32 @install_to_fakeroot(i8* %50)
%52 = tail call i8* @get_pkgname(i8* null)
%53 = tail call i8* (...) @get_pkgversion()
%54 = tail call i32 @get_pkgid(i8* %52, i8* %53)
%55 = tail call i32 @register_in_db(i8* %50, i32 %54)
%56 = tail call i32 @install_to_root(i8* %50)
br label %71
57: ; preds = %44
%58 = load i8*, i8** %17
%59 = tail call i64 @strcmp(i8* %58, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.12, i64 0, i64 0))
%60 = icmp eq i64 %59, 0
br i1 %60, label %61, label %69
61: ; preds = %57
%62 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @str, i64 0, i64 0))
%63 = icmp ult i32 %0, 3
br i1 %63, label %64, label %67
64: ; preds = %61
%65 = tail call i32 (...) @usage()
%66 = tail call i32 @exit(i32 0)
unreachable
67: ; preds = %61
%68 = tail call i32 @unpack(i32 %0, i8** %1)
br label %71
69: ; preds = %57
%70 = tail call i32 (...) @usage()
br label %71
71: ; preds = %32, %48, %69, %67, %40, %21
%72 = tail call i32 (...) @db_close()
ret i32 0
}