xunge/DecIR huggingface dataset:
/* Variables and functions */
int /*<<< orphan*/ assert(int);
int /*<<< orphan*/ mb_free(void *);
int _ls_free_extra(void *data, void *extra) {
  int result = 0;
  ((void)(data));
  do {
    ((void)(extra));
    assert(extra);
  } while (0);
  do {
    if (extra) {
      mb_free(extra);
      extra = 0;
    } else {
      do {
        ((void)(0 && "Memory already released"));
        assert(0 && "Memory already released");
      } while (0);
    }
  } while (0);
  result = -1;
  return result;
}


x86 assembly (clang, -O0):
<_ls_free_extra>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
movl   $0x0,-0x14(%rbp)
mov    -0x10(%rbp),%rax
mov    %eax,%edi
call   1030 <assert@plt>
jmp    1147 <_ls_free_extra+0x27>
cmpq   $0x0,-0x10(%rbp)
je     1168 <_ls_free_extra+0x48>
mov    -0x10(%rbp),%rdi
call   1040 <mb_free@plt>
movq   $0x0,-0x10(%rbp)
jmp    1179 <_ls_free_extra+0x59>
jmp    116d <_ls_free_extra+0x4d>
xor    %edi,%edi
call   1030 <assert@plt>
jmp    1179 <_ls_free_extra+0x59>
jmp    117e <_ls_free_extra+0x5e>
movl   $0xffffffff,-0x14(%rbp)
mov    -0x14(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<_ls_free_extra>:
push   %rbx
mov    %rsi,%rbx
mov    %ebx,%edi
call   1030 <assert@plt>
test   %rbx,%rbx
je     113a <_ls_free_extra+0x1a>
mov    %rbx,%rdi
call   1040 <mb_free@plt>
jmp    1141 <_ls_free_extra+0x21>
xor    %edi,%edi
call   1030 <assert@plt>
mov    $0xffffffff,%eax
pop    %rbx
ret

LLVM IR (-O0):
define i32 @_ls_free_extra(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
%5 = alloca i32
store i8* %0, i8** %3
store i8* %1, i8** %4
store i32 0, i32* %5
%6 = load i8*, i8** %3
br label %7
7: ; preds = %2
%8 = load i8*, i8** %4
%9 = load i8*, i8** %4
%10 = ptrtoint i8* %9 to i32
%11 = call i32 @assert(i32 %10)
br label %12
12: ; preds = %7
br label %13
13: ; preds = %12
%14 = load i8*, i8** %4
%15 = icmp ne i8* %14, null
br i1 %15, label %16, label %19
16: ; preds = %13
%17 = load i8*, i8** %4
%18 = call i32 @mb_free(i8* %17)
store i8* null, i8** %4
br label %23
19: ; preds = %13
br label %20
20: ; preds = %19
%21 = call i32 @assert(i32 0)
br label %22
22: ; preds = %20
br label %23
23: ; preds = %22, %16
br label %24
24: ; preds = %23
store i32 -1, i32* %5
%25 = load i32, i32* %5
ret i32 %25
}

LLVM IR (-O2):
define i32 @_ls_free_extra(i8* nocapture readnone %0, i8* %1) {
%3 = ptrtoint i8* %1 to i64
%4 = trunc i64 %3 to i32
%5 = tail call i32 @assert(i32 %4)
%6 = icmp eq i8* %1, null
br i1 %6, label %9, label %7
7: ; preds = %2
%8 = tail call i32 @mb_free(i8* %1)
br label %11
9: ; preds = %2
%10 = tail call i32 @assert(i32 0)
br label %11
11: ; preds = %9, %7
ret i32 -1
}
/* Type definitions */
struct timeval {
  int tv_sec;
};

/* Variables and functions */
int /*<<< orphan*/ gettimeofday(struct timeval *, int /*<<< orphan*/ *);
int /*<<< orphan*/ memset(struct timeval *, int /*<<< orphan*/, int);
void iscsi_timer_set(struct timeval *timer, int seconds) {
  if (timer) {
    memset(timer, 0, sizeof(*timer));
    gettimeofday(timer, NULL);
    timer->tv_sec += seconds;
  }
}


x86 assembly (clang, -O0):
<iscsi_timer_set>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
cmpq   $0x0,-0x8(%rbp)
je     1162 <iscsi_timer_set+0x42>
mov    -0x8(%rbp),%rdi
xor    %esi,%esi
mov    $0x4,%edx
call   1040 <memset@plt>
mov    -0x8(%rbp),%rdi
xor    %eax,%eax
mov    %eax,%esi
call   1030 <gettimeofday@plt>
mov    -0xc(%rbp),%ecx
mov    -0x8(%rbp),%rax
add    (%rax),%ecx
mov    %ecx,(%rax)
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<iscsi_timer_set>:
test   %rdi,%rdi
je     114b <iscsi_timer_set+0x2b>
push   %rbp
push   %rbx
push   %rax
mov    %esi,%ebp
mov    %rdi,%rbx
xor    %esi,%esi
mov    $0x4,%edx
call   1040 <memset@plt>
mov    %rbx,%rdi
xor    %esi,%esi
call   1030 <gettimeofday@plt>
add    %ebp,(%rbx)
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
%struct.timeval = type { i32 }
define void @iscsi_timer_set(%struct.timeval* %0, i32 %1) {
%3 = alloca %struct.timeval*
%4 = alloca i32
store %struct.timeval* %0, %struct.timeval** %3
store i32 %1, i32* %4
%5 = load %struct.timeval*, %struct.timeval** %3
%6 = icmp ne %struct.timeval* %5, null
br i1 %6, label %7, label %17
7: ; preds = %2
%8 = load %struct.timeval*, %struct.timeval** %3
%9 = call i32 @memset(%struct.timeval* %8, i32 0, i32 4)
%10 = load %struct.timeval*, %struct.timeval** %3
%11 = call i32 @gettimeofday(%struct.timeval* %10, i32* null)
%12 = load i32, i32* %4
%13 = load %struct.timeval*, %struct.timeval** %3
%14 = getelementptr inbounds %struct.timeval, %struct.timeval* %13, i32 0, i32 0
%15 = load i32, i32* %14
%16 = add nsw i32 %15, %12
store i32 %16, i32* %14
br label %17
17: ; preds = %7, %2
ret void
}

LLVM IR (-O2):
%struct.timeval = type { i32 }
define void @iscsi_timer_set(%struct.timeval* %0, i32 %1) {
%3 = icmp eq %struct.timeval* %0, null
br i1 %3, label %10, label %4
4: ; preds = %2
%5 = tail call i32 @memset(%struct.timeval* %0, i32 0, i32 4)
%6 = tail call i32 @gettimeofday(%struct.timeval* %0, i32* null)
%7 = getelementptr inbounds %struct.timeval, %struct.timeval* %0, i64 0, i32 0
%8 = load i32, i32* %7
%9 = add nsw i32 %8, %1
store i32 %9, i32* %7
br label %10
10: ; preds = %4, %2
ret void
}
_Bool is_I_X_C(char c) {
  switch (c) {
  case 'I':
    return 1;
  case 'X':
    return 1;
  case 'C':
    return 1;
  default:
    return 0;
  }
}


x86 assembly (clang, -O0):
<is_I_X_C>:
push   %rbp
mov    %rsp,%rbp
mov    %dil,%al
mov    %al,-0x2(%rbp)
movsbl -0x2(%rbp),%eax
mov    %eax,-0x8(%rbp)
sub    $0x43,%eax
je     1153 <is_I_X_C+0x53>
jmp    111f <is_I_X_C+0x1f>
mov    -0x8(%rbp),%eax
sub    $0x49,%eax
je     1141 <is_I_X_C+0x41>
jmp    1130 <is_I_X_C+0x30>
mov    -0x8(%rbp),%eax
sub    $0x58,%eax
je     114a <is_I_X_C+0x4a>
jmp    115c <is_I_X_C+0x5c>
movb   $0x1,-0x1(%rbp)
jmp    1160 <is_I_X_C+0x60>
movb   $0x1,-0x1(%rbp)
jmp    1160 <is_I_X_C+0x60>
movb   $0x1,-0x1(%rbp)
jmp    1160 <is_I_X_C+0x60>
movb   $0x0,-0x1(%rbp)
mov    -0x1(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_I_X_C>:
add    $0xffffffbd,%edi
cmp    $0x16,%edi
setb   %cl
mov    $0x200041,%eax
bt     %edi,%eax
setb   %al
and    %cl,%al
ret

LLVM IR (-O0):
define zeroext i1 @is_I_X_C(i8 signext %0) {
%2 = alloca i1
%3 = alloca i8
store i8 %0, i8* %3
%4 = load i8, i8* %3
%5 = sext i8 %4 to i32
switch i32 %5, label %9 [
i32 73, label %6
i32 88, label %7
i32 67, label %8
]
6: ; preds = %1
store i1 true, i1* %2
br label %10
7: ; preds = %1
store i1 true, i1* %2
br label %10
8: ; preds = %1
store i1 true, i1* %2
br label %10
9: ; preds = %1
store i1 false, i1* %2
br label %10
10: ; preds = %9, %8, %7, %6
%11 = load i1, i1* %2
ret i1 %11
}

LLVM IR (-O2):
define zeroext i1 @is_I_X_C(i8 signext %0) {
%2 = sext i8 %0 to i32
%3 = add nsw i32 %2, -67
%4 = icmp ult i32 %3, 22
%5 = trunc i32 %3 to i22
%6 = lshr i22 -2097087, %5
%7 = and i22 %6, 1
%8 = icmp ne i22 %7, 0
%9 = select i1 %4, i1 %8, i1 false
ret i1 %9
}
/* Variables and functions */
int /*<<< orphan*/ out_of_memory();
void ensure_ptr(void *p) {
  if (p == NULL) {
    out_of_memory();
  }
}


x86 assembly (clang, -O0):
<ensure_ptr>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
cmpq   $0x0,-0x8(%rbp)
jne    112e <ensure_ptr+0x1e>
mov    $0x0,%al
call   1030 <out_of_memory@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ensure_ptr>:
test   %rdi,%rdi
je     1116 <ensure_ptr+0x6>
ret
xor    %eax,%eax
jmp    1030 <out_of_memory@plt>

LLVM IR (-O0):
define void @ensure_ptr(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = icmp eq i8* %3, null
br i1 %4, label %5, label %7
5: ; preds = %1
%6 = call i32 (...) @out_of_memory()
br label %7
7: ; preds = %5, %1
ret void
}

LLVM IR (-O2):
define void @ensure_ptr(i8* readnone %0) {
%2 = icmp eq i8* %0, null
br i1 %2, label %3, label %5
3: ; preds = %1
%4 = tail call i32 (...) @out_of_memory()
br label %5
5: ; preds = %3, %1
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ uint8_t;

/* Variables and functions */
int /*<<< orphan*/ burnstack(int);
int /*<<< orphan*/ genpub(int /*<<< orphan*/ *, int /*<<< orphan*/ const *);
void ed25519_genpub(uint8_t pub[32], const uint8_t sec[32]) {
  genpub(pub, sec);
  burnstack(2048);
}


x86 assembly (clang, -O0):
<ed25519_genpub>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1030 <genpub@plt>
mov    $0x800,%edi
call   1040 <burnstack@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ed25519_genpub>:
push   %rax
call   1030 <genpub@plt>
mov    $0x800,%edi
pop    %rax
jmp    1040 <burnstack@plt>

LLVM IR (-O0):
define void @ed25519_genpub(i32* %0, i32* %1) {
%3 = alloca i32*
%4 = alloca i32*
store i32* %0, i32** %3
store i32* %1, i32** %4
%5 = load i32*, i32** %3
%6 = load i32*, i32** %4
%7 = call i32 @genpub(i32* %5, i32* %6)
%8 = call i32 @burnstack(i32 2048)
ret void
}

LLVM IR (-O2):
define void @ed25519_genpub(i32* %0, i32* %1) {
%3 = tail call i32 @genpub(i32* %0, i32* %1)
%4 = tail call i32 @burnstack(i32 2048)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ bp_sw_error_flag_off(int, int);
void bp_sw_error_off(int type) { bp_sw_error_flag_off(type, 1); }


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

x86 assembly (clang, -O2):
<bp_sw_error_off>:
mov    $0x1,%esi
jmp    1030 <bp_sw_error_flag_off@plt>

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

LLVM IR (-O2):
define void @bp_sw_error_off(i32 %0) {
%2 = tail call i32 @bp_sw_error_flag_off(i32 %0, i32 1)
ret void
}
void __attribute__((__warning__("curl_easy_getinfo expects a pointer to "
                                "'struct curl_certinfo *' for this info")))
__attribute__((__unused__)) __attribute__((__no__))
_curl_easy_getinfo_err_curl_certinfo(void) {
  __asm__("");
}


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

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

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

LLVM IR (-O2):
define void @_curl_easy_getinfo_err_curl_certinfo() {
tail call void asm sideeffect "", "~{dirflag},~{fpsr},~{flags}"()
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ ino_t;

/* Variables and functions */
int /*<<< orphan*/ guitp(char *, int);
void g_ino_t() { guitp("ino_t", sizeof(ino_t)); }


x86 assembly (clang, -O0):
<g_ino_t>:
push   %rbp
mov    %rsp,%rbp
lea    0xee5(%rip),%rdi
mov    $0x4,%esi
call   1030 <guitp@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<g_ino_t>:
lea    0xee9(%rip),%rdi
mov    $0x4,%esi
jmp    1030 <guitp@plt>

LLVM IR (-O0):
@.str = [6 x i8] c"ino_t\00"
define void @g_ino_t() {
%1 = call i32 @guitp(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 4)
ret void
}

LLVM IR (-O2):
@.str = [6 x i8] c"ino_t\00"
define void @g_ino_t() {
%1 = tail call i32 @guitp(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 4)
ret void
}
/* Type definitions */
struct vec2 {
  int dummy;
};

/* Variables and functions */
int vec2_is_equal(float *, float *);
__attribute__((always_)) bool psvec2_is_equal(struct vec2 *a, struct vec2 *b) {
  return vec2_is_equal((float *)a, (float *)b);
}


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

x86 assembly (clang, -O2):
<psvec2_is_equal>:
jmp    1030 <vec2_is_equal@plt>

LLVM IR (-O0):
%struct.vec2 = type { i32 }
define i32 @psvec2_is_equal(%struct.vec2* %0, %struct.vec2* %1) {
%3 = alloca %struct.vec2*
%4 = alloca %struct.vec2*
store %struct.vec2* %0, %struct.vec2** %3
store %struct.vec2* %1, %struct.vec2** %4
%5 = load %struct.vec2*, %struct.vec2** %3
%6 = bitcast %struct.vec2* %5 to float*
%7 = load %struct.vec2*, %struct.vec2** %4
%8 = bitcast %struct.vec2* %7 to float*
%9 = call i32 @vec2_is_equal(float* %6, float* %8)
ret i32 %9
}

LLVM IR (-O2):
%struct.vec2 = type { i32 }
define i32 @psvec2_is_equal(%struct.vec2* %0, %struct.vec2* %1) {
%3 = bitcast %struct.vec2* %0 to float*
%4 = bitcast %struct.vec2* %1 to float*
%5 = tail call i32 @vec2_is_equal(float* %3, float* %4)
ret i32 %5
}
int add_ret(int a, int b) { return a + b; }


x86 assembly (clang, -O0):
<add_ret>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x4(%rbp),%eax
add    -0x8(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<add_ret>:
lea    (%rdi,%rsi,1),%eax
ret

LLVM IR (-O0):
define i32 @add_ret(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 = add nsw i32 %5, %6
ret i32 %7
}

LLVM IR (-O2):
define i32 @add_ret(i32 %0, i32 %1) {
%3 = add nsw i32 %1, %0
ret i32 %3
}
/* Variables and functions */
double erfc(double);
double c_erfc(double arg0) { return erfc(arg0); }


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

x86 assembly (clang, -O2):
<c_erfc>:
jmp    1030 <erfc@plt>

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

LLVM IR (-O2):
define double @c_erfc(double %0) {
%2 = tail call double @erfc(double %0)
ret double %2
}
struct murmur3_running_checksum *rc_to_priv(struct running_checksum *rc) {
  return (struct murmur3_running_checksum *)rc;
}


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

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

LLVM IR (-O0):
%struct.murmur3_running_checksum = type opaque
%struct.running_checksum = type opaque
define %struct.murmur3_running_checksum* @rc_to_priv(%struct.running_checksum* %0) {
%2 = alloca %struct.running_checksum*
store %struct.running_checksum* %0, %struct.running_checksum** %2
%3 = load %struct.running_checksum*, %struct.running_checksum** %2
%4 = bitcast %struct.running_checksum* %3 to %struct.murmur3_running_checksum*
ret %struct.murmur3_running_checksum* %4
}

LLVM IR (-O2):
%struct.murmur3_running_checksum = type opaque
%struct.running_checksum = type opaque
define %struct.murmur3_running_checksum* @rc_to_priv(%struct.running_checksum* readnone %0) {
%2 = bitcast %struct.running_checksum* %0 to %struct.murmur3_running_checksum*
ret %struct.murmur3_running_checksum* %2
}
/* Variables and functions */
int slibcpy(char **, char const *, int /*<<< orphan*/, int);
int paramstr(char **sout, char const *sin) { return slibcpy(sout, sin, 0, -3); }


x86 assembly (clang, -O0):
<paramstr>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
xor    %edx,%edx
mov    $0xfffffffd,%ecx
call   1030 <slibcpy@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<paramstr>:
xor    %edx,%edx
mov    $0xfffffffd,%ecx
jmp    1030 <slibcpy@plt>

LLVM IR (-O0):
define i32 @paramstr(i8** %0, i8* %1) {
%3 = alloca i8**
%4 = alloca i8*
store i8** %0, i8*** %3
store i8* %1, i8** %4
%5 = load i8**, i8*** %3
%6 = load i8*, i8** %4
%7 = call i32 @slibcpy(i8** %5, i8* %6, i32 0, i32 -3)
ret i32 %7
}

LLVM IR (-O2):
define i32 @paramstr(i8** %0, i8* %1) {
%3 = tail call i32 @slibcpy(i8** %0, i8* %1, i32 0, i32 -3)
ret i32 %3
}
int test_imm_D8uint16_reg(unsigned short val) {
  return ((val) & (-0xD8 << 0)) ? -20 : -40;
}


x86 assembly (clang, -O0):
<test_imm_D8uint16_reg>:
push   %rbp
mov    %rsp,%rbp
mov    %di,%ax
mov    %ax,-0x2(%rbp)
movzwl -0x2(%rbp),%edx
and    $0xffffff28,%edx
mov    $0xffffffd8,%eax
mov    $0xffffffec,%ecx
cmp    $0x0,%edx
cmovne %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_imm_D8uint16_reg>:
test   $0xff28,%edi
mov    $0xffffffd8,%ecx
mov    $0xffffffec,%eax
cmove  %ecx,%eax
ret

LLVM IR (-O0):
define i32 @test_imm_D8uint16_reg(i16 zeroext %0) {
%2 = alloca i16
store i16 %0, i16* %2
%3 = load i16, i16* %2
%4 = zext i16 %3 to i32
%5 = and i32 %4, -216
%6 = icmp ne i32 %5, 0
%7 = zext i1 %6 to i64
%8 = select i1 %6, i32 -20, i32 -40
ret i32 %8
}

LLVM IR (-O2):
define i32 @test_imm_D8uint16_reg(i16 zeroext %0) {
%2 = and i16 %0, -216
%3 = icmp eq i16 %2, 0
%4 = select i1 %3, i32 -40, i32 -20
ret i32 %4
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ isxdigit(int);
void t_isxdigit_0x40() {
  Assert_real((isxdigit(64) == 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_isxdigit.c",
              325, ("isxdigit should be 0 for @"));
}


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

x86 assembly (clang, -O2):
<t_isxdigit_0x40>:
push   %rax
mov    $0x40,%edi
call   1030 <isxdigit@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
lea    0xec5(%rip),%rsi
lea    0xf67(%rip),%rcx
mov    $0x145,%edx
pop    %rax
jmp    1040 <Assert_real@plt>

LLVM IR (-O0):
@.str = [169 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_isxdigit.c\00"
@.str.1 = [27 x i8] c"isxdigit should be 0 for @\00"
define void @t_isxdigit_0x40() {
%1 = call i64 @isxdigit(i32 64)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([169 x i8], [169 x i8]* @.str, i64 0, i64 0), i32 325, i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [169 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_isxdigit.c\00"
@.str.1 = [27 x i8] c"isxdigit should be 0 for @\00"
define void @t_isxdigit_0x40() {
%1 = tail call i64 @isxdigit(i32 64)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = tail call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([169 x i8], [169 x i8]* @.str, i64 0, i64 0), i32 325, i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.1, i64 0, i64 0))
ret void
}
void val_delete_vit_cand(void *v) { (void)v; }


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

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

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

LLVM IR (-O2):
define void @val_delete_vit_cand(i8* nocapture %0) {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ put32(unsigned int);
int /*<<< orphan*/ put8(int);
void mov_eax_memoffs32(unsigned int *memoffs32) {
  put8(0xA1);
  put32((unsigned int)(memoffs32));
}


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

x86 assembly (clang, -O2):
<mov_eax_memoffs32>:
push   %rbx
mov    %rdi,%rbx
mov    $0xa1,%edi
call   1030 <put8@plt>
mov    %ebx,%edi
pop    %rbx
jmp    1040 <put32@plt>

LLVM IR (-O0):
define void @mov_eax_memoffs32(i32* %0) {
%2 = alloca i32*
store i32* %0, i32** %2
%3 = call i32 @put8(i32 161)
%4 = load i32*, i32** %2
%5 = ptrtoint i32* %4 to i32
%6 = call i32 @put32(i32 %5)
ret void
}

LLVM IR (-O2):
define void @mov_eax_memoffs32(i32* %0) {
%2 = tail call i32 @put8(i32 161)
%3 = ptrtoint i32* %0 to i64
%4 = trunc i64 %3 to i32
%5 = tail call i32 @put32(i32 %4)
ret void
}
int test3(int e, int f) { return e & (e ^ f); }


x86 assembly (clang, -O0):
<test3>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x4(%rbp),%eax
mov    -0x4(%rbp),%ecx
xor    -0x8(%rbp),%ecx
and    %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<test3>:
mov    %esi,%eax
not    %eax
and    %edi,%eax
ret

LLVM IR (-O0):
define i32 @test3(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* %3
%7 = load i32, i32* %4
%8 = xor i32 %6, %7
%9 = and i32 %5, %8
ret i32 %9
}

LLVM IR (-O2):
define i32 @test3(i32 %0, i32 %1) {
%3 = xor i32 %1, -1
%4 = and i32 %3, %0
ret i32 %4
}
int one() { return 2; }


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

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

LLVM IR (-O0):
define i32 @one() {
ret i32 2
}

LLVM IR (-O2):
define i32 @one() {
ret i32 2
}
/* Variables and functions */
int /*<<< orphan*/ print_file(char *);
int main(int argc, char **argv) {
  if (argc < 2) {
    return -1;
  }
  print_file(argv[1]);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpl   $0x2,-0x8(%rbp)
jge    113c <main+0x2c>
movl   $0xffffffff,-0x4(%rbp)
jmp    1150 <main+0x40>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
call   1030 <print_file@plt>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
mov    $0xffffffff,%eax
cmp    $0x2,%edi
jl     112a <main+0x1a>
push   %rax
mov    0x8(%rsi),%rdi
call   1030 <print_file@plt>
xor    %eax,%eax
add    $0x8,%rsp
ret

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

LLVM IR (-O2):
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = icmp slt i32 %0, 2
br i1 %3, label %8, label %4
4: ; preds = %2
%5 = getelementptr inbounds i8*, i8** %1, i64 1
%6 = load i8*, i8** %5
%7 = tail call i32 @print_file(i8* %6)
br label %8
8: ; preds = %2, %4
%9 = phi i32 [ 0, %4 ], [ -1, %2 ]
ret i32 %9
}
/* Variables and functions */
int /*<<< orphan*/ wpa_supplicant_disassociate(void *, int);
void _wpa_supplicant_disassociate(void *wpa_s, int reason_code) {
  wpa_supplicant_disassociate(wpa_s, reason_code);
}


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

x86 assembly (clang, -O2):
<_wpa_supplicant_disassociate>:
jmp    1030 <wpa_supplicant_disassociate@plt>

LLVM IR (-O0):
define void @_wpa_supplicant_disassociate(i8* %0, i32 %1) {
%3 = alloca i8*
%4 = alloca i32
store i8* %0, i8** %3
store i32 %1, i32* %4
%5 = load i8*, i8** %3
%6 = load i32, i32* %4
%7 = call i32 @wpa_supplicant_disassociate(i8* %5, i32 %6)
ret void
}

LLVM IR (-O2):
define void @_wpa_supplicant_disassociate(i8* %0, i32 %1) {
%3 = tail call i32 @wpa_supplicant_disassociate(i8* %0, i32 %1)
ret void
}
/* Type definitions */
typedef int uint8_t;

/* Variables and functions */
uint8_t z80_cb_98_res_3(uint8_t value) { return value & 0xf7; }


x86 assembly (clang, -O0):
<z80_cb_98_res_3>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%eax
and    $0xf7,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<z80_cb_98_res_3>:
mov    %edi,%eax
and    $0xf7,%eax
ret

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

LLVM IR (-O2):
define i32 @z80_cb_98_res_3(i32 %0) {
%2 = and i32 %0, 247
ret i32 %2
}
/* Type definitions */
typedef int /*<<< orphan*/ GLfloat;

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


x86 assembly (clang, -O0):
<floattoint>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
lea    -0x4(%rbp),%rax
mov    %rax,-0x10(%rbp)
lea    -0x8(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    -0x10(%rbp),%rax
mov    (%rax),%ecx
mov    -0x18(%rbp),%rax
mov    %ecx,(%rax)
mov    -0x8(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<floattoint>:
mov    %edi,%eax
ret

LLVM IR (-O0):
define i32 @floattoint(i32 %0) {
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32*
%5 = alloca i32*
store i32 %0, i32* %2
store i32 0, i32* %3
store i32* %2, i32** %4
store i32* %3, i32** %5
%6 = load i32*, i32** %4
%7 = load i32, i32* %6
%8 = load i32*, i32** %5
store i32 %7, i32* %8
%9 = load i32, i32* %3
ret i32 %9
}

LLVM IR (-O2):
define i32 @floattoint(i32 returned %0) {
ret i32 %0
}
/* Variables and functions */
int /*<<< orphan*/ powerpc405_init();
void _profile_init(void) {
  int i;
  powerpc405_init();
}


x86 assembly (clang, -O0):
<_profile_init>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x0,%al
call   1030 <powerpc405_init@plt>
add    $0x10,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
define void @_profile_init() {
%1 = alloca i32
%2 = call i32 (...) @powerpc405_init()
ret void
}

LLVM IR (-O2):
define void @_profile_init() {
%1 = tail call i32 (...) @powerpc405_init()
ret void
}
void TestIsEqual(void) {
  (void)0;
  (void)0;
  (void)0;
  (void)0;
  (void)0;
  (void)0;
}


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

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

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

LLVM IR (-O2):
define void @TestIsEqual() {
ret void
}
int stringLength(char string[]) {
  int index = 0;
  while (string[index] != '\0') {
    index++;
  }
  return index;
}


x86 assembly (clang, -O0):
<stringLength>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
mov    -0x8(%rbp),%rax
movslq -0xc(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x0,%eax
je     1132 <stringLength+0x32>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    110f <stringLength+0xf>
mov    -0xc(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<stringLength>:
mov    $0xffffffff,%eax
cs nopw 0x0(%rax,%rax,1)
nop
add    $0x1,%eax
cmpb   $0x0,(%rdi)
lea    0x1(%rdi),%rdi
jne    1110 <stringLength+0x10>
ret

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

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


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

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

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

LLVM IR (-O2):
define void @ERR_peek_error_line_data() {
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ GLvoid;
typedef int /*<<< orphan*/ GLsizei;
typedef int /*<<< orphan*/ GLenum;

/* Variables and functions */
int /*<<< orphan*/ glDrawPixels(int /*<<< orphan*/, int /*<<< orphan*/,
                                int /*<<< orphan*/, int /*<<< orphan*/,
                                int /*<<< orphan*/ *);
void DrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type,
                GLvoid *pixels) {
  glDrawPixels(width, height, format, type, pixels);
}


x86 assembly (clang, -O0):
<DrawPixels>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %ecx,-0x10(%rbp)
mov    %r8,-0x18(%rbp)
mov    -0x4(%rbp),%edi
mov    -0x8(%rbp),%esi
mov    -0xc(%rbp),%edx
mov    -0x10(%rbp),%ecx
mov    -0x18(%rbp),%r8
call   1030 <glDrawPixels@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<DrawPixels>:
jmp    1030 <glDrawPixels@plt>

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

LLVM IR (-O2):
define void @DrawPixels(i32 %0, i32 %1, i32 %2, i32 %3, i32* %4) {
%6 = tail call i32 @glDrawPixels(i32 %0, i32 %1, i32 %2, i32 %3, i32* %4)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ e_ror();
int /*<<< orphan*/ e_writeback();
int /*<<< orphan*/ e_zp();
void e_ror_zp() {
  e_zp();
  e_ror();
  e_writeback();
}


x86 assembly (clang, -O0):
<e_ror_zp>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1050 <e_zp@plt>
mov    $0x0,%al
call   1030 <e_ror@plt>
mov    $0x0,%al
call   1040 <e_writeback@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<e_ror_zp>:
push   %rax
xor    %eax,%eax
call   1050 <e_zp@plt>
xor    %eax,%eax
call   1030 <e_ror@plt>
xor    %eax,%eax
pop    %rcx
jmp    1040 <e_writeback@plt>

LLVM IR (-O0):
define void @e_ror_zp() {
%1 = call i32 (...) @e_zp()
%2 = call i32 (...) @e_ror()
%3 = call i32 (...) @e_writeback()
ret void
}

LLVM IR (-O2):
define void @e_ror_zp() {
%1 = tail call i32 (...) @e_zp()
%2 = tail call i32 (...) @e_ror()
%3 = tail call i32 (...) @e_writeback()
ret void
}
/* Type definitions */
typedef int uint32_t;
typedef int uint16_t;

/* Variables and functions */
int random16();
uint16_t random16_max(uint16_t lim) {
  uint16_t r = random16();
  uint32_t p = (uint32_t)lim * (uint32_t)r;
  r = p >> 16;
  return r;
}


x86 assembly (clang, -O0):
<random16_max>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    $0x0,%al
call   1030 <random16@plt>
mov    %eax,-0x8(%rbp)
mov    -0x4(%rbp),%eax
imul   -0x8(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%eax
sar    $0x10,%eax
mov    %eax,-0x8(%rbp)
mov    -0x8(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<random16_max>:
push   %rbx
mov    %edi,%ebx
xor    %eax,%eax
call   1030 <random16@plt>
imul   %ebx,%eax
sar    $0x10,%eax
pop    %rbx
ret

LLVM IR (-O0):
define i32 @random16_max(i32 %0) {
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
store i32 %0, i32* %2
%5 = call i32 (...) @random16()
store i32 %5, i32* %3
%6 = load i32, i32* %2
%7 = load i32, i32* %3
%8 = mul nsw i32 %6, %7
store i32 %8, i32* %4
%9 = load i32, i32* %4
%10 = ashr i32 %9, 16
store i32 %10, i32* %3
%11 = load i32, i32* %3
ret i32 %11
}

LLVM IR (-O2):
define i32 @random16_max(i32 %0) {
%2 = tail call i32 (...) @random16()
%3 = mul nsw i32 %2, %0
%4 = ashr i32 %3, 16
ret i32 %4
}
/* Type definitions */
struct sockaddr {
  int dummy;
};
struct fd_info {
  int dummy;
};
typedef int /*<<< orphan*/ socklen_t;

/* Variables and functions */
int /*<<< orphan*/ ENOTSOCK;
int /*<<< orphan*/ errno;
int stdin_getsockname(struct fd_info *info, struct sockaddr *addr,
                      socklen_t *addrlen) {
  errno = ENOTSOCK;
  return -1;
}


x86 assembly (clang, -O0):
<stdin_getsockname>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    0x2ec9(%rip),%rax
mov    (%rax),%ecx
mov    0x2eb8(%rip),%rax
mov    %ecx,(%rax)
mov    $0xffffffff,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<stdin_getsockname>:
mov    0x2ed9(%rip),%rax
mov    (%rax),%eax
mov    0x2ec8(%rip),%rcx
mov    %eax,(%rcx)
mov    $0xffffffff,%eax
ret

LLVM IR (-O0):
%struct.fd_info = type { i32 }
%struct.sockaddr = type { i32 }
@ENOTSOCK = global i32 0
@errno = global i32 0
define i32 @stdin_getsockname(%struct.fd_info* %0, %struct.sockaddr* %1, i32* %2) {
%4 = alloca %struct.fd_info*
%5 = alloca %struct.sockaddr*
%6 = alloca i32*
store %struct.fd_info* %0, %struct.fd_info** %4
store %struct.sockaddr* %1, %struct.sockaddr** %5
store i32* %2, i32** %6
%7 = load i32, i32* @ENOTSOCK
store i32 %7, i32* @errno
ret i32 -1
}

LLVM IR (-O2):
%struct.fd_info = type { i32 }
%struct.sockaddr = type { i32 }
@ENOTSOCK = global i32 0
@errno = global i32 0
define i32 @stdin_getsockname(%struct.fd_info* nocapture readnone %0, %struct.sockaddr* nocapture readnone %1, i32* nocapture readnone %2) {
%4 = load i32, i32* @ENOTSOCK
store i32 %4, i32* @errno
ret i32 -1
}
/* Type definitions */
typedef int /*<<< orphan*/ __m128;

/* Variables and functions */
int /*<<< orphan*/ _mm_cvtsi64_ss(int /*<<< orphan*/, long long);
__m128 test_mm_cvtsi64_ss(__m128 A, long long B) {
  return _mm_cvtsi64_ss(A, B);
}


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

x86 assembly (clang, -O2):
<test_mm_cvtsi64_ss>:
jmp    1030 <_mm_cvtsi64_ss@plt>

LLVM IR (-O0):
define i32 @test_mm_cvtsi64_ss(i32 %0, i64 %1) {
%3 = alloca i32
%4 = alloca i64
store i32 %0, i32* %3
store i64 %1, i64* %4
%5 = load i32, i32* %3
%6 = load i64, i64* %4
%7 = call i32 @_mm_cvtsi64_ss(i32 %5, i64 %6)
ret i32 %7
}

LLVM IR (-O2):
define i32 @test_mm_cvtsi64_ss(i32 %0, i64 %1) {
%3 = tail call i32 @_mm_cvtsi64_ss(i32 %0, i64 %1)
ret i32 %3
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
int syscall(int, char *, char *);
int main(int argc, char *argv[]) {
  int i;
  if (argc != 3)
    printf("error\n");
  else {
    i = syscall(338, argv[1], argv[2]);
    printf("success\n");
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpl   $0x3,-0x8(%rbp)
je     1151 <main+0x31>
lea    0xeb9(%rip),%rdi
call   1030 <printf@plt>
jmp    117a <main+0x5a>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rsi
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdx
mov    $0x152,%edi
call   1040 <syscall@plt>
mov    %eax,-0x14(%rbp)
lea    0xe92(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
cmp    $0x3,%edi
jne    1144 <main+0x24>
mov    0x8(%rsi),%rax
mov    0x10(%rsi),%rdx
mov    $0x152,%edi
mov    %rax,%rsi
call   1040 <syscall@plt>
lea    0xebe(%rip),%rdi
jmp    114b <main+0x2b>
lea    0xebd(%rip),%rdi
call   1030 <puts@plt>
xor    %eax,%eax
pop    %rcx
ret

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

LLVM IR (-O2):
@str = [8 x i8] c"success\00"
@str.2 = [6 x i8] c"error\00"
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = icmp eq i32 %0, 3
br i1 %3, label %4, label %10
4: ; preds = %2
%5 = getelementptr inbounds i8*, i8** %1, i64 1
%6 = load i8*, i8** %5
%7 = getelementptr inbounds i8*, i8** %1, i64 2
%8 = load i8*, i8** %7
%9 = tail call i32 @syscall(i32 338, i8* %6, i8* %8)
br label %10
10: ; preds = %2, %4
%11 = phi i8* [ getelementptr inbounds ([8 x i8], [8 x i8]* @str, i64 0, i64 0), %4 ], [ getelementptr inbounds ([6 x i8], [6 x i8]* @str.2, i64 0, i64 0), %2 ]
%12 = tail call i32 @puts(i8* dereferenceable(1) %11)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ Key(int, int /*<<< orphan*/, int /*<<< orphan*/);
void Menu(int value) { Key(value, 0, 0); }


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

x86 assembly (clang, -O2):
<Menu>:
xor    %esi,%esi
xor    %edx,%edx
jmp    1030 <Key@plt>

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

LLVM IR (-O2):
define void @Menu(i32 %0) {
%2 = tail call i32 @Key(i32 %0, i32 0, i32 0)
ret void
}
/* Variables and functions */
scalar_t__ fflush(int /*<<< orphan*/ *);
int /*<<< orphan*/ perror(char *);
int /*<<< orphan*/ printf(char *);
void handler(int sig) {
  printf("U can't touch this. Break it down. Stop Hammer time!\n");
  if (fflush(NULL) != 0) {
    perror("Ouch! (^_^')");
  }
}


x86 assembly (clang, -O0):
<handler>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
lea    0xebe(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
mov    %eax,%edi
call   1040 <fflush@plt>
cmp    $0x0,%rax
je     1166 <handler+0x36>
lea    0xed5(%rip),%rdi
call   1050 <perror@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<handler>:
push   %rax
lea    0xed5(%rip),%rdi
call   1030 <puts@plt>
xor    %edi,%edi
call   1040 <fflush@plt>
test   %rax,%rax
jne    114b <handler+0x1b>
pop    %rax
ret
lea    0xeae(%rip),%rdi
pop    %rax
jmp    1050 <perror@plt>

LLVM IR (-O0):
@.str = [54 x i8] c"U can't touch this. Break it down. Stop Hammer time!\0A\00"
@.str.1 = [13 x i8] c"Ouch! (^_^')\00"
define void @handler(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = call i32 @printf(i8* getelementptr inbounds ([54 x i8], [54 x i8]* @.str, i64 0, i64 0))
%4 = call i64 @fflush(i32* null)
%5 = icmp ne i64 %4, 0
br i1 %5, label %6, label %8
6: ; preds = %1
%7 = call i32 @perror(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.1, i64 0, i64 0))
br label %8
8: ; preds = %6, %1
ret void
}

LLVM IR (-O2):
@.str.1 = [13 x i8] c"Ouch! (^_^')\00"
@str = [53 x i8] c"U can't touch this. Break it down. Stop Hammer time!\00"
define void @handler(i32 %0) {
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([53 x i8], [53 x i8]* @str, i64 0, i64 0))
%3 = tail call i64 @fflush(i32* null)
%4 = icmp eq i64 %3, 0
br i1 %4, label %7, label %5
5: ; preds = %1
%6 = tail call i32 @perror(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.1, i64 0, i64 0))
br label %7
7: ; preds = %5, %1
ret void
}
/* Variables and functions */
int /*<<< orphan*/ F_GETFL;
int /*<<< orphan*/ F_SETFL;
int fcntl(int, int /*<<< orphan*/, int);
void set_fdflag(int fd, int newflag, int set) {
  int flags;
  flags = fcntl(fd, F_GETFL, 0);
  if (set) {
    fcntl(fd, F_SETFL, flags | newflag);
  } else {
    fcntl(fd, F_SETFL, flags & ~newflag);
  }
}


x86 assembly (clang, -O0):
<set_fdflag>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    -0x4(%rbp),%edi
mov    0x2ead(%rip),%rax
mov    (%rax),%esi
xor    %edx,%edx
call   1030 <fcntl@plt>
mov    %eax,-0x10(%rbp)
cmpl   $0x0,-0xc(%rbp)
je     115d <set_fdflag+0x4d>
mov    -0x4(%rbp),%edi
mov    0x2e95(%rip),%rax
mov    (%rax),%esi
mov    -0x10(%rbp),%edx
or     -0x8(%rbp),%edx
call   1030 <fcntl@plt>
jmp    1179 <set_fdflag+0x69>
mov    -0x4(%rbp),%edi
mov    0x2e79(%rip),%rax
mov    (%rax),%esi
mov    -0x10(%rbp),%edx
mov    -0x8(%rbp),%eax
xor    $0xffffffff,%eax
and    %eax,%edx
call   1030 <fcntl@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<set_fdflag>:
push   %rbp
push   %r14
push   %rbx
mov    %edx,%r14d
mov    %esi,%ebp
mov    %edi,%ebx
mov    0x2eb6(%rip),%rax
mov    (%rax),%esi
xor    %edx,%edx
call   1030 <fcntl@plt>
mov    %ebp,%ecx
not    %ecx
and    %eax,%ecx
or     %eax,%ebp
test   %r14d,%r14d
mov    0x2ea3(%rip),%rax
mov    (%rax),%esi
cmove  %ecx,%ebp
mov    %ebx,%edi
mov    %ebp,%edx
pop    %rbx
pop    %r14
pop    %rbp
jmp    1030 <fcntl@plt>

LLVM IR (-O0):
@F_GETFL = global i32 0
@F_SETFL = global i32 0
define void @set_fdflag(i32 %0, i32 %1, i32 %2) {
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
store i32 %0, i32* %4
store i32 %1, i32* %5
store i32 %2, i32* %6
%8 = load i32, i32* %4
%9 = load i32, i32* @F_GETFL
%10 = call i32 @fcntl(i32 %8, i32 %9, i32 0)
store i32 %10, i32* %7
%11 = load i32, i32* %6
%12 = icmp ne i32 %11, 0
br i1 %12, label %13, label %20
13: ; preds = %3
%14 = load i32, i32* %4
%15 = load i32, i32* @F_SETFL
%16 = load i32, i32* %7
%17 = load i32, i32* %5
%18 = or i32 %16, %17
%19 = call i32 @fcntl(i32 %14, i32 %15, i32 %18)
br label %28
20: ; preds = %3
%21 = load i32, i32* %4
%22 = load i32, i32* @F_SETFL
%23 = load i32, i32* %7
%24 = load i32, i32* %5
%25 = xor i32 %24, -1
%26 = and i32 %23, %25
%27 = call i32 @fcntl(i32 %21, i32 %22, i32 %26)
br label %28
28: ; preds = %20, %13
ret void
}

LLVM IR (-O2):
@F_GETFL = global i32 0
@F_SETFL = global i32 0
define void @set_fdflag(i32 %0, i32 %1, i32 %2) {
%4 = load i32, i32* @F_GETFL
%5 = tail call i32 @fcntl(i32 %0, i32 %4, i32 0)
%6 = icmp eq i32 %2, 0
%7 = load i32, i32* @F_SETFL
%8 = xor i32 %1, -1
%9 = and i32 %5, %8
%10 = or i32 %5, %1
%11 = select i1 %6, i32 %9, i32 %10
%12 = tail call i32 @fcntl(i32 %0, i32 %7, i32 %11)
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ WINDOW;

/* Variables and functions */
int waddnstr(WINDOW *w, const char *s, int n) { return 0; }


x86 assembly (clang, -O0):
<waddnstr>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
xor    %eax,%eax
pop    %rbp
ret

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

LLVM IR (-O0):
define i32 @waddnstr(i32* %0, i8* %1, i32 %2) {
%4 = alloca i32*
%5 = alloca i8*
%6 = alloca i32
store i32* %0, i32** %4
store i8* %1, i8** %5
store i32 %2, i32* %6
ret i32 0
}

LLVM IR (-O2):
define i32 @waddnstr(i32* nocapture readnone %0, i8* nocapture readnone %1, i32 %2) {
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ fatal(char *);
int /*<<< orphan*/ free(void *);
void _xfree(void *ptr) {
  if (!ptr)
    fatal("xfree: NULL pointer given as argument");
  free(ptr);
}


x86 assembly (clang, -O0):
<_xfree>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
cmpq   $0x0,-0x8(%rbp)
jne    1143 <_xfree+0x23>
lea    0xec2(%rip),%rdi
call   1040 <fatal@plt>
mov    -0x8(%rbp),%rdi
call   1030 <free@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<_xfree>:
push   %rbx
mov    %rdi,%rbx
test   %rdi,%rdi
jne    1135 <_xfree+0x15>
lea    0xed0(%rip),%rdi
call   1040 <fatal@plt>
mov    %rbx,%rdi
pop    %rbx
jmp    1030 <free@plt>

LLVM IR (-O0):
@.str = [38 x i8] c"xfree: NULL pointer given as argument\00"
define void @_xfree(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = icmp ne i8* %3, null
br i1 %4, label %7, label %5
5: ; preds = %1
%6 = call i32 @fatal(i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str, i64 0, i64 0))
br label %7
7: ; preds = %5, %1
%8 = load i8*, i8** %2
%9 = call i32 @free(i8* %8)
ret void
}

LLVM IR (-O2):
@.str = [38 x i8] c"xfree: NULL pointer given as argument\00"
define void @_xfree(i8* %0) {
%2 = icmp eq i8* %0, null
br i1 %2, label %3, label %5
3: ; preds = %1
%4 = tail call i32 @fatal(i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str, i64 0, i64 0))
br label %5
5: ; preds = %3, %1
%6 = tail call i32 @free(i8* %0)
ret void
}
float Function10Float(float a, float b, float c, float d, float e, float f,
                      float g, float h, float i, float j) {
  return a + b + c + d + e + f + g + h + i + j;
}


x86 assembly (clang, -O0):
<Function10Float>:
push   %rbp
mov    %rsp,%rbp
movss  0x18(%rbp),%xmm8
movss  0x10(%rbp),%xmm8
movss  %xmm0,-0x4(%rbp)
movss  %xmm1,-0x8(%rbp)
movss  %xmm2,-0xc(%rbp)
movss  %xmm3,-0x10(%rbp)
movss  %xmm4,-0x14(%rbp)
movss  %xmm5,-0x18(%rbp)
movss  %xmm6,-0x1c(%rbp)
movss  %xmm7,-0x20(%rbp)
movss  -0x4(%rbp),%xmm0
addss  -0x8(%rbp),%xmm0
addss  -0xc(%rbp),%xmm0
addss  -0x10(%rbp),%xmm0
addss  -0x14(%rbp),%xmm0
addss  -0x18(%rbp),%xmm0
addss  -0x1c(%rbp),%xmm0
addss  -0x20(%rbp),%xmm0
addss  0x10(%rbp),%xmm0
addss  0x18(%rbp),%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<Function10Float>:
addss  %xmm1,%xmm0
addss  %xmm2,%xmm0
addss  %xmm3,%xmm0
addss  %xmm4,%xmm0
addss  %xmm5,%xmm0
addss  %xmm6,%xmm0
addss  %xmm7,%xmm0
addss  0x8(%rsp),%xmm0
addss  0x10(%rsp),%xmm0
ret

LLVM IR (-O0):
define float @Function10Float(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, float %8, float %9) {
%11 = alloca float
%12 = alloca float
%13 = alloca float
%14 = alloca float
%15 = alloca float
%16 = alloca float
%17 = alloca float
%18 = alloca float
%19 = alloca float
%20 = alloca float
store float %0, float* %11
store float %1, float* %12
store float %2, float* %13
store float %3, float* %14
store float %4, float* %15
store float %5, float* %16
store float %6, float* %17
store float %7, float* %18
store float %8, float* %19
store float %9, float* %20
%21 = load float, float* %11
%22 = load float, float* %12
%23 = fadd float %21, %22
%24 = load float, float* %13
%25 = fadd float %23, %24
%26 = load float, float* %14
%27 = fadd float %25, %26
%28 = load float, float* %15
%29 = fadd float %27, %28
%30 = load float, float* %16
%31 = fadd float %29, %30
%32 = load float, float* %17
%33 = fadd float %31, %32
%34 = load float, float* %18
%35 = fadd float %33, %34
%36 = load float, float* %19
%37 = fadd float %35, %36
%38 = load float, float* %20
%39 = fadd float %37, %38
ret float %39
}

LLVM IR (-O2):
define float @Function10Float(float %0, float %1, float %2, float %3, float %4, float %5, float %6, float %7, float %8, float %9) {
%11 = fadd float %0, %1
%12 = fadd float %11, %2
%13 = fadd float %12, %3
%14 = fadd float %13, %4
%15 = fadd float %14, %5
%16 = fadd float %15, %6
%17 = fadd float %16, %7
%18 = fadd float %17, %8
%19 = fadd float %18, %9
ret float %19
}
/* Variables and functions */
int bar(int);
int foo(int a, int b) { return a * bar(b); }


x86 assembly (clang, -O0):
<foo>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x4(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0x8(%rbp),%edi
call   1030 <bar@plt>
mov    %eax,%ecx
mov    -0xc(%rbp),%eax
imul   %ecx,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<foo>:
push   %rbx
mov    %edi,%ebx
mov    %esi,%edi
call   1030 <bar@plt>
imul   %ebx,%eax
pop    %rbx
ret

LLVM IR (-O0):
define i32 @foo(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
store i32 %0, i32* %3
store i32 %1, i32* %4
%5 = load i32, i32* %3
%6 = load i32, i32* %4
%7 = call i32 @bar(i32 %6)
%8 = mul nsw i32 %5, %7
ret i32 %8
}

LLVM IR (-O2):
define i32 @foo(i32 %0, i32 %1) {
%3 = tail call i32 @bar(i32 %1)
%4 = mul nsw i32 %3, %0
ret i32 %4
}