xunge/DecIR huggingface dataset:
int is_pulse(int data) { return data & 0x01000000 ? 1 : 0; }


x86 assembly (clang, -O0):
<is_pulse>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%edx
and    $0x1000000,%edx
xor    %eax,%eax
mov    $0x1,%ecx
cmp    $0x0,%edx
cmovne %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_pulse>:
mov    %edi,%eax
shr    $0x18,%eax
and    $0x1,%eax
ret

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

LLVM IR (-O2):
define i32 @is_pulse(i32 %0) {
%2 = lshr i32 %0, 24
%3 = and i32 %2, 1
ret i32 %3
}
void vec2_sub(const float a[2], const float b[2], float out[2]) {
  out[0] = a[0] - b[0];
  out[1] = a[1] - b[1];
}


x86 assembly (clang, -O0):
<vec2_sub>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x8(%rbp),%rax
movss  (%rax),%xmm0
mov    -0x10(%rbp),%rax
subss  (%rax),%xmm0
mov    -0x18(%rbp),%rax
movss  %xmm0,(%rax)
mov    -0x8(%rbp),%rax
movss  0x4(%rax),%xmm0
mov    -0x10(%rbp),%rax
subss  0x4(%rax),%xmm0
mov    -0x18(%rbp),%rax
movss  %xmm0,0x4(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<vec2_sub>:
movss  (%rdi),%xmm0
subss  (%rsi),%xmm0
movss  %xmm0,(%rdx)
movss  0x4(%rdi),%xmm0
subss  0x4(%rsi),%xmm0
movss  %xmm0,0x4(%rdx)
ret

LLVM IR (-O0):
define void @vec2_sub(float* %0, float* %1, float* %2) {
%4 = alloca float*
%5 = alloca float*
%6 = alloca float*
store float* %0, float** %4
store float* %1, float** %5
store float* %2, float** %6
%7 = load float*, float** %4
%8 = getelementptr inbounds float, float* %7, i64 0
%9 = load float, float* %8
%10 = load float*, float** %5
%11 = getelementptr inbounds float, float* %10, i64 0
%12 = load float, float* %11
%13 = fsub float %9, %12
%14 = load float*, float** %6
%15 = getelementptr inbounds float, float* %14, i64 0
store float %13, float* %15
%16 = load float*, float** %4
%17 = getelementptr inbounds float, float* %16, i64 1
%18 = load float, float* %17
%19 = load float*, float** %5
%20 = getelementptr inbounds float, float* %19, i64 1
%21 = load float, float* %20
%22 = fsub float %18, %21
%23 = load float*, float** %6
%24 = getelementptr inbounds float, float* %23, i64 1
store float %22, float* %24
ret void
}

LLVM IR (-O2):
define void @vec2_sub(float* nocapture %0, float* nocapture %1, float* nocapture writeonly %2) {
%4 = load float, float* %0
%5 = load float, float* %1
%6 = fsub float %4, %5
store float %6, float* %2
%7 = getelementptr inbounds float, float* %0, i64 1
%8 = load float, float* %7
%9 = getelementptr inbounds float, float* %1, i64 1
%10 = load float, float* %9
%11 = fsub float %8, %10
%12 = getelementptr inbounds float, float* %2, i64 1
store float %11, float* %12
ret void
}
/* Variables and functions */
int pow2(int, int);
int isboundary(int flag) {
  return (flag > pow2(2, 12) * 3) || (flag < pow2(2, 12));
}


x86 assembly (clang, -O0):
<isboundary>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    $0x2,%edi
mov    $0xc,%esi
call   1030 <pow2@plt>
mov    -0xc(%rbp),%ecx
imul   $0x3,%eax,%edx
mov    $0x1,%al
cmp    %edx,%ecx
mov    %al,-0x5(%rbp)
jg     1165 <isboundary+0x55>
mov    -0x4(%rbp),%eax
mov    %eax,-0x10(%rbp)
mov    $0x2,%edi
mov    $0xc,%esi
call   1030 <pow2@plt>
mov    %eax,%ecx
mov    -0x10(%rbp),%eax
cmp    %ecx,%eax
setl   %al
mov    %al,-0x5(%rbp)
mov    -0x5(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<isboundary>:
push   %rbx
mov    %edi,%ebx
mov    $0x2,%edi
mov    $0xc,%esi
call   1030 <pow2@plt>
lea    (%rax,%rax,2),%ecx
mov    $0x1,%eax
cmp    %ebx,%ecx
jl     1146 <isboundary+0x36>
mov    $0x2,%edi
mov    $0xc,%esi
call   1030 <pow2@plt>
mov    %eax,%ecx
xor    %eax,%eax
cmp    %ebx,%ecx
setg   %al
pop    %rbx
ret

LLVM IR (-O0):
define i32 @isboundary(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = call i32 @pow2(i32 2, i32 12)
%5 = mul nsw i32 %4, 3
%6 = icmp sgt i32 %3, %5
br i1 %6, label %11, label %7
7: ; preds = %1
%8 = load i32, i32* %2
%9 = call i32 @pow2(i32 2, i32 12)
%10 = icmp slt i32 %8, %9
br label %11
11: ; preds = %7, %1
%12 = phi i1 [ true, %1 ], [ %10, %7 ]
%13 = zext i1 %12 to i32
ret i32 %13
}

LLVM IR (-O2):
define i32 @isboundary(i32 %0) {
%2 = tail call i32 @pow2(i32 2, i32 12)
%3 = mul nsw i32 %2, 3
%4 = icmp slt i32 %3, %0
br i1 %4, label %9, label %5
5: ; preds = %1
%6 = tail call i32 @pow2(i32 2, i32 12)
%7 = icmp sgt i32 %6, %0
%8 = zext i1 %7 to i32
br label %9
9: ; preds = %5, %1
%10 = phi i32 [ 1, %1 ], [ %8, %5 ]
ret i32 %10
}
unsigned long next_collatz_sequence(unsigned long n) {
  if (n % 2 == 0) {
    return n / 2;
  }
  return 3 * n + 1;
}


x86 assembly (clang, -O0):
<next_collatz_sequence>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
and    $0x1,%rax
cmp    $0x0,%rax
jne    112b <next_collatz_sequence+0x2b>
mov    -0x10(%rbp),%rax
shr    $0x1,%rax
mov    %rax,-0x8(%rbp)
jmp    1138 <next_collatz_sequence+0x38>
imul   $0x3,-0x10(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<next_collatz_sequence>:
mov    %rdi,%rcx
shr    %rcx
test   $0x1,%dil
lea    0x1(%rdi,%rdi,2),%rax
cmove  %rcx,%rax
ret

LLVM IR (-O0):
define i64 @next_collatz_sequence(i64 %0) {
%2 = alloca i64
%3 = alloca i64
store i64 %0, i64* %3
%4 = load i64, i64* %3
%5 = urem i64 %4, 2
%6 = icmp eq i64 %5, 0
br i1 %6, label %7, label %10
7: ; preds = %1
%8 = load i64, i64* %3
%9 = udiv i64 %8, 2
store i64 %9, i64* %2
br label %14
10: ; preds = %1
%11 = load i64, i64* %3
%12 = mul i64 3, %11
%13 = add i64 %12, 1
store i64 %13, i64* %2
br label %14
14: ; preds = %10, %7
%15 = load i64, i64* %2
ret i64 %15
}

LLVM IR (-O2):
define i64 @next_collatz_sequence(i64 %0) {
%2 = and i64 %0, 1
%3 = icmp eq i64 %2, 0
%4 = lshr i64 %0, 1
%5 = mul i64 %0, 3
%6 = add i64 %5, 1
%7 = select i1 %3, i64 %4, i64 %6
ret i64 %7
}
/* Variables and functions */
float max(float, float);
float blendColorBurn(float base, float blend) {
  return (blend == 0.0f) ? blend : max((1.0f - ((1.0f - base) / blend)), 0.0f);
}


x86 assembly (clang, -O0):
<blendColorBurn>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movss  %xmm0,-0x4(%rbp)
movss  %xmm1,-0x8(%rbp)
movss  -0x8(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomiss %xmm1,%xmm0
jne    1148 <blendColorBurn+0x38>
jp     1148 <blendColorBurn+0x38>
movss  -0x8(%rbp),%xmm0
movss  %xmm0,-0xc(%rbp)
jmp    1173 <blendColorBurn+0x63>
movss  0xeb0(%rip),%xmm1
subss  -0x4(%rbp),%xmm1
divss  -0x8(%rbp),%xmm1
movss  0xe9e(%rip),%xmm0
subss  %xmm1,%xmm0
xorps  %xmm1,%xmm1
call   1030 <max@plt>
movss  %xmm0,-0xc(%rbp)
movss  -0xc(%rbp),%xmm0
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<blendColorBurn>:
xorps  %xmm2,%xmm2
ucomiss %xmm2,%xmm1
jne    111e <blendColorBurn+0xe>
jp     111e <blendColorBurn+0xe>
movaps %xmm1,%xmm0
ret
movss  0xeda(%rip),%xmm2
movaps %xmm2,%xmm3
subss  %xmm0,%xmm3
divss  %xmm1,%xmm3
subss  %xmm3,%xmm2
xorps  %xmm1,%xmm1
movaps %xmm2,%xmm0
jmp    1030 <max@plt>

LLVM IR (-O0):
define float @blendColorBurn(float %0, float %1) {
%3 = alloca float
%4 = alloca float
store float %0, float* %3
store float %1, float* %4
%5 = load float, float* %4
%6 = fcmp oeq float %5, 0.000000e+00
br i1 %6, label %7, label %9
7: ; preds = %2
%8 = load float, float* %4
br label %16
9: ; preds = %2
%10 = load float, float* %3
%11 = fsub float 1.000000e+00, %10
%12 = load float, float* %4
%13 = fdiv float %11, %12
%14 = fsub float 1.000000e+00, %13
%15 = call float @max(float %14, float 0.000000e+00)
br label %16
16: ; preds = %9, %7
%17 = phi float [ %8, %7 ], [ %15, %9 ]
ret float %17
}

LLVM IR (-O2):
define float @blendColorBurn(float %0, float %1) {
%3 = fcmp oeq float %1, 0.000000e+00
br i1 %3, label %9, label %4
4: ; preds = %2
%5 = fsub float 1.000000e+00, %0
%6 = fdiv float %5, %1
%7 = fsub float 1.000000e+00, %6
%8 = tail call float @max(float %7, float 0.000000e+00)
br label %9
9: ; preds = %2, %4
%10 = phi float [ %8, %4 ], [ %1, %2 ]
ret float %10
}
int mailsem_internal_init(struct mailsem_internal *s,
                          unsigned int initial_count) {
  return -1;
}


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

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

LLVM IR (-O0):
%struct.mailsem_internal = type opaque
define i32 @mailsem_internal_init(%struct.mailsem_internal* %0, i32 %1) {
%3 = alloca %struct.mailsem_internal*
%4 = alloca i32
store %struct.mailsem_internal* %0, %struct.mailsem_internal** %3
store i32 %1, i32* %4
ret i32 -1
}

LLVM IR (-O2):
%struct.mailsem_internal = type opaque
define i32 @mailsem_internal_init(%struct.mailsem_internal* nocapture readnone %0, i32 %1) {
ret i32 -1
}
/* Variables and functions */
int rand();
int randInt(int low, int high) { return (rand() % (high - low)) + low; }


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

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

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

LLVM IR (-O2):
define i32 @randInt(i32 %0, i32 %1) {
%3 = tail call i32 (...) @rand()
%4 = sub nsw i32 %1, %0
%5 = srem i32 %3, %4
%6 = add nsw i32 %5, %0
ret i32 %6
}
/* Type definitions */
struct L0 {
  int dummy;
};

/* Variables and functions */
scalar_t__ __VERIFIER_nondet_int();
int /*<<< orphan*/ l0_destroy(struct L0 *);
int /*<<< orphan*/ l0_insert(struct L0 **);
int main() {
  static struct L0 *list;
  int c = 0;
  do {
    c++;
    l0_insert(&list);
  } while (__VERIFIER_nondet_int() && c < 3);
  l0_destroy(list);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
lea    0x2eea(%rip),%rdi
call   1050 <l0_insert@plt>
mov    $0x0,%al
call   1030 <__VERIFIER_nondet_int@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    $0x0,%rcx
mov    %al,-0x9(%rbp)
je     117e <main+0x4e>
cmpl   $0x3,-0x8(%rbp)
setl   %al
mov    %al,-0x9(%rbp)
mov    -0x9(%rbp),%al
test   $0x1,%al
jne    1146 <main+0x16>
mov    0x2eb0(%rip),%rdi
call   1040 <l0_destroy@plt>
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r14
push   %rbx
push   %rax
lea    0x2f05(%rip),%r14
xor    %ebx,%ebx
nopl   (%rax)
mov    %r14,%rdi
call   1050 <l0_insert@plt>
xor    %eax,%eax
call   1030 <__VERIFIER_nondet_int@plt>
test   %rax,%rax
je     115e <main+0x2e>
lea    0x1(%rbx),%eax
cmp    $0x2,%ebx
mov    %eax,%ebx
jb     1140 <main+0x10>
mov    0x2edb(%rip),%rdi
call   1040 <l0_destroy@plt>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
%struct.L0 = type { i32 }
@main.list = internal global %struct.L0* null
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
store i32 0, i32* %1
store i32 0, i32* %2
br label %3
3: ; preds = %13, %0
%4 = load i32, i32* %2
%5 = add nsw i32 %4, 1
store i32 %5, i32* %2
%6 = call i32 @l0_insert(%struct.L0** @main.list)
br label %7
7: ; preds = %3
%8 = call i64 (...) @__VERIFIER_nondet_int()
%9 = icmp ne i64 %8, 0
br i1 %9, label %10, label %13
10: ; preds = %7
%11 = load i32, i32* %2
%12 = icmp slt i32 %11, 3
br label %13
13: ; preds = %10, %7
%14 = phi i1 [ false, %7 ], [ %12, %10 ]
br i1 %14, label %3, label %15
15: ; preds = %13
%16 = load %struct.L0*, %struct.L0** @main.list
%17 = call i32 @l0_destroy(%struct.L0* %16)
%18 = load i32, i32* %1
ret i32 %18
}

LLVM IR (-O2):
%struct.L0 = type { i32 }
@main.list = internal global %struct.L0* null
define i32 @main() {
br label %1
1: ; preds = %1, %0
%2 = phi i32 [ 0, %0 ], [ %3, %1 ]
%3 = add nuw nsw i32 %2, 1
%4 = tail call i32 @l0_insert(%struct.L0** @main.list)
%5 = tail call i64 (...) @__VERIFIER_nondet_int()
%6 = icmp ne i64 %5, 0
%7 = icmp ult i32 %2, 2
%8 = select i1 %6, i1 %7, i1 false
br i1 %8, label %1, label %9
9: ; preds = %1
%10 = load %struct.L0*, %struct.L0** @main.list
%11 = tail call i32 @l0_destroy(%struct.L0* %10)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ lpc_uart_reg_write(int /*<<< orphan*/, char);
scalar_t__ lpc_uart_tx_full();
void lpc_uart_write(char c) {
  while (lpc_uart_tx_full())
    ;
  lpc_uart_reg_write(0, c);
}


x86 assembly (clang, -O0):
<lpc_uart_write>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %dil,%al
mov    %al,-0x1(%rbp)
mov    $0x0,%al
call   1030 <lpc_uart_tx_full@plt>
cmp    $0x0,%rax
je     1144 <lpc_uart_write+0x24>
jmp    112e <lpc_uart_write+0xe>
xor    %edi,%edi
movsbl -0x1(%rbp),%esi
call   1040 <lpc_uart_reg_write@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<lpc_uart_write>:
push   %rbx
mov    %edi,%ebx
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
xor    %eax,%eax
call   1030 <lpc_uart_tx_full@plt>
test   %rax,%rax
jne    1130 <lpc_uart_write+0x10>
movsbl %bl,%esi
xor    %edi,%edi
pop    %rbx
jmp    1040 <lpc_uart_reg_write@plt>

LLVM IR (-O0):
define void @lpc_uart_write(i8 signext %0) {
%2 = alloca i8
store i8 %0, i8* %2
br label %3
3: ; preds = %6, %1
%4 = call i64 (...) @lpc_uart_tx_full()
%5 = icmp ne i64 %4, 0
br i1 %5, label %6, label %7
6: ; preds = %3
br label %3
7: ; preds = %3
%8 = load i8, i8* %2
%9 = call i32 @lpc_uart_reg_write(i32 0, i8 signext %8)
ret void
}

LLVM IR (-O2):
define void @lpc_uart_write(i8 signext %0) {
br label %2
2: ; preds = %2, %1
%3 = tail call i64 (...) @lpc_uart_tx_full()
%4 = icmp eq i64 %3, 0
br i1 %4, label %5, label %2
5: ; preds = %2
%6 = tail call i32 @lpc_uart_reg_write(i32 0, i8 signext %0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ pushk(int);
void pushone() { pushk(1); }


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

x86 assembly (clang, -O2):
<pushone>:
mov    $0x1,%edi
jmp    1030 <pushk@plt>

LLVM IR (-O0):
define void @pushone() {
%1 = call i32 @pushk(i32 1)
ret void
}

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

/* Variables and functions */
int /*<<< orphan*/ fwrite(unsigned char *, int, int, int /*<<< orphan*/ *);
void fa_write_byte(unsigned char in, FILE *fp) {
  unsigned char temp[1];
  temp[0] = in & 0xff;
  fwrite(temp, sizeof(*temp), 1, fp);
}


x86 assembly (clang, -O0):
<fa_write_byte>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %dil,%al
mov    %al,-0x1(%rbp)
mov    %rsi,-0x10(%rbp)
movzbl -0x1(%rbp),%eax
and    $0xff,%eax
mov    %al,-0x11(%rbp)
lea    -0x11(%rbp),%rdi
mov    -0x10(%rbp),%rcx
mov    $0x1,%edx
mov    %edx,%esi
call   1030 <fwrite@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<fa_write_byte>:
movsbl %dil,%edi
jmp    1030 <fputc@plt>

LLVM IR (-O0):
define void @fa_write_byte(i8 zeroext %0, i32* %1) {
%3 = alloca i8
%4 = alloca i32*
%5 = alloca [1 x i8]
store i8 %0, i8* %3
store i32* %1, i32** %4
%6 = load i8, i8* %3
%7 = zext i8 %6 to i32
%8 = and i32 %7, 255
%9 = trunc i32 %8 to i8
%10 = getelementptr inbounds [1 x i8], [1 x i8]* %5, i64 0, i64 0
store i8 %9, i8* %10
%11 = getelementptr inbounds [1 x i8], [1 x i8]* %5, i64 0, i64 0
%12 = load i32*, i32** %4
%13 = call i32 @fwrite(i8* %11, i32 1, i32 1, i32* %12)
ret void
}

LLVM IR (-O2):
define void @fa_write_byte(i8 zeroext %0, i32* nocapture %1) {
%3 = sext i8 %0 to i32
%4 = tail call i32 @fputc(i32 %3, i32* %1)
ret void
}
float C_Utils_max_float(const float item1, const float item2) {
  return item1 > item2 ? item1 : item2;
}


x86 assembly (clang, -O0):
<C_Utils_max_float>:
push   %rbp
mov    %rsp,%rbp
movss  %xmm0,-0x4(%rbp)
movss  %xmm1,-0x8(%rbp)
movss  -0x4(%rbp),%xmm0
ucomiss -0x8(%rbp),%xmm0
jbe    112c <C_Utils_max_float+0x2c>
movss  -0x4(%rbp),%xmm0
movss  %xmm0,-0xc(%rbp)
jmp    1136 <C_Utils_max_float+0x36>
movss  -0x8(%rbp),%xmm0
movss  %xmm0,-0xc(%rbp)
movss  -0xc(%rbp),%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<C_Utils_max_float>:
maxss  %xmm1,%xmm0
ret

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

LLVM IR (-O2):
define float @C_Utils_max_float(float %0, float %1) {
%3 = fcmp ogt float %0, %1
%4 = select i1 %3, float %0, float %1
ret float %4
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
void h_world(void) { printf("Hello World\n"); }


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

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

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

LLVM IR (-O2):
@str = [12 x i8] c"Hello World\00"
define void @h_world() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @str, i64 0, i64 0))
ret void
}
/* Variables and functions */
void *my_malloc(int);
void af1_e(void **pp) { *pp = my_malloc(42); }


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

x86 assembly (clang, -O2):
<af1_e>:
push   %rbx
mov    %rdi,%rbx
mov    $0x2a,%edi
call   1030 <my_malloc@plt>
mov    %rax,(%rbx)
pop    %rbx
ret

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

LLVM IR (-O2):
define void @af1_e(i8** nocapture writeonly %0) {
%2 = tail call i8* @my_malloc(i32 42)
store i8* %2, i8** %0
ret void
}
/* Forward declarations */
typedef struct TYPE_2__ TYPE_1__;

/* Type definitions */
struct TYPE_2__ {
  int /*<<< orphan*/ *depths;
};
typedef TYPE_1__ Screen;
typedef int /*<<< orphan*/ Depth;

/* Variables and functions */
void set_Screen_depths(void *_p, void *_v) {
  ((Screen *)_p)->depths = (Depth *)_v;
}


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

x86 assembly (clang, -O2):
<set_Screen_depths>:
mov    %rsi,(%rdi)
ret

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

LLVM IR (-O2):
define void @set_Screen_depths(i8* nocapture writeonly %0, i8* %1) {
%3 = bitcast i8* %0 to i8**
store i8* %1, i8** %3
ret void
}
int editorSyntaxToColor(int hl) {
  switch (hl) {
  case 2:
  case 3:
    return 36;
  case 4:
    return 33;
  case 5:
    return 32;
  case 6:
    return 35;
  case 7:
    return 31;
  case 8:
    return 34;
  default:
    return 37;
  }
}


x86 assembly (clang, -O0):
<editorSyntaxToColor>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x8(%rbp)
mov    -0x8(%rbp),%eax
add    $0xfffffffe,%eax
mov    %eax,%ecx
mov    %rcx,-0x10(%rbp)
sub    $0x6,%eax
ja     1178 <editorSyntaxToColor+0x78>
mov    -0x10(%rbp),%rax
lea    0xed9(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
movl   $0x24,-0x4(%rbp)
jmp    117f <editorSyntaxToColor+0x7f>
movl   $0x21,-0x4(%rbp)
jmp    117f <editorSyntaxToColor+0x7f>
movl   $0x20,-0x4(%rbp)
jmp    117f <editorSyntaxToColor+0x7f>
movl   $0x23,-0x4(%rbp)
jmp    117f <editorSyntaxToColor+0x7f>
movl   $0x1f,-0x4(%rbp)
jmp    117f <editorSyntaxToColor+0x7f>
movl   $0x22,-0x4(%rbp)
jmp    117f <editorSyntaxToColor+0x7f>
movl   $0x25,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<editorSyntaxToColor>:
add    $0xfffffffe,%edi
mov    $0x25,%eax
cmp    $0x6,%edi
ja     111a <editorSyntaxToColor+0x1a>
movslq %edi,%rax
lea    0xee9(%rip),%rcx
mov    (%rcx,%rax,4),%eax
ret

LLVM IR (-O0):
define i32 @editorSyntaxToColor(i32 %0) {
%2 = alloca i32
%3 = alloca i32
store i32 %0, i32* %3
%4 = load i32, i32* %3
switch i32 %4, label %11 [
i32 2, label %5
i32 3, label %5
i32 4, label %6
i32 5, label %7
i32 6, label %8
i32 7, label %9
i32 8, label %10
]
5: ; preds = %1, %1
store i32 36, i32* %2
br label %12
6: ; preds = %1
store i32 33, i32* %2
br label %12
7: ; preds = %1
store i32 32, i32* %2
br label %12
8: ; preds = %1
store i32 35, i32* %2
br label %12
9: ; preds = %1
store i32 31, i32* %2
br label %12
10: ; preds = %1
store i32 34, i32* %2
br label %12
11: ; preds = %1
store i32 37, i32* %2
br label %12
12: ; preds = %11, %10, %9, %8, %7, %6, %5
%13 = load i32, i32* %2
ret i32 %13
}

LLVM IR (-O2):
@switch.table.editorSyntaxToColor = [7 x i32] [i32 36, i32 36, i32 33, i32 32, i32 35, i32 31, i32 34]
define i32 @editorSyntaxToColor(i32 %0) {
%2 = add i32 %0, -2
%3 = icmp ult i32 %2, 7
br i1 %3, label %4, label %8
4: ; preds = %1
%5 = sext i32 %2 to i64
%6 = getelementptr inbounds [7 x i32], [7 x i32]* @switch.table.editorSyntaxToColor, i64 0, i64 %5
%7 = load i32, i32* %6
br label %8
8: ; preds = %1, %4
%9 = phi i32 [ %7, %4 ], [ 37, %1 ]
ret i32 %9
}
void Android420ToARGB() {}


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

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

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

LLVM IR (-O2):
define void @Android420ToARGB() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ isxdigit(int);
void t_isxdigit_0xcb() {
  Assert_real((isxdigit(203) == 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_isxdigit.c",
              1020, ("isxdigit should be 0 for 0xcb"));
}


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

x86 assembly (clang, -O2):
<t_isxdigit_0xcb>:
push   %rax
mov    $0xcb,%edi
call   1030 <isxdigit@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
lea    0xec5(%rip),%rsi
lea    0xf67(%rip),%rcx
mov    $0x3fc,%edx
pop    %rax
jmp    1040 <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_isxdigit.c\00"
@.str.1 = [30 x i8] c"isxdigit should be 0 for 0xcb\00"
define void @t_isxdigit_0xcb() {
%1 = call i64 @isxdigit(i32 203)
%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 1020, 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_isxdigit.c\00"
@.str.1 = [30 x i8] c"isxdigit should be 0 for 0xcb\00"
define void @t_isxdigit_0xcb() {
%1 = tail call i64 @isxdigit(i32 203)
%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 1020, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.1, i64 0, i64 0))
ret void
}
int none_busy(void) { return 1; }


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

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

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

LLVM IR (-O2):
define i32 @none_busy() {
ret i32 1
}
void op0xE4(void) {}


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

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

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

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

/* Variables and functions */
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ fputs(char *, int /*<<< orphan*/);
int /*<<< orphan*/ stderr;
void wHDF(char *file, XImage *image, int r[], int g[], int b[]) {
  fputs("**ERROR: wHDF not supported on this platform\n", stderr);
  exit(1);
}


x86 assembly (clang, -O0):
<wHDF>:
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    0x2e9d(%rip),%rax
mov    (%rax),%esi
lea    0xeb4(%rip),%rdi
call   1030 <fputs@plt>
mov    $0x1,%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<wHDF>:
push   %rax
mov    0x2eb8(%rip),%rax
mov    (%rax),%esi
lea    0xecf(%rip),%rdi
call   1030 <fputs@plt>
mov    $0x1,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@.str = [46 x i8] c"**ERROR: wHDF not supported on this platform\0A\00"
@stderr = global i32 0
define void @wHDF(i8* %0, i32* %1, i32* %2, i32* %3, i32* %4) {
%6 = alloca i8*
%7 = alloca i32*
%8 = alloca i32*
%9 = alloca i32*
%10 = alloca i32*
store i8* %0, i8** %6
store i32* %1, i32** %7
store i32* %2, i32** %8
store i32* %3, i32** %9
store i32* %4, i32** %10
%11 = load i32, i32* @stderr
%12 = call i32 @fputs(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str, i64 0, i64 0), i32 %11)
%13 = call i32 @exit(i32 1)
unreachable
}

LLVM IR (-O2):
@.str = [46 x i8] c"**ERROR: wHDF not supported on this platform\0A\00"
@stderr = global i32 0
define void @wHDF(i8* nocapture readnone %0, i32* nocapture readnone %1, i32* nocapture readnone %2, i32* nocapture readnone %3, i32* nocapture readnone %4) {
%6 = load i32, i32* @stderr
%7 = tail call i32 @fputs(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str, i64 0, i64 0), i32 %6)
%8 = tail call i32 @exit(i32 1)
unreachable
}
void lzx_memset(void *dst, int val, unsigned int count) {
  while (count--) {
    *(char *)(dst) = val;
    dst = (char *)(dst) + 1;
  }
}


x86 assembly (clang, -O0):
<lzx_memset>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %edx,-0x10(%rbp)
mov    -0x10(%rbp),%eax
mov    %eax,%ecx
add    $0xffffffff,%ecx
mov    %ecx,-0x10(%rbp)
cmp    $0x0,%eax
je     113e <lzx_memset+0x3e>
mov    -0xc(%rbp),%eax
mov    %al,%cl
mov    -0x8(%rbp),%rax
mov    %cl,(%rax)
mov    -0x8(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x8(%rbp)
jmp    110e <lzx_memset+0xe>
pop    %rbp
ret

x86 assembly (clang, -O2):
<lzx_memset>:
test   %edx,%edx
je     1120 <lzx_memset+0x10>
push   %rax
mov    %edx,%edx
call   1030 <memset@plt>
add    $0x8,%rsp
ret

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

LLVM IR (-O2):
define void @lzx_memset(i8* nocapture writeonly %0, i32 %1, i32 %2) {
%4 = icmp eq i32 %2, 0
br i1 %4, label %8, label %5
5: ; preds = %3
%6 = trunc i32 %1 to i8
%7 = zext i32 %2 to i64
br label %8
8: ; preds = %5, %3
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ buf;

/* Variables and functions */
int /*<<< orphan*/ strlcat(char *, char *, int);
int /*<<< orphan*/ strlcpy(char *, char *, int);
void f2() {
  char buf[5];
  strlcpy(buf, "abcd", sizeof(buf));
  strlcat(buf, "efgh", sizeof(buf));
}


x86 assembly (clang, -O0):
<f2>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
lea    -0x5(%rbp),%rdi
lea    0xecd(%rip),%rsi
mov    $0x5,%edx
call   1040 <strlcpy@plt>
lea    -0x5(%rbp),%rdi
lea    0xebd(%rip),%rsi
mov    $0x5,%edx
call   1030 <strlcat@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<f2>:
push   %rbx
sub    $0x10,%rsp
lea    0xed4(%rip),%rsi
lea    0xb(%rsp),%rbx
mov    %rbx,%rdi
mov    $0x5,%edx
call   1040 <strlcpy@plt>
lea    0xec0(%rip),%rsi
mov    %rbx,%rdi
mov    $0x5,%edx
call   1030 <strlcat@plt>
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [5 x i8] c"abcd\00"
@.str.1 = [5 x i8] c"efgh\00"
define void @f2() {
%1 = alloca [5 x i8]
%2 = getelementptr inbounds [5 x i8], [5 x i8]* %1, i64 0, i64 0
%3 = call i32 @strlcpy(i8* %2, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32 5)
%4 = getelementptr inbounds [5 x i8], [5 x i8]* %1, i64 0, i64 0
%5 = call i32 @strlcat(i8* %4, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i32 5)
ret void
}

LLVM IR (-O2):
@.str = [5 x i8] c"abcd\00"
@.str.1 = [5 x i8] c"efgh\00"
define void @f2() {
%1 = alloca [5 x i8]
%2 = getelementptr inbounds [5 x i8], [5 x i8]* %1, i64 0, i64 0
%3 = call i32 @strlcpy(i8* %2, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32 5)
%4 = call i32 @strlcat(i8* %2, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i32 5)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ appaserver_error_output_starting_argv_stderr(int, char **);
void appaserver_error_stderr(int argc, char **argv) {
  appaserver_error_output_starting_argv_stderr(argc, argv);
}


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

x86 assembly (clang, -O2):
<appaserver_error_stderr>:
jmp    1030 <appaserver_error_output_starting_argv_stderr@plt>

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

LLVM IR (-O2):
define void @appaserver_error_stderr(i32 %0, i8** %1) {
%3 = tail call i32 @appaserver_error_output_starting_argv_stderr(i32 %0, i8** %1)
ret void
}
/* Variables and functions */
char toupper(char);
void _string_upper_element(char *ch) { *ch = toupper(*ch); }


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

x86 assembly (clang, -O2):
<_string_upper_element>:
push   %rbx
mov    %rdi,%rbx
movsbl (%rdi),%edi
call   1030 <toupper@plt>
mov    %al,(%rbx)
pop    %rbx
ret

LLVM IR (-O0):
define void @_string_upper_element(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = load i8, i8* %3
%5 = call signext i8 @toupper(i8 signext %4)
%6 = load i8*, i8** %2
store i8 %5, i8* %6
ret void
}

LLVM IR (-O2):
define void @_string_upper_element(i8* nocapture %0) {
%2 = load i8, i8* %0
%3 = tail call signext i8 @toupper(i8 signext %2)
store i8 %3, i8* %0
ret void
}
/* Variables and functions */
int printf(char *, int);
int funcPrint(int a, int b) { return printf("%d\n", b); }


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

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

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

LLVM IR (-O2):
@.str = [4 x i8] c"%d\0A\00"
define i32 @funcPrint(i32 %0, i32 %1) {
%3 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %1)
ret i32 %3
}
/* Type definitions */
struct util_list {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ free(struct util_list *);
void util_list_free(struct util_list *list) { free(list); }


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

x86 assembly (clang, -O2):
<util_list_free>:
jmp    1030 <free@plt>

LLVM IR (-O0):
%struct.util_list = type { i32 }
define void @util_list_free(%struct.util_list* %0) {
%2 = alloca %struct.util_list*
store %struct.util_list* %0, %struct.util_list** %2
%3 = load %struct.util_list*, %struct.util_list** %2
%4 = call i32 @free(%struct.util_list* %3)
ret void
}

LLVM IR (-O2):
%struct.util_list = type { i32 }
define void @util_list_free(%struct.util_list* nocapture %0) {
%2 = tail call i32 @free(%struct.util_list* %0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, char, char);
void move(char a, char b) { printf("%c -> %c\n", a, b); }


x86 assembly (clang, -O0):
<move>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %sil,%al
mov    %dil,%cl
mov    %cl,-0x1(%rbp)
mov    %al,-0x2(%rbp)
mov    -0x1(%rbp),%al
lea    0xed2(%rip),%rdi
movsbl %al,%esi
movsbl -0x2(%rbp),%edx
call   1030 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

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

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

LLVM IR (-O2):
@.str = [10 x i8] c"%c -> %c\0A\00"
define void @move(i8 signext %0, i8 signext %1) {
%3 = tail call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), i8 signext %0, i8 signext %1)
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
void printShaperResult(unsigned int tbresult, unsigned int tbmindepth,
                       unsigned int tbmaxdepth, double tbrate, int dir,
                       FILE *fp) {
  if (tbresult == 0) {
    return;
  }
}


x86 assembly (clang, -O0):
<printShaperResult>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
movsd  %xmm0,-0x18(%rbp)
mov    %ecx,-0x1c(%rbp)
mov    %r8,-0x28(%rbp)
cmpl   $0x0,-0x4(%rbp)
jne    1128 <printShaperResult+0x28>
jmp    1128 <printShaperResult+0x28>
pop    %rbp
ret

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

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

LLVM IR (-O2):
define void @printShaperResult(i32 %0, i32 %1, i32 %2, double %3, i32 %4, i32* nocapture %5) {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ compute_match_rating_codex(char const *, char *);
char *malloc(int);
char *match_rating_codex(const char *str) {
  char *codex = malloc(7 * sizeof(char));
  if (!codex) {
    return NULL;
  }
  compute_match_rating_codex(str, codex);
  return codex;
}


x86 assembly (clang, -O0):
<match_rating_codex>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    $0x7,%edi
call   1030 <malloc@plt>
mov    %rax,-0x18(%rbp)
cmpq   $0x0,-0x18(%rbp)
jne    1152 <match_rating_codex+0x32>
movq   $0x0,-0x8(%rbp)
jmp    1167 <match_rating_codex+0x47>
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
call   1040 <compute_match_rating_codex@plt>
mov    -0x18(%rbp),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<match_rating_codex>:
push   %r14
push   %rbx
push   %rax
mov    %rdi,%r14
mov    $0x7,%edi
call   1030 <malloc@plt>
mov    %rax,%rbx
test   %rax,%rax
je     1144 <match_rating_codex+0x24>
mov    %r14,%rdi
mov    %rbx,%rsi
call   1040 <compute_match_rating_codex@plt>
mov    %rbx,%rax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

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

LLVM IR (-O2):
define i8* @match_rating_codex(i8* %0) {
%2 = tail call dereferenceable_or_null(7) i8* @malloc(i32 7)
%3 = icmp eq i8* %2, null
br i1 %3, label %6, label %4
4: ; preds = %1
%5 = tail call i32 @compute_match_rating_codex(i8* %0, i8* %2)
br label %6
6: ; preds = %1, %4
ret i8* %2
}
void gtk_tree_model_ref_node() {}


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

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

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

LLVM IR (-O2):
define void @gtk_tree_model_ref_node() {
ret void
}
void rop3_204_0_0(unsigned char *D, unsigned char S, unsigned char T) {
  *D = S;
}


x86 assembly (clang, -O0):
<rop3_204_0_0>:
push   %rbp
mov    %rsp,%rbp
mov    %dl,%al
mov    %sil,%cl
mov    %rdi,-0x8(%rbp)
mov    %cl,-0x9(%rbp)
mov    %al,-0xa(%rbp)
mov    -0x9(%rbp),%cl
mov    -0x8(%rbp),%rax
mov    %cl,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<rop3_204_0_0>:
mov    %sil,(%rdi)
ret

LLVM IR (-O0):
define void @rop3_204_0_0(i8* %0, i8 zeroext %1, i8 zeroext %2) {
%4 = alloca i8*
%5 = alloca i8
%6 = alloca i8
store i8* %0, i8** %4
store i8 %1, i8* %5
store i8 %2, i8* %6
%7 = load i8, i8* %5
%8 = load i8*, i8** %4
store i8 %7, i8* %8
ret void
}

LLVM IR (-O2):
define void @rop3_204_0_0(i8* nocapture writeonly %0, i8 zeroext %1, i8 zeroext %2) {
store i8 %1, i8* %0
ret void
}
/* Variables and functions */
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ warning(char *, int);
void die(int how) {
  warning("exiting (code = %d), goodbye...\n", how);
  exit(how);
}


x86 assembly (clang, -O0):
<die>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%esi
lea    0xecb(%rip),%rdi
call   1030 <warning@plt>
mov    -0x4(%rbp),%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<die>:
push   %rbx
mov    %edi,%ebx
lea    0xed6(%rip),%rdi
mov    %ebx,%esi
call   1030 <warning@plt>
mov    %ebx,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@.str = [33 x i8] c"exiting (code = %d), goodbye...\0A\00"
define void @die(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = call i32 @warning(i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str, i64 0, i64 0), i32 %3)
%5 = load i32, i32* %2
%6 = call i32 @exit(i32 %5)
unreachable
}

LLVM IR (-O2):
@.str = [33 x i8] c"exiting (code = %d), goodbye...\0A\00"
define void @die(i32 %0) {
%2 = tail call i32 @warning(i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str, i64 0, i64 0), i32 %0)
%3 = tail call i32 @exit(i32 %0)
unreachable
}
void rbtree_null_free(void *a) { (void)a; }


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

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

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

LLVM IR (-O2):
define void @rbtree_null_free(i8* nocapture %0) {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ seq_engine_live_stop_all_notes(int);
void seq_engine_key_split_changed(int track, int mode) {
  int i;
  for (i = 0; i < 6; i++) {
    seq_engine_live_stop_all_notes(i);
  }
}


x86 assembly (clang, -O0):
<seq_engine_key_split_changed>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
cmpl   $0x6,-0xc(%rbp)
jge    1145 <seq_engine_key_split_changed+0x35>
mov    -0xc(%rbp),%edi
call   1030 <seq_engine_live_stop_all_notes@plt>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    1125 <seq_engine_key_split_changed+0x15>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<seq_engine_key_split_changed>:
push   %rax
xor    %edi,%edi
call   1030 <seq_engine_live_stop_all_notes@plt>
mov    $0x1,%edi
call   1030 <seq_engine_live_stop_all_notes@plt>
mov    $0x2,%edi
call   1030 <seq_engine_live_stop_all_notes@plt>
mov    $0x3,%edi
call   1030 <seq_engine_live_stop_all_notes@plt>
mov    $0x4,%edi
call   1030 <seq_engine_live_stop_all_notes@plt>
mov    $0x5,%edi
pop    %rax
jmp    1030 <seq_engine_live_stop_all_notes@plt>

LLVM IR (-O0):
define void @seq_engine_key_split_changed(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store i32 %0, i32* %3
store i32 %1, i32* %4
store i32 0, i32* %5
br label %6
6: ; preds = %12, %2
%7 = load i32, i32* %5
%8 = icmp slt i32 %7, 6
br i1 %8, label %9, label %15
9: ; preds = %6
%10 = load i32, i32* %5
%11 = call i32 @seq_engine_live_stop_all_notes(i32 %10)
br label %12
12: ; preds = %9
%13 = load i32, i32* %5
%14 = add nsw i32 %13, 1
store i32 %14, i32* %5
br label %6
15: ; preds = %6
ret void
}

LLVM IR (-O2):
define void @seq_engine_key_split_changed(i32 %0, i32 %1) {
%3 = tail call i32 @seq_engine_live_stop_all_notes(i32 0)
%4 = tail call i32 @seq_engine_live_stop_all_notes(i32 1)
%5 = tail call i32 @seq_engine_live_stop_all_notes(i32 2)
%6 = tail call i32 @seq_engine_live_stop_all_notes(i32 3)
%7 = tail call i32 @seq_engine_live_stop_all_notes(i32 4)
%8 = tail call i32 @seq_engine_live_stop_all_notes(i32 5)
ret void
}
void Com_Crash_f(void) { *(int *)0 = 0x12345678; }


x86 assembly (clang, -O0):
<Com_Crash_f>:
push   %rbp
mov    %rsp,%rbp
xor    %eax,%eax
movl   $0x12345678,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
LLVM IR (-O0):
define void @Com_Crash_f() {
store i32 305419896, i32* null
ret void
}

LLVM IR (-O2):
void prebuilt_func_C() {}


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

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

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

LLVM IR (-O2):
define void @prebuilt_func_C() {
ret void
}
double pow2(double val) { return val * val; }


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

x86 assembly (clang, -O2):
<pow2>:
mulsd  %xmm0,%xmm0
ret

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

LLVM IR (-O2):
define double @pow2(double %0) {
%2 = fmul double %0, %0
ret double %2
}
/* Type definitions */
struct ipr_ioa {
  int dummy;
};

/* Variables and functions */
int ipr_stop_array(struct ipr_ioa *, char *, int);
int ipr_remove_hot_spare(struct ipr_ioa *ioa) {
  return ipr_stop_array(ioa, "Delete hot spare", 1);
}


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

x86 assembly (clang, -O2):
<ipr_remove_hot_spare>:
lea    0xee9(%rip),%rsi
mov    $0x1,%edx
jmp    1030 <ipr_stop_array@plt>

LLVM IR (-O0):
%struct.ipr_ioa = type { i32 }
@.str = [17 x i8] c"Delete hot spare\00"
define i32 @ipr_remove_hot_spare(%struct.ipr_ioa* %0) {
%2 = alloca %struct.ipr_ioa*
store %struct.ipr_ioa* %0, %struct.ipr_ioa** %2
%3 = load %struct.ipr_ioa*, %struct.ipr_ioa** %2
%4 = call i32 @ipr_stop_array(%struct.ipr_ioa* %3, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0), i32 1)
ret i32 %4
}

LLVM IR (-O2):
%struct.ipr_ioa = type { i32 }
@.str = [17 x i8] c"Delete hot spare\00"
define i32 @ipr_remove_hot_spare(%struct.ipr_ioa* %0) {
%2 = tail call i32 @ipr_stop_array(%struct.ipr_ioa* %0, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0), i32 1)
ret i32 %2
}
/* Type definitions */
typedef int /*<<< orphan*/ const uint64_t;
typedef int /*<<< orphan*/ uint32_t;
typedef scalar_t__ B;

/* Variables and functions */
uint64_t sse2_integerify(const void *B, size_t r) {
  const uint32_t *X = (const void *)((uintptr_t)(B) + (2 * r - 1) * 64);
  return X[0];
}


x86 assembly (clang, -O0):
<sse2_integerify>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
mov    -0x10(%rbp),%rcx
shl    $0x1,%rcx
sub    $0x1,%rcx
shl    $0x6,%rcx
add    %rcx,%rax
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
mov    (%rax),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<sse2_integerify>:
shl    $0x7,%rsi
mov    -0x40(%rdi,%rsi,1),%eax
ret

LLVM IR (-O0):
define i32 @sse2_integerify(i8* %0, i64 %1) {
%3 = alloca i8*
%4 = alloca i64
%5 = alloca i32*
store i8* %0, i8** %3
store i64 %1, i64* %4
%6 = load i8*, i8** %3
%7 = ptrtoint i8* %6 to i64
%8 = load i64, i64* %4
%9 = mul i64 2, %8
%10 = sub i64 %9, 1
%11 = mul i64 %10, 64
%12 = add i64 %7, %11
%13 = inttoptr i64 %12 to i8*
%14 = bitcast i8* %13 to i32*
store i32* %14, i32** %5
%15 = load i32*, i32** %5
%16 = getelementptr inbounds i32, i32* %15, i64 0
%17 = load i32, i32* %16
ret i32 %17
}

LLVM IR (-O2):
define i32 @sse2_integerify(i8* %0, i64 %1) {
%3 = ptrtoint i8* %0 to i64
%4 = shl i64 %1, 7
%5 = add i64 %3, -64
%6 = add i64 %5, %4
%7 = inttoptr i64 %6 to i32*
%8 = load i32, i32* %7
ret i32 %8
}