xunge/DecIR huggingface dataset:
int getmntinfo(struct statfs **__mntbufp, int __flags) {
  anvil_syslog(0, "%s unimplemented %s\n", __FUNCTION__);
  return 0;
}


x86 assembly (clang, -O0):
<getmntinfo>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
xor    %edi,%edi
lea    0xed8(%rip),%rsi
lea    0xee6(%rip),%rdx
mov    $0x0,%al
call   1030 <anvil_syslog@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<getmntinfo>:
push   %rax
lea    0xee8(%rip),%rsi
lea    0xef6(%rip),%rdx
xor    %edi,%edi
xor    %eax,%eax
call   1030 <anvil_syslog@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
%struct.statfs = type opaque
@.str = [21 x i8] c"%s unimplemented %s\0A\00"
@__FUNCTION__.getmntinfo = [11 x i8] c"getmntinfo\00"
define i32 @getmntinfo(%struct.statfs** %0, i32 %1) {
%3 = alloca %struct.statfs**
%4 = alloca i32
store %struct.statfs** %0, %struct.statfs*** %3
store i32 %1, i32* %4
%5 = call i32 (i32, i8*, i8*, ...) bitcast (i32 (...)* @anvil_syslog to i32 (i32, i8*, i8*, ...)*)(i32 0, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([11 x i8], [11 x i8]* @__FUNCTION__.getmntinfo, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
%struct.statfs = type opaque
@.str = [21 x i8] c"%s unimplemented %s\0A\00"
@__FUNCTION__.getmntinfo = [11 x i8] c"getmntinfo\00"
define i32 @getmntinfo(%struct.statfs** nocapture readnone %0, i32 %1) {
%3 = tail call i32 (i32, i8*, i8*, ...) bitcast (i32 (...)* @anvil_syslog to i32 (i32, i8*, i8*, ...)*)(i32 0, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([11 x i8], [11 x i8]* @__FUNCTION__.getmntinfo, i64 0, i64 0))
ret i32 0
}
/* Type definitions */
struct tree_node {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ INT_MAX;
int /*<<< orphan*/ INT_MIN;
int is_bst_aux(struct tree_node *, int /*<<< orphan*/, int /*<<< orphan*/);
int is_bst(struct tree_node *root) {
  return is_bst_aux(root, INT_MIN, INT_MAX);
}


x86 assembly (clang, -O0):
<is_bst>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
mov    0x2eb9(%rip),%rax
mov    (%rax),%esi
mov    0x2eb8(%rip),%rax
mov    (%rax),%edx
call   1030 <is_bst_aux@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_bst>:
mov    0x2ec9(%rip),%rax
mov    (%rax),%esi
mov    0x2ec8(%rip),%rax
mov    (%rax),%edx
jmp    1030 <is_bst_aux@plt>

LLVM IR (-O0):
%struct.tree_node = type { i32 }
@INT_MIN = global i32 0
@INT_MAX = global i32 0
define i32 @is_bst(%struct.tree_node* %0) {
%2 = alloca %struct.tree_node*
store %struct.tree_node* %0, %struct.tree_node** %2
%3 = load %struct.tree_node*, %struct.tree_node** %2
%4 = load i32, i32* @INT_MIN
%5 = load i32, i32* @INT_MAX
%6 = call i32 @is_bst_aux(%struct.tree_node* %3, i32 %4, i32 %5)
ret i32 %6
}

LLVM IR (-O2):
%struct.tree_node = type { i32 }
@INT_MIN = global i32 0
@INT_MAX = global i32 0
define i32 @is_bst(%struct.tree_node* %0) {
%2 = load i32, i32* @INT_MIN
%3 = load i32, i32* @INT_MAX
%4 = tail call i32 @is_bst_aux(%struct.tree_node* %0, i32 %2, i32 %3)
ret i32 %4
}
/* Type definitions */
typedef scalar_t__ mode_t;

/* Variables and functions */
int /*<<< orphan*/ dir_mutex_lock(int);
int /*<<< orphan*/ dir_mutex_unlock();
int mkdir(char const *, scalar_t__);
int mkdirat(int dirfd, const char *pathname, mode_t mode) {
  int rc;
  if (mode) {
  }
  dir_mutex_lock(dirfd);
  rc = mkdir(pathname, mode);
  dir_mutex_unlock();
  return rc;
}


x86 assembly (clang, -O0):
<mkdirat>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
cmpq   $0x0,-0x18(%rbp)
je     1153 <mkdirat+0x23>
jmp    1153 <mkdirat+0x23>
mov    -0x4(%rbp),%edi
call   1040 <dir_mutex_lock@plt>
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
call   1030 <mkdir@plt>
mov    %eax,-0x1c(%rbp)
mov    $0x0,%al
call   1050 <dir_mutex_unlock@plt>
mov    -0x1c(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<mkdirat>:
push   %r14
push   %rbx
push   %rax
mov    %rdx,%r14
mov    %rsi,%rbx
call   1040 <dir_mutex_lock@plt>
mov    %rbx,%rdi
mov    %r14,%rsi
call   1030 <mkdir@plt>
mov    %eax,%ebx
xor    %eax,%eax
call   1050 <dir_mutex_unlock@plt>
mov    %ebx,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
define i32 @mkdirat(i32 %0, i8* %1, i64 %2) {
%4 = alloca i32
%5 = alloca i8*
%6 = alloca i64
%7 = alloca i32
store i32 %0, i32* %4
store i8* %1, i8** %5
store i64 %2, i64* %6
%8 = load i64, i64* %6
%9 = icmp ne i64 %8, 0
br i1 %9, label %10, label %11
10: ; preds = %3
br label %11
11: ; preds = %10, %3
%12 = load i32, i32* %4
%13 = call i32 @dir_mutex_lock(i32 %12)
%14 = load i8*, i8** %5
%15 = load i64, i64* %6
%16 = call i32 @mkdir(i8* %14, i64 %15)
store i32 %16, i32* %7
%17 = call i32 (...) @dir_mutex_unlock()
%18 = load i32, i32* %7
ret i32 %18
}

LLVM IR (-O2):
define i32 @mkdirat(i32 %0, i8* nocapture %1, i64 %2) {
%4 = tail call i32 @dir_mutex_lock(i32 %0)
%5 = tail call i32 @mkdir(i8* %1, i64 %2)
%6 = tail call i32 (...) @dir_mutex_unlock()
ret i32 %5
}
/* Type definitions */
struct ambapp_dev_hdr {
  int dummy;
};
struct ambapp_apb_info {
  int dummy;
};

/* Variables and functions */
int ambapp_find_apbslvs_next(struct ambapp_dev_hdr *, int, int,
                             struct ambapp_apb_info *, int /*<<< orphan*/, int);
int ambapp_find_apbslv(struct ambapp_dev_hdr *root, int vendor, int device,
                       struct ambapp_apb_info *dev) {
  return ambapp_find_apbslvs_next(root, vendor, device, dev, 0, 1);
}


x86 assembly (clang, -O0):
<ambapp_find_apbslv>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %edx,-0x10(%rbp)
mov    %rcx,-0x18(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
mov    -0x10(%rbp),%edx
mov    -0x18(%rbp),%rcx
xor    %r8d,%r8d
mov    $0x1,%r9d
call   1030 <ambapp_find_apbslvs_next@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ambapp_find_apbslv>:
xor    %r8d,%r8d
mov    $0x1,%r9d
jmp    1030 <ambapp_find_apbslvs_next@plt>

LLVM IR (-O0):
%struct.ambapp_dev_hdr = type { i32 }
%struct.ambapp_apb_info = type { i32 }
define i32 @ambapp_find_apbslv(%struct.ambapp_dev_hdr* %0, i32 %1, i32 %2, %struct.ambapp_apb_info* %3) {
%5 = alloca %struct.ambapp_dev_hdr*
%6 = alloca i32
%7 = alloca i32
%8 = alloca %struct.ambapp_apb_info*
store %struct.ambapp_dev_hdr* %0, %struct.ambapp_dev_hdr** %5
store i32 %1, i32* %6
store i32 %2, i32* %7
store %struct.ambapp_apb_info* %3, %struct.ambapp_apb_info** %8
%9 = load %struct.ambapp_dev_hdr*, %struct.ambapp_dev_hdr** %5
%10 = load i32, i32* %6
%11 = load i32, i32* %7
%12 = load %struct.ambapp_apb_info*, %struct.ambapp_apb_info** %8
%13 = call i32 @ambapp_find_apbslvs_next(%struct.ambapp_dev_hdr* %9, i32 %10, i32 %11, %struct.ambapp_apb_info* %12, i32 0, i32 1)
ret i32 %13
}

LLVM IR (-O2):
%struct.ambapp_dev_hdr = type { i32 }
%struct.ambapp_apb_info = type { i32 }
define i32 @ambapp_find_apbslv(%struct.ambapp_dev_hdr* %0, i32 %1, i32 %2, %struct.ambapp_apb_info* %3) {
%5 = tail call i32 @ambapp_find_apbslvs_next(%struct.ambapp_dev_hdr* %0, i32 %1, i32 %2, %struct.ambapp_apb_info* %3, i32 0, i32 1)
ret i32 %5
}
/* Variables and functions */
int omp_get_num_threads();
int omp_get_thread_num();
int /*<<< orphan*/ printf(char *, int, int);
void Hello(void) {
  int my_rank = omp_get_thread_num();
  int thread_count = omp_get_num_threads();
  printf("Hello from thread %d of %d\n", my_rank, thread_count);
}


x86 assembly (clang, -O0):
<Hello>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x0,%al
call   1030 <omp_get_thread_num@plt>
mov    %eax,-0x4(%rbp)
mov    $0x0,%al
call   1050 <omp_get_num_threads@plt>
mov    %eax,-0x8(%rbp)
mov    -0x4(%rbp),%esi
mov    -0x8(%rbp),%edx
lea    0xea7(%rip),%rdi
call   1040 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<Hello>:
push   %rbx
xor    %eax,%eax
call   1030 <omp_get_thread_num@plt>
mov    %eax,%ebx
xor    %eax,%eax
call   1050 <omp_get_num_threads@plt>
lea    0xeb8(%rip),%rdi
mov    %ebx,%esi
mov    %eax,%edx
pop    %rbx
jmp    1040 <printf@plt>

LLVM IR (-O0):
@.str = [28 x i8] c"Hello from thread %d of %d\0A\00"
define void @Hello() {
%1 = alloca i32
%2 = alloca i32
%3 = call i32 (...) @omp_get_thread_num()
store i32 %3, i32* %1
%4 = call i32 (...) @omp_get_num_threads()
store i32 %4, i32* %2
%5 = load i32, i32* %1
%6 = load i32, i32* %2
%7 = call i32 @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str, i64 0, i64 0), i32 %5, i32 %6)
ret void
}

LLVM IR (-O2):
@.str = [28 x i8] c"Hello from thread %d of %d\0A\00"
define void @Hello() {
%1 = tail call i32 (...) @omp_get_thread_num()
%2 = tail call i32 (...) @omp_get_num_threads()
%3 = tail call i32 @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str, i64 0, i64 0), i32 %1, i32 %2)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ init(char *);
int ok();
int /*<<< orphan*/ test();
int main() {
  init("while loop");
  test();
  return ok();
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeba(%rip),%rdi
call   1040 <init@plt>
mov    $0x0,%al
call   1050 <test@plt>
mov    $0x0,%al
call   1030 <ok@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xec8(%rip),%rdi
call   1040 <init@plt>
xor    %eax,%eax
call   1050 <test@plt>
xor    %eax,%eax
pop    %rcx
jmp    1030 <ok@plt>

LLVM IR (-O0):
@.str = [11 x i8] c"while loop\00"
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = call i32 @init(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0))
%3 = call i32 (...) @test()
%4 = call i32 (...) @ok()
ret i32 %4
}

LLVM IR (-O2):
@.str = [11 x i8] c"while loop\00"
define i32 @main() {
%1 = tail call i32 @init(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 (...) @test()
%3 = tail call i32 (...) @ok()
ret i32 %3
}
void null_test_success(void **state) {}


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

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

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

LLVM IR (-O2):
define void @null_test_success(i8** nocapture %0) {
ret void
}
void memcg_kmem_uncharge_pages(struct page *page, int order) {}


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

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

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

LLVM IR (-O2):
%struct.page = type opaque
define void @memcg_kmem_uncharge_pages(%struct.page* nocapture %0, i32 %1) {
ret void
}
/* Type definitions */
typedef int pthread_t;

/* Variables and functions */
pthread_t pthread_self(void) { return 1; }


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

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

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

LLVM IR (-O2):
define i32 @pthread_self() {
ret i32 1
}
/* Variables and functions */
int /*<<< orphan*/ ENODEV;
int /*<<< orphan*/ errno;
int fcntl(int fd, int cmd, int arg) {
  (void)fd;
  (void)cmd;
  (void)arg;
  errno = ENODEV;
  return -1;
}


x86 assembly (clang, -O0):
<fcntl>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    0x2ec4(%rip),%rax
mov    (%rax),%ecx
mov    0x2ec3(%rip),%rax
mov    %ecx,(%rax)
mov    $0xffffffff,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<fcntl>:
mov    0x2ed1(%rip),%rax
mov    (%rax),%eax
mov    0x2ed0(%rip),%rcx
mov    %eax,(%rcx)
mov    $0xffffffff,%eax
ret

LLVM IR (-O0):
@ENODEV = global i32 0
@errno = global i32 0
define i32 @fcntl(i32 %0, i32 %1, i32 %2) {
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
store i32 %0, i32* %4
store i32 %1, i32* %5
store i32 %2, i32* %6
%7 = load i32, i32* %4
%8 = load i32, i32* %5
%9 = load i32, i32* %6
%10 = load i32, i32* @ENODEV
store i32 %10, i32* @errno
ret i32 -1
}

LLVM IR (-O2):
@ENODEV = global i32 0
@errno = global i32 0
define i32 @fcntl(i32 %0, i32 %1, i32 %2) {
%4 = load i32, i32* @ENODEV
store i32 %4, i32* @errno
ret i32 -1
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, ...);
void error_epc(char *error, char *type_error) {
  printf("error: <stdin>:\n");
  printf(" -> %s:%s\n", error, type_error);
}


x86 assembly (clang, -O0):
<error_epc>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
lea    0xed9(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x8(%rbp),%rsi
mov    -0x10(%rbp),%rdx
lea    0xed4(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<error_epc>:
push   %r14
push   %rbx
push   %rax
mov    %rsi,%r14
mov    %rdi,%rbx
lea    0xeda(%rip),%rdi
call   1030 <puts@plt>
lea    0xec3(%rip),%rdi
mov    %rbx,%rsi
mov    %r14,%rdx
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1040 <printf@plt>

LLVM IR (-O0):
@.str = [17 x i8] c"error: <stdin>:\0A\00"
@.str.1 = [11 x i8] c" -> %s:%s\0A\00"
define void @error_epc(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
store i8* %0, i8** %3
store i8* %1, i8** %4
%5 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0))
%6 = load i8*, i8** %3
%7 = load i8*, i8** %4
%8 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0), i8* %6, i8* %7)
ret void
}

LLVM IR (-O2):
@.str.1 = [11 x i8] c" -> %s:%s\0A\00"
@str = [16 x i8] c"error: <stdin>:\00"
define void @error_epc(i8* %0, i8* %1) {
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @str, i64 0, i64 0))
%4 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0), i8* %0, i8* %1)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ abort();
int /*<<< orphan*/ error(char *, char const *, char const *, int, char const *,
                         char *);
void malloc_assert_failed(char *expr, const char *file, int line,
                          const char *caller, const char *func) {
  error("%s() Error: from %s:%d: %s(): Assertion (%s) failed", func, file, line,
        caller, expr);
  abort();
}


x86 assembly (clang, -O0):
<malloc_assert_failed>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
mov    -0x28(%rbp),%rsi
mov    -0x10(%rbp),%rdx
mov    -0x14(%rbp),%ecx
mov    -0x20(%rbp),%r8
mov    -0x8(%rbp),%r9
lea    0xeab(%rip),%rdi
call   1040 <error@plt>
mov    $0x0,%al
call   1030 <abort@plt>

x86 assembly (clang, -O2):
<malloc_assert_failed>:
push   %rax
mov    %rcx,%rax
mov    %edx,%ecx
mov    %rsi,%rdx
mov    %rdi,%r9
lea    0xecd(%rip),%rdi
mov    %r8,%rsi
mov    %rax,%r8
call   1040 <error@plt>
xor    %eax,%eax
call   1030 <abort@plt>

LLVM IR (-O0):
@.str = [52 x i8] c"%s() Error: from %s:%d: %s(): Assertion (%s) failed\00"
define void @malloc_assert_failed(i8* %0, i8* %1, i32 %2, i8* %3, i8* %4) {
%6 = alloca i8*
%7 = alloca i8*
%8 = alloca i32
%9 = alloca i8*
%10 = alloca i8*
store i8* %0, i8** %6
store i8* %1, i8** %7
store i32 %2, i32* %8
store i8* %3, i8** %9
store i8* %4, i8** %10
%11 = load i8*, i8** %10
%12 = load i8*, i8** %7
%13 = load i32, i32* %8
%14 = load i8*, i8** %9
%15 = load i8*, i8** %6
%16 = call i32 @error(i8* getelementptr inbounds ([52 x i8], [52 x i8]* @.str, i64 0, i64 0), i8* %11, i8* %12, i32 %13, i8* %14, i8* %15)
%17 = call i32 (...) @abort()
unreachable
}

LLVM IR (-O2):
@.str = [52 x i8] c"%s() Error: from %s:%d: %s(): Assertion (%s) failed\00"
define void @malloc_assert_failed(i8* %0, i8* %1, i32 %2, i8* %3, i8* %4) {
%6 = tail call i32 @error(i8* getelementptr inbounds ([52 x i8], [52 x i8]* @.str, i64 0, i64 0), i8* %4, i8* %1, i32 %2, i8* %3, i8* %0)
%7 = tail call i32 (...) @abort()
unreachable
}
void avio_wb32() {}


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

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

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

LLVM IR (-O2):
define void @avio_wb32() {
ret void
}
unsigned xrop3_7_0_1(unsigned char s, unsigned char t) {
  unsigned D = 0x00ff;
  unsigned S = ((unsigned)s << 8) | s;
  unsigned T = ((unsigned)t << 8) | t;
  unsigned stk1;
  unsigned stk2;
  stk2 = D & S;
  stk1 = T | stk2;
  stk1 = ~stk1;
  return (stk1 & S) | (stk1 & (~T)) | (T & (~S) & D);
}


x86 assembly (clang, -O0):
<xrop3_7_0_1>:
push   %rbp
mov    %rsp,%rbp
mov    %sil,%al
mov    %dil,%cl
mov    %cl,-0x1(%rbp)
mov    %al,-0x2(%rbp)
movl   $0xff,-0x8(%rbp)
movzbl -0x1(%rbp),%eax
shl    $0x8,%eax
movzbl -0x1(%rbp),%ecx
or     %ecx,%eax
mov    %eax,-0xc(%rbp)
movzbl -0x2(%rbp),%eax
shl    $0x8,%eax
movzbl -0x2(%rbp),%ecx
or     %ecx,%eax
mov    %eax,-0x10(%rbp)
mov    -0x8(%rbp),%eax
and    -0xc(%rbp),%eax
mov    %eax,-0x18(%rbp)
mov    -0x10(%rbp),%eax
or     -0x18(%rbp),%eax
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%eax
xor    $0xffffffff,%eax
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%eax
and    -0xc(%rbp),%eax
mov    -0x14(%rbp),%ecx
mov    -0x10(%rbp),%edx
xor    $0xffffffff,%edx
and    %edx,%ecx
or     %ecx,%eax
mov    -0x10(%rbp),%ecx
mov    -0xc(%rbp),%edx
xor    $0xffffffff,%edx
and    %edx,%ecx
and    -0x8(%rbp),%ecx
or     %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<xrop3_7_0_1>:
mov    %edi,%eax
shl    $0x8,%eax
or     %edi,%eax
mov    %esi,%ecx
shl    $0x8,%ecx
or     %esi,%ecx
or     %edi,%ecx
not    %ecx
not    %eax
and    %esi,%eax
or     %ecx,%eax
ret

LLVM IR (-O0):
define i32 @xrop3_7_0_1(i8 zeroext %0, i8 zeroext %1) {
%3 = alloca i8
%4 = alloca i8
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
store i8 %0, i8* %3
store i8 %1, i8* %4
store i32 255, i32* %5
%10 = load i8, i8* %3
%11 = zext i8 %10 to i32
%12 = shl i32 %11, 8
%13 = load i8, i8* %3
%14 = zext i8 %13 to i32
%15 = or i32 %12, %14
store i32 %15, i32* %6
%16 = load i8, i8* %4
%17 = zext i8 %16 to i32
%18 = shl i32 %17, 8
%19 = load i8, i8* %4
%20 = zext i8 %19 to i32
%21 = or i32 %18, %20
store i32 %21, i32* %7
%22 = load i32, i32* %5
%23 = load i32, i32* %6
%24 = and i32 %22, %23
store i32 %24, i32* %9
%25 = load i32, i32* %7
%26 = load i32, i32* %9
%27 = or i32 %25, %26
store i32 %27, i32* %8
%28 = load i32, i32* %8
%29 = xor i32 %28, -1
store i32 %29, i32* %8
%30 = load i32, i32* %8
%31 = load i32, i32* %6
%32 = and i32 %30, %31
%33 = load i32, i32* %8
%34 = load i32, i32* %7
%35 = xor i32 %34, -1
%36 = and i32 %33, %35
%37 = or i32 %32, %36
%38 = load i32, i32* %7
%39 = load i32, i32* %6
%40 = xor i32 %39, -1
%41 = and i32 %38, %40
%42 = load i32, i32* %5
%43 = and i32 %41, %42
%44 = or i32 %37, %43
ret i32 %44
}

LLVM IR (-O2):
define i32 @xrop3_7_0_1(i8 zeroext %0, i8 zeroext %1) {
%3 = zext i8 %0 to i32
%4 = mul nuw nsw i32 %3, 257
%5 = zext i8 %1 to i32
%6 = mul nuw nsw i32 %5, 257
%7 = or i32 %6, %3
%8 = xor i32 %7, -1
%9 = xor i32 %4, -1
%10 = and i32 %9, %5
%11 = or i32 %10, %8
ret i32 %11
}
ylet(str, k) char *str;
{
  k++;
  while (*str && k--)
    str++;
  return (*--str);
}


x86 assembly (clang, -O0):
<ylet>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
mov    -0x8(%rbp),%rax
movsbl (%rax),%ecx
xor    %eax,%eax
cmp    $0x0,%ecx
mov    %al,-0xd(%rbp)
je     113d <ylet+0x3d>
mov    -0xc(%rbp),%eax
mov    %eax,%ecx
add    $0xffffffff,%ecx
mov    %ecx,-0xc(%rbp)
cmp    $0x0,%eax
setne  %al
mov    %al,-0xd(%rbp)
mov    -0xd(%rbp),%al
test   $0x1,%al
jne    114d <ylet+0x4d>
jmp    115e <ylet+0x5e>
mov    -0x8(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x8(%rbp)
jmp    1114 <ylet+0x14>
mov    -0x8(%rbp),%rax
mov    %rax,%rcx
add    $0xffffffffffffffff,%rcx
mov    %rcx,-0x8(%rbp)
movsbl -0x1(%rax),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<ylet>:
mov    %esi,%eax
inc    %eax
sete   %al
cmpb   $0x0,(%rdi)
je     1124 <ylet+0x24>
nopl   0x0(%rax)
test   %al,%al
jne    1124 <ylet+0x24>
sub    $0x1,%esi
setb   %al
cmpb   $0x0,0x1(%rdi)
lea    0x1(%rdi),%rdi
jne    1110 <ylet+0x10>
movsbl -0x1(%rdi),%eax
ret

LLVM IR (-O0):
define i32 @ylet(i8* %0, i32 %1) {
%3 = alloca i8*
%4 = alloca i32
store i8* %0, i8** %3
store i32 %1, i32* %4
%5 = load i32, i32* %4
%6 = add nsw i32 %5, 1
store i32 %6, i32* %4
br label %7
7: ; preds = %18, %2
%8 = load i8*, i8** %3
%9 = load i8, i8* %8
%10 = sext i8 %9 to i32
%11 = icmp ne i32 %10, 0
br i1 %11, label %12, label %16
12: ; preds = %7
%13 = load i32, i32* %4
%14 = add nsw i32 %13, -1
store i32 %14, i32* %4
%15 = icmp ne i32 %13, 0
br label %16
16: ; preds = %12, %7
%17 = phi i1 [ false, %7 ], [ %15, %12 ]
br i1 %17, label %18, label %21
18: ; preds = %16
%19 = load i8*, i8** %3
%20 = getelementptr inbounds i8, i8* %19, i32 1
store i8* %20, i8** %3
br label %7
21: ; preds = %16
%22 = load i8*, i8** %3
%23 = getelementptr inbounds i8, i8* %22, i32 -1
store i8* %23, i8** %3
%24 = load i8, i8* %23
%25 = sext i8 %24 to i32
ret i32 %25
}

LLVM IR (-O2):
define i32 @ylet(i8* nocapture %0, i32 %1) {
%3 = add nsw i32 %1, 1
%4 = load i8, i8* %0
%5 = icmp eq i8 %4, 0
%6 = icmp eq i32 %3, 0
%7 = select i1 %5, i1 true, i1 %6
br i1 %7, label %17, label %8
8: ; preds = %2, %8
%9 = phi i32 [ %11, %8 ], [ %3, %2 ]
%10 = phi i8* [ %12, %8 ], [ %0, %2 ]
%11 = add nsw i32 %9, -1
%12 = getelementptr inbounds i8, i8* %10, i64 1
%13 = load i8, i8* %12
%14 = icmp eq i8 %13, 0
%15 = icmp eq i32 %11, 0
%16 = select i1 %14, i1 true, i1 %15
br i1 %16, label %17, label %8
17: ; preds = %8, %2
%18 = phi i8* [ %0, %2 ], [ %12, %8 ]
%19 = getelementptr inbounds i8, i8* %18, i64 -1
%20 = load i8, i8* %19
%21 = sext i8 %20 to i32
ret i32 %21
}
/* Variables and functions */
int sg_ll_unmap_v2(int, int /*<<< orphan*/, int, int, void *, int, int, int);
int sg_ll_unmap(int sg_fd, int group_num, int timeout_secs, void *paramp,
                int param_len, int noisy, int verbose) {
  return sg_ll_unmap_v2(sg_fd, 0, group_num, timeout_secs, paramp, param_len,
                        noisy, verbose);
}


x86 assembly (clang, -O0):
<sg_ll_unmap>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    0x10(%rbp),%eax
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %rcx,-0x18(%rbp)
mov    %r8d,-0x1c(%rbp)
mov    %r9d,-0x20(%rbp)
mov    -0x4(%rbp),%edi
mov    -0x8(%rbp),%edx
mov    -0xc(%rbp),%ecx
mov    -0x18(%rbp),%r8
mov    -0x1c(%rbp),%r9d
mov    -0x20(%rbp),%r10d
mov    0x10(%rbp),%eax
xor    %esi,%esi
mov    %r10d,(%rsp)
mov    %eax,0x8(%rsp)
call   1030 <sg_ll_unmap_v2@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<sg_ll_unmap>:
push   %rax
mov    %r9d,%eax
mov    %r8d,%r9d
mov    %rcx,%r8
mov    %edx,%ecx
mov    %esi,%edx
mov    0x10(%rsp),%r10d
xor    %esi,%esi
push   %r10
push   %rax
call   1030 <sg_ll_unmap_v2@plt>
add    $0x10,%rsp
pop    %rcx
ret

LLVM IR (-O0):
define i32 @sg_ll_unmap(i32 %0, i32 %1, i32 %2, i8* %3, i32 %4, i32 %5, i32 %6) {
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
%11 = alloca i8*
%12 = alloca i32
%13 = alloca i32
%14 = alloca i32
store i32 %0, i32* %8
store i32 %1, i32* %9
store i32 %2, i32* %10
store i8* %3, i8** %11
store i32 %4, i32* %12
store i32 %5, i32* %13
store i32 %6, i32* %14
%15 = load i32, i32* %8
%16 = load i32, i32* %9
%17 = load i32, i32* %10
%18 = load i8*, i8** %11
%19 = load i32, i32* %12
%20 = load i32, i32* %13
%21 = load i32, i32* %14
%22 = call i32 @sg_ll_unmap_v2(i32 %15, i32 0, i32 %16, i32 %17, i8* %18, i32 %19, i32 %20, i32 %21)
ret i32 %22
}

LLVM IR (-O2):
define i32 @sg_ll_unmap(i32 %0, i32 %1, i32 %2, i8* %3, i32 %4, i32 %5, i32 %6) {
%8 = tail call i32 @sg_ll_unmap_v2(i32 %0, i32 0, i32 %1, i32 %2, i8* %3, i32 %4, i32 %5, i32 %6)
ret i32 %8
}
/* Type definitions */
struct statvfs {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ ENOSYS;
int /*<<< orphan*/ __set_errno(int /*<<< orphan*/);
int __fstatvfs(int fd, struct statvfs *buf) {
  __set_errno(ENOSYS);
  return -1;
}


x86 assembly (clang, -O0):
<__fstatvfs>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    0x2ec2(%rip),%rax
mov    (%rax),%edi
call   1030 <__set_errno@plt>
mov    $0xffffffff,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<__fstatvfs>:
push   %rax
mov    0x2ed0(%rip),%rax
mov    (%rax),%edi
call   1030 <__set_errno@plt>
mov    $0xffffffff,%eax
pop    %rcx
ret

LLVM IR (-O0):
%struct.statvfs = type { i32 }
@ENOSYS = global i32 0
define i32 @__fstatvfs(i32 %0, %struct.statvfs* %1) {
%3 = alloca i32
%4 = alloca %struct.statvfs*
store i32 %0, i32* %3
store %struct.statvfs* %1, %struct.statvfs** %4
%5 = load i32, i32* @ENOSYS
%6 = call i32 @__set_errno(i32 %5)
ret i32 -1
}

LLVM IR (-O2):
%struct.statvfs = type { i32 }
@ENOSYS = global i32 0
define i32 @__fstatvfs(i32 %0, %struct.statvfs* nocapture readnone %1) {
%3 = load i32, i32* @ENOSYS
%4 = tail call i32 @__set_errno(i32 %3)
ret i32 -1
}
/* Variables and functions */
int tarai(int, int, int);
int benchmark() {
  volatile int cnt = 0;
  cnt = tarai(9, 6, 3);
  return cnt;
}


x86 assembly (clang, -O0):
<benchmark>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0x9,%edi
mov    $0x6,%esi
mov    $0x3,%edx
call   1030 <tarai@plt>
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<benchmark>:
push   %rax
movl   $0x0,0x4(%rsp)
mov    $0x9,%edi
mov    $0x6,%esi
mov    $0x3,%edx
call   1030 <tarai@plt>
mov    %eax,0x4(%rsp)
mov    0x4(%rsp),%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @benchmark() {
%1 = alloca i32
store volatile i32 0, i32* %1
%2 = call i32 @tarai(i32 9, i32 6, i32 3)
store volatile i32 %2, i32* %1
%3 = load volatile i32, i32* %1
ret i32 %3
}

LLVM IR (-O2):
define i32 @benchmark() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
store volatile i32 0, i32* %1
%3 = tail call i32 @tarai(i32 9, i32 6, i32 3)
store volatile i32 %3, i32* %1
%4 = load volatile i32, i32* %1
ret i32 %4
}
void check_negative_sized_VLA_5() {
  signed char x = -1;
  int vla[x];
}


x86 assembly (clang, -O0):
<check_negative_sized_VLA_5>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movb   $0xff,-0x1(%rbp)
movzbl -0x1(%rbp),%eax
mov    %rsp,%rcx
mov    %rcx,-0x10(%rbp)
mov    %rax,-0x18(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,%rsp
mov    %rbp,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
define void @check_negative_sized_VLA_5() {
%1 = alloca i8
%2 = alloca i8*
%3 = alloca i64
store i8 -1, i8* %1
%4 = load i8, i8* %1
%5 = zext i8 %4 to i64
%6 = call i8* @llvm.stacksave()
store i8* %6, i8** %2
%7 = alloca i32, i64 %5
store i64 %5, i64* %3
%8 = load i8*, i8** %2
ret void
}

LLVM IR (-O2):
define void @check_negative_sized_VLA_5() {
ret void
}
/* Variables and functions */
scalar_t__ alloca(int);
void *test5a(char *);
void __attribute__((no)) __attribute__((noclone)) * test5(void) {
  char *save = (char *)alloca(4);
  return test5a(save);
}


x86 assembly (clang, -O0):
<test5>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x4,%edi
call   1040 <alloca@plt>
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <test5a@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<test5>:
push   %rax
mov    $0x4,%edi
call   1040 <alloca@plt>
mov    %rax,%rdi
pop    %rax
jmp    1030 <test5a@plt>

LLVM IR (-O0):
define i8* @test5() {
%1 = alloca i8*
%2 = call i64 @alloca(i32 4)
%3 = inttoptr i64 %2 to i8*
store i8* %3, i8** %1
%4 = load i8*, i8** %1
%5 = call i8* @test5a(i8* %4)
ret i8* %5
}

LLVM IR (-O2):
define i8* @test5() {
%1 = tail call i64 @alloca(i32 4)
%2 = inttoptr i64 %1 to i8*
%3 = tail call i8* @test5a(i8* %2)
ret i8* %3
}
/* Forward declarations */
typedef struct TYPE_3__ TYPE_1__;

/* Type definitions */
struct TYPE_3__ {
  int si_pid;
};
typedef TYPE_1__ siginfo_t;

/* Variables and functions */
int /*<<< orphan*/ printf(char *, char *, int);
char *strsignal(int);
void catch (int sig, siginfo_t *info, void *more) {
  printf("Rodzic: Dostałem sygnał >>%s<< od %d\n", strsignal(sig),
         info->si_pid);
}


x86 assembly (clang, -O0):
<catch>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x4(%rbp),%edi
call   1040 <strsignal@plt>
mov    %rax,%rsi
mov    -0x10(%rbp),%rax
mov    (%rax),%edx
lea    0xeb5(%rip),%rdi
call   1030 <printf@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<catch>:
push   %rbx
mov    %rsi,%rbx
call   1040 <strsignal@plt>
mov    (%rbx),%edx
lea    0xece(%rip),%rdi
mov    %rax,%rsi
pop    %rbx
jmp    1030 <printf@plt>

LLVM IR (-O0):
%struct.TYPE_3__ = type { i32 }
@.str = [40 x i8] c"Rodzic: Dosta\C5\82em sygna\C5\82 >>%s<< od %d\0A\00"
define void @catch(i32 %0, %struct.TYPE_3__* %1, i8* %2) {
%4 = alloca i32
%5 = alloca %struct.TYPE_3__*
%6 = alloca i8*
store i32 %0, i32* %4
store %struct.TYPE_3__* %1, %struct.TYPE_3__** %5
store i8* %2, i8** %6
%7 = load i32, i32* %4
%8 = call i8* @strsignal(i32 %7)
%9 = load %struct.TYPE_3__*, %struct.TYPE_3__** %5
%10 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %9, i32 0, i32 0
%11 = load i32, i32* %10
%12 = call i32 @printf(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str, i64 0, i64 0), i8* %8, i32 %11)
ret void
}

LLVM IR (-O2):
%struct.TYPE_3__ = type { i32 }
@.str = [40 x i8] c"Rodzic: Dosta\C5\82em sygna\C5\82 >>%s<< od %d\0A\00"
define void @catch(i32 %0, %struct.TYPE_3__* nocapture %1, i8* nocapture readnone %2) {
%4 = tail call i8* @strsignal(i32 %0)
%5 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %1, i64 0, i32 0
%6 = load i32, i32* %5
%7 = tail call i32 @printf(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str, i64 0, i64 0), i8* %4, i32 %6)
ret void
}
void abort() {
  while (1)
    ;
}


x86 assembly (clang, -O0):
<abort>:
push   %rbp
mov    %rsp,%rbp
jmp    1109 <abort+0x9>
jmp    1109 <abort+0x9>

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

LLVM IR (-O0):
define void @abort() {
br label %1
1: ; preds = %0, %1
br label %1
}

LLVM IR (-O2):
define void @abort() {
br label %1
1: ; preds = %0, %1
br label %1
}
int oiddiv4(int oid) { return oid / 4; }


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

x86 assembly (clang, -O2):
<oiddiv4>:
lea    0x3(%rdi),%eax
test   %edi,%edi
cmovns %edi,%eax
sar    $0x2,%eax
ret

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

LLVM IR (-O2):
define i32 @oiddiv4(i32 %0) {
%2 = sdiv i32 %0, 4
ret i32 %2
}
/* Type definitions */
typedef int /*<<< orphan*/ pid_t;

/* Variables and functions */
int /*<<< orphan*/ fork();
pid_t fork2(int ignored) { return fork(); }


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

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

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

LLVM IR (-O2):
define i32 @fork2(i32 %0) {
%2 = tail call i32 (...) @fork()
ret i32 %2
}
/* Variables and functions */
int /*<<< orphan*/ write_instr(int);
int ret_handler(char **save) {
  (void)save;
  write_instr(0x0A);
  return 2;
}


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

x86 assembly (clang, -O2):
<ret_handler>:
push   %rax
mov    $0xa,%edi
call   1030 <write_instr@plt>
mov    $0x2,%eax
pop    %rcx
ret

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

LLVM IR (-O2):
define i32 @ret_handler(i8** nocapture readnone %0) {
%2 = tail call i32 @write_instr(i32 10)
ret i32 2
}
int isnanf(float x) {
  union {
    long s32;
    float f32;
  } u;
  unsigned long ul;
  u.f32 = x;
  ul = 0x7f800000 - (u.s32 & 0x7fffffff);
  return ul >> 31;
}


x86 assembly (clang, -O0):
<isnanf>:
push   %rbp
mov    %rsp,%rbp
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
movss  %xmm0,-0x10(%rbp)
mov    -0x10(%rbp),%rcx
and    $0x7fffffff,%rcx
mov    $0x7f800000,%eax
sub    %rcx,%rax
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
shr    $0x1f,%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<isnanf>:
movd   %xmm0,%ecx
and    $0x7fffffff,%ecx
mov    $0x7f800000,%eax
sub    %rcx,%rax
shr    $0x1f,%rax
ret

LLVM IR (-O0):
%union.anon = type { i64 }
define i32 @isnanf(float %0) {
%2 = alloca float
%3 = alloca %union.anon
%4 = alloca i64
store float %0, float* %2
%5 = load float, float* %2
%6 = bitcast %union.anon* %3 to float*
store float %5, float* %6
%7 = bitcast %union.anon* %3 to i64*
%8 = load i64, i64* %7
%9 = and i64 %8, 2147483647
%10 = sub nsw i64 2139095040, %9
store i64 %10, i64* %4
%11 = load i64, i64* %4
%12 = lshr i64 %11, 31
%13 = trunc i64 %12 to i32
ret i32 %13
}

LLVM IR (-O2):
define i32 @isnanf(float %0) {
%2 = bitcast float %0 to i32
%3 = and i32 %2, 2147483647
%4 = zext i32 %3 to i64
%5 = sub nsw i64 2139095040, %4
%6 = lshr i64 %5, 31
%7 = trunc i64 %6 to i32
ret i32 %7
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
int main(void) {
  printf("Hello, World\k");
  return 0;
}


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

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

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

LLVM IR (-O2):
@.str = [14 x i8] c"Hello, Worldk\00"
define i32 @main() {
%1 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0))
ret i32 0
}
void *__attribute__((no, noclone))
get_addr_base_and_unit_offset(void *base, long long *i) {
  *i = 0;
  return base;
}


x86 assembly (clang, -O0):
<get_addr_base_and_unit_offset>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
movq   $0x0,(%rax)
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<get_addr_base_and_unit_offset>:
mov    %rdi,%rax
movq   $0x0,(%rsi)
ret

LLVM IR (-O0):
define i8* @get_addr_base_and_unit_offset(i8* %0, i64* %1) {
%3 = alloca i8*
%4 = alloca i64*
store i8* %0, i8** %3
store i64* %1, i64** %4
%5 = load i64*, i64** %4
store i64 0, i64* %5
%6 = load i8*, i8** %3
ret i8* %6
}

LLVM IR (-O2):
define i8* @get_addr_base_and_unit_offset(i8* readnone returned %0, i64* nocapture writeonly %1) {
store i64 0, i64* %1
ret i8* %0
}
void emit_type_definition_int16(
    struct processor_explicatory_state *process_state,
    struct modern_stream *stream, void *stream_state,
    struct modern_vfile *vfile, void *vfile_state) {}


x86 assembly (clang, -O0):
<emit_type_definition_int16>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
pop    %rbp
ret

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

LLVM IR (-O0):
%struct.processor_explicatory_state = type opaque
%struct.modern_stream = type opaque
%struct.modern_vfile = type opaque
define void @emit_type_definition_int16(%struct.processor_explicatory_state* %0, %struct.modern_stream* %1, i8* %2, %struct.modern_vfile* %3, i8* %4) {
%6 = alloca %struct.processor_explicatory_state*
%7 = alloca %struct.modern_stream*
%8 = alloca i8*
%9 = alloca %struct.modern_vfile*
%10 = alloca i8*
store %struct.processor_explicatory_state* %0, %struct.processor_explicatory_state** %6
store %struct.modern_stream* %1, %struct.modern_stream** %7
store i8* %2, i8** %8
store %struct.modern_vfile* %3, %struct.modern_vfile** %9
store i8* %4, i8** %10
ret void
}

LLVM IR (-O2):
%struct.processor_explicatory_state = type opaque
%struct.modern_stream = type opaque
%struct.modern_vfile = type opaque
define void @emit_type_definition_int16(%struct.processor_explicatory_state* nocapture %0, %struct.modern_stream* nocapture %1, i8* nocapture %2, %struct.modern_vfile* nocapture %3, i8* nocapture %4) {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ e_ldy();
int /*<<< orphan*/ e_zp();
void e_ldy_zp() {
  e_zp();
  e_ldy();
}


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

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

LLVM IR (-O0):
define void @e_ldy_zp() {
%1 = call i32 (...) @e_zp()
%2 = call i32 (...) @e_ldy()
ret void
}

LLVM IR (-O2):
define void @e_ldy_zp() {
%1 = tail call i32 (...) @e_zp()
%2 = tail call i32 (...) @e_ldy()
ret void
}
void print_os_property(char *name) {}


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

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

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

LLVM IR (-O2):
define void @print_os_property(i8* nocapture %0) {
ret void
}
/* Variables and functions */
void **calloc(int, int);
void **array_create(int size) {
  void **data = calloc(size, sizeof(void *));
  return data;
}


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

x86 assembly (clang, -O2):
<array_create>:
mov    $0x8,%esi
jmp    1030 <calloc@plt>

LLVM IR (-O0):
define i8** @array_create(i32 %0) {
%2 = alloca i32
%3 = alloca i8**
store i32 %0, i32* %2
%4 = load i32, i32* %2
%5 = call i8** @calloc(i32 %4, i32 8)
store i8** %5, i8*** %3
%6 = load i8**, i8*** %3
ret i8** %6
}

LLVM IR (-O2):
define noalias i8** @array_create(i32 %0) {
%2 = tail call i8** @calloc(i32 %0, i32 8)
ret i8** %2
}
/* Type definitions */
struct evbuffer {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ evbuffer_decref_(struct evbuffer *);
void evbuffer_free(struct evbuffer *buffer) {
  if (!buffer)
    return;
  evbuffer_decref_(buffer);
}


x86 assembly (clang, -O0):
<evbuffer_free>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
cmpq   $0x0,-0x8(%rbp)
jne    112c <evbuffer_free+0x1c>
jmp    1135 <evbuffer_free+0x25>
mov    -0x8(%rbp),%rdi
call   1030 <evbuffer_decref_@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<evbuffer_free>:
test   %rdi,%rdi
je     111a <evbuffer_free+0xa>
jmp    1030 <evbuffer_decref_@plt>
ret

LLVM IR (-O0):
%struct.evbuffer = type { i32 }
define void @evbuffer_free(%struct.evbuffer* %0) {
%2 = alloca %struct.evbuffer*
store %struct.evbuffer* %0, %struct.evbuffer** %2
%3 = load %struct.evbuffer*, %struct.evbuffer** %2
%4 = icmp ne %struct.evbuffer* %3, null
br i1 %4, label %6, label %5
5: ; preds = %1
br label %9
6: ; preds = %1
%7 = load %struct.evbuffer*, %struct.evbuffer** %2
%8 = call i32 @evbuffer_decref_(%struct.evbuffer* %7)
br label %9
9: ; preds = %6, %5
ret void
}

LLVM IR (-O2):
%struct.evbuffer = type { i32 }
define void @evbuffer_free(%struct.evbuffer* %0) {
%2 = icmp eq %struct.evbuffer* %0, null
br i1 %2, label %5, label %3
3: ; preds = %1
%4 = tail call i32 @evbuffer_decref_(%struct.evbuffer* %0)
br label %5
5: ; preds = %1, %3
ret void
}
/* Variables and functions */
int /*<<< orphan*/ free(void *);
void dumb_stdfile_noclose(void *f) { free(f); }


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

x86 assembly (clang, -O2):
<dumb_stdfile_noclose>:
jmp    1030 <free@plt>

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

LLVM IR (-O2):
define void @dumb_stdfile_noclose(i8* nocapture %0) {
%2 = tail call i32 @free(i8* %0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int, int);
void changeValues(int *value1, int *value2) {
  int aux;
  aux = *value1;
  *value1 = *value2;
  *value2 = aux;
  printf("\nValor 1 = %d\nValor 2 = %d", *value1, *value2);
}


x86 assembly (clang, -O0):
<changeValues>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%eax
mov    %eax,-0x14(%rbp)
mov    -0x10(%rbp),%rax
mov    (%rax),%ecx
mov    -0x8(%rbp),%rax
mov    %ecx,(%rax)
mov    -0x14(%rbp),%ecx
mov    -0x10(%rbp),%rax
mov    %ecx,(%rax)
mov    -0x8(%rbp),%rax
mov    (%rax),%esi
mov    -0x10(%rbp),%rax
mov    (%rax),%edx
lea    0xeaf(%rip),%rdi
call   1030 <printf@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<changeValues>:
mov    (%rdi),%edx
mov    (%rsi),%eax
mov    %eax,(%rdi)
mov    %edx,(%rsi)
mov    (%rdi),%esi
lea    0xedf(%rip),%rdi
jmp    1030 <printf@plt>

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

LLVM IR (-O2):
@.str = [27 x i8] c"\0AValor 1 = %d\0AValor 2 = %d\00"
define void @changeValues(i32* nocapture %0, i32* nocapture %1) {
%3 = load i32, i32* %0
%4 = load i32, i32* %1
store i32 %4, i32* %0
store i32 %3, i32* %1
%5 = load i32, i32* %0
%6 = tail call i32 @printf(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str, i64 0, i64 0), i32 %5, i32 %3)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, ...);
void UnitTestMessages_copied____testing_runningTest(char *loc) {
  printf("$$runningTest: running test (");
  printf(" @loc %s \n", loc);
  ;
}


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

x86 assembly (clang, -O2):
<UnitTestMessages_copied____testing_runningTest>:
push   %rbx
mov    %rdi,%rbx
lea    0xee5(%rip),%rdi
xor    %eax,%eax
call   1030 <printf@plt>
lea    0xef5(%rip),%rdi
mov    %rbx,%rsi
xor    %eax,%eax
pop    %rbx
jmp    1030 <printf@plt>

LLVM IR (-O0):
@.str = [30 x i8] c"$$runningTest: running test (\00"
@.str.1 = [11 x i8] c" @loc %s \0A\00"
define void @UnitTestMessages_copied____testing_runningTest(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str, i64 0, i64 0))
%4 = load i8*, i8** %2
%5 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0), i8* %4)
ret void
}

LLVM IR (-O2):
@.str = [30 x i8] c"$$runningTest: running test (\00"
@.str.1 = [11 x i8] c" @loc %s \0A\00"
define void @UnitTestMessages_copied____testing_runningTest(i8* %0) {
%2 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([30 x i8], [30 x i8]* @.str, i64 0, i64 0))
%3 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0), i8* %0)
ret void
}
/* Variables and functions */
int drv_end_tag_recover(int);
extern int drv_attribute_close_recover(int p) { return drv_end_tag_recover(p); }


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

x86 assembly (clang, -O2):
<drv_attribute_close_recover>:
jmp    1030 <drv_end_tag_recover@plt>

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

LLVM IR (-O2):
define i32 @drv_attribute_close_recover(i32 %0) {
%2 = tail call i32 @drv_end_tag_recover(i32 %0)
ret i32 %2
}
unsigned int HSMMCSDIntrStatusGet(unsigned int baseAddr, unsigned int flag) {
  return (*((volatile unsigned int *)(baseAddr + (0x230)))) & flag;
}


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

x86 assembly (clang, -O2):
<HSMMCSDIntrStatusGet>:
mov    %esi,%eax
add    $0x230,%edi
and    (%rdi),%eax
ret

LLVM IR (-O0):
define i32 @HSMMCSDIntrStatusGet(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 = add i32 %5, 560
%7 = zext i32 %6 to i64
%8 = inttoptr i64 %7 to i32*
%9 = load volatile i32, i32* %8
%10 = load i32, i32* %4
%11 = and i32 %9, %10
ret i32 %11
}

LLVM IR (-O2):
define i32 @HSMMCSDIntrStatusGet(i32 %0, i32 %1) {
%3 = add i32 %0, 560
%4 = zext i32 %3 to i64
%5 = inttoptr i64 %4 to i32*
%6 = load volatile i32, i32* %5
%7 = and i32 %6, %1
ret i32 %7
}
void memory_init() { return; }


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

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

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

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