xunge/DecIR huggingface dataset:
/* Variables and functions */
int /*<<< orphan*/ printf(char *, unsigned long);
void main(void) {
  unsigned long i;
  for (i = 1; i <= 300000000; i++) {
    if (0 == i % 100000000) {
      printf("%ld", i);
    }
  }
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movq   $0x1,-0x8(%rbp)
cmpq   $0x11e1a300,-0x8(%rbp)
11
ja     116d <main+0x5d>
mov    -0x8(%rbp),%rax
mov    $0x5f5e100,%ecx
xor    %edx,%edx
div    %rcx
xor    %eax,%eax
cmp    %rdx,%rax
jne    1157 <main+0x47>
mov    -0x8(%rbp),%rsi
lea    0xeae(%rip),%rdi
call   1030 <printf@plt>
jmp    115c <main+0x4c>
mov    -0x8(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x8(%rbp)
jmp    1120 <main+0x10>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r14
push   %rbx
push   %rax
mov    $0x1,%ebx
lea    0xee0(%rip),%r14
jmp    113d <main+0x2d>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
add    $0x1,%rbx
cmp    $0x11e1a301,%rbx
je     1161 <main+0x51>
mov    %ebx,%eax
imul   $0x55e63b89,%rax,%rax
shr    $0x39,%rax
imul   $0xfa0a1f00,%eax,%eax
add    %ebx,%eax
jne    1130 <main+0x20>
mov    %r14,%rdi
mov    %rbx,%rsi
call   1030 <printf@plt>
jmp    1130 <main+0x20>
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
@.str = [4 x i8] c"%ld\00"
define void @main() {
%1 = alloca i64
store i64 1, i64* %1
br label %2
2: ; preds = %13, %0
%3 = load i64, i64* %1
%4 = icmp ule i64 %3, 300000000
br i1 %4, label %5, label %16
5: ; preds = %2
%6 = load i64, i64* %1
%7 = urem i64 %6, 100000000
%8 = icmp eq i64 0, %7
br i1 %8, label %9, label %12
9: ; preds = %5
%10 = load i64, i64* %1
%11 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i64 %10)
br label %12
12: ; preds = %9, %5
br label %13
13: ; preds = %12
%14 = load i64, i64* %1
%15 = add i64 %14, 1
store i64 %15, i64* %1
br label %2
16: ; preds = %2
ret void
}

LLVM IR (-O2):
@.str = [4 x i8] c"%ld\00"
define void @main() {
br label %1
1: ; preds = %0, %8
%2 = phi i64 [ 1, %0 ], [ %9, %8 ]
%3 = trunc i64 %2 to i32
%4 = urem i32 %3, 100000000
%5 = icmp eq i32 %4, 0
br i1 %5, label %6, label %8
6: ; preds = %1
%7 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i64 %2)
br label %8
8: ; preds = %1, %6
%9 = add nuw nsw i64 %2, 1
%10 = icmp eq i64 %9, 300000001
br i1 %10, label %11, label %1
11: ; preds = %8
ret void
}
/* Type definitions */
struct vec3 {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ vec3_bezier4(float *, float *, float *, float *, float *,
                                float);
__attribute__((always_)) struct vec3 *
psvec3_bezier4(struct vec3 *result, struct vec3 *a, struct vec3 *b,
               struct vec3 *c, struct vec3 *d, float p) {
  vec3_bezier4((float *)result, (float *)a, (float *)b, (float *)c, (float *)d,
               p);
  return result;
}


x86 assembly (clang, -O0):
<psvec3_bezier4>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
movss  %xmm0,-0x2c(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
mov    -0x18(%rbp),%rdx
mov    -0x20(%rbp),%rcx
mov    -0x28(%rbp),%r8
movss  -0x2c(%rbp),%xmm0
call   1030 <vec3_bezier4@plt>
mov    -0x8(%rbp),%rax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<psvec3_bezier4>:
push   %rbx
mov    %rdi,%rbx
call   1030 <vec3_bezier4@plt>
mov    %rbx,%rax
pop    %rbx
ret

LLVM IR (-O0):
%struct.vec3 = type { i32 }
define %struct.vec3* @psvec3_bezier4(%struct.vec3* %0, %struct.vec3* %1, %struct.vec3* %2, %struct.vec3* %3, %struct.vec3* %4, float %5) {
%7 = alloca %struct.vec3*
%8 = alloca %struct.vec3*
%9 = alloca %struct.vec3*
%10 = alloca %struct.vec3*
%11 = alloca %struct.vec3*
%12 = alloca float
store %struct.vec3* %0, %struct.vec3** %7
store %struct.vec3* %1, %struct.vec3** %8
store %struct.vec3* %2, %struct.vec3** %9
store %struct.vec3* %3, %struct.vec3** %10
store %struct.vec3* %4, %struct.vec3** %11
store float %5, float* %12
%13 = load %struct.vec3*, %struct.vec3** %7
%14 = bitcast %struct.vec3* %13 to float*
%15 = load %struct.vec3*, %struct.vec3** %8
%16 = bitcast %struct.vec3* %15 to float*
%17 = load %struct.vec3*, %struct.vec3** %9
%18 = bitcast %struct.vec3* %17 to float*
%19 = load %struct.vec3*, %struct.vec3** %10
%20 = bitcast %struct.vec3* %19 to float*
%21 = load %struct.vec3*, %struct.vec3** %11
%22 = bitcast %struct.vec3* %21 to float*
%23 = load float, float* %12
%24 = call i32 @vec3_bezier4(float* %14, float* %16, float* %18, float* %20, float* %22, float %23)
%25 = load %struct.vec3*, %struct.vec3** %7
ret %struct.vec3* %25
}

LLVM IR (-O2):
%struct.vec3 = type { i32 }
define %struct.vec3* @psvec3_bezier4(%struct.vec3* returned %0, %struct.vec3* %1, %struct.vec3* %2, %struct.vec3* %3, %struct.vec3* %4, float %5) {
%7 = bitcast %struct.vec3* %0 to float*
%8 = bitcast %struct.vec3* %1 to float*
%9 = bitcast %struct.vec3* %2 to float*
%10 = bitcast %struct.vec3* %3 to float*
%11 = bitcast %struct.vec3* %4 to float*
%12 = tail call i32 @vec3_bezier4(float* %7, float* %8, float* %9, float* %10, float* %11, float %5)
ret %struct.vec3* %0
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ isbdigit(int);
void t_isbdigit_0xba() {
  Assert_real((isbdigit(186) == 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_isbdigit.c",
              935, ("isbdigit should be 0 for 0xba"));
}


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

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

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

LLVM IR (-O2):
@.str = [169 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_isbdigit.c\00"
@.str.1 = [30 x i8] c"isbdigit should be 0 for 0xba\00"
define void @t_isbdigit_0xba() {
%1 = tail call i64 @isbdigit(i32 186)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = tail call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([169 x i8], [169 x i8]* @.str, i64 0, i64 0), i32 935, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ doexit(int);
int fork();
int /*<<< orphan*/ loop();
int /*<<< orphan*/ sandbox_common();
int do_sandbox_none(int executor_pid, bool enable_tun) {
  int pid = fork();
  if (pid)
    return pid;
  sandbox_common();
  loop();
  doexit(1);
}


x86 assembly (clang, -O0):
<do_sandbox_none>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    $0x0,%al
call   1060 <fork@plt>
mov    %eax,-0x10(%rbp)
cmpl   $0x0,-0x10(%rbp)
je     116d <do_sandbox_none+0x2d>
mov    -0x10(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    1185 <do_sandbox_none+0x45>
mov    $0x0,%al
call   1050 <sandbox_common@plt>
mov    $0x0,%al
call   1030 <loop@plt>
mov    $0x1,%edi
call   1040 <doexit@plt>
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<do_sandbox_none>:
push   %rbx
xor    %eax,%eax
call   1060 <fork@plt>
mov    %eax,%ebx
test   %eax,%eax
jne    1166 <do_sandbox_none+0x26>
xor    %eax,%eax
call   1050 <sandbox_common@plt>
xor    %eax,%eax
call   1030 <loop@plt>
mov    $0x1,%edi
call   1040 <doexit@plt>
mov    %ebx,%eax
pop    %rbx
ret

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

LLVM IR (-O2):
define i32 @do_sandbox_none(i32 %0, i32 %1) {
%3 = tail call i32 (...) @fork()
%4 = icmp eq i32 %3, 0
br i1 %4, label %5, label %9
5: ; preds = %2
%6 = tail call i32 (...) @sandbox_common()
%7 = tail call i32 (...) @loop()
%8 = tail call i32 @doexit(i32 1)
br label %9
9: ; preds = %2, %5
ret i32 %3
}
/* Variables and functions */
unsigned int __bextr_u32(unsigned int, unsigned int);
unsigned int test__bextr_u32(unsigned int __X, unsigned int __Y) {
  return __bextr_u32(__X, __Y);
}


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

x86 assembly (clang, -O2):
<test__bextr_u32>:
jmp    1030 <__bextr_u32@plt>

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

LLVM IR (-O2):
define i32 @test__bextr_u32(i32 %0, i32 %1) {
%3 = tail call i32 @__bextr_u32(i32 %0, i32 %1)
ret i32 %3
}
/* Variables and functions */
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int main(int argc, char *argv[]) {
  int i;
  char *p;
  exit(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)
xor    %edi,%edi
call   1030 <exit@plt>

x86 assembly (clang, -O2):
<main>:
push   %rax
xor    %edi,%edi
call   1030 <exit@plt>

LLVM IR (-O0):
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
%7 = alloca i8*
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%8 = call i32 @exit(i32 0)
unreachable
}

LLVM IR (-O2):
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @exit(i32 0)
unreachable
}
int raise(sig)
int sig;
{ return pthread_kill(pthread_self(), sig); }


x86 assembly (clang, -O0):
<raise>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    $0x0,%al
call   1040 <pthread_self@plt>
mov    %eax,%edi
mov    -0x4(%rbp),%esi
mov    $0x0,%al
call   1030 <pthread_kill@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<raise>:
push   %rbx
mov    %edi,%ebx
xor    %eax,%eax
call   1040 <pthread_self@plt>
mov    %eax,%edi
mov    %ebx,%esi
xor    %eax,%eax
pop    %rbx
jmp    1030 <pthread_kill@plt>

LLVM IR (-O0):
define i32 @raise(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = call i32 (...) @pthread_self()
%4 = load i32, i32* %2
%5 = call i32 (i32, i32, ...) bitcast (i32 (...)* @pthread_kill to i32 (i32, i32, ...)*)(i32 %3, i32 %4)
ret i32 %5
}

LLVM IR (-O2):
define i32 @raise(i32 %0) {
%2 = tail call i32 (...) @pthread_self()
%3 = tail call i32 (i32, i32, ...) bitcast (i32 (...)* @pthread_kill to i32 (i32, i32, ...)*)(i32 %2, i32 %0)
ret i32 %3
}
/* Variables and functions */
int /*<<< orphan*/ output_line(char *);
data_segment_gdata() { output_line(".data"); }


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

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

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

LLVM IR (-O2):
@.str = [6 x i8] c".data\00"
define i32 @data_segment_gdata() {
%1 = tail call i32 @output_line(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
ret i32 undef
}
void gtk_check_button_get_type() {}


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

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

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

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


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

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

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

LLVM IR (-O2):
define void @UYVYToARGB() {
ret void
}
/* Variables and functions */
int MSBitPos(unsigned long);
unsigned long MSBit(unsigned long x) { return 1 << MSBitPos(x); }


x86 assembly (clang, -O0):
<MSBit>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <MSBitPos@plt>
mov    %eax,%ecx
mov    $0x1,%eax
shl    %cl,%eax
cltq
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<MSBit>:
push   %rax
call   1030 <MSBitPos@plt>
mov    $0x1,%edx
mov    %eax,%ecx
shl    %cl,%edx
movslq %edx,%rax
pop    %rcx
ret

LLVM IR (-O0):
define i64 @MSBit(i64 %0) {
%2 = alloca i64
store i64 %0, i64* %2
%3 = load i64, i64* %2
%4 = call i32 @MSBitPos(i64 %3)
%5 = shl i32 1, %4
%6 = sext i32 %5 to i64
ret i64 %6
}

LLVM IR (-O2):
define i64 @MSBit(i64 %0) {
%2 = tail call i32 @MSBitPos(i64 %0)
%3 = shl nuw i32 1, %2
%4 = sext i32 %3 to i64
ret i64 %4
}
/* Variables and functions */
int /*<<< orphan*/ foo(int);
int main() {
  foo(9);
  return 0;
}


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

x86 assembly (clang, -O2):
<main>:
push   %rax
mov    $0x9,%edi
call   1030 <foo@plt>
xor    %eax,%eax
pop    %rcx
ret

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

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 @foo(i32 9)
ret i32 0
}
void io_outb(unsigned short port, unsigned char byte) {
  __asm__("mov %1, %%al\n\t"
          "mov %0, %%dx\n\t"
          "out %%al, %%dx\n"
          :
          : "r"(port), "r"(byte)
          : "%al", "%dx");
}


x86 assembly (clang, -O0):
<io_outb>:
push   %rbp
mov    %rsp,%rbp
mov    %sil,%al
mov    %di,%cx
mov    %cx,-0x2(%rbp)
mov    %al,-0x3(%rbp)
mov    -0x2(%rbp),%cx
mov    -0x3(%rbp),%sil
mov    %sil,%al
mov    %cx,%dx
out    %al,(%dx)
pop    %rbp
ret

x86 assembly (clang, -O2):
<io_outb>:
mov    %sil,%al
mov    %di,%dx
out    %al,(%dx)
ret

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

LLVM IR (-O2):
define void @io_outb(i16 zeroext %0, i8 zeroext %1) {
tail call void asm sideeffect "mov $1, %al\0A\09mov $0, %dx\0A\09out %al, %dx\0A", "r,r,~{al},~{dx},~{dirflag},~{fpsr},~{flags}"(i16 %0, i8 %1)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ move_eol();
void cmd_eol(const char *pf, char **args) { move_eol(); }


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

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

LLVM IR (-O0):
define void @cmd_eol(i8* %0, i8** %1) {
%3 = alloca i8*
%4 = alloca i8**
store i8* %0, i8** %3
store i8** %1, i8*** %4
%5 = call i32 (...) @move_eol()
ret void
}

LLVM IR (-O2):
define void @cmd_eol(i8* nocapture readnone %0, i8** nocapture readnone %1) {
%3 = tail call i32 (...) @move_eol()
ret void
}
/* Variables and functions */
scalar_t__ ft_strcmp(char const *, char const *);
int ft_strequ(char const *s1, char const *s2) {
  if (!s1 || !s2) {
    if (s1 == s2)
      return (1);
    else
      return (0);
  }
  if (ft_strcmp(s1, s2))
    return (0);
  return (1);
}


x86 assembly (clang, -O0):
<ft_strequ>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
cmpq   $0x0,-0x10(%rbp)
je     1136 <ft_strequ+0x26>
cmpq   $0x0,-0x18(%rbp)
jne    115c <ft_strequ+0x4c>
mov    -0x10(%rbp),%rax
cmp    -0x18(%rbp),%rax
jne    1150 <ft_strequ+0x40>
movl   $0x1,-0x4(%rbp)
jmp    1186 <ft_strequ+0x76>
movl   $0x0,-0x4(%rbp)
jmp    1186 <ft_strequ+0x76>
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
call   1030 <ft_strcmp@plt>
cmp    $0x0,%rax
je     117f <ft_strequ+0x6f>
movl   $0x0,-0x4(%rbp)
jmp    1186 <ft_strequ+0x76>
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ft_strequ>:
test   %rdi,%rdi
je     112e <ft_strequ+0x1e>
test   %rsi,%rsi
je     112e <ft_strequ+0x1e>
push   %rax
call   1030 <ft_strcmp@plt>
test   %rax,%rax
sete   %al
add    $0x8,%rsp
movzbl %al,%eax
ret
cmp    %rsi,%rdi
sete   %al
movzbl %al,%eax
ret

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

LLVM IR (-O2):
define i32 @ft_strequ(i8* %0, i8* %1) {
%3 = icmp ne i8* %0, null
%4 = icmp ne i8* %1, null
%5 = and i1 %3, %4
br i1 %5, label %8, label %6
6: ; preds = %2
%7 = icmp eq i8* %0, %1
br label %11
8: ; preds = %2
%9 = tail call i64 @ft_strcmp(i8* %0, i8* %1)
%10 = icmp eq i64 %9, 0
br label %11
11: ; preds = %8, %6
%12 = phi i1 [ %7, %6 ], [ %10, %8 ]
%13 = zext i1 %12 to i32
ret i32 %13
}
void *_Locale_collate_create(const char *__DUMMY_PAR) { return 0; }


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

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

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

LLVM IR (-O2):
define noalias i8* @_Locale_collate_create(i8* nocapture readnone %0) {
ret i8* null
}
int mal_rx_size(int len) {
  len = (len + 0xf) & ~0xf;
  return len > 4080 ? 4080 : len;
}


x86 assembly (clang, -O0):
<mal_rx_size>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0xf,%eax
and    $0xfffffff0,%eax
mov    %eax,-0x4(%rbp)
cmpl   $0xff0,-0x4(%rbp)
jle    112d <mal_rx_size+0x2d>
mov    $0xff0,%eax
mov    %eax,-0x8(%rbp)
jmp    1133 <mal_rx_size+0x33>
mov    -0x4(%rbp),%eax
mov    %eax,-0x8(%rbp)
mov    -0x8(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<mal_rx_size>:
lea    0xf(%rdi),%ecx
and    $0xfffffff0,%ecx
cmp    $0xff0,%ecx
mov    $0xff0,%eax
cmovl  %ecx,%eax
ret

LLVM IR (-O0):
define i32 @mal_rx_size(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = add nsw i32 %3, 15
%5 = and i32 %4, -16
store i32 %5, i32* %2
%6 = load i32, i32* %2
%7 = icmp sgt i32 %6, 4080
br i1 %7, label %8, label %9
8: ; preds = %1
br label %11
9: ; preds = %1
%10 = load i32, i32* %2
br label %11
11: ; preds = %9, %8
%12 = phi i32 [ 4080, %8 ], [ %10, %9 ]
ret i32 %12
}

LLVM IR (-O2):
define i32 @mal_rx_size(i32 %0) {
%2 = add nsw i32 %0, 15
%3 = and i32 %2, -16
%4 = icmp slt i32 %3, 4080
%5 = select i1 %4, i32 %3, i32 4080
ret i32 %5
}
/* Type definitions */
struct termios {
  int c_lflag;
};

/* Variables and functions */
int ECHO;
int ICANON;
int /*<<< orphan*/ TCSANOW;
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ tcgetattr(int /*<<< orphan*/, struct termios *);
int /*<<< orphan*/ tcsetattr(int /*<<< orphan*/, int /*<<< orphan*/,
                             struct termios *);
void xexit(int rc) {
  struct termios sttybuf;
  tcgetattr(0, &sttybuf);
  sttybuf.c_lflag |= ECHO | ICANON;
  tcsetattr(0, TCSANOW, &sttybuf);
  exit(rc);
}


x86 assembly (clang, -O0):
<xexit>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
xor    %edi,%edi
lea    -0x8(%rbp),%rsi
call   1030 <tcgetattr@plt>
mov    0x2e93(%rip),%rax
mov    (%rax),%eax
mov    0x2e7a(%rip),%rcx
or     (%rcx),%eax
or     -0x8(%rbp),%eax
mov    %eax,-0x8(%rbp)
mov    0x2e83(%rip),%rax
mov    (%rax),%esi
xor    %edi,%edi
lea    -0x8(%rbp),%rdx
call   1040 <tcsetattr@plt>
mov    -0x4(%rbp),%edi
call   1050 <exit@plt>

x86 assembly (clang, -O2):
<xexit>:
push   %r14
push   %rbx
push   %rax
mov    %edi,%ebx
mov    %rsp,%r14
xor    %edi,%edi
mov    %r14,%rsi
call   1030 <tcgetattr@plt>
mov    0x2e96(%rip),%rax
mov    0x2e7f(%rip),%rcx
mov    (%rcx),%ecx
or     (%rax),%ecx
or     %ecx,(%rsp)
mov    0x2e89(%rip),%rax
mov    (%rax),%esi
xor    %edi,%edi
mov    %r14,%rdx
call   1040 <tcsetattr@plt>
mov    %ebx,%edi
call   1050 <exit@plt>

LLVM IR (-O0):
%struct.termios = type { i32 }
@ECHO = global i32 0
@ICANON = global i32 0
@TCSANOW = global i32 0
define void @xexit(i32 %0) {
%2 = alloca i32
%3 = alloca %struct.termios
store i32 %0, i32* %2
%4 = call i32 @tcgetattr(i32 0, %struct.termios* %3)
%5 = load i32, i32* @ECHO
%6 = load i32, i32* @ICANON
%7 = or i32 %5, %6
%8 = getelementptr inbounds %struct.termios, %struct.termios* %3, i32 0, i32 0
%9 = load i32, i32* %8
%10 = or i32 %9, %7
store i32 %10, i32* %8
%11 = load i32, i32* @TCSANOW
%12 = call i32 @tcsetattr(i32 0, i32 %11, %struct.termios* %3)
%13 = load i32, i32* %2
%14 = call i32 @exit(i32 %13)
unreachable
}

LLVM IR (-O2):
%struct.termios = type { i32 }
@ECHO = global i32 0
@ICANON = global i32 0
@TCSANOW = global i32 0
define void @xexit(i32 %0) {
%2 = alloca %struct.termios
%3 = bitcast %struct.termios* %2 to i8*
%4 = call i32 @tcgetattr(i32 0, %struct.termios* %2)
%5 = load i32, i32* @ECHO
%6 = load i32, i32* @ICANON
%7 = or i32 %6, %5
%8 = getelementptr inbounds %struct.termios, %struct.termios* %2, i64 0, i32 0
%9 = load i32, i32* %8
%10 = or i32 %7, %9
store i32 %10, i32* %8
%11 = load i32, i32* @TCSANOW
%12 = call i32 @tcsetattr(i32 0, i32 %11, %struct.termios* %2)
%13 = call i32 @exit(i32 %0)
unreachable
}
/* Variables and functions */
int /*<<< orphan*/ clang_analyzer_eval(int);
void mixedSignedness7(unsigned a) {
  unsigned min = 0;
  clang_analyzer_eval(a < min);
  clang_analyzer_eval((a + 2) < min);
  clang_analyzer_eval((a + 2U) < min);
}


x86 assembly (clang, -O0):
<mixedSignedness7>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
mov    -0x4(%rbp),%eax
cmp    -0x8(%rbp),%eax
setb   %al
and    $0x1,%al
movzbl %al,%edi
call   1030 <clang_analyzer_eval@plt>
mov    -0x4(%rbp),%eax
add    $0x2,%eax
cmp    -0x8(%rbp),%eax
setb   %al
and    $0x1,%al
movzbl %al,%edi
call   1030 <clang_analyzer_eval@plt>
mov    -0x4(%rbp),%eax
add    $0x2,%eax
cmp    -0x8(%rbp),%eax
setb   %al
and    $0x1,%al
movzbl %al,%edi
call   1030 <clang_analyzer_eval@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<mixedSignedness7>:
push   %rax
xor    %edi,%edi
call   1030 <clang_analyzer_eval@plt>
xor    %edi,%edi
call   1030 <clang_analyzer_eval@plt>
xor    %edi,%edi
pop    %rax
jmp    1030 <clang_analyzer_eval@plt>

LLVM IR (-O0):
define void @mixedSignedness7(i32 %0) {
%2 = alloca i32
%3 = alloca i32
store i32 %0, i32* %2
store i32 0, i32* %3
%4 = load i32, i32* %2
%5 = load i32, i32* %3
%6 = icmp ult i32 %4, %5
%7 = zext i1 %6 to i32
%8 = call i32 @clang_analyzer_eval(i32 %7)
%9 = load i32, i32* %2
%10 = add i32 %9, 2
%11 = load i32, i32* %3
%12 = icmp ult i32 %10, %11
%13 = zext i1 %12 to i32
%14 = call i32 @clang_analyzer_eval(i32 %13)
%15 = load i32, i32* %2
%16 = add i32 %15, 2
%17 = load i32, i32* %3
%18 = icmp ult i32 %16, %17
%19 = zext i1 %18 to i32
%20 = call i32 @clang_analyzer_eval(i32 %19)
ret void
}

LLVM IR (-O2):
define void @mixedSignedness7(i32 %0) {
%2 = tail call i32 @clang_analyzer_eval(i32 0)
%3 = tail call i32 @clang_analyzer_eval(i32 0)
%4 = tail call i32 @clang_analyzer_eval(i32 0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ __sys_exit(int);
void _exit(int status) {
  __sys_exit(status);
  while (1) {
  };
}


x86 assembly (clang, -O0):
<_exit>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%edi
call   1030 <__sys_exit@plt>
jmp    1123 <_exit+0x13>

x86 assembly (clang, -O2):
<_exit>:
push   %rax
call   1030 <__sys_exit@plt>
cs nopw 0x0(%rax,%rax,1)
jmp    1120 <_exit+0x10>

LLVM IR (-O0):
define void @_exit(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = call i32 @__sys_exit(i32 %3)
br label %5
5: ; preds = %1, %5
br label %5
}

LLVM IR (-O2):
define void @_exit(i32 %0) {
%2 = tail call i32 @__sys_exit(i32 %0)
br label %3
3: ; preds = %1, %3
br label %3
}
char *strrchr(s, c)
register char *s, c;
{
  register char *result;
  result = 0;
  do
    if (*s == c)
      result = s;
  while (*s++ != 0);
  return (result);
}


x86 assembly (clang, -O0):
<strrchr>:
push   %rbp
mov    %rsp,%rbp
mov    %sil,%al
mov    %rdi,-0x8(%rbp)
mov    %al,-0x9(%rbp)
movq   $0x0,-0x18(%rbp)
mov    -0x8(%rbp),%rax
movsbl (%rax),%eax
movsbl -0x9(%rbp),%ecx
cmp    %ecx,%eax
jne    1131 <strrchr+0x31>
mov    -0x8(%rbp),%rax
mov    %rax,-0x18(%rbp)
jmp    1136 <strrchr+0x36>
mov    -0x8(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x8(%rbp)
movsbl (%rax),%eax
cmp    $0x0,%eax
jne    1116 <strrchr+0x16>
mov    -0x18(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<strrchr>:
xor    %eax,%eax
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
movzbl (%rdi),%ecx
cmp    %sil,%cl
cmove  %rdi,%rax
add    $0x1,%rdi
test   %cl,%cl
jne    1110 <strrchr+0x10>
ret

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

LLVM IR (-O2):
define i8* @strrchr(i8* %0, i8 signext %1) {
br label %3
3: ; preds = %3, %2
%4 = phi i8* [ %0, %2 ], [ %9, %3 ]
%5 = phi i8* [ null, %2 ], [ %8, %3 ]
%6 = load i8, i8* %4
%7 = icmp eq i8 %6, %1
%8 = select i1 %7, i8* %4, i8* %5
%9 = getelementptr inbounds i8, i8* %4, i64 1
%10 = icmp eq i8 %6, 0
br i1 %10, label %11, label %3
11: ; preds = %3
ret i8* %8
}
long long bit60() { return 0x1000000000000000LL; }


x86 assembly (clang, -O0):
<bit60>:
push   %rbp
mov    %rsp,%rbp
movabs $0x1000000000000000,%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<bit60>:
movabs $0x1000000000000000,%rax
ret

LLVM IR (-O0):
define i64 @bit60() {
ret i64 1152921504606846976
}

LLVM IR (-O2):
define i64 @bit60() {
ret i64 1152921504606846976
}
int mcount(void) { return (0); }


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

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

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

LLVM IR (-O2):
define i32 @mcount() {
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ check(float *, float *, int);
int /*<<< orphan*/ free(float *);
scalar_t__ malloc(int);
int /*<<< orphan*/ vec_mult(float *, int);
int /*<<< orphan*/ vec_mult_ref(float *, int);
int main() {
  float *p1 = (float *)malloc(10000 * sizeof(float));
  float *p2 = (float *)malloc(10000 * sizeof(float));
  vec_mult_ref(p1, 10000);
  vec_mult(p2, 10000);
  check(p1, p2, 10000);
  free(p1);
  free(p2);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0x9c40,%edi
call   1040 <malloc@plt>
mov    %rax,-0x10(%rbp)
mov    $0x9c40,%edi
call   1040 <malloc@plt>
mov    %rax,-0x18(%rbp)
mov    -0x10(%rbp),%rdi
mov    $0x2710,%esi
call   1050 <vec_mult_ref@plt>
mov    -0x18(%rbp),%rdi
mov    $0x2710,%esi
call   1070 <vec_mult@plt>
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
mov    $0x2710,%edx
call   1060 <check@plt>
mov    -0x10(%rbp),%rdi
call   1030 <free@plt>
mov    -0x18(%rbp),%rdi
call   1030 <free@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r14
push   %rbx
push   %rax
mov    $0x9c40,%edi
call   1040 <malloc@plt>
mov    %rax,%r14
mov    $0x9c40,%edi
call   1040 <malloc@plt>
mov    %rax,%rbx
mov    %r14,%rdi
mov    $0x2710,%esi
call   1050 <vec_mult_ref@plt>
mov    %rbx,%rdi
mov    $0x2710,%esi
call   1070 <vec_mult@plt>
mov    %r14,%rdi
mov    %rbx,%rsi
mov    $0x2710,%edx
call   1060 <check@plt>
mov    %r14,%rdi
call   1030 <free@plt>
mov    %rbx,%rdi
call   1030 <free@plt>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca float*
%3 = alloca float*
store i32 0, i32* %1
%4 = call i64 @malloc(i32 40000)
%5 = inttoptr i64 %4 to float*
store float* %5, float** %2
%6 = call i64 @malloc(i32 40000)
%7 = inttoptr i64 %6 to float*
store float* %7, float** %3
%8 = load float*, float** %2
%9 = call i32 @vec_mult_ref(float* %8, i32 10000)
%10 = load float*, float** %3
%11 = call i32 @vec_mult(float* %10, i32 10000)
%12 = load float*, float** %2
%13 = load float*, float** %3
%14 = call i32 @check(float* %12, float* %13, i32 10000)
%15 = load float*, float** %2
%16 = call i32 @free(float* %15)
%17 = load float*, float** %3
%18 = call i32 @free(float* %17)
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i64 @malloc(i32 40000)
%2 = inttoptr i64 %1 to float*
%3 = tail call i64 @malloc(i32 40000)
%4 = inttoptr i64 %3 to float*
%5 = tail call i32 @vec_mult_ref(float* %2, i32 10000)
%6 = tail call i32 @vec_mult(float* %4, i32 10000)
%7 = tail call i32 @check(float* %2, float* %4, i32 10000)
%8 = tail call i32 @free(float* %2)
%9 = tail call i32 @free(float* %4)
ret i32 0
}
/* Type definitions */
typedef int /*<<< orphan*/ Display;

/* Variables and functions */
int /*<<< orphan*/ None;
int /*<<< orphan*/ RootWindow(int /*<<< orphan*/ *, int /*<<< orphan*/);
int /*<<< orphan*/ XWarpPointer(int /*<<< orphan*/ *, int /*<<< orphan*/,
                                int /*<<< orphan*/, int /*<<< orphan*/,
                                int /*<<< orphan*/, int /*<<< orphan*/,
                                int /*<<< orphan*/, int, int);
void mouseMove(Display *display, int x, int y) {
  XWarpPointer(display, None, RootWindow(display, 0), 0, 0, 0, 0, x, y);
}


x86 assembly (clang, -O0):
<mouseMove>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %edx,-0x10(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x20(%rbp)
mov    0x2ea7(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x14(%rbp)
mov    -0x8(%rbp),%rdi
xor    %esi,%esi
call   1040 <RootWindow@plt>
mov    -0x20(%rbp),%rdi
mov    -0x14(%rbp),%esi
mov    %eax,%edx
mov    -0xc(%rbp),%r10d
mov    -0x10(%rbp),%eax
xor    %r9d,%r9d
mov    %r9d,%ecx
mov    %r9d,%r8d
movl   $0x0,(%rsp)
mov    %r10d,0x8(%rsp)
mov    %eax,0x10(%rsp)
call   1030 <XWarpPointer@plt>
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<mouseMove>:
push   %rbp
push   %r15
push   %r14
push   %rbx
push   %rax
mov    %edx,%r15d
mov    %esi,%r14d
mov    %rdi,%rbx
mov    0x2eb1(%rip),%rax
mov    (%rax),%ebp
xor    %esi,%esi
call   1040 <RootWindow@plt>
sub    $0x8,%rsp
mov    %rbx,%rdi
mov    %ebp,%esi
mov    %eax,%edx
xor    %ecx,%ecx
xor    %r8d,%r8d
xor    %r9d,%r9d
push   %r15
push   %r14
push   $0x0
call   1030 <XWarpPointer@plt>
add    $0x28,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@None = global i32 0
define void @mouseMove(i32* %0, i32 %1, i32 %2) {
%4 = alloca i32*
%5 = alloca i32
%6 = alloca i32
store i32* %0, i32** %4
store i32 %1, i32* %5
store i32 %2, i32* %6
%7 = load i32*, i32** %4
%8 = load i32, i32* @None
%9 = load i32*, i32** %4
%10 = call i32 @RootWindow(i32* %9, i32 0)
%11 = load i32, i32* %5
%12 = load i32, i32* %6
%13 = call i32 @XWarpPointer(i32* %7, i32 %8, i32 %10, i32 0, i32 0, i32 0, i32 0, i32 %11, i32 %12)
ret void
}

LLVM IR (-O2):
@None = global i32 0
define void @mouseMove(i32* %0, i32 %1, i32 %2) {
%4 = load i32, i32* @None
%5 = tail call i32 @RootWindow(i32* %0, i32 0)
%6 = tail call i32 @XWarpPointer(i32* %0, i32 %4, i32 %5, i32 0, i32 0, i32 0, i32 0, i32 %1, i32 %2)
ret void
}
int check() {}


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

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

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

LLVM IR (-O2):
define i32 @check() {
ret i32 undef
}
void opal_atomic_wmb(void) { (*((void (*)(void))(0xffff0fa0)))(); }


x86 assembly (clang, -O0):
<opal_atomic_wmb>:
push   %rbp
mov    %rsp,%rbp
mov    $0xffff0fa0,%eax
call   *%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<opal_atomic_wmb>:
mov    $0xffff0fa0,%eax
jmp    *%rax

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

LLVM IR (-O2):
define void @opal_atomic_wmb() {
tail call void inttoptr (i64 4294905760 to void ()*)()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ putchar(char);
void __attribute__((destructor)) fini(void) { putchar('1'); }


x86 assembly (clang, -O0):
<fini>:
push   %rbp
mov    %rsp,%rbp
mov    $0x31,%edi
call   1030 <putchar@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<fini>:
mov    $0x31,%edi
jmp    1030 <putchar@plt>

LLVM IR (-O0):
@llvm.global_dtors = appending global [1 x { i32, void ()*, i8* }] [{ i32, void ()*, i8* } { i32 65535, void ()* @fini, i8* null }]
define void @fini() {
%1 = call i32 @putchar(i8 signext 49)
ret void
}

LLVM IR (-O2):
@llvm.global_dtors = appending global [1 x { i32, void ()*, i8* }] [{ i32, void ()*, i8* } { i32 65535, void ()* @fini, i8* null }]
define void @fini() {
%1 = tail call i32 @putchar(i8 signext 49)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, ...);
void ShowData(int num[], int n) {
  while (n--)
    printf("%d  ", *num++);
  printf("\n");
}


x86 assembly (clang, -O0):
<ShowData>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,%ecx
add    $0xffffffff,%ecx
mov    %ecx,-0xc(%rbp)
cmp    $0x0,%eax
je     1157 <ShowData+0x47>
mov    -0x8(%rbp),%rax
mov    %rax,%rcx
add    $0x4,%rcx
mov    %rcx,-0x8(%rbp)
mov    (%rax),%esi
lea    0xeb5(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    111f <ShowData+0xf>
lea    0xea7(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ShowData>:
push   %r15
push   %r14
push   %r12
push   %rbx
push   %rax
test   %esi,%esi
je     1157 <ShowData+0x37>
mov    %rdi,%r15
mov    %esi,%r12d
lea    0xec7(%rip),%r14
xor    %ebx,%ebx
nopl   0x0(%rax,%rax,1)
mov    (%r15,%rbx,4),%esi
mov    %r14,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
add    $0x1,%rbx
cmp    %ebx,%r12d
jne    1140 <ShowData+0x20>
mov    $0xa,%edi
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
jmp    1030 <putchar@plt>

LLVM IR (-O0):
@.str = [5 x i8] c"%d \00"
@.str.1 = [2 x i8] c"\0A\00"
define void @ShowData(i32* %0, i32 %1) {
%3 = alloca i32*
%4 = alloca i32
store i32* %0, i32** %3
store i32 %1, i32* %4
br label %5
5: ; preds = %9, %2
%6 = load i32, i32* %4
%7 = add nsw i32 %6, -1
store i32 %7, i32* %4
%8 = icmp ne i32 %6, 0
br i1 %8, label %9, label %14
9: ; preds = %5
%10 = load i32*, i32** %3
%11 = getelementptr inbounds i32, i32* %10, i32 1
store i32* %11, i32** %3
%12 = load i32, i32* %10
%13 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32 %12)
br label %5
14: ; preds = %5
%15 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [5 x i8] c"%d \00"
define void @ShowData(i32* nocapture %0, i32 %1) {
%3 = icmp eq i32 %1, 0
br i1 %3, label %12, label %4
4: ; preds = %2, %4
%5 = phi i32 [ %7, %4 ], [ %1, %2 ]
%6 = phi i32* [ %8, %4 ], [ %0, %2 ]
%7 = add nsw i32 %5, -1
%8 = getelementptr inbounds i32, i32* %6, i64 1
%9 = load i32, i32* %6
%10 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32 %9)
%11 = icmp eq i32 %7, 0
br i1 %11, label %12, label %4
12: ; preds = %4, %2
%13 = tail call i32 @putchar(i32 10)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ getpagesize();
void *ps_memalign(int /*<<< orphan*/, size_t);
void *ps_valloc(size_t size) {
  void *ret = ps_memalign(getpagesize(), size);
  return ret;
}


x86 assembly (clang, -O0):
<ps_valloc>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    $0x0,%al
call   1030 <getpagesize@plt>
mov    %eax,%edi
mov    -0x8(%rbp),%rsi
call   1040 <ps_memalign@plt>
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ps_valloc>:
push   %rbx
mov    %rdi,%rbx
xor    %eax,%eax
call   1030 <getpagesize@plt>
mov    %eax,%edi
mov    %rbx,%rsi
pop    %rbx
jmp    1040 <ps_memalign@plt>

LLVM IR (-O0):
define i8* @ps_valloc(i64 %0) {
%2 = alloca i64
%3 = alloca i8*
store i64 %0, i64* %2
%4 = call i32 (...) @getpagesize()
%5 = load i64, i64* %2
%6 = call i8* @ps_memalign(i32 %4, i64 %5)
store i8* %6, i8** %3
%7 = load i8*, i8** %3
ret i8* %7
}

LLVM IR (-O2):
define i8* @ps_valloc(i64 %0) {
%2 = tail call i32 (...) @getpagesize()
%3 = tail call i8* @ps_memalign(i32 %2, i64 %0)
ret i8* %3
}
/* Variables and functions */
int rand();
int get_random(int min, int max) { return (rand() % (max - min)) + min; }


x86 assembly (clang, -O0):
<get_random>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    $0x0,%al
call   1030 <rand@plt>
mov    -0x8(%rbp),%ecx
sub    -0x4(%rbp),%ecx
cltd
idiv   %ecx
mov    %edx,%eax
add    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<get_random>:
push   %rbp
push   %rbx
push   %rax
mov    %esi,%ebx
mov    %edi,%ebp
xor    %eax,%eax
call   1030 <rand@plt>
sub    %ebp,%ebx
cltd
idiv   %ebx
add    %edx,%ebp
mov    %ebp,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
define i32 @get_random(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
store i32 %0, i32* %3
store i32 %1, i32* %4
%5 = call i32 (...) @rand()
%6 = load i32, i32* %4
%7 = load i32, i32* %3
%8 = sub nsw i32 %6, %7
%9 = srem i32 %5, %8
%10 = load i32, i32* %3
%11 = add nsw i32 %9, %10
ret i32 %11
}

LLVM IR (-O2):
define i32 @get_random(i32 %0, i32 %1) {
%3 = tail call i32 (...) @rand()
%4 = sub nsw i32 %1, %0
%5 = srem i32 %3, %4
%6 = add nsw i32 %5, %0
ret i32 %6
}
/* Variables and functions */
int getn(int, int);
int get3() { return getn(3, 1); }


x86 assembly (clang, -O0):
<get3>:
push   %rbp
mov    %rsp,%rbp
mov    $0x3,%edi
mov    $0x1,%esi
call   1030 <getn@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<get3>:
mov    $0x3,%edi
mov    $0x1,%esi
jmp    1030 <getn@plt>

LLVM IR (-O0):
define i32 @get3() {
%1 = call i32 @getn(i32 3, i32 1)
ret i32 %1
}

LLVM IR (-O2):
define i32 @get3() {
%1 = tail call i32 @getn(i32 3, i32 1)
ret i32 %1
}
/* Type definitions */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
int /*<<< orphan*/ SEEK_END;
int /*<<< orphan*/ SEEK_SET;
int /*<<< orphan*/ fseek(int /*<<< orphan*/ *, unsigned long,
                         int /*<<< orphan*/);
unsigned long ftell(int /*<<< orphan*/ *);
unsigned long FileSize(FILE *fd) {
  unsigned long curpos, length;
  curpos = ftell(fd);
  fseek(fd, 0, SEEK_END);
  length = ftell(fd);
  fseek(fd, curpos, SEEK_SET);
  return length;
}


x86 assembly (clang, -O0):
<FileSize>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <ftell@plt>
mov    %rax,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
mov    0x2ea4(%rip),%rax
mov    (%rax),%edx
xor    %eax,%eax
mov    %eax,%esi
call   1040 <fseek@plt>
mov    -0x8(%rbp),%rdi
call   1030 <ftell@plt>
mov    %rax,-0x18(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
mov    0x2e6d(%rip),%rax
mov    (%rax),%edx
call   1040 <fseek@plt>
mov    -0x18(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<FileSize>:
push   %r15
push   %r14
push   %rbx
mov    %rdi,%rbx
call   1030 <ftell@plt>
mov    %rax,%r14
mov    0x2eb1(%rip),%rax
mov    (%rax),%edx
mov    %rbx,%rdi
xor    %esi,%esi
call   1040 <fseek@plt>
mov    %rbx,%rdi
call   1030 <ftell@plt>
mov    %rax,%r15
mov    0x2e83(%rip),%rax
mov    (%rax),%edx
mov    %rbx,%rdi
mov    %r14,%rsi
call   1040 <fseek@plt>
mov    %r15,%rax
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@SEEK_END = global i32 0
@SEEK_SET = global i32 0
define i64 @FileSize(i32* %0) {
%2 = alloca i32*
%3 = alloca i64
%4 = alloca i64
store i32* %0, i32** %2
%5 = load i32*, i32** %2
%6 = call i64 @ftell(i32* %5)
store i64 %6, i64* %3
%7 = load i32*, i32** %2
%8 = load i32, i32* @SEEK_END
%9 = call i32 @fseek(i32* %7, i64 0, i32 %8)
%10 = load i32*, i32** %2
%11 = call i64 @ftell(i32* %10)
store i64 %11, i64* %4
%12 = load i32*, i32** %2
%13 = load i64, i64* %3
%14 = load i32, i32* @SEEK_SET
%15 = call i32 @fseek(i32* %12, i64 %13, i32 %14)
%16 = load i64, i64* %4
ret i64 %16
}

LLVM IR (-O2):
@SEEK_END = global i32 0
@SEEK_SET = global i32 0
define i64 @FileSize(i32* nocapture %0) {
%2 = tail call i64 @ftell(i32* %0)
%3 = load i32, i32* @SEEK_END
%4 = tail call i32 @fseek(i32* %0, i64 0, i32 %3)
%5 = tail call i64 @ftell(i32* %0)
%6 = load i32, i32* @SEEK_SET
%7 = tail call i32 @fseek(i32* %0, i64 %2, i32 %6)
ret i64 %5
}
/* Variables and functions */
int /*<<< orphan*/ CE_High();
int /*<<< orphan*/ CE_Low();
int /*<<< orphan*/ Send_Byte(int);
void WRDI() {
  CE_Low();
  Send_Byte(0x04);
  CE_High();
}


x86 assembly (clang, -O0):
<WRDI>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1050 <CE_Low@plt>
mov    $0x4,%edi
call   1030 <Send_Byte@plt>
mov    $0x0,%al
call   1040 <CE_High@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<WRDI>:
push   %rax
xor    %eax,%eax
call   1050 <CE_Low@plt>
mov    $0x4,%edi
call   1030 <Send_Byte@plt>
xor    %eax,%eax
pop    %rcx
jmp    1040 <CE_High@plt>

LLVM IR (-O0):
define void @WRDI() {
%1 = call i32 (...) @CE_Low()
%2 = call i32 @Send_Byte(i32 4)
%3 = call i32 (...) @CE_High()
ret void
}

LLVM IR (-O2):
define void @WRDI() {
%1 = tail call i32 (...) @CE_Low()
%2 = tail call i32 @Send_Byte(i32 4)
%3 = tail call i32 (...) @CE_High()
ret void
}
/* Type definitions */
typedef scalar_t__ uint64_t;

/* Variables and functions */
scalar_t__ timer_getTickCount64();
void timer_wait(uint64_t us) {
  us += timer_getTickCount64();
  while (timer_getTickCount64() < us) {
  };
}


x86 assembly (clang, -O0):
<timer_wait>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    $0x0,%al
call   1030 <timer_getTickCount64@plt>
add    -0x8(%rbp),%rax
mov    %rax,-0x8(%rbp)
mov    $0x0,%al
call   1030 <timer_getTickCount64@plt>
cmp    -0x8(%rbp),%rax
jge    1141 <timer_wait+0x31>
jmp    112b <timer_wait+0x1b>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<timer_wait>:
push   %r14
push   %rbx
push   %rax
mov    %rdi,%r14
xor    %eax,%eax
call   1030 <timer_getTickCount64@plt>
mov    %rax,%rbx
add    %r14,%rbx
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
xor    %eax,%eax
call   1030 <timer_getTickCount64@plt>
cmp    %rbx,%rax
jl     1130 <timer_wait+0x20>
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
define void @timer_wait(i64 %0) {
%2 = alloca i64
store i64 %0, i64* %2
%3 = call i64 (...) @timer_getTickCount64()
%4 = load i64, i64* %2
%5 = add nsw i64 %4, %3
store i64 %5, i64* %2
br label %6
6: ; preds = %10, %1
%7 = call i64 (...) @timer_getTickCount64()
%8 = load i64, i64* %2
%9 = icmp slt i64 %7, %8
br i1 %9, label %10, label %11
10: ; preds = %6
br label %6
11: ; preds = %6
ret void
}

LLVM IR (-O2):
define void @timer_wait(i64 %0) {
%2 = tail call i64 (...) @timer_getTickCount64()
%3 = add nsw i64 %2, %0
br label %4
4: ; preds = %4, %1
%5 = tail call i64 (...) @timer_getTickCount64()
%6 = icmp slt i64 %5, %3
br i1 %6, label %4, label %7
7: ; preds = %4
ret void
}
int toupper(int c) {
  if (c >= 'a' && c <= 'z') {
    c += 'A' - 'a';
  }
  return c;
}


x86 assembly (clang, -O0):
<toupper>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
cmpl   $0x61,-0x4(%rbp)
jl     1124 <toupper+0x24>
cmpl   $0x7a,-0x4(%rbp)
jg     1124 <toupper+0x24>
mov    -0x4(%rbp),%eax
add    $0xffffffe0,%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

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

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

LLVM IR (-O2):
define i32 @toupper(i32 %0) {
%2 = add i32 %0, -97
%3 = icmp ult i32 %2, 26
%4 = add nsw i32 %0, -32
%5 = select i1 %3, i32 %4, i32 %0
ret i32 %5
}
/* Type definitions */
typedef int uint32_t;

/* Variables and functions */
uint32_t get_mtu() { return 4096; }


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

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

LLVM IR (-O0):
define i32 @get_mtu() {
ret i32 4096
}

LLVM IR (-O2):
define i32 @get_mtu() {
ret i32 4096
}
void ble_rsp_hardware_io_port_config_direction(
    const struct ble_msg_hardware_io_port_config_direction_rsp_t *msg) {}


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

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

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

LLVM IR (-O2):
%struct.ble_msg_hardware_io_port_config_direction_rsp_t = type opaque
define void @ble_rsp_hardware_io_port_config_direction(%struct.ble_msg_hardware_io_port_config_direction_rsp_t* nocapture %0) {
ret void
}