xunge/DecIR huggingface dataset:
/* Variables and functions */
int /*<<< orphan*/ __builtin_arm_stc(int, int, void *);
void stc(void *i) { __builtin_arm_stc(1, 2, i); }


x86 assembly (clang, -O0):
<stc>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdx
mov    $0x1,%edi
mov    $0x2,%esi
call   1030 <__builtin_arm_stc@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<stc>:
mov    %rdi,%rdx
mov    $0x1,%edi
mov    $0x2,%esi
jmp    1030 <__builtin_arm_stc@plt>

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

LLVM IR (-O2):
define void @stc(i8* %0) {
%2 = tail call i32 @__builtin_arm_stc(i32 1, i32 2, i8* %0)
ret void
}
double f4_sum_long(long v) { return ((double)(v)); }


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

x86 assembly (clang, -O2):
<f4_sum_long>:
cvtsi2sd %rdi,%xmm0
ret

LLVM IR (-O0):
define double @f4_sum_long(i64 %0) {
%2 = alloca i64
store i64 %0, i64* %2
%3 = load i64, i64* %2
%4 = sitofp i64 %3 to double
ret double %4
}

LLVM IR (-O2):
define double @f4_sum_long(i64 %0) {
%2 = sitofp i64 %0 to double
ret double %2
}
/* Variables and functions */
scalar_t__ exp(scalar_t__);
scalar_t__ factorial_ln(int);
float floor(scalar_t__);
float bico(int n, int k) {
  return floor(0.5 +
               exp(factorial_ln(n) - factorial_ln(k) - factorial_ln(n - k)));
}


x86 assembly (clang, -O0):
<bico>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x4(%rbp),%edi
call   1040 <factorial_ln@plt>
mov    %rax,-0x18(%rbp)
mov    -0x8(%rbp),%edi
call   1040 <factorial_ln@plt>
mov    %rax,%rcx
mov    -0x18(%rbp),%rax
sub    %rcx,%rax
mov    %rax,-0x10(%rbp)
mov    -0x4(%rbp),%edi
sub    -0x8(%rbp),%edi
call   1040 <factorial_ln@plt>
mov    -0x10(%rbp),%rdi
sub    %rax,%rdi
call   1030 <exp@plt>
cvtsi2sd %rax,%xmm1
movsd  0xe7c(%rip),%xmm0
addsd  %xmm1,%xmm0
cvttsd2si %xmm0,%rdi
call   1050 <floor@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<bico>:
push   %rbp
push   %r15
push   %r14
push   %rbx
push   %rax
mov    %esi,%r14d
mov    %edi,%ebp
call   1040 <factorial_ln@plt>
mov    %rax,%rbx
mov    %r14d,%edi
call   1040 <factorial_ln@plt>
mov    %rax,%r15
sub    %r14d,%ebp
mov    %ebp,%edi
call   1040 <factorial_ln@plt>
add    %r15,%rax
sub    %rax,%rbx
mov    %rbx,%rdi
call   1030 <exp@plt>
cvtsi2sd %rax,%xmm0
addsd  0xe8c(%rip),%xmm0
cvttsd2si %xmm0,%rdi
add    $0x8,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
jmp    1050 <floor@plt>

LLVM IR (-O0):
define float @bico(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 = call i64 @factorial_ln(i32 %5)
%7 = load i32, i32* %4
%8 = call i64 @factorial_ln(i32 %7)
%9 = sub nsw i64 %6, %8
%10 = load i32, i32* %3
%11 = load i32, i32* %4
%12 = sub nsw i32 %10, %11
%13 = call i64 @factorial_ln(i32 %12)
%14 = sub nsw i64 %9, %13
%15 = call i64 @exp(i64 %14)
%16 = sitofp i64 %15 to double
%17 = fadd double 5.000000e-01, %16
%18 = fptosi double %17 to i64
%19 = call float @floor(i64 %18)
ret float %19
}

LLVM IR (-O2):
define float @bico(i32 %0, i32 %1) {
%3 = tail call i64 @factorial_ln(i32 %0)
%4 = tail call i64 @factorial_ln(i32 %1)
%5 = sub nsw i32 %0, %1
%6 = tail call i64 @factorial_ln(i32 %5)
%7 = add i64 %4, %6
%8 = sub i64 %3, %7
%9 = tail call i64 @exp(i64 %8)
%10 = sitofp i64 %9 to double
%11 = fadd double %10, 5.000000e-01
%12 = fptosi double %11 to i64
%13 = tail call float @floor(i64 %12)
ret float %13
}
/* Variables and functions */
bool nrf51_errata_20(void) { return false; }


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

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

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

LLVM IR (-O2):
define i32 @nrf51_errata_20() {
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ islower(int);
void t_islower_0xa9() {
  Assert_real((islower(169) == 0),
              "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/"
              "2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/"
              "dg/z88dk/test/suites/ctype/test_islower.c",
              850, ("islower should be 0 for 0xa9"));
}


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

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

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

LLVM IR (-O2):
@.str = [168 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_islower.c\00"
@.str.1 = [29 x i8] c"islower should be 0 for 0xa9\00"
define void @t_islower_0xa9() {
%1 = tail call i64 @islower(i32 169)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = tail call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 850, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Type definitions */
typedef int ssize_t;

/* Variables and functions */
int /*<<< orphan*/ ENOSYS;
int /*<<< orphan*/ __set_errno(int /*<<< orphan*/);
ssize_t flistxattr(int __fd, char *__list, size_t __size) {
  __set_errno(ENOSYS);
  return -1;
}


x86 assembly (clang, -O0):
<flistxattr>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    0x2ebe(%rip),%rax
mov    (%rax),%edi
call   1030 <__set_errno@plt>
mov    $0xffffffff,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<flistxattr>:
push   %rax
mov    0x2ed0(%rip),%rax
mov    (%rax),%edi
call   1030 <__set_errno@plt>
mov    $0xffffffff,%eax
pop    %rcx
ret

LLVM IR (-O0):
@ENOSYS = global i32 0
define i32 @flistxattr(i32 %0, i8* %1, i64 %2) {
%4 = alloca i32
%5 = alloca i8*
%6 = alloca i64
store i32 %0, i32* %4
store i8* %1, i8** %5
store i64 %2, i64* %6
%7 = load i32, i32* @ENOSYS
%8 = call i32 @__set_errno(i32 %7)
ret i32 -1
}

LLVM IR (-O2):
@ENOSYS = global i32 0
define i32 @flistxattr(i32 %0, i8* nocapture readnone %1, i64 %2) {
%4 = load i32, i32* @ENOSYS
%5 = tail call i32 @__set_errno(i32 %4)
ret i32 -1
}
/* Variables and functions */
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *);
int /*<<< orphan*/ stderr;
void usage(void) {
  fprintf(stderr, "Usage: lxc-init [OPTION]...\n\n"
                  "Common options :\n"
                  "  -n, --name=NAME          NAME for name of the container\n"
                  "  -l, --logpriority=LEVEL  Set log priority to LEVEL\n"
                  "  -q, --quiet              Don't produce any output\n"
                  "  -P, --lxcpath=PATH       Use specified container path\n"
                  "  -?, --help               Give this help list\n"
                  "\n"
                  "Mandatory or optional arguments to long options are also "
                  "mandatory or optional\n"
                  "for any corresponding short options.\n"
                  "\n"
                  "NOTE: lxc-init is intended for use by lxc internally\n"
                  "      and does not need to be run by hand\n\n");
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
mov    0x2ec5(%rip),%rax
mov    (%rax),%edi
lea    0xedc(%rip),%rsi
call   1030 <fprintf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<usage>:
mov    0x2ec9(%rip),%rax
mov    (%rax),%edi
lea    0xee0(%rip),%rsi
jmp    1030 <fprintf@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [527 x i8] c"Usage: lxc-init [OPTION]...\0A\0ACommon options :\0A -n, --name=NAME NAME for name of the container\0A -l, --logpriority=LEVEL Set log priority to LEVEL\0A -q, --quiet Don't produce any output\0A -P, --lxcpath=PATH Use specified container path\0A -?, --help Give this help list\0A\0AMandatory or optional arguments to long options are also mandatory or optional\0Afor any corresponding short options.\0A\0ANOTE: lxc-init is intended for use by lxc internally\0A and does not need to be run by hand\0A\0A\00"
define void @usage() {
%1 = load i32, i32* @stderr
%2 = call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([527 x i8], [527 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [527 x i8] c"Usage: lxc-init [OPTION]...\0A\0ACommon options :\0A -n, --name=NAME NAME for name of the container\0A -l, --logpriority=LEVEL Set log priority to LEVEL\0A -q, --quiet Don't produce any output\0A -P, --lxcpath=PATH Use specified container path\0A -?, --help Give this help list\0A\0AMandatory or optional arguments to long options are also mandatory or optional\0Afor any corresponding short options.\0A\0ANOTE: lxc-init is intended for use by lxc internally\0A and does not need to be run by hand\0A\0A\00"
define void @usage() {
%1 = load i32, i32* @stderr
%2 = tail call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([527 x i8], [527 x i8]* @.str, i64 0, i64 0))
ret void
}
/* Variables and functions */
bool is_hex_digit(char c) {
  return ((c >= 'a' && c <= 'f') || (c >= 'A' && c <= 'F')) ||
         (c >= '0' && c <= '9');
}


x86 assembly (clang, -O0):
<is_hex_digit>:
push   %rbp
mov    %rsp,%rbp
mov    %dil,%al
mov    %al,-0x1(%rbp)
movsbl -0x1(%rbp),%eax
cmp    $0x61,%eax
jl     1129 <is_hex_digit+0x29>
movsbl -0x1(%rbp),%ecx
mov    $0x1,%al
cmp    $0x66,%ecx
mov    %al,-0x2(%rbp)
jle    116d <is_hex_digit+0x6d>
movsbl -0x1(%rbp),%eax
cmp    $0x41,%eax
jl     1148 <is_hex_digit+0x48>
movsbl -0x1(%rbp),%ecx
mov    $0x1,%al
cmp    $0x46,%ecx
mov    %al,-0x2(%rbp)
jle    116d <is_hex_digit+0x6d>
movsbl -0x1(%rbp),%ecx
xor    %eax,%eax
cmp    $0x30,%ecx
mov    %al,-0x3(%rbp)
jl     1167 <is_hex_digit+0x67>
movsbl -0x1(%rbp),%eax
cmp    $0x39,%eax
setle  %al
mov    %al,-0x3(%rbp)
mov    -0x3(%rbp),%al
mov    %al,-0x2(%rbp)
mov    -0x2(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_hex_digit>:
mov    %edi,%eax
and    $0xdf,%al
add    $0xbf,%al
cmp    $0x6,%al
setb   %al
add    $0xd0,%dil
cmp    $0xa,%dil
setb   %cl
or     %al,%cl
movzbl %cl,%eax
ret

LLVM IR (-O0):
define i32 @is_hex_digit(i8 signext %0) {
%2 = alloca i8
store i8 %0, i8* %2
%3 = load i8, i8* %2
%4 = sext i8 %3 to i32
%5 = icmp sge i32 %4, 97
br i1 %5, label %6, label %10
6: ; preds = %1
%7 = load i8, i8* %2
%8 = sext i8 %7 to i32
%9 = icmp sle i32 %8, 102
br i1 %9, label %28, label %10
10: ; preds = %6, %1
%11 = load i8, i8* %2
%12 = sext i8 %11 to i32
%13 = icmp sge i32 %12, 65
br i1 %13, label %14, label %18
14: ; preds = %10
%15 = load i8, i8* %2
%16 = sext i8 %15 to i32
%17 = icmp sle i32 %16, 70
br i1 %17, label %28, label %18
18: ; preds = %14, %10
%19 = load i8, i8* %2
%20 = sext i8 %19 to i32
%21 = icmp sge i32 %20, 48
br i1 %21, label %22, label %26
22: ; preds = %18
%23 = load i8, i8* %2
%24 = sext i8 %23 to i32
%25 = icmp sle i32 %24, 57
br label %26
26: ; preds = %22, %18
%27 = phi i1 [ false, %18 ], [ %25, %22 ]
br label %28
28: ; preds = %26, %14, %6
%29 = phi i1 [ true, %14 ], [ true, %6 ], [ %27, %26 ]
%30 = zext i1 %29 to i32
ret i32 %30
}

LLVM IR (-O2):
define i32 @is_hex_digit(i8 signext %0) {
%2 = and i8 %0, -33
%3 = add i8 %2, -65
%4 = icmp ult i8 %3, 6
%5 = add i8 %0, -48
%6 = icmp ult i8 %5, 10
%7 = or i1 %6, %4
%8 = zext i1 %7 to i32
ret i32 %8
}
void d2i_ASN1_OCTET_STRING(void) {}


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

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

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

LLVM IR (-O2):
define void @d2i_ASN1_OCTET_STRING() {
ret void
}
int f_ble_cr2(float a1) { return !(__builtin_islessequal(100, a1)); }


x86 assembly (clang, -O0):
<f_ble_cr2>:
push   %rbp
mov    %rsp,%rbp
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
movss  0xeea(%rip),%xmm1
ucomiss %xmm1,%xmm0
setae  %al
xor    $0xff,%al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<f_ble_cr2>:
xor    %eax,%eax
ucomiss 0xef7(%rip),%xmm0
setb   %al
ret

LLVM IR (-O0):
define i32 @f_ble_cr2(float %0) {
%2 = alloca float
store float %0, float* %2
%3 = load float, float* %2
%4 = fcmp ole float 1.000000e+02, %3
%5 = xor i1 %4, true
%6 = zext i1 %5 to i32
ret i32 %6
}

LLVM IR (-O2):
define i32 @f_ble_cr2(float %0) {
%2 = fcmp ult float %0, 1.000000e+02
%3 = zext i1 %2 to i32
ret i32 %3
}
/* Type definitions */
typedef int /*<<< orphan*/ uint64_t;

/* Variables and functions */
int /*<<< orphan*/ __builtin_arm_wsr64(char *, int /*<<< orphan*/);
void wsr64(uint64_t v) { __builtin_arm_wsr64("1:2:3:4:5", v); }


x86 assembly (clang, -O0):
<wsr64>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%esi
lea    0xedb(%rip),%rdi
call   1030 <__builtin_arm_wsr64@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<wsr64>:
mov    %edi,%esi
lea    0xee7(%rip),%rdi
jmp    1030 <__builtin_arm_wsr64@plt>

LLVM IR (-O0):
@.str = [10 x i8] c"1:2:3:4:5\00"
define void @wsr64(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = call i32 @__builtin_arm_wsr64(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), i32 %3)
ret void
}

LLVM IR (-O2):
@.str = [10 x i8] c"1:2:3:4:5\00"
define void @wsr64(i32 %0) {
%2 = tail call i32 @__builtin_arm_wsr64(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), i32 %0)
ret void
}
/* Variables and functions */
int rom_present(char *);
int s3_diamond_stealth64_764_available(void) {
  return rom_present(L"roms/video/s3/stealt64.bin");
}


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

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

LLVM IR (-O0):
@.str = [27 x i32] [i32 114, i32 111, i32 109, i32 115, i32 47, i32 118, i32 105, i32 100, i32 101, i32 111, i32 47, i32 115, i32 51, i32 47, i32 115, i32 116, i32 101, i32 97, i32 108, i32 116, i32 54, i32 52, i32 46, i32 98, i32 105, i32 110, i32 0]
define i32 @s3_diamond_stealth64_764_available() {
%1 = call i32 @rom_present(i8* bitcast ([27 x i32]* @.str to i8*))
ret i32 %1
}

LLVM IR (-O2):
@.str = [27 x i32] [i32 114, i32 111, i32 109, i32 115, i32 47, i32 118, i32 105, i32 100, i32 101, i32 111, i32 47, i32 115, i32 51, i32 47, i32 115, i32 116, i32 101, i32 97, i32 108, i32 116, i32 54, i32 52, i32 46, i32 98, i32 105, i32 110, i32 0]
define i32 @s3_diamond_stealth64_764_available() {
%1 = tail call i32 @rom_present(i8* bitcast ([27 x i32]* @.str to i8*))
ret i32 %1
}
void gtk_accelerator_get_default_mod_mask() {}


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

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

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

LLVM IR (-O2):
define void @gtk_accelerator_get_default_mod_mask() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ abort();
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, void *);
int /*<<< orphan*/ stderr;
void rtpp_modman_startall_fin(void *pub) {
  fprintf(stderr,
          "Method rtpp_modman@%p::startall (rtpp_modman_startall) is invoked "
          "after destruction\x0a",
          pub);
  abort();
}


x86 assembly (clang, -O0):
<rtpp_modman_startall_fin>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    0x2ead(%rip),%rax
mov    (%rax),%edi
mov    -0x8(%rbp),%rdx
lea    0xec0(%rip),%rsi
call   1040 <fprintf@plt>
mov    $0x0,%al
call   1030 <abort@plt>

x86 assembly (clang, -O2):
<rtpp_modman_startall_fin>:
push   %rax
mov    %rdi,%rdx
mov    0x2eb5(%rip),%rax
mov    (%rax),%edi
lea    0xecc(%rip),%rsi
call   1040 <fprintf@plt>
xor    %eax,%eax
call   1030 <abort@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [85 x i8] c"Method rtpp_modman@%p::startall (rtpp_modman_startall) is invoked after destruction\0A\00"
define void @rtpp_modman_startall_fin(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 ([85 x i8], [85 x i8]* @.str, i64 0, i64 0), i8* %4)
%6 = call i32 (...) @abort()
unreachable
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [85 x i8] c"Method rtpp_modman@%p::startall (rtpp_modman_startall) is invoked after destruction\0A\00"
define void @rtpp_modman_startall_fin(i8* %0) {
%2 = load i32, i32* @stderr
%3 = tail call i32 @fprintf(i32 %2, i8* getelementptr inbounds ([85 x i8], [85 x i8]* @.str, i64 0, i64 0), i8* %0)
%4 = tail call i32 (...) @abort()
unreachable
}
int tcdrain(int fildes) {
  anvil_syslog(0, "%s unimplemented\n", __FUNCTION__);
  return 0;
}


x86 assembly (clang, -O0):
<tcdrain>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
xor    %edi,%edi
lea    0xedc(%rip),%rsi
lea    0xee7(%rip),%rdx
mov    $0x0,%al
call   1030 <anvil_syslog@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<tcdrain>:
push   %rax
lea    0xee8(%rip),%rsi
lea    0xef3(%rip),%rdx
xor    %edi,%edi
xor    %eax,%eax
call   1030 <anvil_syslog@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [18 x i8] c"%s unimplemented\0A\00"
@__FUNCTION__.tcdrain = [8 x i8] c"tcdrain\00"
define i32 @tcdrain(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = call i32 (i32, i8*, i8*, ...) bitcast (i32 (...)* @anvil_syslog to i32 (i32, i8*, i8*, ...)*)(i32 0, i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @__FUNCTION__.tcdrain, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@.str = [18 x i8] c"%s unimplemented\0A\00"
@__FUNCTION__.tcdrain = [8 x i8] c"tcdrain\00"
define i32 @tcdrain(i32 %0) {
%2 = tail call i32 (i32, i8*, i8*, ...) bitcast (i32 (...)* @anvil_syslog to i32 (i32, i8*, i8*, ...)*)(i32 0, i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @__FUNCTION__.tcdrain, i64 0, i64 0))
ret i32 0
}
unsigned char otoi(char *str) {
  return 64 * (*str - '0') + 8 * (*(str + 1) - '0') + (*(str + 2) - '0');
}


x86 assembly (clang, -O0):
<otoi>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
movsbl (%rax),%eax
sub    $0x30,%eax
shl    $0x6,%eax
mov    -0x8(%rbp),%rcx
movsbl 0x1(%rcx),%ecx
sub    $0x30,%ecx
shl    $0x3,%ecx
add    %ecx,%eax
mov    -0x8(%rbp),%rcx
movsbl 0x2(%rcx),%ecx
sub    $0x30,%ecx
add    %ecx,%eax
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<otoi>:
mov    (%rdi),%cl
mov    0x1(%rdi),%al
shl    $0x6,%cl
shl    $0x3,%al
add    %cl,%al
add    0x2(%rdi),%al
add    $0x50,%al
ret

LLVM IR (-O0):
define zeroext i8 @otoi(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 = sub nsw i32 %5, 48
%7 = mul nsw i32 64, %6
%8 = load i8*, i8** %2
%9 = getelementptr inbounds i8, i8* %8, i64 1
%10 = load i8, i8* %9
%11 = sext i8 %10 to i32
%12 = sub nsw i32 %11, 48
%13 = mul nsw i32 8, %12
%14 = add nsw i32 %7, %13
%15 = load i8*, i8** %2
%16 = getelementptr inbounds i8, i8* %15, i64 2
%17 = load i8, i8* %16
%18 = sext i8 %17 to i32
%19 = sub nsw i32 %18, 48
%20 = add nsw i32 %14, %19
%21 = trunc i32 %20 to i8
ret i8 %21
}

LLVM IR (-O2):
define zeroext i8 @otoi(i8* nocapture %0) {
%2 = load i8, i8* %0
%3 = shl i8 %2, 6
%4 = getelementptr inbounds i8, i8* %0, i64 1
%5 = load i8, i8* %4
%6 = shl i8 %5, 3
%7 = getelementptr inbounds i8, i8* %0, i64 2
%8 = load i8, i8* %7
%9 = add i8 %3, 80
%10 = add i8 %9, %6
%11 = add i8 %10, %8
ret i8 %11
}
/* Type definitions */
typedef scalar_t__ pthread_t;

/* Variables and functions */
int /*<<< orphan*/ printf(char *, unsigned int, long);
int /*<<< orphan*/ pthread_exit(int /*<<< orphan*/ *);
scalar_t__ pthread_self();
void *PrintHello(void *arg) {
  long int val = (long int)arg;
  pthread_t tid = pthread_self();
  printf("Thread %u: Hello! arg = %ld\n", (unsigned int)tid, val);
  pthread_exit(NULL);
}


x86 assembly (clang, -O0):
<PrintHello>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    $0x0,%al
call   1050 <pthread_self@plt>
mov    %rax,-0x20(%rbp)
mov    -0x20(%rbp),%rax
mov    %eax,%esi
mov    -0x18(%rbp),%rdx
lea    0xea0(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
mov    %eax,%edi
call   1040 <pthread_exit@plt>
mov    -0x8(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<PrintHello>:
push   %rbx
mov    %rdi,%rbx
xor    %eax,%eax
call   1050 <pthread_self@plt>
lea    0xebe(%rip),%rdi
mov    %eax,%esi
mov    %rbx,%rdx
call   1030 <printf@plt>
xor    %edi,%edi
pop    %rbx
jmp    1040 <pthread_exit@plt>

LLVM IR (-O0):
@.str = [29 x i8] c"Thread %u: Hello! arg = %ld\0A\00"
define i8* @PrintHello(i8* %0) {
%2 = alloca i8*
%3 = alloca i8*
%4 = alloca i64
%5 = alloca i64
store i8* %0, i8** %3
%6 = load i8*, i8** %3
%7 = ptrtoint i8* %6 to i64
store i64 %7, i64* %4
%8 = call i64 (...) @pthread_self()
store i64 %8, i64* %5
%9 = load i64, i64* %5
%10 = trunc i64 %9 to i32
%11 = load i64, i64* %4
%12 = call i32 @printf(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str, i64 0, i64 0), i32 %10, i64 %11)
%13 = call i32 @pthread_exit(i32* null)
%14 = load i8*, i8** %2
ret i8* %14
}

LLVM IR (-O2):
@.str = [29 x i8] c"Thread %u: Hello! arg = %ld\0A\00"
define noalias i8* @PrintHello(i8* %0) {
%2 = ptrtoint i8* %0 to i64
%3 = tail call i64 (...) @pthread_self()
%4 = trunc i64 %3 to i32
%5 = tail call i32 @printf(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str, i64 0, i64 0), i32 %4, i64 %2)
%6 = tail call i32 @pthread_exit(i32* null)
ret i8* undef
}
long min32(long a, long b) { return (a < b) ? a : b; }


x86 assembly (clang, -O0):
<min32>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
cmp    -0x10(%rbp),%rax
jge    1127 <min32+0x27>
mov    -0x8(%rbp),%rax
mov    %rax,-0x18(%rbp)
jmp    112f <min32+0x2f>
mov    -0x10(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<min32>:
mov    %rsi,%rax
cmp    %rsi,%rdi
cmovl  %rdi,%rax
ret

LLVM IR (-O0):
define i64 @min32(i64 %0, i64 %1) {
%3 = alloca i64
%4 = alloca i64
store i64 %0, i64* %3
store i64 %1, i64* %4
%5 = load i64, i64* %3
%6 = load i64, i64* %4
%7 = icmp slt i64 %5, %6
br i1 %7, label %8, label %10
8: ; preds = %2
%9 = load i64, i64* %3
br label %12
10: ; preds = %2
%11 = load i64, i64* %4
br label %12
12: ; preds = %10, %8
%13 = phi i64 [ %9, %8 ], [ %11, %10 ]
ret i64 %13
}

LLVM IR (-O2):
define i64 @min32(i64 %0, i64 %1) {
%3 = icmp slt i64 %0, %1
%4 = select i1 %3, i64 %0, i64 %1
ret i64 %4
}
/* Variables and functions */
int /*<<< orphan*/ write32(int, int);
void gcpad_init(void) {
  write32((0xCD006400 + (0) * 4), 0x00400300);
  write32((0xCD006400 + (3) * 4), 0x00400300);
  write32((0xCD006400 + (6) * 4), 0x00400300);
  write32((0xCD006400 + (8) * 4), 0x00400300);
  write32((0xCD006400 + (12) * 4), 0x000701f0);
  write32((0xCD006400 + (14) * 4), 0x80000000);
}


x86 assembly (clang, -O0):
<gcpad_init>:
push   %rbp
mov    %rsp,%rbp
mov    $0xcd006400,%edi
mov    $0x400300,%esi
call   1030 <write32@plt>
mov    $0xcd00640c,%edi
mov    $0x400300,%esi
call   1030 <write32@plt>
mov    $0xcd006418,%edi
mov    $0x400300,%esi
call   1030 <write32@plt>
mov    $0xcd006420,%edi
mov    $0x400300,%esi
call   1030 <write32@plt>
mov    $0xcd006430,%edi
mov    $0x701f0,%esi
call   1030 <write32@plt>
mov    $0xcd006438,%edi
mov    $0x80000000,%esi
call   1030 <write32@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<gcpad_init>:
push   %rax
mov    $0xcd006400,%edi
mov    $0x400300,%esi
call   1030 <write32@plt>
mov    $0xcd00640c,%edi
mov    $0x400300,%esi
call   1030 <write32@plt>
mov    $0xcd006418,%edi
mov    $0x400300,%esi
call   1030 <write32@plt>
mov    $0xcd006420,%edi
mov    $0x400300,%esi
call   1030 <write32@plt>
mov    $0xcd006430,%edi
mov    $0x701f0,%esi
call   1030 <write32@plt>
mov    $0xcd006438,%edi
mov    $0x80000000,%esi
pop    %rax
jmp    1030 <write32@plt>

LLVM IR (-O0):
define void @gcpad_init() {
%1 = call i32 @write32(i32 -855612416, i32 4195072)
%2 = call i32 @write32(i32 -855612404, i32 4195072)
%3 = call i32 @write32(i32 -855612392, i32 4195072)
%4 = call i32 @write32(i32 -855612384, i32 4195072)
%5 = call i32 @write32(i32 -855612368, i32 459248)
%6 = call i32 @write32(i32 -855612360, i32 -2147483648)
ret void
}

LLVM IR (-O2):
define void @gcpad_init() {
%1 = tail call i32 @write32(i32 -855612416, i32 4195072)
%2 = tail call i32 @write32(i32 -855612404, i32 4195072)
%3 = tail call i32 @write32(i32 -855612392, i32 4195072)
%4 = tail call i32 @write32(i32 -855612384, i32 4195072)
%5 = tail call i32 @write32(i32 -855612368, i32 459248)
%6 = tail call i32 @write32(i32 -855612360, i32 -2147483648)
ret void
}
/* Type definitions */
struct namebuf {
  int dummy;
};

/* Variables and functions */
int __VERIFIER_nondet_int();
int findMyZone(struct namebuf *np, int class) {
  int tmp;
  {
    { tmp = __VERIFIER_nondet_int(); }
    return (tmp);
  }
}


x86 assembly (clang, -O0):
<findMyZone>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    $0x0,%al
call   1030 <__VERIFIER_nondet_int@plt>
mov    %eax,-0x10(%rbp)
mov    -0x10(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
%struct.namebuf = type { i32 }
define i32 @findMyZone(%struct.namebuf* %0, i32 %1) {
%3 = alloca %struct.namebuf*
%4 = alloca i32
%5 = alloca i32
store %struct.namebuf* %0, %struct.namebuf** %3
store i32 %1, i32* %4
%6 = call i32 (...) @__VERIFIER_nondet_int()
store i32 %6, i32* %5
%7 = load i32, i32* %5
ret i32 %7
}

LLVM IR (-O2):
%struct.namebuf = type { i32 }
define i32 @findMyZone(%struct.namebuf* nocapture readnone %0, i32 %1) {
%3 = tail call i32 (...) @__VERIFIER_nondet_int()
ret i32 %3
}
/* Variables and functions */
int fork_exec_wait(char const *, char **);
int fork_exec_wait_arg(const char *command, char *args[], int argsub,
                       char *arg) {
  args[argsub] = arg;
  return fork_exec_wait(command, args);
}


x86 assembly (clang, -O0):
<fork_exec_wait_arg>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    %rcx,-0x20(%rbp)
mov    -0x20(%rbp),%rdx
mov    -0x10(%rbp),%rax
movslq -0x14(%rbp),%rcx
mov    %rdx,(%rax,%rcx,8)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1030 <fork_exec_wait@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<fork_exec_wait_arg>:
movslq %edx,%rax
mov    %rcx,(%rsi,%rax,8)
jmp    1030 <fork_exec_wait@plt>

LLVM IR (-O0):
define i32 @fork_exec_wait_arg(i8* %0, i8** %1, i32 %2, i8* %3) {
%5 = alloca i8*
%6 = alloca i8**
%7 = alloca i32
%8 = alloca i8*
store i8* %0, i8** %5
store i8** %1, i8*** %6
store i32 %2, i32* %7
store i8* %3, i8** %8
%9 = load i8*, i8** %8
%10 = load i8**, i8*** %6
%11 = load i32, i32* %7
%12 = sext i32 %11 to i64
%13 = getelementptr inbounds i8*, i8** %10, i64 %12
store i8* %9, i8** %13
%14 = load i8*, i8** %5
%15 = load i8**, i8*** %6
%16 = call i32 @fork_exec_wait(i8* %14, i8** %15)
ret i32 %16
}

LLVM IR (-O2):
define i32 @fork_exec_wait_arg(i8* %0, i8** %1, i32 %2, i8* %3) {
%5 = sext i32 %2 to i64
%6 = getelementptr inbounds i8*, i8** %1, i64 %5
store i8* %3, i8** %6
%7 = tail call i32 @fork_exec_wait(i8* %0, i8** %1)
ret i32 %7
}
/* Variables and functions */
int /*<<< orphan*/ LOG_DAEMON;
int /*<<< orphan*/ LOG_NOTICE;
int /*<<< orphan*/ LOG_PID;
int /*<<< orphan*/ LOG_UPTO(int /*<<< orphan*/);
int /*<<< orphan*/ openlog(char *, int /*<<< orphan*/, int /*<<< orphan*/);
int /*<<< orphan*/ setlogmask(int /*<<< orphan*/);
void syslog_init() {
  setlogmask(LOG_UPTO(LOG_NOTICE));
  openlog("home-rf433", LOG_PID, LOG_DAEMON);
}


x86 assembly (clang, -O0):
<syslog_init>:
push   %rbp
mov    %rsp,%rbp
mov    0x2e95(%rip),%rax
mov    (%rax),%edi
call   1030 <LOG_UPTO@plt>
mov    %eax,%edi
call   1040 <setlogmask@plt>
mov    0x2e88(%rip),%rax
mov    (%rax),%esi
mov    0x2e8f(%rip),%rax
mov    (%rax),%edx
lea    0xe9e(%rip),%rdi
call   1050 <openlog@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<syslog_init>:
push   %rax
mov    0x2e98(%rip),%rax
mov    (%rax),%edi
call   1030 <LOG_UPTO@plt>
mov    %eax,%edi
call   1040 <setlogmask@plt>
mov    0x2e8b(%rip),%rax
mov    (%rax),%esi
mov    0x2e92(%rip),%rax
mov    (%rax),%edx
lea    0xea1(%rip),%rdi
pop    %rax
jmp    1050 <openlog@plt>

LLVM IR (-O0):
@LOG_NOTICE = global i32 0
@.str = [11 x i8] c"home-rf433\00"
@LOG_PID = global i32 0
@LOG_DAEMON = global i32 0
define void @syslog_init() {
%1 = load i32, i32* @LOG_NOTICE
%2 = call i32 @LOG_UPTO(i32 %1)
%3 = call i32 @setlogmask(i32 %2)
%4 = load i32, i32* @LOG_PID
%5 = load i32, i32* @LOG_DAEMON
%6 = call i32 @openlog(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0), i32 %4, i32 %5)
ret void
}

LLVM IR (-O2):
@LOG_NOTICE = global i32 0
@.str = [11 x i8] c"home-rf433\00"
@LOG_PID = global i32 0
@LOG_DAEMON = global i32 0
define void @syslog_init() {
%1 = load i32, i32* @LOG_NOTICE
%2 = tail call i32 @LOG_UPTO(i32 %1)
%3 = tail call i32 @setlogmask(i32 %2)
%4 = load i32, i32* @LOG_PID
%5 = load i32, i32* @LOG_DAEMON
%6 = tail call i32 @openlog(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0), i32 %4, i32 %5)
ret void
}
int MAIN() {
  int i = 8;
  int *p = &i;
  i <<= 2;
  print("i ", *p);
  print(i);
  return 0;
}


x86 assembly (clang, -O0):
<MAIN>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x8,-0x4(%rbp)
lea    -0x4(%rbp),%rax
mov    %rax,-0x10(%rbp)
mov    -0x4(%rbp),%eax
shl    $0x2,%eax
mov    %eax,-0x4(%rbp)
mov    -0x10(%rbp),%rax
mov    (%rax),%esi
lea    0xec3(%rip),%rdi
mov    $0x0,%al
call   1030 <print@plt>
mov    -0x4(%rbp),%edi
mov    $0x0,%al
call   1030 <print@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<MAIN>:
push   %rax
lea    0xee8(%rip),%rdi
mov    $0x20,%esi
xor    %eax,%eax
call   1030 <print@plt>
mov    $0x20,%edi
xor    %eax,%eax
call   1030 <print@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [3 x i8] c"i \00"
define i32 @MAIN() {
%1 = alloca i32
%2 = alloca i32*
store i32 8, i32* %1
store i32* %1, i32** %2
%3 = load i32, i32* %1
%4 = shl i32 %3, 2
store i32 %4, i32* %1
%5 = load i32*, i32** %2
%6 = load i32, i32* %5
%7 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @print to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32 %6)
%8 = load i32, i32* %1
%9 = call i32 (i32, ...) bitcast (i32 (...)* @print to i32 (i32, ...)*)(i32 %8)
ret i32 0
}

LLVM IR (-O2):
@.str = [3 x i8] c"i \00"
define i32 @MAIN() {
%1 = tail call i32 (i8*, i32, ...) bitcast (i32 (...)* @print to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32 32)
%2 = tail call i32 (i32, ...) bitcast (i32 (...)* @print to i32 (i32, ...)*)(i32 32)
ret i32 0
}
/* Type definitions */
typedef int /*<<< orphan*/ socketPath;

/* Variables and functions */
scalar_t__ getpid();
int /*<<< orphan*/ snprintf(char *, int, char *, int);
int /*<<< orphan*/ unlink(char *);
void cleanupSocketFuzzer() {
  char socketPath[512];
  snprintf(socketPath, sizeof(socketPath), "/tmp/honggfuzz_socket.%i",
           (int)getpid());
  unlink(socketPath);
}


x86 assembly (clang, -O0):
<cleanupSocketFuzzer>:
push   %rbp
mov    %rsp,%rbp
sub    $0x210,%rsp
lea    -0x200(%rbp),%rax
mov    %rax,-0x208(%rbp)
mov    $0x0,%al
call   1040 <getpid@plt>
mov    -0x208(%rbp),%rdi
mov    %eax,%ecx
mov    $0x200,%esi
lea    0xe9b(%rip),%rdx
call   1050 <snprintf@plt>
lea    -0x200(%rbp),%rdi
call   1030 <unlink@plt>
add    $0x210,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<cleanupSocketFuzzer>:
push   %rbx
sub    $0x200,%rsp
xor    %eax,%eax
call   1040 <getpid@plt>
lea    0xeba(%rip),%rdx
mov    %rsp,%rbx
mov    %rbx,%rdi
mov    $0x200,%esi
mov    %eax,%ecx
call   1050 <snprintf@plt>
mov    %rbx,%rdi
call   1030 <unlink@plt>
add    $0x200,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [25 x i8] c"/tmp/honggfuzz_socket.%i\00"
define void @cleanupSocketFuzzer() {
%1 = alloca [512 x i8]
%2 = getelementptr inbounds [512 x i8], [512 x i8]* %1, i64 0, i64 0
%3 = call i64 (...) @getpid()
%4 = trunc i64 %3 to i32
%5 = call i32 @snprintf(i8* %2, i32 512, i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i32 %4)
%6 = getelementptr inbounds [512 x i8], [512 x i8]* %1, i64 0, i64 0
%7 = call i32 @unlink(i8* %6)
ret void
}

LLVM IR (-O2):
@.str = [25 x i8] c"/tmp/honggfuzz_socket.%i\00"
define void @cleanupSocketFuzzer() {
%1 = alloca [512 x i8]
%2 = getelementptr inbounds [512 x i8], [512 x i8]* %1, i64 0, i64 0
%3 = tail call i64 (...) @getpid()
%4 = trunc i64 %3 to i32
%5 = call i32 @snprintf(i8* %2, i32 512, i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i32 %4)
%6 = call i32 @unlink(i8* %2)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ linear_probing_tests();
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ seperate_chaining_tests();
int main(int argc, char *argv[]) {
  printf("------ Seperate Chaining -----\n");
  seperate_chaining_tests();
  printf("------ Linear Probing ------\n");
  linear_probing_tests();
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
lea    0xeba(%rip),%rdi
call   1030 <printf@plt>
mov    $0x0,%al
call   1040 <seperate_chaining_tests@plt>
lea    0xec7(%rip),%rdi
call   1030 <printf@plt>
mov    $0x0,%al
call   1050 <linear_probing_tests@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
@.str = [32 x i8] c"------ Seperate Chaining -----\0A\00"
@.str.1 = [30 x i8] c"------ Linear Probing ------\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i8**
store i32 %0, i32* %3
store i8** %1, i8*** %4
%5 = call i32 @printf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str, i64 0, i64 0))
%6 = call i32 (...) @seperate_chaining_tests()
%7 = call i32 @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.1, i64 0, i64 0))
%8 = call i32 (...) @linear_probing_tests()
ret i32 0
}

LLVM IR (-O2):
@str = [31 x i8] c"------ Seperate Chaining -----\00"
@str.2 = [29 x i8] c"------ Linear Probing ------\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([31 x i8], [31 x i8]* @str, i64 0, i64 0))
%4 = tail call i32 (...) @seperate_chaining_tests()
%5 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([29 x i8], [29 x i8]* @str.2, i64 0, i64 0))
%6 = tail call i32 (...) @linear_probing_tests()
ret i32 0
}
__attribute__((destructor(123))) void G() {}


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

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

LLVM IR (-O0):
@llvm.global_dtors = appending global [1 x { i32, void ()*, i8* }] [{ i32, void ()*, i8* } { i32 123, void ()* @G, i8* null }]
define void @G() {
ret void
}

LLVM IR (-O2):
@llvm.global_dtors = appending global [1 x { i32, void ()*, i8* }] [{ i32, void ()*, i8* } { i32 123, void ()* @G, i8* null }]
define void @G() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ assert(int /*<<< orphan*/);
int /*<<< orphan*/ gen_is_bdw(int);
int gen_get_bdw_gt(int devid) {
  assert(gen_is_bdw(devid));
  return ((devid & 0x30) >> 4) + 1;
}


x86 assembly (clang, -O0):
<gen_get_bdw_gt>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%edi
call   1030 <gen_is_bdw@plt>
mov    %eax,%edi
call   1040 <assert@plt>
mov    -0x4(%rbp),%eax
and    $0x30,%eax
sar    $0x4,%eax
add    $0x1,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<gen_get_bdw_gt>:
push   %rbx
mov    %edi,%ebx
call   1030 <gen_is_bdw@plt>
mov    %eax,%edi
call   1040 <assert@plt>
shr    $0x4,%ebx
and    $0x3,%ebx
add    $0x1,%ebx
mov    %ebx,%eax
pop    %rbx
ret

LLVM IR (-O0):
define i32 @gen_get_bdw_gt(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = call i32 @gen_is_bdw(i32 %3)
%5 = call i32 @assert(i32 %4)
%6 = load i32, i32* %2
%7 = and i32 %6, 48
%8 = ashr i32 %7, 4
%9 = add nsw i32 %8, 1
ret i32 %9
}

LLVM IR (-O2):
define i32 @gen_get_bdw_gt(i32 %0) {
%2 = tail call i32 @gen_is_bdw(i32 %0)
%3 = tail call i32 @assert(i32 %2)
%4 = lshr i32 %0, 4
%5 = and i32 %4, 3
%6 = add nuw nsw i32 %5, 1
ret i32 %6
}
void *lstrip(char *string) {
  if (!string)
    return string;
  while (isspace(*string)) {
    string++;
  }
  return string;
}


x86 assembly (clang, -O0):
<lstrip>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x10(%rbp)
cmpq   $0x0,-0x10(%rbp)
jne    1134 <lstrip+0x24>
mov    -0x10(%rbp),%rax
mov    %rax,-0x8(%rbp)
jmp    1167 <lstrip+0x57>
jmp    1139 <lstrip+0x29>
mov    -0x10(%rbp),%rax
movsbl (%rax),%edi
call   1030 <isspace@plt>
cmp    $0x0,%eax
je     115f <lstrip+0x4f>
mov    -0x10(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x10(%rbp)
jmp    1139 <lstrip+0x29>
mov    -0x10(%rbp),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<lstrip>:
push   %rbx
test   %rdi,%rdi
je     1133 <lstrip+0x23>
mov    %rdi,%rbx
add    $0xffffffffffffffff,%rbx
nopl   (%rax)
movsbl 0x1(%rbx),%edi
add    $0x1,%rbx
call   1030 <isspace@plt>
test   %eax,%eax
jne    1120 <lstrip+0x10>
jmp    1135 <lstrip+0x25>
xor    %ebx,%ebx
mov    %rbx,%rax
pop    %rbx
ret

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

LLVM IR (-O2):
define i8* @lstrip(i8* %0) {
%2 = icmp eq i8* %0, null
br i1 %2, label %10, label %3
3: ; preds = %1, %3
%4 = phi i8* [ %9, %3 ], [ %0, %1 ]
%5 = load i8, i8* %4
%6 = sext i8 %5 to i32
%7 = tail call i32 @isspace(i32 %6)
%8 = icmp eq i32 %7, 0
%9 = getelementptr inbounds i8, i8* %4, i64 1
br i1 %8, label %10, label %3
10: ; preds = %3, %1
%11 = phi i8* [ null, %1 ], [ %4, %3 ]
ret i8* %11
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ isdigit(int);
void t_isdigit_0xa5() {
  Assert_real((isdigit(165) == 0),
              "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/"
              "2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/"
              "dg/z88dk/test/suites/ctype/test_isdigit.c",
              830, ("isdigit should be 0 for 0xa5"));
}


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

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

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

LLVM IR (-O2):
@.str = [168 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_isdigit.c\00"
@.str.1 = [29 x i8] c"isdigit should be 0 for 0xa5\00"
define void @t_isdigit_0xa5() {
%1 = tail call i64 @isdigit(i32 165)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = tail call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 830, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Type definitions */
typedef int int32_t;

/* Variables and functions */
int bound_motion_vector(const int vector, const int f_code) {
  return ((int32_t)vector << (27 - f_code)) >> (27 - f_code);
}


x86 assembly (clang, -O0):
<bound_motion_vector>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x4(%rbp),%eax
mov    $0x1b,%ecx
sub    -0x8(%rbp),%ecx
shl    %cl,%eax
mov    $0x1b,%ecx
sub    -0x8(%rbp),%ecx
sar    %cl,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<bound_motion_vector>:
mov    %edi,%eax
mov    $0x1b,%cl
sub    %sil,%cl
shl    %cl,%eax
sar    %cl,%eax
ret

LLVM IR (-O0):
define i32 @bound_motion_vector(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 = sub nsw i32 27, %6
%8 = shl i32 %5, %7
%9 = load i32, i32* %4
%10 = sub nsw i32 27, %9
%11 = ashr i32 %8, %10
ret i32 %11
}

LLVM IR (-O2):
define i32 @bound_motion_vector(i32 %0, i32 %1) {
%3 = sub nsw i32 27, %1
%4 = shl i32 %0, %3
%5 = ashr i32 %4, %3
ret i32 %5
}
void RepaintGraphWindow(void) {}


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

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

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

LLVM IR (-O2):
define void @RepaintGraphWindow() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ putc(int /*<<< orphan*/);
int puts(unsigned char *str) {
  while (*str)
    putc(*(str++));
  return 0;
}


x86 assembly (clang, -O0):
<puts>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
cmpb   $0x0,(%rax)
je     1145 <puts+0x35>
mov    -0x8(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x8(%rbp)
movzbl (%rax),%edi
call   1030 <putc@plt>
jmp    111c <puts+0xc>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

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

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

LLVM IR (-O2):
define i32 @puts(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* [ %7, %4 ], [ %0, %1 ]
%7 = getelementptr inbounds i8, i8* %6, i64 1
%8 = zext i8 %5 to i32
%9 = tail call i32 @putc(i32 %8)
%10 = load i8, i8* %7
%11 = icmp eq i8 %10, 0
br i1 %11, label %12, label %4
12: ; preds = %4, %1
ret i32 0
}
/* Variables and functions */
float floor(float);
float ceil(float x) { return -floor(-x); }


x86 assembly (clang, -O0):
<ceil>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
call   1030 <floor@plt>
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ceil>:
push   %rax
xorps  0xee8(%rip),%xmm0
call   1030 <floorf@plt>
xorps  0xedc(%rip),%xmm0
pop    %rax
ret

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

LLVM IR (-O2):
define float @ceil(float %0) {
%2 = fneg float %0
%3 = tail call float @llvm.floor.f32(float %2)
%4 = fneg float %3
ret float %4
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, char *);
int /*<<< orphan*/ shiftleft(char *, int, int);
int strlen(char *);
int main() {
  char s[] = "abcdefg";
  int strlength = 0;
  strlength = strlen(s);
  int offset = 3;
  shiftleft(s, strlength, offset);
  printf("%s", s);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    0xeba(%rip),%rax
mov    %rax,-0xc(%rbp)
movl   $0x0,-0x10(%rbp)
lea    -0xc(%rbp),%rdi
call   1030 <strlen@plt>
mov    %eax,-0x10(%rbp)
movl   $0x3,-0x14(%rbp)
lea    -0xc(%rbp),%rdi
mov    -0x10(%rbp),%esi
mov    -0x14(%rbp),%edx
call   1050 <shiftleft@plt>
lea    -0xc(%rbp),%rsi
lea    0xe8a(%rip),%rdi
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x10,%rsp
movabs $0x67666564636261,%rax
mov    %rax,0x8(%rsp)
lea    0x8(%rsp),%rbx
mov    %rbx,%rdi
call   1030 <strlen@plt>
mov    %rbx,%rdi
mov    %eax,%esi
mov    $0x3,%edx
call   1050 <shiftleft@plt>
lea    0xe99(%rip),%rdi
mov    %rbx,%rsi
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@__const.main.s = [8 x i8] c"abcdefg\00"
@.str = [3 x i8] c"%s\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [8 x i8]
%3 = alloca i32
%4 = alloca i32
store i32 0, i32* %1
%5 = bitcast [8 x i8]* %2 to i8*
store i32 0, i32* %3
%6 = getelementptr inbounds [8 x i8], [8 x i8]* %2, i64 0, i64 0
%7 = call i32 @strlen(i8* %6)
store i32 %7, i32* %3
store i32 3, i32* %4
%8 = getelementptr inbounds [8 x i8], [8 x i8]* %2, i64 0, i64 0
%9 = load i32, i32* %3
%10 = load i32, i32* %4
%11 = call i32 @shiftleft(i8* %8, i32 %9, i32 %10)
%12 = getelementptr inbounds [8 x i8], [8 x i8]* %2, i64 0, i64 0
%13 = call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* %12)
ret i32 0
}

LLVM IR (-O2):
@.str = [3 x i8] c"%s\00"
define i32 @main() {
%1 = alloca i64
%2 = bitcast i64* %1 to i8*
store i64 29104508263162465, i64* %1
%3 = call i32 @strlen(i8* %2)
%4 = call i32 @shiftleft(i8* %2, i32 %3, i32 3)
%5 = call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* %2)
ret i32 0
}