xunge/DecIR huggingface dataset:
int xmlUCSIsLowSurrogates(int code) {
  return (((code >= 0xDC00) && (code <= 0xDFFF)));
}


x86 assembly (clang, -O0):
<xmlUCSIsLowSurrogates>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
xor    %eax,%eax
cmpl   $0xdc00,-0x4(%rbp)
mov    %al,-0x5(%rbp)
jl     1126 <xmlUCSIsLowSurrogates+0x26>
cmpl   $0xdfff,-0x4(%rbp)
setle  %al
mov    %al,-0x5(%rbp)
mov    -0x5(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<xmlUCSIsLowSurrogates>:
and    $0xfffffc00,%edi
xor    %eax,%eax
cmp    $0xdc00,%edi
sete   %al
ret

LLVM IR (-O0):
define i32 @xmlUCSIsLowSurrogates(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = icmp sge i32 %3, 56320
br i1 %4, label %5, label %8
5: ; preds = %1
%6 = load i32, i32* %2
%7 = icmp sle i32 %6, 57343
br label %8
8: ; preds = %5, %1
%9 = phi i1 [ false, %1 ], [ %7, %5 ]
%10 = zext i1 %9 to i32
ret i32 %10
}

LLVM IR (-O2):
define i32 @xmlUCSIsLowSurrogates(i32 %0) {
%2 = and i32 %0, -1024
%3 = icmp eq i32 %2, 56320
%4 = zext i1 %3 to i32
ret i32 %4
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int);
int /*<<< orphan*/ sum(int);
int main(int argc, char *argv[]) {
  int i = 0, n = 0;
  sum(50);
  for (i = 1; i <= 50; i += 1)
    n += i;
  printf("The sum of 1-50 is %d\n", 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)
movl   $0x0,-0x14(%rbp)
movl   $0x0,-0x18(%rbp)
mov    $0x32,%edi
call   1040 <sum@plt>
movl   $0x1,-0x14(%rbp)
cmpl   $0x32,-0x14(%rbp)
jg     1176 <main+0x56>
mov    -0x14(%rbp),%eax
add    -0x18(%rbp),%eax
mov    %eax,-0x18(%rbp)
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    1155 <main+0x35>
mov    -0x18(%rbp),%esi
lea    0xe80(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

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

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

LLVM IR (-O2):
@.str = [23 x i8] c"The sum of 1-50 is %d\0A\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @sum(i32 50)
%4 = tail call i32 @printf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str, i64 0, i64 0), i32 1275)
ret i32 0
}
/* Type definitions */
typedef scalar_t__ wchar_t;

/* Variables and functions */
int exactcmp(wchar_t a, wchar_t b) { return a == b; }


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

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

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

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

/* Variables and functions */
int /*<<< orphan*/ wmemcmp(int /*<<< orphan*/ *, int /*<<< orphan*/, int);
void nullPointer_wmemcmp(wchar_t *p) { (void)wmemcmp(p, 0, 123); }


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

x86 assembly (clang, -O2):
<nullPointer_wmemcmp>:
xor    %esi,%esi
mov    $0x7b,%edx
jmp    1030 <wmemcmp@plt>

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

LLVM IR (-O2):
define void @nullPointer_wmemcmp(i32* %0) {
%2 = tail call i32 @wmemcmp(i32* %0, i32 0, i32 123)
ret void
}
int cimaged11_omp_get_max_threads(void) { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @cimaged11_omp_get_max_threads() {
ret i32 0
}
/* Variables and functions */
scalar_t__ strtoul(char *, int /*<<< orphan*/ *, int);
unsigned int _parse_int_arg(char *str) {
  if (str[1] == 'x') {
    return (unsigned int)strtoul(str, NULL, 16);
  } else {
    return (unsigned int)strtoul(str, NULL, 10);
  }
}


x86 assembly (clang, -O0):
<_parse_int_arg>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
movsbl 0x1(%rax),%eax
cmp    $0x78,%eax
jne    1147 <_parse_int_arg+0x37>
mov    -0x10(%rbp),%rdi
xor    %eax,%eax
mov    %eax,%esi
mov    $0x10,%edx
call   1030 <strtoul@plt>
mov    %eax,-0x4(%rbp)
jmp    115c <_parse_int_arg+0x4c>
mov    -0x10(%rbp),%rdi
xor    %eax,%eax
mov    %eax,%esi
mov    $0xa,%edx
call   1030 <strtoul@plt>
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<_parse_int_arg>:
cmpb   $0x78,0x1(%rdi)
mov    $0x10,%eax
mov    $0xa,%edx
cmove  %eax,%edx
xor    %esi,%esi
jmp    1030 <strtoul@plt>

LLVM IR (-O0):
define i32 @_parse_int_arg(i8* %0) {
%2 = alloca i32
%3 = alloca i8*
store i8* %0, i8** %3
%4 = load i8*, i8** %3
%5 = getelementptr inbounds i8, i8* %4, i64 1
%6 = load i8, i8* %5
%7 = sext i8 %6 to i32
%8 = icmp eq i32 %7, 120
br i1 %8, label %9, label %13
9: ; preds = %1
%10 = load i8*, i8** %3
%11 = call i64 @strtoul(i8* %10, i32* null, i32 16)
%12 = trunc i64 %11 to i32
store i32 %12, i32* %2
br label %17
13: ; preds = %1
%14 = load i8*, i8** %3
%15 = call i64 @strtoul(i8* %14, i32* null, i32 10)
%16 = trunc i64 %15 to i32
store i32 %16, i32* %2
br label %17
17: ; preds = %13, %9
%18 = load i32, i32* %2
ret i32 %18
}

LLVM IR (-O2):
define i32 @_parse_int_arg(i8* nocapture %0) {
%2 = getelementptr inbounds i8, i8* %0, i64 1
%3 = load i8, i8* %2
%4 = icmp eq i8 %3, 120
%5 = select i1 %4, i32 16, i32 10
%6 = tail call i64 @strtoul(i8* nocapture %0, i32* null, i32 %5)
%7 = trunc i64 %6 to i32
ret i32 %7
}
/* Type definitions */
struct arg_str {
  int dummy;
};

/* Variables and functions */
struct arg_str *arg_strn(char const *, char const *, char const *, int, int,
                         char const *);
struct arg_str *arg_str1(const char *shortopts, const char *longopts,
                         const char *datatype, const char *glossary) {
  return arg_strn(shortopts, longopts, datatype, 1, 1, glossary);
}


x86 assembly (clang, -O0):
<arg_str1>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
mov    -0x18(%rbp),%rdx
mov    -0x20(%rbp),%r9
mov    $0x1,%r8d
mov    %r8d,%ecx
call   1030 <arg_strn@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<arg_str1>:
mov    %rcx,%r9
mov    $0x1,%ecx
mov    $0x1,%r8d
jmp    1030 <arg_strn@plt>

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

LLVM IR (-O2):
%struct.arg_str = type { i32 }
define %struct.arg_str* @arg_str1(i8* %0, i8* %1, i8* %2, i8* %3) {
%5 = tail call %struct.arg_str* @arg_strn(i8* %0, i8* %1, i8* %2, i32 1, i32 1, i8* %3)
ret %struct.arg_str* %5
}
void av_append_path_component() {}


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

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

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

LLVM IR (-O2):
define void @av_append_path_component() {
ret void
}
/* Type definitions */
typedef int ssize_t;

/* Variables and functions */
int /*<<< orphan*/ printf(char *);
int struct_calcsize(char *);
void test_struct_example_1_3(void) {
  ssize_t size;
  size = struct_calcsize("hhl");
  printf("Example 1.3 test: ");
  if (size == 8)
    printf("PASS\n");
  else
    printf("FAIL\n");
}


x86 assembly (clang, -O0):
<test_struct_example_1_3>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
lea    0xed1(%rip),%rdi
call   1030 <struct_calcsize@plt>
mov    %eax,-0x4(%rbp)
lea    0xec6(%rip),%rdi
call   1040 <printf@plt>
cmpl   $0x8,-0x4(%rbp)
jne    115e <test_struct_example_1_3+0x3e>
lea    0xec3(%rip),%rdi
call   1040 <printf@plt>
jmp    116a <test_struct_example_1_3+0x4a>
lea    0xeb8(%rip),%rdi
call   1040 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_struct_example_1_3>:
push   %rbx
lea    0xec8(%rip),%rdi
call   1030 <struct_calcsize@plt>
mov    %eax,%ebx
lea    0xebe(%rip),%rdi
call   1050 <printf@plt>
cmp    $0x8,%ebx
lea    0xec7(%rip),%rax
lea    0xebb(%rip),%rdi
cmove  %rax,%rdi
pop    %rbx
jmp    1040 <puts@plt>

LLVM IR (-O0):
@.str = [4 x i8] c"hhl\00"
@.str.1 = [19 x i8] c"Example 1.3 test: \00"
@.str.2 = [6 x i8] c"PASS\0A\00"
@.str.3 = [6 x i8] c"FAIL\0A\00"
define void @test_struct_example_1_3() {
%1 = alloca i32
%2 = call i32 @struct_calcsize(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0))
store i32 %2, i32* %1
%3 = call i32 @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.1, i64 0, i64 0))
%4 = load i32, i32* %1
%5 = icmp eq i32 %4, 8
br i1 %5, label %6, label %8
6: ; preds = %0
%7 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0))
br label %10
8: ; preds = %0
%9 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0))
br label %10
10: ; preds = %8, %6
ret void
}

LLVM IR (-O2):
@.str = [4 x i8] c"hhl\00"
@.str.1 = [19 x i8] c"Example 1.3 test: \00"
@str = [5 x i8] c"FAIL\00"
@str.4 = [5 x i8] c"PASS\00"
define void @test_struct_example_1_3() {
%1 = tail call i32 @struct_calcsize(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @.str.1, i64 0, i64 0))
%3 = icmp eq i32 %1, 8
%4 = select i1 %3, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @str.4, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @str, i64 0, i64 0)
%5 = tail call i32 @puts(i8* dereferenceable(1) %4)
ret void
}
void SPIM_1_RX_ISR(void) {}


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

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

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

LLVM IR (-O2):
define void @SPIM_1_RX_ISR() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ STDOUT_FILENO;
int write(int /*<<< orphan*/, unsigned char *, int);
int recv_tty(void *cb_data, unsigned char *buf, int len) {
  return write(STDOUT_FILENO, buf, len);
}


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

x86 assembly (clang, -O2):
<recv_tty>:
mov    0x2ed9(%rip),%rax
mov    (%rax),%edi
jmp    1030 <write@plt>

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

LLVM IR (-O2):
@STDOUT_FILENO = global i32 0
define i32 @recv_tty(i8* nocapture readnone %0, i8* nocapture %1, i32 %2) {
%4 = load i32, i32* @STDOUT_FILENO
%5 = tail call i32 @write(i32 %4, i8* %1, i32 %2)
ret i32 %5
}
/* Type definitions */
struct stat {
  int /*<<< orphan*/ st_mode;
};

/* Variables and functions */
scalar_t__ S_ISDIR(int /*<<< orphan*/);
int stat(char *, struct stat *);
int dir_check(char *drohn_dir) {
  struct stat s;
  int err = stat(drohn_dir, &s);
  if (err == -1) {
    return -1;
  } else {
    if (S_ISDIR(s.st_mode)) {
      return 1;
    } else {
      return 0;
    }
  }
}


x86 assembly (clang, -O0):
<dir_check>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
lea    -0x18(%rbp),%rsi
call   1040 <stat@plt>
mov    %eax,-0x1c(%rbp)
cmpl   $0xffffffff,-0x1c(%rbp)
jne    1152 <dir_check+0x32>
movl   $0xffffffff,-0x4(%rbp)
jmp    1177 <dir_check+0x57>
mov    -0x18(%rbp),%edi
call   1030 <S_ISDIR@plt>
cmp    $0x0,%rax
je     1170 <dir_check+0x50>
movl   $0x1,-0x4(%rbp)
jmp    1177 <dir_check+0x57>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<dir_check>:
push   %rax
mov    %rsp,%rsi
call   1040 <stat@plt>
cmp    $0xffffffff,%eax
je     1143 <dir_check+0x23>
mov    (%rsp),%edi
call   1030 <S_ISDIR@plt>
mov    %rax,%rcx
xor    %eax,%eax
test   %rcx,%rcx
setne  %al
pop    %rcx
ret
mov    $0xffffffff,%eax
pop    %rcx
ret

LLVM IR (-O0):
%struct.stat = type { i32 }
define i32 @dir_check(i8* %0) {
%2 = alloca i32
%3 = alloca i8*
%4 = alloca %struct.stat
%5 = alloca i32
store i8* %0, i8** %3
%6 = load i8*, i8** %3
%7 = call i32 @stat(i8* %6, %struct.stat* %4)
store i32 %7, i32* %5
%8 = load i32, i32* %5
%9 = icmp eq i32 %8, -1
br i1 %9, label %10, label %11
10: ; preds = %1
store i32 -1, i32* %2
br label %18
11: ; preds = %1
%12 = getelementptr inbounds %struct.stat, %struct.stat* %4, i32 0, i32 0
%13 = load i32, i32* %12
%14 = call i64 @S_ISDIR(i32 %13)
%15 = icmp ne i64 %14, 0
br i1 %15, label %16, label %17
16: ; preds = %11
store i32 1, i32* %2
br label %18
17: ; preds = %11
store i32 0, i32* %2
br label %18
18: ; preds = %17, %16, %10
%19 = load i32, i32* %2
ret i32 %19
}

LLVM IR (-O2):
%struct.stat = type { i32 }
define i32 @dir_check(i8* nocapture %0) {
%2 = alloca %struct.stat
%3 = bitcast %struct.stat* %2 to i8*
%4 = call i32 @stat(i8* %0, %struct.stat* %2)
%5 = icmp eq i32 %4, -1
br i1 %5, label %12, label %6
6: ; preds = %1
%7 = getelementptr inbounds %struct.stat, %struct.stat* %2, i64 0, i32 0
%8 = load i32, i32* %7
%9 = tail call i64 @S_ISDIR(i32 %8)
%10 = icmp ne i64 %9, 0
%11 = zext i1 %10 to i32
br label %12
12: ; preds = %6, %1
%13 = phi i32 [ -1, %1 ], [ %11, %6 ]
ret i32 %13
}
/* Variables and functions */
int /*<<< orphan*/ EXIT_FAILURE;
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ printf(char *, char const *);
int die(const char *msg) {
  printf("Fatal error: %s.\n", msg);
  exit(EXIT_FAILURE);
}


x86 assembly (clang, -O0):
<die>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rsi
lea    0xec9(%rip),%rdi
call   1030 <printf@plt>
mov    0x2e9d(%rip),%rax
mov    (%rax),%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<die>:
push   %rax
mov    %rdi,%rsi
lea    0xed5(%rip),%rdi
call   1030 <printf@plt>
mov    0x2ea9(%rip),%rax
mov    (%rax),%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@.str = [18 x i8] c"Fatal error: %s.\0A\00"
@EXIT_FAILURE = global i32 0
define i32 @die(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = call i32 @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0), i8* %3)
%5 = load i32, i32* @EXIT_FAILURE
%6 = call i32 @exit(i32 %5)
unreachable
}

LLVM IR (-O2):
@.str = [18 x i8] c"Fatal error: %s.\0A\00"
@EXIT_FAILURE = global i32 0
define i32 @die(i8* %0) {
%2 = tail call i32 @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0), i8* %0)
%3 = load i32, i32* @EXIT_FAILURE
%4 = tail call i32 @exit(i32 %3)
unreachable
}
void gtk_action_group_get_visible() {}


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

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

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

LLVM IR (-O2):
define void @gtk_action_group_get_visible() {
ret void
}
void nullifyRow(int rows, int cols, int index, int matrix[rows][cols]) {
  for (int i = 0; i < cols; ++i) {
    matrix[index][i] = 0;
  }
}


x86 assembly (clang, -O0):
<nullifyRow>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %rcx,-0x18(%rbp)
mov    -0x8(%rbp),%eax
mov    %rax,-0x28(%rbp)
movl   $0x0,-0x1c(%rbp)
mov    -0x1c(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    115b <nullifyRow+0x5b>
mov    -0x28(%rbp),%rdx
mov    -0x18(%rbp),%rax
movslq -0xc(%rbp),%rcx
imul   %rdx,%rcx
shl    $0x2,%rcx
add    %rcx,%rax
movslq -0x1c(%rbp),%rcx
movl   $0x0,(%rax,%rcx,4)
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    111f <nullifyRow+0x1f>
pop    %rbp
ret

x86 assembly (clang, -O2):
<nullifyRow>:
test   %esi,%esi
jle    1134 <nullifyRow+0x24>
push   %rax
mov    %esi,%eax
movslq %edx,%rdx
imul   %rax,%rdx
lea    (%rcx,%rdx,4),%rdi
shl    $0x2,%rax
xor    %esi,%esi
mov    %rax,%rdx
call   1030 <memset@plt>
add    $0x8,%rsp
ret

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

LLVM IR (-O2):
define void @nullifyRow(i32 %0, i32 %1, i32 %2, i32* nocapture writeonly %3) {
%5 = icmp sgt i32 %1, 0
br i1 %5, label %6, label %13
6: ; preds = %4
%7 = zext i32 %1 to i64
%8 = sext i32 %2 to i64
%9 = mul nsw i64 %8, %7
%10 = getelementptr inbounds i32, i32* %3, i64 %9
%11 = bitcast i32* %10 to i8*
%12 = shl nuw nsw i64 %7, 2
br label %13
13: ; preds = %6, %4
ret void
}
int execute_subpage_prot() { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @execute_subpage_prot() {
ret i32 0
}
int test_imm_35int64_midword_mem(long long *val) {
  return ((*val >> 16) & (0x35 << 0)) ? -20 : -40;
}


x86 assembly (clang, -O0):
<test_imm_35int64_midword_mem>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%rdx
sar    $0x10,%rdx
and    $0x35,%rdx
mov    $0xffffffd8,%eax
mov    $0xffffffec,%ecx
cmp    $0x0,%rdx
cmovne %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_imm_35int64_midword_mem>:
testb  $0x35,0x2(%rdi)
mov    $0xffffffd8,%ecx
mov    $0xffffffec,%eax
cmove  %ecx,%eax
ret

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

LLVM IR (-O2):
define i32 @test_imm_35int64_midword_mem(i64* nocapture %0) {
%2 = load i64, i64* %0
%3 = and i64 %2, 3473408
%4 = icmp eq i64 %3, 0
%5 = select i1 %4, i32 -40, i32 -20
ret i32 %5
}
/* Variables and functions */
int /*<<< orphan*/ puts(char *);
funfacts(void) {
  puts("--Reboot--\n\n"
       "        Fun Facts\n\n"
       "#LINUX_REBOOT_MAGIC1  is 0xfee1dead"
       "#LINUX_REBOOT_MAGIC2  is 672274793"
       "#LINUX_REBOOT_MAGIC2A is 85072278"
       "#LINUX_REBOOT_MAGIC2B is 369367448"
       "#LINUX_REBOOT_MAGIC2C is 537993216");
}


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

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

LLVM IR (-O0):
@.str = [202 x i8] c"--Reboot--\0A\0A Fun Facts\0A\0A#LINUX_REBOOT_MAGIC1 is 0xfee1dead#LINUX_REBOOT_MAGIC2 is 672274793#LINUX_REBOOT_MAGIC2A is 85072278#LINUX_REBOOT_MAGIC2B is 369367448#LINUX_REBOOT_MAGIC2C is 537993216\00"
define i32 @funfacts() {
%1 = alloca i32
%2 = call i32 @puts(i8* getelementptr inbounds ([202 x i8], [202 x i8]* @.str, i64 0, i64 0))
%3 = load i32, i32* %1
ret i32 %3
}

LLVM IR (-O2):
@.str = [202 x i8] c"--Reboot--\0A\0A Fun Facts\0A\0A#LINUX_REBOOT_MAGIC1 is 0xfee1dead#LINUX_REBOOT_MAGIC2 is 672274793#LINUX_REBOOT_MAGIC2A is 85072278#LINUX_REBOOT_MAGIC2B is 369367448#LINUX_REBOOT_MAGIC2C is 537993216\00"
define i32 @funfacts() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([202 x i8], [202 x i8]* @.str, i64 0, i64 0))
ret i32 undef
}
/* Type definitions */
typedef int /*<<< orphan*/ uint64_t;

/* Variables and functions */
int /*<<< orphan*/ htonll(int /*<<< orphan*/);
int /*<<< orphan*/ std_memcpy(void *, int /*<<< orphan*/ *, int);
void pack_uint64(void **pp, uint64_t val) {
  val = htonll(val);
  std_memcpy(*pp, &val, sizeof(uint64_t));
  *pp += sizeof(uint64_t);
}


x86 assembly (clang, -O0):
<pack_uint64>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0xc(%rbp),%edi
call   1040 <htonll@plt>
mov    %eax,-0xc(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%rdi
lea    -0xc(%rbp),%rsi
mov    $0x4,%edx
call   1030 <std_memcpy@plt>
mov    -0x8(%rbp),%rax
mov    (%rax),%rcx
add    $0x4,%rcx
mov    %rcx,(%rax)
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<pack_uint64>:
push   %rbx
sub    $0x10,%rsp
mov    %rdi,%rbx
mov    %esi,%edi
call   1040 <htonll@plt>
mov    %eax,0xc(%rsp)
mov    (%rbx),%rdi
lea    0xc(%rsp),%rsi
mov    $0x4,%edx
call   1030 <std_memcpy@plt>
addq   $0x4,(%rbx)
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
define void @pack_uint64(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 = call i32 @htonll(i32 %5)
store i32 %6, i32* %4
%7 = load i8**, i8*** %3
%8 = load i8*, i8** %7
%9 = call i32 @std_memcpy(i8* %8, i32* %4, i32 4)
%10 = load i8**, i8*** %3
%11 = load i8*, i8** %10
%12 = getelementptr i8, i8* %11, i64 4
store i8* %12, i8** %10
ret void
}

LLVM IR (-O2):
define void @pack_uint64(i8** nocapture %0, i32 %1) {
%3 = alloca i32
%4 = tail call i32 @htonll(i32 %1)
store i32 %4, i32* %3
%5 = load i8*, i8** %0
%6 = call i32 @std_memcpy(i8* %5, i32* %3, i32 4)
%7 = load i8*, i8** %0
%8 = getelementptr i8, i8* %7, i64 4
store i8* %8, i8** %0
ret void
}
/* Variables and functions */
int /*<<< orphan*/ scanf(char *, double *);
double read_double(void) {
  double d;
  scanf("%lf", &d);
  return d;
}


x86 assembly (clang, -O0):
<read_double>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
lea    0xee1(%rip),%rdi
lea    -0x8(%rbp),%rsi
call   1030 <scanf@plt>
movsd  -0x8(%rbp),%xmm0
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<read_double>:
push   %rax
lea    0xee8(%rip),%rdi
mov    %rsp,%rsi
call   1030 <scanf@plt>
movsd  (%rsp),%xmm0
pop    %rax
ret

LLVM IR (-O0):
@.str = [4 x i8] c"%lf\00"
define double @read_double() {
%1 = alloca double
%2 = call i32 @scanf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), double* %1)
%3 = load double, double* %1
ret double %3
}

LLVM IR (-O2):
@.str = [4 x i8] c"%lf\00"
define double @read_double() {
%1 = alloca double
%2 = bitcast double* %1 to i8*
%3 = call i32 @scanf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), double* %1)
%4 = load double, double* %1
ret double %4
}
/* Variables and functions */
int /*<<< orphan*/ POSIX_FADV_DONTNEED;
int /*<<< orphan*/ SIZE_MAX;
int /*<<< orphan*/ posix_fadvise(int, int /*<<< orphan*/, int /*<<< orphan*/,
                                 int /*<<< orphan*/);
void lic_fadv_dont(int _fd) {
  posix_fadvise(_fd, 0, SIZE_MAX, POSIX_FADV_DONTNEED);
  return;
}


x86 assembly (clang, -O0):
<lic_fadv_dont>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%edi
mov    0x2eab(%rip),%rax
mov    (%rax),%edx
mov    0x2ec2(%rip),%rax
mov    (%rax),%ecx
xor    %esi,%esi
call   1030 <posix_fadvise@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<lic_fadv_dont>:
mov    0x2eb9(%rip),%rax
mov    (%rax),%edx
mov    0x2ed0(%rip),%rax
mov    (%rax),%ecx
xor    %esi,%esi
jmp    1030 <posix_fadvise@plt>

LLVM IR (-O0):
@SIZE_MAX = global i32 0
@POSIX_FADV_DONTNEED = global i32 0
define void @lic_fadv_dont(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = load i32, i32* @SIZE_MAX
%5 = load i32, i32* @POSIX_FADV_DONTNEED
%6 = call i32 @posix_fadvise(i32 %3, i32 0, i32 %4, i32 %5)
ret void
}

LLVM IR (-O2):
@SIZE_MAX = global i32 0
@POSIX_FADV_DONTNEED = global i32 0
define void @lic_fadv_dont(i32 %0) {
%2 = load i32, i32* @SIZE_MAX
%3 = load i32, i32* @POSIX_FADV_DONTNEED
%4 = tail call i32 @posix_fadvise(i32 %0, i32 0, i32 %2, i32 %3)
ret void
}
int vrt_cmd_threads_init(void) { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @vrt_cmd_threads_init() {
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ free(void *);
void free2(void *memblock) { free(memblock); }


x86 assembly (clang, -O0):
<free2>:
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):
<free2>:
jmp    1030 <free@plt>

LLVM IR (-O0):
define void @free2(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 @free2(i8* nocapture %0) {
%2 = tail call i32 @free(i8* %0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ fgets(char *, int, int /*<<< orphan*/);
int /*<<< orphan*/ odwroc(char *);
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ stdin;
int main(void) {
  char c[10];
  printf("podaj napis: ");
  fgets(c, 10, stdin);
  odwroc(c);
  printf("%s\n", c);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
lea    0xec1(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    -0xa(%rbp),%rdi
mov    0x2e97(%rip),%rax
mov    (%rax),%edx
mov    $0xa,%esi
call   1050 <fgets@plt>
lea    -0xa(%rbp),%rdi
call   1030 <odwroc@plt>
lea    -0xa(%rbp),%rsi
lea    0xe9d(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x10,%rsp
lea    0xeb4(%rip),%rdi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0x2e8e(%rip),%rax
mov    (%rax),%edx
lea    0x6(%rsp),%rbx
mov    %rbx,%rdi
mov    $0xa,%esi
call   1060 <fgets@plt>
mov    %rbx,%rdi
call   1040 <odwroc@plt>
mov    %rbx,%rdi
call   1030 <puts@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [14 x i8] c"podaj napis: \00"
@stdin = global i32 0
@.str.1 = [4 x i8] c"%s\0A\00"
define i32 @main() {
%1 = alloca [10 x i8]
%2 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0))
%3 = getelementptr inbounds [10 x i8], [10 x i8]* %1, i64 0, i64 0
%4 = load i32, i32* @stdin
%5 = call i32 @fgets(i8* %3, i32 10, i32 %4)
%6 = getelementptr inbounds [10 x i8], [10 x i8]* %1, i64 0, i64 0
%7 = call i32 @odwroc(i8* %6)
%8 = getelementptr inbounds [10 x i8], [10 x i8]* %1, i64 0, i64 0
%9 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* %8)
ret i32 0
}

LLVM IR (-O2):
@.str = [14 x i8] c"podaj napis: \00"
@stdin = global i32 0
define i32 @main() {
%1 = alloca [10 x i8]
%2 = getelementptr inbounds [10 x i8], [10 x i8]* %1, i64 0, i64 0
%3 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0))
%4 = load i32, i32* @stdin
%5 = call i32 @fgets(i8* %2, i32 10, i32 %4)
%6 = call i32 @odwroc(i8* %2)
%7 = call i32 @puts(i8* %2)
ret i32 0
}
long foo(long x) {
  if ((x & 0xffff0000L) == 0xabcd0000L)
    return x & 0xffffL;
  return 1;
}


x86 assembly (clang, -O0):
<foo>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x10(%rbp)
movabs $0xffff0000,%rax
and    -0x10(%rbp),%rax
mov    $0xabcd0000,%ecx
cmp    %rcx,%rax
jne    1137 <foo+0x37>
mov    -0x10(%rbp),%rax
and    $0xffff,%rax
mov    %rax,-0x8(%rbp)
jmp    113f <foo+0x3f>
movq   $0x1,-0x8(%rbp)
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<foo>:
movzwl %di,%ecx
mov    %edi,%eax
and    $0xffff0000,%eax
cmp    $0xabcd0000,%eax
mov    $0x1,%eax
cmove  %rcx,%rax
ret

LLVM IR (-O0):
define i64 @foo(i64 %0) {
%2 = alloca i64
%3 = alloca i64
store i64 %0, i64* %3
%4 = load i64, i64* %3
%5 = and i64 %4, 4294901760
%6 = icmp eq i64 %5, 2882338816
br i1 %6, label %7, label %10
7: ; preds = %1
%8 = load i64, i64* %3
%9 = and i64 %8, 65535
store i64 %9, i64* %2
br label %11
10: ; preds = %1
store i64 1, i64* %2
br label %11
11: ; preds = %10, %7
%12 = load i64, i64* %2
ret i64 %12
}

LLVM IR (-O2):
define i64 @foo(i64 %0) {
%2 = and i64 %0, 4294901760
%3 = icmp eq i64 %2, 2882338816
%4 = and i64 %0, 65535
%5 = select i1 %3, i64 %4, i64 1
ret i64 %5
}
/* Variables and functions */
int stegmp(char const *, int /*<<< orphan*/ *);
int stegmp_read(const char *bmp_file) { return stegmp(bmp_file, NULL); }


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

x86 assembly (clang, -O2):
<stegmp_read>:
xor    %esi,%esi
jmp    1030 <stegmp@plt>

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

LLVM IR (-O2):
define i32 @stegmp_read(i8* %0) {
%2 = tail call i32 @stegmp(i8* %0, i32* null)
ret i32 %2
}
int esVocalAc(int c) {
  return c == 160 || c == 130 || c == 161 || c == 162 || c == 163;
}


x86 assembly (clang, -O0):
<esVocalAc>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    $0x1,%al
cmpl   $0xa0,-0x4(%rbp)
mov    %al,-0x5(%rbp)
je     115c <esVocalAc+0x5c>
mov    $0x1,%al
cmpl   $0x82,-0x4(%rbp)
mov    %al,-0x5(%rbp)
je     115c <esVocalAc+0x5c>
mov    $0x1,%al
cmpl   $0xa1,-0x4(%rbp)
mov    %al,-0x5(%rbp)
je     115c <esVocalAc+0x5c>
mov    $0x1,%al
cmpl   $0xa2,-0x4(%rbp)
mov    %al,-0x5(%rbp)
je     115c <esVocalAc+0x5c>
cmpl   $0xa3,-0x4(%rbp)
sete   %al
mov    %al,-0x5(%rbp)
mov    -0x5(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<esVocalAc>:
lea    -0x82(%rdi),%ecx
cmp    $0x20,%ecx
ja     1121 <esVocalAc+0x21>
mov    $0x1,%eax
movabs $0x1c0000001,%rdx
bt     %rcx,%rdx
jae    1121 <esVocalAc+0x21>
ret
xor    %eax,%eax
cmp    $0xa3,%edi
sete   %al
ret

LLVM IR (-O0):
define i32 @esVocalAc(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = icmp eq i32 %3, 160
br i1 %4, label %17, label %5
5: ; preds = %1
%6 = load i32, i32* %2
%7 = icmp eq i32 %6, 130
br i1 %7, label %17, label %8
8: ; preds = %5
%9 = load i32, i32* %2
%10 = icmp eq i32 %9, 161
br i1 %10, label %17, label %11
11: ; preds = %8
%12 = load i32, i32* %2
%13 = icmp eq i32 %12, 162
br i1 %13, label %17, label %14
14: ; preds = %11
%15 = load i32, i32* %2
%16 = icmp eq i32 %15, 163
br label %17
17: ; preds = %14, %11, %8, %5, %1
%18 = phi i1 [ true, %11 ], [ true, %8 ], [ true, %5 ], [ true, %1 ], [ %16, %14 ]
%19 = zext i1 %18 to i32
ret i32 %19
}

LLVM IR (-O2):
define i32 @esVocalAc(i32 %0) {
switch i32 %0, label %2 [
i32 162, label %5
i32 161, label %5
i32 160, label %5
i32 130, label %5
]
2: ; preds = %1
%3 = icmp eq i32 %0, 163
%4 = zext i1 %3 to i32
br label %5
5: ; preds = %1, %1, %1, %1, %2
%6 = phi i32 [ 1, %1 ], [ %4, %2 ], [ 1, %1 ], [ 1, %1 ], [ 1, %1 ]
ret i32 %6
}
/* Variables and functions */
int /*<<< orphan*/ cgsynth(char *);
void cgsynor(void) { cgsynth("orq"); }


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

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

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

LLVM IR (-O2):
@.str = [4 x i8] c"orq\00"
define void @cgsynor() {
%1 = tail call i32 @cgsynth(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ DisableLEDS();
int /*<<< orphan*/ printf(char *);
void cleanup(int sig) {
  printf(" Sign vector clenning up\n");
  DisableLEDS();
}


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

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

LLVM IR (-O0):
@.str = [26 x i8] c" Sign vector clenning up\0A\00"
define void @cleanup(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = call i32 @printf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str, i64 0, i64 0))
%4 = call i32 (...) @DisableLEDS()
ret void
}

LLVM IR (-O2):
@str = [25 x i8] c" Sign vector clenning up\00"
define void @cleanup(i32 %0) {
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([25 x i8], [25 x i8]* @str, i64 0, i64 0))
%3 = tail call i32 (...) @DisableLEDS()
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ X509;
typedef int /*<<< orphan*/ BIO;

/* Variables and functions */
int /*<<< orphan*/ BIO_free(int /*<<< orphan*/ *);
int /*<<< orphan*/ OPENSSL_free(char *);
int /*<<< orphan*/ *PEM_read_bio_X509(int /*<<< orphan*/ *,
                                      int /*<<< orphan*/ *,
                                      int /*<<< orphan*/ *,
                                      int /*<<< orphan*/ *);
int /*<<< orphan*/ *glue2bio(char const **, char **);
X509 *X509_from_strings(const char **pem) {
  char *p;
  BIO *b = glue2bio(pem, &p);
  X509 *x = PEM_read_bio_X509(b, NULL, NULL, NULL);
  OPENSSL_free(p);
  BIO_free(b);
  return x;
}


x86 assembly (clang, -O0):
<X509_from_strings>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
lea    -0x10(%rbp),%rsi
call   1030 <glue2bio@plt>
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rdi
xor    %eax,%eax
mov    %eax,%ecx
mov    %rcx,%rsi
mov    %rcx,%rdx
call   1060 <PEM_read_bio_X509@plt>
mov    %rax,-0x20(%rbp)
mov    -0x10(%rbp),%rdi
call   1050 <OPENSSL_free@plt>
mov    -0x18(%rbp),%rdi
call   1040 <BIO_free@plt>
mov    -0x20(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<X509_from_strings>:
push   %r14
push   %rbx
push   %rax
mov    %rsp,%rsi
call   1030 <glue2bio@plt>
mov    %rax,%rbx
mov    %rax,%rdi
xor    %esi,%esi
xor    %edx,%edx
xor    %ecx,%ecx
call   1060 <PEM_read_bio_X509@plt>
mov    %rax,%r14
mov    (%rsp),%rdi
call   1050 <OPENSSL_free@plt>
mov    %rbx,%rdi
call   1040 <BIO_free@plt>
mov    %r14,%rax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
define i32* @X509_from_strings(i8** %0) {
%2 = alloca i8**
%3 = alloca i8*
%4 = alloca i32*
%5 = alloca i32*
store i8** %0, i8*** %2
%6 = load i8**, i8*** %2
%7 = call i32* @glue2bio(i8** %6, i8** %3)
store i32* %7, i32** %4
%8 = load i32*, i32** %4
%9 = call i32* @PEM_read_bio_X509(i32* %8, i32* null, i32* null, i32* null)
store i32* %9, i32** %5
%10 = load i8*, i8** %3
%11 = call i32 @OPENSSL_free(i8* %10)
%12 = load i32*, i32** %4
%13 = call i32 @BIO_free(i32* %12)
%14 = load i32*, i32** %5
ret i32* %14
}

LLVM IR (-O2):
define i32* @X509_from_strings(i8** %0) {
%2 = alloca i8*
%3 = bitcast i8** %2 to i8*
%4 = call i32* @glue2bio(i8** %0, i8** %2)
%5 = call i32* @PEM_read_bio_X509(i32* %4, i32* null, i32* null, i32* null)
%6 = load i8*, i8** %2
%7 = call i32 @OPENSSL_free(i8* %6)
%8 = call i32 @BIO_free(i32* %4)
ret i32* %5
}
/* Variables and functions */
int f132(int *);
int f133(int *p) { return f132(p); }


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

x86 assembly (clang, -O2):
<f133>:
jmp    1030 <f132@plt>

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

LLVM IR (-O2):
define i32 @f133(i32* %0) {
%2 = tail call i32 @f132(i32* %0)
ret i32 %2
}
int ITreeSpan(int _NodeMin, int _NodeMax, int _Min, int _Max) {
  return (_NodeMin >= _Min && _NodeMax <= _Max);
}


x86 assembly (clang, -O0):
<ITreeSpan>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %ecx,-0x10(%rbp)
mov    -0x4(%rbp),%ecx
xor    %eax,%eax
cmp    -0xc(%rbp),%ecx
mov    %al,-0x11(%rbp)
jl     112d <ITreeSpan+0x2d>
mov    -0x8(%rbp),%eax
cmp    -0x10(%rbp),%eax
setle  %al
mov    %al,-0x11(%rbp)
mov    -0x11(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<ITreeSpan>:
cmp    %edx,%edi
setge  %al
cmp    %ecx,%esi
setle  %cl
and    %al,%cl
movzbl %cl,%eax
ret

LLVM IR (-O0):
define i32 @ITreeSpan(i32 %0, i32 %1, i32 %2, i32 %3) {
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
store i32 %0, i32* %5
store i32 %1, i32* %6
store i32 %2, i32* %7
store i32 %3, i32* %8
%9 = load i32, i32* %5
%10 = load i32, i32* %7
%11 = icmp sge i32 %9, %10
br i1 %11, label %12, label %16
12: ; preds = %4
%13 = load i32, i32* %6
%14 = load i32, i32* %8
%15 = icmp sle i32 %13, %14
br label %16
16: ; preds = %12, %4
%17 = phi i1 [ false, %4 ], [ %15, %12 ]
%18 = zext i1 %17 to i32
ret i32 %18
}

LLVM IR (-O2):
define i32 @ITreeSpan(i32 %0, i32 %1, i32 %2, i32 %3) {
%5 = icmp sge i32 %0, %2
%6 = icmp sle i32 %1, %3
%7 = and i1 %5, %6
%8 = zext i1 %7 to i32
ret i32 %8
}
double test_scalbln(double x, int y) { return __builtin_scalbln(x, y); }


x86 assembly (clang, -O0):
<test_scalbln>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movsd  %xmm0,-0x8(%rbp)
mov    %edi,-0xc(%rbp)
movsd  -0x8(%rbp),%xmm0
movslq -0xc(%rbp),%rdi
call   1030 <scalbln@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_scalbln>:
movslq %edi,%rdi
jmp    1030 <scalbln@plt>

LLVM IR (-O0):
define double @test_scalbln(double %0, i32 %1) {
%3 = alloca double
%4 = alloca i32
store double %0, double* %3
store i32 %1, i32* %4
%5 = load double, double* %3
%6 = load i32, i32* %4
%7 = sext i32 %6 to i64
%8 = call double @scalbln(double %5, i64 %7)
ret double %8
}

LLVM IR (-O2):
define double @test_scalbln(double %0, i32 %1) {
%3 = sext i32 %1 to i64
%4 = tail call double @scalbln(double %0, i64 %3)
ret double %4
}
/* Variables and functions */
int /*<<< orphan*/ cal_fail();
int /*<<< orphan*/ putchar(char);
int /*<<< orphan*/ puts(char *);
int /*<<< orphan*/ serial_dec32(int);
void assert_fail(char *_file_, int _line_) {
  putchar('\n');
  puts(_file_);
  putchar(':');
  serial_dec32(_line_);
  puts(" -- assert failed!");
  putchar('\n');
  cal_fail();
}


x86 assembly (clang, -O0):
<assert_fail>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    $0xa,%edi
call   1040 <putchar@plt>
mov    -0x8(%rbp),%rdi
call   1050 <puts@plt>
mov    $0x3a,%edi
call   1040 <putchar@plt>
mov    -0xc(%rbp),%edi
call   1030 <serial_dec32@plt>
lea    0xe85(%rip),%rdi
call   1050 <puts@plt>
mov    $0xa,%edi
call   1040 <putchar@plt>
mov    $0x0,%al
call   1060 <cal_fail@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<assert_fail>:
push   %rbp
push   %rbx
push   %rax
mov    %esi,%ebp
mov    %rdi,%rbx
mov    $0xa,%edi
call   1040 <putchar@plt>
mov    %rbx,%rdi
call   1050 <puts@plt>
mov    $0x3a,%edi
call   1040 <putchar@plt>
mov    %ebp,%edi
call   1030 <serial_dec32@plt>
lea    0xe8e(%rip),%rdi
call   1050 <puts@plt>
mov    $0xa,%edi
call   1040 <putchar@plt>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1060 <cal_fail@plt>

LLVM IR (-O0):
@.str = [19 x i8] c" -- assert failed!\00"
define void @assert_fail(i8* %0, i32 %1) {
%3 = alloca i8*
%4 = alloca i32
store i8* %0, i8** %3
store i32 %1, i32* %4
%5 = call i32 @putchar(i8 signext 10)
%6 = load i8*, i8** %3
%7 = call i32 @puts(i8* %6)
%8 = call i32 @putchar(i8 signext 58)
%9 = load i32, i32* %4
%10 = call i32 @serial_dec32(i32 %9)
%11 = call i32 @puts(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0))
%12 = call i32 @putchar(i8 signext 10)
%13 = call i32 (...) @cal_fail()
ret void
}

LLVM IR (-O2):
@.str = [19 x i8] c" -- assert failed!\00"
define void @assert_fail(i8* nocapture %0, i32 %1) {
%3 = tail call i32 @putchar(i8 signext 10)
%4 = tail call i32 @puts(i8* dereferenceable(1) %0)
%5 = tail call i32 @putchar(i8 signext 58)
%6 = tail call i32 @serial_dec32(i32 %1)
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0))
%8 = tail call i32 @putchar(i8 signext 10)
%9 = tail call i32 (...) @cal_fail()
ret void
}
/* Variables and functions */
char *encode_URI_component(char const *);
char *vlc_UrlEncode(const char *psz_url) {
  return encode_URI_component(psz_url);
}


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

x86 assembly (clang, -O2):
<vlc_UrlEncode>:
jmp    1030 <encode_URI_component@plt>

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

LLVM IR (-O2):
define i8* @vlc_UrlEncode(i8* %0) {
%2 = tail call i8* @encode_URI_component(i8* %0)
ret i8* %2
}
/* Type definitions */
struct sockaddr_storage {
  int dummy;
};
typedef int /*<<< orphan*/ socklen_t;

/* Variables and functions */
__attribute__((weak)) socklen_t HonggfuzzNetDriverServerAddress(
    struct sockaddr_storage *addr __attribute__((unused)),
    int *type __attribute__((unused)), int *protocol __attribute__((unused))) {
  return 0;
}


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

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

LLVM IR (-O0):
%struct.sockaddr_storage = type { i32 }
define weak i32 @HonggfuzzNetDriverServerAddress(%struct.sockaddr_storage* %0, i32* %1, i32* %2) {
%4 = alloca %struct.sockaddr_storage*
%5 = alloca i32*
%6 = alloca i32*
store %struct.sockaddr_storage* %0, %struct.sockaddr_storage** %4
store i32* %1, i32** %5
store i32* %2, i32** %6
ret i32 0
}

LLVM IR (-O2):
%struct.sockaddr_storage = type { i32 }
define weak i32 @HonggfuzzNetDriverServerAddress(%struct.sockaddr_storage* %0, i32* %1, i32* %2) {
ret i32 0
}
/* Variables and functions */
unsigned short htole16(unsigned short);
void writew(unsigned short v, void *a) {
  unsigned short *p = a;
  *p = htole16(v);
}


x86 assembly (clang, -O0):
<writew>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %di,%ax
mov    %ax,-0x2(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,-0x18(%rbp)
movzwl -0x2(%rbp),%edi
call   1030 <htole16@plt>
mov    %ax,%cx
mov    -0x18(%rbp),%rax
mov    %cx,(%rax)
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<writew>:
push   %rbx
mov    %rsi,%rbx
call   1030 <htole16@plt>
mov    %ax,(%rbx)
pop    %rbx
ret

LLVM IR (-O0):
define void @writew(i16 zeroext %0, i8* %1) {
%3 = alloca i16
%4 = alloca i8*
%5 = alloca i16*
store i16 %0, i16* %3
store i8* %1, i8** %4
%6 = load i8*, i8** %4
%7 = bitcast i8* %6 to i16*
store i16* %7, i16** %5
%8 = load i16, i16* %3
%9 = call zeroext i16 @htole16(i16 zeroext %8)
%10 = load i16*, i16** %5
store i16 %9, i16* %10
ret void
}

LLVM IR (-O2):
define void @writew(i16 zeroext %0, i8* nocapture writeonly %1) {
%3 = bitcast i8* %1 to i16*
%4 = tail call zeroext i16 @htole16(i16 zeroext %0)
store i16 %4, i16* %3
ret void
}
/* Variables and functions */
int /*<<< orphan*/ firstPass();
int /*<<< orphan*/ printAnswer();
int /*<<< orphan*/ printRemaining();
int /*<<< orphan*/ secondPass();
int /*<<< orphan*/ thirdPass();
int main() {
  printRemaining();
  firstPass();
  printRemaining();
  secondPass();
  printRemaining();
  thirdPass();
  printAnswer();
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0x0,%al
call   1050 <printRemaining@plt>
mov    $0x0,%al
call   1060 <firstPass@plt>
mov    $0x0,%al
call   1050 <printRemaining@plt>
mov    $0x0,%al
call   1040 <secondPass@plt>
mov    $0x0,%al
call   1050 <printRemaining@plt>
mov    $0x0,%al
call   1030 <thirdPass@plt>
mov    $0x0,%al
call   1070 <printAnswer@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
xor    %eax,%eax
call   1050 <printRemaining@plt>
xor    %eax,%eax
call   1060 <firstPass@plt>
xor    %eax,%eax
call   1050 <printRemaining@plt>
xor    %eax,%eax
call   1040 <secondPass@plt>
xor    %eax,%eax
call   1050 <printRemaining@plt>
xor    %eax,%eax
call   1030 <thirdPass@plt>
xor    %eax,%eax
call   1070 <printAnswer@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = call i32 (...) @printRemaining()
%3 = call i32 (...) @firstPass()
%4 = call i32 (...) @printRemaining()
%5 = call i32 (...) @secondPass()
%6 = call i32 (...) @printRemaining()
%7 = call i32 (...) @thirdPass()
%8 = call i32 (...) @printAnswer()
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 (...) @printRemaining()
%2 = tail call i32 (...) @firstPass()
%3 = tail call i32 (...) @printRemaining()
%4 = tail call i32 (...) @secondPass()
%5 = tail call i32 (...) @printRemaining()
%6 = tail call i32 (...) @thirdPass()
%7 = tail call i32 (...) @printAnswer()
ret i32 0
}