xunge/DecIR huggingface dataset:
/* Variables and functions */
int /*<<< orphan*/ print_word(char *);
char *strtok(int /*<<< orphan*/ *, char *);
void cmdPrintWord(void) {
  char *token = strtok(NULL, " ");
  if (token != NULL) {
    print_word(token);
  }
}


x86 assembly (clang, -O0):
<cmdPrintWord>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
xor    %eax,%eax
mov    %eax,%edi
lea    0xecd(%rip),%rsi
call   1040 <strtok@plt>
mov    %rax,-0x8(%rbp)
cmpq   $0x0,-0x8(%rbp)
je     1150 <cmdPrintWord+0x30>
mov    -0x8(%rbp),%rdi
call   1030 <print_word@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<cmdPrintWord>:
push   %rax
lea    0xed8(%rip),%rsi
xor    %edi,%edi
call   1040 <strtok@plt>
test   %rax,%rax
je     113d <cmdPrintWord+0x1d>
mov    %rax,%rdi
pop    %rax
jmp    1030 <print_word@plt>
pop    %rax
ret

LLVM IR (-O0):
@.str = [2 x i8] c" \00"
define void @cmdPrintWord() {
%1 = alloca i8*
%2 = call i8* @strtok(i32* null, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
store i8* %2, i8** %1
%3 = load i8*, i8** %1
%4 = icmp ne i8* %3, null
br i1 %4, label %5, label %8
5: ; preds = %0
%6 = load i8*, i8** %1
%7 = call i32 @print_word(i8* %6)
br label %8
8: ; preds = %5, %0
ret void
}

LLVM IR (-O2):
@.str = [2 x i8] c" \00"
define void @cmdPrintWord() {
%1 = tail call i8* @strtok(i32* null, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%2 = icmp eq i8* %1, null
br i1 %2, label %5, label %3
3: ; preds = %0
%4 = tail call i32 @print_word(i8* %1)
br label %5
5: ; preds = %3, %0
ret void
}
/* Variables and functions */
int /*<<< orphan*/ write_mail_box(int, int, int);
void clear_my_rmb(int index) { write_mail_box(false, index, false); }


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

x86 assembly (clang, -O2):
<clear_my_rmb>:
mov    %edi,%esi
xor    %edi,%edi
xor    %edx,%edx
jmp    1030 <write_mail_box@plt>

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

LLVM IR (-O2):
define void @clear_my_rmb(i32 %0) {
%2 = tail call i32 @write_mail_box(i32 0, i32 %0, i32 0)
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ va_list;

/* Variables and functions */
void hge_not_valarm(const unsigned int value, const char *expr,
                    const char *format, va_list args) {}


x86 assembly (clang, -O0):
<hge_not_valarm>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %ecx,-0x1c(%rbp)
pop    %rbp
ret

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

LLVM IR (-O0):
define void @hge_not_valarm(i32 %0, i8* %1, i8* %2, i32 %3) {
%5 = alloca i32
%6 = alloca i8*
%7 = alloca i8*
%8 = alloca i32
store i32 %0, i32* %5
store i8* %1, i8** %6
store i8* %2, i8** %7
store i32 %3, i32* %8
ret void
}

LLVM IR (-O2):
define void @hge_not_valarm(i32 %0, i8* nocapture %1, i8* nocapture %2, i32 %3) {
ret void
}
/* Variables and functions */
size_t strlen(char const *);
size_t get_str_len(const char *str, int len) {
  if (len < 0)
    return strlen(str);
  else
    return len;
}


x86 assembly (clang, -O0):
<get_str_len>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %esi,-0x14(%rbp)
cmpl   $0x0,-0x14(%rbp)
jge    113b <get_str_len+0x2b>
mov    -0x10(%rbp),%rdi
call   1030 <strlen@plt>
mov    %rax,-0x8(%rbp)
jmp    1143 <get_str_len+0x33>
movslq -0x14(%rbp),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<get_str_len>:
test   %esi,%esi
js     1117 <get_str_len+0x7>
mov    %esi,%eax
ret
jmp    1030 <strlen@plt>

LLVM IR (-O0):
define i64 @get_str_len(i8* %0, i32 %1) {
%3 = alloca i64
%4 = alloca i8*
%5 = alloca i32
store i8* %0, i8** %4
store i32 %1, i32* %5
%6 = load i32, i32* %5
%7 = icmp slt i32 %6, 0
br i1 %7, label %8, label %11
8: ; preds = %2
%9 = load i8*, i8** %4
%10 = call i64 @strlen(i8* %9)
store i64 %10, i64* %3
br label %14
11: ; preds = %2
%12 = load i32, i32* %5
%13 = sext i32 %12 to i64
store i64 %13, i64* %3
br label %14
14: ; preds = %11, %8
%15 = load i64, i64* %3
ret i64 %15
}

LLVM IR (-O2):
define i64 @get_str_len(i8* nocapture %0, i32 %1) {
%3 = icmp slt i32 %1, 0
br i1 %3, label %4, label %6
4: ; preds = %2
%5 = tail call i64 @strlen(i8* dereferenceable(1) %0)
br label %8
6: ; preds = %2
%7 = zext i32 %1 to i64
br label %8
8: ; preds = %6, %4
%9 = phi i64 [ %5, %4 ], [ %7, %6 ]
ret i64 %9
}
int Arith_mod(int x, int y) {
  if (-13 / 5 == -2 && (x < 0) != (y < 0) && x % y != 0)
    return x % y + y;
  else
    return x % y;
}


x86 assembly (clang, -O0):
<Arith_mod>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
cmpl   $0x0,-0x8(%rbp)
setl   %al
and    $0x1,%al
movzbl %al,%eax
cmpl   $0x0,-0xc(%rbp)
setl   %cl
and    $0x1,%cl
movzbl %cl,%ecx
cmp    %ecx,%eax
je     114d <Arith_mod+0x4d>
mov    -0x8(%rbp),%eax
cltd
idivl  -0xc(%rbp)
cmp    $0x0,%edx
je     114d <Arith_mod+0x4d>
mov    -0x8(%rbp),%eax
cltd
idivl  -0xc(%rbp)
add    -0xc(%rbp),%edx
mov    %edx,-0x4(%rbp)
jmp    1157 <Arith_mod+0x57>
mov    -0x8(%rbp),%eax
cltd
idivl  -0xc(%rbp)
mov    %edx,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<Arith_mod>:
mov    %edi,%eax
cltd
idiv   %esi
lea    (%rdx,%rsi,1),%eax
test   %edx,%edx
cmove  %edx,%eax
xor    %edi,%esi
cmovns %edx,%eax
ret

LLVM IR (-O0):
define i32 @Arith_mod(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store i32 %0, i32* %4
store i32 %1, i32* %5
%6 = load i32, i32* %4
%7 = icmp slt i32 %6, 0
%8 = zext i1 %7 to i32
%9 = load i32, i32* %5
%10 = icmp slt i32 %9, 0
%11 = zext i1 %10 to i32
%12 = icmp ne i32 %8, %11
br i1 %12, label %13, label %24
13: ; preds = %2
%14 = load i32, i32* %4
%15 = load i32, i32* %5
%16 = srem i32 %14, %15
%17 = icmp ne i32 %16, 0
br i1 %17, label %18, label %24
18: ; preds = %13
%19 = load i32, i32* %4
%20 = load i32, i32* %5
%21 = srem i32 %19, %20
%22 = load i32, i32* %5
%23 = add nsw i32 %21, %22
store i32 %23, i32* %3
br label %28
24: ; preds = %13, %2
%25 = load i32, i32* %4
%26 = load i32, i32* %5
%27 = srem i32 %25, %26
store i32 %27, i32* %3
br label %28
28: ; preds = %24, %18
%29 = load i32, i32* %3
ret i32 %29
}

LLVM IR (-O2):
define i32 @Arith_mod(i32 %0, i32 %1) {
%3 = xor i32 %1, %0
%4 = icmp sgt i32 %3, -1
%5 = srem i32 %0, %1
%6 = icmp eq i32 %5, 0
%7 = add nsw i32 %5, %1
%8 = select i1 %6, i32 0, i32 %7
%9 = select i1 %4, i32 %5, i32 %8
ret i32 %9
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
void psplot_finish(void) {
  printf("stroke\ngrestore\nend\nshowpage\n");
  printf("%%%%Trailer\n");
}


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

x86 assembly (clang, -O2):
<psplot_finish>:
push   %rax
lea    0xee5(%rip),%rdi
call   1030 <puts@plt>
lea    0xecc(%rip),%rdi
pop    %rax
jmp    1040 <printf@plt>

LLVM IR (-O0):
@.str = [30 x i8] c"stroke\0Agrestore\0Aend\0Ashowpage\0A\00"
@.str.1 = [13 x i8] c"%%%%Trailer\0A\00"
define void @psplot_finish() {
%1 = call i32 @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str, i64 0, i64 0))
%2 = call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str.1 = [13 x i8] c"%%%%Trailer\0A\00"
@str = [29 x i8] c"stroke\0Agrestore\0Aend\0Ashowpage\00"
define void @psplot_finish() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([29 x i8], [29 x i8]* @str, i64 0, i64 0))
%2 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Type definitions */
struct _tuple8 {
  int dummy;
};
struct Cyc_Sexp_Parser {
  int dummy;
};

/* Variables and functions */
float Cyc_Sexp_int2float(unsigned int);
struct _tuple8 *Cyc_Sexp_mk_float(float);
unsigned int Cyc_Sexp_parse_int(struct Cyc_Sexp_Parser *);
struct _tuple8 *Cyc_Sexp_parse_float(struct Cyc_Sexp_Parser *p) {
  unsigned _T0;
  float _T1;
  struct _tuple8 *_T2;
  _T0 = Cyc_Sexp_parse_int(p);
  _T1 = Cyc_Sexp_int2float(_T0);
  _T2 = Cyc_Sexp_mk_float(_T1);
  return _T2;
}


x86 assembly (clang, -O0):
<Cyc_Sexp_parse_float>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1040 <Cyc_Sexp_parse_int@plt>
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%edi
call   1050 <Cyc_Sexp_int2float@plt>
movss  %xmm0,-0x10(%rbp)
movss  -0x10(%rbp),%xmm0
call   1030 <Cyc_Sexp_mk_float@plt>
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<Cyc_Sexp_parse_float>:
push   %rax
call   1040 <Cyc_Sexp_parse_int@plt>
mov    %eax,%edi
call   1050 <Cyc_Sexp_int2float@plt>
pop    %rax
jmp    1030 <Cyc_Sexp_mk_float@plt>

LLVM IR (-O0):
%struct._tuple8 = type { i32 }
%struct.Cyc_Sexp_Parser = type { i32 }
define %struct._tuple8* @Cyc_Sexp_parse_float(%struct.Cyc_Sexp_Parser* %0) {
%2 = alloca %struct.Cyc_Sexp_Parser*
%3 = alloca i32
%4 = alloca float
%5 = alloca %struct._tuple8*
store %struct.Cyc_Sexp_Parser* %0, %struct.Cyc_Sexp_Parser** %2
%6 = load %struct.Cyc_Sexp_Parser*, %struct.Cyc_Sexp_Parser** %2
%7 = call i32 @Cyc_Sexp_parse_int(%struct.Cyc_Sexp_Parser* %6)
store i32 %7, i32* %3
%8 = load i32, i32* %3
%9 = call float @Cyc_Sexp_int2float(i32 %8)
store float %9, float* %4
%10 = load float, float* %4
%11 = call %struct._tuple8* @Cyc_Sexp_mk_float(float %10)
store %struct._tuple8* %11, %struct._tuple8** %5
%12 = load %struct._tuple8*, %struct._tuple8** %5
ret %struct._tuple8* %12
}

LLVM IR (-O2):
%struct._tuple8 = type { i32 }
%struct.Cyc_Sexp_Parser = type { i32 }
define %struct._tuple8* @Cyc_Sexp_parse_float(%struct.Cyc_Sexp_Parser* %0) {
%2 = tail call i32 @Cyc_Sexp_parse_int(%struct.Cyc_Sexp_Parser* %0)
%3 = tail call float @Cyc_Sexp_int2float(i32 %2)
%4 = tail call %struct._tuple8* @Cyc_Sexp_mk_float(float %3)
ret %struct._tuple8* %4
}
void av_color_space_name() {}


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

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

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

LLVM IR (-O2):
define void @av_color_space_name() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *);
int /*<<< orphan*/ stderr;
void readpng_version_info() {
  fprintf(stderr, "   Compiled without libpng, zlib or PBMPLUS/NetPBM.\n");
}


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

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

LLVM IR (-O0):
@stderr = global i32 0
@.str = [53 x i8] c" Compiled without libpng, zlib or PBMPLUS/NetPBM.\0A\00"
define void @readpng_version_info() {
%1 = load i32, i32* @stderr
%2 = call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([53 x i8], [53 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [53 x i8] c" Compiled without libpng, zlib or PBMPLUS/NetPBM.\0A\00"
define void @readpng_version_info() {
%1 = load i32, i32* @stderr
%2 = tail call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([53 x i8], [53 x i8]* @.str, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ _mm_monitorx(char *, long, long);
int /*<<< orphan*/ _mm_mwaitx(long, long, long);
void bar(char *p, long x, long y, long z, long c) {
  _mm_monitorx(p, y, x);
  _mm_mwaitx(z, y, c);
}


x86 assembly (clang, -O0):
<bar>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x18(%rbp),%rsi
mov    -0x10(%rbp),%rdx
call   1040 <_mm_monitorx@plt>
mov    -0x20(%rbp),%rdi
mov    -0x18(%rbp),%rsi
mov    -0x28(%rbp),%rdx
call   1030 <_mm_mwaitx@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<bar>:
push   %r15
push   %r14
push   %rbx
mov    %r8,%r14
mov    %rcx,%r15
mov    %rdx,%rbx
mov    %rsi,%rdx
mov    %rbx,%rsi
call   1040 <_mm_monitorx@plt>
mov    %r15,%rdi
mov    %rbx,%rsi
mov    %r14,%rdx
pop    %rbx
pop    %r14
pop    %r15
jmp    1030 <_mm_mwaitx@plt>

LLVM IR (-O0):
define void @bar(i8* %0, i64 %1, i64 %2, i64 %3, i64 %4) {
%6 = alloca i8*
%7 = alloca i64
%8 = alloca i64
%9 = alloca i64
%10 = alloca i64
store i8* %0, i8** %6
store i64 %1, i64* %7
store i64 %2, i64* %8
store i64 %3, i64* %9
store i64 %4, i64* %10
%11 = load i8*, i8** %6
%12 = load i64, i64* %8
%13 = load i64, i64* %7
%14 = call i32 @_mm_monitorx(i8* %11, i64 %12, i64 %13)
%15 = load i64, i64* %9
%16 = load i64, i64* %8
%17 = load i64, i64* %10
%18 = call i32 @_mm_mwaitx(i64 %15, i64 %16, i64 %17)
ret void
}

LLVM IR (-O2):
define void @bar(i8* %0, i64 %1, i64 %2, i64 %3, i64 %4) {
%6 = tail call i32 @_mm_monitorx(i8* %0, i64 %2, i64 %1)
%7 = tail call i32 @_mm_mwaitx(i64 %3, i64 %2, i64 %4)
ret void
}
int detach_thin_subvol(struct mosaic *m, struct volume *v) { return -1; }


x86 assembly (clang, -O0):
<detach_thin_subvol>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    $0xffffffff,%eax
pop    %rbp
ret

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

LLVM IR (-O0):
%struct.mosaic = type opaque
%struct.volume = type opaque
define i32 @detach_thin_subvol(%struct.mosaic* %0, %struct.volume* %1) {
%3 = alloca %struct.mosaic*
%4 = alloca %struct.volume*
store %struct.mosaic* %0, %struct.mosaic** %3
store %struct.volume* %1, %struct.volume** %4
ret i32 -1
}

LLVM IR (-O2):
%struct.mosaic = type opaque
%struct.volume = type opaque
define i32 @detach_thin_subvol(%struct.mosaic* nocapture readnone %0, %struct.volume* nocapture readnone %1) {
ret i32 -1
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
int pa_ascii_filter() {
  printf("NOT IMPLEMENTED:"
         "pa_ascii_filter"
         "\n");
}


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

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

LLVM IR (-O0):
@.str = [33 x i8] c"NOT IMPLEMENTED:pa_ascii_filter\0A\00"
define i32 @pa_ascii_filter() {
%1 = alloca i32
%2 = call i32 @printf(i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str, i64 0, i64 0))
%3 = load i32, i32* %1
ret i32 %3
}

LLVM IR (-O2):
@str = [32 x i8] c"NOT IMPLEMENTED:pa_ascii_filter\00"
define i32 @pa_ascii_filter() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([32 x i8], [32 x i8]* @str, i64 0, i64 0))
ret i32 undef
}
/* Variables and functions */
int /*<<< orphan*/ A();
int /*<<< orphan*/ printf(char *);
int main() {
  printf("hello world\n");
  A();
  return 0;
}


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

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

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

LLVM IR (-O2):
@str = [12 x i8] c"hello world\00"
define i32 @main() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @str, i64 0, i64 0))
%2 = tail call i32 (...) @A()
ret i32 0
}
int dn_lim(int minval, int val) { return val < minval ? minval : val; }


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

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

LLVM IR (-O0):
define i32 @dn_lim(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 = load i32, i32* %3
%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 @dn_lim(i32 %0, i32 %1) {
%3 = icmp slt i32 %1, %0
%4 = select i1 %3, i32 %0, i32 %1
ret i32 %4
}
void always_sampler_free(struct htrace_sampler *sampler) {}


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

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

LLVM IR (-O0):
%struct.htrace_sampler = type opaque
define void @always_sampler_free(%struct.htrace_sampler* %0) {
%2 = alloca %struct.htrace_sampler*
store %struct.htrace_sampler* %0, %struct.htrace_sampler** %2
ret void
}

LLVM IR (-O2):
%struct.htrace_sampler = type opaque
define void @always_sampler_free(%struct.htrace_sampler* nocapture %0) {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ putc(int);
void newline() {
  putc(10);
  putc(13);
}


x86 assembly (clang, -O0):
<newline>:
push   %rbp
mov    %rsp,%rbp
mov    $0xa,%edi
call   1030 <putc@plt>
mov    $0xd,%edi
call   1030 <putc@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<newline>:
push   %rax
mov    $0xa,%edi
call   1030 <putc@plt>
mov    $0xd,%edi
pop    %rax
jmp    1030 <putc@plt>

LLVM IR (-O0):
define void @newline() {
%1 = call i32 @putc(i32 10)
%2 = call i32 @putc(i32 13)
ret void
}

LLVM IR (-O2):
define void @newline() {
%1 = tail call i32 @putc(i32 10)
%2 = tail call i32 @putc(i32 13)
ret void
}
/* Variables and functions */
bool load(const char *dictionary) { return false; }


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

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

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

LLVM IR (-O2):
define i32 @load(i8* nocapture readnone %0) {
ret i32 0
}
int ft_toupper(int c) {
  if (c >= 97 && c <= 122)
    return (c - 32);
  return (c);
}


x86 assembly (clang, -O0):
<ft_toupper>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x8(%rbp)
cmpl   $0x61,-0x8(%rbp)
jl     1129 <ft_toupper+0x29>
cmpl   $0x7a,-0x8(%rbp)
jg     1129 <ft_toupper+0x29>
mov    -0x8(%rbp),%eax
sub    $0x20,%eax
mov    %eax,-0x4(%rbp)
jmp    112f <ft_toupper+0x2f>
mov    -0x8(%rbp),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<ft_toupper>:
lea    -0x61(%rdi),%ecx
lea    -0x20(%rdi),%eax
cmp    $0x1a,%ecx
cmovae %edi,%eax
ret

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

LLVM IR (-O2):
define i32 @ft_toupper(i32 %0) {
%2 = add i32 %0, -97
%3 = icmp ult i32 %2, 26
%4 = add nsw i32 %0, -32
%5 = select i1 %3, i32 %4, i32 %0
ret i32 %5
}
void interrupts_configure(void) {}


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

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

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

LLVM IR (-O2):
define void @interrupts_configure() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
void sig_alrm(int signo) { printf("received SIGALRM\n"); }


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

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

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

LLVM IR (-O2):
@str = [17 x i8] c"received SIGALRM\00"
define void @sig_alrm(i32 %0) {
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([17 x i8], [17 x i8]* @str, i64 0, i64 0))
ret void
}
/* Variables and functions */
scalar_t__ malloc(int);
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ scanf(char *, char *);
char *get_file_name_to_delete(char *filename_list) {
  printf("%s\n", filename_list);
  printf("Escriba el nombre del archivo a eliminar: ");
  char *name = (char *)malloc(sizeof(char) * 30);
  scanf("%s", name);
  return name;
}


x86 assembly (clang, -O0):
<get_file_name_to_delete>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rsi
lea    0xeb9(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xeaf(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    $0x1e,%edi
call   1040 <malloc@plt>
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rsi
lea    0xeba(%rip),%rdi
call   1050 <scanf@plt>
mov    -0x10(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<get_file_name_to_delete>:
push   %rbx
call   1030 <puts@plt>
lea    0xeb3(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0x1e,%edi
call   1050 <malloc@plt>
mov    %rax,%rbx
lea    0xec3(%rip),%rdi
mov    %rax,%rsi
call   1060 <scanf@plt>
mov    %rbx,%rax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [4 x i8] c"%s\0A\00"
@.str.1 = [43 x i8] c"Escriba el nombre del archivo a eliminar: \00"
@.str.2 = [3 x i8] c"%s\00"
define i8* @get_file_name_to_delete(i8* %0) {
%2 = alloca i8*
%3 = alloca i8*
store i8* %0, i8** %2
%4 = load i8*, i8** %2
%5 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* %4)
%6 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.1, i64 0, i64 0))
%7 = call i64 @malloc(i32 30)
%8 = inttoptr i64 %7 to i8*
store i8* %8, i8** %3
%9 = load i8*, i8** %3
%10 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i8* %9)
%11 = load i8*, i8** %3
ret i8* %11
}

LLVM IR (-O2):
@.str.1 = [43 x i8] c"Escriba el nombre del archivo a eliminar: \00"
@.str.2 = [3 x i8] c"%s\00"
define i8* @get_file_name_to_delete(i8* nocapture %0) {
%2 = tail call i32 @puts(i8* dereferenceable(1) %0)
%3 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([43 x i8], [43 x i8]* @.str.1, i64 0, i64 0))
%4 = tail call i64 @malloc(i32 30)
%5 = inttoptr i64 %4 to i8*
%6 = tail call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i8* %5)
ret i8* %5
}
/* Variables and functions */
int str_fixup(void **, int);
int enum_fixup(void **param, int param_no) {
  if (param_no == 1) {
    return str_fixup(param, 1);
  } else if (param_no == 2) {
    return str_fixup(param, 1);
  }
  return 0;
}


x86 assembly (clang, -O0):
<enum_fixup>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %esi,-0x14(%rbp)
cmpl   $0x1,-0x14(%rbp)
jne    113f <enum_fixup+0x2f>
mov    -0x10(%rbp),%rdi
mov    $0x1,%esi
call   1030 <str_fixup@plt>
mov    %eax,-0x4(%rbp)
jmp    116b <enum_fixup+0x5b>
cmpl   $0x2,-0x14(%rbp)
jne    115f <enum_fixup+0x4f>
mov    -0x10(%rbp),%rdi
mov    $0x1,%esi
call   1030 <str_fixup@plt>
mov    %eax,-0x4(%rbp)
jmp    116b <enum_fixup+0x5b>
jmp    1164 <enum_fixup+0x54>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<enum_fixup>:
add    $0xffffffff,%esi
cmp    $0x1,%esi
ja     1122 <enum_fixup+0x12>
mov    $0x1,%esi
jmp    1030 <str_fixup@plt>
xor    %eax,%eax
ret

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

LLVM IR (-O2):
define i32 @enum_fixup(i8** %0, i32 %1) {
%3 = add i32 %1, -1
%4 = icmp ult i32 %3, 2
br i1 %4, label %5, label %7
5: ; preds = %2
%6 = tail call i32 @str_fixup(i8** %0, i32 1)
br label %7
7: ; preds = %2, %5
%8 = phi i32 [ 0, %2 ], [ %6, %5 ]
ret i32 %8
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, unsigned char, unsigned char, unsigned char,
                          unsigned char);
void printIPAddress(unsigned char *addr) {
  printf("%u.%u.%u.%u\n", addr[0], addr[1], addr[2], addr[3]);
}


x86 assembly (clang, -O0):
<printIPAddress>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%sil
mov    -0x8(%rbp),%rax
mov    0x1(%rax),%dl
mov    -0x8(%rbp),%rax
mov    0x2(%rax),%cl
mov    -0x8(%rbp),%rax
lea    0xec4(%rip),%rdi
movzbl %sil,%esi
movzbl %dl,%edx
movzbl %cl,%ecx
movzbl 0x3(%rax),%r8d
call   1030 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<printIPAddress>:
movzbl (%rdi),%esi
movzbl 0x1(%rdi),%edx
movzbl 0x2(%rdi),%ecx
movzbl 0x3(%rdi),%r8d
lea    0xed9(%rip),%rdi
jmp    1030 <printf@plt>

LLVM IR (-O0):
@.str = [13 x i8] c"%u.%u.%u.%u\0A\00"
define void @printIPAddress(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = getelementptr inbounds i8, i8* %3, i64 0
%5 = load i8, i8* %4
%6 = load i8*, i8** %2
%7 = getelementptr inbounds i8, i8* %6, i64 1
%8 = load i8, i8* %7
%9 = load i8*, i8** %2
%10 = getelementptr inbounds i8, i8* %9, i64 2
%11 = load i8, i8* %10
%12 = load i8*, i8** %2
%13 = getelementptr inbounds i8, i8* %12, i64 3
%14 = load i8, i8* %13
%15 = call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i8 zeroext %5, i8 zeroext %8, i8 zeroext %11, i8 zeroext %14)
ret void
}

LLVM IR (-O2):
@.str = [13 x i8] c"%u.%u.%u.%u\0A\00"
define void @printIPAddress(i8* nocapture %0) {
%2 = load i8, i8* %0
%3 = getelementptr inbounds i8, i8* %0, i64 1
%4 = load i8, i8* %3
%5 = getelementptr inbounds i8, i8* %0, i64 2
%6 = load i8, i8* %5
%7 = getelementptr inbounds i8, i8* %0, i64 3
%8 = load i8, i8* %7
%9 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i8 zeroext %2, i8 zeroext %4, i8 zeroext %6, i8 zeroext %8)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
int pa_context_get_source_output_info_list() {
  printf("NOT IMPLEMENTED:"
         "pa_context_get_source_output_info_list"
         "\n");
}


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

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

LLVM IR (-O0):
@.str = [56 x i8] c"NOT IMPLEMENTED:pa_context_get_source_output_info_list\0A\00"
define i32 @pa_context_get_source_output_info_list() {
%1 = alloca i32
%2 = call i32 @printf(i8* getelementptr inbounds ([56 x i8], [56 x i8]* @.str, i64 0, i64 0))
%3 = load i32, i32* %1
ret i32 %3
}

LLVM IR (-O2):
@str = [55 x i8] c"NOT IMPLEMENTED:pa_context_get_source_output_info_list\00"
define i32 @pa_context_get_source_output_info_list() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([55 x i8], [55 x i8]* @str, i64 0, i64 0))
ret i32 undef
}
/* Variables and functions */
scalar_t__ COND_EQ();
int /*<<< orphan*/ EA_A7_PD_8();
int /*<<< orphan*/ m68ki_write_8(int /*<<< orphan*/, int);
void m68k_op_seq_8_pd7(void) {
  m68ki_write_8(EA_A7_PD_8(), COND_EQ() ? 0xff : 0);
}


x86 assembly (clang, -O0):
<m68k_op_seq_8_pd7>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x0,%al
call   1030 <EA_A7_PD_8@plt>
mov    %eax,-0x4(%rbp)
mov    $0x0,%al
call   1040 <COND_EQ@plt>
mov    -0x4(%rbp),%edi
mov    %rax,%rcx
xor    %esi,%esi
mov    $0xff,%eax
cmp    $0x0,%rcx
cmovne %eax,%esi
call   1050 <m68ki_write_8@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<m68k_op_seq_8_pd7>:
push   %rbp
push   %rbx
push   %rax
xor    %ebp,%ebp
xor    %eax,%eax
call   1030 <EA_A7_PD_8@plt>
mov    %eax,%ebx
xor    %eax,%eax
call   1040 <COND_EQ@plt>
test   %rax,%rax
mov    $0xff,%esi
cmove  %ebp,%esi
mov    %ebx,%edi
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1050 <m68ki_write_8@plt>

LLVM IR (-O0):
define void @m68k_op_seq_8_pd7() {
%1 = call i32 (...) @EA_A7_PD_8()
%2 = call i64 (...) @COND_EQ()
%3 = icmp ne i64 %2, 0
%4 = zext i1 %3 to i64
%5 = select i1 %3, i32 255, i32 0
%6 = call i32 @m68ki_write_8(i32 %1, i32 %5)
ret void
}

LLVM IR (-O2):
define void @m68k_op_seq_8_pd7() {
%1 = tail call i32 (...) @EA_A7_PD_8()
%2 = tail call i64 (...) @COND_EQ()
%3 = icmp eq i64 %2, 0
%4 = select i1 %3, i32 0, i32 255
%5 = tail call i32 @m68ki_write_8(i32 %1, i32 %4)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ cgincind(char *, char *, int);
void cginc1iw(void) { cgincind("ax", "add", 1); }


x86 assembly (clang, -O0):
<cginc1iw>:
push   %rbp
mov    %rsp,%rbp
lea    0xee5(%rip),%rdi
lea    0xee1(%rip),%rsi
mov    $0x1,%edx
call   1030 <cgincind@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<cginc1iw>:
lea    0xee9(%rip),%rdi
lea    0xee5(%rip),%rsi
mov    $0x1,%edx
jmp    1030 <cgincind@plt>

LLVM IR (-O0):
@.str = [3 x i8] c"ax\00"
@.str.1 = [4 x i8] c"add\00"
define void @cginc1iw() {
%1 = call i32 @cgincind(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 1)
ret void
}

LLVM IR (-O2):
@.str = [3 x i8] c"ax\00"
@.str.1 = [4 x i8] c"add\00"
define void @cginc1iw() {
%1 = tail call i32 @cgincind(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 1)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ errno;
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, char *, char *);
int /*<<< orphan*/ stderr;
char *strerror(int /*<<< orphan*/);
void PrintError(char *error) {
  fprintf(stderr, "<<ERROR>>\t%s:\t%s", error, strerror(errno));
}


x86 assembly (clang, -O0):
<PrintError>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    0x2ead(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x14(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x10(%rbp)
mov    0x2e91(%rip),%rax
mov    (%rax),%edi
call   1040 <strerror@plt>
mov    -0x14(%rbp),%edi
mov    -0x10(%rbp),%rdx
mov    %rax,%rcx
lea    0xea1(%rip),%rsi
call   1030 <fprintf@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<PrintError>:
push   %rbp
push   %rbx
push   %rax
mov    %rdi,%rbx
mov    0x2eb3(%rip),%rax
mov    (%rax),%ebp
mov    0x2ea2(%rip),%rax
mov    (%rax),%edi
call   1040 <strerror@plt>
lea    0xebc(%rip),%rsi
mov    %ebp,%edi
mov    %rbx,%rdx
mov    %rax,%rcx
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1030 <fprintf@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [17 x i8] c"<<ERROR>>\09%s:\09%s\00"
@errno = global i32 0
define void @PrintError(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i32, i32* @stderr
%4 = load i8*, i8** %2
%5 = load i32, i32* @errno
%6 = call i8* @strerror(i32 %5)
%7 = call i32 @fprintf(i32 %3, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0), i8* %4, i8* %6)
ret void
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [17 x i8] c"<<ERROR>>\09%s:\09%s\00"
@errno = global i32 0
define void @PrintError(i8* %0) {
%2 = load i32, i32* @stderr
%3 = load i32, i32* @errno
%4 = tail call i8* @strerror(i32 %3)
%5 = tail call i32 @fprintf(i32 %2, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0), i8* %0, i8* %4)
ret void
}
long double mixed_div(long long a, long double b) { return a / b; }


x86 assembly (clang, -O0):
<mixed_div>:
push   %rbp
mov    %rsp,%rbp
fldt   0x10(%rbp)
mov    %rdi,-0x8(%rbp)
fstpt  -0x20(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x28(%rbp)
fildll -0x28(%rbp)
fldt   -0x20(%rbp)
fdivrp %st,%st(1)
pop    %rbp
ret

x86 assembly (clang, -O2):
<mixed_div>:
fldt   0x8(%rsp)
mov    %rdi,-0x8(%rsp)
fildll -0x8(%rsp)
fdivp  %st,%st(1)
ret

LLVM IR (-O0):
define x86_fp80 @mixed_div(i64 %0, x86_fp80 %1) {
%3 = alloca i64
%4 = alloca x86_fp80
store i64 %0, i64* %3
store x86_fp80 %1, x86_fp80* %4
%5 = load i64, i64* %3
%6 = sitofp i64 %5 to x86_fp80
%7 = load x86_fp80, x86_fp80* %4
%8 = fdiv x86_fp80 %6, %7
ret x86_fp80 %8
}

LLVM IR (-O2):
define x86_fp80 @mixed_div(i64 %0, x86_fp80 %1) {
%3 = sitofp i64 %0 to x86_fp80
%4 = fdiv x86_fp80 %3, %1
ret x86_fp80 %4
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int /*<<< orphan*/);
int /*<<< orphan*/ sqroot(int);
int main(int argc, char const *argv[]) {
  printf("%lf\n", sqroot(25));
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    $0x19,%edi
call   1040 <sqroot@plt>
mov    %eax,%esi
lea    0xeb7(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
mov    $0x19,%edi
call   1040 <sqroot@plt>
lea    0xece(%rip),%rdi
mov    %eax,%esi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rcx
ret

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

LLVM IR (-O2):
@.str = [5 x i8] c"%lf\0A\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @sqroot(i32 25)
%4 = tail call i32 @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32 %3)
ret i32 0
}
/* Variables and functions */
int color_eqn(int, int, int, int, int, int);
int b_cyg_cymg_yemg(int entrycyg, int entrycymg, int entryyeg, int entryyemg) {
  return color_eqn(122, entrycymg, -49, entryyemg, -48, entrycyg);
}


x86 assembly (clang, -O0):
<b_cyg_cymg_yemg>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %ecx,-0x10(%rbp)
mov    -0x8(%rbp),%esi
mov    -0x10(%rbp),%ecx
mov    -0x4(%rbp),%r9d
mov    $0x7a,%edi
mov    $0xffffffcf,%edx
mov    $0xffffffd0,%r8d
call   1030 <color_eqn@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<b_cyg_cymg_yemg>:
mov    %edi,%r9d
mov    $0x7a,%edi
mov    $0xffffffcf,%edx
mov    $0xffffffd0,%r8d
jmp    1030 <color_eqn@plt>

LLVM IR (-O0):
define i32 @b_cyg_cymg_yemg(i32 %0, i32 %1, i32 %2, i32 %3) {
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
store i32 %0, i32* %5
store i32 %1, i32* %6
store i32 %2, i32* %7
store i32 %3, i32* %8
%9 = load i32, i32* %6
%10 = load i32, i32* %8
%11 = load i32, i32* %5
%12 = call i32 @color_eqn(i32 122, i32 %9, i32 -49, i32 %10, i32 -48, i32 %11)
ret i32 %12
}

LLVM IR (-O2):
define i32 @b_cyg_cymg_yemg(i32 %0, i32 %1, i32 %2, i32 %3) {
%5 = tail call i32 @color_eqn(i32 122, i32 %1, i32 -49, i32 %3, i32 -48, i32 %0)
ret i32 %5
}
/* Type definitions */
struct task_struct {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ __slp_store_task_history(unsigned int, struct task_struct *);
void slp_store_task_history(unsigned int cpu, struct task_struct *task) {
  __slp_store_task_history(cpu, task);
}


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

x86 assembly (clang, -O2):
<slp_store_task_history>:
jmp    1030 <__slp_store_task_history@plt>

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

LLVM IR (-O2):
%struct.task_struct = type { i32 }
define void @slp_store_task_history(i32 %0, %struct.task_struct* %1) {
%3 = tail call i32 @__slp_store_task_history(i32 %0, %struct.task_struct* %1)
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ int8_t;
typedef int int16_t;

/* Variables and functions */
int ms_bigendianhost() {
  int16_t host = 1;
  return !(*((int8_t *)(&host)));
}


x86 assembly (clang, -O0):
<ms_bigendianhost>:
push   %rbp
mov    %rsp,%rbp
movl   $0x1,-0x4(%rbp)
cmpl   $0x0,-0x4(%rbp)
setne  %al
xor    $0xff,%al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

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

LLVM IR (-O0):
define i32 @ms_bigendianhost() {
%1 = alloca i32
store i32 1, i32* %1
%2 = load i32, i32* %1
%3 = icmp ne i32 %2, 0
%4 = xor i1 %3, true
%5 = zext i1 %4 to i32
ret i32 %5
}

LLVM IR (-O2):
define i32 @ms_bigendianhost() {
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ toggle_csum();
int main(void) {
  toggle_csum();
  return 0;
}


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

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

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

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 (...) @toggle_csum()
ret i32 0
}
void lcd_waitbusy() {}


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

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

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

LLVM IR (-O2):
define void @lcd_waitbusy() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ free(void *);
int /*<<< orphan*/ memset(void *, int /*<<< orphan*/, int);
void aes_decrypt_deinit(void *ctx) {
  memset(ctx, 0, (4 * 4 * 15 + 4));
  free(ctx);
}


x86 assembly (clang, -O0):
<aes_decrypt_deinit>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
xor    %esi,%esi
mov    $0xf4,%edx
call   1040 <memset@plt>
mov    -0x8(%rbp),%rdi
call   1030 <free@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<aes_decrypt_deinit>:
push   %rbx
mov    %rdi,%rbx
xor    %esi,%esi
mov    $0xf4,%edx
call   1040 <memset@plt>
mov    %rbx,%rdi
pop    %rbx
jmp    1030 <free@plt>

LLVM IR (-O0):
define void @aes_decrypt_deinit(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = call i32 @memset(i8* %3, i32 0, i32 244)
%5 = load i8*, i8** %2
%6 = call i32 @free(i8* %5)
ret void
}

LLVM IR (-O2):
define void @aes_decrypt_deinit(i8* %0) {
%2 = tail call i32 @memset(i8* %0, i32 0, i32 244)
%3 = tail call i32 @free(i8* %0)
ret void
}
long long ROUND(long double value) {
  long long intpart;
  intpart = (long long)value;
  value = value - intpart;
  if (value >= 0.5)
    ++intpart;
  if (value <= -0.5)
    --intpart;
  return intpart;
}


x86 assembly (clang, -O0):
<ROUND>:
push   %rbp
mov    %rsp,%rbp
fldt   0x10(%rbp)
fstpt  -0x10(%rbp)
fldt   -0x10(%rbp)
fnstcw -0x2a(%rbp)
movzwl -0x2a(%rbp),%eax
or     $0xc00,%eax
mov    %ax,-0x2c(%rbp)
fldcw  -0x2c(%rbp)
fistpll -0x28(%rbp)
fldcw  -0x2a(%rbp)
mov    -0x28(%rbp),%rax
mov    %rax,-0x18(%rbp)
fldt   -0x10(%rbp)
mov    -0x18(%rbp),%rax
mov    %rax,-0x20(%rbp)
fildll -0x20(%rbp)
fsubrp %st,%st(1)
fstpt  -0x10(%rbp)
fldt   -0x10(%rbp)
flds   0xeb6(%rip)
fxch   %st(1)
fucomip %st(1),%st
fstp   %st(0)
jb     1167 <ROUND+0x67>
jmp    115b <ROUND+0x5b>
mov    -0x18(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x18(%rbp)
fldt   -0x10(%rbp)
flds   0xe94(%rip)
fucomip %st(1),%st
fstp   %st(0)
jb     118b <ROUND+0x8b>
jmp    117f <ROUND+0x7f>
mov    -0x18(%rbp),%rax
add    $0xffffffffffffffff,%rax
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<ROUND>:
fldt   0x8(%rsp)
fnstcw -0x14(%rsp)
movzwl -0x14(%rsp),%eax
or     $0xc00,%eax
mov    %ax,-0x12(%rsp)
fldcw  -0x12(%rsp)
fld    %st(0)
fistpll -0x10(%rsp)
fldcw  -0x14(%rsp)
mov    -0x10(%rsp),%rax
mov    %rax,-0x8(%rsp)
fildll -0x8(%rsp)
fsubrp %st,%st(1)
flds   0xec5(%rip)
fxch   %st(1)
fucomi %st(1),%st
fstp   %st(1)
sbb    $0xffffffffffffffff,%rax
flds   0xeb9(%rip)
fucomip %st(1),%st
fstp   %st(0)
adc    $0xffffffffffffffff,%rax
ret

LLVM IR (-O0):
define i64 @ROUND(x86_fp80 %0) {
%2 = alloca x86_fp80
%3 = alloca i64
store x86_fp80 %0, x86_fp80* %2
%4 = load x86_fp80, x86_fp80* %2
%5 = fptosi x86_fp80 %4 to i64
store i64 %5, i64* %3
%6 = load x86_fp80, x86_fp80* %2
%7 = load i64, i64* %3
%8 = sitofp i64 %7 to x86_fp80
%9 = fsub x86_fp80 %6, %8
store x86_fp80 %9, x86_fp80* %2
%10 = load x86_fp80, x86_fp80* %2
%11 = fcmp oge x86_fp80 %10, 0xK3FFE8000000000000000
br i1 %11, label %12, label %15
12: ; preds = %1
%13 = load i64, i64* %3
%14 = add nsw i64 %13, 1
store i64 %14, i64* %3
br label %15
15: ; preds = %12, %1
%16 = load x86_fp80, x86_fp80* %2
%17 = fcmp ole x86_fp80 %16, 0xKBFFE8000000000000000
br i1 %17, label %18, label %21
18: ; preds = %15
%19 = load i64, i64* %3
%20 = add nsw i64 %19, -1
store i64 %20, i64* %3
br label %21
21: ; preds = %18, %15
%22 = load i64, i64* %3
ret i64 %22
}

LLVM IR (-O2):
define i64 @ROUND(x86_fp80 %0) {
%2 = fptosi x86_fp80 %0 to i64
%3 = sitofp i64 %2 to x86_fp80
%4 = fsub x86_fp80 %0, %3
%5 = fcmp oge x86_fp80 %4, 0xK3FFE8000000000000000
%6 = zext i1 %5 to i64
%7 = add nsw i64 %6, %2
%8 = fcmp ole x86_fp80 %4, 0xKBFFE8000000000000000
%9 = sext i1 %8 to i64
%10 = add nsw i64 %7, %9
ret i64 %10
}
/* Variables and functions */
int /*<<< orphan*/ move_current(int /*<<< orphan*/);
int /*<<< orphan*/ to_point(int, int /*<<< orphan*/);
int move_left() {
  move_current(to_point(-1, 0));
  return 1;
}


x86 assembly (clang, -O0):
<move_left>:
push   %rbp
mov    %rsp,%rbp
mov    $0xffffffff,%edi
xor    %esi,%esi
call   1030 <to_point@plt>
mov    %eax,%edi
call   1040 <move_current@plt>
mov    $0x1,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<move_left>:
push   %rax
mov    $0xffffffff,%edi
xor    %esi,%esi
call   1030 <to_point@plt>
mov    %eax,%edi
call   1040 <move_current@plt>
mov    $0x1,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @move_left() {
%1 = call i32 @to_point(i32 -1, i32 0)
%2 = call i32 @move_current(i32 %1)
ret i32 1
}

LLVM IR (-O2):
define i32 @move_left() {
%1 = tail call i32 @to_point(i32 -1, i32 0)
%2 = tail call i32 @move_current(i32 %1)
ret i32 1
}
void CleanupQst(void) { return; }


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

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

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

LLVM IR (-O2):
define void @CleanupQst() {
ret void
}
int get_npar(int ncol) { return (ncol * (ncol + 1)) / 2; }


x86 assembly (clang, -O0):
<get_npar>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%eax
mov    -0x4(%rbp),%ecx
add    $0x1,%ecx
imul   %ecx,%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
pop    %rbp
ret

x86 assembly (clang, -O2):
<get_npar>:
lea    0x1(%rdi),%ecx
imul   %edi,%ecx
mov    %ecx,%eax
shr    $0x1f,%eax
add    %ecx,%eax
sar    %eax
ret

LLVM IR (-O0):
define i32 @get_npar(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = load i32, i32* %2
%5 = add nsw i32 %4, 1
%6 = mul nsw i32 %3, %5
%7 = sdiv i32 %6, 2
ret i32 %7
}

LLVM IR (-O2):
define i32 @get_npar(i32 %0) {
%2 = add nsw i32 %0, 1
%3 = mul nsw i32 %2, %0
%4 = sdiv i32 %3, 2
ret i32 %4
}
/* Variables and functions */
int /*<<< orphan*/ test_fread();
int /*<<< orphan*/ test_random_read_file();
int main() {
  test_fread();
  test_random_read_file();
  return 0;
}


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

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

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = call i32 (...) @test_fread()
%3 = call i32 (...) @test_random_read_file()
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 (...) @test_fread()
%2 = tail call i32 (...) @test_random_read_file()
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ iscntrl(int);
void t_iscntrl_0x27() {
  Assert_real((iscntrl(39) == 0),
              "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/"
              "2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/"
              "dg/z88dk/test/suites/ctype/test_iscntrl.c",
              200, ("iscntrl should be 0 for '"));
}


x86 assembly (clang, -O0):
<t_iscntrl_0x27>:
push   %rbp
mov    %rsp,%rbp
mov    $0x27,%edi
call   1030 <iscntrl@plt>
cmp    $0x0,%rax
sete   %al
and    $0x1,%al
movzbl %al,%edi
lea    0xebf(%rip),%rsi
mov    $0xc8,%edx
lea    0xf5b(%rip),%rcx
call   1040 <Assert_real@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<t_iscntrl_0x27>:
push   %rax
mov    $0x27,%edi
call   1030 <iscntrl@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
lea    0xec5(%rip),%rsi
lea    0xf66(%rip),%rcx
mov    $0xc8,%edx
pop    %rax
jmp    1040 <Assert_real@plt>

LLVM IR (-O0):
@.str = [168 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_iscntrl.c\00"
@.str.1 = [26 x i8] c"iscntrl should be 0 for '\00"
define void @t_iscntrl_0x27() {
%1 = call i64 @iscntrl(i32 39)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 200, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [168 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_iscntrl.c\00"
@.str.1 = [26 x i8] c"iscntrl should be 0 for '\00"
define void @t_iscntrl_0x27() {
%1 = tail call i64 @iscntrl(i32 39)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = tail call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 200, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.1, i64 0, i64 0))
ret void
}