xunge/DecIR huggingface dataset:
/* Variables and functions */
unsigned long special_field_exponent_bits(unsigned long);
signed long dfp64_exponent(unsigned long dword1) {
  unsigned long exponent_left;
  unsigned long exponent_right;
  unsigned long biased_exponent;
  signed long exponent;
  exponent_left = special_field_exponent_bits(dword1);
  exponent_right = (dword1 & 0x03fc000000000000);
  biased_exponent = (exponent_left << 8) + (exponent_right >> 50);
  exponent = biased_exponent - 398;
  return exponent;
}


x86 assembly (clang, -O0):
<dfp64_exponent>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <special_field_exponent_bits@plt>
mov    %rax,-0x10(%rbp)
movabs $0x3fc000000000000,%rax
and    -0x8(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    -0x10(%rbp),%rax
shl    $0x8,%rax
mov    -0x18(%rbp),%rcx
shr    $0x32,%rcx
add    %rcx,%rax
mov    %rax,-0x20(%rbp)
mov    -0x20(%rbp),%rax
sub    $0x18e,%rax
mov    %rax,-0x28(%rbp)
mov    -0x28(%rbp),%rax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<dfp64_exponent>:
push   %rbx
mov    %rdi,%rbx
call   1030 <special_field_exponent_bits@plt>
shl    $0x8,%rax
shr    $0x32,%rbx
movzbl %bl,%ecx
add    %rcx,%rax
add    $0xfffffffffffffe72,%rax
pop    %rbx
ret

LLVM IR (-O0):
define i64 @dfp64_exponent(i64 %0) {
%2 = alloca i64
%3 = alloca i64
%4 = alloca i64
%5 = alloca i64
%6 = alloca i64
store i64 %0, i64* %2
%7 = load i64, i64* %2
%8 = call i64 @special_field_exponent_bits(i64 %7)
store i64 %8, i64* %3
%9 = load i64, i64* %2
%10 = and i64 %9, 287104476244869120
store i64 %10, i64* %4
%11 = load i64, i64* %3
%12 = shl i64 %11, 8
%13 = load i64, i64* %4
%14 = lshr i64 %13, 50
%15 = add i64 %12, %14
store i64 %15, i64* %5
%16 = load i64, i64* %5
%17 = sub i64 %16, 398
store i64 %17, i64* %6
%18 = load i64, i64* %6
ret i64 %18
}

LLVM IR (-O2):
define i64 @dfp64_exponent(i64 %0) {
%2 = tail call i64 @special_field_exponent_bits(i64 %0)
%3 = shl i64 %2, 8
%4 = lshr i64 %0, 50
%5 = and i64 %4, 255
%6 = add nuw nsw i64 %5, -398
%7 = add i64 %6, %3
ret i64 %7
}
void gtk_container_child_type() {}


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

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

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

LLVM IR (-O2):
define void @gtk_container_child_type() {
ret void
}
/* Type definitions */
typedef int uint64_t;
typedef int /*<<< orphan*/ uint16_t;

/* Variables and functions */
int read8low(int /*<<< orphan*/);
uint64_t dictionary_get(uint16_t addr) {
  uint64_t v = 0;
  int c = 3 > 3 ? 6 : 4;
  while (c--)
    v = (v << 8) | read8low(addr++);
  return v;
}


x86 assembly (clang, -O0):
<dictionary_get>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
movl   $0x4,-0xc(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,%ecx
add    $0xffffffff,%ecx
mov    %ecx,-0xc(%rbp)
cmp    $0x0,%eax
je     1165 <dictionary_get+0x55>
mov    -0x8(%rbp),%eax
shl    $0x8,%eax
mov    %eax,-0x10(%rbp)
mov    -0x4(%rbp),%edi
mov    %edi,%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
call   1030 <read8low@plt>
mov    %eax,%ecx
mov    -0x10(%rbp),%eax
or     %ecx,%eax
mov    %eax,-0x8(%rbp)
jmp    1129 <dictionary_get+0x19>
mov    -0x8(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<dictionary_get>:
push   %rbp
push   %r15
push   %r14
push   %r12
push   %rbx
mov    %edi,%ebx
lea    0x1(%rbx),%r14d
call   1030 <read8low@plt>
mov    %eax,%r12d
lea    0x2(%rbx),%r15d
mov    %r14d,%edi
call   1030 <read8low@plt>
mov    %eax,%r14d
shl    $0x10,%r12d
shl    $0x8,%r14d
add    $0x3,%ebx
mov    %r15d,%edi
call   1030 <read8low@plt>
mov    %eax,%ebp
or     %r12d,%ebp
or     %r14d,%ebp
shl    $0x8,%ebp
mov    %ebx,%edi
call   1030 <read8low@plt>
or     %ebp,%eax
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
define i32 @dictionary_get(i32 %0) {
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
store i32 %0, i32* %2
store i32 0, i32* %3
store i32 4, i32* %4
br label %5
5: ; preds = %9, %1
%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 %16
9: ; preds = %5
%10 = load i32, i32* %3
%11 = shl i32 %10, 8
%12 = load i32, i32* %2
%13 = add nsw i32 %12, 1
store i32 %13, i32* %2
%14 = call i32 @read8low(i32 %12)
%15 = or i32 %11, %14
store i32 %15, i32* %3
br label %5
16: ; preds = %5
%17 = load i32, i32* %3
ret i32 %17
}

LLVM IR (-O2):
define i32 @dictionary_get(i32 %0) {
%2 = add nsw i32 %0, 1
%3 = tail call i32 @read8low(i32 %0)
%4 = add nsw i32 %0, 2
%5 = tail call i32 @read8low(i32 %2)
%6 = shl i32 %3, 16
%7 = shl i32 %5, 8
%8 = or i32 %6, %7
%9 = add nsw i32 %0, 3
%10 = tail call i32 @read8low(i32 %4)
%11 = or i32 %10, %8
%12 = shl i32 %11, 8
%13 = tail call i32 @read8low(i32 %9)
%14 = or i32 %13, %12
ret i32 %14
}
/* Type definitions */
typedef int uint32_t;
typedef int int32_t;

/* Variables and functions */
int main(void) {
  int32_t i;
  *(uint32_t *)(0xA0000000) = 0x155;
  while (1) {
    if (1 & *(volatile uint32_t *)(0xA0001000)) {
      ;
    } else {
      for (i = 0; i < 0x2FFFFF; i++)
        ;
      *(uint32_t *)(0xA0000000) ^= 0x3FF;
    }
  }
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
movl   $0x0,-0x4(%rbp)
mov    $0xa0000000,%eax
movl   $0x155,(%rax)
mov    $0xa0001000,%eax
mov    (%rax),%eax
and    $0x1,%eax
cmp    $0x0,%eax
je     112e <main+0x2e>
jmp    1169 <main+0x69>
movl   $0x0,-0x8(%rbp)
cmpl   $0x2fffff,-0x8(%rbp)
jge    1155 <main+0x55>
jmp    1147 <main+0x47>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1135 <main+0x35>
mov    $0xa0000000,%eax
mov    (%rax),%ecx
xor    $0x3ff,%ecx
mov    $0xa0000000,%eax
mov    %ecx,(%rax)
jmp    1116 <main+0x16>

x86 assembly (clang, -O2):
<main>:
mov    $0x155,%eax
mov    $0xa0000000,%ecx
nopw   0x0(%rax,%rax,1)
mov    %eax,(%rcx)
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
mov    0x1000(%rcx),%edx
test   $0x1,%dl
jne    1120 <main+0x20>
xor    $0x3ff,%eax
jmp    1110 <main+0x10>

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
store i32 0, i32* %1
store i32 341, i32* inttoptr (i64 2684354560 to i32*)
br label %3
3: ; preds = %0, %19
%4 = load volatile i32, i32* inttoptr (i64 2684358656 to i32*)
%5 = and i32 1, %4
%6 = icmp ne i32 %5, 0
br i1 %6, label %7, label %8
7: ; preds = %3
br label %19
8: ; preds = %3
store i32 0, i32* %2
br label %9
9: ; preds = %13, %8
%10 = load i32, i32* %2
%11 = icmp slt i32 %10, 3145727
br i1 %11, label %12, label %16
12: ; preds = %9
br label %13
13: ; preds = %12
%14 = load i32, i32* %2
%15 = add nsw i32 %14, 1
store i32 %15, i32* %2
br label %9
16: ; preds = %9
%17 = load i32, i32* inttoptr (i64 2684354560 to i32*)
%18 = xor i32 %17, 1023
store i32 %18, i32* inttoptr (i64 2684354560 to i32*)
br label %19
19: ; preds = %16, %7
br label %3
}

LLVM IR (-O2):
define i32 @main() {
br label %1
1: ; preds = %0, %7
%2 = phi i32 [ %8, %7 ], [ 341, %0 ]
store i32 %2, i32* inttoptr (i64 2684354560 to i32*)
br label %3
3: ; preds = %1, %3
%4 = load volatile i32, i32* inttoptr (i64 2684358656 to i32*)
%5 = and i32 %4, 1
%6 = icmp eq i32 %5, 0
br i1 %6, label %7, label %3
7: ; preds = %3
%8 = xor i32 %2, 1023
br label %1
}
/* Variables and functions */
int /*<<< orphan*/ CompileCondition();
int /*<<< orphan*/ ResetIf();
int /*<<< orphan*/ WriteInstruction(char *);
void CR_CanGoLeft(void) {
  WriteInstruction("call cangl");
  WriteInstruction("jp nz,      ");
  CompileCondition();
  ResetIf();
}


x86 assembly (clang, -O0):
<CR_CanGoLeft>:
push   %rbp
mov    %rsp,%rbp
lea    0xec5(%rip),%rdi
call   1040 <WriteInstruction@plt>
lea    0xec4(%rip),%rdi
call   1040 <WriteInstruction@plt>
mov    $0x0,%al
call   1050 <CompileCondition@plt>
mov    $0x0,%al
call   1030 <ResetIf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<CR_CanGoLeft>:
push   %rax
lea    0xec8(%rip),%rdi
call   1040 <WriteInstruction@plt>
lea    0xec7(%rip),%rdi
call   1040 <WriteInstruction@plt>
xor    %eax,%eax
call   1050 <CompileCondition@plt>
xor    %eax,%eax
pop    %rcx
jmp    1030 <ResetIf@plt>

LLVM IR (-O0):
@.str = [11 x i8] c"call cangl\00"
@.str.1 = [13 x i8] c"jp nz, \00"
define void @CR_CanGoLeft() {
%1 = call i32 @WriteInstruction(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0))
%2 = call i32 @WriteInstruction(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.1, i64 0, i64 0))
%3 = call i32 (...) @CompileCondition()
%4 = call i32 (...) @ResetIf()
ret void
}

LLVM IR (-O2):
@.str = [11 x i8] c"call cangl\00"
@.str.1 = [13 x i8] c"jp nz, \00"
define void @CR_CanGoLeft() {
%1 = tail call i32 @WriteInstruction(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 @WriteInstruction(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.1, i64 0, i64 0))
%3 = tail call i32 (...) @CompileCondition()
%4 = tail call i32 (...) @ResetIf()
ret void
}
/* Variables and functions */
int lifted_a(unsigned int *);
int unlifted_a(unsigned int *);
unsigned lifted_b(unsigned *x) { return unlifted_a(x) + lifted_a(x) + *x; }


x86 assembly (clang, -O0):
<lifted_b>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <unlifted_a@plt>
mov    %eax,-0xc(%rbp)
mov    -0x8(%rbp),%rdi
call   1040 <lifted_a@plt>
mov    %eax,%ecx
mov    -0xc(%rbp),%eax
add    %ecx,%eax
mov    -0x8(%rbp),%rcx
add    (%rcx),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<lifted_b>:
push   %rbp
push   %rbx
push   %rax
mov    %rdi,%rbx
call   1030 <unlifted_a@plt>
mov    %eax,%ebp
mov    %rbx,%rdi
call   1040 <lifted_a@plt>
add    %ebp,%eax
add    (%rbx),%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
define i32 @lifted_b(i32* %0) {
%2 = alloca i32*
store i32* %0, i32** %2
%3 = load i32*, i32** %2
%4 = call i32 @unlifted_a(i32* %3)
%5 = load i32*, i32** %2
%6 = call i32 @lifted_a(i32* %5)
%7 = add nsw i32 %4, %6
%8 = load i32*, i32** %2
%9 = load i32, i32* %8
%10 = add i32 %7, %9
ret i32 %10
}

LLVM IR (-O2):
define i32 @lifted_b(i32* %0) {
%2 = tail call i32 @unlifted_a(i32* %0)
%3 = tail call i32 @lifted_a(i32* %0)
%4 = add nsw i32 %3, %2
%5 = load i32, i32* %0
%6 = add i32 %4, %5
ret i32 %6
}
/* Type definitions */
struct pri {
  int dummy;
};

/* Variables and functions */
int q931_restart(struct pri *, int);
int pri_reset(struct pri *pri, int channel) {
  if (!pri)
    return -1;
  return q931_restart(pri, channel);
}


x86 assembly (clang, -O0):
<pri_reset>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %esi,-0x14(%rbp)
cmpq   $0x0,-0x10(%rbp)
jne    1136 <pri_reset+0x26>
movl   $0xffffffff,-0x4(%rbp)
jmp    1145 <pri_reset+0x35>
mov    -0x10(%rbp),%rdi
mov    -0x14(%rbp),%esi
call   1030 <q931_restart@plt>
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<pri_reset>:
test   %rdi,%rdi
je     111a <pri_reset+0xa>
jmp    1030 <q931_restart@plt>
mov    $0xffffffff,%eax
ret

LLVM IR (-O0):
%struct.pri = type { i32 }
define i32 @pri_reset(%struct.pri* %0, i32 %1) {
%3 = alloca i32
%4 = alloca %struct.pri*
%5 = alloca i32
store %struct.pri* %0, %struct.pri** %4
store i32 %1, i32* %5
%6 = load %struct.pri*, %struct.pri** %4
%7 = icmp ne %struct.pri* %6, null
br i1 %7, label %9, label %8
8: ; preds = %2
store i32 -1, i32* %3
br label %13
9: ; preds = %2
%10 = load %struct.pri*, %struct.pri** %4
%11 = load i32, i32* %5
%12 = call i32 @q931_restart(%struct.pri* %10, i32 %11)
store i32 %12, i32* %3
br label %13
13: ; preds = %9, %8
%14 = load i32, i32* %3
ret i32 %14
}

LLVM IR (-O2):
%struct.pri = type { i32 }
define i32 @pri_reset(%struct.pri* %0, i32 %1) {
%3 = icmp eq %struct.pri* %0, null
br i1 %3, label %6, label %4
4: ; preds = %2
%5 = tail call i32 @q931_restart(%struct.pri* %0, i32 %1)
br label %6
6: ; preds = %2, %4
%7 = phi i32 [ %5, %4 ], [ -1, %2 ]
ret i32 %7
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, char *, char *);
void print_constant_str(char *name, char *value) {
  printf("#define %s \"%s\"\n", name, value);
}


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

x86 assembly (clang, -O2):
<print_constant_str>:
mov    %rsi,%rdx
mov    %rdi,%rsi
lea    0xee3(%rip),%rdi
jmp    1030 <printf@plt>

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

LLVM IR (-O2):
@.str = [17 x i8] c"#define %s \22%s\22\0A\00"
define void @print_constant_str(i8* %0, i8* %1) {
%3 = tail call i32 @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0), i8* %0, i8* %1)
ret void
}
/* Variables and functions */
int foo(int);
int main(void) {
  int l_i, x1, x2, x3;
  l_i = l_i + 1;
  x1 = 1;
  x1 = x1 + l_i;
  x2 = foo(x1);
  return 1;
}


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

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

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store i32 0, i32* %1
%6 = load i32, i32* %2
%7 = add nsw i32 %6, 1
store i32 %7, i32* %2
store i32 1, i32* %3
%8 = load i32, i32* %3
%9 = load i32, i32* %2
%10 = add nsw i32 %8, %9
store i32 %10, i32* %3
%11 = load i32, i32* %3
%12 = call i32 @foo(i32 %11)
store i32 %12, i32* %4
ret i32 1
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 @foo(i32 undef)
ret i32 1
}
/* Variables and functions */
scalar_t__ Clock_SetSeconds(double *, int /*<<< orphan*/);
double time(int /*<<< orphan*/ *);
double Clock_Seconds(void) {
  double ans;
  if (Clock_SetSeconds(&ans, 0) == 0) {
    ans = time(NULL);
  }
  return ans;
}


x86 assembly (clang, -O0):
<Clock_Seconds>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
lea    -0x8(%rbp),%rdi
xor    %esi,%esi
call   1030 <Clock_SetSeconds@plt>
cmp    $0x0,%rax
jne    114b <Clock_Seconds+0x2b>
xor    %eax,%eax
mov    %eax,%edi
call   1040 <time@plt>
movsd  %xmm0,-0x8(%rbp)
movsd  -0x8(%rbp),%xmm0
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<Clock_Seconds>:
push   %rax
mov    %rsp,%rdi
xor    %esi,%esi
call   1030 <Clock_SetSeconds@plt>
test   %rax,%rax
je     1137 <Clock_Seconds+0x17>
movsd  (%rsp),%xmm0
pop    %rax
ret
xor    %edi,%edi
call   1040 <time@plt>
pop    %rax
ret

LLVM IR (-O0):
define double @Clock_Seconds() {
%1 = alloca double
%2 = call i64 @Clock_SetSeconds(double* %1, i32 0)
%3 = icmp eq i64 %2, 0
br i1 %3, label %4, label %6
4: ; preds = %0
%5 = call double @time(i32* null)
store double %5, double* %1
br label %6
6: ; preds = %4, %0
%7 = load double, double* %1
ret double %7
}

LLVM IR (-O2):
define double @Clock_Seconds() {
%1 = alloca double
%2 = bitcast double* %1 to i8*
%3 = call i64 @Clock_SetSeconds(double* %1, i32 0)
%4 = icmp eq i64 %3, 0
br i1 %4, label %7, label %5
5: ; preds = %0
%6 = load double, double* %1
br label %9
7: ; preds = %0
%8 = call double @time(i32* null)
br label %9
9: ; preds = %5, %7
%10 = phi double [ %6, %5 ], [ %8, %7 ]
ret double %10
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, char const *);
void usage(const char *prg) { printf("Usage: %s: [host:port] CMD\n", prg); }


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

x86 assembly (clang, -O2):
<usage>:
mov    %rdi,%rsi
lea    0xee6(%rip),%rdi
jmp    1030 <printf@plt>

LLVM IR (-O0):
@.str = [28 x i8] c"Usage: %s: [host:port] CMD\0A\00"
define void @usage(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = call i32 @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str, i64 0, i64 0), i8* %3)
ret void
}

LLVM IR (-O2):
@.str = [28 x i8] c"Usage: %s: [host:port] CMD\0A\00"
define void @usage(i8* %0) {
%2 = tail call i32 @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str, i64 0, i64 0), i8* %0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ checkForChanges();
int /*<<< orphan*/ updatePos();
void idleFunc() {
  checkForChanges();
  updatePos();
}


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

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

LLVM IR (-O0):
define void @idleFunc() {
%1 = call i32 (...) @checkForChanges()
%2 = call i32 (...) @updatePos()
ret void
}

LLVM IR (-O2):
define void @idleFunc() {
%1 = tail call i32 (...) @checkForChanges()
%2 = tail call i32 (...) @updatePos()
ret void
}
/* Variables and functions */
int strcmp(char const *, char const *);
int cmp_string_gt(const void *a, const void *b) {
  return -(strcmp(*(const char **)a, *(const char **)b));
}


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

x86 assembly (clang, -O2):
<cmp_string_gt>:
push   %rax
mov    (%rdi),%rdi
mov    (%rsi),%rsi
call   1030 <strcmp@plt>
neg    %eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @cmp_string_gt(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
store i8* %0, i8** %3
store i8* %1, i8** %4
%5 = load i8*, i8** %3
%6 = bitcast i8* %5 to i8**
%7 = load i8*, i8** %6
%8 = load i8*, i8** %4
%9 = bitcast i8* %8 to i8**
%10 = load i8*, i8** %9
%11 = call i32 @strcmp(i8* %7, i8* %10)
%12 = sub nsw i32 0, %11
ret i32 %12
}

LLVM IR (-O2):
define i32 @cmp_string_gt(i8* nocapture %0, i8* nocapture %1) {
%3 = bitcast i8* %0 to i8**
%4 = load i8*, i8** %3
%5 = bitcast i8* %1 to i8**
%6 = load i8*, i8** %5
%7 = tail call i32 @strcmp(i8* dereferenceable(1) %4, i8* dereferenceable(1) %6)
%8 = sub nsw i32 0, %7
ret i32 %8
}
/* Variables and functions */
int EINVAL;
__attribute__((visibility("default"))) int
sd_bus_message_copy(void *m, void *source, int all) {
  return -EINVAL;
}


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

x86 assembly (clang, -O2):
<sd_bus_message_copy>:
mov    0x2ed9(%rip),%rcx
xor    %eax,%eax
sub    (%rcx),%eax
ret

LLVM IR (-O0):
@EINVAL = global i32 0
define i32 @sd_bus_message_copy(i8* %0, i8* %1, i32 %2) {
%4 = alloca i8*
%5 = alloca i8*
%6 = alloca i32
store i8* %0, i8** %4
store i8* %1, i8** %5
store i32 %2, i32* %6
%7 = load i32, i32* @EINVAL
%8 = sub nsw i32 0, %7
ret i32 %8
}

LLVM IR (-O2):
@EINVAL = global i32 0
define i32 @sd_bus_message_copy(i8* nocapture readnone %0, i8* nocapture readnone %1, i32 %2) {
%4 = load i32, i32* @EINVAL
%5 = sub nsw i32 0, %4
ret i32 %5
}
void sk_find(void) {}


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

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

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

LLVM IR (-O2):
define void @sk_find() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, float);
int main(int argc, const char *argv[]) {
  float weight;
  weight = 14.2;
  printf("The turkey weight is %f.\n", weight);
  float cookingTime;
  cookingTime = 15.0 + 15.0 * weight;
  printf("Cook it for %f minutes.\n", cookingTime);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
movss  0xeda(%rip),%xmm0
movss  %xmm0,-0x14(%rbp)
movss  -0x14(%rbp),%xmm0
lea    0xecd(%rip),%rdi
call   1030 <printf@plt>
movss  -0x14(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  0xeab(%rip),%xmm1
mulsd  %xmm1,%xmm0
addsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,-0x18(%rbp)
movss  -0x18(%rbp),%xmm0
lea    0xeb4(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
@.str = [26 x i8] c"The turkey weight is %f.\0A\00"
@.str.1 = [25 x i8] c"Cook it for %f minutes.\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca float
%7 = alloca float
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store float 0x402C666660000000, float* %6
%8 = load float, float* %6
%9 = call i32 @printf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str, i64 0, i64 0), float %8)
%10 = load float, float* %6
%11 = fpext float %10 to double
%12 = call double @llvm.fmuladd.f64(double 1.500000e+01, double %11, double 1.500000e+01)
%13 = fptrunc double %12 to float
store float %13, float* %7
%14 = load float, float* %7
%15 = call i32 @printf(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.1, i64 0, i64 0), float %14)
ret i32 0
}

LLVM IR (-O2):
@.str = [26 x i8] c"The turkey weight is %f.\0A\00"
@.str.1 = [25 x i8] c"Cook it for %f minutes.\0A\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @printf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str, i64 0, i64 0), float 0x402C666660000000)
%4 = tail call i32 @printf(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.1, i64 0, i64 0), float 2.280000e+02)
ret i32 0
}
void gtk_widget_set_parent() {}


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

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

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

LLVM IR (-O2):
define void @gtk_widget_set_parent() {
ret void
}
int iFunAdd(int iA, int iB) { return iA + iB; }


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

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

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

LLVM IR (-O2):
define i32 @iFunAdd(i32 %0, i32 %1) {
%3 = add nsw i32 %1, %0
ret i32 %3
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
int isqrt(int);
void t_sqrt_49() {
  Assert_real((isqrt(49) == 7),
              "/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/stdlib/isqrt.c",
              250, ("Integer square root of 49 should be 7"));
}


x86 assembly (clang, -O0):
<t_sqrt_49>:
push   %rbp
mov    %rsp,%rbp
mov    $0x31,%edi
call   1030 <isqrt@plt>
cmp    $0x7,%eax
sete   %al
and    $0x1,%al
movzbl %al,%edi
lea    0xec0(%rip),%rsi
mov    $0xfa,%edx
lea    0xf56(%rip),%rcx
call   1040 <Assert_real@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<t_sqrt_49>:
push   %rax
mov    $0x31,%edi
call   1030 <isqrt@plt>
xor    %edi,%edi
cmp    $0x7,%eax
sete   %dil
lea    0xec5(%rip),%rsi
lea    0xf60(%rip),%rcx
mov    $0xfa,%edx
pop    %rax
jmp    1040 <Assert_real@plt>

LLVM IR (-O0):
@.str = [162 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/stdlib/isqrt.c\00"
@.str.1 = [38 x i8] c"Integer square root of 49 should be 7\00"
define void @t_sqrt_49() {
%1 = call i32 @isqrt(i32 49)
%2 = icmp eq i32 %1, 7
%3 = zext i1 %2 to i32
%4 = call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([162 x i8], [162 x i8]* @.str, i64 0, i64 0), i32 250, i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [162 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/stdlib/isqrt.c\00"
@.str.1 = [38 x i8] c"Integer square root of 49 should be 7\00"
define void @t_sqrt_49() {
%1 = tail call i32 @isqrt(i32 49)
%2 = icmp eq i32 %1, 7
%3 = zext i1 %2 to i32
%4 = tail call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([162 x i8], [162 x i8]* @.str, i64 0, i64 0), i32 250, i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ ssize_t;
typedef int /*<<< orphan*/ __ptr_t;

/* Variables and functions */
int PTHREAD_CANCEL_ASYNCHRONOUS;
int /*<<< orphan*/ __libc_recv(int, int /*<<< orphan*/, size_t, int);
int /*<<< orphan*/ pthread_setcanceltype(int, int *);
ssize_t __attribute__((weak)) recv(int fd, __ptr_t buf, size_t n, int flags) {
  ssize_t result;
  int oldtype;
  pthread_setcanceltype(PTHREAD_CANCEL_ASYNCHRONOUS, &oldtype);
  result = __libc_recv(fd, buf, n, flags);
  pthread_setcanceltype(oldtype, NULL);
  return result;
}


x86 assembly (clang, -O0):
<recv>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %rdx,-0x10(%rbp)
mov    %ecx,-0x14(%rbp)
mov    0x2eac(%rip),%rax
mov    (%rax),%edi
lea    -0x1c(%rbp),%rsi
call   1040 <pthread_setcanceltype@plt>
mov    -0x4(%rbp),%edi
mov    -0x8(%rbp),%esi
mov    -0x10(%rbp),%rdx
mov    -0x14(%rbp),%ecx
call   1030 <__libc_recv@plt>
mov    %eax,-0x18(%rbp)
mov    -0x1c(%rbp),%edi
xor    %eax,%eax
mov    %eax,%esi
call   1040 <pthread_setcanceltype@plt>
mov    -0x18(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<recv>:
push   %rbp
push   %r15
push   %r14
push   %rbx
push   %rax
mov    %ecx,%r14d
mov    %rdx,%r15
mov    %esi,%ebp
mov    %edi,%ebx
mov    0x2eb0(%rip),%rax
mov    (%rax),%edi
lea    0x4(%rsp),%rsi
call   1040 <pthread_setcanceltype@plt>
mov    %ebx,%edi
mov    %ebp,%esi
mov    %r15,%rdx
mov    %r14d,%ecx
call   1030 <__libc_recv@plt>
mov    %eax,%ebx
mov    0x4(%rsp),%edi
xor    %esi,%esi
call   1040 <pthread_setcanceltype@plt>
mov    %ebx,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@PTHREAD_CANCEL_ASYNCHRONOUS = global i32 0
define weak i32 @recv(i32 %0, i32 %1, i64 %2, i32 %3) {
%5 = alloca i32
%6 = alloca i32
%7 = alloca i64
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
store i32 %0, i32* %5
store i32 %1, i32* %6
store i64 %2, i64* %7
store i32 %3, i32* %8
%11 = load i32, i32* @PTHREAD_CANCEL_ASYNCHRONOUS
%12 = call i32 @pthread_setcanceltype(i32 %11, i32* %10)
%13 = load i32, i32* %5
%14 = load i32, i32* %6
%15 = load i64, i64* %7
%16 = load i32, i32* %8
%17 = call i32 @__libc_recv(i32 %13, i32 %14, i64 %15, i32 %16)
store i32 %17, i32* %9
%18 = load i32, i32* %10
%19 = call i32 @pthread_setcanceltype(i32 %18, i32* null)
%20 = load i32, i32* %9
ret i32 %20
}

LLVM IR (-O2):
@PTHREAD_CANCEL_ASYNCHRONOUS = global i32 0
define weak i32 @recv(i32 %0, i32 %1, i64 %2, i32 %3) {
%5 = alloca i32
%6 = bitcast i32* %5 to i8*
%7 = load i32, i32* @PTHREAD_CANCEL_ASYNCHRONOUS
%8 = call i32 @pthread_setcanceltype(i32 %7, i32* %5)
%9 = call i32 @__libc_recv(i32 %0, i32 %1, i64 %2, i32 %3)
%10 = load i32, i32* %5
%11 = call i32 @pthread_setcanceltype(i32 %10, i32* null)
ret i32 %9
}
/* Variables and functions */
int /*<<< orphan*/ free(void *);
int ph_unknown_destroy(void *handler) {
  free(handler);
  return 0;
}


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

x86 assembly (clang, -O2):
<ph_unknown_destroy>:
push   %rax
call   1030 <free@plt>
xor    %eax,%eax
pop    %rcx
ret

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

LLVM IR (-O2):
define i32 @ph_unknown_destroy(i8* nocapture %0) {
%2 = tail call i32 @free(i8* %0)
ret i32 0
}
/* Type definitions */
typedef int /*<<< orphan*/ __u8;
typedef int /*<<< orphan*/ __s32;

/* Variables and functions */
int /*<<< orphan*/ i2c_smbus_access(int, int /*<<< orphan*/, int /*<<< orphan*/,
                                    int, int /*<<< orphan*/ *);
__s32 i2c_smbus_write_byte(int file, __u8 value) {
  return i2c_smbus_access(file, 0, value, 1, NULL);
}


x86 assembly (clang, -O0):
<i2c_smbus_write_byte>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x4(%rbp),%edi
mov    -0x8(%rbp),%edx
xor    %esi,%esi
mov    $0x1,%ecx
xor    %eax,%eax
mov    %eax,%r8d
call   1030 <i2c_smbus_access@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<i2c_smbus_write_byte>:
mov    %esi,%edx
xor    %esi,%esi
mov    $0x1,%ecx
xor    %r8d,%r8d
jmp    1030 <i2c_smbus_access@plt>

LLVM IR (-O0):
define i32 @i2c_smbus_write_byte(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 @i2c_smbus_access(i32 %5, i32 0, i32 %6, i32 1, i32* null)
ret i32 %7
}

LLVM IR (-O2):
define i32 @i2c_smbus_write_byte(i32 %0, i32 %1) {
%3 = tail call i32 @i2c_smbus_access(i32 %0, i32 0, i32 %1, i32 1, i32* null)
ret i32 %3
}
/* Variables and functions */
unsigned int getchar();
unsigned int readChar(void) { return (getchar() & 0777777u); }


x86 assembly (clang, -O0):
<readChar>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1030 <getchar@plt>
and    $0x3ffff,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<readChar>:
push   %rax
xor    %eax,%eax
call   1030 <getchar@plt>
and    $0x3ffff,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @readChar() {
%1 = call i32 (...) @getchar()
%2 = and i32 %1, 262143
ret i32 %2
}

LLVM IR (-O2):
define i32 @readChar() {
%1 = tail call i32 (...) @getchar()
%2 = and i32 %1, 262143
ret i32 %2
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, ...);
void helle(char *t) {
  printf("Hello %s", t);
  printf("\n Bienvenu dans le monde de c la ou les fonctions et les variable "
         "vivent en harmonie");
}


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

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

LLVM IR (-O0):
@.str = [9 x i8] c"Hello %s\00"
@.str.1 = [85 x i8] c"\0A Bienvenu dans le monde de c la ou les fonctions et les variable vivent en harmonie\00"
define void @helle(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i8* %3)
%5 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([85 x i8], [85 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [9 x i8] c"Hello %s\00"
@.str.1 = [85 x i8] c"\0A Bienvenu dans le monde de c la ou les fonctions et les variable vivent en harmonie\00"
define void @helle(i8* %0) {
%2 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i8* %0)
%3 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([85 x i8], [85 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
int main() {
#pragma xmp task on p0(1, 1) nocomm
  { printf("Skipped\n"); }
}


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

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

LLVM IR (-O0):
@.str = [9 x i8] c"Skipped\0A\00"
define i32 @main() {
%1 = call i32 @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@str = [8 x i8] c"Skipped\00"
define i32 @main() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([8 x i8], [8 x i8]* @str, i64 0, i64 0))
ret i32 0
}
int dbCreationTest() { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @dbCreationTest() {
ret i32 0
}
/* Forward declarations */
typedef struct TYPE_2__ TYPE_1__;

/* Type definitions */
struct TYPE_2__ {
  scalar_t__ key;
};
typedef TYPE_1__ XKeyboardControl;

/* Variables and functions */
int get_XKeyboardControl_key(void *_p) {
  return (int)((XKeyboardControl *)_p)->key;
}


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

x86 assembly (clang, -O2):
<get_XKeyboardControl_key>:
mov    (%rdi),%eax
ret

LLVM IR (-O0):
%struct.TYPE_2__ = type { i64 }
define i32 @get_XKeyboardControl_key(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
%7 = trunc i64 %6 to i32
ret i32 %7
}

LLVM IR (-O2):
define i32 @get_XKeyboardControl_key(i8* nocapture %0) {
%2 = bitcast i8* %0 to i64*
%3 = load i64, i64* %2
%4 = trunc i64 %3 to i32
ret i32 %4
}
int fun127() { return 127; }


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

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

LLVM IR (-O0):
define i32 @fun127() {
ret i32 127
}

LLVM IR (-O2):
define i32 @fun127() {
ret i32 127
}
/* Type definitions */
typedef int /*<<< orphan*/ uint8_t;

/* Variables and functions */
unsigned int WORD_(int /*<<< orphan*/ const, int /*<<< orphan*/ const);
int /*<<< orphan*/ decode_hiscoa_band_data(int /*<<< orphan*/ const *, size_t,
                                           unsigned int);
void decode_hiscoa_band2(const uint8_t *buf, size_t size) {
  unsigned lines = WORD_(buf[2], buf[3]);
  decode_hiscoa_band_data(buf + 8, size - 8, lines);
}


x86 assembly (clang, -O0):
<decode_hiscoa_band2>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
mov    0x8(%rax),%edi
mov    -0x8(%rbp),%rax
mov    0xc(%rax),%esi
call   1030 <WORD_@plt>
mov    %eax,-0x14(%rbp)
mov    -0x8(%rbp),%rdi
add    $0x20,%rdi
mov    -0x10(%rbp),%rsi
sub    $0x8,%rsi
mov    -0x14(%rbp),%edx
call   1040 <decode_hiscoa_band_data@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<decode_hiscoa_band2>:
push   %r14
push   %rbx
push   %rax
mov    %rsi,%r14
mov    %rdi,%rbx
mov    0x8(%rdi),%edi
mov    0xc(%rbx),%esi
call   1030 <WORD_@plt>
add    $0x20,%rbx
add    $0xfffffffffffffff8,%r14
mov    %rbx,%rdi
mov    %r14,%rsi
mov    %eax,%edx
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1040 <decode_hiscoa_band_data@plt>

LLVM IR (-O0):
define void @decode_hiscoa_band2(i32* %0, i64 %1) {
%3 = alloca i32*
%4 = alloca i64
%5 = alloca i32
store i32* %0, i32** %3
store i64 %1, i64* %4
%6 = load i32*, i32** %3
%7 = getelementptr inbounds i32, i32* %6, i64 2
%8 = load i32, i32* %7
%9 = load i32*, i32** %3
%10 = getelementptr inbounds i32, i32* %9, i64 3
%11 = load i32, i32* %10
%12 = call i32 @WORD_(i32 %8, i32 %11)
store i32 %12, i32* %5
%13 = load i32*, i32** %3
%14 = getelementptr inbounds i32, i32* %13, i64 8
%15 = load i64, i64* %4
%16 = sub i64 %15, 8
%17 = load i32, i32* %5
%18 = call i32 @decode_hiscoa_band_data(i32* %14, i64 %16, i32 %17)
ret void
}

LLVM IR (-O2):
define void @decode_hiscoa_band2(i32* %0, i64 %1) {
%3 = getelementptr inbounds i32, i32* %0, i64 2
%4 = load i32, i32* %3
%5 = getelementptr inbounds i32, i32* %0, i64 3
%6 = load i32, i32* %5
%7 = tail call i32 @WORD_(i32 %4, i32 %6)
%8 = getelementptr inbounds i32, i32* %0, i64 8
%9 = add i64 %1, -8
%10 = tail call i32 @decode_hiscoa_band_data(i32* %8, i64 %9, i32 %7)
ret void
}
/* Variables and functions */
int check_bg_ucn(char *);
scalar_t__ is_string_equals(char *, char *);
int check_ucn(char ucn[], char country[]) {
  if (is_string_equals(country, "bg")) {
    return check_bg_ucn(ucn);
  }
  return 0;
}


x86 assembly (clang, -O0):
<check_ucn>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    -0x18(%rbp),%rdi
lea    0xec5(%rip),%rsi
call   1030 <is_string_equals@plt>
cmp    $0x0,%rax
je     115b <check_ucn+0x3b>
mov    -0x10(%rbp),%rdi
call   1040 <check_bg_ucn@plt>
mov    %eax,-0x4(%rbp)
jmp    1162 <check_ucn+0x42>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<check_ucn>:
push   %rbx
mov    %rsi,%rax
mov    %rdi,%rbx
lea    0xed2(%rip),%rsi
mov    %rax,%rdi
call   1030 <is_string_equals@plt>
test   %rax,%rax
je     1144 <check_ucn+0x24>
mov    %rbx,%rdi
pop    %rbx
jmp    1040 <check_bg_ucn@plt>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [3 x i8] c"bg\00"
define i32 @check_ucn(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** %5
%7 = call i64 @is_string_equals(i8* %6, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0))
%8 = icmp ne i64 %7, 0
br i1 %8, label %9, label %12
9: ; preds = %2
%10 = load i8*, i8** %4
%11 = call i32 @check_bg_ucn(i8* %10)
store i32 %11, i32* %3
br label %13
12: ; preds = %2
store i32 0, i32* %3
br label %13
13: ; preds = %12, %9
%14 = load i32, i32* %3
ret i32 %14
}

LLVM IR (-O2):
@.str = [3 x i8] c"bg\00"
define i32 @check_ucn(i8* %0, i8* %1) {
%3 = tail call i64 @is_string_equals(i8* %1, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0))
%4 = icmp eq i64 %3, 0
br i1 %4, label %7, label %5
5: ; preds = %2
%6 = tail call i32 @check_bg_ucn(i8* %0)
br label %7
7: ; preds = %2, %5
%8 = phi i32 [ %6, %5 ], [ 0, %2 ]
ret i32 %8
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, void *);
void _pr_addr_(void *head) { printf("   %p\n", head); }


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

x86 assembly (clang, -O2):
<_pr_addr_>:
mov    %rdi,%rsi
lea    0xee6(%rip),%rdi
jmp    1030 <printf@plt>

LLVM IR (-O0):
@.str = [7 x i8] c" %p\0A\00"
define void @_pr_addr_(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i8* %3)
ret void
}

LLVM IR (-O2):
@.str = [7 x i8] c" %p\0A\00"
define void @_pr_addr_(i8* %0) {
%2 = tail call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i8* %0)
ret void
}
/* Type definitions */
struct stat {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ _STAT_VER;
int true_xstat(int /*<<< orphan*/, char const *, struct stat *);
int true_stat(const char *pathname, struct stat *info) {
  return true_xstat(_STAT_VER, pathname, info);
}


x86 assembly (clang, -O0):
<true_stat>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    0x2eb9(%rip),%rax
mov    (%rax),%edi
mov    -0x8(%rbp),%rsi
mov    -0x10(%rbp),%rdx
call   1030 <true_xstat@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<true_stat>:
mov    %rsi,%rdx
mov    %rdi,%rsi
mov    0x2ec3(%rip),%rax
mov    (%rax),%edi
jmp    1030 <true_xstat@plt>

LLVM IR (-O0):
%struct.stat = type { i32 }
@_STAT_VER = global i32 0
define i32 @true_stat(i8* %0, %struct.stat* %1) {
%3 = alloca i8*
%4 = alloca %struct.stat*
store i8* %0, i8** %3
store %struct.stat* %1, %struct.stat** %4
%5 = load i32, i32* @_STAT_VER
%6 = load i8*, i8** %3
%7 = load %struct.stat*, %struct.stat** %4
%8 = call i32 @true_xstat(i32 %5, i8* %6, %struct.stat* %7)
ret i32 %8
}

LLVM IR (-O2):
%struct.stat = type { i32 }
@_STAT_VER = global i32 0
define i32 @true_stat(i8* %0, %struct.stat* %1) {
%3 = load i32, i32* @_STAT_VER
%4 = tail call i32 @true_xstat(i32 %3, i8* %0, %struct.stat* %1)
ret i32 %4
}
/* Variables and functions */
int /*<<< orphan*/ setPixel(short, short, char);
void pencil(short x, short y, char color) { setPixel(x, y, color); }


x86 assembly (clang, -O0):
<pencil>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %dl,%al
mov    %si,%cx
mov    %di,%dx
mov    %dx,-0x2(%rbp)
mov    %cx,-0x4(%rbp)
mov    %al,-0x5(%rbp)
mov    -0x2(%rbp),%cx
mov    -0x4(%rbp),%ax
movswl %cx,%edi
movswl %ax,%esi
movsbl -0x5(%rbp),%edx
call   1030 <setPixel@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<pencil>:
jmp    1030 <setPixel@plt>

LLVM IR (-O0):
define void @pencil(i16 signext %0, i16 signext %1, i8 signext %2) {
%4 = alloca i16
%5 = alloca i16
%6 = alloca i8
store i16 %0, i16* %4
store i16 %1, i16* %5
store i8 %2, i8* %6
%7 = load i16, i16* %4
%8 = load i16, i16* %5
%9 = load i8, i8* %6
%10 = call i32 @setPixel(i16 signext %7, i16 signext %8, i8 signext %9)
ret void
}

LLVM IR (-O2):
define void @pencil(i16 signext %0, i16 signext %1, i8 signext %2) {
%4 = tail call i32 @setPixel(i16 signext %0, i16 signext %1, i8 signext %2)
ret void
}
void pipe_write() { return; }


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

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

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

LLVM IR (-O2):
define void @pipe_write() {
ret void
}
unsigned int get_le32(unsigned int v_) {
  const unsigned char *v = (const unsigned char *)&v_;
  unsigned int r = v[3];
  r <<= 8;
  r |= v[2];
  r <<= 8;
  r |= v[1];
  r <<= 8;
  r |= v[0];
  return r;
}


x86 assembly (clang, -O0):
<get_le32>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
lea    -0x4(%rbp),%rax
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rax
movzbl 0x3(%rax),%eax
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%eax
shl    $0x8,%eax
mov    %eax,-0x14(%rbp)
mov    -0x10(%rbp),%rax
movzbl 0x2(%rax),%eax
or     -0x14(%rbp),%eax
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%eax
shl    $0x8,%eax
mov    %eax,-0x14(%rbp)
mov    -0x10(%rbp),%rax
movzbl 0x1(%rax),%eax
or     -0x14(%rbp),%eax
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%eax
shl    $0x8,%eax
mov    %eax,-0x14(%rbp)
mov    -0x10(%rbp),%rax
movzbl (%rax),%eax
or     -0x14(%rbp),%eax
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%eax
pop    %rbp
ret

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

LLVM IR (-O0):
define i32 @get_le32(i32 %0) {
%2 = alloca i32
%3 = alloca i8*
%4 = alloca i32
store i32 %0, i32* %2
%5 = bitcast i32* %2 to i8*
store i8* %5, i8** %3
%6 = load i8*, i8** %3
%7 = getelementptr inbounds i8, i8* %6, i64 3
%8 = load i8, i8* %7
%9 = zext i8 %8 to i32
store i32 %9, i32* %4
%10 = load i32, i32* %4
%11 = shl i32 %10, 8
store i32 %11, i32* %4
%12 = load i8*, i8** %3
%13 = getelementptr inbounds i8, i8* %12, i64 2
%14 = load i8, i8* %13
%15 = zext i8 %14 to i32
%16 = load i32, i32* %4
%17 = or i32 %16, %15
store i32 %17, i32* %4
%18 = load i32, i32* %4
%19 = shl i32 %18, 8
store i32 %19, i32* %4
%20 = load i8*, i8** %3
%21 = getelementptr inbounds i8, i8* %20, i64 1
%22 = load i8, i8* %21
%23 = zext i8 %22 to i32
%24 = load i32, i32* %4
%25 = or i32 %24, %23
store i32 %25, i32* %4
%26 = load i32, i32* %4
%27 = shl i32 %26, 8
store i32 %27, i32* %4
%28 = load i8*, i8** %3
%29 = getelementptr inbounds i8, i8* %28, i64 0
%30 = load i8, i8* %29
%31 = zext i8 %30 to i32
%32 = load i32, i32* %4
%33 = or i32 %32, %31
store i32 %33, i32* %4
%34 = load i32, i32* %4
ret i32 %34
}

LLVM IR (-O2):
define i32 @get_le32(i32 returned %0) {
ret i32 %0
}
int dist2_i(int x1, int y1, int x2, int y2) {
  return (x1 - x2) * (x1 - x2) + (y1 - y2) * (y1 - y2);
}


x86 assembly (clang, -O0):
<dist2_i>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %ecx,-0x10(%rbp)
mov    -0x4(%rbp),%eax
sub    -0xc(%rbp),%eax
mov    -0x4(%rbp),%ecx
sub    -0xc(%rbp),%ecx
imul   %ecx,%eax
mov    -0x8(%rbp),%ecx
sub    -0x10(%rbp),%ecx
mov    -0x8(%rbp),%edx
sub    -0x10(%rbp),%edx
imul   %edx,%ecx
add    %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<dist2_i>:
sub    %edx,%edi
imul   %edi,%edi
sub    %ecx,%esi
imul   %esi,%esi
lea    (%rsi,%rdi,1),%eax
ret

LLVM IR (-O0):
define i32 @dist2_i(i32 %0, i32 %1, i32 %2, i32 %3) {
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
store i32 %0, i32* %5
store i32 %1, i32* %6
store i32 %2, i32* %7
store i32 %3, i32* %8
%9 = load i32, i32* %5
%10 = load i32, i32* %7
%11 = sub nsw i32 %9, %10
%12 = load i32, i32* %5
%13 = load i32, i32* %7
%14 = sub nsw i32 %12, %13
%15 = mul nsw i32 %11, %14
%16 = load i32, i32* %6
%17 = load i32, i32* %8
%18 = sub nsw i32 %16, %17
%19 = load i32, i32* %6
%20 = load i32, i32* %8
%21 = sub nsw i32 %19, %20
%22 = mul nsw i32 %18, %21
%23 = add nsw i32 %15, %22
ret i32 %23
}

LLVM IR (-O2):
define i32 @dist2_i(i32 %0, i32 %1, i32 %2, i32 %3) {
%5 = sub nsw i32 %0, %2
%6 = mul nsw i32 %5, %5
%7 = sub nsw i32 %1, %3
%8 = mul nsw i32 %7, %7
%9 = add nuw nsw i32 %8, %6
ret i32 %9
}
/* Type definitions */
struct pattern {
  int dummy;
};

/* Variables and functions */
int countlib(int);
int offset(int /*<<< orphan*/, int, int, int);
int autohelperowl_attackpat81(struct pattern *patt, int transformation,
                              int move, int color, int action) {
  int A;
  (void)patt;
  (void)color;
  (void)action;
  A = offset(0, 2, move, transformation);
  return countlib(A) > 1;
}


x86 assembly (clang, -O0):
<autohelperowl_attackpat81>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %edx,-0x10(%rbp)
mov    %ecx,-0x14(%rbp)
mov    %r8d,-0x18(%rbp)
mov    -0x10(%rbp),%edx
mov    -0xc(%rbp),%ecx
xor    %edi,%edi
mov    $0x2,%esi
call   1030 <offset@plt>
mov    %eax,-0x1c(%rbp)
mov    -0x1c(%rbp),%edi
call   1040 <countlib@plt>
cmp    $0x1,%eax
setg   %al
and    $0x1,%al
movzbl %al,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<autohelperowl_attackpat81>:
push   %rax
mov    %esi,%ecx
xor    %edi,%edi
mov    $0x2,%esi
call   1030 <offset@plt>
mov    %eax,%edi
call   1040 <countlib@plt>
xor    %ecx,%ecx
cmp    $0x2,%eax
setge  %cl
mov    %ecx,%eax
pop    %rcx
ret

LLVM IR (-O0):
%struct.pattern = type { i32 }
define i32 @autohelperowl_attackpat81(%struct.pattern* %0, i32 %1, i32 %2, i32 %3, i32 %4) {
%6 = alloca %struct.pattern*
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
%11 = alloca i32
store %struct.pattern* %0, %struct.pattern** %6
store i32 %1, i32* %7
store i32 %2, i32* %8
store i32 %3, i32* %9
store i32 %4, i32* %10
%12 = load %struct.pattern*, %struct.pattern** %6
%13 = load i32, i32* %9
%14 = load i32, i32* %10
%15 = load i32, i32* %8
%16 = load i32, i32* %7
%17 = call i32 @offset(i32 0, i32 2, i32 %15, i32 %16)
store i32 %17, i32* %11
%18 = load i32, i32* %11
%19 = call i32 @countlib(i32 %18)
%20 = icmp sgt i32 %19, 1
%21 = zext i1 %20 to i32
ret i32 %21
}

LLVM IR (-O2):
%struct.pattern = type { i32 }
define i32 @autohelperowl_attackpat81(%struct.pattern* nocapture readnone %0, i32 %1, i32 %2, i32 %3, i32 %4) {
%6 = tail call i32 @offset(i32 0, i32 2, i32 %2, i32 %1)
%7 = tail call i32 @countlib(i32 %6)
%8 = icmp sgt i32 %7, 1
%9 = zext i1 %8 to i32
ret i32 %9
}