xunge/DecIR huggingface dataset:
int matchalpha(char c) {
  return ((c >= 'a') && (c <= 'z')) || ((c >= 'A') && (c <= 'Z'));
}


x86 assembly (clang, -O0):
<matchalpha>:
push   %rbp
mov    %rsp,%rbp
mov    %dil,%al
mov    %al,-0x1(%rbp)
movsbl -0x1(%rbp),%eax
cmp    $0x61,%eax
jl     1129 <matchalpha+0x29>
movsbl -0x1(%rbp),%ecx
mov    $0x1,%al
cmp    $0x7a,%ecx
mov    %al,-0x2(%rbp)
jle    114e <matchalpha+0x4e>
movsbl -0x1(%rbp),%ecx
xor    %eax,%eax
cmp    $0x41,%ecx
mov    %al,-0x3(%rbp)
jl     1148 <matchalpha+0x48>
movsbl -0x1(%rbp),%eax
cmp    $0x5a,%eax
setle  %al
mov    %al,-0x3(%rbp)
mov    -0x3(%rbp),%al
mov    %al,-0x2(%rbp)
mov    -0x2(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<matchalpha>:
and    $0xdf,%dil
add    $0xbf,%dil
xor    %eax,%eax
cmp    $0x1a,%dil
setb   %al
ret

LLVM IR (-O0):
define i32 @matchalpha(i8 signext %0) {
%2 = alloca i8
store i8 %0, i8* %2
%3 = load i8, i8* %2
%4 = sext i8 %3 to i32
%5 = icmp sge i32 %4, 97
br i1 %5, label %6, label %10
6: ; preds = %1
%7 = load i8, i8* %2
%8 = sext i8 %7 to i32
%9 = icmp sle i32 %8, 122
br i1 %9, label %20, label %10
10: ; preds = %6, %1
%11 = load i8, i8* %2
%12 = sext i8 %11 to i32
%13 = icmp sge i32 %12, 65
br i1 %13, label %14, label %18
14: ; preds = %10
%15 = load i8, i8* %2
%16 = sext i8 %15 to i32
%17 = icmp sle i32 %16, 90
br label %18
18: ; preds = %14, %10
%19 = phi i1 [ false, %10 ], [ %17, %14 ]
br label %20
20: ; preds = %18, %6
%21 = phi i1 [ true, %6 ], [ %19, %18 ]
%22 = zext i1 %21 to i32
ret i32 %22
}

LLVM IR (-O2):
define i32 @matchalpha(i8 signext %0) {
%2 = and i8 %0, -33
%3 = add i8 %2, -65
%4 = icmp ult i8 %3, 26
%5 = zext i1 %4 to i32
ret i32 %5
}
/* Type definitions */
typedef int uint8_t;

/* Variables and functions */
int /*<<< orphan*/ memcpy(int *, int const *, size_t const);
int /*<<< orphan*/ memset(int *, int /*<<< orphan*/, int);
void norx_pad(uint8_t *out, const uint8_t *in, const size_t inlen) {
  memset(out, 0, (((((32 * 16) - (32 * 6))) + 7) / 8));
  memcpy(out, in, inlen);
  out[inlen] = 0x01;
  out[(((((32 * 16) - (32 * 6))) + 7) / 8) - 1] |= 0x80;
}


x86 assembly (clang, -O0):
<norx_pad>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x8(%rbp),%rdi
xor    %esi,%esi
mov    $0x28,%edx
call   1030 <memset@plt>
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
mov    -0x18(%rbp),%rdx
call   1040 <memcpy@plt>
mov    -0x8(%rbp),%rax
mov    -0x18(%rbp),%rcx
movl   $0x1,(%rax,%rcx,4)
mov    -0x8(%rbp),%rax
mov    0x9c(%rax),%ecx
or     $0x80,%ecx
mov    %ecx,0x9c(%rax)
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<norx_pad>:
push   %r15
push   %r14
push   %rbx
mov    %rdx,%r15
mov    %rsi,%r14
mov    %rdi,%rbx
xor    %esi,%esi
mov    $0x28,%edx
call   1030 <memset@plt>
mov    %rbx,%rdi
mov    %r14,%rsi
mov    %r15,%rdx
call   1040 <memcpy@plt>
movl   $0x1,(%rbx,%r15,4)
orb    $0x80,0x9c(%rbx)
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
define void @norx_pad(i32* %0, i32* %1, i64 %2) {
%4 = alloca i32*
%5 = alloca i32*
%6 = alloca i64
store i32* %0, i32** %4
store i32* %1, i32** %5
store i64 %2, i64* %6
%7 = load i32*, i32** %4
%8 = call i32 @memset(i32* %7, i32 0, i32 40)
%9 = load i32*, i32** %4
%10 = load i32*, i32** %5
%11 = load i64, i64* %6
%12 = call i32 @memcpy(i32* %9, i32* %10, i64 %11)
%13 = load i32*, i32** %4
%14 = load i64, i64* %6
%15 = getelementptr inbounds i32, i32* %13, i64 %14
store i32 1, i32* %15
%16 = load i32*, i32** %4
%17 = getelementptr inbounds i32, i32* %16, i64 39
%18 = load i32, i32* %17
%19 = or i32 %18, 128
store i32 %19, i32* %17
ret void
}

LLVM IR (-O2):
define void @norx_pad(i32* %0, i32* %1, i64 %2) {
%4 = tail call i32 @memset(i32* %0, i32 0, i32 40)
%5 = tail call i32 @memcpy(i32* %0, i32* %1, i64 %2)
%6 = getelementptr inbounds i32, i32* %0, i64 %2
store i32 1, i32* %6
%7 = getelementptr inbounds i32, i32* %0, i64 39
%8 = load i32, i32* %7
%9 = or i32 %8, 128
store i32 %9, i32* %7
ret void
}
/* Variables and functions */
int isascii(int);
int isrune(int c) { return isascii(c); }


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

x86 assembly (clang, -O2):
<isrune>:
xor    %eax,%eax
cmp    $0x80,%edi
setb   %al
ret

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

LLVM IR (-O2):
define i32 @isrune(i32 %0) {
%2 = icmp ult i32 %0, 128
%3 = zext i1 %2 to i32
ret i32 %3
}
/* Variables and functions */
int /*<<< orphan*/ h2o__fatal(char *, int, char *);
void *malloc(size_t);
void *h2o_mem_alloc(size_t sz) {
  void *p = malloc(sz);
  if (p == NULL)
    h2o__fatal("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
               "outputs/2022-01-22/02-19-57/repos/devnexen/h2o/refs/heads/"
               "master/include/h2o/h2o/memory.h",
               406, "no memory");
  return p;
}


x86 assembly (clang, -O0):
<h2o_mem_alloc>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1040 <malloc@plt>
mov    %rax,-0x10(%rbp)
cmpq   $0x0,-0x10(%rbp)
jne    115c <h2o_mem_alloc+0x3c>
lea    0xeb5(%rip),%rdi
mov    $0x196,%esi
lea    0xf3b(%rip),%rdx
call   1030 <h2o__fatal@plt>
mov    -0x10(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<h2o_mem_alloc>:
push   %rbx
call   1040 <malloc@plt>
mov    %rax,%rbx
test   %rax,%rax
jne    1146 <h2o_mem_alloc+0x26>
lea    0xecb(%rip),%rdi
lea    0xf56(%rip),%rdx
mov    $0x196,%esi
call   1030 <h2o__fatal@plt>
mov    %rbx,%rax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [146 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/devnexen/h2o/refs/heads/master/include/h2o/h2o/memory.h\00"
@.str.1 = [10 x i8] c"no memory\00"
define i8* @h2o_mem_alloc(i64 %0) {
%2 = alloca i64
%3 = alloca i8*
store i64 %0, i64* %2
%4 = load i64, i64* %2
%5 = call i8* @malloc(i64 %4)
store i8* %5, i8** %3
%6 = load i8*, i8** %3
%7 = icmp eq i8* %6, null
br i1 %7, label %8, label %10
8: ; preds = %1
%9 = call i32 @h2o__fatal(i8* getelementptr inbounds ([146 x i8], [146 x i8]* @.str, i64 0, i64 0), i32 406, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0))
br label %10
10: ; preds = %8, %1
%11 = load i8*, i8** %3
ret i8* %11
}

LLVM IR (-O2):
@.str = [146 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/devnexen/h2o/refs/heads/master/include/h2o/h2o/memory.h\00"
@.str.1 = [10 x i8] c"no memory\00"
define noalias i8* @h2o_mem_alloc(i64 %0) {
%2 = tail call i8* @malloc(i64 %0)
%3 = icmp eq i8* %2, null
br i1 %3, label %4, label %6
4: ; preds = %1
%5 = tail call i32 @h2o__fatal(i8* getelementptr inbounds ([146 x i8], [146 x i8]* @.str, i64 0, i64 0), i32 406, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0))
br label %6
6: ; preds = %4, %1
ret i8* %2
}
/* Variables and functions */
int /*<<< orphan*/ make_upper(char *);
int /*<<< orphan*/ scanf(char *, char *);
int main() {
  char word[80];
  scanf("%s", word);
  make_upper(word);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x60,%rsp
movl   $0x0,-0x4(%rbp)
lea    -0x60(%rbp),%rsi
lea    0xec6(%rip),%rdi
call   1040 <scanf@plt>
lea    -0x60(%rbp),%rdi
call   1030 <make_upper@plt>
xor    %eax,%eax
add    $0x60,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x50,%rsp
lea    0xed4(%rip),%rdi
mov    %rsp,%rbx
mov    %rbx,%rsi
call   1040 <scanf@plt>
mov    %rbx,%rdi
call   1030 <make_upper@plt>
xor    %eax,%eax
add    $0x50,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%s\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [80 x i8]
store i32 0, i32* %1
%3 = getelementptr inbounds [80 x i8], [80 x i8]* %2, i64 0, i64 0
%4 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* %3)
%5 = getelementptr inbounds [80 x i8], [80 x i8]* %2, i64 0, i64 0
%6 = call i32 @make_upper(i8* %5)
ret i32 0
}

LLVM IR (-O2):
@.str = [3 x i8] c"%s\00"
define i32 @main() {
%1 = alloca [80 x i8]
%2 = getelementptr inbounds [80 x i8], [80 x i8]* %1, i64 0, i64 0
%3 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* %2)
%4 = call i32 @make_upper(i8* %2)
ret i32 0
}
/* Variables and functions */
float __ocml_trunc_f32(float);
float truncf(float x) { return __ocml_trunc_f32(x); }


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

x86 assembly (clang, -O2):
<truncf>:
jmp    1030 <__ocml_trunc_f32@plt>

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

LLVM IR (-O2):
define float @truncf(float %0) {
%2 = tail call float @__ocml_trunc_f32(float %0)
ret float %2
}
/* Type definitions */
typedef scalar_t__ cl_int;
typedef scalar_t__ cl_event;

/* Variables and functions */
int /*<<< orphan*/ syscall(int, int, unsigned int *);
cl_int clSetUserEventStatus(cl_event event, cl_int execution_status) {
  unsigned int sys_args[2];
  sys_args[0] = (unsigned int)event;
  sys_args[1] = (unsigned int)execution_status;
  return (cl_int)syscall(325, 1048, sys_args);
}


x86 assembly (clang, -O0):
<clSetUserEventStatus>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
mov    %eax,-0x18(%rbp)
mov    -0x10(%rbp),%rax
mov    %eax,-0x14(%rbp)
lea    -0x18(%rbp),%rdx
mov    $0x145,%edi
mov    $0x418,%esi
call   1030 <syscall@plt>
cltq
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<clSetUserEventStatus>:
push   %rax
mov    %edi,(%rsp)
mov    %esi,0x4(%rsp)
mov    %rsp,%rdx
mov    $0x145,%edi
mov    $0x418,%esi
call   1030 <syscall@plt>
cltq
pop    %rcx
ret

LLVM IR (-O0):
define i64 @clSetUserEventStatus(i64 %0, i64 %1) {
%3 = alloca i64
%4 = alloca i64
%5 = alloca [2 x i32]
store i64 %0, i64* %3
store i64 %1, i64* %4
%6 = load i64, i64* %3
%7 = trunc i64 %6 to i32
%8 = getelementptr inbounds [2 x i32], [2 x i32]* %5, i64 0, i64 0
store i32 %7, i32* %8
%9 = load i64, i64* %4
%10 = trunc i64 %9 to i32
%11 = getelementptr inbounds [2 x i32], [2 x i32]* %5, i64 0, i64 1
store i32 %10, i32* %11
%12 = getelementptr inbounds [2 x i32], [2 x i32]* %5, i64 0, i64 0
%13 = call i32 @syscall(i32 325, i32 1048, i32* %12)
%14 = sext i32 %13 to i64
ret i64 %14
}

LLVM IR (-O2):
define i64 @clSetUserEventStatus(i64 %0, i64 %1) {
%3 = alloca [2 x i32]
%4 = bitcast [2 x i32]* %3 to i8*
%5 = trunc i64 %0 to i32
%6 = getelementptr inbounds [2 x i32], [2 x i32]* %3, i64 0, i64 0
store i32 %5, i32* %6
%7 = trunc i64 %1 to i32
%8 = getelementptr inbounds [2 x i32], [2 x i32]* %3, i64 0, i64 1
store i32 %7, i32* %8
%9 = call i32 @syscall(i32 325, i32 1048, i32* %6)
%10 = sext i32 %9 to i64
ret i64 %10
}
/* Variables and functions */
scalar_t__ jnf(int, float);
int /*<<< orphan*/ link_failure_jnf();
void test_jnf(int x, float f) {
  if (jnf(x, f) != jnf(x, f))
    link_failure_jnf();
}


x86 assembly (clang, -O0):
<test_jnf>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
movss  %xmm0,-0x8(%rbp)
mov    -0x4(%rbp),%edi
movss  -0x8(%rbp),%xmm0
call   1030 <jnf@plt>
mov    %rax,-0x10(%rbp)
mov    -0x4(%rbp),%edi
movss  -0x8(%rbp),%xmm0
call   1030 <jnf@plt>
mov    %rax,%rcx
mov    -0x10(%rbp),%rax
cmp    %rcx,%rax
je     1165 <test_jnf+0x45>
mov    $0x0,%al
call   1040 <link_failure_jnf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_jnf>:
push   %r14
push   %rbx
push   %rax
movss  %xmm0,0x4(%rsp)
mov    %edi,%ebx
call   1030 <jnf@plt>
mov    %rax,%r14
mov    %ebx,%edi
movss  0x4(%rsp),%xmm0
call   1030 <jnf@plt>
cmp    %rax,%r14
jne    114e <test_jnf+0x2e>
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1040 <link_failure_jnf@plt>

LLVM IR (-O0):
define void @test_jnf(i32 %0, float %1) {
%3 = alloca i32
%4 = alloca float
store i32 %0, i32* %3
store float %1, float* %4
%5 = load i32, i32* %3
%6 = load float, float* %4
%7 = call i64 @jnf(i32 %5, float %6)
%8 = load i32, i32* %3
%9 = load float, float* %4
%10 = call i64 @jnf(i32 %8, float %9)
%11 = icmp ne i64 %7, %10
br i1 %11, label %12, label %14
12: ; preds = %2
%13 = call i32 (...) @link_failure_jnf()
br label %14
14: ; preds = %12, %2
ret void
}

LLVM IR (-O2):
define void @test_jnf(i32 %0, float %1) {
%3 = tail call i64 @jnf(i32 %0, float %1)
%4 = tail call i64 @jnf(i32 %0, float %1)
%5 = icmp eq i64 %3, %4
br i1 %5, label %8, label %6
6: ; preds = %2
%7 = tail call i32 (...) @link_failure_jnf()
br label %8
8: ; preds = %6, %2
ret void
}
void __attribute__((visibility("default")))
border_w_horizontal_special_sand_s(unsigned char *pic, unsigned char *mirr) {
  *pic = 0x2D;
  *mirr = 0x01;
}


x86 assembly (clang, -O0):
<border_w_horizontal_special_sand_s>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
movb   $0x2d,(%rax)
mov    -0x10(%rbp),%rax
movb   $0x1,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<border_w_horizontal_special_sand_s>:
movb   $0x2d,(%rdi)
movb   $0x1,(%rsi)
ret

LLVM IR (-O0):
define void @border_w_horizontal_special_sand_s(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
store i8 45, i8* %5
%6 = load i8*, i8** %4
store i8 1, i8* %6
ret void
}

LLVM IR (-O2):
define void @border_w_horizontal_special_sand_s(i8* nocapture writeonly %0, i8* nocapture writeonly %1) {
store i8 45, i8* %0
store i8 1, i8* %1
ret void
}
/* Variables and functions */
int /*<<< orphan*/ delay(int);
int /*<<< orphan*/ print_str(char *);
int /*<<< orphan*/ syscall();
void task1_func(void) {
  print_str("task1: Created!\n");
  print_str("task1: Now, return to kernel mode\n");
  syscall();
  while (1) {
    print_str("task1: Running...\n");
    delay(1000);
  }
}


x86 assembly (clang, -O0):
<task1_func>:
push   %rbp
mov    %rsp,%rbp
lea    0xec5(%rip),%rdi
call   1040 <print_str@plt>
lea    0xeca(%rip),%rdi
call   1040 <print_str@plt>
mov    $0x0,%al
call   1050 <syscall@plt>
lea    0xeda(%rip),%rdi
call   1040 <print_str@plt>
mov    $0x3e8,%edi
call   1030 <delay@plt>
jmp    1153 <task1_func+0x23>

x86 assembly (clang, -O2):
<task1_func>:
push   %rbx
lea    0xec8(%rip),%rdi
call   1040 <print_str@plt>
lea    0xecd(%rip),%rdi
call   1040 <print_str@plt>
xor    %eax,%eax
call   1050 <syscall@plt>
lea    0xedd(%rip),%rbx
nopw   0x0(%rax,%rax,1)
mov    %rbx,%rdi
call   1040 <print_str@plt>
mov    $0x3e8,%edi
call   1030 <delay@plt>
jmp    1160 <task1_func+0x30>

LLVM IR (-O0):
@.str = [17 x i8] c"task1: Created!\0A\00"
@.str.1 = [35 x i8] c"task1: Now, return to kernel mode\0A\00"
@.str.2 = [19 x i8] c"task1: Running...\0A\00"
define void @task1_func() {
%1 = call i32 @print_str(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0))
%2 = call i32 @print_str(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.1, i64 0, i64 0))
%3 = call i32 (...) @syscall()
br label %4
4: ; preds = %0, %4
%5 = call i32 @print_str(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.2, i64 0, i64 0))
%6 = call i32 @delay(i32 1000)
br label %4
}

LLVM IR (-O2):
@.str = [17 x i8] c"task1: Created!\0A\00"
@.str.1 = [35 x i8] c"task1: Now, return to kernel mode\0A\00"
@.str.2 = [19 x i8] c"task1: Running...\0A\00"
define void @task1_func() {
%1 = tail call i32 @print_str(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 @print_str(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.1, i64 0, i64 0))
%3 = tail call i32 (...) @syscall()
br label %4
4: ; preds = %0, %4
%5 = tail call i32 @print_str(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.2, i64 0, i64 0))
%6 = tail call i32 @delay(i32 1000)
br label %4
}
/* Variables and functions */
int /*<<< orphan*/ inittls();
void xinitcgo(void) { inittls(); }


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

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

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

LLVM IR (-O2):
define void @xinitcgo() {
%1 = tail call i32 (...) @inittls()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf2(char *, int /*<<< orphan*/);
int /*<<< orphan*/ truncUint(unsigned int);
void GenZeroData(unsigned Size, int bss) {
  printf2(bss ? "\tresb\t%u\n" : "\ttimes\t%u db 0\n", truncUint(Size));
}


x86 assembly (clang, -O0):
<GenZeroData>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x8(%rbp),%edx
lea    0xed2(%rip),%rax
lea    0xec1(%rip),%rcx
cmp    $0x0,%edx
cmovne %rcx,%rax
mov    %rax,-0x10(%rbp)
mov    -0x4(%rbp),%edi
call   1040 <truncUint@plt>
mov    -0x10(%rbp),%rdi
mov    %eax,%esi
call   1030 <printf2@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<GenZeroData>:
push   %rbx
test   %esi,%esi
lea    0xee0(%rip),%rax
lea    0xecf(%rip),%rbx
cmove  %rax,%rbx
call   1040 <truncUint@plt>
mov    %rbx,%rdi
mov    %eax,%esi
pop    %rbx
jmp    1030 <printf2@plt>

LLVM IR (-O0):
@.str = [10 x i8] c"\09resb\09%u\0A\00"
@.str.1 = [16 x i8] c"\09times\09%u db 0\0A\00"
define void @GenZeroData(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
store i32 %0, i32* %3
store i32 %1, i32* %4
%5 = load i32, i32* %4
%6 = icmp ne i32 %5, 0
%7 = zext i1 %6 to i64
%8 = select i1 %6, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.1, i64 0, i64 0)
%9 = load i32, i32* %3
%10 = call i32 @truncUint(i32 %9)
%11 = call i32 @printf2(i8* %8, i32 %10)
ret void
}

LLVM IR (-O2):
@.str = [10 x i8] c"\09resb\09%u\0A\00"
@.str.1 = [16 x i8] c"\09times\09%u db 0\0A\00"
define void @GenZeroData(i32 %0, i32 %1) {
%3 = icmp eq i32 %1, 0
%4 = select i1 %3, i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0)
%5 = tail call i32 @truncUint(i32 %0)
%6 = tail call i32 @printf2(i8* %4, i32 %5)
ret void
}
void DBGFR3OSQueryNameAndVersion(void) {}


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

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

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

LLVM IR (-O2):
define void @DBGFR3OSQueryNameAndVersion() {
ret void
}
int strlen_other(char *s) {
  int n = 0;
  for (n = 0; *s != '\0'; s++) {
    n++;
  };
  return n;
}


x86 assembly (clang, -O0):
<strlen_other>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
movl   $0x0,-0xc(%rbp)
mov    -0x8(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x0,%eax
je     1140 <strlen_other+0x40>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
mov    -0x8(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x8(%rbp)
jmp    1116 <strlen_other+0x16>
mov    -0xc(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<strlen_other>:
cmpb   $0x0,(%rdi)
je     111c <strlen_other+0x1c>
xor    %eax,%eax
nopw   0x0(%rax,%rax,1)
cmpb   $0x0,0x1(%rdi,%rax,1)
lea    0x1(%rax),%rax
jne    1110 <strlen_other+0x10>
ret
xor    %eax,%eax
ret

LLVM IR (-O0):
define i32 @strlen_other(i8* %0) {
%2 = alloca i8*
%3 = alloca i32
store i8* %0, i8** %2
store i32 0, i32* %3
store i32 0, i32* %3
br label %4
4: ; preds = %12, %1
%5 = load i8*, i8** %2
%6 = load i8, i8* %5
%7 = sext i8 %6 to i32
%8 = icmp ne i32 %7, 0
br i1 %8, label %9, label %15
9: ; preds = %4
%10 = load i32, i32* %3
%11 = add nsw i32 %10, 1
store i32 %11, i32* %3
br label %12
12: ; preds = %9
%13 = load i8*, i8** %2
%14 = getelementptr inbounds i8, i8* %13, i32 1
store i8* %14, i8** %2
br label %4
15: ; preds = %4
%16 = load i32, i32* %3
ret i32 %16
}

LLVM IR (-O2):
define i32 @strlen_other(i8* nocapture %0) {
%2 = load i8, i8* %0
%3 = icmp eq i8 %2, 0
br i1 %3, label %11, label %4
4: ; preds = %1, %4
%5 = phi i32 [ %7, %4 ], [ 0, %1 ]
%6 = phi i8* [ %8, %4 ], [ %0, %1 ]
%7 = add nuw nsw i32 %5, 1
%8 = getelementptr inbounds i8, i8* %6, i64 1
%9 = load i8, i8* %8
%10 = icmp eq i8 %9, 0
br i1 %10, label %11, label %4
11: ; preds = %4, %1
%12 = phi i32 [ 0, %1 ], [ %7, %4 ]
ret i32 %12
}
void S_Shutdown(void) {}


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

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

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

LLVM IR (-O2):
define void @S_Shutdown() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
int main(int argc, char **argv) {
  printf("Clash 2.\n");
  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)
lea    0xed3(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xee8(%rip),%rdi
call   1030 <puts@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [10 x i8] c"Clash 2.\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 = call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@str = [9 x i8] c"Clash 2.\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @str, i64 0, i64 0))
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ clearDregister();
int /*<<< orphan*/ clearEregister();
int /*<<< orphan*/ clearFregister();
int /*<<< orphan*/ clearMregister();
int /*<<< orphan*/ clearWregister();
int /*<<< orphan*/ initFuncPtrArray();
int /*<<< orphan*/ initMemory();
void setupyess(void) {
  initFuncPtrArray();
  initMemory();
  clearFregister();
  clearDregister();
  clearEregister();
  clearMregister();
  clearWregister();
}


x86 assembly (clang, -O0):
<setupyess>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1090 <initFuncPtrArray@plt>
mov    $0x0,%al
call   1040 <initMemory@plt>
mov    $0x0,%al
call   1050 <clearFregister@plt>
mov    $0x0,%al
call   1060 <clearDregister@plt>
mov    $0x0,%al
call   1030 <clearEregister@plt>
mov    $0x0,%al
call   1080 <clearMregister@plt>
mov    $0x0,%al
call   1070 <clearWregister@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<setupyess>:
push   %rax
xor    %eax,%eax
call   1090 <initFuncPtrArray@plt>
xor    %eax,%eax
call   1040 <initMemory@plt>
xor    %eax,%eax
call   1050 <clearFregister@plt>
xor    %eax,%eax
call   1060 <clearDregister@plt>
xor    %eax,%eax
call   1030 <clearEregister@plt>
xor    %eax,%eax
call   1080 <clearMregister@plt>
xor    %eax,%eax
pop    %rcx
jmp    1070 <clearWregister@plt>

LLVM IR (-O0):
define void @setupyess() {
%1 = call i32 (...) @initFuncPtrArray()
%2 = call i32 (...) @initMemory()
%3 = call i32 (...) @clearFregister()
%4 = call i32 (...) @clearDregister()
%5 = call i32 (...) @clearEregister()
%6 = call i32 (...) @clearMregister()
%7 = call i32 (...) @clearWregister()
ret void
}

LLVM IR (-O2):
define void @setupyess() {
%1 = tail call i32 (...) @initFuncPtrArray()
%2 = tail call i32 (...) @initMemory()
%3 = tail call i32 (...) @clearFregister()
%4 = tail call i32 (...) @clearDregister()
%5 = tail call i32 (...) @clearEregister()
%6 = tail call i32 (...) @clearMregister()
%7 = tail call i32 (...) @clearWregister()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ itemDrop(int /*<<< orphan*/);
int /*<<< orphan*/ itemInvChooseItem();
void input_drop(void) { itemDrop(itemInvChooseItem()); }


x86 assembly (clang, -O0):
<input_drop>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1040 <itemInvChooseItem@plt>
mov    %eax,%edi
call   1030 <itemDrop@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<input_drop>:
push   %rax
xor    %eax,%eax
call   1040 <itemInvChooseItem@plt>
mov    %eax,%edi
pop    %rax
jmp    1030 <itemDrop@plt>

LLVM IR (-O0):
define void @input_drop() {
%1 = call i32 (...) @itemInvChooseItem()
%2 = call i32 @itemDrop(i32 %1)
ret void
}

LLVM IR (-O2):
define void @input_drop() {
%1 = tail call i32 (...) @itemInvChooseItem()
%2 = tail call i32 @itemDrop(i32 %1)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, unsigned char *);
void dumpitems(unsigned char *s[], int n) {
  int i;
  for (i = 0; i < n; i++) {
    printf("%s", s[i]);
  };
}


x86 assembly (clang, -O0):
<dumpitems>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
movl   $0x0,-0x10(%rbp)
mov    -0x10(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    1158 <dumpitems+0x48>
mov    -0x8(%rbp),%rax
movslq -0x10(%rbp),%rcx
mov    (%rax,%rcx,8),%rsi
lea    0xebb(%rip),%rdi
call   1030 <printf@plt>
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
jmp    1126 <dumpitems+0x16>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<dumpitems>:
push   %r15
push   %r14
push   %r12
push   %rbx
push   %rax
test   %esi,%esi
jle    1145 <dumpitems+0x35>
mov    %rdi,%r15
mov    %esi,%r12d
xor    %ebx,%ebx
lea    0xed5(%rip),%r14
nopl   0x0(%rax,%rax,1)
mov    (%r15,%rbx,8),%rsi
mov    %r14,%rdi
call   1030 <printf@plt>
add    $0x1,%rbx
cmp    %rbx,%r12
jne    1130 <dumpitems+0x20>
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%s\00"
define void @dumpitems(i8** %0, i32 %1) {
%3 = alloca i8**
%4 = alloca i32
%5 = alloca i32
store i8** %0, i8*** %3
store i32 %1, i32* %4
store i32 0, i32* %5
br label %6
6: ; preds = %17, %2
%7 = load i32, i32* %5
%8 = load i32, i32* %4
%9 = icmp slt i32 %7, %8
br i1 %9, label %10, label %20
10: ; preds = %6
%11 = load i8**, i8*** %3
%12 = load i32, i32* %5
%13 = sext i32 %12 to i64
%14 = getelementptr inbounds i8*, i8** %11, i64 %13
%15 = load i8*, i8** %14
%16 = call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* %15)
br label %17
17: ; preds = %10
%18 = load i32, i32* %5
%19 = add nsw i32 %18, 1
store i32 %19, i32* %5
br label %6
20: ; preds = %6
ret void
}

LLVM IR (-O2):
@.str = [3 x i8] c"%s\00"
define void @dumpitems(i8** nocapture %0, i32 %1) {
%3 = icmp sgt i32 %1, 0
br i1 %3, label %4, label %13
4: ; preds = %2
%5 = zext i32 %1 to i64
br label %6
6: ; preds = %4, %6
%7 = phi i64 [ 0, %4 ], [ %11, %6 ]
%8 = getelementptr inbounds i8*, i8** %0, i64 %7
%9 = load i8*, i8** %8
%10 = tail call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* %9)
%11 = add nuw nsw i64 %7, 1
%12 = icmp eq i64 %11, %5
br i1 %12, label %13, label %6
13: ; preds = %6, %2
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ ENGINE;

/* Variables and functions */
int RAND_set_rand_engine(ENGINE *engine) { return 1; }


x86 assembly (clang, -O0):
<RAND_set_rand_engine>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    $0x1,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<RAND_set_rand_engine>:
mov    $0x1,%eax
ret

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

LLVM IR (-O2):
define i32 @RAND_set_rand_engine(i32* nocapture readnone %0) {
ret i32 1
}
/* Type definitions */
typedef int /*<<< orphan*/ uint8_t;
struct list_head {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ clear_compression_mode_pg(struct list_head *);
uint8_t clear_ult_compression(struct list_head *m) {
  ;
  return clear_compression_mode_pg(m);
}


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

x86 assembly (clang, -O2):
<clear_ult_compression>:
jmp    1030 <clear_compression_mode_pg@plt>

LLVM IR (-O0):
%struct.list_head = type { i32 }
define i32 @clear_ult_compression(%struct.list_head* %0) {
%2 = alloca %struct.list_head*
store %struct.list_head* %0, %struct.list_head** %2
%3 = load %struct.list_head*, %struct.list_head** %2
%4 = call i32 @clear_compression_mode_pg(%struct.list_head* %3)
ret i32 %4
}

LLVM IR (-O2):
%struct.list_head = type { i32 }
define i32 @clear_ult_compression(%struct.list_head* %0) {
%2 = tail call i32 @clear_compression_mode_pg(%struct.list_head* %0)
ret i32 %2
}
/* Variables and functions */
double pow(double, double);
double c_pow(double arg0, double arg1) { return pow(arg0, arg1); }


x86 assembly (clang, -O0):
<c_pow>:
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 <pow@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<c_pow>:
jmp    1030 <pow@plt>

LLVM IR (-O0):
define double @c_pow(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 @pow(double %5, double %6)
ret double %7
}

LLVM IR (-O2):
define double @c_pow(double %0, double %1) {
%3 = tail call double @pow(double %0, double %1)
ret double %3
}
__attribute__((always_)) void uvisor_noreturn(void) {
  volatile int var = 1;
  while (var)
    ;
}


x86 assembly (clang, -O0):
<uvisor_noreturn>:
push   %rbp
mov    %rsp,%rbp
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
cmp    $0x0,%eax
je     111c <uvisor_noreturn+0x1c>
jmp    110b <uvisor_noreturn+0xb>
pop    %rbp
ret

x86 assembly (clang, -O2):
<uvisor_noreturn>:
movl   $0x1,-0x4(%rsp)
nopl   0x0(%rax,%rax,1)
cmpl   $0x0,-0x4(%rsp)
jne    1110 <uvisor_noreturn+0x10>
ret

LLVM IR (-O0):
define void @uvisor_noreturn() {
%1 = alloca i32
store volatile i32 1, i32* %1
br label %2
2: ; preds = %5, %0
%3 = load volatile i32, i32* %1
%4 = icmp ne i32 %3, 0
br i1 %4, label %5, label %6
5: ; preds = %2
br label %2
6: ; preds = %2
ret void
}

LLVM IR (-O2):
define void @uvisor_noreturn() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
store volatile i32 1, i32* %1
br label %3
3: ; preds = %3, %0
%4 = load volatile i32, i32* %1
%5 = icmp eq i32 %4, 0
br i1 %5, label %6, label %3
6: ; preds = %3
ret void
}
int smb1357_watchdog_timer_enable(void) { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @smb1357_watchdog_timer_enable() {
ret i32 0
}
/* Type definitions */
typedef int /*<<< orphan*/ cpu_set_t;

/* Variables and functions */
int /*<<< orphan*/ CPU_ALLOC_SIZE(size_t);
int /*<<< orphan*/ *malloc(int /*<<< orphan*/);
cpu_set_t *__sched_cpualloc(size_t count) {
  return malloc(CPU_ALLOC_SIZE(count));
}


x86 assembly (clang, -O0):
<__sched_cpualloc>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <CPU_ALLOC_SIZE@plt>
mov    %eax,%edi
call   1040 <malloc@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<__sched_cpualloc>:
push   %rax
call   1030 <CPU_ALLOC_SIZE@plt>
mov    %eax,%edi
pop    %rax
jmp    1040 <malloc@plt>

LLVM IR (-O0):
define i32* @__sched_cpualloc(i64 %0) {
%2 = alloca i64
store i64 %0, i64* %2
%3 = load i64, i64* %2
%4 = call i32 @CPU_ALLOC_SIZE(i64 %3)
%5 = call i32* @malloc(i32 %4)
ret i32* %5
}

LLVM IR (-O2):
define noalias i32* @__sched_cpualloc(i64 %0) {
%2 = tail call i32 @CPU_ALLOC_SIZE(i64 %0)
%3 = tail call i32* @malloc(i32 %2)
ret i32* %3
}
/* Type definitions */
typedef int /*<<< orphan*/ time_t;
struct mg_connection {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ mg_call(struct mg_connection *, int /*<<< orphan*/ *,
                           int /*<<< orphan*/, int /*<<< orphan*/ *);
void mg_if_poll(struct mg_connection *nc, time_t now) {
  mg_call(nc, NULL, 0, &now);
}


x86 assembly (clang, -O0):
<mg_if_poll>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0x8(%rbp),%rdi
xor    %eax,%eax
mov    %eax,%esi
xor    %edx,%edx
lea    -0xc(%rbp),%rcx
call   1030 <mg_call@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<mg_if_poll>:
push   %rax
mov    %esi,0x4(%rsp)
lea    0x4(%rsp),%rcx
xor    %esi,%esi
xor    %edx,%edx
call   1030 <mg_call@plt>
pop    %rax
ret

LLVM IR (-O0):
%struct.mg_connection = type { i32 }
define void @mg_if_poll(%struct.mg_connection* %0, i32 %1) {
%3 = alloca %struct.mg_connection*
%4 = alloca i32
store %struct.mg_connection* %0, %struct.mg_connection** %3
store i32 %1, i32* %4
%5 = load %struct.mg_connection*, %struct.mg_connection** %3
%6 = call i32 @mg_call(%struct.mg_connection* %5, i32* null, i32 0, i32* %4)
ret void
}

LLVM IR (-O2):
%struct.mg_connection = type { i32 }
define void @mg_if_poll(%struct.mg_connection* %0, i32 %1) {
%3 = alloca i32
store i32 %1, i32* %3
%4 = call i32 @mg_call(%struct.mg_connection* %0, i32* null, i32 0, i32* %3)
ret void
}
void I422ToYUY2Row_Any_NEON() {}


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

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

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

LLVM IR (-O2):
define void @I422ToYUY2Row_Any_NEON() {
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ uint8_t;
typedef scalar_t__ uint32_t;
typedef scalar_t__ int32_t;

/* Variables and functions */
uint8_t Count1s(int32_t LongWord) { return Count1s((uint32_t)LongWord); }


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

x86 assembly (clang, -O2):
<Count1s>:
jmp    1100 <Count1s>

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

LLVM IR (-O2):
define i32 @Count1s(i64 %0) {
br label %2
2: ; preds = %2, %1
br label %2
}
float dotvv(const float *s1, const float *s2) {
  return (float)(s1[0] * s2[0] + s1[1] * s2[1] + s1[2] * s2[2]);
}


x86 assembly (clang, -O0):
<dotvv>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
movss  (%rax),%xmm1
mov    -0x10(%rbp),%rax
movss  (%rax),%xmm2
mov    -0x8(%rbp),%rax
movss  0x4(%rax),%xmm0
mov    -0x10(%rbp),%rax
mulss  0x4(%rax),%xmm0
mulss  %xmm2,%xmm1
addss  %xmm0,%xmm1
mov    -0x8(%rbp),%rax
movss  0x8(%rax),%xmm0
mov    -0x10(%rbp),%rax
movss  0x8(%rax),%xmm2
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<dotvv>:
movss  0x4(%rdi),%xmm0
mulss  0x4(%rsi),%xmm0
movss  (%rdi),%xmm1
mulss  (%rsi),%xmm1
addss  %xmm0,%xmm1
movss  0x8(%rdi),%xmm0
mulss  0x8(%rsi),%xmm0
addss  %xmm1,%xmm0
ret

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

LLVM IR (-O2):
define float @dotvv(float* nocapture %0, float* nocapture %1) {
%3 = load float, float* %0
%4 = load float, float* %1
%5 = getelementptr inbounds float, float* %0, i64 1
%6 = load float, float* %5
%7 = getelementptr inbounds float, float* %1, i64 1
%8 = load float, float* %7
%9 = fmul float %6, %8
%10 = tail call float @llvm.fmuladd.f32(float %3, float %4, float %9)
%11 = getelementptr inbounds float, float* %0, i64 2
%12 = load float, float* %11
%13 = getelementptr inbounds float, float* %1, i64 2
%14 = load float, float* %13
%15 = tail call float @llvm.fmuladd.f32(float %12, float %14, float %10)
ret float %15
}
/* Variables and functions */
int /*<<< orphan*/ check_vect();
int /*<<< orphan*/ main1(float *);
int main(void) {
  int i;
  float a[256] __attribute__((__aligned__(16)));
  check_vect();
  main1(a);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x410,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0x0,%al
call   1030 <check_vect@plt>
lea    -0x410(%rbp),%rdi
call   1040 <main1@plt>
xor    %eax,%eax
add    $0x410,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
sub    $0x408,%rsp
xor    %eax,%eax
call   1030 <check_vect@plt>
mov    %rsp,%rdi
call   1040 <main1@plt>
xor    %eax,%eax
add    $0x408,%rsp
ret

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca [256 x float]
store i32 0, i32* %1
%4 = call i32 (...) @check_vect()
%5 = getelementptr inbounds [256 x float], [256 x float]* %3, i64 0, i64 0
%6 = call i32 @main1(float* %5)
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = alloca [256 x float]
%2 = bitcast [256 x float]* %1 to i8*
%3 = tail call i32 (...) @check_vect()
%4 = getelementptr inbounds [256 x float], [256 x float]* %1, i64 0, i64 0
%5 = call i32 @main1(float* %4)
ret i32 0
}
long f1(long a, long b) { return a == b; }


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

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

LLVM IR (-O0):
define i64 @f1(i64 %0, i64 %1) {
%3 = alloca i64
%4 = alloca i64
store i64 %0, i64* %3
store i64 %1, i64* %4
%5 = load i64, i64* %3
%6 = load i64, i64* %4
%7 = icmp eq i64 %5, %6
%8 = zext i1 %7 to i32
%9 = sext i32 %8 to i64
ret i64 %9
}

LLVM IR (-O2):
define i64 @f1(i64 %0, i64 %1) {
%3 = icmp eq i64 %0, %1
%4 = zext i1 %3 to i64
ret i64 %4
}
/* Type definitions */
typedef int /*<<< orphan*/ XFocusOutEvent;

/* Variables and functions */
int /*<<< orphan*/ abort();
scalar_t__ malloc(int);
void *alloc_XFocusOutEvent(void) {
  XFocusOutEvent *_p = (XFocusOutEvent *)malloc(sizeof(XFocusOutEvent));
  if (_p == NULL)
    abort();
  return (void *)_p;
}


x86 assembly (clang, -O0):
<alloc_XFocusOutEvent>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x4,%edi
call   1040 <malloc@plt>
mov    %rax,-0x8(%rbp)
cmpq   $0x0,-0x8(%rbp)
jne    1148 <alloc_XFocusOutEvent+0x28>
mov    $0x0,%al
call   1030 <abort@plt>
mov    -0x8(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<alloc_XFocusOutEvent>:
push   %rax
mov    $0x4,%edi
call   1040 <malloc@plt>
test   %rax,%rax
je     1132 <alloc_XFocusOutEvent+0x12>
pop    %rcx
ret
xor    %eax,%eax
call   1030 <abort@plt>

LLVM IR (-O0):
define i8* @alloc_XFocusOutEvent() {
%1 = alloca i32*
%2 = call i64 @malloc(i32 4)
%3 = inttoptr i64 %2 to i32*
store i32* %3, i32** %1
%4 = load i32*, i32** %1
%5 = icmp eq i32* %4, null
br i1 %5, label %6, label %8
6: ; preds = %0
%7 = call i32 (...) @abort()
unreachable
8: ; preds = %0
%9 = load i32*, i32** %1
%10 = bitcast i32* %9 to i8*
ret i8* %10
}

LLVM IR (-O2):
define i8* @alloc_XFocusOutEvent() {
%1 = tail call i64 @malloc(i32 4)
%2 = icmp eq i64 %1, 0
br i1 %2, label %3, label %5
3: ; preds = %0
%4 = tail call i32 (...) @abort()
unreachable
5: ; preds = %0
%6 = inttoptr i64 %1 to i8*
ret i8* %6
}
/* Type definitions */
typedef int /*<<< orphan*/ mpfr_t;
typedef int /*<<< orphan*/ mpfr_prec_t;

/* Variables and functions */
int /*<<< orphan*/ createArray(int /*<<< orphan*/ **, size_t const,
                               int /*<<< orphan*/ const);
void allocateArrays(const size_t matrixSize, const mpfr_prec_t precision,
                    const int nbGradientIterations, mpfr_t **adk,
                    mpfr_t **gkgk2save, mpfr_t **dkTmp) {
  createArray(adk, matrixSize, precision);
  createArray(gkgk2save, nbGradientIterations, precision);
  createArray(dkTmp, matrixSize, precision);
}


x86 assembly (clang, -O0):
<allocateArrays>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %edx,-0x10(%rbp)
mov    %rcx,-0x18(%rbp)
mov    %r8,-0x20(%rbp)
mov    %r9,-0x28(%rbp)
mov    -0x18(%rbp),%rdi
mov    -0x8(%rbp),%rsi
mov    -0xc(%rbp),%edx
call   1030 <createArray@plt>
mov    -0x20(%rbp),%rdi
movslq -0x10(%rbp),%rsi
mov    -0xc(%rbp),%edx
call   1030 <createArray@plt>
mov    -0x28(%rbp),%rdi
mov    -0x8(%rbp),%rsi
mov    -0xc(%rbp),%edx
call   1030 <createArray@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<allocateArrays>:
push   %rbp
push   %r15
push   %r14
push   %r12
push   %rbx
mov    %r9,%r14
mov    %r8,%r15
mov    %edx,%r12d
mov    %esi,%ebx
mov    %rdi,%rbp
mov    %rcx,%rdi
mov    %rbp,%rsi
mov    %ebx,%edx
call   1030 <createArray@plt>
movslq %r12d,%rsi
mov    %r15,%rdi
mov    %ebx,%edx
call   1030 <createArray@plt>
mov    %r14,%rdi
mov    %rbp,%rsi
mov    %ebx,%edx
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
pop    %rbp
jmp    1030 <createArray@plt>

LLVM IR (-O0):
define void @allocateArrays(i64 %0, i32 %1, i32 %2, i32** %3, i32** %4, i32** %5) {
%7 = alloca i64
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32**
%11 = alloca i32**
%12 = alloca i32**
store i64 %0, i64* %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
%13 = load i32**, i32*** %10
%14 = load i64, i64* %7
%15 = load i32, i32* %8
%16 = call i32 @createArray(i32** %13, i64 %14, i32 %15)
%17 = load i32**, i32*** %11
%18 = load i32, i32* %9
%19 = sext i32 %18 to i64
%20 = load i32, i32* %8
%21 = call i32 @createArray(i32** %17, i64 %19, i32 %20)
%22 = load i32**, i32*** %12
%23 = load i64, i64* %7
%24 = load i32, i32* %8
%25 = call i32 @createArray(i32** %22, i64 %23, i32 %24)
ret void
}

LLVM IR (-O2):
define void @allocateArrays(i64 %0, i32 %1, i32 %2, i32** %3, i32** %4, i32** %5) {
%7 = tail call i32 @createArray(i32** %3, i64 %0, i32 %1)
%8 = sext i32 %2 to i64
%9 = tail call i32 @createArray(i32** %4, i64 %8, i32 %1)
%10 = tail call i32 @createArray(i32** %5, i64 %0, i32 %1)
ret void
}
const char *mugglec_compile_time() {
  return "Mar 15 2022"
         " "
         "14:45:02";
}


x86 assembly (clang, -O0):
<mugglec_compile_time>:
push   %rbp
mov    %rsp,%rbp
lea    0xef5(%rip),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<mugglec_compile_time>:
lea    0xef9(%rip),%rax
ret

LLVM IR (-O0):
@.str = [21 x i8] c"Mar 15 2022 14:45:02\00"
define i8* @mugglec_compile_time() {
ret i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0)
}

LLVM IR (-O2):
@.str = [21 x i8] c"Mar 15 2022 14:45:02\00"
define i8* @mugglec_compile_time() {
ret i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0)
}
/* Variables and functions */
size_t ft_strlen(const char *s) {
  size_t i;
  i = 0;
  if (!s)
    return (0);
  while (s[i])
    i++;
  return (i);
}


x86 assembly (clang, -O0):
<ft_strlen>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x10(%rbp)
movq   $0x0,-0x18(%rbp)
cmpq   $0x0,-0x10(%rbp)
jne    1128 <ft_strlen+0x28>
movq   $0x0,-0x8(%rbp)
jmp    1158 <ft_strlen+0x58>
jmp    112d <ft_strlen+0x2d>
mov    -0x10(%rbp),%rax
mov    -0x18(%rbp),%rcx
cmpb   $0x0,(%rax,%rcx,1)
je     1150 <ft_strlen+0x50>
mov    -0x18(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x18(%rbp)
jmp    112d <ft_strlen+0x2d>
mov    -0x18(%rbp),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<ft_strlen>:
test   %rdi,%rdi
je     111f <ft_strlen+0x1f>
mov    $0xffffffffffffffff,%rcx
nopl   0x0(%rax)
lea    0x1(%rcx),%rax
cmpb   $0x0,0x1(%rdi,%rcx,1)
mov    %rax,%rcx
jne    1110 <ft_strlen+0x10>
ret
xor    %eax,%eax
ret

LLVM IR (-O0):
define i64 @ft_strlen(i8* %0) {
%2 = alloca i64
%3 = alloca i8*
%4 = alloca i64
store i8* %0, i8** %3
store i64 0, i64* %4
%5 = load i8*, i8** %3
%6 = icmp ne i8* %5, null
br i1 %6, label %8, label %7
7: ; preds = %1
store i64 0, i64* %2
br label %20
8: ; preds = %1
br label %9
9: ; preds = %15, %8
%10 = load i8*, i8** %3
%11 = load i64, i64* %4
%12 = getelementptr inbounds i8, i8* %10, i64 %11
%13 = load i8, i8* %12
%14 = icmp ne i8 %13, 0
br i1 %14, label %15, label %18
15: ; preds = %9
%16 = load i64, i64* %4
%17 = add i64 %16, 1
store i64 %17, i64* %4
br label %9
18: ; preds = %9
%19 = load i64, i64* %4
store i64 %19, i64* %2
br label %20
20: ; preds = %18, %7
%21 = load i64, i64* %2
ret i64 %21
}

LLVM IR (-O2):
define i64 @ft_strlen(i8* %0) {
%2 = icmp eq i8* %0, null
br i1 %2, label %9, label %3
3: ; preds = %1, %3
%4 = phi i64 [ %8, %3 ], [ 0, %1 ]
%5 = getelementptr inbounds i8, i8* %0, i64 %4
%6 = load i8, i8* %5
%7 = icmp eq i8 %6, 0
%8 = add i64 %4, 1
br i1 %7, label %9, label %3
9: ; preds = %3, %1
%10 = phi i64 [ 0, %1 ], [ %4, %3 ]
ret i64 %10
}
/* Type definitions */
typedef int /*<<< orphan*/ uint32_t;

/* Variables and functions */
void delayMicroseconds(uint32_t us) {}


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

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

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

LLVM IR (-O2):
define void @delayMicroseconds(i32 %0) {
ret void
}
/* Variables and functions */
int fileGetc();
int parseEscapedCharacter();
int /*<<< orphan*/ skipToCharacter(char);
int parseCharacter(void) {
  int c = fileGetc();
  int result = c;
  if (c == '%')
    result = parseEscapedCharacter();
  c = fileGetc();
  if (c != '\'')
    skipToCharacter('\n');
  return result;
}


x86 assembly (clang, -O0):
<parseCharacter>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x0,%al
call   1040 <fileGetc@plt>
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
mov    %eax,-0x8(%rbp)
cmpl   $0x25,-0x4(%rbp)
jne    115c <parseCharacter+0x2c>
mov    $0x0,%al
call   1030 <parseEscapedCharacter@plt>
mov    %eax,-0x8(%rbp)
mov    $0x0,%al
call   1040 <fileGetc@plt>
mov    %eax,-0x4(%rbp)
cmpl   $0x27,-0x4(%rbp)
je     117a <parseCharacter+0x4a>
mov    $0xa,%edi
call   1050 <skipToCharacter@plt>
mov    -0x8(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<parseCharacter>:
push   %rbx
xor    %eax,%eax
call   1040 <fileGetc@plt>
mov    %eax,%ebx
cmp    $0x25,%eax
jne    1148 <parseCharacter+0x18>
xor    %eax,%eax
call   1030 <parseEscapedCharacter@plt>
mov    %eax,%ebx
xor    %eax,%eax
call   1040 <fileGetc@plt>
cmp    $0x27,%eax
je     115e <parseCharacter+0x2e>
mov    $0xa,%edi
call   1050 <skipToCharacter@plt>
mov    %ebx,%eax
pop    %rbx
ret

LLVM IR (-O0):
define i32 @parseCharacter() {
%1 = alloca i32
%2 = alloca i32
%3 = call i32 (...) @fileGetc()
store i32 %3, i32* %1
%4 = load i32, i32* %1
store i32 %4, i32* %2
%5 = load i32, i32* %1
%6 = icmp eq i32 %5, 37
br i1 %6, label %7, label %9
7: ; preds = %0
%8 = call i32 (...) @parseEscapedCharacter()
store i32 %8, i32* %2
br label %9
9: ; preds = %7, %0
%10 = call i32 (...) @fileGetc()
store i32 %10, i32* %1
%11 = load i32, i32* %1
%12 = icmp ne i32 %11, 39
br i1 %12, label %13, label %15
13: ; preds = %9
%14 = call i32 @skipToCharacter(i8 signext 10)
br label %15
15: ; preds = %13, %9
%16 = load i32, i32* %2
ret i32 %16
}

LLVM IR (-O2):
define i32 @parseCharacter() {
%1 = tail call i32 (...) @fileGetc()
%2 = icmp eq i32 %1, 37
br i1 %2, label %3, label %5
3: ; preds = %0
%4 = tail call i32 (...) @parseEscapedCharacter()
br label %5
5: ; preds = %3, %0
%6 = phi i32 [ %4, %3 ], [ %1, %0 ]
%7 = tail call i32 (...) @fileGetc()
%8 = icmp eq i32 %7, 39
br i1 %8, label %11, label %9
9: ; preds = %5
%10 = tail call i32 @skipToCharacter(i8 signext 10)
br label %11
11: ; preds = %9, %5
ret i32 %6
}