xunge/DecIR huggingface dataset:
/* Type definitions */
typedef int /*<<< orphan*/ uint8_t;
typedef int int32_t;

/* Variables and functions */
int tms_get_int(int /*<<< orphan*/ *, int *, int);
int32_t tms_msg_size(uint8_t *msg, int32_t n, int32_t *i) {
  int32_t size = 0;
  (*i) = 2;
  size = tms_get_int(msg, i, 1);
  (*i) = 4;
  if (size == 0xFF) {
    size = tms_get_int(msg, i, 4);
  }
  return (size);
}


x86 assembly (clang, -O0):
<tms_msg_size>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %rdx,-0x18(%rbp)
movl   $0x0,-0x1c(%rbp)
mov    -0x18(%rbp),%rax
movl   $0x2,(%rax)
mov    -0x8(%rbp),%rdi
mov    -0x18(%rbp),%rsi
mov    $0x1,%edx
call   1030 <tms_get_int@plt>
mov    %eax,-0x1c(%rbp)
mov    -0x18(%rbp),%rax
movl   $0x4,(%rax)
cmpl   $0xff,-0x1c(%rbp)
jne    1175 <tms_msg_size+0x65>
mov    -0x8(%rbp),%rdi
mov    -0x18(%rbp),%rsi
mov    $0x4,%edx
call   1030 <tms_get_int@plt>
mov    %eax,-0x1c(%rbp)
mov    -0x1c(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<tms_msg_size>:
push   %r14
push   %rbx
push   %rax
mov    %rdx,%rbx
mov    %rdi,%r14
movl   $0x2,(%rdx)
mov    %rdx,%rsi
mov    $0x1,%edx
call   1030 <tms_get_int@plt>
movl   $0x4,(%rbx)
cmp    $0xff,%eax
jne    1151 <tms_msg_size+0x41>
mov    %r14,%rdi
mov    %rbx,%rsi
mov    $0x4,%edx
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1030 <tms_get_int@plt>
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

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

LLVM IR (-O2):
define i32 @tms_msg_size(i32* %0, i32 %1, i32* %2) {
store i32 2, i32* %2
%4 = tail call i32 @tms_get_int(i32* %0, i32* %2, i32 1)
store i32 4, i32* %2
%5 = icmp eq i32 %4, 255
br i1 %5, label %6, label %8
6: ; preds = %3
%7 = tail call i32 @tms_get_int(i32* %0, i32* %2, i32 4)
br label %8
8: ; preds = %6, %3
%9 = phi i32 [ %7, %6 ], [ %4, %3 ]
ret i32 %9
}
/* Variables and functions */
scalar_t__ isemptyline(char *);
double strtod(char *, char **);
int parsedbl(char *buf, double *val) {
  char *end;
  val[0] = strtod(buf, &end);
  if (isemptyline(end))
    return (0);
  else
    return (1);
}


x86 assembly (clang, -O0):
<parsedbl>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    -0x10(%rbp),%rdi
lea    -0x20(%rbp),%rsi
call   1030 <strtod@plt>
mov    -0x18(%rbp),%rax
movsd  %xmm0,(%rax)
mov    -0x20(%rbp),%rdi
call   1040 <isemptyline@plt>
cmp    $0x0,%rax
je     1164 <parsedbl+0x44>
movl   $0x0,-0x4(%rbp)
jmp    116b <parsedbl+0x4b>
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<parsedbl>:
push   %rbx
sub    $0x10,%rsp
mov    %rsi,%rbx
lea    0x8(%rsp),%rsi
call   1030 <strtod@plt>
movsd  %xmm0,(%rbx)
mov    0x8(%rsp),%rdi
call   1040 <isemptyline@plt>
xor    %ecx,%ecx
test   %rax,%rax
sete   %cl
mov    %ecx,%eax
add    $0x10,%rsp
pop    %rbx
ret

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

LLVM IR (-O2):
define i32 @parsedbl(i8* %0, double* nocapture writeonly %1) {
%3 = alloca i8*
%4 = bitcast i8** %3 to i8*
%5 = call double @strtod(i8* %0, i8** %3)
store double %5, double* %1
%6 = load i8*, i8** %3
%7 = tail call i64 @isemptyline(i8* %6)
%8 = icmp eq i64 %7, 0
%9 = zext i1 %8 to i32
ret i32 %9
}
/* Variables and functions */
int _ada_use_c2phc(int, int *, int *, double *);
int number_of_dobldobl_factors(int *nf) {
  int *b, fail;
  double *c;
  fail = _ada_use_c2phc(656, nf, b, c);
  return fail;
}


x86 assembly (clang, -O0):
<number_of_dobldobl_factors>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rsi
mov    -0x10(%rbp),%rdx
mov    -0x20(%rbp),%rcx
mov    $0x290,%edi
call   1030 <_ada_use_c2phc@plt>
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<number_of_dobldobl_factors>:
mov    %rdi,%rsi
mov    $0x290,%edi
jmp    1030 <_ada_use_c2phc@plt>

LLVM IR (-O0):
define i32 @number_of_dobldobl_factors(i32* %0) {
%2 = alloca i32*
%3 = alloca i32*
%4 = alloca i32
%5 = alloca double*
store i32* %0, i32** %2
%6 = load i32*, i32** %2
%7 = load i32*, i32** %3
%8 = load double*, double** %5
%9 = call i32 @_ada_use_c2phc(i32 656, i32* %6, i32* %7, double* %8)
store i32 %9, i32* %4
%10 = load i32, i32* %4
ret i32 %10
}

LLVM IR (-O2):
define i32 @number_of_dobldobl_factors(i32* %0) {
%2 = tail call i32 @_ada_use_c2phc(i32 656, i32* %0, i32* undef, double* undef)
ret i32 %2
}
/* Variables and functions */
unsigned int zipmapDecodeLength(unsigned char *);
unsigned int zipmapEncodeLength(int /*<<< orphan*/ *, unsigned int);
unsigned int zipmapRawKeyLength(unsigned char *p) {
  unsigned int l = zipmapDecodeLength(p);
  return zipmapEncodeLength(NULL, l) + l;
}


x86 assembly (clang, -O0):
<zipmapRawKeyLength>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <zipmapDecodeLength@plt>
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%esi
xor    %eax,%eax
mov    %eax,%edi
call   1040 <zipmapEncodeLength@plt>
add    -0xc(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<zipmapRawKeyLength>:
push   %rbx
call   1030 <zipmapDecodeLength@plt>
mov    %eax,%ebx
xor    %edi,%edi
mov    %eax,%esi
call   1040 <zipmapEncodeLength@plt>
add    %ebx,%eax
pop    %rbx
ret

LLVM IR (-O0):
define i32 @zipmapRawKeyLength(i8* %0) {
%2 = alloca i8*
%3 = alloca i32
store i8* %0, i8** %2
%4 = load i8*, i8** %2
%5 = call i32 @zipmapDecodeLength(i8* %4)
store i32 %5, i32* %3
%6 = load i32, i32* %3
%7 = call i32 @zipmapEncodeLength(i32* null, i32 %6)
%8 = load i32, i32* %3
%9 = add i32 %7, %8
ret i32 %9
}

LLVM IR (-O2):
define i32 @zipmapRawKeyLength(i8* %0) {
%2 = tail call i32 @zipmapDecodeLength(i8* %0)
%3 = tail call i32 @zipmapEncodeLength(i32* null, i32 %2)
%4 = add i32 %3, %2
ret i32 %4
}
/* Variables and functions */
void *thread2(void *d) {
  int count2 = 0;
  count2++;
  return NULL;
}


x86 assembly (clang, -O0):
<thread2>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
xor    %eax,%eax
pop    %rbp
ret

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

LLVM IR (-O0):
define i8* @thread2(i8* %0) {
%2 = alloca i8*
%3 = alloca i32
store i8* %0, i8** %2
store i32 0, i32* %3
%4 = load i32, i32* %3
%5 = add nsw i32 %4, 1
store i32 %5, i32* %3
ret i8* null
}

LLVM IR (-O2):
define noalias i8* @thread2(i8* nocapture readnone %0) {
ret i8* null
}
f2(int *x) { *x = 666; }


x86 assembly (clang, -O0):
<f2>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
movl   $0x29a,(%rax)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<f2>:
movl   $0x29a,(%rdi)
ret

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

LLVM IR (-O2):
define i32 @f2(i32* nocapture writeonly %0) {
store i32 666, i32* %0
ret i32 undef
}
void null_free(void *data) {}


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

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

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

LLVM IR (-O2):
define void @null_free(i8* nocapture %0) {
ret void
}
void Unmark(int R, int C, int Size, short Col[], short Diag[], short AntiD[]) {
  int Idx;
  Col[C] = 0;
  Idx = R - C + Size - 1;
  Diag[Idx] = 0;
  Idx = R + C;
  AntiD[Idx] = 0;
}


x86 assembly (clang, -O0):
<Unmark>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %rcx,-0x18(%rbp)
mov    %r8,-0x20(%rbp)
mov    %r9,-0x28(%rbp)
mov    -0x18(%rbp),%rax
movslq -0x8(%rbp),%rcx
movw   $0x0,(%rax,%rcx,2)
mov    -0x4(%rbp),%eax
sub    -0x8(%rbp),%eax
add    -0xc(%rbp),%eax
sub    $0x1,%eax
mov    %eax,-0x2c(%rbp)
mov    -0x20(%rbp),%rax
movslq -0x2c(%rbp),%rcx
movw   $0x0,(%rax,%rcx,2)
mov    -0x4(%rbp),%eax
add    -0x8(%rbp),%eax
mov    %eax,-0x2c(%rbp)
mov    -0x28(%rbp),%rax
movslq -0x2c(%rbp),%rcx
movw   $0x0,(%rax,%rcx,2)
pop    %rbp
ret

x86 assembly (clang, -O2):
<Unmark>:
movslq %esi,%rax
movw   $0x0,(%rcx,%rax,2)
mov    %eax,%ecx
not    %ecx
add    %edi,%ecx
add    %edx,%ecx
movslq %ecx,%rcx
movw   $0x0,(%r8,%rcx,2)
add    %edi,%eax
cltq
movw   $0x0,(%r9,%rax,2)
ret

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

LLVM IR (-O2):
define void @Unmark(i32 %0, i32 %1, i32 %2, i16* nocapture writeonly %3, i16* nocapture writeonly %4, i16* nocapture writeonly %5) {
%7 = sext i32 %1 to i64
%8 = getelementptr inbounds i16, i16* %3, i64 %7
store i16 0, i16* %8
%9 = xor i32 %1, -1
%10 = add i32 %9, %0
%11 = add i32 %10, %2
%12 = sext i32 %11 to i64
%13 = getelementptr inbounds i16, i16* %4, i64 %12
store i16 0, i16* %13
%14 = add nsw i32 %1, %0
%15 = sext i32 %14 to i64
%16 = getelementptr inbounds i16, i16* %5, i64 %15
store i16 0, i16* %16
ret void
}
void gtk_response_type_get_type() {}


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

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

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

LLVM IR (-O2):
define void @gtk_response_type_get_type() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ strncpy(char *, char const *, size_t);
const char *fix_win_serial_name_r(const char *comname, char *obuf, size_t len) {
  strncpy(obuf, comname, len);
  return obuf;
}


x86 assembly (clang, -O0):
<fix_win_serial_name_r>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x10(%rbp),%rdi
mov    -0x8(%rbp),%rsi
mov    -0x18(%rbp),%rdx
call   1030 <strncpy@plt>
mov    -0x10(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<fix_win_serial_name_r>:
push   %rbx
mov    %rsi,%rbx
mov    %rdi,%rsi
mov    %rbx,%rdi
call   1030 <strncpy@plt>
mov    %rbx,%rax
pop    %rbx
ret

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

LLVM IR (-O2):
define i8* @fix_win_serial_name_r(i8* %0, i8* returned %1, i64 %2) {
%4 = tail call i32 @strncpy(i8* %1, i8* %0, i64 %2)
ret i8* %1
}
/* Type definitions */
struct isal_zstream {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ isal_deflate_finish_base(struct isal_zstream *);
void isal_deflate_finish(struct isal_zstream *stream) {
  isal_deflate_finish_base(stream);
}


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

x86 assembly (clang, -O2):
<isal_deflate_finish>:
jmp    1030 <isal_deflate_finish_base@plt>

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

LLVM IR (-O2):
%struct.isal_zstream = type { i32 }
define void @isal_deflate_finish(%struct.isal_zstream* %0) {
%2 = tail call i32 @isal_deflate_finish_base(%struct.isal_zstream* %0)
ret void
}
/* Variables and functions */
int sci_get_chip_id();
int soc_id_is_sc9631v0(void) {
  return ((sci_get_chip_id() & (0xFFFF0000)) == ((0x96310000) & (0xFFFF0000)));
}


x86 assembly (clang, -O0):
<soc_id_is_sc9631v0>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1030 <sci_get_chip_id@plt>
and    $0xffff0000,%eax
cmp    $0x96310000,%eax
sete   %al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<soc_id_is_sc9631v0>:
push   %rax
xor    %eax,%eax
call   1030 <sci_get_chip_id@plt>
and    $0xffff0000,%eax
xor    %ecx,%ecx
cmp    $0x96310000,%eax
sete   %cl
mov    %ecx,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @soc_id_is_sc9631v0() {
%1 = call i32 (...) @sci_get_chip_id()
%2 = and i32 %1, -65536
%3 = icmp eq i32 %2, -1775173632
%4 = zext i1 %3 to i32
ret i32 %4
}

LLVM IR (-O2):
define i32 @soc_id_is_sc9631v0() {
%1 = tail call i32 (...) @sci_get_chip_id()
%2 = and i32 %1, -65536
%3 = icmp eq i32 %2, -1775173632
%4 = zext i1 %3 to i32
ret i32 %4
}
int SKP_Silk_lin2log(const int inLin) {
  int lz, frac_Q7;
  SKP_Silk_CLZ_FRAC(inLin, &lz, &frac_Q7);
  return (((31 - lz) << (7)) +
          ((frac_Q7) +
           ((((((frac_Q7) * (128 - frac_Q7))) >> 16) * (int)((short)(179))) +
            ((((((frac_Q7) * (128 - frac_Q7))) & 0x0000FFFF) *
              (int)((short)(179))) >>
             16))));
}


x86 assembly (clang, -O0):
<SKP_Silk_lin2log>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%edi
lea    -0x8(%rbp),%rsi
lea    -0xc(%rbp),%rdx
mov    $0x0,%al
call   1030 <SKP_Silk_CLZ_FRAC@plt>
mov    $0x1f,%eax
sub    -0x8(%rbp),%eax
shl    $0x7,%eax
mov    -0xc(%rbp),%ecx
mov    -0xc(%rbp),%edx
mov    $0x80,%esi
sub    -0xc(%rbp),%esi
imul   %esi,%edx
sar    $0x10,%edx
imul   $0xb3,%edx,%edx
mov    -0xc(%rbp),%esi
mov    $0x80,%edi
sub    -0xc(%rbp),%edi
imul   %edi,%esi
and    $0xffff,%esi
imul   $0xb3,%esi,%esi
sar    $0x10,%esi
add    %esi,%edx
add    %edx,%ecx
add    %ecx,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<SKP_Silk_lin2log>:
push   %rax
lea    0x4(%rsp),%rsi
mov    %rsp,%rdx
xor    %eax,%eax
call   1030 <SKP_Silk_CLZ_FRAC@plt>
mov    0x4(%rsp),%eax
shl    $0x7,%eax
mov    (%rsp),%ecx
mov    $0x80,%edx
sub    %ecx,%edx
imul   %ecx,%edx
movzwl %dx,%esi
sar    $0x10,%edx
imul   $0xb3,%edx,%edx
imul   $0xb3,%esi,%esi
shr    $0x10,%esi
sub    %eax,%ecx
add    %edx,%ecx
lea    (%rsi,%rcx,1),%eax
add    $0xf80,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @SKP_Silk_lin2log(i32 %0) {
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
store i32 %0, i32* %2
%5 = load i32, i32* %2
%6 = call i32 (i32, i32*, i32*, ...) bitcast (i32 (...)* @SKP_Silk_CLZ_FRAC to i32 (i32, i32*, i32*, ...)*)(i32 %5, i32* %3, i32* %4)
%7 = load i32, i32* %3
%8 = sub nsw i32 31, %7
%9 = shl i32 %8, 7
%10 = load i32, i32* %4
%11 = load i32, i32* %4
%12 = load i32, i32* %4
%13 = sub nsw i32 128, %12
%14 = mul nsw i32 %11, %13
%15 = ashr i32 %14, 16
%16 = mul nsw i32 %15, 179
%17 = load i32, i32* %4
%18 = load i32, i32* %4
%19 = sub nsw i32 128, %18
%20 = mul nsw i32 %17, %19
%21 = and i32 %20, 65535
%22 = mul nsw i32 %21, 179
%23 = ashr i32 %22, 16
%24 = add nsw i32 %16, %23
%25 = add nsw i32 %10, %24
%26 = add nsw i32 %9, %25
ret i32 %26
}

LLVM IR (-O2):
define i32 @SKP_Silk_lin2log(i32 %0) {
%2 = alloca i32
%3 = alloca i32
%4 = bitcast i32* %2 to i8*
%5 = bitcast i32* %3 to i8*
%6 = call i32 (i32, i32*, i32*, ...) bitcast (i32 (...)* @SKP_Silk_CLZ_FRAC to i32 (i32, i32*, i32*, ...)*)(i32 %0, i32* %2, i32* %3)
%7 = load i32, i32* %2
%8 = mul i32 %7, -128
%9 = load i32, i32* %3
%10 = sub nsw i32 128, %9
%11 = mul nsw i32 %10, %9
%12 = ashr i32 %11, 16
%13 = mul nsw i32 %12, 179
%14 = and i32 %11, 65535
%15 = mul nuw nsw i32 %14, 179
%16 = lshr i32 %15, 16
%17 = add i32 %8, 3968
%18 = add i32 %17, %9
%19 = add i32 %18, %13
%20 = add i32 %19, %16
ret i32 %20
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int, int);
void razmeni(int a, int b) {
  int c;
  c = a;
  a = b;
  b = c;
  printf("a = %d, b = %d\n", a, b);
}


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

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

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

LLVM IR (-O2):
@.str = [16 x i8] c"a = %d, b = %d\0A\00"
define void @razmeni(i32 %0, i32 %1) {
%3 = tail call i32 @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str, i64 0, i64 0), i32 %1, i32 %0)
ret void
}
int updateOnMissTest() { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @updateOnMissTest() {
ret i32 0
}
const char *hello(void) { return "Hello, World!"; }


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

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

LLVM IR (-O0):
@.str = [14 x i8] c"Hello, World!\00"
define i8* @hello() {
ret i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0)
}

LLVM IR (-O2):
@.str = [14 x i8] c"Hello, World!\00"
define i8* @hello() {
ret i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0)
}
/* Variables and functions */
int /*<<< orphan*/ init_freelist(int);
void init_myalloc(int size) { init_freelist(size); }


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

x86 assembly (clang, -O2):
<init_myalloc>:
jmp    1030 <init_freelist@plt>

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

LLVM IR (-O2):
define void @init_myalloc(i32 %0) {
%2 = tail call i32 @init_freelist(i32 %0)
ret void
}
void gtk_list_store_clear() {}


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

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

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

LLVM IR (-O2):
define void @gtk_list_store_clear() {
ret void
}
float remainderf(float x, float y) {
  unsigned short fpsr;
  do
    __asm__("fprem1; fnstsw %%ax" : "+t"(x), "=a"(fpsr) : "u"(y));
  while (fpsr & 0x400);
  return x;
}


x86 assembly (clang, -O0):
<remainderf>:
push   %rbp
mov    %rsp,%rbp
movss  %xmm0,-0x4(%rbp)
movss  %xmm1,-0x8(%rbp)
movss  -0x4(%rbp),%xmm0
movss  -0x8(%rbp),%xmm1
movss  %xmm1,-0x10(%rbp)
movss  %xmm0,-0x14(%rbp)
flds   -0x10(%rbp)
flds   -0x14(%rbp)
fprem1
fnstsw %ax
fstp   %st(1)
fstps  -0x18(%rbp)
movss  -0x18(%rbp),%xmm0
movss  %xmm0,-0x4(%rbp)
mov    %ax,-0xa(%rbp)
movzwl -0xa(%rbp),%eax
and    $0x400,%eax
cmp    $0x0,%eax
jne    110e <remainderf+0xe>
movss  -0x4(%rbp),%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<remainderf>:
movss  %xmm1,-0x4(%rsp)
movss  %xmm0,-0x8(%rsp)
flds   -0x4(%rsp)
flds   -0x8(%rsp)
fprem1
fnstsw %ax
fstp   %st(1)
fstps  -0xc(%rsp)
movss  -0xc(%rsp),%xmm0
test   $0x400,%eax
jne    1100 <remainderf>
ret

LLVM IR (-O0):
define float @remainderf(float %0, float %1) {
%3 = alloca float
%4 = alloca float
%5 = alloca i16
store float %0, float* %3
store float %1, float* %4
br label %6
6: ; preds = %12, %2
%7 = load float, float* %3
%8 = load float, float* %4
%9 = call { float, i16 } asm "fprem1; fnstsw %ax", "={st},={ax},{st(1)},0,~{dirflag},~{fpsr},~{flags}"(float %8, float %7)
%10 = extractvalue { float, i16 } %9, 0
%11 = extractvalue { float, i16 } %9, 1
store float %10, float* %3
store i16 %11, i16* %5
br label %12
12: ; preds = %6
%13 = load i16, i16* %5
%14 = zext i16 %13 to i32
%15 = and i32 %14, 1024
%16 = icmp ne i32 %15, 0
br i1 %16, label %6, label %17
17: ; preds = %12
%18 = load float, float* %3
ret float %18
}

LLVM IR (-O2):
define float @remainderf(float %0, float %1) {
br label %3
3: ; preds = %3, %2
%4 = phi float [ %0, %2 ], [ %6, %3 ]
%5 = tail call { float, i16 } asm "fprem1; fnstsw %ax", "={st},={ax},{st(1)},0,~{dirflag},~{fpsr},~{flags}"(float %1, float %4)
%6 = extractvalue { float, i16 } %5, 0
%7 = extractvalue { float, i16 } %5, 1
%8 = and i16 %7, 1024
%9 = icmp eq i16 %8, 0
br i1 %9, label %10, label %3
10: ; preds = %3
%11 = extractvalue { float, i16 } %5, 0
ret float %11
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int);
int main() {
  int counter = 1;
  while (counter <= 10) {
    if (counter % 2 == 0) {
      counter++;
      continue;
    }
    printf("%i\n", counter);
    counter++;
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x1,-0x8(%rbp)
cmpl   $0xa,-0x8(%rbp)
jg     116f <main+0x5f>
mov    -0x8(%rbp),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
cmp    $0x0,%edx
jne    1152 <main+0x42>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1126 <main+0x16>
mov    -0x8(%rbp),%esi
lea    0xea4(%rip),%rdi
call   1030 <printf@plt>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1126 <main+0x16>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
lea    0xee8(%rip),%rbx
mov    %rbx,%rdi
mov    $0x1,%esi
call   1030 <printf@plt>
mov    %rbx,%rdi
mov    $0x3,%esi
call   1030 <printf@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
call   1030 <printf@plt>
mov    %rbx,%rdi
mov    $0x7,%esi
call   1030 <printf@plt>
mov    %rbx,%rdi
mov    $0x9,%esi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rbx
ret

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

LLVM IR (-O2):
@.str = [4 x i8] c"%i\0A\00"
define i32 @main() {
%1 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 1)
%2 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 3)
%3 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 5)
%4 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 7)
%5 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 9)
ret i32 0
}
int match(char a, char b) {
  if (a == '[' && b == ']')
    return 1;
  if (a == '{' && b == '}')
    return 1;
  if (a == '(' && b == ')')
    return 1;
}


x86 assembly (clang, -O0):
<match>:
push   %rbp
mov    %rsp,%rbp
mov    %sil,%al
mov    %dil,%cl
mov    %cl,-0x5(%rbp)
mov    %al,-0x6(%rbp)
movsbl -0x5(%rbp),%eax
cmp    $0x5b,%eax
jne    1136 <match+0x36>
movsbl -0x6(%rbp),%eax
cmp    $0x5d,%eax
jne    1136 <match+0x36>
movl   $0x1,-0x4(%rbp)
jmp    117d <match+0x7d>
movsbl -0x5(%rbp),%eax
cmp    $0x7b,%eax
jne    115c <match+0x5c>
movsbl -0x6(%rbp),%eax
cmp    $0x7d,%eax
jne    115c <match+0x5c>
movl   $0x1,-0x4(%rbp)
jmp    117d <match+0x7d>
movsbl -0x5(%rbp),%eax
cmp    $0x28,%eax
jne    117d <match+0x7d>
movsbl -0x6(%rbp),%eax
cmp    $0x29,%eax
jne    117d <match+0x7d>
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

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

LLVM IR (-O0):
define i32 @match(i8 signext %0, i8 signext %1) {
%3 = alloca i32
%4 = alloca i8
%5 = alloca i8
store i8 %0, i8* %4
store i8 %1, i8* %5
%6 = load i8, i8* %4
%7 = sext i8 %6 to i32
%8 = icmp eq i32 %7, 91
br i1 %8, label %9, label %14
9: ; preds = %2
%10 = load i8, i8* %5
%11 = sext i8 %10 to i32
%12 = icmp eq i32 %11, 93
br i1 %12, label %13, label %14
13: ; preds = %9
store i32 1, i32* %3
br label %32
14: ; preds = %9, %2
%15 = load i8, i8* %4
%16 = sext i8 %15 to i32
%17 = icmp eq i32 %16, 123
br i1 %17, label %18, label %23
18: ; preds = %14
%19 = load i8, i8* %5
%20 = sext i8 %19 to i32
%21 = icmp eq i32 %20, 125
br i1 %21, label %22, label %23
22: ; preds = %18
store i32 1, i32* %3
br label %32
23: ; preds = %18, %14
%24 = load i8, i8* %4
%25 = sext i8 %24 to i32
%26 = icmp eq i32 %25, 40
br i1 %26, label %27, label %32
27: ; preds = %23
%28 = load i8, i8* %5
%29 = sext i8 %28 to i32
%30 = icmp eq i32 %29, 41
br i1 %30, label %31, label %32
31: ; preds = %27
store i32 1, i32* %3
br label %32
32: ; preds = %13, %22, %31, %27, %23
%33 = load i32, i32* %3
ret i32 %33
}

LLVM IR (-O2):
define i32 @match(i8 signext %0, i8 signext %1) {
ret i32 1
}
long long f6(void) {
  unsigned int a = 0x80000000;
  return (a & 0x80000000) ? 0x80000000LL : 0LL;
}


x86 assembly (clang, -O0):
<f6>:
push   %rbp
mov    %rsp,%rbp
movl   $0x80000000,-0x4(%rbp)
mov    -0x4(%rbp),%edx
and    $0x80000000,%edx
xor    %eax,%eax
mov    $0x80000000,%ecx
cmp    $0x0,%edx
cmovne %rcx,%rax
pop    %rbp
ret

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

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

LLVM IR (-O2):
define i64 @f6() {
ret i64 2147483648
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, char const *);
void _print_usage_header(const char *command) {
  printf("Usage: %s [OPTION]... [FILE]\n"
         "Reads FILE (or stdin if no FILE given or when FILE is '-').\n"
         "and sends it to buckets (logrotate comes to mind).\n",
         command);
}


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

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

LLVM IR (-O0):
@.str = [141 x i8] c"Usage: %s [OPTION]... [FILE]\0AReads FILE (or stdin if no FILE given or when FILE is '-').\0Aand sends it to buckets (logrotate comes to mind).\0A\00"
define void @_print_usage_header(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = call i32 @printf(i8* getelementptr inbounds ([141 x i8], [141 x i8]* @.str, i64 0, i64 0), i8* %3)
ret void
}

LLVM IR (-O2):
@.str = [141 x i8] c"Usage: %s [OPTION]... [FILE]\0AReads FILE (or stdin if no FILE given or when FILE is '-').\0Aand sends it to buckets (logrotate comes to mind).\0A\00"
define void @_print_usage_header(i8* %0) {
%2 = tail call i32 @printf(i8* getelementptr inbounds ([141 x i8], [141 x i8]* @.str, i64 0, i64 0), i8* %0)
ret void
}
/* Variables and functions */
int is_first_in_group_PreAllocGrp(size_t __tag) {
  return (__tag == (79)) ? 1 : 0;
}


x86 assembly (clang, -O0):
<is_first_in_group_PreAllocGrp>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdx
xor    %eax,%eax
mov    $0x1,%ecx
cmp    $0x4f,%rdx
cmove  %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_first_in_group_PreAllocGrp>:
xor    %eax,%eax
cmp    $0x4f,%rdi
sete   %al
ret

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

LLVM IR (-O2):
define i32 @is_first_in_group_PreAllocGrp(i64 %0) {
%2 = icmp eq i64 %0, 79
%3 = zext i1 %2 to i32
ret i32 %3
}
void set_need_resched(void) {}


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

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

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

LLVM IR (-O2):
define void @set_need_resched() {
ret void
}
void fptr(void (*fp)(void)) {
  int i;
  for (i = 0; i < 50; i++)
    (*fp)();
}


x86 assembly (clang, -O0):
<fptr>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
cmpl   $0x32,-0xc(%rbp)
jge    112e <fptr+0x2e>
call   *-0x8(%rbp)
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    1113 <fptr+0x13>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<fptr>:
push   %rbx
mov    %rdi,%rbx
call   *%rdi
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
call   *%rbx
mov    %rbx,%rax
pop    %rbx
jmp    *%rax

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

LLVM IR (-O2):
define void @fptr(void ()* nocapture %0) {
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
tail call void %0()
ret void
}
/* Variables and functions */
scalar_t__ main2_parallel(int, int /*<<< orphan*/);
scalar_t__ main2_serial(int, int /*<<< orphan*/);
int main(void) {
  if (main2_serial(1, 0) != main2_parallel(1, 0))
    return 1;
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0x1,%edi
xor    %esi,%esi
call   1030 <main2_serial@plt>
mov    %rax,-0x10(%rbp)
mov    $0x1,%edi
xor    %esi,%esi
call   1040 <main2_parallel@plt>
mov    %rax,%rcx
mov    -0x10(%rbp),%rax
cmp    %rcx,%rax
je     1167 <main+0x47>
movl   $0x1,-0x4(%rbp)
jmp    116e <main+0x4e>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
mov    $0x1,%edi
xor    %esi,%esi
call   1030 <main2_serial@plt>
mov    %rax,%rbx
mov    $0x1,%edi
xor    %esi,%esi
call   1040 <main2_parallel@plt>
xor    %ecx,%ecx
cmp    %rax,%rbx
setne  %cl
mov    %ecx,%eax
pop    %rbx
ret

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = call i64 @main2_serial(i32 1, i32 0)
%3 = call i64 @main2_parallel(i32 1, i32 0)
%4 = icmp ne i64 %2, %3
br i1 %4, label %5, label %6
5: ; preds = %0
store i32 1, i32* %1
br label %7
6: ; preds = %0
store i32 0, i32* %1
br label %7
7: ; preds = %6, %5
%8 = load i32, i32* %1
ret i32 %8
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i64 @main2_serial(i32 1, i32 0)
%2 = tail call i64 @main2_parallel(i32 1, i32 0)
%3 = icmp ne i64 %1, %2
%4 = zext i1 %3 to i32
ret i32 %4
}
/* Type definitions */
struct printf_info {
  int dummy;
};

/* Variables and functions */
int ret0(const struct printf_info *info, size_t n, int *argtypes) { return 0; }


x86 assembly (clang, -O0):
<ret0>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
xor    %eax,%eax
pop    %rbp
ret

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

LLVM IR (-O0):
%struct.printf_info = type { i32 }
define i32 @ret0(%struct.printf_info* %0, i64 %1, i32* %2) {
%4 = alloca %struct.printf_info*
%5 = alloca i64
%6 = alloca i32*
store %struct.printf_info* %0, %struct.printf_info** %4
store i64 %1, i64* %5
store i32* %2, i32** %6
ret i32 0
}

LLVM IR (-O2):
%struct.printf_info = type { i32 }
define i32 @ret0(%struct.printf_info* nocapture readnone %0, i64 %1, i32* nocapture readnone %2) {
ret i32 0
}
/* Variables and functions */
size_t __tolower(int);
void __attribute((always_)) re_set_fastmap(char *fastmap, int icase, int ch) {
  fastmap[ch] = 1;
  if (icase)
    fastmap[__tolower(ch)] = 1;
}


x86 assembly (clang, -O0):
<re_set_fastmap>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %edx,-0x10(%rbp)
mov    -0x8(%rbp),%rax
movslq -0x10(%rbp),%rcx
movb   $0x1,(%rax,%rcx,1)
cmpl   $0x0,-0xc(%rbp)
je     1153 <re_set_fastmap+0x43>
mov    -0x8(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    -0x10(%rbp),%edi
call   1030 <__tolower@plt>
mov    %rax,%rcx
mov    -0x18(%rbp),%rax
movb   $0x1,(%rax,%rcx,1)
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<re_set_fastmap>:
push   %rbx
movslq %edx,%rax
movb   $0x1,(%rdi,%rax,1)
test   %esi,%esi
je     112a <re_set_fastmap+0x1a>
mov    %rdi,%rbx
mov    %edx,%edi
call   1030 <__tolower@plt>
movb   $0x1,(%rbx,%rax,1)
pop    %rbx
ret

LLVM IR (-O0):
define void @re_set_fastmap(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
%7 = load i8*, i8** %4
%8 = load i32, i32* %6
%9 = sext i32 %8 to i64
%10 = getelementptr inbounds i8, i8* %7, i64 %9
store i8 1, i8* %10
%11 = load i32, i32* %5
%12 = icmp ne i32 %11, 0
br i1 %12, label %13, label %18
13: ; preds = %3
%14 = load i8*, i8** %4
%15 = load i32, i32* %6
%16 = call i64 @__tolower(i32 %15)
%17 = getelementptr inbounds i8, i8* %14, i64 %16
store i8 1, i8* %17
br label %18
18: ; preds = %13, %3
ret void
}

LLVM IR (-O2):
define void @re_set_fastmap(i8* nocapture writeonly %0, i32 %1, i32 %2) {
%4 = sext i32 %2 to i64
%5 = getelementptr inbounds i8, i8* %0, i64 %4
store i8 1, i8* %5
%6 = icmp eq i32 %1, 0
br i1 %6, label %10, label %7
7: ; preds = %3
%8 = tail call i64 @__tolower(i32 %2)
%9 = getelementptr inbounds i8, i8* %0, i64 %8
store i8 1, i8* %9
br label %10
10: ; preds = %7, %3
ret void
}
unsigned int atoi_b10(char *s) {
  unsigned int result = 0;
  int i;
  for (i = 0; i < 2; i++, s++)
    result = 10 * result + (*s) - '0';
  return result;
}


x86 assembly (clang, -O0):
<atoi_b10>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
movl   $0x0,-0x10(%rbp)
cmpl   $0x2,-0x10(%rbp)
jge    114d <atoi_b10+0x4d>
imul   $0xa,-0xc(%rbp),%eax
mov    -0x8(%rbp),%rcx
movsbl (%rcx),%ecx
add    %ecx,%eax
sub    $0x30,%eax
mov    %eax,-0xc(%rbp)
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
mov    -0x8(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x8(%rbp)
jmp    1116 <atoi_b10+0x16>
mov    -0xc(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<atoi_b10>:
movsbl (%rdi),%eax
lea    (%rax,%rax,4),%eax
movsbl 0x1(%rdi),%ecx
lea    (%rcx,%rax,2),%eax
add    $0xfffffdf0,%eax
ret

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

LLVM IR (-O2):
define i32 @atoi_b10(i8* nocapture %0) {
%2 = load i8, i8* %0
%3 = sext i8 %2 to i32
%4 = getelementptr inbounds i8, i8* %0, i64 1
%5 = mul nsw i32 %3, 10
%6 = load i8, i8* %4
%7 = sext i8 %6 to i32
%8 = add nsw i32 %5, -528
%9 = add nsw i32 %8, %7
ret i32 %9
}
void ff_hevc_put_hevc_qpel_v12_12_sse4() {}


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

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

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

LLVM IR (-O2):
define void @ff_hevc_put_hevc_qpel_v12_12_sse4() {
ret void
}
/* Variables and functions */
int atoi(char *);
int /*<<< orphan*/ printf(char *, int);
int main() {
  int val = 0;
  char card_name[] = "Q";
  switch (card_name[0]) {
  case 'K':
  case 'Q':
  case 'J':
    val = 10;
    break;
  case 'A':
    val = 11;
    break;
  default:
    val = atoi(card_name);
  }
  printf("%d\n", val);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
movw   $0x51,-0xa(%rbp)
movsbl -0xa(%rbp),%eax
mov    %eax,-0x10(%rbp)
sub    $0x41,%eax
je     1182 <main+0x62>
jmp    1151 <main+0x31>
mov    -0x10(%rbp),%eax
add    $0xffffffb6,%eax
sub    $0x2,%eax
jb     1176 <main+0x56>
jmp    1165 <main+0x45>
mov    -0x10(%rbp),%eax
sub    $0x51,%eax
jne    118e <main+0x6e>
jmp    1176 <main+0x56>
movl   $0xa,-0x8(%rbp)
jmp    119a <main+0x7a>
movl   $0xb,-0x8(%rbp)
jmp    119a <main+0x7a>
lea    -0xa(%rbp),%rdi
call   1040 <atoi@plt>
mov    %eax,-0x8(%rbp)
mov    -0x8(%rbp),%esi
lea    0xe5e(%rip),%rdi
call   1030 <printf@plt>
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
@__const.main.card_name = [2 x i8] c"Q\00"
@.str = [4 x i8] c"%d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca [2 x i8]
store i32 0, i32* %1
store i32 0, i32* %2
%4 = bitcast [2 x i8]* %3 to i8*
%5 = getelementptr inbounds [2 x i8], [2 x i8]* %3, i64 0, i64 0
%6 = load i8, i8* %5
%7 = sext i8 %6 to i32
switch i32 %7, label %10 [
i32 75, label %8
i32 81, label %8
i32 74, label %8
i32 65, label %9
]
8: ; preds = %0, %0, %0
store i32 10, i32* %2
br label %13
9: ; preds = %0
store i32 11, i32* %2
br label %13
10: ; preds = %0
%11 = getelementptr inbounds [2 x i8], [2 x i8]* %3, i64 0, i64 0
%12 = call i32 @atoi(i8* %11)
store i32 %12, i32* %2
br label %13
13: ; preds = %10, %9, %8
%14 = load i32, i32* %2
%15 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %14)
%16 = load i32, i32* %1
ret i32 %16
}

LLVM IR (-O2):
@.str = [4 x i8] c"%d\0A\00"
define i32 @main() {
%1 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 10)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ print_on_level(int, char *);
int cr_plugin_init(void) {
  print_on_level((3), "Initialized macvlan dumper\n");
  return 0;
}


x86 assembly (clang, -O0):
<cr_plugin_init>:
push   %rbp
mov    %rsp,%rbp
mov    $0x3,%edi
lea    0xee0(%rip),%rsi
call   1030 <print_on_level@plt>
xor    %eax,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<cr_plugin_init>:
push   %rax
lea    0xee8(%rip),%rsi
mov    $0x3,%edi
call   1030 <print_on_level@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [28 x i8] c"Initialized macvlan dumper\0A\00"
define i32 @cr_plugin_init() {
%1 = call i32 @print_on_level(i32 3, i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@.str = [28 x i8] c"Initialized macvlan dumper\0A\00"
define i32 @cr_plugin_init() {
%1 = tail call i32 @print_on_level(i32 3, i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str, i64 0, i64 0))
ret i32 0
}
/* Variables and functions */
int _func_xpath_operators(char *, void *, int, int);
int _func_xpath_operator_equal(char *chunk, void *data) {
  return _func_xpath_operators(chunk, data, 8, 8);
}


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

x86 assembly (clang, -O2):
<_func_xpath_operator_equal>:
mov    $0x8,%edx
mov    $0x8,%ecx
jmp    1030 <_func_xpath_operators@plt>

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

LLVM IR (-O2):
define i32 @_func_xpath_operator_equal(i8* %0, i8* %1) {
%3 = tail call i32 @_func_xpath_operators(i8* %0, i8* %1, i32 8, i32 8)
ret i32 %3
}
/* Variables and functions */
char *parse_atom(char *, char **);
char *parse_quoted_string(char *, char **);
char *parse_word_simple(char *word, char **pbuf) {
  char *ret;
  ret = parse_quoted_string(word, pbuf);
  if (!ret)
    ret = parse_atom(word, pbuf);
  return ret;
}


x86 assembly (clang, -O0):
<parse_word_simple>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1040 <parse_quoted_string@plt>
mov    %rax,-0x18(%rbp)
cmpq   $0x0,-0x18(%rbp)
jne    115d <parse_word_simple+0x3d>
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1030 <parse_atom@plt>
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<parse_word_simple>:
push   %r14
push   %rbx
push   %rax
mov    %rsi,%r14
mov    %rdi,%rbx
call   1040 <parse_quoted_string@plt>
test   %rax,%rax
je     113c <parse_word_simple+0x1c>
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret
mov    %rbx,%rdi
mov    %r14,%rsi
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1030 <parse_atom@plt>

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

LLVM IR (-O2):
define i8* @parse_word_simple(i8* %0, i8** %1) {
%3 = tail call i8* @parse_quoted_string(i8* %0, i8** %1)
%4 = icmp eq i8* %3, null
br i1 %4, label %5, label %7
5: ; preds = %2
%6 = tail call i8* @parse_atom(i8* %0, i8** %1)
br label %7
7: ; preds = %5, %2
%8 = phi i8* [ %3, %2 ], [ %6, %5 ]
ret i8* %8
}