xunge/DecIR huggingface dataset:
/* Variables and functions */
unsigned int get_auxv_pagesize();
unsigned int gotcha_getpagesize() {
  static unsigned int pagesz = 0;
  if (pagesz)
    return pagesz;
  pagesz = get_auxv_pagesize();
  if (!pagesz)
    pagesz = 4096;
  return pagesz;
}


x86 assembly (clang, -O0):
<gotcha_getpagesize>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
cmpl   $0x0,0x2f0d(%rip)
je     1133 <gotcha_getpagesize+0x23>
mov    0x2f01(%rip),%eax
mov    %eax,-0x4(%rbp)
jmp    1160 <gotcha_getpagesize+0x50>
mov    $0x0,%al
call   1030 <get_auxv_pagesize@plt>
mov    %eax,0x2eec(%rip)
cmpl   $0x0,0x2ee5(%rip)
jne    1157 <gotcha_getpagesize+0x47>
movl   $0x1000,0x2ed5(%rip)
mov    0x2ecf(%rip),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<gotcha_getpagesize>:
push   %rax
mov    0x2f15(%rip),%eax
test   %eax,%eax
je     111d <gotcha_getpagesize+0xd>
pop    %rcx
ret
xor    %eax,%eax
call   1030 <get_auxv_pagesize@plt>
mov    %eax,%ecx
test   %eax,%eax
mov    $0x1000,%eax
cmovne %ecx,%eax
mov    %eax,0x2ef6(%rip)
pop    %rcx
ret

LLVM IR (-O0):
@gotcha_getpagesize.pagesz = internal global i32 0
define i32 @gotcha_getpagesize() {
%1 = alloca i32
%2 = load i32, i32* @gotcha_getpagesize.pagesz
%3 = icmp ne i32 %2, 0
br i1 %3, label %4, label %6
4: ; preds = %0
%5 = load i32, i32* @gotcha_getpagesize.pagesz
store i32 %5, i32* %1
br label %13
6: ; preds = %0
%7 = call i32 (...) @get_auxv_pagesize()
store i32 %7, i32* @gotcha_getpagesize.pagesz
%8 = load i32, i32* @gotcha_getpagesize.pagesz
%9 = icmp ne i32 %8, 0
br i1 %9, label %11, label %10
10: ; preds = %6
store i32 4096, i32* @gotcha_getpagesize.pagesz
br label %11
11: ; preds = %10, %6
%12 = load i32, i32* @gotcha_getpagesize.pagesz
store i32 %12, i32* %1
br label %13
13: ; preds = %11, %4
%14 = load i32, i32* %1
ret i32 %14
}

LLVM IR (-O2):
@gotcha_getpagesize.pagesz = internal unnamed_addr global i32 0
define i32 @gotcha_getpagesize() {
%1 = load i32, i32* @gotcha_getpagesize.pagesz
%2 = icmp eq i32 %1, 0
br i1 %2, label %3, label %7
3: ; preds = %0
%4 = tail call i32 (...) @get_auxv_pagesize()
%5 = icmp eq i32 %4, 0
%6 = select i1 %5, i32 4096, i32 %4
store i32 %6, i32* @gotcha_getpagesize.pagesz
br label %7
7: ; preds = %0, %3
%8 = phi i32 [ %6, %3 ], [ %1, %0 ]
ret i32 %8
}
unsigned int getNextPid() { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @getNextPid() {
ret i32 0
}
void pm_autosleep_unlock(void) {}


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

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

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

LLVM IR (-O2):
define void @pm_autosleep_unlock() {
ret void
}
/* Variables and functions */
int strlen(char *);
void mycpy(char *dst, char *src) {
  if (strlen(src) < 16 - 1)
    while (*src)
      *dst++ = *src++;
  *dst = '\x00';
}


x86 assembly (clang, -O0):
<mycpy>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
call   1030 <strlen@plt>
cmp    $0xf,%eax
jge    1170 <mycpy+0x60>
jmp    1137 <mycpy+0x27>
mov    -0x10(%rbp),%rax
cmpb   $0x0,(%rax)
je     116b <mycpy+0x5b>
mov    -0x10(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x10(%rbp)
mov    (%rax),%cl
mov    -0x8(%rbp),%rax
mov    %rax,%rdx
add    $0x1,%rdx
mov    %rdx,-0x8(%rbp)
mov    %cl,(%rax)
jmp    1137 <mycpy+0x27>
jmp    1170 <mycpy+0x60>
mov    -0x8(%rbp),%rax
movb   $0x0,(%rax)
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<mycpy>:
push   %r14
push   %rbx
push   %rax
mov    %rsi,%rbx
mov    %rdi,%r14
mov    %rsi,%rdi
call   1030 <strlen@plt>
cmp    $0xe,%eax
jg     1152 <mycpy+0x42>
mov    (%rbx),%al
test   %al,%al
je     1152 <mycpy+0x42>
add    $0x1,%rbx
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
mov    %al,(%r14)
add    $0x1,%r14
movzbl (%rbx),%eax
add    $0x1,%rbx
test   %al,%al
jne    1140 <mycpy+0x30>
movb   $0x0,(%r14)
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

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

LLVM IR (-O2):
define void @mycpy(i8* nocapture writeonly %0, i8* %1) {
%3 = tail call i32 @strlen(i8* %1)
%4 = icmp slt i32 %3, 15
br i1 %4, label %5, label %16
5: ; preds = %2
%6 = load i8, i8* %1
%7 = icmp eq i8 %6, 0
br i1 %7, label %16, label %8
8: ; preds = %5, %8
%9 = phi i8 [ %14, %8 ], [ %6, %5 ]
%10 = phi i8* [ %12, %8 ], [ %1, %5 ]
%11 = phi i8* [ %13, %8 ], [ %0, %5 ]
%12 = getelementptr inbounds i8, i8* %10, i64 1
%13 = getelementptr inbounds i8, i8* %11, i64 1
store i8 %9, i8* %11
%14 = load i8, i8* %12
%15 = icmp eq i8 %14, 0
br i1 %15, label %16, label %8
16: ; preds = %8, %5, %2
%17 = phi i8* [ %0, %2 ], [ %0, %5 ], [ %13, %8 ]
store i8 0, i8* %17
ret void
}
int fun1385() { return 1385; }


x86 assembly (clang, -O0):
<fun1385>:
push   %rbp
mov    %rsp,%rbp
mov    $0x569,%eax
pop    %rbp
ret

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

LLVM IR (-O0):
define i32 @fun1385() {
ret i32 1385
}

LLVM IR (-O2):
define i32 @fun1385() {
ret i32 1385
}
/* Variables and functions */
int fdatasync(int);
void test(void) {
  int fd;
  int result;
  fd = 4;
  result = fdatasync(fd);
}


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

x86 assembly (clang, -O2):
<test>:
mov    $0x4,%edi
jmp    1030 <fdatasync@plt>

LLVM IR (-O0):
define void @test() {
%1 = alloca i32
%2 = alloca i32
store i32 4, i32* %1
%3 = load i32, i32* %1
%4 = call i32 @fdatasync(i32 %3)
store i32 %4, i32* %2
ret void
}

LLVM IR (-O2):
define void @test() {
%1 = tail call i32 @fdatasync(i32 4)
ret void
}
void test_log_entries_appended() {}


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

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

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

LLVM IR (-O2):
define void @test_log_entries_appended() {
ret void
}
void pthread_equal() {}


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

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

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

LLVM IR (-O2):
define void @pthread_equal() {
ret void
}
double calCpuTime(double c0, double c1) {
  double wt;
  wt = c1 - c0;
  return wt;
}


x86 assembly (clang, -O0):
<calCpuTime>:
push   %rbp
mov    %rsp,%rbp
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
movsd  -0x10(%rbp),%xmm0
subsd  -0x8(%rbp),%xmm0
movsd  %xmm0,-0x18(%rbp)
movsd  -0x18(%rbp),%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<calCpuTime>:
subsd  %xmm0,%xmm1
movapd %xmm1,%xmm0
ret

LLVM IR (-O0):
define double @calCpuTime(double %0, double %1) {
%3 = alloca double
%4 = alloca double
%5 = alloca double
store double %0, double* %3
store double %1, double* %4
%6 = load double, double* %4
%7 = load double, double* %3
%8 = fsub double %6, %7
store double %8, double* %5
%9 = load double, double* %5
ret double %9
}

LLVM IR (-O2):
define double @calCpuTime(double %0, double %1) {
%3 = fsub double %1, %0
ret double %3
}
int Min(const int a, const int b) { return ((a < b) ? a : b); }


x86 assembly (clang, -O0):
<Min>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x4(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    1121 <Min+0x21>
mov    -0x4(%rbp),%eax
mov    %eax,-0xc(%rbp)
jmp    1127 <Min+0x27>
mov    -0x8(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<Min>:
mov    %esi,%eax
cmp    %esi,%edi
cmovl  %edi,%eax
ret

LLVM IR (-O0):
define i32 @Min(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 = icmp slt i32 %5, %6
br i1 %7, label %8, label %10
8: ; preds = %2
%9 = load i32, i32* %3
br label %12
10: ; preds = %2
%11 = load i32, i32* %4
br label %12
12: ; preds = %10, %8
%13 = phi i32 [ %9, %8 ], [ %11, %10 ]
ret i32 %13
}

LLVM IR (-O2):
define i32 @Min(i32 %0, i32 %1) {
%3 = icmp slt i32 %0, %1
%4 = select i1 %3, i32 %0, i32 %1
ret i32 %4
}
/* Type definitions */
typedef unsigned char value;
typedef int u_int16_t;

/* Variables and functions */
unsigned char *serialize_u_int16_t(unsigned char *buffer, u_int16_t value) {
  buffer[0] = (value >> 8) & 0xFF;
  buffer[1] = (value)&0xFF;
  return buffer + 2;
}


x86 assembly (clang, -O0):
<serialize_u_int16_t>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0xc(%rbp),%eax
sar    $0x8,%eax
and    $0xff,%eax
mov    %al,%cl
mov    -0x8(%rbp),%rax
mov    %cl,(%rax)
mov    -0xc(%rbp),%eax
and    $0xff,%eax
mov    %al,%cl
mov    -0x8(%rbp),%rax
mov    %cl,0x1(%rax)
mov    -0x8(%rbp),%rax
add    $0x2,%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<serialize_u_int16_t>:
rol    $0x8,%si
mov    %si,(%rdi)
lea    0x2(%rdi),%rax
ret

LLVM IR (-O0):
define i8* @serialize_u_int16_t(i8* %0, i32 %1) {
%3 = alloca i8*
%4 = alloca i32
store i8* %0, i8** %3
store i32 %1, i32* %4
%5 = load i32, i32* %4
%6 = ashr i32 %5, 8
%7 = and i32 %6, 255
%8 = trunc i32 %7 to i8
%9 = load i8*, i8** %3
%10 = getelementptr inbounds i8, i8* %9, i64 0
store i8 %8, i8* %10
%11 = load i32, i32* %4
%12 = and i32 %11, 255
%13 = trunc i32 %12 to i8
%14 = load i8*, i8** %3
%15 = getelementptr inbounds i8, i8* %14, i64 1
store i8 %13, i8* %15
%16 = load i8*, i8** %3
%17 = getelementptr inbounds i8, i8* %16, i64 2
ret i8* %17
}

LLVM IR (-O2):
define i8* @serialize_u_int16_t(i8* writeonly %0, i32 %1) {
%3 = lshr i32 %1, 8
%4 = trunc i32 %3 to i8
store i8 %4, i8* %0
%5 = trunc i32 %1 to i8
%6 = getelementptr inbounds i8, i8* %0, i64 1
store i8 %5, i8* %6
%7 = getelementptr inbounds i8, i8* %0, i64 2
ret i8* %7
}
/* Variables and functions */
int /*<<< orphan*/ hl_alloc_strbytes(char *);
int /*<<< orphan*/ hl_throw(int /*<<< orphan*/);
__attribute__((optimize("-O0"))) void hl_assert() {
  ;
  hl_throw(hl_alloc_strbytes(u"assert"));
}


x86 assembly (clang, -O0):
<hl_assert>:
push   %rbp
mov    %rsp,%rbp
lea    0xed5(%rip),%rdi
call   1040 <hl_alloc_strbytes@plt>
mov    %eax,%edi
call   1030 <hl_throw@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<hl_assert>:
push   %rax
lea    0xed8(%rip),%rdi
call   1040 <hl_alloc_strbytes@plt>
mov    %eax,%edi
pop    %rax
jmp    1030 <hl_throw@plt>

LLVM IR (-O0):
@.str = [7 x i16] [i16 97, i16 115, i16 115, i16 101, i16 114, i16 116, i16 0]
define void @hl_assert() {
%1 = call i32 @hl_alloc_strbytes(i8* bitcast ([7 x i16]* @.str to i8*))
%2 = call i32 @hl_throw(i32 %1)
ret void
}

LLVM IR (-O2):
@.str = [7 x i16] [i16 97, i16 115, i16 115, i16 101, i16 114, i16 116, i16 0]
define void @hl_assert() {
%1 = tail call i32 @hl_alloc_strbytes(i8* bitcast ([7 x i16]* @.str to i8*))
%2 = tail call i32 @hl_throw(i32 %1)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ MAIN__();
int cblat1_() {
  MAIN__();
  return 0;
}


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

x86 assembly (clang, -O2):
<cblat1_>:
push   %rax
xor    %eax,%eax
call   1030 <MAIN__@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @cblat1_() {
%1 = call i32 (...) @MAIN__()
ret i32 0
}

LLVM IR (-O2):
define i32 @cblat1_() {
%1 = tail call i32 (...) @MAIN__()
ret i32 0
}
/* Variables and functions */
double percentile_weight_nocopy_double(int, double *, double *, double);
double percentile_weight_nocopy(int n, double *data, double *err, double pct) {
  return percentile_weight_nocopy_double(n, data, err, pct);
}


x86 assembly (clang, -O0):
<percentile_weight_nocopy>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
movsd  %xmm0,-0x20(%rbp)
mov    -0x4(%rbp),%edi
mov    -0x10(%rbp),%rsi
mov    -0x18(%rbp),%rdx
movsd  -0x20(%rbp),%xmm0
call   1030 <percentile_weight_nocopy_double@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<percentile_weight_nocopy>:
jmp    1030 <percentile_weight_nocopy_double@plt>

LLVM IR (-O0):
define double @percentile_weight_nocopy(i32 %0, double* %1, double* %2, double %3) {
%5 = alloca i32
%6 = alloca double*
%7 = alloca double*
%8 = alloca double
store i32 %0, i32* %5
store double* %1, double** %6
store double* %2, double** %7
store double %3, double* %8
%9 = load i32, i32* %5
%10 = load double*, double** %6
%11 = load double*, double** %7
%12 = load double, double* %8
%13 = call double @percentile_weight_nocopy_double(i32 %9, double* %10, double* %11, double %12)
ret double %13
}

LLVM IR (-O2):
define double @percentile_weight_nocopy(i32 %0, double* %1, double* %2, double %3) {
%5 = tail call double @percentile_weight_nocopy_double(i32 %0, double* %1, double* %2, double %3)
ret double %5
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
int main(int argc, char **args) {
  printf("Example program running.\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 = [26 x i8] c"Example program running.\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 ([26 x i8], [26 x i8]* @.str, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@str = [25 x i8] c"Example program running.\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([25 x i8], [25 x i8]* @str, i64 0, i64 0))
ret i32 0
}
void ff_hevc_put_hevc_qpel_h32_12_sse4() {}


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

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

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

LLVM IR (-O2):
define void @ff_hevc_put_hevc_qpel_h32_12_sse4() {
ret void
}
/* Type definitions */
struct list_head {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ lex_tests(struct list_head *);
int /*<<< orphan*/ radix_tree_tests(struct list_head *);
void register_all_tests(struct list_head *suites) {
  lex_tests(suites);
  radix_tree_tests(suites);
}


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

x86 assembly (clang, -O2):
<register_all_tests>:
push   %rbx
mov    %rdi,%rbx
call   1030 <lex_tests@plt>
mov    %rbx,%rdi
pop    %rbx
jmp    1040 <radix_tree_tests@plt>

LLVM IR (-O0):
%struct.list_head = type { i32 }
define void @register_all_tests(%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 @lex_tests(%struct.list_head* %3)
%5 = load %struct.list_head*, %struct.list_head** %2
%6 = call i32 @radix_tree_tests(%struct.list_head* %5)
ret void
}

LLVM IR (-O2):
%struct.list_head = type { i32 }
define void @register_all_tests(%struct.list_head* %0) {
%2 = tail call i32 @lex_tests(%struct.list_head* %0)
%3 = tail call i32 @radix_tree_tests(%struct.list_head* %0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ GPIO_SET_GPFSEL(int, int);
void gpio_init(void) {
  GPIO_SET_GPFSEL(16, 1);
  GPIO_SET_GPFSEL(19, 1);
}


x86 assembly (clang, -O0):
<gpio_init>:
push   %rbp
mov    %rsp,%rbp
mov    $0x10,%edi
mov    $0x1,%esi
call   1030 <GPIO_SET_GPFSEL@plt>
mov    $0x13,%edi
mov    $0x1,%esi
call   1030 <GPIO_SET_GPFSEL@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<gpio_init>:
push   %rax
mov    $0x10,%edi
mov    $0x1,%esi
call   1030 <GPIO_SET_GPFSEL@plt>
mov    $0x13,%edi
mov    $0x1,%esi
pop    %rax
jmp    1030 <GPIO_SET_GPFSEL@plt>

LLVM IR (-O0):
define void @gpio_init() {
%1 = call i32 @GPIO_SET_GPFSEL(i32 16, i32 1)
%2 = call i32 @GPIO_SET_GPFSEL(i32 19, i32 1)
ret void
}

LLVM IR (-O2):
define void @gpio_init() {
%1 = tail call i32 @GPIO_SET_GPFSEL(i32 16, i32 1)
%2 = tail call i32 @GPIO_SET_GPFSEL(i32 19, i32 1)
ret void
}
void ErasePersistentArea() {}


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

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

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

LLVM IR (-O2):
define void @ErasePersistentArea() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ menu(int);
void key(unsigned char key, int x, int y) { menu((int)key); }


x86 assembly (clang, -O0):
<key>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %dil,%al
mov    %al,-0x1(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
movzbl -0x1(%rbp),%edi
call   1030 <menu@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<key>:
jmp    1030 <menu@plt>

LLVM IR (-O0):
define void @key(i8 zeroext %0, i32 %1, i32 %2) {
%4 = alloca i8
%5 = alloca i32
%6 = alloca i32
store i8 %0, i8* %4
store i32 %1, i32* %5
store i32 %2, i32* %6
%7 = load i8, i8* %4
%8 = zext i8 %7 to i32
%9 = call i32 @menu(i32 %8)
ret void
}

LLVM IR (-O2):
define void @key(i8 zeroext %0, i32 %1, i32 %2) {
%4 = zext i8 %0 to i32
%5 = tail call i32 @menu(i32 %4)
ret void
}
/* Variables and functions */
int _ada_use_c2pieri(int, int *, int *, double *);
int initialize_dimensions(int m, int p, int q) {
  int fail, mpq[3];
  int *b;
  double *c;
  mpq[0] = m;
  mpq[1] = p;
  mpq[2] = q;
  fail = _ada_use_c2pieri(1, mpq, b, c);
  return fail;
}


x86 assembly (clang, -O0):
<initialize_dimensions>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    -0x4(%rbp),%eax
mov    %eax,-0x1c(%rbp)
mov    -0x8(%rbp),%eax
mov    %eax,-0x18(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x14(%rbp)
lea    -0x1c(%rbp),%rsi
mov    -0x28(%rbp),%rdx
mov    -0x30(%rbp),%rcx
mov    $0x1,%edi
call   1030 <_ada_use_c2pieri@plt>
mov    %eax,-0x10(%rbp)
mov    -0x10(%rbp),%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<initialize_dimensions>:
sub    $0x18,%rsp
mov    %edi,0xc(%rsp)
mov    %esi,0x10(%rsp)
mov    %edx,0x14(%rsp)
lea    0xc(%rsp),%rsi
mov    $0x1,%edi
call   1030 <_ada_use_c2pieri@plt>
add    $0x18,%rsp
ret

LLVM IR (-O0):
define i32 @initialize_dimensions(i32 %0, i32 %1, i32 %2) {
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca [3 x i32]
%9 = alloca i32*
%10 = alloca double*
store i32 %0, i32* %4
store i32 %1, i32* %5
store i32 %2, i32* %6
%11 = load i32, i32* %4
%12 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 0
store i32 %11, i32* %12
%13 = load i32, i32* %5
%14 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 1
store i32 %13, i32* %14
%15 = load i32, i32* %6
%16 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 2
store i32 %15, i32* %16
%17 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 0
%18 = load i32*, i32** %9
%19 = load double*, double** %10
%20 = call i32 @_ada_use_c2pieri(i32 1, i32* %17, i32* %18, double* %19)
store i32 %20, i32* %7
%21 = load i32, i32* %7
ret i32 %21
}

LLVM IR (-O2):
define i32 @initialize_dimensions(i32 %0, i32 %1, i32 %2) {
%4 = alloca [3 x i32]
%5 = bitcast [3 x i32]* %4 to i8*
%6 = getelementptr inbounds [3 x i32], [3 x i32]* %4, i64 0, i64 0
store i32 %0, i32* %6
%7 = getelementptr inbounds [3 x i32], [3 x i32]* %4, i64 0, i64 1
store i32 %1, i32* %7
%8 = getelementptr inbounds [3 x i32], [3 x i32]* %4, i64 0, i64 2
store i32 %2, i32* %8
%9 = call i32 @_ada_use_c2pieri(i32 1, i32* %6, i32* undef, double* undef)
ret i32 %9
}
/* Variables and functions */
int EXIT_FAILURE;
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, char *);
int /*<<< orphan*/ stderr;
int failExit(char *s) {
  fprintf(stderr, "%s\n", s);
  return EXIT_FAILURE;
}


x86 assembly (clang, -O0):
<failExit>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    0x2ebd(%rip),%rax
mov    (%rax),%edi
mov    -0x8(%rbp),%rdx
lea    0xed0(%rip),%rsi
call   1030 <fprintf@plt>
mov    0x2e9c(%rip),%rax
mov    (%rax),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<failExit>:
push   %rax
mov    %rdi,%rdx
mov    0x2ec5(%rip),%rax
mov    (%rax),%edi
lea    0xedc(%rip),%rsi
call   1030 <fprintf@plt>
mov    0x2ea8(%rip),%rax
mov    (%rax),%eax
pop    %rcx
ret

LLVM IR (-O0):
@stderr = global i32 0
@.str = [4 x i8] c"%s\0A\00"
@EXIT_FAILURE = global i32 0
define i32 @failExit(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i32, i32* @stderr
%4 = load i8*, i8** %2
%5 = call i32 @fprintf(i32 %3, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* %4)
%6 = load i32, i32* @EXIT_FAILURE
ret i32 %6
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [4 x i8] c"%s\0A\00"
@EXIT_FAILURE = global i32 0
define i32 @failExit(i8* %0) {
%2 = load i32, i32* @stderr
%3 = tail call i32 @fprintf(i32 %2, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* %0)
%4 = load i32, i32* @EXIT_FAILURE
ret i32 %4
}
/* Variables and functions */
int /*<<< orphan*/ fusione();
int /*<<< orphan*/ stampa();
int /*<<< orphan*/ system(char *);
int main(void) {
  fusione();
  stampa();
  system("pause");
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0x0,%al
call   1050 <fusione@plt>
mov    $0x0,%al
call   1040 <stampa@plt>
lea    0xeac(%rip),%rdi
call   1030 <system@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
xor    %eax,%eax
call   1050 <fusione@plt>
xor    %eax,%eax
call   1040 <stampa@plt>
lea    0xeba(%rip),%rdi
call   1030 <system@plt>
xor    %eax,%eax
pop    %rcx
ret

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

LLVM IR (-O2):
@.str = [6 x i8] c"pause\00"
define i32 @main() {
%1 = tail call i32 (...) @fusione()
%2 = tail call i32 (...) @stampa()
%3 = tail call i32 @system(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
ret i32 0
}
/* Type definitions */
typedef int /*<<< orphan*/ mode_t;

/* Variables and functions */
int /*<<< orphan*/ mkdir(char *, int /*<<< orphan*/);
void c_mkdir_(char *path, mode_t *mode, int plen) { mkdir(path, *mode); }


x86 assembly (clang, -O0):
<c_mkdir_>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rax
mov    (%rax),%esi
call   1030 <mkdir@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<c_mkdir_>:
mov    (%rsi),%esi
jmp    1030 <mkdir@plt>

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

LLVM IR (-O2):
define void @c_mkdir_(i8* nocapture %0, i32* nocapture %1, i32 %2) {
%4 = load i32, i32* %1
%5 = tail call i32 @mkdir(i8* %0, i32 %4)
ret void
}
int valueset_shutdown(void) { return 0; }


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

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

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

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

/* Variables and functions */
int /*<<< orphan*/ SIG_SETMASK;
int /*<<< orphan*/ sigemptyset(int /*<<< orphan*/ *);
int /*<<< orphan*/ sigprocmask(int /*<<< orphan*/, int /*<<< orphan*/ *,
                               int /*<<< orphan*/);
void sigclearmask(void) {
  sigset_t set;
  sigemptyset(&set);
  sigprocmask(SIG_SETMASK, &set, 0);
}


x86 assembly (clang, -O0):
<sigclearmask>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
lea    -0x4(%rbp),%rdi
call   1040 <sigemptyset@plt>
mov    0x2eb0(%rip),%rax
mov    (%rax),%edi
lea    -0x4(%rbp),%rsi
xor    %edx,%edx
call   1030 <sigprocmask@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<sigclearmask>:
push   %rbx
sub    $0x10,%rsp
lea    0xc(%rsp),%rbx
mov    %rbx,%rdi
call   1040 <sigemptyset@plt>
mov    0x2eaf(%rip),%rax
mov    (%rax),%edi
mov    %rbx,%rsi
xor    %edx,%edx
call   1030 <sigprocmask@plt>
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@SIG_SETMASK = global i32 0
define void @sigclearmask() {
%1 = alloca i32
%2 = call i32 @sigemptyset(i32* %1)
%3 = load i32, i32* @SIG_SETMASK
%4 = call i32 @sigprocmask(i32 %3, i32* %1, i32 0)
ret void
}

LLVM IR (-O2):
@SIG_SETMASK = global i32 0
define void @sigclearmask() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
%3 = call i32 @sigemptyset(i32* %1)
%4 = load i32, i32* @SIG_SETMASK
%5 = call i32 @sigprocmask(i32 %4, i32* %1, i32 0)
ret void
}
unsigned int arch_get_random(void) { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @arch_get_random() {
ret i32 0
}
/* Type definitions */
struct daemon_session {
  int dummy;
};

/* Variables and functions */
int serve_reg_write(struct daemon_session *);
int serve_sata_write(struct daemon_session *dsess) {
  return serve_reg_write(dsess);
}


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

x86 assembly (clang, -O2):
<serve_sata_write>:
jmp    1030 <serve_reg_write@plt>

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

LLVM IR (-O2):
%struct.daemon_session = type { i32 }
define i32 @serve_sata_write(%struct.daemon_session* %0) {
%2 = tail call i32 @serve_reg_write(%struct.daemon_session* %0)
ret i32 %2
}
/* Forward declarations */
typedef struct TYPE_3__ TYPE_1__;

/* Type definitions */
struct TYPE_3__ {
  int quot;
  int rem;
};
typedef TYPE_1__ div_t;

/* Variables and functions */
div_t div(int numer, int denom) {
  div_t rc;
  rc.quot = numer / denom;
  rc.rem = numer % denom;
  return rc;
}


x86 assembly (clang, -O0):
<div>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0xc(%rbp)
mov    %esi,-0x10(%rbp)
mov    -0xc(%rbp),%eax
cltd
idivl  -0x10(%rbp)
mov    %eax,-0x8(%rbp)
mov    -0xc(%rbp),%eax
cltd
idivl  -0x10(%rbp)
mov    %edx,-0x4(%rbp)
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<div>:
mov    %edi,%eax
cltd
idiv   %esi
shl    $0x20,%rdx
or     %rdx,%rax
ret

LLVM IR (-O0):
%struct.TYPE_3__ = type { i32, i32 }
define i64 @div(i32 %0, i32 %1) {
%3 = alloca %struct.TYPE_3__
%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* %5
%8 = sdiv i32 %6, %7
%9 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %3, i32 0, i32 0
store i32 %8, i32* %9
%10 = load i32, i32* %4
%11 = load i32, i32* %5
%12 = srem i32 %10, %11
%13 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %3, i32 0, i32 1
store i32 %12, i32* %13
%14 = bitcast %struct.TYPE_3__* %3 to i64*
%15 = load i64, i64* %14
ret i64 %15
}

LLVM IR (-O2):
define i64 @div(i32 %0, i32 %1) {
%3 = sdiv i32 %0, %1
%4 = srem i32 %0, %1
%5 = zext i32 %4 to i64
%6 = shl nuw i64 %5, 32
%7 = zext i32 %3 to i64
%8 = or i64 %6, %7
ret i64 %8
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
void asmepilog() {
  printf("# contents of %%eax will be the exit code\n");
  printf("	leave\n");
  printf("	ret\n");
  printf("	.subsections_via_symbols\n");
}


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

x86 assembly (clang, -O2):
<asmepilog>:
push   %rax
lea    0xed8(%rip),%rdi
call   1040 <printf@plt>
lea    0xef7(%rip),%rdi
call   1030 <puts@plt>
lea    0xef2(%rip),%rdi
call   1030 <puts@plt>
lea    0xeeb(%rip),%rdi
pop    %rax
jmp    1030 <puts@plt>

LLVM IR (-O0):
@.str = [43 x i8] c"# contents of %%eax will be the exit code\0A\00"
@.str.1 = [8 x i8] c"\09leave\0A\00"
@.str.2 = [6 x i8] c"\09ret\0A\00"
@.str.3 = [27 x i8] c"\09.subsections_via_symbols\0A\00"
define void @asmepilog() {
%1 = call i32 @printf(i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str, i64 0, i64 0))
%2 = call i32 @printf(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0))
%3 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0))
%4 = call i32 @printf(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.3, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [43 x i8] c"# contents of %%eax will be the exit code\0A\00"
@str = [7 x i8] c"\09leave\00"
@str.4 = [5 x i8] c"\09ret\00"
@str.5 = [26 x i8] c"\09.subsections_via_symbols\00"
define void @asmepilog() {
%1 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([43 x i8], [43 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([7 x i8], [7 x i8]* @str, i64 0, i64 0))
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @str.4, i64 0, i64 0))
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([26 x i8], [26 x i8]* @str.5, i64 0, i64 0))
ret void
}
/* Type definitions */
typedef double GLfloat;

/* Variables and functions */
GLfloat inttofloat(int i) {
  GLfloat f = 0.0;
  GLfloat *fp;
  int *ip;
  fp = &f;
  ip = &i;
  *fp = *((GLfloat *)ip);
  return f;
}


x86 assembly (clang, -O0):
<inttofloat>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x10(%rbp)
lea    -0x10(%rbp),%rax
mov    %rax,-0x18(%rbp)
lea    -0x4(%rbp),%rax
mov    %rax,-0x20(%rbp)
mov    -0x20(%rbp),%rax
movsd  (%rax),%xmm0
mov    -0x18(%rbp),%rax
movsd  %xmm0,(%rax)
movsd  -0x10(%rbp),%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<inttofloat>:
mov    %edi,-0x8(%rsp)
movsd  -0x8(%rsp),%xmm0
ret

LLVM IR (-O0):
define double @inttofloat(i32 %0) {
%2 = alloca i32
%3 = alloca double
%4 = alloca double*
%5 = alloca i32*
store i32 %0, i32* %2
store double 0.000000e+00, double* %3
store double* %3, double** %4
store i32* %2, i32** %5
%6 = load i32*, i32** %5
%7 = bitcast i32* %6 to double*
%8 = load double, double* %7
%9 = load double*, double** %4
store double %8, double* %9
%10 = load double, double* %3
ret double %10
}

LLVM IR (-O2):
define double @inttofloat(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = bitcast i32* %2 to double*
%4 = load double, double* %3
ret double %4
}
/* Type definitions */
typedef int uint32_t;

/* Variables and functions */
uint32_t select_int8_t() { return 1 | (0 << 1); }


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

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

LLVM IR (-O0):
define i32 @select_int8_t() {
ret i32 1
}

LLVM IR (-O2):
define i32 @select_int8_t() {
ret i32 1
}
/* Variables and functions */
int is_first_in_group_Hop(size_t __tag) { return (__tag == (628)) ? 1 : 0; }


x86 assembly (clang, -O0):
<is_first_in_group_Hop>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdx
xor    %eax,%eax
mov    $0x1,%ecx
cmp    $0x274,%rdx
cmove  %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_first_in_group_Hop>:
xor    %eax,%eax
cmp    $0x274,%rdi
sete   %al
ret

LLVM IR (-O0):
define i32 @is_first_in_group_Hop(i64 %0) {
%2 = alloca i64
store i64 %0, i64* %2
%3 = load i64, i64* %2
%4 = icmp eq i64 %3, 628
%5 = zext i1 %4 to i64
%6 = select i1 %4, i32 1, i32 0
ret i32 %6
}

LLVM IR (-O2):
define i32 @is_first_in_group_Hop(i64 %0) {
%2 = icmp eq i64 %0, 628
%3 = zext i1 %2 to i32
ret i32 %3
}
/* Variables and functions */
int /*<<< orphan*/ EXIT_SUCCESS;
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ fputs(char *, int /*<<< orphan*/);
int /*<<< orphan*/ stdout;
void usage() {
  fputs("Usage: tail  [OPTION] [FILE]\n\n"
        "OPTIONS:\n"
        "  -v, --verbose                      print a message for every creat "
        "directory\n"
        "  -c  --bytes=[number of bytes]      print the last bytes. Use c "
        "[number of bytes]\n"
        "  -n  --lines=[number of lines]      print the last lines, Use n "
        "[number of bytes]\n"
        "    --help                           print this message and exit\n"
        "    --version                        print version and exit\n",
        stdout);
  exit(EXIT_SUCCESS);
}


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>
mov    0x2e98(%rip),%rax
mov    (%rax),%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>
mov    0x2e9b(%rip),%rax
mov    (%rax),%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@.str = [410 x i8] c"Usage: tail [OPTION] [FILE]\0A\0AOPTIONS:\0A -v, --verbose print a message for every creat directory\0A -c --bytes=[number of bytes] print the last bytes. Use c [number of bytes]\0A -n --lines=[number of lines] print the last lines, Use n [number of bytes]\0A --help print this message and exit\0A --version print version and exit\0A\00"
@stdout = global i32 0
@EXIT_SUCCESS = global i32 0
define void @usage() {
%1 = load i32, i32* @stdout
%2 = call i32 @fputs(i8* getelementptr inbounds ([410 x i8], [410 x i8]* @.str, i64 0, i64 0), i32 %1)
%3 = load i32, i32* @EXIT_SUCCESS
%4 = call i32 @exit(i32 %3)
unreachable
}

LLVM IR (-O2):
@.str = [410 x i8] c"Usage: tail [OPTION] [FILE]\0A\0AOPTIONS:\0A -v, --verbose print a message for every creat directory\0A -c --bytes=[number of bytes] print the last bytes. Use c [number of bytes]\0A -n --lines=[number of lines] print the last lines, Use n [number of bytes]\0A --help print this message and exit\0A --version print version and exit\0A\00"
@stdout = global i32 0
@EXIT_SUCCESS = global i32 0
define void @usage() {
%1 = load i32, i32* @stdout
%2 = tail call i32 @fputs(i8* getelementptr inbounds ([410 x i8], [410 x i8]* @.str, i64 0, i64 0), i32 %1)
%3 = load i32, i32* @EXIT_SUCCESS
%4 = tail call i32 @exit(i32 %3)
unreachable
}
/* Variables and functions */
int ap_snprintf(char *, int, char *, char *, int);
char *zonestr(char *file, int line) {
  static char buff[64];
  int i;
  i = ap_snprintf(buff, 63, "%s:%d", file, line);
  buff[i] = '\0';
  return buff;
}


x86 assembly (clang, -O0):
<zonestr>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0x8(%rbp),%rcx
mov    -0xc(%rbp),%r8d
lea    0x2f12(%rip),%rdi
mov    $0x3f,%esi
lea    0xec6(%rip),%rdx
call   1030 <ap_snprintf@plt>
mov    %eax,-0x10(%rbp)
movslq -0x10(%rbp),%rcx
lea    0x2ef3(%rip),%rax
movb   $0x0,(%rax,%rcx,1)
lea    0x2ee8(%rip),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<zonestr>:
push   %rbx
mov    %esi,%r8d
mov    %rdi,%rcx
lea    0x2f22(%rip),%rbx
lea    0xedb(%rip),%rdx
mov    %rbx,%rdi
mov    $0x3f,%esi
call   1030 <ap_snprintf@plt>
cltq
movb   $0x0,(%rax,%rbx,1)
mov    %rbx,%rax
pop    %rbx
ret

LLVM IR (-O0):
@zonestr.buff = internal global [64 x i8] zeroinitializer
@.str = [6 x i8] c"%s:%d\00"
define i8* @zonestr(i8* %0, i32 %1) {
%3 = alloca i8*
%4 = alloca i32
%5 = alloca i32
store i8* %0, i8** %3
store i32 %1, i32* %4
%6 = load i8*, i8** %3
%7 = load i32, i32* %4
%8 = call i32 @ap_snprintf(i8* getelementptr inbounds ([64 x i8], [64 x i8]* @zonestr.buff, i64 0, i64 0), i32 63, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i8* %6, i32 %7)
store i32 %8, i32* %5
%9 = load i32, i32* %5
%10 = sext i32 %9 to i64
%11 = getelementptr inbounds [64 x i8], [64 x i8]* @zonestr.buff, i64 0, i64 %10
store i8 0, i8* %11
ret i8* getelementptr inbounds ([64 x i8], [64 x i8]* @zonestr.buff, i64 0, i64 0)
}

LLVM IR (-O2):
@zonestr.buff = internal global [64 x i8] zeroinitializer
@.str = [6 x i8] c"%s:%d\00"
define i8* @zonestr(i8* %0, i32 %1) {
%3 = tail call i32 @ap_snprintf(i8* getelementptr inbounds ([64 x i8], [64 x i8]* @zonestr.buff, i64 0, i64 0), i32 63, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i8* %0, i32 %1)
%4 = sext i32 %3 to i64
%5 = getelementptr inbounds [64 x i8], [64 x i8]* @zonestr.buff, i64 0, i64 %4
store i8 0, i8* %5
ret i8* getelementptr inbounds ([64 x i8], [64 x i8]* @zonestr.buff, i64 0, i64 0)
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
void ordenar(void) { printf("Função Ordenar não implementada!\n"); }


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

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

LLVM IR (-O0):
@.str = [37 x i8] c"Fun\C3\A7\C3\A3o Ordenar n\C3\A3o implementada!\0A\00"
define void @ordenar() {
%1 = call i32 @printf(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@str = [36 x i8] c"Fun\C3\A7\C3\A3o Ordenar n\C3\A3o implementada!\00"
define void @ordenar() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([36 x i8], [36 x i8]* @str, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ puts(char *);
usage(void) {
  puts("--Simple TCP Server--\n\n"
       "        To play with socket programming\n\n"
       "Options:\n\n"
       " -h|--help		Display help\n"
       " -p|--port		Port to listen on\n"
       " -n|--num		Listen for number of connections\n"
       " -b|--bind		Address to listen on (def: all)\n");
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
lea    0xee1(%rip),%rdi
call   1030 <puts@plt>
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
@.str = [218 x i8] c"--Simple TCP Server--\0A\0A To play with socket programming\0A\0AOptions:\0A\0A -h|--help\09\09Display help\0A -p|--port\09\09Port to listen on\0A -n|--num\09\09Listen for number of connections\0A -b|--bind\09\09Address to listen on (def: all)\0A\00"
define i32 @usage() {
%1 = alloca i32
%2 = call i32 @puts(i8* getelementptr inbounds ([218 x i8], [218 x i8]* @.str, i64 0, i64 0))
%3 = load i32, i32* %1
ret i32 %3
}

LLVM IR (-O2):
@.str = [218 x i8] c"--Simple TCP Server--\0A\0A To play with socket programming\0A\0AOptions:\0A\0A -h|--help\09\09Display help\0A -p|--port\09\09Port to listen on\0A -n|--num\09\09Listen for number of connections\0A -b|--bind\09\09Address to listen on (def: all)\0A\00"
define i32 @usage() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([218 x i8], [218 x i8]* @.str, i64 0, i64 0))
ret i32 undef
}
/* Type definitions */
typedef int /*<<< orphan*/ __u64;

/* Variables and functions */
__u64 ptr_to_u64(const void *ptr) { return (__u64)(unsigned long)ptr; }


x86 assembly (clang, -O0):
<ptr_to_u64>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<ptr_to_u64>:
mov    %rdi,%rax
ret

LLVM IR (-O0):
define i32 @ptr_to_u64(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = ptrtoint i8* %3 to i64
%5 = trunc i64 %4 to i32
ret i32 %5
}

LLVM IR (-O2):
define i32 @ptr_to_u64(i8* %0) {
%2 = ptrtoint i8* %0 to i64
%3 = trunc i64 %2 to i32
ret i32 %3
}
unsigned int invert(unsigned int x, unsigned int p, unsigned int n) {
  unsigned int r_1 = ~(~0 << n) << p;
  unsigned int r_2 = x & ~r_1;
  unsigned int r_3 = x & r_1;
  unsigned int r_4 = ~r_3 & r_1;
  return r_2 | r_4;
}


x86 assembly (clang, -O0):
<invert>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    -0xc(%rbp),%ecx
mov    $0xffffffff,%eax
shl    %cl,%eax
xor    $0xffffffff,%eax
mov    -0x8(%rbp),%ecx
shl    %cl,%eax
mov    %eax,-0x10(%rbp)
mov    -0x4(%rbp),%eax
mov    -0x10(%rbp),%ecx
xor    $0xffffffff,%ecx
and    %ecx,%eax
mov    %eax,-0x14(%rbp)
mov    -0x4(%rbp),%eax
and    -0x10(%rbp),%eax
mov    %eax,-0x18(%rbp)
mov    -0x18(%rbp),%eax
xor    $0xffffffff,%eax
and    -0x10(%rbp),%eax
mov    %eax,-0x1c(%rbp)
mov    -0x14(%rbp),%eax
or     -0x1c(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<invert>:
mov    %edx,%ecx
mov    $0xffffffff,%eax
shl    %cl,%eax
not    %eax
mov    %esi,%ecx
shl    %cl,%eax
xor    %edi,%eax
ret

LLVM IR (-O0):
define i32 @invert(i32 %0, i32 %1, i32 %2) {
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
store i32 %0, i32* %4
store i32 %1, i32* %5
store i32 %2, i32* %6
%11 = load i32, i32* %6
%12 = shl i32 -1, %11
%13 = xor i32 %12, -1
%14 = load i32, i32* %5
%15 = shl i32 %13, %14
store i32 %15, i32* %7
%16 = load i32, i32* %4
%17 = load i32, i32* %7
%18 = xor i32 %17, -1
%19 = and i32 %16, %18
store i32 %19, i32* %8
%20 = load i32, i32* %4
%21 = load i32, i32* %7
%22 = and i32 %20, %21
store i32 %22, i32* %9
%23 = load i32, i32* %9
%24 = xor i32 %23, -1
%25 = load i32, i32* %7
%26 = and i32 %24, %25
store i32 %26, i32* %10
%27 = load i32, i32* %8
%28 = load i32, i32* %10
%29 = or i32 %27, %28
ret i32 %29
}

LLVM IR (-O2):
define i32 @invert(i32 %0, i32 %1, i32 %2) {
%4 = shl nsw i32 -1, %2
%5 = xor i32 %4, -1
%6 = shl i32 %5, %1
%7 = xor i32 %6, %0
ret i32 %7
}
/* Variables and functions */
int /*<<< orphan*/ inter_guild_mapif_init(int);
int inter_mapif_init(int fd) {
  inter_guild_mapif_init(fd);
  return 0;
}


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

x86 assembly (clang, -O2):
<inter_mapif_init>:
push   %rax
call   1030 <inter_guild_mapif_init@plt>
xor    %eax,%eax
pop    %rcx
ret

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

LLVM IR (-O2):
define i32 @inter_mapif_init(i32 %0) {
%2 = tail call i32 @inter_guild_mapif_init(i32 %0)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *);
int /*<<< orphan*/ stderr;
void usage(void) {
  fprintf(stderr, "usage: runbg [-l logpath] -- command args...\n");
  fprintf(stderr,
          "    -l logpath  path to log stderr/stdout (default bgproc.log)\n");
  fprintf(stderr, "    -v          enable verbose logging\n");
  exit(2);
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
mov    0x2eb5(%rip),%rax
mov    (%rax),%edi
lea    0xecc(%rip),%rsi
call   1030 <fprintf@plt>
mov    0x2ea0(%rip),%rax
mov    (%rax),%edi
lea    0xee5(%rip),%rsi
call   1030 <fprintf@plt>
mov    0x2e8b(%rip),%rax
mov    (%rax),%edi
lea    0xf10(%rip),%rsi
call   1030 <fprintf@plt>
mov    $0x2,%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<usage>:
push   %rbx
mov    0x2eb8(%rip),%rbx
mov    (%rbx),%edi
lea    0xecf(%rip),%rsi
call   1030 <fprintf@plt>
mov    (%rbx),%edi
lea    0xeef(%rip),%rsi
call   1030 <fprintf@plt>
mov    (%rbx),%edi
lea    0xf21(%rip),%rsi
call   1030 <fprintf@plt>
mov    $0x2,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [46 x i8] c"usage: runbg [-l logpath] -- command args...\0A\00"
@.str.1 = [64 x i8] c" -l logpath path to log stderr/stdout (default bgproc.log)\0A\00"
@.str.2 = [40 x i8] c" -v enable verbose logging\0A\00"
define void @usage() {
%1 = load i32, i32* @stderr
%2 = call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str, i64 0, i64 0))
%3 = load i32, i32* @stderr
%4 = call i32 @fprintf(i32 %3, i8* getelementptr inbounds ([64 x i8], [64 x i8]* @.str.1, i64 0, i64 0))
%5 = load i32, i32* @stderr
%6 = call i32 @fprintf(i32 %5, i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str.2, i64 0, i64 0))
%7 = call i32 @exit(i32 2)
unreachable
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [46 x i8] c"usage: runbg [-l logpath] -- command args...\0A\00"
@.str.1 = [64 x i8] c" -l logpath path to log stderr/stdout (default bgproc.log)\0A\00"
@.str.2 = [40 x i8] c" -v enable verbose logging\0A\00"
define void @usage() {
%1 = load i32, i32* @stderr
%2 = tail call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str, i64 0, i64 0))
%3 = load i32, i32* @stderr
%4 = tail call i32 @fprintf(i32 %3, i8* getelementptr inbounds ([64 x i8], [64 x i8]* @.str.1, i64 0, i64 0))
%5 = load i32, i32* @stderr
%6 = tail call i32 @fprintf(i32 %5, i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str.2, i64 0, i64 0))
%7 = tail call i32 @exit(i32 2)
unreachable
}