xunge/DecIR huggingface dataset:
/* Variables and functions */
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ usage_command_usagestr(char const *const *,
                                          int /*<<< orphan*/ *, int, int);
void usage(const char *const *usagestr) {
  usage_command_usagestr(usagestr, NULL, 1, 1);
  exit(1);
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
xor    %eax,%eax
mov    %eax,%esi
mov    $0x1,%ecx
mov    %ecx,%edx
call   1030 <usage_command_usagestr@plt>
mov    $0x1,%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<usage>:
push   %rax
xor    %esi,%esi
mov    $0x1,%edx
mov    $0x1,%ecx
call   1030 <usage_command_usagestr@plt>
mov    $0x1,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
define void @usage(i8** %0) {
%2 = alloca i8**
store i8** %0, i8*** %2
%3 = load i8**, i8*** %2
%4 = call i32 @usage_command_usagestr(i8** %3, i32* null, i32 1, i32 1)
%5 = call i32 @exit(i32 1)
unreachable
}

LLVM IR (-O2):
define void @usage(i8** %0) {
%2 = tail call i32 @usage_command_usagestr(i8** %0, i32* null, i32 1, i32 1)
%3 = tail call i32 @exit(i32 1)
unreachable
}
/* Variables and functions */
int recv(int, char *, int, int /*<<< orphan*/);
int w5100_sock_read(int fd, char *buf, int len) {
  return recv(fd, buf, len, 0);
}


x86 assembly (clang, -O0):
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    -0x4(%rbp),%edi
mov    -0x10(%rbp),%rsi
mov    -0x14(%rbp),%edx
xor    %ecx,%ecx
call   1030 <recv@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
xor    %ecx,%ecx
jmp    1030 <recv@plt>

LLVM IR (-O0):
define i32 @w5100_sock_read(i32 %0, i8* %1, i32 %2) {
%4 = alloca i32
%5 = alloca i8*
%6 = alloca i32
store i32 %0, i32* %4
store i8* %1, i8** %5
store i32 %2, i32* %6
%7 = load i32, i32* %4
%8 = load i8*, i8** %5
%9 = load i32, i32* %6
%10 = call i32 @recv(i32 %7, i8* %8, i32 %9, i32 0)
ret i32 %10
}

LLVM IR (-O2):
define i32 @w5100_sock_read(i32 %0, i8* %1, i32 %2) {
%4 = tail call i32 @recv(i32 %0, i8* %1, i32 %2, i32 0)
ret i32 %4
}
/* Type definitions */
struct VariableShare {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ memcpy(void *, void *, unsigned int);
unsigned long rvhash(void *, unsigned int);
unsigned long GetVariableHash(struct VariableShare *vsh, void *ptr,
                              unsigned int size_of_ptr) {
  if (size_of_ptr <= sizeof(unsigned long)) {
    unsigned long stacklong = 0;
    memcpy((void *)&stacklong, ptr, size_of_ptr);
    return stacklong;
  } else {
    return rvhash(ptr, size_of_ptr);
  }
  return 0;
}


x86 assembly (clang, -O0):
<GetVariableHash>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    %edx,-0x1c(%rbp)
mov    -0x1c(%rbp),%eax
cmp    $0x8,%rax
ja     1165 <GetVariableHash+0x45>
movq   $0x0,-0x28(%rbp)
lea    -0x28(%rbp),%rdi
mov    -0x18(%rbp),%rsi
mov    -0x1c(%rbp),%edx
call   1040 <memcpy@plt>
mov    -0x28(%rbp),%rax
mov    %rax,-0x8(%rbp)
jmp    1175 <GetVariableHash+0x55>
mov    -0x18(%rbp),%rdi
mov    -0x1c(%rbp),%esi
call   1030 <rvhash@plt>
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<GetVariableHash>:
cmp    $0x8,%edx
ja     113c <GetVariableHash+0x1c>
push   %rax
movq   $0x0,(%rsp)
mov    %rsp,%rdi
call   1040 <memcpy@plt>
mov    (%rsp),%rax
pop    %rcx
ret
mov    %rsi,%rdi
mov    %edx,%esi
jmp    1030 <rvhash@plt>

LLVM IR (-O0):
%struct.VariableShare = type { i32 }
define i64 @GetVariableHash(%struct.VariableShare* %0, i8* %1, i32 %2) {
%4 = alloca i64
%5 = alloca %struct.VariableShare*
%6 = alloca i8*
%7 = alloca i32
%8 = alloca i64
store %struct.VariableShare* %0, %struct.VariableShare** %5
store i8* %1, i8** %6
store i32 %2, i32* %7
%9 = load i32, i32* %7
%10 = zext i32 %9 to i64
%11 = icmp ule i64 %10, 8
br i1 %11, label %12, label %18
12: ; preds = %3
store i64 0, i64* %8
%13 = bitcast i64* %8 to i8*
%14 = load i8*, i8** %6
%15 = load i32, i32* %7
%16 = call i32 @memcpy(i8* %13, i8* %14, i32 %15)
%17 = load i64, i64* %8
store i64 %17, i64* %4
br label %22
18: ; preds = %3
%19 = load i8*, i8** %6
%20 = load i32, i32* %7
%21 = call i64 @rvhash(i8* %19, i32 %20)
store i64 %21, i64* %4
br label %22
22: ; preds = %18, %12
%23 = load i64, i64* %4
ret i64 %23
}

LLVM IR (-O2):
%struct.VariableShare = type { i32 }
define i64 @GetVariableHash(%struct.VariableShare* nocapture readnone %0, i8* %1, i32 %2) {
%4 = alloca i64
%5 = icmp ult i32 %2, 9
br i1 %5, label %6, label %10
6: ; preds = %3
%7 = bitcast i64* %4 to i8*
store i64 0, i64* %4
%8 = call i32 @memcpy(i8* %7, i8* %1, i32 %2)
%9 = load i64, i64* %4
br label %12
10: ; preds = %3
%11 = tail call i64 @rvhash(i8* %1, i32 %2)
br label %12
12: ; preds = %10, %6
%13 = phi i64 [ %9, %6 ], [ %11, %10 ]
ret i64 %13
}
/* Variables and functions */
int /*<<< orphan*/ gen_gaddag(char *);
int /*<<< orphan*/ printf(char *, char *);
int main(int argc, char **argv) {
  if (argc != 2) {
    printf("usage: %s [argument]\n", argv[0]);
  } else {
    gen_gaddag(argv[1]);
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpl   $0x2,-0x8(%rbp)
je     1158 <main+0x38>
mov    -0x10(%rbp),%rax
mov    (%rax),%rsi
lea    0xeb2(%rip),%rdi
call   1030 <printf@plt>
jmp    1165 <main+0x45>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
call   1040 <gen_gaddag@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
cmp    $0x2,%edi
jne    1131 <main+0x11>
mov    0x8(%rsi),%rdi
call   1040 <gen_gaddag@plt>
jmp    1140 <main+0x20>
mov    (%rsi),%rsi
lea    0xec5(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [22 x i8] c"usage: %s [argument]\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%6 = load i32, i32* %4
%7 = icmp ne i32 %6, 2
br i1 %7, label %8, label %13
8: ; preds = %2
%9 = load i8**, i8*** %5
%10 = getelementptr inbounds i8*, i8** %9, i64 0
%11 = load i8*, i8** %10
%12 = call i32 @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i8* %11)
br label %18
13: ; preds = %2
%14 = load i8**, i8*** %5
%15 = getelementptr inbounds i8*, i8** %14, i64 1
%16 = load i8*, i8** %15
%17 = call i32 @gen_gaddag(i8* %16)
br label %18
18: ; preds = %13, %8
ret i32 0
}

LLVM IR (-O2):
@.str = [22 x i8] c"usage: %s [argument]\0A\00"
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = icmp eq i32 %0, 2
br i1 %3, label %7, label %4
4: ; preds = %2
%5 = load i8*, i8** %1
%6 = tail call i32 @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i8* %5)
br label %11
7: ; preds = %2
%8 = getelementptr inbounds i8*, i8** %1, i64 1
%9 = load i8*, i8** %8
%10 = tail call i32 @gen_gaddag(i8* %9)
br label %11
11: ; preds = %7, %4
ret i32 0
}
void RTNetIPv4AddUDPChecksum(void) {}


x86 assembly (clang, -O0):
<RTNetIPv4AddUDPChecksum>:
push   %rbp
mov    %rsp,%rbp
pop    %rbp
ret

x86 assembly (clang, -O2):
<RTNetIPv4AddUDPChecksum>:
ret

LLVM IR (-O0):
define void @RTNetIPv4AddUDPChecksum() {
ret void
}

LLVM IR (-O2):
define void @RTNetIPv4AddUDPChecksum() {
ret void
}
int prescope_init(void) { return 0; }


x86 assembly (clang, -O0):
<prescope_init>:
push   %rbp
mov    %rsp,%rbp
xor    %eax,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<prescope_init>:
xor    %eax,%eax
ret

LLVM IR (-O0):
define i32 @prescope_init() {
ret i32 0
}

LLVM IR (-O2):
define i32 @prescope_init() {
ret i32 0
}
/* Variables and functions */
int strlen(char *);
int strncmp(char *, char *, int);
int _strncmpend(char *s1, char *s2, int len) {
  return strncmp(s1 + len - strlen(s2), s2, strlen(s2));
}


x86 assembly (clang, -O0):
<_strncmpend>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    -0x8(%rbp),%rax
movslq -0x14(%rbp),%rcx
add    %rcx,%rax
mov    %rax,-0x30(%rbp)
mov    -0x10(%rbp),%rdi
call   1040 <strlen@plt>
mov    %eax,%ecx
mov    -0x30(%rbp),%rax
movslq %ecx,%rdx
xor    %ecx,%ecx
sub    %rdx,%rcx
add    %rcx,%rax
mov    %rax,-0x28(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,-0x20(%rbp)
mov    -0x10(%rbp),%rdi
call   1040 <strlen@plt>
mov    -0x28(%rbp),%rdi
mov    -0x20(%rbp),%rsi
mov    %eax,%edx
call   1030 <strncmp@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<_strncmpend>:
push   %r14
push   %rbx
push   %rax
mov    %rsi,%r14
mov    %rdi,%rbx
movslq %edx,%rax
add    %rax,%rbx
mov    %rsi,%rdi
call   1040 <strlen@plt>
cltq
sub    %rax,%rbx
mov    %r14,%rdi
call   1040 <strlen@plt>
mov    %rbx,%rdi
mov    %r14,%rsi
mov    %eax,%edx
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1030 <strncmp@plt>

LLVM IR (-O0):
define i32 @_strncmpend(i8* %0, i8* %1, i32 %2) {
%4 = alloca i8*
%5 = alloca i8*
%6 = alloca i32
store i8* %0, i8** %4
store i8* %1, i8** %5
store i32 %2, i32* %6
%7 = load i8*, i8** %4
%8 = load i32, i32* %6
%9 = sext i32 %8 to i64
%10 = getelementptr inbounds i8, i8* %7, i64 %9
%11 = load i8*, i8** %5
%12 = call i32 @strlen(i8* %11)
%13 = sext i32 %12 to i64
%14 = sub i64 0, %13
%15 = getelementptr inbounds i8, i8* %10, i64 %14
%16 = load i8*, i8** %5
%17 = load i8*, i8** %5
%18 = call i32 @strlen(i8* %17)
%19 = call i32 @strncmp(i8* %15, i8* %16, i32 %18)
ret i32 %19
}

LLVM IR (-O2):
define i32 @_strncmpend(i8* %0, i8* %1, i32 %2) {
%4 = sext i32 %2 to i64
%5 = getelementptr inbounds i8, i8* %0, i64 %4
%6 = tail call i32 @strlen(i8* %1)
%7 = sext i32 %6 to i64
%8 = sub nsw i64 0, %7
%9 = getelementptr inbounds i8, i8* %5, i64 %8
%10 = tail call i32 @strlen(i8* %1)
%11 = tail call i32 @strncmp(i8* %9, i8* %1, i32 %10)
ret i32 %11
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
void hook_func(void *arg) { printf("hello world\n"); }


x86 assembly (clang, -O0):
<hook_func>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
lea    0xedd(%rip),%rdi
call   1030 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<hook_func>:
lea    0xee9(%rip),%rdi
jmp    1030 <puts@plt>

LLVM IR (-O0):
@.str = [13 x i8] c"hello world\0A\00"
define void @hook_func(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@str = [12 x i8] c"hello world\00"
define void @hook_func(i8* nocapture readnone %0) {
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @str, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ pmu_set_sleep_clk(int);
void pmu_set_sleep_low() { pmu_set_sleep_clk(0x02010101); }


x86 assembly (clang, -O0):
<pmu_set_sleep_low>:
push   %rbp
mov    %rsp,%rbp
mov    $0x2010101,%edi
call   1030 <pmu_set_sleep_clk@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<pmu_set_sleep_low>:
mov    $0x2010101,%edi
jmp    1030 <pmu_set_sleep_clk@plt>

LLVM IR (-O0):
define void @pmu_set_sleep_low() {
%1 = call i32 @pmu_set_sleep_clk(i32 33620225)
ret void
}

LLVM IR (-O2):
define void @pmu_set_sleep_low() {
%1 = tail call i32 @pmu_set_sleep_clk(i32 33620225)
ret void
}
float test_log2f(float x) { return __builtin_log2f(x); }


x86 assembly (clang, -O0):
<test_log2f>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
call   1030 <log2f@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_log2f>:
jmp    1030 <log2f@plt>

LLVM IR (-O0):
define float @test_log2f(float %0) {
%2 = alloca float
store float %0, float* %2
%3 = load float, float* %2
%4 = call float @log2f(float %3)
ret float %4
}

LLVM IR (-O2):
define float @test_log2f(float %0) {
%2 = tail call float @log2f(float %0)
ret float %2
}
/* Variables and functions */
scalar_t__ pow(int, int);
double sqrt(scalar_t__);
int consegue(int r1, int x1, int y1, int r2, int x2, int y2) {
  double hip;
  hip = sqrt(pow(x1 - x2, 2) + pow(y1 - y2, 2));
  return r1 >= r2 + hip;
}


x86 assembly (clang, -O0):
<consegue>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %ecx,-0x10(%rbp)
mov    %r8d,-0x14(%rbp)
mov    %r9d,-0x18(%rbp)
mov    -0x8(%rbp),%edi
sub    -0x14(%rbp),%edi
mov    $0x2,%esi
call   1030 <pow@plt>
mov    %rax,-0x28(%rbp)
mov    -0xc(%rbp),%edi
sub    -0x18(%rbp),%edi
mov    $0x2,%esi
call   1030 <pow@plt>
mov    -0x28(%rbp),%rdi
add    %rax,%rdi
call   1040 <sqrt@plt>
movsd  %xmm0,-0x20(%rbp)
cvtsi2sdl -0x4(%rbp),%xmm0
cvtsi2sdl -0x10(%rbp),%xmm1
addsd  -0x20(%rbp),%xmm1
ucomisd %xmm1,%xmm0
setae  %al
and    $0x1,%al
movzbl %al,%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<consegue>:
push   %rbp
push   %r15
push   %r14
push   %r12
push   %rbx
mov    %r9d,%r12d
mov    %ecx,%r14d
mov    %edx,%ebp
mov    %edi,%r15d
sub    %r8d,%esi
mov    %esi,%edi
mov    $0x2,%esi
call   1030 <pow@plt>
mov    %rax,%rbx
sub    %r12d,%ebp
mov    %ebp,%edi
mov    $0x2,%esi
call   1030 <pow@plt>
add    %rax,%rbx
mov    %rbx,%rdi
call   1040 <sqrt@plt>
cvtsi2sd %r15d,%xmm1
cvtsi2sd %r14d,%xmm2
addsd  %xmm0,%xmm2
xor    %eax,%eax
ucomisd %xmm2,%xmm1
setae  %al
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
define i32 @consegue(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5) {
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
%11 = alloca i32
%12 = alloca i32
%13 = alloca double
store i32 %0, i32* %7
store i32 %1, i32* %8
store i32 %2, i32* %9
store i32 %3, i32* %10
store i32 %4, i32* %11
store i32 %5, i32* %12
%14 = load i32, i32* %8
%15 = load i32, i32* %11
%16 = sub nsw i32 %14, %15
%17 = call i64 @pow(i32 %16, i32 2)
%18 = load i32, i32* %9
%19 = load i32, i32* %12
%20 = sub nsw i32 %18, %19
%21 = call i64 @pow(i32 %20, i32 2)
%22 = add nsw i64 %17, %21
%23 = call double @sqrt(i64 %22)
store double %23, double* %13
%24 = load i32, i32* %7
%25 = sitofp i32 %24 to double
%26 = load i32, i32* %10
%27 = sitofp i32 %26 to double
%28 = load double, double* %13
%29 = fadd double %27, %28
%30 = fcmp oge double %25, %29
%31 = zext i1 %30 to i32
ret i32 %31
}

LLVM IR (-O2):
define i32 @consegue(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5) {
%7 = sub nsw i32 %1, %4
%8 = tail call i64 @pow(i32 %7, i32 2)
%9 = sub nsw i32 %2, %5
%10 = tail call i64 @pow(i32 %9, i32 2)
%11 = add nsw i64 %10, %8
%12 = tail call double @sqrt(i64 %11)
%13 = sitofp i32 %0 to double
%14 = sitofp i32 %3 to double
%15 = fadd double %12, %14
%16 = fcmp ole double %15, %13
%17 = zext i1 %16 to i32
ret i32 %17
}
/* Variables and functions */
int my_put_double_base(double, int, int /*<<< orphan*/);
int my_put_double(double d) { return (my_put_double_base(d, 10, 0)); }


x86 assembly (clang, -O0):
<my_put_double>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movsd  %xmm0,-0x8(%rbp)
movsd  -0x8(%rbp),%xmm0
mov    $0xa,%edi
xor    %esi,%esi
call   1030 <my_put_double_base@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<my_put_double>:
mov    $0xa,%edi
xor    %esi,%esi
jmp    1030 <my_put_double_base@plt>

LLVM IR (-O0):
define i32 @my_put_double(double %0) {
%2 = alloca double
store double %0, double* %2
%3 = load double, double* %2
%4 = call i32 @my_put_double_base(double %3, i32 10, i32 0)
ret i32 %4
}

LLVM IR (-O2):
define i32 @my_put_double(double %0) {
%2 = tail call i32 @my_put_double_base(double %0, i32 10, i32 0)
ret i32 %2
}
__attribute__((no, noclone)) unsigned __int128 t160_2sub(unsigned __int128 y) {
  unsigned __int128 x = (2);
  unsigned __int128 r;
  if (__builtin_sub_overflow(x, y, &r))
    bar();
  return r;
}


x86 assembly (clang, -O0):
<t160_2sub>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
mov    %rdi,-0x20(%rbp)
mov    %rsi,-0x18(%rbp)
mov    -0x20(%rbp),%rax
mov    -0x18(%rbp),%rcx
mov    %rcx,-0x28(%rbp)
mov    %rax,-0x30(%rbp)
movq   $0x0,-0x38(%rbp)
movq   $0x2,-0x40(%rbp)
mov    -0x40(%rbp),%rdx
mov    -0x38(%rbp),%rcx
mov    -0x30(%rbp),%rsi
mov    -0x28(%rbp),%rax
sub    %rsi,%rdx
sbb    %rax,%rcx
setb   %al
mov    %rdx,-0x50(%rbp)
mov    %rcx,-0x48(%rbp)
test   $0x1,%al
jne    116e <t160_2sub+0x5e>
jmp    1175 <t160_2sub+0x65>
mov    $0x0,%al
call   1030 <bar@plt>
mov    -0x50(%rbp),%rax
mov    -0x48(%rbp),%rcx
mov    %rcx,-0x8(%rbp)
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rax
mov    -0x8(%rbp),%rdx
add    $0x50,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<t160_2sub>:
push   %r14
push   %rbx
push   %rax
xor    %r14d,%r14d
mov    $0x2,%ebx
sub    %rdi,%rbx
sbb    %rsi,%r14
jae    112b <t160_2sub+0x1b>
xor    %eax,%eax
call   1030 <bar@plt>
mov    %rbx,%rax
mov    %r14,%rdx
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
define { i64, i64 } @t160_2sub(i64 %0, i64 %1) {
%3 = alloca i128
%4 = alloca i128
%5 = alloca i128
%6 = alloca i128
%7 = alloca i128
%8 = bitcast i128* %4 to { i64, i64 }*
%9 = getelementptr inbounds { i64, i64 }, { i64, i64 }* %8, i32 0, i32 0
store i64 %0, i64* %9
%10 = getelementptr inbounds { i64, i64 }, { i64, i64 }* %8, i32 0, i32 1
store i64 %1, i64* %10
%11 = load i128, i128* %4
store i128 %11, i128* %5
store i128 2, i128* %6
%12 = load i128, i128* %6
%13 = load i128, i128* %5
%14 = call { i128, i1 } @llvm.usub.with.overflow.i128(i128 %12, i128 %13)
%15 = extractvalue { i128, i1 } %14, 1
%16 = extractvalue { i128, i1 } %14, 0
store i128 %16, i128* %7
br i1 %15, label %17, label %19
17: ; preds = %2
%18 = call i32 (...) @bar()
br label %19
19: ; preds = %17, %2
%20 = load i128, i128* %7
store i128 %20, i128* %3
%21 = bitcast i128* %3 to { i64, i64 }*
%22 = load { i64, i64 }, { i64, i64 }* %21
ret { i64, i64 } %22
}

LLVM IR (-O2):
define { i64, i64 } @t160_2sub(i64 %0, i64 %1) {
%3 = zext i64 %1 to i128
%4 = shl nuw i128 %3, 64
%5 = zext i64 %0 to i128
%6 = or i128 %4, %5
%7 = tail call { i128, i1 } @llvm.usub.with.overflow.i128(i128 2, i128 %6)
%8 = extractvalue { i128, i1 } %7, 1
%9 = extractvalue { i128, i1 } %7, 0
br i1 %8, label %10, label %12
10: ; preds = %2
%11 = tail call i32 (...) @bar()
br label %12
12: ; preds = %10, %2
%13 = trunc i128 %9 to i64
%14 = lshr i128 %9, 64
%15 = trunc i128 %14 to i64
%16 = insertvalue { i64, i64 } poison, i64 %13, 0
%17 = insertvalue { i64, i64 } %16, i64 %15, 1
ret { i64, i64 } %17
}
/* Variables and functions */
int /*<<< orphan*/ dotest(int, int);
int main() {
  {
    dotest(5, 80);
    dotest(7, 216);
    dotest(20, 114624);
    dotest(30, 14098308);
  }
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
mov    $0x5,%edi
mov    $0x50,%esi
call   1030 <dotest@plt>
mov    $0x7,%edi
mov    $0xd8,%esi
call   1030 <dotest@plt>
mov    $0x14,%edi
mov    $0x1bfc0,%esi
call   1030 <dotest@plt>
mov    $0x1e,%edi
mov    $0xd71f84,%esi
call   1030 <dotest@plt>
xor    %eax,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
mov    $0x5,%edi
mov    $0x50,%esi
call   1030 <dotest@plt>
mov    $0x7,%edi
mov    $0xd8,%esi
call   1030 <dotest@plt>
mov    $0x14,%edi
mov    $0x1bfc0,%esi
call   1030 <dotest@plt>
mov    $0x1e,%edi
mov    $0xd71f84,%esi
call   1030 <dotest@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @main() {
%1 = call i32 @dotest(i32 5, i32 80)
%2 = call i32 @dotest(i32 7, i32 216)
%3 = call i32 @dotest(i32 20, i32 114624)
%4 = call i32 @dotest(i32 30, i32 14098308)
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 @dotest(i32 5, i32 80)
%2 = tail call i32 @dotest(i32 7, i32 216)
%3 = tail call i32 @dotest(i32 20, i32 114624)
%4 = tail call i32 @dotest(i32 30, i32 14098308)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
void wjout() {
  printf("\n Sorry, you may get the jaguar output by running a jaguar program");
}


x86 assembly (clang, -O0):
<wjout>:
push   %rbp
mov    %rsp,%rbp
lea    0xee5(%rip),%rdi
call   1030 <printf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<wjout>:
lea    0xee9(%rip),%rdi
jmp    1030 <printf@plt>

LLVM IR (-O0):
@.str = [67 x i8] c"\0A Sorry, you may get the jaguar output by running a jaguar program\00"
define void @wjout() {
%1 = call i32 @printf(i8* getelementptr inbounds ([67 x i8], [67 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [67 x i8] c"\0A Sorry, you may get the jaguar output by running a jaguar program\00"
define void @wjout() {
%1 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([67 x i8], [67 x i8]* @.str, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ fputs(char *, int /*<<< orphan*/);
int /*<<< orphan*/ stderr;
void usage(void) {
  fputs(" qcp [-x dataspace] infile [outfile]\n", stderr);
  exit(0);
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
mov    0x2eb5(%rip),%rax
mov    (%rax),%esi
lea    0xecc(%rip),%rdi
call   1030 <fputs@plt>
xor    %edi,%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<usage>:
push   %rax
mov    0x2eb8(%rip),%rax
mov    (%rax),%esi
lea    0xecf(%rip),%rdi
call   1030 <fputs@plt>
xor    %edi,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@.str = [38 x i8] c" qcp [-x dataspace] infile [outfile]\0A\00"
@stderr = global i32 0
define void @usage() {
%1 = load i32, i32* @stderr
%2 = call i32 @fputs(i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str, i64 0, i64 0), i32 %1)
%3 = call i32 @exit(i32 0)
unreachable
}

LLVM IR (-O2):
@.str = [38 x i8] c" qcp [-x dataspace] infile [outfile]\0A\00"
@stderr = global i32 0
define void @usage() {
%1 = load i32, i32* @stderr
%2 = tail call i32 @fputs(i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str, i64 0, i64 0), i32 %1)
%3 = tail call i32 @exit(i32 0)
unreachable
}
/* Variables and functions */
int /*<<< orphan*/ GL_TRIANGLES;
int /*<<< orphan*/ glBegin(int /*<<< orphan*/);
int /*<<< orphan*/ glEnd();
int /*<<< orphan*/ glVertex3f(float, float, float);
void draw_tri(void) {
  glBegin(GL_TRIANGLES);
  glVertex3f(-1.0f, -1.0f, 0.0f);
  glVertex3f(1.0f, -1.0f, 0.0f);
  glVertex3f(0.0f, 1.0f, 0.0f);
  glEnd();
}


x86 assembly (clang, -O0):
<draw_tri>:
push   %rbp
mov    %rsp,%rbp
mov    0x2ea5(%rip),%rax
mov    (%rax),%edi
call   1050 <glBegin@plt>
movss  0xeba(%rip),%xmm1
xorps  %xmm2,%xmm2
movaps %xmm1,%xmm0
call   1030 <glVertex3f@plt>
movss  0xea3(%rip),%xmm0
movss  0xe9f(%rip),%xmm1
xorps  %xmm2,%xmm2
call   1030 <glVertex3f@plt>
xorps  %xmm2,%xmm2
movss  0xe88(%rip),%xmm1
movaps %xmm2,%xmm0
call   1030 <glVertex3f@plt>
mov    $0x0,%al
call   1040 <glEnd@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<draw_tri>:
push   %rax
mov    0x2ea8(%rip),%rax
mov    (%rax),%edi
call   1050 <glBegin@plt>
movss  0xeb9(%rip),%xmm0
xorps  %xmm2,%xmm2
movaps %xmm0,%xmm1
call   1030 <glVertex3f@plt>
movss  0xeaa(%rip),%xmm0
xorps  %xmm2,%xmm2
movss  0xe9b(%rip),%xmm1
call   1030 <glVertex3f@plt>
xorps  %xmm0,%xmm0
xorps  %xmm2,%xmm2
movss  0xe8c(%rip),%xmm1
call   1030 <glVertex3f@plt>
xor    %eax,%eax
pop    %rcx
jmp    1040 <glEnd@plt>

LLVM IR (-O0):
@GL_TRIANGLES = global i32 0
define void @draw_tri() {
%1 = load i32, i32* @GL_TRIANGLES
%2 = call i32 @glBegin(i32 %1)
%3 = call i32 @glVertex3f(float -1.000000e+00, float -1.000000e+00, float 0.000000e+00)
%4 = call i32 @glVertex3f(float 1.000000e+00, float -1.000000e+00, float 0.000000e+00)
%5 = call i32 @glVertex3f(float 0.000000e+00, float 1.000000e+00, float 0.000000e+00)
%6 = call i32 (...) @glEnd()
ret void
}

LLVM IR (-O2):
@GL_TRIANGLES = global i32 0
define void @draw_tri() {
%1 = load i32, i32* @GL_TRIANGLES
%2 = tail call i32 @glBegin(i32 %1)
%3 = tail call i32 @glVertex3f(float -1.000000e+00, float -1.000000e+00, float 0.000000e+00)
%4 = tail call i32 @glVertex3f(float 1.000000e+00, float -1.000000e+00, float 0.000000e+00)
%5 = tail call i32 @glVertex3f(float 0.000000e+00, float 1.000000e+00, float 0.000000e+00)
%6 = tail call i32 (...) @glEnd()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ A();
void AA() { A(); }


x86 assembly (clang, -O0):
<AA>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1030 <A@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<AA>:
xor    %eax,%eax
jmp    1030 <A@plt>

LLVM IR (-O0):
define void @AA() {
%1 = call i32 (...) @A()
ret void
}

LLVM IR (-O2):
define void @AA() {
%1 = tail call i32 (...) @A()
ret void
}
int are_equal_int(const void *a, const void *b) {
  return *(int *)a == *(int *)b;
}


x86 assembly (clang, -O0):
<are_equal_int>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%eax
mov    -0x10(%rbp),%rcx
cmp    (%rcx),%eax
sete   %al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<are_equal_int>:
mov    (%rdi),%ecx
xor    %eax,%eax
cmp    (%rsi),%ecx
sete   %al
ret

LLVM IR (-O0):
define i32 @are_equal_int(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
store i8* %0, i8** %3
store i8* %1, i8** %4
%5 = load i8*, i8** %3
%6 = bitcast i8* %5 to i32*
%7 = load i32, i32* %6
%8 = load i8*, i8** %4
%9 = bitcast i8* %8 to i32*
%10 = load i32, i32* %9
%11 = icmp eq i32 %7, %10
%12 = zext i1 %11 to i32
ret i32 %12
}

LLVM IR (-O2):
define i32 @are_equal_int(i8* nocapture %0, i8* nocapture %1) {
%3 = bitcast i8* %0 to i32*
%4 = load i32, i32* %3
%5 = bitcast i8* %1 to i32*
%6 = load i32, i32* %5
%7 = icmp eq i32 %4, %6
%8 = zext i1 %7 to i32
ret i32 %8
}
/* Variables and functions */
int /*<<< orphan*/ get_opt(int, char **);
int /*<<< orphan*/ use_flags();
int main(int argc, char **argv) {
  get_opt(argc, argv);
  use_flags();
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%edi
mov    -0x10(%rbp),%rsi
call   1040 <get_opt@plt>
mov    $0x0,%al
call   1030 <use_flags@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
call   1040 <get_opt@plt>
xor    %eax,%eax
call   1030 <use_flags@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%6 = load i32, i32* %4
%7 = load i8**, i8*** %5
%8 = call i32 @get_opt(i32 %6, i8** %7)
%9 = call i32 (...) @use_flags()
ret i32 0
}

LLVM IR (-O2):
define i32 @main(i32 %0, i8** %1) {
%3 = tail call i32 @get_opt(i32 %0, i8** %1)
%4 = tail call i32 (...) @use_flags()
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *);
int /*<<< orphan*/ stderr;
void usage() {
  fprintf(stderr, "Usage:\traw2c filename<ext>\n"
                  "\tConverts a binary file to C array and header\n"
                  "\tdefault input extension is .bin\n");
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
mov    0x2ec5(%rip),%rax
mov    (%rax),%edi
lea    0xedc(%rip),%rsi
call   1030 <fprintf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<usage>:
mov    0x2ec9(%rip),%rax
mov    (%rax),%edi
lea    0xee0(%rip),%rsi
jmp    1030 <fprintf@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [107 x i8] c"Usage:\09raw2c filename<ext>\0A\09Converts a binary file to C array and header\0A\09default input extension is .bin\0A\00"
define void @usage() {
%1 = load i32, i32* @stderr
%2 = call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([107 x i8], [107 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [107 x i8] c"Usage:\09raw2c filename<ext>\0A\09Converts a binary file to C array and header\0A\09default input extension is .bin\0A\00"
define void @usage() {
%1 = load i32, i32* @stderr
%2 = tail call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([107 x i8], [107 x i8]* @.str, i64 0, i64 0))
ret void
}
int __xstat64(const char *path, struct stat *buf) {
  puts("# ");
  puts(__FUNCTION__);
  puts("()\n");
  delay(100000000);
  (void)(path);
  (void)(buf);
  return -1;
}


x86 assembly (clang, -O0):
<__xstat64>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
lea    0xec9(%rip),%rdi
mov    $0x0,%al
call   1030 <puts@plt>
lea    0xebe(%rip),%rdi
mov    $0x0,%al
call   1030 <puts@plt>
lea    0xeba(%rip),%rdi
mov    $0x0,%al
call   1030 <puts@plt>
mov    $0x5f5e100,%edi
mov    $0x0,%al
call   1040 <delay@plt>
mov    $0xffffffff,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<__xstat64>:
push   %rax
lea    0xed8(%rip),%rdi
xor    %eax,%eax
call   1030 <puts@plt>
lea    0xecd(%rip),%rdi
xor    %eax,%eax
call   1030 <puts@plt>
lea    0xec9(%rip),%rdi
xor    %eax,%eax
call   1030 <puts@plt>
mov    $0x5f5e100,%edi
xor    %eax,%eax
call   1040 <delay@plt>
mov    $0xffffffff,%eax
pop    %rcx
ret

LLVM IR (-O0):
%struct.stat = type opaque
@.str = [3 x i8] c"# \00"
@__FUNCTION__.__xstat64 = [10 x i8] c"__xstat64\00"
@.str.1 = [4 x i8] c"()\0A\00"
define i32 @__xstat64(i8* %0, %struct.stat* %1) {
%3 = alloca i8*
%4 = alloca %struct.stat*
store i8* %0, i8** %3
store %struct.stat* %1, %struct.stat** %4
%5 = call i32 (i8*, ...) bitcast (i32 (...)* @puts to i32 (i8*, ...)*)(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0))
%6 = call i32 (i8*, ...) bitcast (i32 (...)* @puts to i32 (i8*, ...)*)(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @__FUNCTION__.__xstat64, i64 0, i64 0))
%7 = call i32 (i8*, ...) bitcast (i32 (...)* @puts to i32 (i8*, ...)*)(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0))
%8 = call i32 (i32, ...) bitcast (i32 (...)* @delay to i32 (i32, ...)*)(i32 100000000)
%9 = load i8*, i8** %3
%10 = load %struct.stat*, %struct.stat** %4
ret i32 -1
}

LLVM IR (-O2):
%struct.stat = type opaque
@.str = [3 x i8] c"# \00"
@__FUNCTION__.__xstat64 = [10 x i8] c"__xstat64\00"
@.str.1 = [4 x i8] c"()\0A\00"
define i32 @__xstat64(i8* nocapture readnone %0, %struct.stat* nocapture readnone %1) {
%3 = tail call i32 (i8*, ...) bitcast (i32 (...)* @puts to i32 (i8*, ...)*)(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0))
%4 = tail call i32 (i8*, ...) bitcast (i32 (...)* @puts to i32 (i8*, ...)*)(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @__FUNCTION__.__xstat64, i64 0, i64 0))
%5 = tail call i32 (i8*, ...) bitcast (i32 (...)* @puts to i32 (i8*, ...)*)(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0))
%6 = tail call i32 (i32, ...) bitcast (i32 (...)* @delay to i32 (i32, ...)*)(i32 100000000)
ret i32 -1
}
void deposer(int message) {}


x86 assembly (clang, -O0):
<deposer>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
pop    %rbp
ret

x86 assembly (clang, -O2):
<deposer>:
ret

LLVM IR (-O0):
define void @deposer(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
ret void
}

LLVM IR (-O2):
define void @deposer(i32 %0) {
ret void
}
/* Type definitions */
struct stree {
  int dummy;
};

/* Variables and functions */
struct stree *kTstree_new_tree(int, int, int);
struct stree *stree_new_tree(int number_of_strings, int alphabet_size) {
  return kTstree_new_tree(number_of_strings, alphabet_size, -1);
}


x86 assembly (clang, -O0):
<stree_new_tree>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x4(%rbp),%edi
mov    -0x8(%rbp),%esi
mov    $0xffffffff,%edx
call   1030 <kTstree_new_tree@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<stree_new_tree>:
mov    $0xffffffff,%edx
jmp    1030 <kTstree_new_tree@plt>

LLVM IR (-O0):
%struct.stree = type { i32 }
define %struct.stree* @stree_new_tree(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
store i32 %0, i32* %3
store i32 %1, i32* %4
%5 = load i32, i32* %3
%6 = load i32, i32* %4
%7 = call %struct.stree* @kTstree_new_tree(i32 %5, i32 %6, i32 -1)
ret %struct.stree* %7
}

LLVM IR (-O2):
%struct.stree = type { i32 }
define %struct.stree* @stree_new_tree(i32 %0, i32 %1) {
%3 = tail call %struct.stree* @kTstree_new_tree(i32 %0, i32 %1, i32 -1)
ret %struct.stree* %3
}
int main(void) {
  int a = 1 + 2 * 3;
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
movl   $0x0,-0x4(%rbp)
movl   $0x7,-0x8(%rbp)
xor    %eax,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
xor    %eax,%eax
ret

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
store i32 0, i32* %1
store i32 7, i32* %2
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ ENOMEM;
scalar_t__ WOMallocShouldFail();
void *calloc(size_t, size_t);
int /*<<< orphan*/ errno;
void *WOCalloc(size_t count, size_t size) {
  if (WOMallocShouldFail()) {
    errno = ENOMEM;
    return NULL;
  }
  return calloc(count, size);
}


x86 assembly (clang, -O0):
<WOCalloc>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    $0x0,%al
call   1030 <WOMallocShouldFail@plt>
cmp    $0x0,%rax
je     1160 <WOCalloc+0x40>
mov    0x2e98(%rip),%rax
mov    (%rax),%ecx
mov    0x2e87(%rip),%rax
mov    %ecx,(%rax)
movq   $0x0,-0x8(%rbp)
jmp    1171 <WOCalloc+0x51>
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
call   1040 <calloc@plt>
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<WOCalloc>:
push   %r14
push   %rbx
push   %rax
mov    %rsi,%r14
mov    %rdi,%rbx
xor    %eax,%eax
call   1030 <WOMallocShouldFail@plt>
test   %rax,%rax
je     1152 <WOCalloc+0x32>
mov    0x2ea3(%rip),%rax
mov    (%rax),%eax
mov    0x2e92(%rip),%rcx
mov    %eax,(%rcx)
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret
mov    %rbx,%rdi
mov    %r14,%rsi
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1040 <calloc@plt>

LLVM IR (-O0):
@ENOMEM = global i32 0
@errno = global i32 0
define i8* @WOCalloc(i64 %0, i64 %1) {
%3 = alloca i8*
%4 = alloca i64
%5 = alloca i64
store i64 %0, i64* %4
store i64 %1, i64* %5
%6 = call i64 (...) @WOMallocShouldFail()
%7 = icmp ne i64 %6, 0
br i1 %7, label %8, label %10
8: ; preds = %2
%9 = load i32, i32* @ENOMEM
store i32 %9, i32* @errno
store i8* null, i8** %3
br label %14
10: ; preds = %2
%11 = load i64, i64* %4
%12 = load i64, i64* %5
%13 = call i8* @calloc(i64 %11, i64 %12)
store i8* %13, i8** %3
br label %14
14: ; preds = %10, %8
%15 = load i8*, i8** %3
ret i8* %15
}

LLVM IR (-O2):
@ENOMEM = global i32 0
@errno = global i32 0
define noalias i8* @WOCalloc(i64 %0, i64 %1) {
%3 = tail call i64 (...) @WOMallocShouldFail()
%4 = icmp eq i64 %3, 0
br i1 %4, label %7, label %5
5: ; preds = %2
%6 = load i32, i32* @ENOMEM
store i32 %6, i32* @errno
br label %9
7: ; preds = %2
%8 = tail call i8* @calloc(i64 %0, i64 %1)
br label %9
9: ; preds = %7, %5
%10 = phi i8* [ null, %5 ], [ %8, %7 ]
ret i8* %10
}
/* Variables and functions */
long CommandInitialize(unsigned long);
int /*<<< orphan*/ McDevIf_AddPacket(int, int /*<<< orphan*/);
long McDevIf_ExecutePacket();
signed long InitializeOS(void) {
  signed long sdRet;
  sdRet = CommandInitialize((0UL));
  if (((signed long)0) == sdRet) {
    sdRet = CommandInitialize((1UL));
    if (((signed long)0) == sdRet) {
      McDevIf_AddPacket(((0x40000000UL) | (0x000F0000UL) |
                         (((unsigned long)(112)) << 8) | (unsigned long)(0x80)),
                        0);
      sdRet = McDevIf_ExecutePacket();
    }
  }
  return sdRet;
}


x86 assembly (clang, -O0):
<InitializeOS>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
xor    %eax,%eax
mov    %eax,%edi
call   1050 <CommandInitialize@plt>
mov    %rax,-0x8(%rbp)
xor    %eax,%eax
cmp    -0x8(%rbp),%rax
jne    1187 <InitializeOS+0x57>
mov    $0x1,%edi
call   1050 <CommandInitialize@plt>
mov    %rax,-0x8(%rbp)
xor    %eax,%eax
cmp    -0x8(%rbp),%rax
jne    1182 <InitializeOS+0x52>
mov    $0x400f7080,%edi
xor    %esi,%esi
call   1040 <McDevIf_AddPacket@plt>
mov    $0x0,%al
call   1030 <McDevIf_ExecutePacket@plt>
mov    %rax,-0x8(%rbp)
jmp    1187 <InitializeOS+0x57>
mov    -0x8(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<InitializeOS>:
push   %rax
xor    %edi,%edi
call   1050 <CommandInitialize@plt>
test   %rax,%rax
jne    114c <InitializeOS+0x1c>
mov    $0x1,%edi
call   1050 <CommandInitialize@plt>
test   %rax,%rax
je     114e <InitializeOS+0x1e>
pop    %rcx
ret
mov    $0x400f7080,%edi
xor    %esi,%esi
call   1040 <McDevIf_AddPacket@plt>
xor    %eax,%eax
pop    %rcx
jmp    1030 <McDevIf_ExecutePacket@plt>

LLVM IR (-O0):
define i64 @InitializeOS() {
%1 = alloca i64
%2 = call i64 @CommandInitialize(i64 0)
store i64 %2, i64* %1
%3 = load i64, i64* %1
%4 = icmp eq i64 0, %3
br i1 %4, label %5, label %13
5: ; preds = %0
%6 = call i64 @CommandInitialize(i64 1)
store i64 %6, i64* %1
%7 = load i64, i64* %1
%8 = icmp eq i64 0, %7
br i1 %8, label %9, label %12
9: ; preds = %5
%10 = call i32 @McDevIf_AddPacket(i32 1074753664, i32 0)
%11 = call i64 (...) @McDevIf_ExecutePacket()
store i64 %11, i64* %1
br label %12
12: ; preds = %9, %5
br label %13
13: ; preds = %12, %0
%14 = load i64, i64* %1
ret i64 %14
}

LLVM IR (-O2):
define i64 @InitializeOS() {
%1 = tail call i64 @CommandInitialize(i64 0)
%2 = icmp eq i64 %1, 0
br i1 %2, label %3, label %9
3: ; preds = %0
%4 = tail call i64 @CommandInitialize(i64 1)
%5 = icmp eq i64 %4, 0
br i1 %5, label %6, label %9
6: ; preds = %3
%7 = tail call i32 @McDevIf_AddPacket(i32 1074753664, i32 0)
%8 = tail call i64 (...) @McDevIf_ExecutePacket()
br label %9
9: ; preds = %3, %6, %0
%10 = phi i64 [ %8, %6 ], [ %4, %3 ], [ %1, %0 ]
ret i64 %10
}
void oorb(void) {}


x86 assembly (clang, -O0):
<oorb>:
push   %rbp
mov    %rsp,%rbp
pop    %rbp
ret

x86 assembly (clang, -O2):
<oorb>:
ret

LLVM IR (-O0):
define void @oorb() {
ret void
}

LLVM IR (-O2):
define void @oorb() {
ret void
}
/* Variables and functions */
double fmod(double, double);
double c_fmod(double arg0, double arg1) { return fmod(arg0, arg1); }


x86 assembly (clang, -O0):
<c_fmod>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
movsd  -0x8(%rbp),%xmm0
movsd  -0x10(%rbp),%xmm1
call   1030 <fmod@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<c_fmod>:
jmp    1030 <fmod@plt>

LLVM IR (-O0):
define double @c_fmod(double %0, double %1) {
%3 = alloca double
%4 = alloca double
store double %0, double* %3
store double %1, double* %4
%5 = load double, double* %3
%6 = load double, double* %4
%7 = call double @fmod(double %5, double %6)
ret double %7
}

LLVM IR (-O2):
define double @c_fmod(double %0, double %1) {
%3 = tail call double @fmod(double %0, double %1)
ret double %3
}
/* Type definitions */
struct hostent {
  int dummy;
};

/* Variables and functions */
int file_lookup(char const *, struct hostent **);
int hostfile_lookup(const char *name, struct hostent **host) {
  return file_lookup(name, host);
}


x86 assembly (clang, -O0):
<hostfile_lookup>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1030 <file_lookup@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<hostfile_lookup>:
jmp    1030 <file_lookup@plt>

LLVM IR (-O0):
%struct.hostent = type { i32 }
define i32 @hostfile_lookup(i8* %0, %struct.hostent** %1) {
%3 = alloca i8*
%4 = alloca %struct.hostent**
store i8* %0, i8** %3
store %struct.hostent** %1, %struct.hostent*** %4
%5 = load i8*, i8** %3
%6 = load %struct.hostent**, %struct.hostent*** %4
%7 = call i32 @file_lookup(i8* %5, %struct.hostent** %6)
ret i32 %7
}

LLVM IR (-O2):
%struct.hostent = type { i32 }
define i32 @hostfile_lookup(i8* %0, %struct.hostent** %1) {
%3 = tail call i32 @file_lookup(i8* %0, %struct.hostent** %1)
ret i32 %3
}
void g_param_spec_pool_remove() {}


x86 assembly (clang, -O0):
<g_param_spec_pool_remove>:
push   %rbp
mov    %rsp,%rbp
pop    %rbp
ret

x86 assembly (clang, -O2):
<g_param_spec_pool_remove>:
ret

LLVM IR (-O0):
define void @g_param_spec_pool_remove() {
ret void
}

LLVM IR (-O2):
define void @g_param_spec_pool_remove() {
ret void
}
int *vmaior(int *valor1, int *valor2) {
  if (*valor1 >= *valor2) {
    return valor1;
  } else {
    return valor2;
  }
}


x86 assembly (clang, -O0):
<vmaior>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    -0x10(%rbp),%rax
mov    (%rax),%eax
mov    -0x18(%rbp),%rcx
cmp    (%rcx),%eax
jl     112b <vmaior+0x2b>
mov    -0x10(%rbp),%rax
mov    %rax,-0x8(%rbp)
jmp    1133 <vmaior+0x33>
mov    -0x18(%rbp),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<vmaior>:
mov    %rdi,%rax
mov    (%rdi),%ecx
cmp    (%rsi),%ecx
cmovl  %rsi,%rax
ret

LLVM IR (-O0):
define i32* @vmaior(i32* %0, i32* %1) {
%3 = alloca i32*
%4 = alloca i32*
%5 = alloca i32*
store i32* %0, i32** %4
store i32* %1, i32** %5
%6 = load i32*, i32** %4
%7 = load i32, i32* %6
%8 = load i32*, i32** %5
%9 = load i32, i32* %8
%10 = icmp sge i32 %7, %9
br i1 %10, label %11, label %13
11: ; preds = %2
%12 = load i32*, i32** %4
store i32* %12, i32** %3
br label %15
13: ; preds = %2
%14 = load i32*, i32** %5
store i32* %14, i32** %3
br label %15
15: ; preds = %13, %11
%16 = load i32*, i32** %3
ret i32* %16
}

LLVM IR (-O2):
define i32* @vmaior(i32* %0, i32* %1) {
%3 = load i32, i32* %0
%4 = load i32, i32* %1
%5 = icmp slt i32 %3, %4
%6 = select i1 %5, i32* %1, i32* %0
ret i32* %6
}
double vector_dot_3d(const double v1[3], const double v2[3]) {
  return v1[0] * v2[0] + v1[1] * v2[1] + v1[2] * v2[2];
}


x86 assembly (clang, -O0):
<vector_dot_3d>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
movsd  (%rax),%xmm1
mov    -0x10(%rbp),%rax
movsd  (%rax),%xmm2
mov    -0x8(%rbp),%rax
movsd  0x8(%rax),%xmm0
mov    -0x10(%rbp),%rax
mulsd  0x8(%rax),%xmm0
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
mov    -0x8(%rbp),%rax
movsd  0x10(%rax),%xmm0
mov    -0x10(%rbp),%rax
movsd  0x10(%rax),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<vector_dot_3d>:
movsd  0x8(%rdi),%xmm0
mulsd  0x8(%rsi),%xmm0
movsd  (%rdi),%xmm1
mulsd  (%rsi),%xmm1
addsd  %xmm0,%xmm1
movsd  0x10(%rdi),%xmm0
mulsd  0x10(%rsi),%xmm0
addsd  %xmm1,%xmm0
ret

LLVM IR (-O0):
define double @vector_dot_3d(double* %0, double* %1) {
%3 = alloca double*
%4 = alloca double*
store double* %0, double** %3
store double* %1, double** %4
%5 = load double*, double** %3
%6 = getelementptr inbounds double, double* %5, i64 0
%7 = load double, double* %6
%8 = load double*, double** %4
%9 = getelementptr inbounds double, double* %8, i64 0
%10 = load double, double* %9
%11 = load double*, double** %3
%12 = getelementptr inbounds double, double* %11, i64 1
%13 = load double, double* %12
%14 = load double*, double** %4
%15 = getelementptr inbounds double, double* %14, i64 1
%16 = load double, double* %15
%17 = fmul double %13, %16
%18 = call double @llvm.fmuladd.f64(double %7, double %10, double %17)
%19 = load double*, double** %3
%20 = getelementptr inbounds double, double* %19, i64 2
%21 = load double, double* %20
%22 = load double*, double** %4
%23 = getelementptr inbounds double, double* %22, i64 2
%24 = load double, double* %23
%25 = call double @llvm.fmuladd.f64(double %21, double %24, double %18)
ret double %25
}

LLVM IR (-O2):
define double @vector_dot_3d(double* nocapture %0, double* nocapture %1) {
%3 = load double, double* %0
%4 = load double, double* %1
%5 = getelementptr inbounds double, double* %0, i64 1
%6 = load double, double* %5
%7 = getelementptr inbounds double, double* %1, i64 1
%8 = load double, double* %7
%9 = fmul double %6, %8
%10 = tail call double @llvm.fmuladd.f64(double %3, double %4, double %9)
%11 = getelementptr inbounds double, double* %0, i64 2
%12 = load double, double* %11
%13 = getelementptr inbounds double, double* %1, i64 2
%14 = load double, double* %13
%15 = tail call double @llvm.fmuladd.f64(double %12, double %14, double %10)
ret double %15
}
/* Type definitions */
struct lwan_strbuf {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ lwan_strbuf_free(struct lwan_strbuf *);
void lwan_strbuf_free_defer(void *data) {
  lwan_strbuf_free((struct lwan_strbuf *)data);
}


x86 assembly (clang, -O0):
<lwan_strbuf_free_defer>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <lwan_strbuf_free@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<lwan_strbuf_free_defer>:
jmp    1030 <lwan_strbuf_free@plt>

LLVM IR (-O0):
%struct.lwan_strbuf = type { i32 }
define void @lwan_strbuf_free_defer(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = bitcast i8* %3 to %struct.lwan_strbuf*
%5 = call i32 @lwan_strbuf_free(%struct.lwan_strbuf* %4)
ret void
}

LLVM IR (-O2):
%struct.lwan_strbuf = type { i32 }
define void @lwan_strbuf_free_defer(i8* %0) {
%2 = bitcast i8* %0 to %struct.lwan_strbuf*
%3 = tail call i32 @lwan_strbuf_free(%struct.lwan_strbuf* %2)
ret void
}
/* Variables and functions */
void *Heap_REGMOD(unsigned char *, int /*<<< orphan*/);
void *Strings__init(void) {
  static void *m;
  if (m != 0) {
    return m;
  };
  if (m == 0) {
    m = Heap_REGMOD((unsigned char *)"Strings", 0);
  };
  return m;
}


x86 assembly (clang, -O0):
<Strings__init>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
cmpq   $0x0,0x2f10(%rip)
je     1136 <Strings__init+0x26>
mov    0x2f03(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1164 <Strings__init+0x54>
cmpq   $0x0,0x2ef2(%rip)
jne    1159 <Strings__init+0x49>
lea    0xeb5(%rip),%rdi
xor    %esi,%esi
call   1030 <Heap_REGMOD@plt>
mov    %rax,0x2ed7(%rip)
mov    0x2ed0(%rip),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<Strings__init>:
push   %rax
mov    0x2f18(%rip),%rax
test   %rax,%rax
je     111f <Strings__init+0xf>
pop    %rcx
ret
lea    0xeda(%rip),%rdi
xor    %esi,%esi
call   1030 <Heap_REGMOD@plt>
mov    %rax,0x2efc(%rip)
pop    %rcx
ret

LLVM IR (-O0):
@Strings__init.m = internal global i8* null
@.str = [8 x i8] c"Strings\00"
define i8* @Strings__init() {
%1 = alloca i8*
%2 = load i8*, i8** @Strings__init.m
%3 = icmp ne i8* %2, null
br i1 %3, label %4, label %6
4: ; preds = %0
%5 = load i8*, i8** @Strings__init.m
store i8* %5, i8** %1
br label %13
6: ; preds = %0
%7 = load i8*, i8** @Strings__init.m
%8 = icmp eq i8* %7, null
br i1 %8, label %9, label %11
9: ; preds = %6
%10 = call i8* @Heap_REGMOD(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i32 0)
store i8* %10, i8** @Strings__init.m
br label %11
11: ; preds = %9, %6
%12 = load i8*, i8** @Strings__init.m
store i8* %12, i8** %1
br label %13
13: ; preds = %11, %4
%14 = load i8*, i8** %1
ret i8* %14
}

LLVM IR (-O2):
@Strings__init.m = internal unnamed_addr global i8* null
@.str = [8 x i8] c"Strings\00"
define i8* @Strings__init() {
%1 = load i8*, i8** @Strings__init.m
%2 = icmp eq i8* %1, null
br i1 %2, label %3, label %5
3: ; preds = %0
%4 = tail call i8* @Heap_REGMOD(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i32 0)
store i8* %4, i8** @Strings__init.m
br label %5
5: ; preds = %0, %3
%6 = phi i8* [ %4, %3 ], [ %1, %0 ]
ret i8* %6
}
/* Variables and functions */
float logf(float);
float HMM_LogF(float Float) {
  float Result = logf(Float);
  return (Result);
}


x86 assembly (clang, -O0):
<HMM_LogF>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
call   1030 <logf@plt>
movss  %xmm0,-0x8(%rbp)
movss  -0x8(%rbp),%xmm0
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<HMM_LogF>:
jmp    1030 <logf@plt>

LLVM IR (-O0):
define float @HMM_LogF(float %0) {
%2 = alloca float
%3 = alloca float
store float %0, float* %2
%4 = load float, float* %2
%5 = call float @logf(float %4)
store float %5, float* %3
%6 = load float, float* %3
ret float %6
}

LLVM IR (-O2):
define float @HMM_LogF(float %0) {
%2 = tail call float @logf(float %0)
ret float %2
}