xunge/DecIR huggingface dataset:
/* Type definitions */
typedef int uint32_t;

/* Variables and functions */
uint32_t hash_jenkins_32b(uint32_t a) {
  a -= (a << 6);
  a ^= (a >> 17);
  a -= (a << 9);
  a ^= (a << 4);
  a -= (a << 3);
  a ^= (a << 10);
  a ^= (a >> 15);
  return a;
}


x86 assembly (clang, -O0):
<hash_jenkins_32b>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%ecx
shl    $0x6,%ecx
mov    -0x4(%rbp),%eax
sub    %ecx,%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
sar    $0x11,%eax
xor    -0x4(%rbp),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%ecx
shl    $0x9,%ecx
mov    -0x4(%rbp),%eax
sub    %ecx,%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
shl    $0x4,%eax
xor    -0x4(%rbp),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%ecx
shl    $0x3,%ecx
mov    -0x4(%rbp),%eax
sub    %ecx,%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
shl    $0xa,%eax
xor    -0x4(%rbp),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
sar    $0xf,%eax
xor    -0x4(%rbp),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<hash_jenkins_32b>:
mov    %edi,%eax
shl    $0x6,%eax
sub    %eax,%edi
mov    %edi,%ecx
sar    $0x11,%ecx
xor    %edi,%ecx
mov    %ecx,%eax
shl    $0x9,%eax
imul   $0xffffe010,%ecx,%edx
sub    %eax,%ecx
xor    %edx,%ecx
lea    0x0(,%rcx,8),%eax
imul   $0xffffe400,%ecx,%edx
sub    %eax,%ecx
xor    %edx,%ecx
mov    %ecx,%eax
sar    $0xf,%eax
xor    %ecx,%eax
ret

LLVM IR (-O0):
define i32 @hash_jenkins_32b(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = shl i32 %3, 6
%5 = load i32, i32* %2
%6 = sub nsw i32 %5, %4
store i32 %6, i32* %2
%7 = load i32, i32* %2
%8 = ashr i32 %7, 17
%9 = load i32, i32* %2
%10 = xor i32 %9, %8
store i32 %10, i32* %2
%11 = load i32, i32* %2
%12 = shl i32 %11, 9
%13 = load i32, i32* %2
%14 = sub nsw i32 %13, %12
store i32 %14, i32* %2
%15 = load i32, i32* %2
%16 = shl i32 %15, 4
%17 = load i32, i32* %2
%18 = xor i32 %17, %16
store i32 %18, i32* %2
%19 = load i32, i32* %2
%20 = shl i32 %19, 3
%21 = load i32, i32* %2
%22 = sub nsw i32 %21, %20
store i32 %22, i32* %2
%23 = load i32, i32* %2
%24 = shl i32 %23, 10
%25 = load i32, i32* %2
%26 = xor i32 %25, %24
store i32 %26, i32* %2
%27 = load i32, i32* %2
%28 = ashr i32 %27, 15
%29 = load i32, i32* %2
%30 = xor i32 %29, %28
store i32 %30, i32* %2
%31 = load i32, i32* %2
ret i32 %31
}

LLVM IR (-O2):
define i32 @hash_jenkins_32b(i32 %0) {
%2 = mul i32 %0, -63
%3 = ashr i32 %2, 17
%4 = xor i32 %3, %2
%5 = mul i32 %4, -511
%6 = mul i32 %4, -8176
%7 = xor i32 %5, %6
%8 = mul i32 %7, -7
%9 = mul i32 %7, -7168
%10 = xor i32 %8, %9
%11 = ashr i32 %10, 15
%12 = xor i32 %11, %10
ret i32 %12
}
/* Type definitions */
typedef int uint8_t;

/* Variables and functions */
uint8_t vlsi_fifo_ready() { return 1; }


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

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

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

LLVM IR (-O2):
define i32 @vlsi_fifo_ready() {
ret i32 1
}
/* Variables and functions */
int _ada_use_c2phc4c(int, int *, int *, double *, int /*<<< orphan*/);
int solcon_retrieve_next_dobldobl_initialize(void) {
  int a, *b, fail;
  double *c;
  a = 0;
  fail = _ada_use_c2phc4c(277, &a, b, c, 0);
  return fail;
}


x86 assembly (clang, -O0):
<solcon_retrieve_next_dobldobl_initialize>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    -0x10(%rbp),%rdx
mov    -0x20(%rbp),%rcx
mov    $0x115,%edi
lea    -0x4(%rbp),%rsi
xor    %r8d,%r8d
call   1030 <_ada_use_c2phc4c@plt>
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<solcon_retrieve_next_dobldobl_initialize>:
push   %rax
movl   $0x0,0x4(%rsp)
lea    0x4(%rsp),%rsi
mov    $0x115,%edi
xor    %r8d,%r8d
call   1030 <_ada_use_c2phc4c@plt>
pop    %rcx
ret

LLVM IR (-O0):
define i32 @solcon_retrieve_next_dobldobl_initialize() {
%1 = alloca i32
%2 = alloca i32*
%3 = alloca i32
%4 = alloca double*
store i32 0, i32* %1
%5 = load i32*, i32** %2
%6 = load double*, double** %4
%7 = call i32 @_ada_use_c2phc4c(i32 277, i32* %1, i32* %5, double* %6, i32 0)
store i32 %7, i32* %3
%8 = load i32, i32* %3
ret i32 %8
}

LLVM IR (-O2):
define i32 @solcon_retrieve_next_dobldobl_initialize() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
store i32 0, i32* %1
%3 = call i32 @_ada_use_c2phc4c(i32 277, i32* %1, i32* undef, double* undef, i32 0)
ret i32 %3
}
int test_imm_32uint64_midword_mem(unsigned long long *val) {
  return ((*val >> 16) & (0x32 << 0)) ? -20 : -40;
}


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

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

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

LLVM IR (-O2):
define i32 @test_imm_32uint64_midword_mem(i64* nocapture %0) {
%2 = load i64, i64* %0
%3 = and i64 %2, 3276800
%4 = icmp eq i64 %3, 0
%5 = select i1 %4, i32 -40, i32 -20
ret i32 %5
}
/* Variables and functions */
float power(float, int);
float volume(float raio) {
  float V;
  float r;
  r = power(raio, 3);
  V = (4 * 3.14 * r) / 3;
  return V;
}


x86 assembly (clang, -O0):
<volume>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
mov    $0x3,%edi
call   1030 <power@plt>
movss  %xmm0,-0xc(%rbp)
movss  -0xc(%rbp),%xmm0
cvtss2sd %xmm0,%xmm1
movsd  0xec6(%rip),%xmm0
mulsd  %xmm1,%xmm0
movsd  0xeb2(%rip),%xmm1
divsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,-0x8(%rbp)
movss  -0x8(%rbp),%xmm0
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<volume>:
push   %rax
mov    $0x3,%edi
call   1030 <power@plt>
cvtss2sd %xmm0,%xmm0
mulsd  0xed9(%rip),%xmm0
divsd  0xed9(%rip),%xmm0
cvtsd2ss %xmm0,%xmm0
pop    %rax
ret

LLVM IR (-O0):
define float @volume(float %0) {
%2 = alloca float
%3 = alloca float
%4 = alloca float
store float %0, float* %2
%5 = load float, float* %2
%6 = call float @power(float %5, i32 3)
store float %6, float* %4
%7 = load float, float* %4
%8 = fpext float %7 to double
%9 = fmul double 1.256000e+01, %8
%10 = fdiv double %9, 3.000000e+00
%11 = fptrunc double %10 to float
store float %11, float* %3
%12 = load float, float* %3
ret float %12
}

LLVM IR (-O2):
define float @volume(float %0) {
%2 = tail call float @power(float %0, i32 3)
%3 = fpext float %2 to double
%4 = fmul double %3, 1.256000e+01
%5 = fdiv double %4, 3.000000e+00
%6 = fptrunc double %5 to float
ret float %6
}
int test_imm_E6int32_mem(int *val) {
  return ((*val) & (0xE6 << 0)) ? -20 : -40;
}


x86 assembly (clang, -O0):
<test_imm_E6int32_mem>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%edx
and    $0xe6,%edx
mov    $0xffffffd8,%eax
mov    $0xffffffec,%ecx
cmp    $0x0,%edx
cmovne %ecx,%eax
pop    %rbp
ret

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

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

LLVM IR (-O2):
define i32 @test_imm_E6int32_mem(i32* nocapture %0) {
%2 = load i32, i32* %0
%3 = and i32 %2, 230
%4 = icmp eq i32 %3, 0
%5 = select i1 %4, i32 -40, i32 -20
ret i32 %5
}
void gtk_about_dialog_set_email_hook() {}


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

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

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

LLVM IR (-O2):
define void @gtk_about_dialog_set_email_hook() {
ret void
}
/* Variables and functions */
int __infer_nondet_int();
int isalnum(int x) { return __infer_nondet_int(); }


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

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

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

LLVM IR (-O2):
define i32 @isalnum(i32 %0) {
%2 = tail call i32 (...) @__infer_nondet_int()
ret i32 %2
}
/* Variables and functions */
int toascii(char);
int getsn1(char *str) {
  int i;
  int sum;
  sum = 0;
  for (i = 0; i < 5; i++) {
    sum = sum + toascii(str[i]);
  }
  return sum;
}


x86 assembly (clang, -O0):
<getsn1>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
movl   $0x0,-0x10(%rbp)
movl   $0x0,-0xc(%rbp)
cmpl   $0x5,-0xc(%rbp)
jge    1163 <getsn1+0x53>
mov    -0x10(%rbp),%eax
mov    %eax,-0x14(%rbp)
mov    -0x8(%rbp),%rax
movslq -0xc(%rbp),%rcx
movsbl (%rax,%rcx,1),%edi
call   1030 <toascii@plt>
mov    %eax,%ecx
mov    -0x14(%rbp),%eax
add    %ecx,%eax
mov    %eax,-0x10(%rbp)
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    112a <getsn1+0x1a>
mov    -0x10(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<getsn1>:
push   %rbp
push   %r15
push   %r14
push   %rbx
push   %rax
mov    %rdi,%r15
movsbl (%rdi),%edi
call   1030 <toascii@plt>
mov    %eax,%r14d
movsbl 0x1(%r15),%edi
call   1030 <toascii@plt>
mov    %eax,%ebp
add    %r14d,%ebp
movsbl 0x2(%r15),%edi
call   1030 <toascii@plt>
mov    %eax,%ebx
add    %ebp,%ebx
movsbl 0x3(%r15),%edi
call   1030 <toascii@plt>
mov    %eax,%ebp
add    %ebx,%ebp
movsbl 0x4(%r15),%edi
call   1030 <toascii@plt>
add    %ebp,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
ret

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

LLVM IR (-O2):
define i32 @getsn1(i8* nocapture %0) {
%2 = load i8, i8* %0
%3 = tail call i32 @toascii(i8 signext %2)
%4 = getelementptr inbounds i8, i8* %0, i64 1
%5 = load i8, i8* %4
%6 = tail call i32 @toascii(i8 signext %5)
%7 = add nsw i32 %6, %3
%8 = getelementptr inbounds i8, i8* %0, i64 2
%9 = load i8, i8* %8
%10 = tail call i32 @toascii(i8 signext %9)
%11 = add nsw i32 %10, %7
%12 = getelementptr inbounds i8, i8* %0, i64 3
%13 = load i8, i8* %12
%14 = tail call i32 @toascii(i8 signext %13)
%15 = add nsw i32 %14, %11
%16 = getelementptr inbounds i8, i8* %0, i64 4
%17 = load i8, i8* %16
%18 = tail call i32 @toascii(i8 signext %17)
%19 = add nsw i32 %18, %15
ret i32 %19
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, char const *);
void emit_unit_begin(const char *basename) {
  printf("\t.file\t\"%s\"\n", basename);
}


x86 assembly (clang, -O0):
<emit_unit_begin>:
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):
<emit_unit_begin>:
mov    %rdi,%rsi
lea    0xee6(%rip),%rdi
jmp    1030 <printf@plt>

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

LLVM IR (-O2):
@.str = [13 x i8] c"\09.file\09\22%s\22\0A\00"
define void @emit_unit_begin(i8* %0) {
%2 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i8* %0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ put(int /*<<< orphan*/);
void prs(char *s) {
  while (*s != '\0')
    put(*s++);
}


x86 assembly (clang, -O0):
<prs>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x0,%eax
je     1148 <prs+0x38>
mov    -0x8(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x8(%rbp)
movsbl (%rax),%edi
call   1030 <put@plt>
jmp    111c <prs+0xc>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<prs>:
push   %rbx
mov    (%rdi),%al
test   %al,%al
je     1133 <prs+0x23>
mov    %rdi,%rbx
add    $0x1,%rbx
xchg   %ax,%ax
movsbl %al,%edi
call   1030 <put@plt>
movzbl (%rbx),%eax
add    $0x1,%rbx
test   %al,%al
jne    1120 <prs+0x10>
pop    %rbx
ret

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

LLVM IR (-O2):
define void @prs(i8* nocapture %0) {
%2 = load i8, i8* %0
%3 = icmp eq i8 %2, 0
br i1 %3, label %12, label %4
4: ; preds = %1, %4
%5 = phi i8 [ %10, %4 ], [ %2, %1 ]
%6 = phi i8* [ %8, %4 ], [ %0, %1 ]
%7 = sext i8 %5 to i32
%8 = getelementptr inbounds i8, i8* %6, i64 1
%9 = tail call i32 @put(i32 %7)
%10 = load i8, i8* %8
%11 = icmp eq i8 %10, 0
br i1 %11, label %12, label %4
12: ; preds = %4, %1
ret void
}
void Sys_Mkdir(const char *path) {}


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

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

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

LLVM IR (-O2):
define void @Sys_Mkdir(i8* nocapture %0) {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
void set_lock_status() {
  printf("This feature is disabled by administrative policy. This setting\n");
  printf("can be modified using the physical link interface.\n");
}


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

x86 assembly (clang, -O2):
<set_lock_status>:
push   %rax
lea    0xee8(%rip),%rdi
call   1030 <puts@plt>
lea    0xf1c(%rip),%rdi
pop    %rax
jmp    1030 <puts@plt>

LLVM IR (-O0):
@.str = [65 x i8] c"This feature is disabled by administrative policy. This setting\0A\00"
@.str.1 = [52 x i8] c"can be modified using the physical link interface.\0A\00"
define void @set_lock_status() {
%1 = call i32 @printf(i8* getelementptr inbounds ([65 x i8], [65 x i8]* @.str, i64 0, i64 0))
%2 = call i32 @printf(i8* getelementptr inbounds ([52 x i8], [52 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@str = [64 x i8] c"This feature is disabled by administrative policy. This setting\00"
@str.2 = [51 x i8] c"can be modified using the physical link interface.\00"
define void @set_lock_status() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([64 x i8], [64 x i8]* @str, i64 0, i64 0))
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([51 x i8], [51 x i8]* @str.2, i64 0, i64 0))
ret void
}
/* Type definitions */
typedef int uint8_t;
typedef int uint32_t;

/* Variables and functions */
void dmc_unrar_put_uint32le(uint8_t *data, uint32_t x) {
  data[3] = x >> 24;
  data[2] = x >> 16;
  data[1] = x >> 8;
  data[0] = x;
}


x86 assembly (clang, -O0):
<dmc_unrar_put_uint32le>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0xc(%rbp),%ecx
sar    $0x18,%ecx
mov    -0x8(%rbp),%rax
mov    %ecx,0xc(%rax)
mov    -0xc(%rbp),%ecx
sar    $0x10,%ecx
mov    -0x8(%rbp),%rax
mov    %ecx,0x8(%rax)
mov    -0xc(%rbp),%ecx
sar    $0x8,%ecx
mov    -0x8(%rbp),%rax
mov    %ecx,0x4(%rax)
mov    -0xc(%rbp),%ecx
mov    -0x8(%rbp),%rax
mov    %ecx,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<dmc_unrar_put_uint32le>:
mov    %esi,%eax
sar    $0x18,%eax
mov    %eax,0xc(%rdi)
mov    %esi,%eax
sar    $0x10,%eax
mov    %eax,0x8(%rdi)
mov    %esi,%eax
sar    $0x8,%eax
mov    %eax,0x4(%rdi)
mov    %esi,(%rdi)
ret

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

LLVM IR (-O2):
define void @dmc_unrar_put_uint32le(i32* nocapture writeonly %0, i32 %1) {
%3 = ashr i32 %1, 24
%4 = getelementptr inbounds i32, i32* %0, i64 3
store i32 %3, i32* %4
%5 = ashr i32 %1, 16
%6 = getelementptr inbounds i32, i32* %0, i64 2
store i32 %5, i32* %6
%7 = ashr i32 %1, 8
%8 = getelementptr inbounds i32, i32* %0, i64 1
store i32 %7, i32* %8
store i32 %1, i32* %0
ret void
}
/* Variables and functions */
float div_by_pow_2(double, int);
int /*<<< orphan*/ printf(char *, float);
void main() {
  float y = div_by_pow_2(4.82, 1);
  printf("%f\n", y);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movsd  0xed0(%rip),%xmm0
mov    $0x1,%edi
call   1030 <div_by_pow_2@plt>
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
lea    0xebd(%rip),%rdi
call   1040 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
movsd  0xed7(%rip),%xmm0
mov    $0x1,%edi
call   1030 <div_by_pow_2@plt>
lea    0xece(%rip),%rdi
pop    %rax
jmp    1040 <printf@plt>

LLVM IR (-O0):
@.str = [4 x i8] c"%f\0A\00"
define void @main() {
%1 = alloca float
%2 = call float @div_by_pow_2(double 4.820000e+00, i32 1)
store float %2, float* %1
%3 = load float, float* %1
%4 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), float %3)
ret void
}

LLVM IR (-O2):
@.str = [4 x i8] c"%f\0A\00"
define void @main() {
%1 = tail call float @div_by_pow_2(double 4.820000e+00, i32 1)
%2 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), float %1)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ halt();
char io_getkey();
int /*<<< orphan*/ io_printmap(int);
int /*<<< orphan*/ map_setmessage(char *);
void quit(int printres) {
  map_setmessage("Are you sure you want to quit? (y/n)");
  io_printmap(printres);
  if (io_getkey() == 'y') {
    halt();
  }
  map_setmessage("");
}


x86 assembly (clang, -O0):
<quit>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
lea    0xeae(%rip),%rdi
call   1040 <map_setmessage@plt>
mov    -0x4(%rbp),%edi
call   1060 <io_printmap@plt>
mov    $0x0,%al
call   1030 <io_getkey@plt>
movsbl %al,%eax
cmp    $0x79,%eax
jne    1179 <quit+0x39>
mov    $0x0,%al
call   1050 <halt@plt>
lea    0xea4(%rip),%rdi
call   1040 <map_setmessage@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<quit>:
push   %rbx
mov    %edi,%ebx
lea    0xeb6(%rip),%rdi
call   1040 <map_setmessage@plt>
mov    %ebx,%edi
call   1060 <io_printmap@plt>
xor    %eax,%eax
call   1030 <io_getkey@plt>
cmp    $0x79,%al
jne    1168 <quit+0x28>
xor    %eax,%eax
call   1050 <halt@plt>
lea    0xeb5(%rip),%rdi
pop    %rbx
jmp    1040 <map_setmessage@plt>

LLVM IR (-O0):
@.str = [37 x i8] c"Are you sure you want to quit? (y/n)\00"
@.str.1 = [1 x i8] zeroinitializer
define void @quit(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = call i32 @map_setmessage(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str, i64 0, i64 0))
%4 = load i32, i32* %2
%5 = call i32 @io_printmap(i32 %4)
%6 = call signext i8 (...) @io_getkey()
%7 = sext i8 %6 to i32
%8 = icmp eq i32 %7, 121
br i1 %8, label %9, label %11
9: ; preds = %1
%10 = call i32 (...) @halt()
br label %11
11: ; preds = %9, %1
%12 = call i32 @map_setmessage(i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [37 x i8] c"Are you sure you want to quit? (y/n)\00"
@.str.1 = [1 x i8] zeroinitializer
define void @quit(i32 %0) {
%2 = tail call i32 @map_setmessage(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str, i64 0, i64 0))
%3 = tail call i32 @io_printmap(i32 %0)
%4 = tail call signext i8 (...) @io_getkey()
%5 = icmp eq i8 %4, 121
br i1 %5, label %6, label %8
6: ; preds = %1
%7 = tail call i32 (...) @halt()
br label %8
8: ; preds = %6, %1
%9 = tail call i32 @map_setmessage(i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.1, i64 0, i64 0))
ret void
}
void NV21ToRGB24Row_Any_AVX2() {}


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

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

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

LLVM IR (-O2):
define void @NV21ToRGB24Row_Any_AVX2() {
ret void
}
/* Type definitions */
typedef int uint16_t;
struct p4_field_match_lpm {
  int dummy;
};

/* Variables and functions */
struct p4_field_match_lpm *unpack_p4_field_match_lpm(char *buffer,
                                                     uint16_t offset) {
  return (struct p4_field_match_lpm *)(buffer + offset);
}


x86 assembly (clang, -O0):
<unpack_p4_field_match_lpm>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0x8(%rbp),%rax
movslq -0xc(%rbp),%rcx
add    %rcx,%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<unpack_p4_field_match_lpm>:
movslq %esi,%rax
add    %rdi,%rax
ret

LLVM IR (-O0):
%struct.p4_field_match_lpm = type { i32 }
define %struct.p4_field_match_lpm* @unpack_p4_field_match_lpm(i8* %0, i32 %1) {
%3 = alloca i8*
%4 = alloca i32
store i8* %0, i8** %3
store i32 %1, i32* %4
%5 = load i8*, i8** %3
%6 = load i32, i32* %4
%7 = sext i32 %6 to i64
%8 = getelementptr inbounds i8, i8* %5, i64 %7
%9 = bitcast i8* %8 to %struct.p4_field_match_lpm*
ret %struct.p4_field_match_lpm* %9
}

LLVM IR (-O2):
%struct.p4_field_match_lpm = type { i32 }
define %struct.p4_field_match_lpm* @unpack_p4_field_match_lpm(i8* readnone %0, i32 %1) {
%3 = sext i32 %1 to i64
%4 = getelementptr inbounds i8, i8* %0, i64 %3
%5 = bitcast i8* %4 to %struct.p4_field_match_lpm*
ret %struct.p4_field_match_lpm* %5
}
int test_imm_ECint8_mem(signed char *val) {
  return ((*val) & (0xEC << 0)) ? -20 : -40;
}


x86 assembly (clang, -O0):
<test_imm_ECint8_mem>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
movsbl (%rax),%edx
and    $0xec,%edx
mov    $0xffffffd8,%eax
mov    $0xffffffec,%ecx
cmp    $0x0,%edx
cmovne %ecx,%eax
pop    %rbp
ret

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

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

LLVM IR (-O2):
define i32 @test_imm_ECint8_mem(i8* nocapture %0) {
%2 = load i8, i8* %0
%3 = and i8 %2, -20
%4 = icmp eq i8 %3, 0
%5 = select i1 %4, i32 -40, i32 -20
ret i32 %5
}
double to_rad(double x) { return x * 0.017453292519943295; }


x86 assembly (clang, -O0):
<to_rad>:
push   %rbp
mov    %rsp,%rbp
movsd  %xmm0,-0x8(%rbp)
movsd  0xeef(%rip),%xmm0
mulsd  -0x8(%rbp),%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<to_rad>:
mulsd  0xef8(%rip),%xmm0
ret

LLVM IR (-O0):
define double @to_rad(double %0) {
%2 = alloca double
store double %0, double* %2
%3 = load double, double* %2
%4 = fmul double %3, 0x3F91DF46A2529D39
ret double %4
}

LLVM IR (-O2):
define double @to_rad(double %0) {
%2 = fmul double %0, 0x3F91DF46A2529D39
ret double %2
}
int recv_portal_null(struct PortalInternal *pint, volatile unsigned int *buffer,
                     int len, int *recvfd) {
  return 0;
}


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

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

LLVM IR (-O0):
%struct.PortalInternal = type opaque
define i32 @recv_portal_null(%struct.PortalInternal* %0, i32* %1, i32 %2, i32* %3) {
%5 = alloca %struct.PortalInternal*
%6 = alloca i32*
%7 = alloca i32
%8 = alloca i32*
store %struct.PortalInternal* %0, %struct.PortalInternal** %5
store i32* %1, i32** %6
store i32 %2, i32* %7
store i32* %3, i32** %8
ret i32 0
}

LLVM IR (-O2):
%struct.PortalInternal = type opaque
define i32 @recv_portal_null(%struct.PortalInternal* nocapture readnone %0, i32* nocapture readnone %1, i32 %2, i32* nocapture readnone %3) {
ret i32 0
}
void GPIOMultiplePinsWrite(unsigned int baseAdd, unsigned int setMask,
                           unsigned int clrMask) {
  (*((volatile unsigned int *)(baseAdd + (0x194)))) = setMask;
  (*((volatile unsigned int *)(baseAdd + (0x190)))) = clrMask;
}


x86 assembly (clang, -O0):
<GPIOMultiplePinsWrite>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    -0x8(%rbp),%ecx
mov    -0x4(%rbp),%eax
add    $0x194,%eax
mov    %eax,%eax
mov    %ecx,(%rax)
mov    -0xc(%rbp),%ecx
mov    -0x4(%rbp),%eax
add    $0x190,%eax
mov    %eax,%eax
mov    %ecx,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<GPIOMultiplePinsWrite>:
lea    0x194(%rdi),%eax
mov    %esi,(%rax)
add    $0x190,%edi
mov    %edx,(%rdi)
ret

LLVM IR (-O0):
define void @GPIOMultiplePinsWrite(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* %5
%8 = load i32, i32* %4
%9 = add i32 %8, 404
%10 = zext i32 %9 to i64
%11 = inttoptr i64 %10 to i32*
store volatile i32 %7, i32* %11
%12 = load i32, i32* %6
%13 = load i32, i32* %4
%14 = add i32 %13, 400
%15 = zext i32 %14 to i64
%16 = inttoptr i64 %15 to i32*
store volatile i32 %12, i32* %16
ret void
}

LLVM IR (-O2):
define void @GPIOMultiplePinsWrite(i32 %0, i32 %1, i32 %2) {
%4 = add i32 %0, 404
%5 = zext i32 %4 to i64
%6 = inttoptr i64 %5 to i32*
store volatile i32 %1, i32* %6
%7 = add i32 %0, 400
%8 = zext i32 %7 to i64
%9 = inttoptr i64 %8 to i32*
store volatile i32 %2, i32* %9
ret void
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int /*<<< orphan*/, char *, int, char *);
int /*<<< orphan*/ isascii(int);
void t_isascii_0x4d() {
  Assert_real((isascii(77)),
              "/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_isascii.c",
              390, ("isascii should be 1 for M"));
}


x86 assembly (clang, -O0):
<t_isascii_0x4d>:
push   %rbp
mov    %rsp,%rbp
mov    $0x4d,%edi
call   1030 <isascii@plt>
mov    %eax,%edi
lea    0xec9(%rip),%rsi
mov    $0x186,%edx
lea    0xf65(%rip),%rcx
call   1040 <Assert_real@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<t_isascii_0x4d>:
lea    0xee9(%rip),%rsi
lea    0xf8a(%rip),%rcx
mov    $0x1,%edi
mov    $0x186,%edx
jmp    1030 <Assert_real@plt>

LLVM IR (-O0):
@.str = [168 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_isascii.c\00"
@.str.1 = [26 x i8] c"isascii should be 1 for M\00"
define void @t_isascii_0x4d() {
%1 = call i32 @isascii(i32 77)
%2 = call i32 @Assert_real(i32 %1, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 390, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [168 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_isascii.c\00"
@.str.1 = [26 x i8] c"isascii should be 1 for M\00"
define void @t_isascii_0x4d() {
%1 = tail call i32 @Assert_real(i32 1, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 390, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Variables and functions */
scalar_t__ strchr(char *, char);
int closeparen(char c) {
  if (c && strchr(")", c))
    return 1;
  return 0;
}


x86 assembly (clang, -O0):
<closeparen>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %dil,%al
mov    %al,-0x5(%rbp)
movsbl -0x5(%rbp),%eax
cmp    $0x0,%eax
je     1151 <closeparen+0x41>
lea    0xece(%rip),%rdi
movsbl -0x5(%rbp),%esi
call   1030 <strchr@plt>
cmp    $0x0,%rax
je     1151 <closeparen+0x41>
movl   $0x1,-0x4(%rbp)
jmp    1158 <closeparen+0x48>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<closeparen>:
test   %dil,%dil
je     1139 <closeparen+0x29>
push   %rax
movsbl %dil,%esi
lea    0xedf(%rip),%rdi
call   1030 <strchr@plt>
mov    %rax,%rcx
mov    $0x1,%eax
test   %rcx,%rcx
lea    0x8(%rsp),%rsp
je     1139 <closeparen+0x29>
ret
xor    %eax,%eax
ret

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

LLVM IR (-O2):
@.str = [2 x i8] c")\00"
define i32 @closeparen(i8 signext %0) {
%2 = icmp eq i8 %0, 0
br i1 %2, label %6, label %3
3: ; preds = %1
%4 = tail call i64 @strchr(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0), i8 signext %0)
%5 = icmp eq i64 %4, 0
br i1 %5, label %6, label %7
6: ; preds = %3, %1
br label %7
7: ; preds = %3, %6
%8 = phi i32 [ 0, %6 ], [ 1, %3 ]
ret i32 %8
}
int vlan_tunnel_init(struct net_bridge_vlan_group *vg) { return 0; }


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

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

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

LLVM IR (-O2):
%struct.net_bridge_vlan_group = type opaque
define i32 @vlan_tunnel_init(%struct.net_bridge_vlan_group* nocapture readnone %0) {
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ PB_Cgetbuf(char *, int);
void PB_freebuf_() { (void)PB_Cgetbuf(" ", -1); }


x86 assembly (clang, -O0):
<PB_freebuf_>:
push   %rbp
mov    %rsp,%rbp
lea    0xee5(%rip),%rdi
mov    $0xffffffff,%esi
call   1030 <PB_Cgetbuf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<PB_freebuf_>:
lea    0xee9(%rip),%rdi
mov    $0xffffffff,%esi
jmp    1030 <PB_Cgetbuf@plt>

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

LLVM IR (-O2):
@.str = [2 x i8] c" \00"
define void @PB_freebuf_() {
%1 = tail call i32 @PB_Cgetbuf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0), i32 -1)
ret void
}
/* Forward declarations */
typedef struct TYPE_5__ TYPE_2__;
typedef struct TYPE_4__ TYPE_1__;

/* Type definitions */
struct TYPE_4__ {
  int /*<<< orphan*/ y;
};
struct TYPE_5__ {
  TYPE_1__ max_logical_extent;
};
typedef TYPE_2__ XFontSetExtents;

/* Variables and functions */
int abs(int /*<<< orphan*/);
extern int ascent(XFontSetExtents *font_set_ext) {
  return abs(font_set_ext->max_logical_extent.y);
}


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

x86 assembly (clang, -O2):
<ascent>:
mov    (%rdi),%ecx
mov    %ecx,%eax
neg    %eax
cmovs  %ecx,%eax
ret

LLVM IR (-O0):
%struct.TYPE_5__ = type { %struct.TYPE_4__ }
%struct.TYPE_4__ = type { i32 }
define i32 @ascent(%struct.TYPE_5__* %0) {
%2 = alloca %struct.TYPE_5__*
store %struct.TYPE_5__* %0, %struct.TYPE_5__** %2
%3 = load %struct.TYPE_5__*, %struct.TYPE_5__** %2
%4 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %3, i32 0, i32 0
%5 = getelementptr inbounds %struct.TYPE_4__, %struct.TYPE_4__* %4, i32 0, i32 0
%6 = load i32, i32* %5
%7 = call i32 @abs(i32 %6)
ret i32 %7
}

LLVM IR (-O2):
%struct.TYPE_5__ = type { %struct.TYPE_4__ }
%struct.TYPE_4__ = type { i32 }
define i32 @ascent(%struct.TYPE_5__* nocapture %0) {
%2 = getelementptr inbounds %struct.TYPE_5__, %struct.TYPE_5__* %0, i64 0, i32 0, i32 0
%3 = load i32, i32* %2
%4 = tail call i32 @llvm.abs.i32(i32 %3, i1 true)
ret i32 %4
}
/* Variables and functions */
int atoi(char *);
int /*<<< orphan*/ clear();
int /*<<< orphan*/ print_result(int);
int /*<<< orphan*/ printf(char *, char *);
int main(int argc, char *argv[]) {
  clear();
  int N;
  if (argc == 1)
    printf("usage: %s <size>\n", argv[0]);
  else {
    N = atoi(argv[1]);
    print_result(N);
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    $0x0,%al
call   1060 <clear@plt>
cmpl   $0x1,-0x8(%rbp)
jne    117f <main+0x3f>
mov    -0x10(%rbp),%rax
mov    (%rax),%rsi
lea    0xe8b(%rip),%rdi
call   1030 <printf@plt>
jmp    1197 <main+0x57>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
call   1050 <atoi@plt>
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%edi
call   1040 <print_result@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %rbx
push   %rax
mov    %rsi,%rbx
mov    %edi,%ebp
xor    %eax,%eax
call   1060 <clear@plt>
cmp    $0x1,%ebp
jne    1165 <main+0x25>
mov    (%rbx),%rsi
lea    0xea2(%rip),%rdi
call   1030 <printf@plt>
jmp    1175 <main+0x35>
mov    0x8(%rbx),%rdi
call   1050 <atoi@plt>
mov    %eax,%edi
call   1040 <print_result@plt>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
@.str = [18 x i8] c"usage: %s <size>\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%7 = call i32 (...) @clear()
%8 = load i32, i32* %4
%9 = icmp eq i32 %8, 1
br i1 %9, label %10, label %15
10: ; preds = %2
%11 = load i8**, i8*** %5
%12 = getelementptr inbounds i8*, i8** %11, i64 0
%13 = load i8*, i8** %12
%14 = call i32 @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0), i8* %13)
br label %22
15: ; preds = %2
%16 = load i8**, i8*** %5
%17 = getelementptr inbounds i8*, i8** %16, i64 1
%18 = load i8*, i8** %17
%19 = call i32 @atoi(i8* %18)
store i32 %19, i32* %6
%20 = load i32, i32* %6
%21 = call i32 @print_result(i32 %20)
br label %22
22: ; preds = %15, %10
ret i32 0
}

LLVM IR (-O2):
@.str = [18 x i8] c"usage: %s <size>\0A\00"
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = tail call i32 (...) @clear()
%4 = icmp eq i32 %0, 1
br i1 %4, label %5, label %8
5: ; preds = %2
%6 = load i8*, i8** %1
%7 = tail call i32 @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0), i8* %6)
br label %13
8: ; preds = %2
%9 = getelementptr inbounds i8*, i8** %1, i64 1
%10 = load i8*, i8** %9
%11 = tail call i32 @atoi(i8* %10)
%12 = tail call i32 @print_result(i32 %11)
br label %13
13: ; preds = %8, %5
ret i32 0
}
/* Type definitions */
typedef int /*<<< orphan*/ tmpbuf;

/* Variables and functions */
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ snprintf(char *, int, char *);
void go(char *msg) {
  int i = 0;
  char tmpbuf[512];
  printf("i = %p\n", &i);
  snprintf(tmpbuf, sizeof(tmpbuf), msg);
  tmpbuf[sizeof(tmpbuf) - 1] = '\0';
  printf("msg: %s, i = %d\n", tmpbuf, i);
}


x86 assembly (clang, -O0):
<go>:
push   %rbp
mov    %rsp,%rbp
sub    $0x210,%rsp
mov    %rdi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
lea    0xec3(%rip),%rdi
lea    -0xc(%rbp),%rsi
mov    $0x0,%al
call   1030 <printf@plt>
lea    -0x210(%rbp),%rdi
mov    -0x8(%rbp),%rdx
mov    $0x200,%esi
call   1040 <snprintf@plt>
movb   $0x0,-0x11(%rbp)
lea    -0x210(%rbp),%rsi
mov    -0xc(%rbp),%edx
lea    0xe96(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
add    $0x210,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<go>:
push   %r14
push   %rbx
sub    $0x218,%rsp
mov    %rdi,%rbx
movl   $0x0,0xc(%rsp)
lea    0xec4(%rip),%rdi
lea    0xc(%rsp),%rsi
xor    %eax,%eax
call   1030 <printf@plt>
lea    0x10(%rsp),%r14
mov    %r14,%rdi
mov    $0x200,%esi
mov    %rbx,%rdx
call   1040 <snprintf@plt>
movb   $0x0,0x20f(%rsp)
mov    0xc(%rsp),%edx
lea    0xe98(%rip),%rdi
mov    %r14,%rsi
xor    %eax,%eax
call   1030 <printf@plt>
add    $0x218,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
@.str = [8 x i8] c"i = %p\0A\00"
@.str.1 = [17 x i8] c"msg: %s, i = %d\0A\00"
define void @go(i8* %0) {
%2 = alloca i8*
%3 = alloca i32
%4 = alloca [512 x i8]
store i8* %0, i8** %2
store i32 0, i32* %3
%5 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i32* %3)
%6 = getelementptr inbounds [512 x i8], [512 x i8]* %4, i64 0, i64 0
%7 = load i8*, i8** %2
%8 = call i32 @snprintf(i8* %6, i32 512, i8* %7)
%9 = getelementptr inbounds [512 x i8], [512 x i8]* %4, i64 0, i64 511
store i8 0, i8* %9
%10 = getelementptr inbounds [512 x i8], [512 x i8]* %4, i64 0, i64 0
%11 = load i32, i32* %3
%12 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.1, i64 0, i64 0), i8* %10, i32 %11)
ret void
}

LLVM IR (-O2):
@.str = [8 x i8] c"i = %p\0A\00"
@.str.1 = [17 x i8] c"msg: %s, i = %d\0A\00"
define void @go(i8* %0) {
%2 = alloca i32
%3 = alloca [512 x i8]
%4 = bitcast i32* %2 to i8*
store i32 0, i32* %2
%5 = getelementptr inbounds [512 x i8], [512 x i8]* %3, i64 0, i64 0
%6 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i32* %2)
%7 = call i32 @snprintf(i8* %5, i32 512, i8* %0)
%8 = getelementptr inbounds [512 x i8], [512 x i8]* %3, i64 0, i64 511
store i8 0, i8* %8
%9 = load i32, i32* %2
%10 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([17 x i8], [17 x i8]* @.str.1, i64 0, i64 0), i8* %5, i32 %9)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, char *);
int /*<<< orphan*/ stderr;
void error_print(char *arr) {
  fprintf(
      stderr,
      "\n%s changes the contrast constant gamma for gnuplot formatted file \n",
      arr);
  fprintf(stderr,
          "\nUSAGE: %s n G < file1 > file2\nwhere n is grid sampling, G is the "
          "gamma value\n\n",
          arr);
}


x86 assembly (clang, -O0):
<error_print>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    0x2ebd(%rip),%rax
mov    (%rax),%edi
mov    -0x8(%rbp),%rdx
lea    0xed0(%rip),%rsi
call   1030 <fprintf@plt>
mov    0x2ea4(%rip),%rax
mov    (%rax),%edi
mov    -0x8(%rbp),%rdx
lea    0xefc(%rip),%rsi
call   1030 <fprintf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<error_print>:
push   %r14
push   %rbx
push   %rax
mov    %rdi,%rbx
mov    0x2ec2(%rip),%r14
mov    (%r14),%edi
lea    0xed8(%rip),%rsi
mov    %rbx,%rdx
call   1030 <fprintf@plt>
mov    (%r14),%edi
lea    0xf0b(%rip),%rsi
mov    %rbx,%rdx
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1030 <fprintf@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [69 x i8] c"\0A%s changes the contrast constant gamma for gnuplot formatted file \0A\00"
@.str.1 = [80 x i8] c"\0AUSAGE: %s n G < file1 > file2\0Awhere n is grid sampling, G is the gamma value\0A\0A\00"
define void @error_print(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i32, i32* @stderr
%4 = load i8*, i8** %2
%5 = call i32 @fprintf(i32 %3, i8* getelementptr inbounds ([69 x i8], [69 x i8]* @.str, i64 0, i64 0), i8* %4)
%6 = load i32, i32* @stderr
%7 = load i8*, i8** %2
%8 = call i32 @fprintf(i32 %6, i8* getelementptr inbounds ([80 x i8], [80 x i8]* @.str.1, i64 0, i64 0), i8* %7)
ret void
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [69 x i8] c"\0A%s changes the contrast constant gamma for gnuplot formatted file \0A\00"
@.str.1 = [80 x i8] c"\0AUSAGE: %s n G < file1 > file2\0Awhere n is grid sampling, G is the gamma value\0A\0A\00"
define void @error_print(i8* %0) {
%2 = load i32, i32* @stderr
%3 = tail call i32 @fprintf(i32 %2, i8* getelementptr inbounds ([69 x i8], [69 x i8]* @.str, i64 0, i64 0), i8* %0)
%4 = load i32, i32* @stderr
%5 = tail call i32 @fprintf(i32 %4, i8* getelementptr inbounds ([80 x i8], [80 x i8]* @.str.1, i64 0, i64 0), i8* %0)
ret void
}
/* Variables and functions */
char *strdup(char const *);
char *wbxml_strdup(const char *str) { return strdup(str); }


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

x86 assembly (clang, -O2):
<wbxml_strdup>:
jmp    1030 <strdup@plt>

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

LLVM IR (-O2):
define noalias i8* @wbxml_strdup(i8* nocapture %0) {
%2 = tail call i8* @strdup(i8* %0)
ret i8* %2
}
/* Type definitions */
typedef int int32_t;

/* Variables and functions */
int is_hangul_vpart(int32_t code) {
  return (0x1161 <= code && code < 0x1161 + 21);
}


x86 assembly (clang, -O0):
<is_hangul_vpart>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
xor    %eax,%eax
mov    $0x1161,%ecx
cmp    -0x4(%rbp),%ecx
mov    %al,-0x5(%rbp)
jg     1127 <is_hangul_vpart+0x27>
cmpl   $0x1176,-0x4(%rbp)
setl   %al
mov    %al,-0x5(%rbp)
mov    -0x5(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_hangul_vpart>:
add    $0xffffee9f,%edi
xor    %eax,%eax
cmp    $0x15,%edi
setb   %al
ret

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

LLVM IR (-O2):
define i32 @is_hangul_vpart(i32 %0) {
%2 = add i32 %0, -4449
%3 = icmp ult i32 %2, 21
%4 = zext i1 %3 to i32
ret i32 %4
}
void mdp4_overlay_dsi_video_dma_busy_wait(struct msm_fb_data_type *mfd) {}


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

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

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

LLVM IR (-O2):
%struct.msm_fb_data_type = type opaque
define void @mdp4_overlay_dsi_video_dma_busy_wait(%struct.msm_fb_data_type* nocapture %0) {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int, int, int);
void mul(int f_num1, int f_num2) {
  printf("%d * %d = %d\n", f_num1, f_num2, (f_num1 * f_num2));
}


x86 assembly (clang, -O0):
<mul>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x4(%rbp),%esi
mov    -0x8(%rbp),%edx
mov    -0x4(%rbp),%ecx
imul   -0x8(%rbp),%ecx
lea    0xece(%rip),%rdi
call   1030 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<mul>:
mov    %esi,%edx
mov    %edi,%esi
mov    %edx,%ecx
imul   %edi,%ecx
lea    0xee0(%rip),%rdi
jmp    1030 <printf@plt>

LLVM IR (-O0):
@.str = [14 x i8] c"%d * %d = %d\0A\00"
define void @mul(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 = load i32, i32* %3
%8 = load i32, i32* %4
%9 = mul nsw i32 %7, %8
%10 = call i32 @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0), i32 %5, i32 %6, i32 %9)
ret void
}

LLVM IR (-O2):
@.str = [14 x i8] c"%d * %d = %d\0A\00"
define void @mul(i32 %0, i32 %1) {
%3 = mul nsw i32 %1, %0
%4 = tail call i32 @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0), i32 %0, i32 %1, i32 %3)
ret void
}
/* Variables and functions */
int __VERIFIER_nondet_int();
int /*<<< orphan*/ strlen(char const *);
int strcmp(char const *__s1, char const *__s2) {
  int tmp;
  {
    {
      strlen(__s1);
      strlen(__s2);
      tmp = __VERIFIER_nondet_int();
    }
    return (tmp);
  }
}


x86 assembly (clang, -O0):
<strcmp>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <strlen@plt>
mov    -0x10(%rbp),%rdi
call   1030 <strlen@plt>
mov    $0x0,%al
call   1040 <__VERIFIER_nondet_int@plt>
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<strcmp>:
push   %rbx
mov    %rsi,%rbx
call   1030 <strlen@plt>
mov    %rbx,%rdi
call   1030 <strlen@plt>
xor    %eax,%eax
pop    %rbx
jmp    1040 <__VERIFIER_nondet_int@plt>

LLVM IR (-O0):
define i32 @strcmp(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
%5 = alloca i32
store i8* %0, i8** %3
store i8* %1, i8** %4
%6 = load i8*, i8** %3
%7 = call i32 @strlen(i8* %6)
%8 = load i8*, i8** %4
%9 = call i32 @strlen(i8* %8)
%10 = call i32 (...) @__VERIFIER_nondet_int()
store i32 %10, i32* %5
%11 = load i32, i32* %5
ret i32 %11
}

LLVM IR (-O2):
define i32 @strcmp(i8* %0, i8* %1) {
%3 = tail call i32 @strlen(i8* %0)
%4 = tail call i32 @strlen(i8* %1)
%5 = tail call i32 (...) @__VERIFIER_nondet_int()
ret i32 %5
}
/* Variables and functions */
float sinf(float);
float HMM_SinF(float Radians) {
  float Result = sinf(Radians);
  return (Result);
}


x86 assembly (clang, -O0):
<HMM_SinF>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
call   1030 <sinf@plt>
movss  %xmm0,-0x8(%rbp)
movss  -0x8(%rbp),%xmm0
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<HMM_SinF>:
jmp    1030 <sinf@plt>

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

LLVM IR (-O2):
define float @HMM_SinF(float %0) {
%2 = tail call float @sinf(float %0)
ret float %2
}