xunge/DecIR huggingface dataset:
/* Variables and functions */
int /*<<< orphan*/ func1();
int /*<<< orphan*/ mmapdata();
int /*<<< orphan*/ sleep(int);
scalar_t__ strcmp(char *, char *);
int main(int argc, char **argv) {
  if (argc == 2 && strcmp(argv[1], "sleep") == 0) {
    sleep(60);
    return 0;
  }
  mmapdata();
  func1();
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpl   $0x2,-0x8(%rbp)
jne    1194 <main+0x54>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
lea    0xe91(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%rax
jne    1194 <main+0x54>
mov    $0x3c,%edi
call   1060 <sleep@plt>
movl   $0x0,-0x4(%rbp)
jmp    11a9 <main+0x69>
mov    $0x0,%al
call   1050 <mmapdata@plt>
mov    $0x0,%al
call   1030 <func1@plt>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
cmp    $0x2,%edi
jne    115b <main+0x1b>
mov    0x8(%rsi),%rdi
lea    0xeaf(%rip),%rsi
call   1040 <strcmp@plt>
test   %rax,%rax
je     116b <main+0x2b>
xor    %eax,%eax
call   1050 <mmapdata@plt>
xor    %eax,%eax
call   1030 <func1@plt>
jmp    1175 <main+0x35>
mov    $0x3c,%edi
call   1060 <sleep@plt>
xor    %eax,%eax
pop    %rcx
ret

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

LLVM IR (-O2):
@.str = [6 x i8] c"sleep\00"
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = icmp eq i32 %0, 2
br i1 %3, label %4, label %11
4: ; preds = %2
%5 = getelementptr inbounds i8*, i8** %1, i64 1
%6 = load i8*, i8** %5
%7 = tail call i64 @strcmp(i8* %6, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
%8 = icmp eq i64 %7, 0
br i1 %8, label %9, label %11
9: ; preds = %4
%10 = tail call i32 @sleep(i32 60)
br label %14
11: ; preds = %4, %2
%12 = tail call i32 (...) @mmapdata()
%13 = tail call i32 (...) @func1()
br label %14
14: ; preds = %11, %9
ret i32 0
}
/* Type definitions */
typedef int /*<<< orphan*/ uint64_t;
typedef int /*<<< orphan*/ time_t;

/* Variables and functions */
int /*<<< orphan*/ atou64(char const *, int /*<<< orphan*/ *);
int atotime_t(const char *str, time_t *val) {
  uint64_t tmp;
  if (!atou64(str, &tmp))
    return -1;
  *val = tmp;
  return 1;
}


x86 assembly (clang, -O0):
<atotime_t>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    -0x10(%rbp),%rdi
lea    -0x1c(%rbp),%rsi
call   1030 <atou64@plt>
cmp    $0x0,%eax
jne    1142 <atotime_t+0x32>
movl   $0xffffffff,-0x4(%rbp)
jmp    1152 <atotime_t+0x42>
mov    -0x1c(%rbp),%ecx
mov    -0x18(%rbp),%rax
mov    %ecx,(%rax)
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<atotime_t>:
push   %rbx
sub    $0x10,%rsp
mov    %rsi,%rbx
lea    0xc(%rsp),%rsi
call   1030 <atou64@plt>
test   %eax,%eax
je     1133 <atotime_t+0x23>
mov    0xc(%rsp),%eax
mov    %eax,(%rbx)
mov    $0x1,%eax
jmp    1138 <atotime_t+0x28>
mov    $0xffffffff,%eax
add    $0x10,%rsp
pop    %rbx
ret

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

LLVM IR (-O2):
define i32 @atotime_t(i8* %0, i32* nocapture writeonly %1) {
%3 = alloca i32
%4 = bitcast i32* %3 to i8*
%5 = call i32 @atou64(i8* %0, i32* %3)
%6 = icmp eq i32 %5, 0
br i1 %6, label %9, label %7
7: ; preds = %2
%8 = load i32, i32* %3
store i32 %8, i32* %1
br label %9
9: ; preds = %2, %7
%10 = phi i32 [ 1, %7 ], [ -1, %2 ]
ret i32 %10
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, float, float);
main() {
  float py = 3.14;
  float rad = 4.8;
  float area = py * (rad * rad);
  printf("\nThe Cirlce with radius %f has an area of %f\n", rad, area);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movss  0xee4(%rip),%xmm0
movss  %xmm0,-0x4(%rbp)
movss  0xed3(%rip),%xmm0
movss  %xmm0,-0x8(%rbp)
movss  -0x4(%rbp),%xmm0
movss  -0x8(%rbp),%xmm1
mulss  -0x8(%rbp),%xmm1
mulss  %xmm1,%xmm0
movss  %xmm0,-0xc(%rbp)
movss  -0x8(%rbp),%xmm0
movss  -0xc(%rbp),%xmm1
lea    0xead(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
@.str = [46 x i8] c"\0AThe Cirlce with radius %f has an area of %f\0A\00"
define i32 @main() {
%1 = alloca float
%2 = alloca float
%3 = alloca float
store float 0x40091EB860000000, float* %1
store float 0x4013333340000000, float* %2
%4 = load float, float* %1
%5 = load float, float* %2
%6 = load float, float* %2
%7 = fmul float %5, %6
%8 = fmul float %4, %7
store float %8, float* %3
%9 = load float, float* %2
%10 = load float, float* %3
%11 = call i32 @printf(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str, i64 0, i64 0), float %9, float %10)
ret i32 0
}

LLVM IR (-O2):
@.str = [46 x i8] c"\0AThe Cirlce with radius %f has an area of %f\0A\00"
define i32 @main() {
%1 = tail call i32 @printf(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str, i64 0, i64 0), float 0x4013333340000000, float 0x4052161E60000000)
ret i32 0
}
void g_string_erase() {}


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

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

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

LLVM IR (-O2):
define void @g_string_erase() {
ret void
}
void dbg_wait(const int factor) {
  if (factor > 0) {
    for (int j = 1; j <= 2000 * factor; ++j)
      ;
  } else {
    __asm__("infinite_loop: hlt;                                jmp "
            "infinite_loop;");
  }
}


x86 assembly (clang, -O0):
<dbg_wait>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
cmpl   $0x0,-0x4(%rbp)
jle    1142 <infinite_loop>
movl   $0x1,-0x8(%rbp)
mov    -0x8(%rbp),%eax
imul   $0x7d0,-0x4(%rbp),%ecx
cmp    %ecx,%eax
jg     113d <dbg_wait+0x3d>
jmp    112f <dbg_wait+0x2f>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1118 <dbg_wait+0x18>
jmp    1148 <infinite_loop+0x6>

x86 assembly (clang, -O2):
<dbg_wait>:
test   %edi,%edi
jle    1105 <infinite_loop>
ret

LLVM IR (-O0):
define void @dbg_wait(i32 %0) {
%2 = alloca i32
%3 = alloca i32
store i32 %0, i32* %2
%4 = load i32, i32* %2
%5 = icmp sgt i32 %4, 0
br i1 %5, label %6, label %17
6: ; preds = %1
store i32 1, i32* %3
br label %7
7: ; preds = %13, %6
%8 = load i32, i32* %3
%9 = load i32, i32* %2
%10 = mul nsw i32 2000, %9
%11 = icmp sle i32 %8, %10
br i1 %11, label %12, label %16
12: ; preds = %7
br label %13
13: ; preds = %12
%14 = load i32, i32* %3
%15 = add nsw i32 %14, 1
store i32 %15, i32* %3
br label %7
16: ; preds = %7
br label %18
17: ; preds = %1
br label %18
18: ; preds = %17, %16
ret void
}

LLVM IR (-O2):
define void @dbg_wait(i32 %0) {
%2 = icmp sgt i32 %0, 0
br i1 %2, label %4, label %3
3: ; preds = %1
tail call void asm sideeffect "infinite_loop: hlt; jmp infinite_loop;", "~{dirflag},~{fpsr},~{flags}"()
br label %4
4: ; preds = %1, %3
ret void
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ isspace(int);
void t_isspace_0xd8() {
  Assert_real((isspace(216) == 0),
              "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/"
              "2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/"
              "dg/z88dk/test/suites/ctype/test_isspace.c",
              1085, ("isspace should be 0 for 0xd8"));
}


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

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

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

LLVM IR (-O2):
@.str = [168 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_isspace.c\00"
@.str.1 = [29 x i8] c"isspace should be 0 for 0xd8\00"
define void @t_isspace_0xd8() {
%1 = tail call i64 @isspace(i32 216)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = tail call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 1085, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Forward declarations */
typedef struct TYPE_2__ TYPE_1__;

/* Type definitions */
struct TYPE_2__ {
  scalar_t__ window;
};
typedef TYPE_1__ XMotionEvent;

/* Variables and functions */
unsigned long get_XMotionEvent_window(void *_p) {
  return (unsigned long)((XMotionEvent *)_p)->window;
}


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

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

LLVM IR (-O0):
%struct.TYPE_2__ = type { i64 }
define i64 @get_XMotionEvent_window(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = bitcast i8* %3 to %struct.TYPE_2__*
%5 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %4, i32 0, i32 0
%6 = load i64, i64* %5
ret i64 %6
}

LLVM IR (-O2):
define i64 @get_XMotionEvent_window(i8* nocapture %0) {
%2 = bitcast i8* %0 to i64*
%3 = load i64, i64* %2
ret i64 %3
}
int fun1152() { return 1152; }


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

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

LLVM IR (-O0):
define i32 @fun1152() {
ret i32 1152
}

LLVM IR (-O2):
define i32 @fun1152() {
ret i32 1152
}
/* Variables and functions */
int /*<<< orphan*/ mergeSort(int *, int, int, int);
void partition(int arr[], int low, int high) {
  int mid;
  if (low < high) {
    mid = (low + high) / 2;
    partition(arr, low, mid);
    partition(arr, mid + 1, high);
    mergeSort(arr, low, mid, high);
  }
}


x86 assembly (clang, -O0):
<partition>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %edx,-0x10(%rbp)
mov    -0xc(%rbp),%eax
cmp    -0x10(%rbp),%eax
jge    1182 <partition+0x62>
mov    -0xc(%rbp),%eax
add    -0x10(%rbp),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,-0x14(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
mov    -0x14(%rbp),%edx
call   1030 <partition@plt>
mov    -0x8(%rbp),%rdi
mov    -0x14(%rbp),%esi
add    $0x1,%esi
mov    -0x10(%rbp),%edx
call   1030 <partition@plt>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
mov    -0x14(%rbp),%edx
mov    -0x10(%rbp),%ecx
call   1040 <mergeSort@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<partition>:
cmp    %edx,%esi
jge    1172 <partition+0x52>
push   %r15
push   %r14
push   %r12
push   %rbx
push   %rax
mov    %edx,%r14d
mov    %esi,%r12d
mov    %rdi,%r15
lea    (%r14,%r12,1),%eax
mov    %eax,%ebx
shr    $0x1f,%ebx
add    %eax,%ebx
sar    %ebx
mov    %ebx,%edx
call   1030 <partition@plt>
lea    0x1(%rbx),%esi
mov    %r15,%rdi
mov    %r14d,%edx
call   1030 <partition@plt>
mov    %r15,%rdi
mov    %r12d,%esi
mov    %ebx,%edx
mov    %r14d,%ecx
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
jmp    1040 <mergeSort@plt>
ret

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

LLVM IR (-O2):
define void @partition(i32* %0, i32 %1, i32 %2) {
%4 = icmp slt i32 %1, %2
br i1 %4, label %6, label %5
5: ; preds = %3, %6
ret void
6: ; preds = %3
%7 = add nsw i32 %2, %1
%8 = sdiv i32 %7, 2
tail call void @partition(i32* %0, i32 %1, i32 %8)
%9 = add nsw i32 %8, 1
tail call void @partition(i32* %0, i32 %9, i32 %2)
%10 = tail call i32 @mergeSort(i32* %0, i32 %1, i32 %8, i32 %2)
br label %5
}
/* Variables and functions */
double exp(scalar_t__);
scalar_t__ lgamma(double);
double beta(double a, double b) {
  return exp(lgamma(a) + lgamma(b) - lgamma(a + b));
}


x86 assembly (clang, -O0):
<beta>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
movsd  -0x8(%rbp),%xmm0
call   1040 <lgamma@plt>
mov    %rax,-0x20(%rbp)
movsd  -0x10(%rbp),%xmm0
call   1040 <lgamma@plt>
mov    %rax,%rcx
mov    -0x20(%rbp),%rax
add    %rcx,%rax
mov    %rax,-0x18(%rbp)
movsd  -0x8(%rbp),%xmm0
addsd  -0x10(%rbp),%xmm0
call   1040 <lgamma@plt>
mov    -0x18(%rbp),%rdi
sub    %rax,%rdi
call   1030 <exp@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<beta>:
push   %rbx
sub    $0x10,%rsp
movsd  %xmm1,(%rsp)
movsd  %xmm0,0x8(%rsp)
call   1040 <lgamma@plt>
mov    %rax,%rbx
movsd  (%rsp),%xmm0
call   1040 <lgamma@plt>
add    %rax,%rbx
movsd  0x8(%rsp),%xmm0
addsd  (%rsp),%xmm0
call   1040 <lgamma@plt>
sub    %rax,%rbx
mov    %rbx,%rdi
add    $0x10,%rsp
pop    %rbx
jmp    1030 <exp@plt>

LLVM IR (-O0):
define double @beta(double %0, double %1) {
%3 = alloca double
%4 = alloca double
store double %0, double* %3
store double %1, double* %4
%5 = load double, double* %3
%6 = call i64 @lgamma(double %5)
%7 = load double, double* %4
%8 = call i64 @lgamma(double %7)
%9 = add nsw i64 %6, %8
%10 = load double, double* %3
%11 = load double, double* %4
%12 = fadd double %10, %11
%13 = call i64 @lgamma(double %12)
%14 = sub nsw i64 %9, %13
%15 = call double @exp(i64 %14)
ret double %15
}

LLVM IR (-O2):
define double @beta(double %0, double %1) {
%3 = tail call i64 @lgamma(double %0)
%4 = tail call i64 @lgamma(double %1)
%5 = add nsw i64 %4, %3
%6 = fadd double %0, %1
%7 = tail call i64 @lgamma(double %6)
%8 = sub i64 %5, %7
%9 = tail call double @exp(i64 %8)
ret double %9
}
int HelpItem98(void) { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @HelpItem98() {
ret i32 0
}
int stack_check(int depth) {
  int buf[10];
  int i;
  if (depth == 100)
    return 1;
  for (i = 0; i < 10; i++) {
    buf[i] += stack_check(depth + 1);
  }
  return buf[0];
}


x86 assembly (clang, -O0):
<stack_check>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
mov    %edi,-0x8(%rbp)
cmpl   $0x64,-0x8(%rbp)
jne    1131 <stack_check+0x21>
movl   $0x1,-0x4(%rbp)
jmp    116f <stack_check+0x5f>
movl   $0x0,-0x34(%rbp)
cmpl   $0xa,-0x34(%rbp)
jge    1169 <stack_check+0x59>
mov    -0x8(%rbp),%edi
add    $0x1,%edi
call   1030 <stack_check@plt>
mov    %eax,%ecx
movslq -0x34(%rbp),%rax
add    -0x30(%rbp,%rax,4),%ecx
mov    %ecx,-0x30(%rbp,%rax,4)
mov    -0x34(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x34(%rbp)
jmp    1138 <stack_check+0x28>
mov    -0x30(%rbp),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<stack_check>:
cmp    $0x64,%edi
je     1122 <stack_check+0x12>
push   %rax
add    $0x1,%edi
call   1030 <stack_check@plt>
add    $0x8,%rsp
mov    $0x1,%eax
ret

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

LLVM IR (-O2):
define i32 @stack_check(i32 %0) {
%2 = icmp eq i32 %0, 100
br i1 %2, label %6, label %3
3: ; preds = %1
%4 = add nsw i32 %0, 1
%5 = tail call i32 @stack_check(i32 %4)
br label %6
6: ; preds = %1, %3
ret i32 1
}
/* Type definitions */
typedef int /*<<< orphan*/ uint64_t;

/* Variables and functions */
int /*<<< orphan*/ internal_fiat_secp256k1_from_montgomery(uintptr_t,
                                                           uintptr_t);
void fiat_secp256k1_from_montgomery(uint64_t out1[4], const uint64_t arg1[4]) {
  internal_fiat_secp256k1_from_montgomery((uintptr_t)out1, (uintptr_t)arg1);
}


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

x86 assembly (clang, -O2):
<fiat_secp256k1_from_montgomery>:
jmp    1030 <internal_fiat_secp256k1_from_montgomery@plt>

LLVM IR (-O0):
define void @fiat_secp256k1_from_montgomery(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 = ptrtoint i32* %5 to i64
%7 = load i32*, i32** %4
%8 = ptrtoint i32* %7 to i64
%9 = call i32 @internal_fiat_secp256k1_from_montgomery(i64 %6, i64 %8)
ret void
}

LLVM IR (-O2):
define void @fiat_secp256k1_from_montgomery(i32* %0, i32* %1) {
%3 = ptrtoint i32* %0 to i64
%4 = ptrtoint i32* %1 to i64
%5 = tail call i32 @internal_fiat_secp256k1_from_montgomery(i64 %3, i64 %4)
ret void
}
int dbg_is_chk_index(const struct ubifs_info *c) { return 0; }


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

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

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

LLVM IR (-O2):
%struct.ubifs_info = type opaque
define i32 @dbg_is_chk_index(%struct.ubifs_info* nocapture readnone %0) {
ret i32 0
}
/* Variables and functions */
int __VERIFIER_nondet_int();
int ZwClose(int Handle) {
  {
    int tmp_ndt_15;
    tmp_ndt_15 = __VERIFIER_nondet_int();
    if (tmp_ndt_15 == 0) {
      goto switch_12_0;
    } else {
      goto switch_12_default;
      if (0) {
      switch_12_0:
        return (0);
      switch_12_default:;
        return (-1073741823);
      } else {
      }
    }
  }
}


x86 assembly (clang, -O0):
<ZwClose>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x8(%rbp)
mov    $0x0,%al
call   1030 <__VERIFIER_nondet_int@plt>
mov    %eax,-0xc(%rbp)
cmpl   $0x0,-0xc(%rbp)
jne    1134 <ZwClose+0x24>
jmp    1139 <ZwClose+0x29>
jmp    1145 <ZwClose+0x35>
movl   $0x0,-0x4(%rbp)
jmp    114c <ZwClose+0x3c>
movl   $0xc0000001,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ZwClose>:
push   %rax
xor    %eax,%eax
call   1030 <__VERIFIER_nondet_int@plt>
test   %eax,%eax
mov    $0xc0000001,%ecx
cmovne %ecx,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @ZwClose(i32 %0) {
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
store i32 %0, i32* %3
%5 = call i32 (...) @__VERIFIER_nondet_int()
store i32 %5, i32* %4
%6 = load i32, i32* %4
%7 = icmp eq i32 %6, 0
br i1 %7, label %8, label %9
8: ; preds = %1
br label %12
9: ; preds = %1
br label %13
10: ; No predecessors!
br i1 false, label %11, label %14
11: ; preds = %10
br label %12
12: ; preds = %11, %8
store i32 0, i32* %2
br label %16
13: ; preds = %9
store i32 -1073741823, i32* %2
br label %16
14: ; preds = %10
br label %15
15: ; preds = %14
br label %16
16: ; preds = %12, %13, %15
%17 = load i32, i32* %2
ret i32 %17
}

LLVM IR (-O2):
define i32 @ZwClose(i32 %0) {
%2 = tail call i32 (...) @__VERIFIER_nondet_int()
%3 = icmp eq i32 %2, 0
%4 = select i1 %3, i32 0, i32 -1073741823
ret i32 %4
}
int test_imm_1Bint64_midword_mem(long long *val) {
  return ((*val >> 16) & (0x1B << 0)) ? -20 : -40;
}


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

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

LLVM IR (-O0):
define i32 @test_imm_1Bint64_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, 27
%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_1Bint64_midword_mem(i64* nocapture %0) {
%2 = load i64, i64* %0
%3 = and i64 %2, 1769472
%4 = icmp eq i64 %3, 0
%5 = select i1 %4, i32 -40, i32 -20
ret i32 %5
}
void led_num(short state) {
  if (state)
    (*(volatile unsigned char *)(0xffffb3)) &= ~(1 << 5);
  else
    (*(volatile unsigned char *)(0xffffb3)) |= (1 << 5);
}


x86 assembly (clang, -O0):
<led_num>:
push   %rbp
mov    %rsp,%rbp
mov    %di,%ax
mov    %ax,-0x2(%rbp)
cmpw   $0x0,-0x2(%rbp)
je     1131 <led_num+0x31>
mov    $0xffffb3,%eax
mov    (%rax),%al
movzbl %al,%eax
and    $0xffffffdf,%eax
mov    %al,%cl
mov    $0xffffb3,%eax
mov    %cl,(%rax)
jmp    1147 <led_num+0x47>
mov    $0xffffb3,%eax
mov    (%rax),%al
movzbl %al,%eax
or     $0x20,%eax
mov    %al,%cl
mov    $0xffffb3,%eax
mov    %cl,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<led_num>:
test   %di,%di
sete   %al
mov    0xffffb3,%cl
and    $0xdf,%cl
shl    $0x5,%al
or     %cl,%al
mov    %al,0xffffb3
ret

LLVM IR (-O0):
define void @led_num(i16 signext %0) {
%2 = alloca i16
store i16 %0, i16* %2
%3 = load i16, i16* %2
%4 = icmp ne i16 %3, 0
br i1 %4, label %5, label %10
5: ; preds = %1
%6 = load volatile i8, i8* inttoptr (i64 16777139 to i8*)
%7 = zext i8 %6 to i32
%8 = and i32 %7, -33
%9 = trunc i32 %8 to i8
store volatile i8 %9, i8* inttoptr (i64 16777139 to i8*)
br label %15
10: ; preds = %1
%11 = load volatile i8, i8* inttoptr (i64 16777139 to i8*)
%12 = zext i8 %11 to i32
%13 = or i32 %12, 32
%14 = trunc i32 %13 to i8
store volatile i8 %14, i8* inttoptr (i64 16777139 to i8*)
br label %15
15: ; preds = %10, %5
ret void
}

LLVM IR (-O2):
define void @led_num(i16 signext %0) {
%2 = icmp eq i16 %0, 0
%3 = load volatile i8, i8* inttoptr (i64 16777139 to i8*)
%4 = and i8 %3, -33
%5 = select i1 %2, i8 32, i8 0
%6 = or i8 %4, %5
store volatile i8 %6, i8* inttoptr (i64 16777139 to i8*)
ret void
}
int test33(int *a, int b, int c, volatile char *d) {
  d[1] = a[0] == 0;
  return b;
}


x86 assembly (clang, -O0):
<test33>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %edx,-0x10(%rbp)
mov    %rcx,-0x18(%rbp)
mov    -0x8(%rbp),%rax
cmpl   $0x0,(%rax)
sete   %al
and    $0x1,%al
movzbl %al,%eax
mov    %al,%cl
mov    -0x18(%rbp),%rax
mov    %cl,0x1(%rax)
mov    -0xc(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<test33>:
cmpl   $0x0,(%rdi)
mov    %esi,%eax
sete   0x1(%rcx)
ret

LLVM IR (-O0):
define i32 @test33(i32* %0, i32 %1, i32 %2, i8* %3) {
%5 = alloca i32*
%6 = alloca i32
%7 = alloca i32
%8 = alloca i8*
store i32* %0, i32** %5
store i32 %1, i32* %6
store i32 %2, i32* %7
store i8* %3, i8** %8
%9 = load i32*, i32** %5
%10 = getelementptr inbounds i32, i32* %9, i64 0
%11 = load i32, i32* %10
%12 = icmp eq i32 %11, 0
%13 = zext i1 %12 to i32
%14 = trunc i32 %13 to i8
%15 = load i8*, i8** %8
%16 = getelementptr inbounds i8, i8* %15, i64 1
store volatile i8 %14, i8* %16
%17 = load i32, i32* %6
ret i32 %17
}

LLVM IR (-O2):
define i32 @test33(i32* nocapture %0, i32 returned %1, i32 %2, i8* %3) {
%5 = load i32, i32* %0
%6 = icmp eq i32 %5, 0
%7 = zext i1 %6 to i8
%8 = getelementptr inbounds i8, i8* %3, i64 1
store volatile i8 %7, i8* %8
ret i32 %1
}
int flteq(double a, double b) {
  double hibound = a + 0.000002;
  double lobound = a - 0.000002;
  if (b > hibound || b < lobound)
    return (0);
  return (1);
}


x86 assembly (clang, -O0):
<flteq>:
push   %rbp
mov    %rsp,%rbp
movsd  %xmm0,-0x10(%rbp)
movsd  %xmm1,-0x18(%rbp)
movsd  0xeea(%rip),%xmm0
addsd  -0x10(%rbp),%xmm0
movsd  %xmm0,-0x20(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  0xed3(%rip),%xmm1
subsd  %xmm1,%xmm0
movsd  %xmm0,-0x28(%rbp)
movsd  -0x18(%rbp),%xmm0
ucomisd -0x20(%rbp),%xmm0
ja     115a <flteq+0x5a>
movsd  -0x18(%rbp),%xmm1
movsd  -0x28(%rbp),%xmm0
ucomisd %xmm1,%xmm0
jbe    1166 <flteq+0x66>
movl   $0x0,-0x4(%rbp)
jmp    116d <flteq+0x6d>
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<flteq>:
movsd  0xef8(%rip),%xmm2
addsd  %xmm0,%xmm2
ucomisd %xmm2,%xmm1
setbe  %al
addsd  0xeed(%rip),%xmm0
ucomisd %xmm1,%xmm0
setbe  %cl
and    %al,%cl
movzbl %cl,%eax
ret

LLVM IR (-O0):
define i32 @flteq(double %0, double %1) {
%3 = alloca i32
%4 = alloca double
%5 = alloca double
%6 = alloca double
%7 = alloca double
store double %0, double* %4
store double %1, double* %5
%8 = load double, double* %4
%9 = fadd double %8, 2.000000e-06
store double %9, double* %6
%10 = load double, double* %4
%11 = fsub double %10, 2.000000e-06
store double %11, double* %7
%12 = load double, double* %5
%13 = load double, double* %6
%14 = fcmp ogt double %12, %13
br i1 %14, label %19, label %15
15: ; preds = %2
%16 = load double, double* %5
%17 = load double, double* %7
%18 = fcmp olt double %16, %17
br i1 %18, label %19, label %20
19: ; preds = %15, %2
store i32 0, i32* %3
br label %21
20: ; preds = %15
store i32 1, i32* %3
br label %21
21: ; preds = %20, %19
%22 = load i32, i32* %3
ret i32 %22
}

LLVM IR (-O2):
define i32 @flteq(double %0, double %1) {
%3 = fadd double %0, 2.000000e-06
%4 = fcmp uge double %3, %1
%5 = fadd double %0, -2.000000e-06
%6 = fcmp ule double %5, %1
%7 = and i1 %4, %6
%8 = zext i1 %7 to i32
ret i32 %8
}
/* Type definitions */
struct rbtree_bp {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ free(struct rbtree_bp *);
int /*<<< orphan*/ rbtree_bp_clear(struct rbtree_bp *);
void rbtree_bp_free(struct rbtree_bp *target) {
  rbtree_bp_clear(target);
  free(target);
}


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

x86 assembly (clang, -O2):
<rbtree_bp_free>:
push   %rbx
mov    %rdi,%rbx
call   1040 <rbtree_bp_clear@plt>
mov    %rbx,%rdi
pop    %rbx
jmp    1030 <free@plt>

LLVM IR (-O0):
%struct.rbtree_bp = type { i32 }
define void @rbtree_bp_free(%struct.rbtree_bp* %0) {
%2 = alloca %struct.rbtree_bp*
store %struct.rbtree_bp* %0, %struct.rbtree_bp** %2
%3 = load %struct.rbtree_bp*, %struct.rbtree_bp** %2
%4 = call i32 @rbtree_bp_clear(%struct.rbtree_bp* %3)
%5 = load %struct.rbtree_bp*, %struct.rbtree_bp** %2
%6 = call i32 @free(%struct.rbtree_bp* %5)
ret void
}

LLVM IR (-O2):
%struct.rbtree_bp = type { i32 }
define void @rbtree_bp_free(%struct.rbtree_bp* %0) {
%2 = tail call i32 @rbtree_bp_clear(%struct.rbtree_bp* %0)
%3 = tail call i32 @free(%struct.rbtree_bp* %0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ nmea_load_parsers();
void nmea_init() { nmea_load_parsers(); }


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

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

LLVM IR (-O0):
define void @nmea_init() {
%1 = call i32 (...) @nmea_load_parsers()
ret void
}

LLVM IR (-O2):
define void @nmea_init() {
%1 = tail call i32 (...) @nmea_load_parsers()
ret void
}
float ffvers(float *version) {
  *version = (float)3.35;
  return (*version);
}


x86 assembly (clang, -O0):
<ffvers>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
movss  0xeec(%rip),%xmm0
movss  %xmm0,(%rax)
mov    -0x8(%rbp),%rax
movss  (%rax),%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<ffvers>:
movl   $0x40566666,(%rdi)
movss  0xef2(%rip),%xmm0
ret

LLVM IR (-O0):
define float @ffvers(float* %0) {
%2 = alloca float*
store float* %0, float** %2
%3 = load float*, float** %2
store float 0x400ACCCCC0000000, float* %3
%4 = load float*, float** %2
%5 = load float, float* %4
ret float %5
}

LLVM IR (-O2):
define float @ffvers(float* nocapture writeonly %0) {
store float 0x400ACCCCC0000000, float* %0
ret float 0x400ACCCCC0000000
}
int return_false(void) { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @return_false() {
ret i32 0
}
void pr34373() {
  int *a = 0;
  (a + 0)[0];
}


x86 assembly (clang, -O0):
<pr34373>:
push   %rbp
mov    %rsp,%rbp
movq   $0x0,-0x8(%rbp)
pop    %rbp
ret

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

LLVM IR (-O0):
define void @pr34373() {
%1 = alloca i32*
store i32* null, i32** %1
%2 = load i32*, i32** %1
%3 = getelementptr inbounds i32, i32* %2, i64 0
%4 = getelementptr inbounds i32, i32* %3, i64 0
%5 = load i32, i32* %4
ret void
}

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

/* Variables and functions */
int /*<<< orphan*/ epoll10(struct __test_metadata *);
void wrapper_epoll10(struct __test_metadata *_metadata,
                     struct __fixture_variant_metadata *variant) {
  epoll10(_metadata);
}


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

x86 assembly (clang, -O2):
<wrapper_epoll10>:
jmp    1030 <epoll10@plt>

LLVM IR (-O0):
%struct.__test_metadata = type { i32 }
%struct.__fixture_variant_metadata = type { i32 }
define void @wrapper_epoll10(%struct.__test_metadata* %0, %struct.__fixture_variant_metadata* %1) {
%3 = alloca %struct.__test_metadata*
%4 = alloca %struct.__fixture_variant_metadata*
store %struct.__test_metadata* %0, %struct.__test_metadata** %3
store %struct.__fixture_variant_metadata* %1, %struct.__fixture_variant_metadata** %4
%5 = load %struct.__test_metadata*, %struct.__test_metadata** %3
%6 = call i32 @epoll10(%struct.__test_metadata* %5)
ret void
}

LLVM IR (-O2):
%struct.__test_metadata = type { i32 }
%struct.__fixture_variant_metadata = type { i32 }
define void @wrapper_epoll10(%struct.__test_metadata* %0, %struct.__fixture_variant_metadata* nocapture readnone %1) {
%3 = tail call i32 @epoll10(%struct.__test_metadata* %0)
ret void
}
/* Variables and functions */
double log10(float);
float dbLogB(float x) {
  if (x <= 1.18e-38f)
    return -379.28f;
  return (float)(10.0 * log10(x));
}


x86 assembly (clang, -O0):
<dbLogB>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movss  %xmm0,-0x8(%rbp)
movss  0xedb(%rip),%xmm0
ucomiss -0x8(%rbp),%xmm0
jb     1141 <dbLogB+0x31>
movss  0xecd(%rip),%xmm0
movss  %xmm0,-0x4(%rbp)
jmp    1163 <dbLogB+0x53>
movss  -0x8(%rbp),%xmm0
call   1030 <log10@plt>
movaps %xmm0,%xmm1
movsd  0xeb2(%rip),%xmm0
mulsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<dbLogB>:
push   %rax
movss  0xeeb(%rip),%xmm1
ucomiss %xmm0,%xmm1
jae    1131 <dbLogB+0x21>
call   1030 <log10@plt>
mulsd  0xedd(%rip),%xmm0
cvtsd2ss %xmm0,%xmm0
pop    %rax
ret
movss  0xec7(%rip),%xmm0
pop    %rax
ret

LLVM IR (-O0):
define float @dbLogB(float %0) {
%2 = alloca float
%3 = alloca float
store float %0, float* %3
%4 = load float, float* %3
%5 = fcmp ole float %4, 0x38100FB320000000
br i1 %5, label %6, label %7
6: ; preds = %1
store float 0xC077B47AE0000000, float* %2
br label %12
7: ; preds = %1
%8 = load float, float* %3
%9 = call double @log10(float %8)
%10 = fmul double 1.000000e+01, %9
%11 = fptrunc double %10 to float
store float %11, float* %2
br label %12
12: ; preds = %7, %6
%13 = load float, float* %2
ret float %13
}

LLVM IR (-O2):
define float @dbLogB(float %0) {
%2 = fcmp ugt float %0, 0x38100FB320000000
br i1 %2, label %3, label %7
3: ; preds = %1
%4 = tail call double @log10(float %0)
%5 = fmul double %4, 1.000000e+01
%6 = fptrunc double %5 to float
br label %7
7: ; preds = %1, %3
%8 = phi float [ %6, %3 ], [ 0xC077B47AE0000000, %1 ]
ret float %8
}
/* Variables and functions */
int /*<<< orphan*/ chSysLock();
int /*<<< orphan*/ chSysUnlock();
int /*<<< orphan*/ chVTResetTimeStampI();
void chVTResetTimeStamp(void) {
  chSysLock();
  chVTResetTimeStampI();
  chSysUnlock();
}


x86 assembly (clang, -O0):
<chVTResetTimeStamp>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1030 <chSysLock@plt>
mov    $0x0,%al
call   1040 <chVTResetTimeStampI@plt>
mov    $0x0,%al
call   1050 <chSysUnlock@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<chVTResetTimeStamp>:
push   %rax
xor    %eax,%eax
call   1030 <chSysLock@plt>
xor    %eax,%eax
call   1040 <chVTResetTimeStampI@plt>
xor    %eax,%eax
pop    %rcx
jmp    1050 <chSysUnlock@plt>

LLVM IR (-O0):
define void @chVTResetTimeStamp() {
%1 = call i32 (...) @chSysLock()
%2 = call i32 (...) @chVTResetTimeStampI()
%3 = call i32 (...) @chSysUnlock()
ret void
}

LLVM IR (-O2):
define void @chVTResetTimeStamp() {
%1 = tail call i32 (...) @chSysLock()
%2 = tail call i32 (...) @chVTResetTimeStampI()
%3 = tail call i32 (...) @chSysUnlock()
ret void
}
unsigned int *s_to_u_assign(signed int *sp) {
  unsigned int *up;
  up = sp;
  return up;
}


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

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

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

LLVM IR (-O2):
define i32* @s_to_u_assign(i32* readnone returned %0) {
ret i32* %0
}
void i2d_ECParameters(void) {}


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

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

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

LLVM IR (-O2):
define void @i2d_ECParameters() {
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ uint8_t;
typedef int /*<<< orphan*/ c;

/* Variables and functions */
int /*<<< orphan*/ STDIN_FILENO;
int /*<<< orphan*/ read(int /*<<< orphan*/, int /*<<< orphan*/ *, int);
uint8_t _read_char(void) {
  uint8_t c = 0;
  read(STDIN_FILENO, &c, sizeof(c));
  return c;
}


x86 assembly (clang, -O0):
<_read_char>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    0x2eba(%rip),%rax
mov    (%rax),%edi
lea    -0x4(%rbp),%rsi
mov    $0x4,%edx
call   1030 <read@plt>
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<_read_char>:
push   %rax
movl   $0x0,0x4(%rsp)
mov    0x2ec0(%rip),%rax
mov    (%rax),%edi
lea    0x4(%rsp),%rsi
mov    $0x4,%edx
call   1030 <read@plt>
mov    0x4(%rsp),%eax
pop    %rcx
ret

LLVM IR (-O0):
@STDIN_FILENO = global i32 0
define i32 @_read_char() {
%1 = alloca i32
store i32 0, i32* %1
%2 = load i32, i32* @STDIN_FILENO
%3 = call i32 @read(i32 %2, i32* %1, i32 4)
%4 = load i32, i32* %1
ret i32 %4
}

LLVM IR (-O2):
@STDIN_FILENO = global i32 0
define i32 @_read_char() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
store i32 0, i32* %1
%3 = load i32, i32* @STDIN_FILENO
%4 = call i32 @read(i32 %3, i32* %1, i32 4)
%5 = load i32, i32* %1
ret i32 %5
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
int scanf(char *, int *);
int getInt(void) {
  int tmpInt;
  if (scanf("%d", &tmpInt) == 1) {
    return tmpInt;
  } else {
    printf("Plus d'une chaine a été saisie.");
    return -1;
  }
}


x86 assembly (clang, -O0):
<getInt>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
lea    0xed1(%rip),%rdi
lea    -0x8(%rbp),%rsi
call   1040 <scanf@plt>
cmp    $0x1,%eax
jne    114c <getInt+0x2c>
mov    -0x8(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    115f <getInt+0x3f>
lea    0xeb0(%rip),%rdi
call   1030 <printf@plt>
movl   $0xffffffff,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<getInt>:
push   %rax
lea    0xed8(%rip),%rdi
lea    0x4(%rsp),%rsi
call   1040 <scanf@plt>
cmp    $0x1,%eax
jne    113d <getInt+0x1d>
mov    0x4(%rsp),%eax
pop    %rcx
ret
lea    0xebf(%rip),%rdi
call   1030 <printf@plt>
mov    $0xffffffff,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%d\00"
@.str.1 = [34 x i8] c"Plus d'une chaine a \C3\A9t\C3\A9 saisie.\00"
define i32 @getInt() {
%1 = alloca i32
%2 = alloca i32
%3 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %2)
%4 = icmp eq i32 %3, 1
br i1 %4, label %5, label %7
5: ; preds = %0
%6 = load i32, i32* %2
store i32 %6, i32* %1
br label %9
7: ; preds = %0
%8 = call i32 @printf(i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str.1, i64 0, i64 0))
store i32 -1, i32* %1
br label %9
9: ; preds = %7, %5
%10 = load i32, i32* %1
ret i32 %10
}

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
@.str.1 = [34 x i8] c"Plus d'une chaine a \C3\A9t\C3\A9 saisie.\00"
define i32 @getInt() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
%3 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %1)
%4 = icmp eq i32 %3, 1
br i1 %4, label %5, label %7
5: ; preds = %0
%6 = load i32, i32* %1
br label %9
7: ; preds = %0
%8 = call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([34 x i8], [34 x i8]* @.str.1, i64 0, i64 0))
br label %9
9: ; preds = %7, %5
%10 = phi i32 [ %6, %5 ], [ -1, %7 ]
ret i32 %10
}
/* Variables and functions */
int /*<<< orphan*/ execve(char *, char **, int /*<<< orphan*/ *);
void get_shell_seg() {
  char *shell = "/bin/sh";
  char *args[] = {shell, NULL};
  execve(shell, args, NULL);
}


x86 assembly (clang, -O0):
<get_shell_seg>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
lea    0xee1(%rip),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x20(%rbp)
movq   $0x0,-0x18(%rbp)
mov    -0x8(%rbp),%rdi
lea    -0x20(%rbp),%rsi
xor    %eax,%eax
mov    %eax,%edx
call   1030 <execve@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<get_shell_seg>:
sub    $0x18,%rsp
lea    0xee5(%rip),%rdi
mov    %rdi,(%rsp)
movq   $0x0,0x8(%rsp)
mov    %rsp,%rsi
xor    %edx,%edx
call   1030 <execve@plt>
add    $0x18,%rsp
ret

LLVM IR (-O0):
@.str = [8 x i8] c"/bin/sh\00"
define void @get_shell_seg() {
%1 = alloca i8*
%2 = alloca [2 x i8*]
store i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i8** %1
%3 = getelementptr inbounds [2 x i8*], [2 x i8*]* %2, i64 0, i64 0
%4 = load i8*, i8** %1
store i8* %4, i8** %3
%5 = getelementptr inbounds i8*, i8** %3, i64 1
store i8* null, i8** %5
%6 = load i8*, i8** %1
%7 = getelementptr inbounds [2 x i8*], [2 x i8*]* %2, i64 0, i64 0
%8 = call i32 @execve(i8* %6, i8** %7, i32* null)
ret void
}

LLVM IR (-O2):
@.str = [8 x i8] c"/bin/sh\00"
define void @get_shell_seg() {
%1 = alloca [2 x i8*]
%2 = bitcast [2 x i8*]* %1 to i8*
%3 = getelementptr inbounds [2 x i8*], [2 x i8*]* %1, i64 0, i64 0
store i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i8** %3
%4 = getelementptr inbounds [2 x i8*], [2 x i8*]* %1, i64 0, i64 1
store i8* null, i8** %4
%5 = call i32 @execve(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i8** %3, i32* null)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ fff();
int /*<<< orphan*/ printf(char *, int);
void ctest1(int *a) {
  fff();
  printf("ORIGINAL:\"a\" value is:%d\n", *a);
  *a = 666;
}


x86 assembly (clang, -O0):
<ctest1>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    $0x0,%al
call   1040 <fff@plt>
mov    -0x8(%rbp),%rax
mov    (%rax),%esi
lea    0xec0(%rip),%rdi
call   1030 <printf@plt>
mov    -0x8(%rbp),%rax
movl   $0x29a,(%rax)
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ctest1>:
push   %rbx
mov    %rdi,%rbx
xor    %eax,%eax
call   1040 <fff@plt>
mov    (%rbx),%esi
lea    0xecc(%rip),%rdi
call   1030 <printf@plt>
movl   $0x29a,(%rbx)
pop    %rbx
ret

LLVM IR (-O0):
@.str = [26 x i8] c"ORIGINAL:\22a\22 value is:%d\0A\00"
define void @ctest1(i32* %0) {
%2 = alloca i32*
store i32* %0, i32** %2
%3 = call i32 (...) @fff()
%4 = load i32*, i32** %2
%5 = load i32, i32* %4
%6 = call i32 @printf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str, i64 0, i64 0), i32 %5)
%7 = load i32*, i32** %2
store i32 666, i32* %7
ret void
}

LLVM IR (-O2):
@.str = [26 x i8] c"ORIGINAL:\22a\22 value is:%d\0A\00"
define void @ctest1(i32* nocapture %0) {
%2 = tail call i32 (...) @fff()
%3 = load i32, i32* %0
%4 = tail call i32 @printf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str, i64 0, i64 0), i32 %3)
store i32 666, i32* %0
ret void
}
int somefun(char *p, int n) { return 0; }


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

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

LLVM IR (-O0):
define i32 @somefun(i8* %0, i32 %1) {
%3 = alloca i8*
%4 = alloca i32
store i8* %0, i8** %3
store i32 %1, i32* %4
ret i32 0
}

LLVM IR (-O2):
define i32 @somefun(i8* nocapture readnone %0, i32 %1) {
ret i32 0
}
int is_valid_schooner_platform() { return 1; }


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

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

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

LLVM IR (-O2):
define i32 @is_valid_schooner_platform() {
ret i32 1
}
int mono_time_cleanup() { return 0; }


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

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

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

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

/* Variables and functions */
int /*<<< orphan*/ pthread_mutex_unlock(int /*<<< orphan*/ *);
void __worker_clean(void *arg) {
  pthread_mutex_t *mutex = (pthread_mutex_t *)arg;
  pthread_mutex_unlock(mutex);
}


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

x86 assembly (clang, -O2):
<__worker_clean>:
jmp    1030 <pthread_mutex_unlock@plt>

LLVM IR (-O0):
define void @__worker_clean(i8* %0) {
%2 = alloca i8*
%3 = alloca i32*
store i8* %0, i8** %2
%4 = load i8*, i8** %2
%5 = bitcast i8* %4 to i32*
store i32* %5, i32** %3
%6 = load i32*, i32** %3
%7 = call i32 @pthread_mutex_unlock(i32* %6)
ret void
}

LLVM IR (-O2):
define void @__worker_clean(i8* %0) {
%2 = bitcast i8* %0 to i32*
%3 = tail call i32 @pthread_mutex_unlock(i32* %2)
ret void
}
int test_imm_D8int64_highword_reg(long long val) {
  return ((val >> 32) & (0xD8 << 0)) ? -20 : -40;
}


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

x86 assembly (clang, -O2):
<test_imm_D8int64_highword_reg>:
movabs $0xd800000000,%rax
test   %rax,%rdi
mov    $0xffffffd8,%ecx
mov    $0xffffffec,%eax
cmove  %ecx,%eax
ret

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

LLVM IR (-O2):
define i32 @test_imm_D8int64_highword_reg(i64 %0) {
%2 = and i64 %0, 927712935936
%3 = icmp eq i64 %2, 0
%4 = select i1 %3, i32 -40, i32 -20
ret i32 %4
}