#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*/ assert(int);
int completion_exists(char *);
int /*<<< orphan*/ init_completion(char *);
int /*<<< orphan*/ init_completions();
void setup() {
  assert(!completion_exists("help"));
  init_completion("help");
  init_completion("history");
  init_completion("exit");
  assert(completion_exists("history"));
  assert(!completion_exists("alpha.omega"));
  init_completion("alpha.omega");
  init_completion("alpha.zeta");
  init_completion("beta");
  init_completion("gamma");
  init_completion("gamma.al-z3");
  init_completion("gamma.alpha");
  init_completion("gamma.alpha.epsilon[22]");
  init_completion("gamma.alpha.epsilon[20].abc");
  init_completion("gamma.alpha.epsilon[20].def");
  init_completion("gamma.alpha.epsilon[20].gdd");
  init_completion("gamma.alpha.epsilon[20].ddds");
  init_completion("gamma.alpha.epsilon[20].aaa");
  init_completion("gamma.alpha.epsilon[20].vv");
  init_completion("gamma.alpha.epsilon[20].aa");
  init_completion("gamma.alpha.epsilon[20].ee");
  init_completion("gamma.alpha.epsilon[20].tttt");
  init_completion("gamma.alpha.epsilon[21]");
  init_completion("zeta");
  init_completions();
}


x86 assembly (clang, -O0):
<setup>:
push   %rbp
mov    %rsp,%rbp
lea    0xeb5(%rip),%rdi
call   1030 <completion_exists@plt>
cmp    $0x0,%eax
setne  %al
xor    $0xff,%al
and    $0x1,%al
movzbl %al,%edi
call   1040 <assert@plt>
lea    0xe97(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe90(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe8c(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe78(%rip),%rdi
call   1030 <completion_exists@plt>
mov    %eax,%edi
call   1040 <assert@plt>
lea    0xe72(%rip),%rdi
call   1030 <completion_exists@plt>
cmp    $0x0,%eax
setne  %al
xor    $0xff,%al
and    $0x1,%al
movzbl %al,%edi
call   1040 <assert@plt>
lea    0xe54(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe54(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe53(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe4c(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe46(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe46(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe46(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe52(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe62(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe72(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe82(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe93(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xea3(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xeb2(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xec1(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xed0(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xee1(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xd9a(%rip),%rdi
call   1060 <init_completion@plt>
mov    $0x0,%al
call   1050 <init_completions@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<setup>:
push   %rbx
lea    0xeb8(%rip),%rbx
mov    %rbx,%rdi
call   1030 <completion_exists@plt>
xor    %edi,%edi
test   %eax,%eax
sete   %dil
call   1040 <assert@plt>
mov    %rbx,%rdi
call   1060 <init_completion@plt>
lea    0xe99(%rip),%rbx
mov    %rbx,%rdi
call   1060 <init_completion@plt>
lea    0xe92(%rip),%rdi
call   1060 <init_completion@plt>
mov    %rbx,%rdi
call   1030 <completion_exists@plt>
mov    %eax,%edi
call   1040 <assert@plt>
lea    0xe7c(%rip),%rbx
mov    %rbx,%rdi
call   1030 <completion_exists@plt>
xor    %edi,%edi
test   %eax,%eax
sete   %dil
call   1040 <assert@plt>
mov    %rbx,%rdi
call   1060 <init_completion@plt>
lea    0xe64(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe63(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe5c(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe56(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe56(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe56(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe62(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe72(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe82(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xe92(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xea3(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xeb3(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xec2(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xed1(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xee0(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xef1(%rip),%rdi
call   1060 <init_completion@plt>
lea    0xdaa(%rip),%rdi
call   1060 <init_completion@plt>
xor    %eax,%eax
pop    %rbx
jmp    1050 <init_completions@plt>

LLVM IR (-O0):
@.str = [5 x i8] c"help\00"
@.str.1 = [8 x i8] c"history\00"
@.str.2 = [5 x i8] c"exit\00"
@.str.3 = [12 x i8] c"alpha.omega\00"
@.str.4 = [11 x i8] c"alpha.zeta\00"
@.str.5 = [5 x i8] c"beta\00"
@.str.6 = [6 x i8] c"gamma\00"
@.str.7 = [12 x i8] c"gamma.al-z3\00"
@.str.8 = [12 x i8] c"gamma.alpha\00"
@.str.9 = [24 x i8] c"gamma.alpha.epsilon[22]\00"
@.str.10 = [28 x i8] c"gamma.alpha.epsilon[20].abc\00"
@.str.11 = [28 x i8] c"gamma.alpha.epsilon[20].def\00"
@.str.12 = [28 x i8] c"gamma.alpha.epsilon[20].gdd\00"
@.str.13 = [29 x i8] c"gamma.alpha.epsilon[20].ddds\00"
@.str.14 = [28 x i8] c"gamma.alpha.epsilon[20].aaa\00"
@.str.15 = [27 x i8] c"gamma.alpha.epsilon[20].vv\00"
@.str.16 = [27 x i8] c"gamma.alpha.epsilon[20].aa\00"
@.str.17 = [27 x i8] c"gamma.alpha.epsilon[20].ee\00"
@.str.18 = [29 x i8] c"gamma.alpha.epsilon[20].tttt\00"
@.str.19 = [24 x i8] c"gamma.alpha.epsilon[21]\00"
@.str.20 = [5 x i8] c"zeta\00"
define void @setup() {
%1 = call i32 @completion_exists(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%2 = icmp ne i32 %1, 0
%3 = xor i1 %2, true
%4 = zext i1 %3 to i32
%5 = call i32 @assert(i32 %4)
%6 = call i32 @init_completion(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%7 = call i32 @init_completion(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0))
%8 = call i32 @init_completion(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0))
%9 = call i32 @completion_exists(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0))
%10 = call i32 @assert(i32 %9)
%11 = call i32 @completion_exists(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.3, i64 0, i64 0))
%12 = icmp ne i32 %11, 0
%13 = xor i1 %12, true
%14 = zext i1 %13 to i32
%15 = call i32 @assert(i32 %14)
%16 = call i32 @init_completion(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.3, i64 0, i64 0))
%17 = call i32 @init_completion(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.4, i64 0, i64 0))
%18 = call i32 @init_completion(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0))
%19 = call i32 @init_completion(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.6, i64 0, i64 0))
%20 = call i32 @init_completion(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.7, i64 0, i64 0))
%21 = call i32 @init_completion(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.8, i64 0, i64 0))
%22 = call i32 @init_completion(i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.9, i64 0, i64 0))
%23 = call i32 @init_completion(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.10, i64 0, i64 0))
%24 = call i32 @init_completion(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.11, i64 0, i64 0))
%25 = call i32 @init_completion(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.12, i64 0, i64 0))
%26 = call i32 @init_completion(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.13, i64 0, i64 0))
%27 = call i32 @init_completion(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.14, i64 0, i64 0))
%28 = call i32 @init_completion(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.15, i64 0, i64 0))
%29 = call i32 @init_completion(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.16, i64 0, i64 0))
%30 = call i32 @init_completion(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.17, i64 0, i64 0))
%31 = call i32 @init_completion(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.18, i64 0, i64 0))
%32 = call i32 @init_completion(i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.19, i64 0, i64 0))
%33 = call i32 @init_completion(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.20, i64 0, i64 0))
%34 = call i32 (...) @init_completions()
ret void
}

LLVM IR (-O2):
@.str = [5 x i8] c"help\00"
@.str.1 = [8 x i8] c"history\00"
@.str.2 = [5 x i8] c"exit\00"
@.str.3 = [12 x i8] c"alpha.omega\00"
@.str.4 = [11 x i8] c"alpha.zeta\00"
@.str.5 = [5 x i8] c"beta\00"
@.str.6 = [6 x i8] c"gamma\00"
@.str.7 = [12 x i8] c"gamma.al-z3\00"
@.str.8 = [12 x i8] c"gamma.alpha\00"
@.str.9 = [24 x i8] c"gamma.alpha.epsilon[22]\00"
@.str.10 = [28 x i8] c"gamma.alpha.epsilon[20].abc\00"
@.str.11 = [28 x i8] c"gamma.alpha.epsilon[20].def\00"
@.str.12 = [28 x i8] c"gamma.alpha.epsilon[20].gdd\00"
@.str.13 = [29 x i8] c"gamma.alpha.epsilon[20].ddds\00"
@.str.14 = [28 x i8] c"gamma.alpha.epsilon[20].aaa\00"
@.str.15 = [27 x i8] c"gamma.alpha.epsilon[20].vv\00"
@.str.16 = [27 x i8] c"gamma.alpha.epsilon[20].aa\00"
@.str.17 = [27 x i8] c"gamma.alpha.epsilon[20].ee\00"
@.str.18 = [29 x i8] c"gamma.alpha.epsilon[20].tttt\00"
@.str.19 = [24 x i8] c"gamma.alpha.epsilon[21]\00"
@.str.20 = [5 x i8] c"zeta\00"
define void @setup() {
%1 = tail call i32 @completion_exists(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%2 = icmp eq i32 %1, 0
%3 = zext i1 %2 to i32
%4 = tail call i32 @assert(i32 %3)
%5 = tail call i32 @init_completion(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%6 = tail call i32 @init_completion(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0))
%7 = tail call i32 @init_completion(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0))
%8 = tail call i32 @completion_exists(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0))
%9 = tail call i32 @assert(i32 %8)
%10 = tail call i32 @completion_exists(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.3, i64 0, i64 0))
%11 = icmp eq i32 %10, 0
%12 = zext i1 %11 to i32
%13 = tail call i32 @assert(i32 %12)
%14 = tail call i32 @init_completion(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.3, i64 0, i64 0))
%15 = tail call i32 @init_completion(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.4, i64 0, i64 0))
%16 = tail call i32 @init_completion(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0))
%17 = tail call i32 @init_completion(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.6, i64 0, i64 0))
%18 = tail call i32 @init_completion(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.7, i64 0, i64 0))
%19 = tail call i32 @init_completion(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.8, i64 0, i64 0))
%20 = tail call i32 @init_completion(i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.9, i64 0, i64 0))
%21 = tail call i32 @init_completion(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.10, i64 0, i64 0))
%22 = tail call i32 @init_completion(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.11, i64 0, i64 0))
%23 = tail call i32 @init_completion(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.12, i64 0, i64 0))
%24 = tail call i32 @init_completion(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.13, i64 0, i64 0))
%25 = tail call i32 @init_completion(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.14, i64 0, i64 0))
%26 = tail call i32 @init_completion(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.15, i64 0, i64 0))
%27 = tail call i32 @init_completion(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.16, i64 0, i64 0))
%28 = tail call i32 @init_completion(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.17, i64 0, i64 0))
%29 = tail call i32 @init_completion(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.18, i64 0, i64 0))
%30 = tail call i32 @init_completion(i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.19, i64 0, i64 0))
%31 = tail call i32 @init_completion(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.20, i64 0, i64 0))
%32 = tail call i32 (...) @init_completions()
ret void
}