xunge/DecIR huggingface dataset:
int util_byte_to_bin(unsigned char *dst, unsigned char b) {
  int retval;
  switch (b) {
  case 0x7d:
  case 0x23:
  case 0x24:
  case 0x2a:
    *(dst++) = 0x7d;
    *dst = b ^ 0x20;
    retval = 2;
    break;
  default:
    *dst = b;
    retval = 1;
    break;
  }
  return retval;
}


x86 assembly (clang, -O0):
<util_byte_to_bin>:
push   %rbp
mov    %rsp,%rbp
mov    %sil,%al
mov    %rdi,-0x8(%rbp)
mov    %al,-0x9(%rbp)
movzbl -0x9(%rbp),%eax
mov    %eax,-0x14(%rbp)
add    $0xffffffdd,%eax
sub    $0x2,%eax
jb     1148 <util_byte_to_bin+0x48>
jmp    1126 <util_byte_to_bin+0x26>
mov    -0x14(%rbp),%eax
sub    $0x2a,%eax
je     1148 <util_byte_to_bin+0x48>
jmp    1137 <util_byte_to_bin+0x37>
mov    -0x14(%rbp),%eax
sub    $0x7d,%eax
jne    1175 <util_byte_to_bin+0x75>
jmp    1148 <util_byte_to_bin+0x48>
mov    -0x8(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x8(%rbp)
movb   $0x7d,(%rax)
movzbl -0x9(%rbp),%eax
xor    $0x20,%eax
mov    %al,%cl
mov    -0x8(%rbp),%rax
mov    %cl,(%rax)
movl   $0x2,-0x10(%rbp)
jmp    1185 <util_byte_to_bin+0x85>
mov    -0x9(%rbp),%cl
mov    -0x8(%rbp),%rax
mov    %cl,(%rax)
movl   $0x1,-0x10(%rbp)
mov    -0x10(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<util_byte_to_bin>:
cmp    $0x2a,%sil
ja     1118 <util_byte_to_bin+0x18>
mov    %esi,%eax
movabs $0x41800000000,%rcx
bt     %rax,%rcx
jb     111e <util_byte_to_bin+0x1e>
cmp    $0x7d,%sil
jne    112f <util_byte_to_bin+0x2f>
movb   $0x7d,(%rdi)
xor    $0x20,%sil
mov    %sil,0x1(%rdi)
mov    $0x2,%eax
ret
mov    %sil,(%rdi)
mov    $0x1,%eax
ret

LLVM IR (-O0):
define i32 @util_byte_to_bin(i8* %0, i8 zeroext %1) {
%3 = alloca i8*
%4 = alloca i8
%5 = alloca i32
store i8* %0, i8** %3
store i8 %1, i8* %4
%6 = load i8, i8* %4
%7 = zext i8 %6 to i32
switch i32 %7, label %16 [
i32 125, label %8
i32 35, label %8
i32 36, label %8
i32 42, label %8
]
8: ; preds = %2, %2, %2, %2
%9 = load i8*, i8** %3
%10 = getelementptr inbounds i8, i8* %9, i32 1
store i8* %10, i8** %3
store i8 125, i8* %9
%11 = load i8, i8* %4
%12 = zext i8 %11 to i32
%13 = xor i32 %12, 32
%14 = trunc i32 %13 to i8
%15 = load i8*, i8** %3
store i8 %14, i8* %15
store i32 2, i32* %5
br label %19
16: ; preds = %2
%17 = load i8, i8* %4
%18 = load i8*, i8** %3
store i8 %17, i8* %18
store i32 1, i32* %5
br label %19
19: ; preds = %16, %8
%20 = load i32, i32* %5
ret i32 %20
}

LLVM IR (-O2):
define i32 @util_byte_to_bin(i8* nocapture writeonly %0, i8 zeroext %1) {
switch i8 %1, label %6 [
i8 125, label %3
i8 35, label %3
i8 36, label %3
i8 42, label %3
]
3: ; preds = %2, %2, %2, %2
%4 = getelementptr inbounds i8, i8* %0, i64 1
store i8 125, i8* %0
%5 = xor i8 %1, 32
store i8 %5, i8* %4
br label %7
6: ; preds = %2
store i8 %1, i8* %0
br label %7
7: ; preds = %6, %3
%8 = phi i32 [ 1, %6 ], [ 2, %3 ]
ret i32 %8
}
char *dog_ident() { return "$Id: dog_devel.c 230 2007-10-23 17:42:49Z  $"; }


x86 assembly (clang, -O0):
<dog_ident>:
push   %rbp
mov    %rsp,%rbp
lea    0xef5(%rip),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<dog_ident>:
lea    0xef9(%rip),%rax
ret

LLVM IR (-O0):
@.str = [45 x i8] c"$Id: dog_devel.c 230 2007-10-23 17:42:49Z $\00"
define i8* @dog_ident() {
ret i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str, i64 0, i64 0)
}

LLVM IR (-O2):
@.str = [45 x i8] c"$Id: dog_devel.c 230 2007-10-23 17:42:49Z $\00"
define i8* @dog_ident() {
ret i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str, i64 0, i64 0)
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int);
int strlen(char *);
char *corta_string(char *apuntador) {
  int l;
  l = strlen(apuntador);
  if (l > 0) {
    apuntador = apuntador + 1;
    return apuntador;
  } else {
    printf("Longitud %d \n", l);
    return "ERROR";
  }
}


x86 assembly (clang, -O0):
<corta_string>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
call   1030 <strlen@plt>
mov    %eax,-0x14(%rbp)
cmpl   $0x0,-0x14(%rbp)
jle    115b <corta_string+0x3b>
mov    -0x10(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,-0x8(%rbp)
jmp    1175 <corta_string+0x55>
mov    -0x14(%rbp),%esi
lea    0xe9b(%rip),%rdi
call   1040 <printf@plt>
lea    0xe9d(%rip),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<corta_string>:
push   %rbx
mov    %rdi,%rbx
call   1030 <strlen@plt>
test   %eax,%eax
jle    1133 <corta_string+0x13>
add    $0x1,%rbx
jmp    1148 <corta_string+0x28>
lea    0xec6(%rip),%rdi
mov    %eax,%esi
call   1040 <printf@plt>
lea    0xec6(%rip),%rbx
mov    %rbx,%rax
pop    %rbx
ret

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

LLVM IR (-O2):
@.str = [14 x i8] c"Longitud %d \0A\00"
@.str.1 = [6 x i8] c"ERROR\00"
define i8* @corta_string(i8* %0) {
%2 = tail call i32 @strlen(i8* %0)
%3 = icmp sgt i32 %2, 0
br i1 %3, label %4, label %6
4: ; preds = %1
%5 = getelementptr inbounds i8, i8* %0, i64 1
br label %8
6: ; preds = %1
%7 = tail call i32 @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0), i32 %2)
br label %8
8: ; preds = %6, %4
%9 = phi i8* [ %5, %4 ], [ getelementptr inbounds ([6 x i8], [6 x i8]* @.str.1, i64 0, i64 0), %6 ]
ret i8* %9
}
int test1(int i, int j) {
  if (i >= j)
    if (i != j)
      return 0;
  return -2;
}


x86 assembly (clang, -O0):
<test1>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0x8(%rbp),%eax
cmp    -0xc(%rbp),%eax
jl     1133 <test1+0x33>
mov    -0x8(%rbp),%eax
cmp    -0xc(%rbp),%eax
je     112e <test1+0x2e>
movl   $0x0,-0x4(%rbp)
jmp    113a <test1+0x3a>
jmp    1133 <test1+0x33>
movl   $0xfffffffe,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<test1>:
xor    %eax,%eax
cmp    %esi,%edi
setg   %al
add    %eax,%eax
add    $0xfffffffe,%eax
ret

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

LLVM IR (-O2):
define i32 @test1(i32 %0, i32 %1) {
%3 = icmp sgt i32 %0, %1
%4 = select i1 %3, i32 0, i32 -2
ret i32 %4
}
void bar(int arg0) { (void)arg0; }


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

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

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

LLVM IR (-O2):
define void @bar(i32 %0) {
ret void
}
const char *dump_inputdev_vtype(unsigned type) {
  switch (type) {
  case 0:
    return "CVBS";
  case 1:
    return "Tuner";
  case 2:
    return "S-Video";
  default:
    return "UNK";
  }
}


x86 assembly (clang, -O0):
<dump_inputdev_vtype>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0xc(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x10(%rbp)
test   %eax,%eax
je     113c <dump_inputdev_vtype+0x3c>
jmp    111a <dump_inputdev_vtype+0x1a>
mov    -0x10(%rbp),%eax
sub    $0x1,%eax
je     114c <dump_inputdev_vtype+0x4c>
jmp    112b <dump_inputdev_vtype+0x2b>
mov    -0x10(%rbp),%eax
sub    $0x2,%eax
je     115c <dump_inputdev_vtype+0x5c>
jmp    116c <dump_inputdev_vtype+0x6c>
lea    0xebd(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1177 <dump_inputdev_vtype+0x77>
lea    0xeb2(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1177 <dump_inputdev_vtype+0x77>
lea    0xea8(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1177 <dump_inputdev_vtype+0x77>
lea    0xea0(%rip),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<dump_inputdev_vtype>:
cmp    $0x2,%edi
ja     1117 <dump_inputdev_vtype+0x17>
movslq %edi,%rax
lea    0xf09(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
ret
lea    0xef5(%rip),%rax
ret

LLVM IR (-O0):
@.str = [5 x i8] c"CVBS\00"
@.str.1 = [6 x i8] c"Tuner\00"
@.str.2 = [8 x i8] c"S-Video\00"
@.str.3 = [4 x i8] c"UNK\00"
define i8* @dump_inputdev_vtype(i32 %0) {
%2 = alloca i8*
%3 = alloca i32
store i32 %0, i32* %3
%4 = load i32, i32* %3
switch i32 %4, label %8 [
i32 0, label %5
i32 1, label %6
i32 2, label %7
]
5: ; preds = %1
store i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i8** %2
br label %9
6: ; preds = %1
store i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.1, i64 0, i64 0), i8** %2
br label %9
7: ; preds = %1
store i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.2, i64 0, i64 0), i8** %2
br label %9
8: ; preds = %1
store i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0), i8** %2
br label %9
9: ; preds = %8, %7, %6, %5
%10 = load i8*, i8** %2
ret i8* %10
}

LLVM IR (-O2):
@.str = [5 x i8] c"CVBS\00"
@.str.1 = [6 x i8] c"Tuner\00"
@.str.2 = [8 x i8] c"S-Video\00"
@.str.3 = [4 x i8] c"UNK\00"
@reltable.dump_inputdev_vtype = [3 x i32] [i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str to i64), i64 ptrtoint ([3 x i32]* @reltable.dump_inputdev_vtype to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([6 x i8]* @.str.1 to i64), i64 ptrtoint ([3 x i32]* @reltable.dump_inputdev_vtype to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([8 x i8]* @.str.2 to i64), i64 ptrtoint ([3 x i32]* @reltable.dump_inputdev_vtype to i64)) to i32)]
define i8* @dump_inputdev_vtype(i32 %0) {
%2 = icmp ult i32 %0, 3
br i1 %2, label %3, label %7
3: ; preds = %1
%4 = sext i32 %0 to i64
%5 = shl i64 %4, 2
%6 = call i8* @llvm.load.relative.i64(i8* bitcast ([3 x i32]* @reltable.dump_inputdev_vtype to i8*), i64 %5)
br label %7
7: ; preds = %1, %3
%8 = phi i8* [ %6, %3 ], [ getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0), %1 ]
ret i8* %8
}
/* Variables and functions */
int /*<<< orphan*/ memset(char *, int /*<<< orphan*/, int);
int /*<<< orphan*/ printf(char *, char *);
int /*<<< orphan*/ serialport_read_until(int, char *, char);
void read_line(int fd) {
  char buf[256];
  memset(buf, 0, 256);
  serialport_read_until(fd, buf, '\r');
  printf("read: %s\n", buf);
}


x86 assembly (clang, -O0):
<read_line>:
push   %rbp
mov    %rsp,%rbp
sub    $0x110,%rsp
mov    %edi,-0x4(%rbp)
lea    -0x110(%rbp),%rdi
xor    %esi,%esi
mov    $0x100,%edx
call   1050 <memset@plt>
mov    -0x4(%rbp),%edi
lea    -0x110(%rbp),%rsi
mov    $0xd,%edx
call   1030 <serialport_read_until@plt>
lea    -0x110(%rbp),%rsi
lea    0xe8d(%rip),%rdi
call   1040 <printf@plt>
add    $0x110,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<read_line>:
push   %r14
push   %rbx
sub    $0x108,%rsp
mov    %edi,%ebx
mov    %rsp,%r14
mov    %r14,%rdi
xor    %esi,%esi
mov    $0x100,%edx
call   1050 <memset@plt>
mov    %ebx,%edi
mov    %r14,%rsi
mov    $0xd,%edx
call   1030 <serialport_read_until@plt>
lea    0xe9c(%rip),%rdi
mov    %r14,%rsi
call   1040 <printf@plt>
add    $0x108,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
@.str = [10 x i8] c"read: %s\0A\00"
define void @read_line(i32 %0) {
%2 = alloca i32
%3 = alloca [256 x i8]
store i32 %0, i32* %2
%4 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 0
%5 = call i32 @memset(i8* %4, i32 0, i32 256)
%6 = load i32, i32* %2
%7 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 0
%8 = call i32 @serialport_read_until(i32 %6, i8* %7, i8 signext 13)
%9 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 0
%10 = call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), i8* %9)
ret void
}

LLVM IR (-O2):
@.str = [10 x i8] c"read: %s\0A\00"
define void @read_line(i32 %0) {
%2 = alloca [256 x i8]
%3 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%4 = call i32 @memset(i8* %3, i32 0, i32 256)
%5 = call i32 @serialport_read_until(i32 %0, i8* %3, i8 signext 13)
%6 = call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), i8* %3)
ret void
}
/* Type definitions */
struct rte_ring {
  int dummy;
};

/* Variables and functions */
int rte_ring_sp_enqueue_bulk(struct rte_ring *, void **, int);
int rte_ring_sp_enqueue(struct rte_ring *r, void *obj) {
  return rte_ring_sp_enqueue_bulk(r, &obj, 1);
}


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

x86 assembly (clang, -O2):
<rte_ring_sp_enqueue>:
push   %rax
mov    %rsi,(%rsp)
mov    %rsp,%rsi
mov    $0x1,%edx
call   1030 <rte_ring_sp_enqueue_bulk@plt>
pop    %rcx
ret

LLVM IR (-O0):
%struct.rte_ring = type { i32 }
define i32 @rte_ring_sp_enqueue(%struct.rte_ring* %0, i8* %1) {
%3 = alloca %struct.rte_ring*
%4 = alloca i8*
store %struct.rte_ring* %0, %struct.rte_ring** %3
store i8* %1, i8** %4
%5 = load %struct.rte_ring*, %struct.rte_ring** %3
%6 = call i32 @rte_ring_sp_enqueue_bulk(%struct.rte_ring* %5, i8** %4, i32 1)
ret i32 %6
}

LLVM IR (-O2):
%struct.rte_ring = type { i32 }
define i32 @rte_ring_sp_enqueue(%struct.rte_ring* %0, i8* %1) {
%3 = alloca i8*
store i8* %1, i8** %3
%4 = call i32 @rte_ring_sp_enqueue_bulk(%struct.rte_ring* %0, i8** %3, i32 1)
ret i32 %4
}
/* Variables and functions */
int /*<<< orphan*/ set_grid_metrics_gcov();
int /*<<< orphan*/ set_grid_metrics_others();
int /*<<< orphan*/ symmetrize_gcov();
void set_grid_metrics_withsymmetrization(void) {
  set_grid_metrics_gcov();
  if (0)
    symmetrize_gcov();
  set_grid_metrics_others();
}


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

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

LLVM IR (-O0):
define void @set_grid_metrics_withsymmetrization() {
%1 = call i32 (...) @set_grid_metrics_gcov()
%2 = call i32 (...) @set_grid_metrics_others()
ret void
}

LLVM IR (-O2):
define void @set_grid_metrics_withsymmetrization() {
%1 = tail call i32 (...) @set_grid_metrics_gcov()
%2 = tail call i32 (...) @set_grid_metrics_others()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ __pmp_inline_memory_fence();
void __pmp_memory_fence() { __pmp_inline_memory_fence(); }


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

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

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

LLVM IR (-O2):
define void @__pmp_memory_fence() {
%1 = tail call i32 (...) @__pmp_inline_memory_fence()
ret void
}
/* Variables and functions */
double log(double);
double ss(double Q2) {
  double a2 = 232.2 * 232.2;
  double mi2 = 230000;
  if (Q2 <= 232000)
    return 0;
  else
    return log(log(Q2 / a2) / log(mi2 / a2));
}


x86 assembly (clang, -O0):
<ss>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movsd  %xmm0,-0x10(%rbp)
movsd  0xeeb(%rip),%xmm0
movsd  %xmm0,-0x18(%rbp)
movsd  0xed6(%rip),%xmm0
movsd  %xmm0,-0x20(%rbp)
movsd  0xec1(%rip),%xmm0
ucomisd -0x10(%rbp),%xmm0
jb     1157 <ss+0x47>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x8(%rbp)
jmp    1190 <ss+0x80>
movsd  -0x10(%rbp),%xmm0
divsd  -0x18(%rbp),%xmm0
call   1030 <log@plt>
movsd  %xmm0,-0x28(%rbp)
movsd  -0x20(%rbp),%xmm0
divsd  -0x18(%rbp),%xmm0
call   1030 <log@plt>
movaps %xmm0,%xmm1
movsd  -0x28(%rbp),%xmm0
divsd  %xmm1,%xmm0
call   1030 <log@plt>
movsd  %xmm0,-0x8(%rbp)
movsd  -0x8(%rbp),%xmm0
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ss>:
push   %rax
movsd  0xee7(%rip),%xmm1
ucomisd %xmm0,%xmm1
jae    113a <ss+0x2a>
divsd  0xee1(%rip),%xmm0
call   1030 <log@plt>
divsd  0xedc(%rip),%xmm0
pop    %rax
jmp    1030 <log@plt>
xorpd  %xmm0,%xmm0
pop    %rax
ret

LLVM IR (-O0):
define double @ss(double %0) {
%2 = alloca double
%3 = alloca double
%4 = alloca double
%5 = alloca double
store double %0, double* %3
store double 0x40EA539AE147AE14, double* %4
store double 2.300000e+05, double* %5
%6 = load double, double* %3
%7 = fcmp ole double %6, 2.320000e+05
br i1 %7, label %8, label %9
8: ; preds = %1
store double 0.000000e+00, double* %2
br label %20
9: ; preds = %1
%10 = load double, double* %3
%11 = load double, double* %4
%12 = fdiv double %10, %11
%13 = call double @log(double %12)
%14 = load double, double* %5
%15 = load double, double* %4
%16 = fdiv double %14, %15
%17 = call double @log(double %16)
%18 = fdiv double %13, %17
%19 = call double @log(double %18)
store double %19, double* %2
br label %20
20: ; preds = %9, %8
%21 = load double, double* %2
ret double %21
}

LLVM IR (-O2):
define double @ss(double %0) {
%2 = fcmp ugt double %0, 2.320000e+05
br i1 %2, label %3, label %8
3: ; preds = %1
%4 = fdiv double %0, 0x40EA539AE147AE14
%5 = tail call double @log(double %4)
%6 = fdiv double %5, 0x3FF735CE90C7686F
%7 = tail call double @log(double %6)
br label %8
8: ; preds = %1, %3
%9 = phi double [ %7, %3 ], [ 0.000000e+00, %1 ]
ret double %9
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ isbdigit(int);
void t_isbdigit_0x0f() {
  Assert_real((isbdigit(15) == 0),
              "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/"
              "2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/"
              "dg/z88dk/test/suites/ctype/test_isbdigit.c",
              80, ("isbdigit should be 0 for 0x0f"));
}


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

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

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

LLVM IR (-O2):
@.str = [169 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_isbdigit.c\00"
@.str.1 = [30 x i8] c"isbdigit should be 0 for 0x0f\00"
define void @t_isbdigit_0x0f() {
%1 = tail call i64 @isbdigit(i32 15)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = tail call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([169 x i8], [169 x i8]* @.str, i64 0, i64 0), i32 80, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.1, i64 0, i64 0))
ret void
}
int main() {
  int a;
  int b;
  int c;
  c = a * b + 5;
  return c;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
movl   $0x0,-0x4(%rbp)
mov    -0x8(%rbp),%eax
imul   -0xc(%rbp),%eax
add    $0x5,%eax
mov    %eax,-0x10(%rbp)
mov    -0x10(%rbp),%eax
pop    %rbp
ret

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

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

LLVM IR (-O2):
define i32 @main() {
ret i32 undef
}
void debug_malloc_police(const char *file, int line) {
  file = file;
  line = line;
}


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

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

LLVM IR (-O0):
define void @debug_malloc_police(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
store i8* %5, i8** %3
%6 = load i32, i32* %4
store i32 %6, i32* %4
ret void
}

LLVM IR (-O2):
define void @debug_malloc_police(i8* nocapture %0, i32 %1) {
ret void
}
/* Variables and functions */
int fn_sq_qtg_1_4294967295_cl_48_57(char const *);
int fn_al_sq_qtg_1_4294967295_cl_48_57(const char *text) {
  int pos = 0;
  pos = fn_sq_qtg_1_4294967295_cl_48_57(text);
  if (pos != -1)
    return pos;
  return -1;
}


x86 assembly (clang, -O0):
<fn_al_sq_qtg_1_4294967295_cl_48_57>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
movl   $0x0,-0x14(%rbp)
mov    -0x10(%rbp),%rdi
call   1030 <fn_sq_qtg_1_4294967295_cl_48_57@plt>
mov    %eax,-0x14(%rbp)
cmpl   $0xffffffff,-0x14(%rbp)
je     1144 <fn_al_sq_qtg_1_4294967295_cl_48_57+0x34>
mov    -0x14(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    114b <fn_al_sq_qtg_1_4294967295_cl_48_57+0x3b>
movl   $0xffffffff,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<fn_al_sq_qtg_1_4294967295_cl_48_57>:
jmp    1030 <fn_sq_qtg_1_4294967295_cl_48_57@plt>

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

LLVM IR (-O2):
define i32 @fn_al_sq_qtg_1_4294967295_cl_48_57(i8* %0) {
%2 = tail call i32 @fn_sq_qtg_1_4294967295_cl_48_57(i8* %0)
ret i32 %2
}
/* Variables and functions */
int _ada_use_c2phc(int, int *, int *, double *);
int solcon_retrieve_next_standard_initialize(void) {
  int a, *b, fail;
  double *c;
  a = 0;
  fail = _ada_use_c2phc(276, &a, b, c);
  return fail;
}


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

x86 assembly (clang, -O2):
<solcon_retrieve_next_standard_initialize>:
push   %rax
movl   $0x0,0x4(%rsp)
lea    0x4(%rsp),%rsi
mov    $0x114,%edi
call   1030 <_ada_use_c2phc@plt>
pop    %rcx
ret

LLVM IR (-O0):
define i32 @solcon_retrieve_next_standard_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_c2phc(i32 276, i32* %1, i32* %5, double* %6)
store i32 %7, i32* %3
%8 = load i32, i32* %3
ret i32 %8
}

LLVM IR (-O2):
define i32 @solcon_retrieve_next_standard_initialize() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
store i32 0, i32* %1
%3 = call i32 @_ada_use_c2phc(i32 276, i32* %1, i32* undef, double* undef)
ret i32 %3
}
/* Variables and functions */
unsigned char *hmac_haval224(unsigned char *, unsigned char const *, size_t,
                             unsigned char const *, size_t);
unsigned char *mac_hmac_haval224(unsigned char *out, const unsigned char *key,
                                 size_t key_len, const unsigned char *msg,
                                 size_t msg_len) {
  return hmac_haval224(out, key, key_len, msg, msg_len);
}


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

x86 assembly (clang, -O2):
<mac_hmac_haval224>:
jmp    1030 <hmac_haval224@plt>

LLVM IR (-O0):
define i8* @mac_hmac_haval224(i8* %0, i8* %1, i64 %2, i8* %3, i64 %4) {
%6 = alloca i8*
%7 = alloca i8*
%8 = alloca i64
%9 = alloca i8*
%10 = alloca i64
store i8* %0, i8** %6
store i8* %1, i8** %7
store i64 %2, i64* %8
store i8* %3, i8** %9
store i64 %4, i64* %10
%11 = load i8*, i8** %6
%12 = load i8*, i8** %7
%13 = load i64, i64* %8
%14 = load i8*, i8** %9
%15 = load i64, i64* %10
%16 = call i8* @hmac_haval224(i8* %11, i8* %12, i64 %13, i8* %14, i64 %15)
ret i8* %16
}

LLVM IR (-O2):
define i8* @mac_hmac_haval224(i8* %0, i8* %1, i64 %2, i8* %3, i64 %4) {
%6 = tail call i8* @hmac_haval224(i8* %0, i8* %1, i64 %2, i8* %3, i64 %4)
ret i8* %6
}
int is_hx(int c) {
  return (unsigned int)(c - 48) < 10u || (unsigned int)((c | 32) - 97) < 6u;
}


x86 assembly (clang, -O0):
<is_hx>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%ecx
sub    $0x30,%ecx
mov    $0x1,%al
cmp    $0xa,%ecx
mov    %al,-0x5(%rbp)
jb     112d <is_hx+0x2d>
mov    -0x4(%rbp),%eax
or     $0x20,%eax
sub    $0x61,%eax
cmp    $0x6,%eax
setb   %al
mov    %al,-0x5(%rbp)
mov    -0x5(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_hx>:
lea    -0x30(%rdi),%eax
cmp    $0xa,%eax
setb   %al
or     $0x20,%edi
add    $0xffffff9f,%edi
cmp    $0x6,%edi
setb   %cl
or     %al,%cl
movzbl %cl,%eax
ret

LLVM IR (-O0):
define i32 @is_hx(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = sub nsw i32 %3, 48
%5 = icmp ult i32 %4, 10
br i1 %5, label %11, label %6
6: ; preds = %1
%7 = load i32, i32* %2
%8 = or i32 %7, 32
%9 = sub nsw i32 %8, 97
%10 = icmp ult i32 %9, 6
br label %11
11: ; preds = %6, %1
%12 = phi i1 [ true, %1 ], [ %10, %6 ]
%13 = zext i1 %12 to i32
ret i32 %13
}

LLVM IR (-O2):
define i32 @is_hx(i32 %0) {
%2 = add nsw i32 %0, -48
%3 = icmp ult i32 %2, 10
%4 = or i32 %0, 32
%5 = add nsw i32 %4, -97
%6 = icmp ult i32 %5, 6
%7 = select i1 %3, i1 true, i1 %6
%8 = zext i1 %7 to i32
ret i32 %8
}
/* Variables and functions */
int i2c_smbus_write_byte_data(int, int, int);
int hummingboardI2CWriteReg8(int fd, int reg, int data) {
  return i2c_smbus_write_byte_data(fd, reg, data);
}


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

x86 assembly (clang, -O2):
<hummingboardI2CWriteReg8>:
jmp    1030 <i2c_smbus_write_byte_data@plt>

LLVM IR (-O0):
define i32 @hummingboardI2CWriteReg8(i32 %0, i32 %1, i32 %2) {
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
store i32 %0, i32* %4
store i32 %1, i32* %5
store i32 %2, i32* %6
%7 = load i32, i32* %4
%8 = load i32, i32* %5
%9 = load i32, i32* %6
%10 = call i32 @i2c_smbus_write_byte_data(i32 %7, i32 %8, i32 %9)
ret i32 %10
}

LLVM IR (-O2):
define i32 @hummingboardI2CWriteReg8(i32 %0, i32 %1, i32 %2) {
%4 = tail call i32 @i2c_smbus_write_byte_data(i32 %0, i32 %1, i32 %2)
ret i32 %4
}
int test_imm_68uint32_mem(unsigned int *val) {
  return ((*val) & (0x68 << 0)) ? -20 : -40;
}


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

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

LLVM IR (-O0):
define i32 @test_imm_68uint32_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, 104
%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_68uint32_mem(i32* nocapture %0) {
%2 = load i32, i32* %0
%3 = and i32 %2, 104
%4 = icmp eq i32 %3, 0
%5 = select i1 %4, i32 -40, i32 -20
ret i32 %5
}
/* Type definitions */
typedef int /*<<< orphan*/ cl_int;
typedef scalar_t__ cl_command_queue;

/* Variables and functions */
int /*<<< orphan*/ syscall(int, int, unsigned int *);
cl_int clFlush(cl_command_queue command_queue) {
  unsigned int sys_args[1];
  sys_args[0] = (unsigned int)command_queue;
  return (cl_int)syscall(325, 1051, sys_args);
}


x86 assembly (clang, -O0):
<clFlush>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
mov    %eax,-0xc(%rbp)
lea    -0xc(%rbp),%rdx
mov    $0x145,%edi
mov    $0x41b,%esi
call   1030 <syscall@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<clFlush>:
push   %rax
mov    %edi,0x4(%rsp)
lea    0x4(%rsp),%rdx
mov    $0x145,%edi
mov    $0x41b,%esi
call   1030 <syscall@plt>
pop    %rcx
ret

LLVM IR (-O0):
define i32 @clFlush(i64 %0) {
%2 = alloca i64
%3 = alloca [1 x i32]
store i64 %0, i64* %2
%4 = load i64, i64* %2
%5 = trunc i64 %4 to i32
%6 = getelementptr inbounds [1 x i32], [1 x i32]* %3, i64 0, i64 0
store i32 %5, i32* %6
%7 = getelementptr inbounds [1 x i32], [1 x i32]* %3, i64 0, i64 0
%8 = call i32 @syscall(i32 325, i32 1051, i32* %7)
ret i32 %8
}

LLVM IR (-O2):
define i32 @clFlush(i64 %0) {
%2 = alloca [1 x i32]
%3 = bitcast [1 x i32]* %2 to i8*
%4 = trunc i64 %0 to i32
%5 = getelementptr inbounds [1 x i32], [1 x i32]* %2, i64 0, i64 0
store i32 %4, i32* %5
%6 = call i32 @syscall(i32 325, i32 1051, i32* %5)
ret i32 %6
}
/* Variables and functions */
int /*<<< orphan*/ _x86_detect_cpu();
void _x86_detect(void) {
  static int flag = 0;
  if (flag)
    return;
  _x86_detect_cpu();
  flag = 1;
}


x86 assembly (clang, -O0):
<_x86_detect>:
push   %rbp
mov    %rsp,%rbp
cmpl   $0x0,0x2f11(%rip)
je     1126 <_x86_detect+0x16>
jmp    1137 <_x86_detect+0x27>
mov    $0x0,%al
call   1030 <_x86_detect_cpu@plt>
movl   $0x1,0x2ef5(%rip)
pop    %rbp
ret

x86 assembly (clang, -O2):
<_x86_detect>:
push   %rax
cmpb   $0x0,0x2f14(%rip)
jne    1128 <_x86_detect+0x18>
xor    %eax,%eax
call   1030 <_x86_detect_cpu@plt>
movb   $0x1,0x2f04(%rip)
pop    %rax
ret

LLVM IR (-O0):
@_x86_detect.flag = internal global i32 0
define void @_x86_detect() {
%1 = load i32, i32* @_x86_detect.flag
%2 = icmp ne i32 %1, 0
br i1 %2, label %3, label %4
3: ; preds = %0
br label %6
4: ; preds = %0
%5 = call i32 (...) @_x86_detect_cpu()
store i32 1, i32* @_x86_detect.flag
br label %6
6: ; preds = %4, %3
ret void
}

LLVM IR (-O2):
@_x86_detect.flag = internal unnamed_addr global i1 false
define void @_x86_detect() {
%1 = load i1, i1* @_x86_detect.flag
br i1 %1, label %4, label %2
2: ; preds = %0
%3 = tail call i32 (...) @_x86_detect_cpu()
store i1 true, i1* @_x86_detect.flag
br label %4
4: ; preds = %0, %2
ret void
}
int dumbCall(int a, int b) { return a + b; }


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

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

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

LLVM IR (-O2):
define i32 @dumbCall(i32 %0, i32 %1) {
%3 = add nsw i32 %1, %0
ret i32 %3
}
/* Type definitions */
struct TreeNode {
  int dummy;
};

/* Variables and functions */
int INT_MIN;
int /*<<< orphan*/ helper(struct TreeNode *, int *);
int maxPathSum(struct TreeNode *root) {
  if (!root)
    return 0;
  int maxSum = INT_MIN;
  helper(root, &maxSum);
  return maxSum;
}


x86 assembly (clang, -O0):
<maxPathSum>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
cmpq   $0x0,-0x10(%rbp)
jne    1133 <maxPathSum+0x23>
movl   $0x0,-0x4(%rbp)
jmp    1152 <maxPathSum+0x42>
mov    0x2eae(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x14(%rbp)
mov    -0x10(%rbp),%rdi
lea    -0x14(%rbp),%rsi
call   1030 <helper@plt>
mov    -0x14(%rbp),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<maxPathSum>:
test   %rdi,%rdi
je     1136 <maxPathSum+0x26>
push   %rax
mov    0x2ecb(%rip),%rax
mov    (%rax),%eax
mov    %eax,0x4(%rsp)
lea    0x4(%rsp),%rsi
call   1030 <helper@plt>
mov    0x4(%rsp),%eax
add    $0x8,%rsp
ret
xor    %eax,%eax
ret

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

LLVM IR (-O2):
%struct.TreeNode = type { i32 }
@INT_MIN = global i32 0
define i32 @maxPathSum(%struct.TreeNode* %0) {
%2 = alloca i32
%3 = icmp eq %struct.TreeNode* %0, null
br i1 %3, label %9, label %4
4: ; preds = %1
%5 = bitcast i32* %2 to i8*
%6 = load i32, i32* @INT_MIN
store i32 %6, i32* %2
%7 = call i32 @helper(%struct.TreeNode* %0, i32* %2)
%8 = load i32, i32* %2
br label %9
9: ; preds = %1, %4
%10 = phi i32 [ %8, %4 ], [ 0, %1 ]
ret i32 %10
}
/* Variables and functions */
unsigned long long __bextri_u64(unsigned long long, int);
unsigned long long test__bextri_u64_bigint(unsigned long long a) {
  return __bextri_u64(a, 0x7fffffffffLL);
}


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

x86 assembly (clang, -O2):
<test__bextri_u64_bigint>:
mov    $0xffffffff,%esi
jmp    1030 <__bextri_u64@plt>

LLVM IR (-O0):
define i64 @test__bextri_u64_bigint(i64 %0) {
%2 = alloca i64
store i64 %0, i64* %2
%3 = load i64, i64* %2
%4 = call i64 @__bextri_u64(i64 %3, i32 -1)
ret i64 %4
}

LLVM IR (-O2):
define i64 @test__bextri_u64_bigint(i64 %0) {
%2 = tail call i64 @__bextri_u64(i64 %0, i32 -1)
ret i64 %2
}
/* Variables and functions */
char getchar();
void seeknln(void) {
  while (getchar() != '\n')
    ;
}


x86 assembly (clang, -O0):
<seeknln>:
push   %rbp
mov    %rsp,%rbp
jmp    1119 <seeknln+0x9>
mov    $0x0,%al
call   1030 <getchar@plt>
movsbl %al,%eax
cmp    $0xa,%eax
je     1131 <seeknln+0x21>
jmp    1119 <seeknln+0x9>
pop    %rbp
ret

x86 assembly (clang, -O2):
<seeknln>:
push   %rax
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
xor    %eax,%eax
call   1030 <getchar@plt>
cmp    $0xa,%al
jne    1120 <seeknln+0x10>
pop    %rax
ret

LLVM IR (-O0):
define void @seeknln() {
br label %1
1: ; preds = %5, %0
%2 = call signext i8 (...) @getchar()
%3 = sext i8 %2 to i32
%4 = icmp ne i32 %3, 10
br i1 %4, label %5, label %6
5: ; preds = %1
br label %1
6: ; preds = %1
ret void
}

LLVM IR (-O2):
define void @seeknln() {
br label %1
1: ; preds = %1, %0
%2 = tail call signext i8 (...) @getchar()
%3 = icmp eq i8 %2, 10
br i1 %3, label %4, label %1
4: ; preds = %1
ret void
}
/* Variables and functions */
int /*<<< orphan*/ doublesubcycle2();
void doublesubcycle1(void) { doublesubcycle2(); }


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

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

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

LLVM IR (-O2):
define void @doublesubcycle1() {
%1 = tail call i32 (...) @doublesubcycle2()
ret void
}
void pwrite() {}


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

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

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

LLVM IR (-O2):
define void @pwrite() {
ret void
}
int is_wild(char *s) {
  int i;
  for (i = 0; s[i] != '\0'; i++)
    if (s[i] == '*' || s[i] == '?')
      break;
  return (s[i] != '\0');
}


x86 assembly (clang, -O0):
<is_wild>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
mov    -0x8(%rbp),%rax
movslq -0xc(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x0,%eax
je     1166 <is_wild+0x66>
mov    -0x8(%rbp),%rax
movslq -0xc(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x2a,%eax
je     114e <is_wild+0x4e>
mov    -0x8(%rbp),%rax
movslq -0xc(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x3f,%eax
jne    1153 <is_wild+0x53>
jmp    1166 <is_wild+0x66>
jmp    1158 <is_wild+0x58>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    110f <is_wild+0xf>
mov    -0x8(%rbp),%rax
movslq -0xc(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x0,%eax
setne  %al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_wild>:
movabs $0x8000040000000001,%rax
jmp    1114 <is_wild+0x14>
nopl   0x0(%rax)
add    $0x1,%rdi
movzbl (%rdi),%ecx
cmp    $0x3f,%rcx
ja     1110 <is_wild+0x10>
bt     %rcx,%rax
jae    1110 <is_wild+0x10>
xor    %eax,%eax
test   %cl,%cl
setne  %al
ret

LLVM IR (-O0):
define i32 @is_wild(i8* %0) {
%2 = alloca i8*
%3 = alloca i32
store i8* %0, i8** %2
store i32 0, i32* %3
br label %4
4: ; preds = %30, %1
%5 = load i8*, i8** %2
%6 = load i32, i32* %3
%7 = sext i32 %6 to i64
%8 = getelementptr inbounds i8, i8* %5, i64 %7
%9 = load i8, i8* %8
%10 = sext i8 %9 to i32
%11 = icmp ne i32 %10, 0
br i1 %11, label %12, label %33
12: ; preds = %4
%13 = load i8*, i8** %2
%14 = load i32, i32* %3
%15 = sext i32 %14 to i64
%16 = getelementptr inbounds i8, i8* %13, i64 %15
%17 = load i8, i8* %16
%18 = sext i8 %17 to i32
%19 = icmp eq i32 %18, 42
br i1 %19, label %28, label %20
20: ; preds = %12
%21 = load i8*, i8** %2
%22 = load i32, i32* %3
%23 = sext i32 %22 to i64
%24 = getelementptr inbounds i8, i8* %21, i64 %23
%25 = load i8, i8* %24
%26 = sext i8 %25 to i32
%27 = icmp eq i32 %26, 63
br i1 %27, label %28, label %29
28: ; preds = %20, %12
br label %33
29: ; preds = %20
br label %30
30: ; preds = %29
%31 = load i32, i32* %3
%32 = add nsw i32 %31, 1
store i32 %32, i32* %3
br label %4
33: ; preds = %28, %4
%34 = load i8*, i8** %2
%35 = load i32, i32* %3
%36 = sext i32 %35 to i64
%37 = getelementptr inbounds i8, i8* %34, i64 %36
%38 = load i8, i8* %37
%39 = sext i8 %38 to i32
%40 = icmp ne i32 %39, 0
%41 = zext i1 %40 to i32
ret i32 %41
}

LLVM IR (-O2):
define i32 @is_wild(i8* nocapture %0) {
br label %2
2: ; preds = %6, %1
%3 = phi i64 [ %7, %6 ], [ 0, %1 ]
%4 = getelementptr inbounds i8, i8* %0, i64 %3
%5 = load i8, i8* %4
switch i8 %5, label %6 [
i8 0, label %8
i8 42, label %8
i8 63, label %8
]
6: ; preds = %2
%7 = add nuw i64 %3, 1
br label %2
8: ; preds = %2, %2, %2
%9 = icmp ne i8 %5, 0
%10 = zext i1 %9 to i32
ret i32 %10
}
void foo075() {}


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

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

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

LLVM IR (-O2):
define void @foo075() {
ret void
}
void gtk_color_selection_set_current_color() {}


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

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

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

LLVM IR (-O2):
define void @gtk_color_selection_set_current_color() {
ret void
}
int uname(struct utsname *buf) {
  ;
  return -1;
}


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

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

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

LLVM IR (-O2):
%struct.utsname = type opaque
define i32 @uname(%struct.utsname* nocapture readnone %0) {
ret i32 -1
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ islower(int);
void t_islower_0xa7() {
  Assert_real((islower(167) == 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",
              840, ("islower should be 0 for 0xa7"));
}


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

x86 assembly (clang, -O2):
<t_islower_0xa7>:
push   %rax
mov    $0xa7,%edi
call   1030 <islower@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
lea    0xec5(%rip),%rsi
lea    0xf66(%rip),%rcx
mov    $0x348,%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 0xa7\00"
define void @t_islower_0xa7() {
%1 = call i64 @islower(i32 167)
%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 840, 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 0xa7\00"
define void @t_islower_0xa7() {
%1 = tail call i64 @islower(i32 167)
%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 840, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, char *);
int /*<<< orphan*/ stderr;
void print_usage(char *prgname) {
  fprintf(stderr, "%s 1.0 (c) 2013-2014 Martin Kopta\n", prgname);
  fprintf(stderr, "Usage: %s  [-d] [-l port] [-p pidfile] [-v]\n", prgname);
}


x86 assembly (clang, -O0):
<print_usage>:
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    0xeda(%rip),%rsi
call   1030 <fprintf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<print_usage>:
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    0xee9(%rip),%rsi
mov    %rbx,%rdx
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1030 <fprintf@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [35 x i8] c"%s 1.0 (c) 2013-2014 Martin Kopta\0A\00"
@.str.1 = [45 x i8] c"Usage: %s [-d] [-l port] [-p pidfile] [-v]\0A\00"
define void @print_usage(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 ([35 x i8], [35 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 ([45 x i8], [45 x i8]* @.str.1, i64 0, i64 0), i8* %7)
ret void
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [35 x i8] c"%s 1.0 (c) 2013-2014 Martin Kopta\0A\00"
@.str.1 = [45 x i8] c"Usage: %s [-d] [-l port] [-p pidfile] [-v]\0A\00"
define void @print_usage(i8* %0) {
%2 = load i32, i32* @stderr
%3 = tail call i32 @fprintf(i32 %2, i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str, i64 0, i64 0), i8* %0)
%4 = load i32, i32* @stderr
%5 = tail call i32 @fprintf(i32 %4, i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str.1, i64 0, i64 0), i8* %0)
ret void
}
/* Type definitions */
typedef int int64_t;

/* Variables and functions */
int /*<<< orphan*/ printf(char *, double);
double stdlib_strided_dmin(int, double *, int);
int main() {
  double x[] = {1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0};
  int64_t N = 4;
  int64_t stride = 2;
  double v = stdlib_strided_dmin(N, x, stride);
  printf("min: %lf\n", v);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
lea    -0x40(%rbp),%rdi
lea    0xebd(%rip),%rsi
mov    $0x40,%edx
call   1050 <memcpy@plt>
movl   $0x4,-0x44(%rbp)
movl   $0x2,-0x48(%rbp)
mov    -0x44(%rbp),%edi
lea    -0x40(%rbp),%rsi
mov    -0x48(%rbp),%edx
call   1030 <stdlib_strided_dmin@plt>
movsd  %xmm0,-0x50(%rbp)
movsd  -0x50(%rbp),%xmm0
lea    0xec5(%rip),%rdi
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x50,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
sub    $0x48,%rsp
movaps 0xf05(%rip),%xmm0
movaps %xmm0,0x30(%rsp)
movaps 0xee9(%rip),%xmm0
movaps %xmm0,0x20(%rsp)
movaps 0xecd(%rip),%xmm0
movaps %xmm0,0x10(%rsp)
movaps 0xeb1(%rip),%xmm0
movaps %xmm0,(%rsp)
mov    %rsp,%rsi
mov    $0x4,%edi
mov    $0x2,%edx
call   1030 <stdlib_strided_dmin@plt>
lea    0xed4(%rip),%rdi
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x48,%rsp
ret

LLVM IR (-O0):
@__const.main.x = [8 x double] [double 1.000000e+00, double 2.000000e+00, double 3.000000e+00, double 4.000000e+00, double 5.000000e+00, double 6.000000e+00, double 7.000000e+00, double 8.000000e+00]
@.str = [10 x i8] c"min: %lf\0A\00"
define i32 @main() {
%1 = alloca [8 x double]
%2 = alloca i32
%3 = alloca i32
%4 = alloca double
%5 = bitcast [8 x double]* %1 to i8*
store i32 4, i32* %2
store i32 2, i32* %3
%6 = load i32, i32* %2
%7 = getelementptr inbounds [8 x double], [8 x double]* %1, i64 0, i64 0
%8 = load i32, i32* %3
%9 = call double @stdlib_strided_dmin(i32 %6, double* %7, i32 %8)
store double %9, double* %4
%10 = load double, double* %4
%11 = call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), double %10)
ret i32 0
}

LLVM IR (-O2):
@__const.main.x = [8 x double] [double 1.000000e+00, double 2.000000e+00, double 3.000000e+00, double 4.000000e+00, double 5.000000e+00, double 6.000000e+00, double 7.000000e+00, double 8.000000e+00]
@.str = [10 x i8] c"min: %lf\0A\00"
define i32 @main() {
%1 = alloca [8 x double]
%2 = bitcast [8 x double]* %1 to i8*
%3 = getelementptr inbounds [8 x double], [8 x double]* %1, i64 0, i64 0
%4 = call double @stdlib_strided_dmin(i32 4, double* %3, i32 2)
%5 = call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), double %4)
ret i32 0
}