xunge/DecIR huggingface dataset:
void assert1(void) { ((void)0); }


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

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

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

LLVM IR (-O2):
define void @assert1() {
ret void
}
int test_imm_1Dint16_reg(short val) {
  return ((val) & (-0x1D << 0)) ? -20 : -40;
}


x86 assembly (clang, -O0):
<test_imm_1Dint16_reg>:
push   %rbp
mov    %rsp,%rbp
mov    %di,%ax
mov    %ax,-0x2(%rbp)
movswl -0x2(%rbp),%edx
and    $0xffffffe3,%edx
mov    $0xffffffd8,%eax
mov    $0xffffffec,%ecx
cmp    $0x0,%edx
cmovne %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_imm_1Dint16_reg>:
test   $0xffe3,%edi
mov    $0xffffffd8,%ecx
mov    $0xffffffec,%eax
cmove  %ecx,%eax
ret

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

LLVM IR (-O2):
define i32 @test_imm_1Dint16_reg(i16 signext %0) {
%2 = and i16 %0, -29
%3 = icmp eq i16 %2, 0
%4 = select i1 %3, i32 -40, i32 -20
ret i32 %4
}
/* Variables and functions */
unsigned int RAND_MAX;
double rand();
int cyrand(unsigned int min, unsigned int max) {
  if (min == max)
    return min;
  return (int)(1.0 * (max + 1.0) * rand() / (RAND_MAX + min + 0.0));
}


x86 assembly (clang, -O0):
<cyrand>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0x8(%rbp),%eax
cmp    -0xc(%rbp),%eax
jne    1135 <cyrand+0x25>
mov    -0x8(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    1186 <cyrand+0x76>
mov    -0xc(%rbp),%eax
cvtsi2sd %rax,%xmm0
movsd  0xebb(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x18(%rbp)
xor    %eax,%eax
call   1030 <rand@plt>
movaps %xmm0,%xmm1
movsd  -0x18(%rbp),%xmm0
mulsd  %xmm1,%xmm0
mov    0x2e80(%rip),%rax
mov    (%rax),%eax
mov    -0x8(%rbp),%ecx
add    %ecx,%eax
cvtsi2sd %rax,%xmm1
xorps  %xmm2,%xmm2
addsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
cvttsd2si %xmm0,%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<cyrand>:
push   %rbx
sub    $0x10,%rsp
mov    %edi,%ebx
cmp    %esi,%edi
je     1153 <cyrand+0x43>
mov    %esi,%eax
cvtsi2sd %rax,%xmm0
addsd  0xed6(%rip),%xmm0
movsd  %xmm0,0x8(%rsp)
xor    %eax,%eax
call   1030 <rand@plt>
mov    0x2eaa(%rip),%rax
add    (%rax),%ebx
cvtsi2sd %rbx,%xmm1
mulsd  0x8(%rsp),%xmm0
divsd  %xmm1,%xmm0
cvttsd2si %xmm0,%ebx
mov    %ebx,%eax
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@RAND_MAX = global i32 0
define i32 @cyrand(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store i32 %0, i32* %4
store i32 %1, i32* %5
%6 = load i32, i32* %4
%7 = load i32, i32* %5
%8 = icmp eq i32 %6, %7
br i1 %8, label %9, label %11
9: ; preds = %2
%10 = load i32, i32* %4
store i32 %10, i32* %3
br label %25
11: ; preds = %2
%12 = load i32, i32* %5
%13 = uitofp i32 %12 to double
%14 = fadd double %13, 1.000000e+00
%15 = fmul double 1.000000e+00, %14
%16 = call double (...) @rand()
%17 = fmul double %15, %16
%18 = load i32, i32* @RAND_MAX
%19 = load i32, i32* %4
%20 = add i32 %18, %19
%21 = uitofp i32 %20 to double
%22 = fadd double %21, 0.000000e+00
%23 = fdiv double %17, %22
%24 = fptosi double %23 to i32
store i32 %24, i32* %3
br label %25
25: ; preds = %11, %9
%26 = load i32, i32* %3
ret i32 %26
}

LLVM IR (-O2):
@RAND_MAX = global i32 0
define i32 @cyrand(i32 %0, i32 %1) {
%3 = icmp eq i32 %0, %1
br i1 %3, label %14, label %4
4: ; preds = %2
%5 = uitofp i32 %1 to double
%6 = fadd double %5, 1.000000e+00
%7 = tail call double (...) @rand()
%8 = fmul double %6, %7
%9 = load i32, i32* @RAND_MAX
%10 = add i32 %9, %0
%11 = uitofp i32 %10 to double
%12 = fdiv double %8, %11
%13 = fptosi double %12 to i32
br label %14
14: ; preds = %2, %4
%15 = phi i32 [ %13, %4 ], [ %0, %2 ]
ret i32 %15
}
/* Variables and functions */
int convert(unsigned char);
int convertTwoByte(unsigned char hexNumber[2]) {
  unsigned int temp = 0;
  int a = convert(hexNumber[1]);
  int b = convert(hexNumber[0]);
  temp = b * 256 + a;
  return temp;
}


x86 assembly (clang, -O0):
<convertTwoByte>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
mov    -0x8(%rbp),%rax
movzbl 0x1(%rax),%edi
call   1030 <convert@plt>
mov    %eax,-0x10(%rbp)
mov    -0x8(%rbp),%rax
movzbl (%rax),%edi
call   1030 <convert@plt>
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%eax
shl    $0x8,%eax
add    -0x10(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<convertTwoByte>:
push   %rbp
push   %rbx
push   %rax
mov    %rdi,%rbx
movzbl 0x1(%rdi),%edi
call   1030 <convert@plt>
mov    %eax,%ebp
movzbl (%rbx),%edi
call   1030 <convert@plt>
shl    $0x8,%eax
add    %ebp,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
define i32 @convertTwoByte(i8* %0) {
%2 = alloca i8*
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store i8* %0, i8** %2
store i32 0, i32* %3
%6 = load i8*, i8** %2
%7 = getelementptr inbounds i8, i8* %6, i64 1
%8 = load i8, i8* %7
%9 = call i32 @convert(i8 zeroext %8)
store i32 %9, i32* %4
%10 = load i8*, i8** %2
%11 = getelementptr inbounds i8, i8* %10, i64 0
%12 = load i8, i8* %11
%13 = call i32 @convert(i8 zeroext %12)
store i32 %13, i32* %5
%14 = load i32, i32* %5
%15 = mul nsw i32 %14, 256
%16 = load i32, i32* %4
%17 = add nsw i32 %15, %16
store i32 %17, i32* %3
%18 = load i32, i32* %3
ret i32 %18
}

LLVM IR (-O2):
define i32 @convertTwoByte(i8* nocapture %0) {
%2 = getelementptr inbounds i8, i8* %0, i64 1
%3 = load i8, i8* %2
%4 = tail call i32 @convert(i8 zeroext %3)
%5 = load i8, i8* %0
%6 = tail call i32 @convert(i8 zeroext %5)
%7 = shl nsw i32 %6, 8
%8 = add nsw i32 %7, %4
ret i32 %8
}
/* Variables and functions */
int /*<<< orphan*/ is_prime(int);
int /*<<< orphan*/ scanf(char *, int *);
int main() {
  int a;
  scanf("%d", &a);
  is_prime(a);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeca(%rip),%rdi
lea    -0x8(%rbp),%rsi
call   1040 <scanf@plt>
mov    -0x8(%rbp),%edi
call   1030 <is_prime@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xed8(%rip),%rdi
lea    0x4(%rsp),%rsi
call   1040 <scanf@plt>
mov    0x4(%rsp),%edi
call   1030 <is_prime@plt>
xor    %eax,%eax
pop    %rcx
ret

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

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
define i32 @main() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
%3 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %1)
%4 = load i32, i32* %1
%5 = call i32 @is_prime(i32 %4)
ret i32 0
}
double SFMMPCToMPH(double mpc) {
  return (mpc / (1609.34738 / 3600.0 * (double)(1000 * 1000) / 1000000.0));
}


x86 assembly (clang, -O0):
<SFMMPCToMPH>:
push   %rbp
mov    %rsp,%rbp
movsd  %xmm0,-0x8(%rbp)
movsd  -0x8(%rbp),%xmm0
movsd  0xeea(%rip),%xmm1
divsd  %xmm1,%xmm0
pop    %rbp
ret

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

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

LLVM IR (-O2):
define double @SFMMPCToMPH(double %0) {
%2 = fdiv double %0, 0x3FDC9C5199200EF2
ret double %2
}
/* Variables and functions */
int /*<<< orphan*/ fputs(char const *, int /*<<< orphan*/);
int /*<<< orphan*/ stderr;
void warn(char const *msg) { fputs(msg, stderr); }


x86 assembly (clang, -O0):
<warn>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
mov    0x2eb9(%rip),%rax
mov    (%rax),%esi
call   1030 <fputs@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<warn>:
mov    0x2ec9(%rip),%rax
mov    (%rax),%esi
jmp    1030 <fputs@plt>

LLVM IR (-O0):
@stderr = global i32 0
define void @warn(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = load i32, i32* @stderr
%5 = call i32 @fputs(i8* %3, i32 %4)
ret void
}

LLVM IR (-O2):
@stderr = global i32 0
define void @warn(i8* %0) {
%2 = load i32, i32* @stderr
%3 = tail call i32 @fputs(i8* %0, i32 %2)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ isprint(int);
void t_isprint_0xbf() {
  Assert_real((isprint(191) == 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_isprint.c",
              960, ("isprint should be 0 for 0xbf"));
}


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

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

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

LLVM IR (-O2):
@.str = [168 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_isprint.c\00"
@.str.1 = [29 x i8] c"isprint should be 0 for 0xbf\00"
define void @t_isprint_0xbf() {
%1 = tail call i64 @isprint(i32 191)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = tail call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 960, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
main(void) {
  printf("Raj"
         " and "
         "Kumar"
         ": we are present here!\n");
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeda(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
@.str = [37 x i8] c"Raj and Kumar: we are present here!\0A\00"
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = call i32 @printf(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@str = [36 x i8] c"Raj and Kumar: we are present here!\00"
define i32 @main() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([36 x i8], [36 x i8]* @str, i64 0, i64 0))
ret i32 0
}
/* Variables and functions */
char *decodeReg(char *);
char *str_replace(char *, char *, char *);
char *decodeAddr(char *token) {
  char *decoded = NULL;
  char *partial, *last;
  partial = str_replace(token, "[", "");
  last = str_replace(partial, "]", "");
  decoded = decodeReg(last);
  return decoded;
}


x86 assembly (clang, -O0):
<decodeAddr>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
movq   $0x0,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
lea    0xec1(%rip),%rsi
lea    0xebb(%rip),%rdx
call   1030 <str_replace@plt>
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rdi
lea    0xea8(%rip),%rsi
lea    0xea0(%rip),%rdx
call   1030 <str_replace@plt>
mov    %rax,-0x20(%rbp)
mov    -0x20(%rbp),%rdi
call   1040 <decodeReg@plt>
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<decodeAddr>:
push   %rbx
lea    0xed8(%rip),%rsi
lea    0xed2(%rip),%rbx
mov    %rbx,%rdx
call   1030 <str_replace@plt>
lea    0xec4(%rip),%rsi
mov    %rax,%rdi
mov    %rbx,%rdx
call   1030 <str_replace@plt>
mov    %rax,%rdi
pop    %rbx
jmp    1040 <decodeReg@plt>

LLVM IR (-O0):
@.str = [2 x i8] c"[\00"
@.str.1 = [1 x i8] zeroinitializer
@.str.2 = [2 x i8] c"]\00"
define i8* @decodeAddr(i8* %0) {
%2 = alloca i8*
%3 = alloca i8*
%4 = alloca i8*
%5 = alloca i8*
store i8* %0, i8** %2
store i8* null, i8** %3
%6 = load i8*, i8** %2
%7 = call i8* @str_replace(i8* %6, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.1, i64 0, i64 0))
store i8* %7, i8** %4
%8 = load i8*, i8** %4
%9 = call i8* @str_replace(i8* %8, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.1, i64 0, i64 0))
store i8* %9, i8** %5
%10 = load i8*, i8** %5
%11 = call i8* @decodeReg(i8* %10)
store i8* %11, i8** %3
%12 = load i8*, i8** %3
ret i8* %12
}

LLVM IR (-O2):
@.str = [2 x i8] c"[\00"
@.str.1 = [1 x i8] zeroinitializer
@.str.2 = [2 x i8] c"]\00"
define i8* @decodeAddr(i8* %0) {
%2 = tail call i8* @str_replace(i8* %0, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.1, i64 0, i64 0))
%3 = tail call i8* @str_replace(i8* %2, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.1, i64 0, i64 0))
%4 = tail call i8* @decodeReg(i8* %3)
ret i8* %4
}
/* Type definitions */
typedef int /*<<< orphan*/ uint32_t;

/* Variables and functions */
int /*<<< orphan*/ _sha256_be32enc(unsigned char *, int /*<<< orphan*/ const);
void be32enc_vect(unsigned char *dst, const uint32_t *src, size_t len) {
  size_t i;
  for (i = 0; i < len / 4; i++) {
    _sha256_be32enc(dst + i * 4, src[i]);
  }
}


x86 assembly (clang, -O0):
<be32enc_vect>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
movq   $0x0,-0x20(%rbp)
mov    -0x20(%rbp),%rax
mov    -0x18(%rbp),%rcx
shr    $0x2,%rcx
cmp    %rcx,%rax
jae    1171 <be32enc_vect+0x61>
mov    -0x8(%rbp),%rdi
mov    -0x20(%rbp),%rax
shl    $0x2,%rax
add    %rax,%rdi
mov    -0x10(%rbp),%rax
mov    -0x20(%rbp),%rcx
mov    (%rax,%rcx,4),%esi
call   1030 <_sha256_be32enc@plt>
mov    -0x20(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x20(%rbp)
jmp    112c <be32enc_vect+0x1c>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<be32enc_vect>:
push   %r15
push   %r14
push   %r12
push   %rbx
push   %rax
cmp    $0x4,%rdx
jb     1149 <be32enc_vect+0x39>
mov    %rdx,%r15
mov    %rsi,%r14
mov    %rdi,%r12
shr    $0x2,%r15
xor    %ebx,%ebx
nopl   (%rax)
mov    (%r14,%rbx,4),%esi
mov    %r12,%rdi
call   1030 <_sha256_be32enc@plt>
add    $0x1,%rbx
add    $0x4,%r12
cmp    %rbx,%r15
jne    1130 <be32enc_vect+0x20>
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
define void @be32enc_vect(i8* %0, i32* %1, i64 %2) {
%4 = alloca i8*
%5 = alloca i32*
%6 = alloca i64
%7 = alloca i64
store i8* %0, i8** %4
store i32* %1, i32** %5
store i64 %2, i64* %6
store i64 0, i64* %7
br label %8
8: ; preds = %23, %3
%9 = load i64, i64* %7
%10 = load i64, i64* %6
%11 = udiv i64 %10, 4
%12 = icmp ult i64 %9, %11
br i1 %12, label %13, label %26
13: ; preds = %8
%14 = load i8*, i8** %4
%15 = load i64, i64* %7
%16 = mul i64 %15, 4
%17 = getelementptr inbounds i8, i8* %14, i64 %16
%18 = load i32*, i32** %5
%19 = load i64, i64* %7
%20 = getelementptr inbounds i32, i32* %18, i64 %19
%21 = load i32, i32* %20
%22 = call i32 @_sha256_be32enc(i8* %17, i32 %21)
br label %23
23: ; preds = %13
%24 = load i64, i64* %7
%25 = add i64 %24, 1
store i64 %25, i64* %7
br label %8
26: ; preds = %8
ret void
}

LLVM IR (-O2):
define void @be32enc_vect(i8* %0, i32* nocapture %1, i64 %2) {
%4 = icmp ult i64 %2, 4
br i1 %4, label %16, label %5
5: ; preds = %3
%6 = lshr i64 %2, 2
br label %7
7: ; preds = %5, %7
%8 = phi i64 [ %14, %7 ], [ 0, %5 ]
%9 = shl i64 %8, 2
%10 = getelementptr inbounds i8, i8* %0, i64 %9
%11 = getelementptr inbounds i32, i32* %1, i64 %8
%12 = load i32, i32* %11
%13 = tail call i32 @_sha256_be32enc(i8* %10, i32 %12)
%14 = add nuw nsw i64 %8, 1
%15 = icmp eq i64 %14, %6
br i1 %15, label %16, label %7
16: ; preds = %7, %3
ret void
}
/* Variables and functions */
int /*<<< orphan*/ atoi(char *, int *);
int /*<<< orphan*/ getline(char *, int);
int getnumber() {
  int num;
  char s[1000];
  getline(s, 1000);
  atoi(s, &num);
  return num;
}


x86 assembly (clang, -O0):
<getnumber>:
push   %rbp
mov    %rsp,%rbp
sub    $0x3f0,%rsp
lea    -0x3f0(%rbp),%rdi
mov    $0x3e8,%esi
call   1040 <getline@plt>
lea    -0x3f0(%rbp),%rdi
lea    -0x4(%rbp),%rsi
call   1030 <atoi@plt>
mov    -0x4(%rbp),%eax
add    $0x3f0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<getnumber>:
push   %rbx
sub    $0x400,%rsp
lea    0x10(%rsp),%rbx
mov    %rbx,%rdi
mov    $0x3e8,%esi
call   1040 <getline@plt>
lea    0xc(%rsp),%rsi
mov    %rbx,%rdi
call   1030 <atoi@plt>
mov    0xc(%rsp),%eax
add    $0x400,%rsp
pop    %rbx
ret

LLVM IR (-O0):
define i32 @getnumber() {
%1 = alloca i32
%2 = alloca [1000 x i8]
%3 = getelementptr inbounds [1000 x i8], [1000 x i8]* %2, i64 0, i64 0
%4 = call i32 @getline(i8* %3, i32 1000)
%5 = getelementptr inbounds [1000 x i8], [1000 x i8]* %2, i64 0, i64 0
%6 = call i32 @atoi(i8* %5, i32* %1)
%7 = load i32, i32* %1
ret i32 %7
}

LLVM IR (-O2):
define i32 @getnumber() {
%1 = alloca i32
%2 = alloca [1000 x i8]
%3 = bitcast i32* %1 to i8*
%4 = getelementptr inbounds [1000 x i8], [1000 x i8]* %2, i64 0, i64 0
%5 = call i32 @getline(i8* %4, i32 1000)
%6 = call i32 @atoi(i8* %4, i32* %1)
%7 = load i32, i32* %1
ret i32 %7
}
int main() {
  long t1 = function("asdf");
  long t2 = function("asdf");
  return t1 == t2 && t1 == "asdf";
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeda(%rip),%rdi
mov    $0x0,%al
call   1030 <function@plt>
cltq
mov    %rax,-0x10(%rbp)
lea    0xec6(%rip),%rdi
mov    $0x0,%al
call   1030 <function@plt>
cltq
mov    %rax,-0x18(%rbp)
mov    -0x10(%rbp),%rcx
xor    %eax,%eax
cmp    -0x18(%rbp),%rcx
mov    %al,-0x19(%rbp)
jne    116e <main+0x5e>
mov    -0x10(%rbp),%rax
lea    0xe9b(%rip),%rcx
cmp    %rcx,%rax
sete   %al
mov    %al,-0x19(%rbp)
mov    -0x19(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r14
push   %rbx
push   %rax
lea    0xee5(%rip),%r14
mov    %r14,%rdi
xor    %eax,%eax
call   1030 <function@plt>
movslq %eax,%rbx
mov    %r14,%rdi
xor    %eax,%eax
call   1030 <function@plt>
cmp    %eax,%ebx
sete   %al
cmp    %r14,%rbx
sete   %cl
and    %al,%cl
movzbl %cl,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
@.str = [5 x i8] c"asdf\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i64
%3 = alloca i64
store i32 0, i32* %1
%4 = call i32 (i8*, ...) bitcast (i32 (...)* @function to i32 (i8*, ...)*)(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%5 = sext i32 %4 to i64
store i64 %5, i64* %2
%6 = call i32 (i8*, ...) bitcast (i32 (...)* @function to i32 (i8*, ...)*)(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%7 = sext i32 %6 to i64
store i64 %7, i64* %3
%8 = load i64, i64* %2
%9 = load i64, i64* %3
%10 = icmp eq i64 %8, %9
br i1 %10, label %11, label %15
11: ; preds = %0
%12 = load i64, i64* %2
%13 = inttoptr i64 %12 to i8*
%14 = icmp eq i8* %13, getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0)
br label %15
15: ; preds = %11, %0
%16 = phi i1 [ false, %0 ], [ %14, %11 ]
%17 = zext i1 %16 to i32
ret i32 %17
}

LLVM IR (-O2):
@.str = [5 x i8] c"asdf\00"
define i32 @main() {
%1 = tail call i32 (i8*, ...) bitcast (i32 (...)* @function to i32 (i8*, ...)*)(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%2 = sext i32 %1 to i64
%3 = tail call i32 (i8*, ...) bitcast (i32 (...)* @function to i32 (i8*, ...)*)(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%4 = icmp eq i32 %1, %3
%5 = inttoptr i64 %2 to i8*
%6 = icmp eq i8* %5, getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0)
%7 = select i1 %4, i1 %6, i1 false
%8 = zext i1 %7 to i32
ret i32 %8
}
unsigned int get_right(unsigned int index) { return index * 2 + 2; }


x86 assembly (clang, -O0):
<get_right>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%eax
shl    $0x1,%eax
add    $0x2,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<get_right>:
lea    (%rdi,%rdi,1),%eax
add    $0x2,%eax
ret

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

LLVM IR (-O2):
define i32 @get_right(i32 %0) {
%2 = shl i32 %0, 1
%3 = add i32 %2, 2
ret i32 %3
}
/* Variables and functions */
int /*<<< orphan*/ dcopy_(int *, double *, int *, double *, int *);
void dcopy(int n, double *x, int incx, double *y, int incy) {
  dcopy_(&n, x, &incx, y, &incy);
}


x86 assembly (clang, -O0):
<dcopy>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8d,-0x24(%rbp)
mov    -0x10(%rbp),%rsi
mov    -0x20(%rbp),%rcx
lea    -0x4(%rbp),%rdi
lea    -0x14(%rbp),%rdx
lea    -0x24(%rbp),%r8
call   1030 <dcopy_@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<dcopy>:
sub    $0x18,%rsp
mov    %edi,0x14(%rsp)
mov    %edx,0x10(%rsp)
mov    %r8d,0xc(%rsp)
lea    0x14(%rsp),%rdi
lea    0x10(%rsp),%rdx
lea    0xc(%rsp),%r8
call   1030 <dcopy_@plt>
add    $0x18,%rsp
ret

LLVM IR (-O0):
define void @dcopy(i32 %0, double* %1, i32 %2, double* %3, i32 %4) {
%6 = alloca i32
%7 = alloca double*
%8 = alloca i32
%9 = alloca double*
%10 = alloca i32
store i32 %0, i32* %6
store double* %1, double** %7
store i32 %2, i32* %8
store double* %3, double** %9
store i32 %4, i32* %10
%11 = load double*, double** %7
%12 = load double*, double** %9
%13 = call i32 @dcopy_(i32* %6, double* %11, i32* %8, double* %12, i32* %10)
ret void
}

LLVM IR (-O2):
define void @dcopy(i32 %0, double* %1, i32 %2, double* %3, i32 %4) {
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
store i32 %0, i32* %6
store i32 %2, i32* %7
store i32 %4, i32* %8
%9 = call i32 @dcopy_(i32* %6, double* %1, i32* %7, double* %3, i32* %8)
ret void
}
vdstcs(y_size) float *y_size;
{}


x86 assembly (clang, -O0):
<vdstcs>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x10(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

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

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

LLVM IR (-O2):
define i32 @vdstcs(float* nocapture readnone %0) {
ret i32 undef
}
void XtTranslateKey() {}


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

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

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

LLVM IR (-O2):
define void @XtTranslateKey() {
ret void
}
void insertcursor(void) {}


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

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

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

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

/* Variables and functions */
int /*<<< orphan*/ fprintf(int /*<<< orphan*/ *, char *);
void type_prefix_print(FILE *output, void *self) { fprintf(output, "prefix"); }


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

x86 assembly (clang, -O2):
<type_prefix_print>:
mov    %rdi,%rcx
lea    0xee6(%rip),%rdi
mov    $0x6,%esi
mov    $0x1,%edx
jmp    1030 <fwrite@plt>

LLVM IR (-O0):
@.str = [7 x i8] c"prefix\00"
define void @type_prefix_print(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 = call i32 @fprintf(i32* %5, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [7 x i8] c"prefix\00"
define void @type_prefix_print(i32* nocapture %0, i8* nocapture readnone %1) {
%3 = tail call i64 @fwrite(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i64 6, i64 1, i32* %0)
ret void
}
int fibonacci(int n) {
  if (n == 0) {
    return 0;
  } else if (n == 1) {
    return 1;
  } else {
    return (fibonacci(n - 2) + fibonacci(n - 1));
  }
}


x86 assembly (clang, -O0):
<fibonacci>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x8(%rbp)
cmpl   $0x0,-0x8(%rbp)
jne    1131 <fibonacci+0x21>
movl   $0x0,-0x4(%rbp)
jmp    116a <fibonacci+0x5a>
cmpl   $0x1,-0x8(%rbp)
jne    1147 <fibonacci+0x37>
movl   $0x1,-0x4(%rbp)
jmp    116a <fibonacci+0x5a>
mov    -0x8(%rbp),%edi
sub    $0x2,%edi
call   1030 <fibonacci@plt>
mov    %eax,-0xc(%rbp)
mov    -0x8(%rbp),%edi
sub    $0x1,%edi
call   1030 <fibonacci@plt>
mov    %eax,%ecx
mov    -0xc(%rbp),%eax
add    %ecx,%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<fibonacci>:
push   %rbp
push   %rbx
push   %rax
mov    %edi,%ebx
xor    %ebp,%ebp
cmp    $0x2,%ebx
jb     1132 <fibonacci+0x22>
nopl   0x0(%rax)
lea    -0x2(%rbx),%edi
call   1030 <fibonacci@plt>
add    %eax,%ebp
add    $0xffffffff,%ebx
cmp    $0x2,%ebx
jae    1120 <fibonacci+0x10>
add    %ebp,%ebx
mov    %ebx,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

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

LLVM IR (-O2):
define i32 @fibonacci(i32 %0) {
br label %2
2: ; preds = %6, %1
%3 = phi i32 [ 0, %1 ], [ %10, %6 ]
%4 = phi i32 [ %0, %1 ], [ %9, %6 ]
%5 = icmp ult i32 %4, 2
br i1 %5, label %11, label %6
6: ; preds = %2
%7 = add nsw i32 %4, -2
%8 = tail call i32 @fibonacci(i32 %7)
%9 = add nsw i32 %4, -1
%10 = add nsw i32 %8, %3
br label %2
11: ; preds = %2
%12 = add nsw i32 %4, %3
ret i32 %12
}
/* Variables and functions */
int _ada_use_c2phc(int, int *, int *, double *);
int mapcon_clear_maps(void) {
  int *a, *b, fail;
  double *c;
  fail = _ada_use_c2phc(432, a, b, c);
  return fail;
}


x86 assembly (clang, -O0):
<mapcon_clear_maps>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    -0x8(%rbp),%rsi
mov    -0x10(%rbp),%rdx
mov    -0x20(%rbp),%rcx
mov    $0x1b0,%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):
<mapcon_clear_maps>:
mov    $0x1b0,%edi
jmp    1030 <_ada_use_c2phc@plt>

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

LLVM IR (-O2):
define i32 @mapcon_clear_maps() {
%1 = tail call i32 @_ada_use_c2phc(i32 432, i32* undef, i32* undef, double* undef)
ret i32 %1
}
/* Variables and functions */
int strlen(char *);
int isheader(char *line) {
  return (line[0] == '[') && (line[strlen(line) - 1] == ']');
}


x86 assembly (clang, -O0):
<isheader>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
movsbl (%rax),%ecx
xor    %eax,%eax
cmp    $0x5b,%ecx
mov    %al,-0x9(%rbp)
jne    115b <isheader+0x4b>
mov    -0x8(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <strlen@plt>
mov    %eax,%ecx
mov    -0x18(%rbp),%rax
sub    $0x1,%ecx
movslq %ecx,%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x5d,%eax
sete   %al
mov    %al,-0x9(%rbp)
mov    -0x9(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<isheader>:
push   %rbx
xor    %eax,%eax
cmpb   $0x5b,(%rdi)
jne    112d <isheader+0x1d>
mov    %rdi,%rbx
call   1030 <strlen@plt>
movslq %eax,%rcx
xor    %eax,%eax
cmpb   $0x5d,-0x1(%rcx,%rbx,1)
sete   %al
pop    %rbx
ret

LLVM IR (-O0):
define i32 @isheader(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = getelementptr inbounds i8, i8* %3, i64 0
%5 = load i8, i8* %4
%6 = sext i8 %5 to i32
%7 = icmp eq i32 %6, 91
br i1 %7, label %8, label %18
8: ; preds = %1
%9 = load i8*, i8** %2
%10 = load i8*, i8** %2
%11 = call i32 @strlen(i8* %10)
%12 = sub nsw i32 %11, 1
%13 = sext i32 %12 to i64
%14 = getelementptr inbounds i8, i8* %9, i64 %13
%15 = load i8, i8* %14
%16 = sext i8 %15 to i32
%17 = icmp eq i32 %16, 93
br label %18
18: ; preds = %8, %1
%19 = phi i1 [ false, %1 ], [ %17, %8 ]
%20 = zext i1 %19 to i32
ret i32 %20
}

LLVM IR (-O2):
define i32 @isheader(i8* %0) {
%2 = load i8, i8* %0
%3 = icmp eq i8 %2, 91
br i1 %3, label %4, label %12
4: ; preds = %1
%5 = tail call i32 @strlen(i8* %0)
%6 = add nsw i32 %5, -1
%7 = sext i32 %6 to i64
%8 = getelementptr inbounds i8, i8* %0, i64 %7
%9 = load i8, i8* %8
%10 = icmp eq i8 %9, 93
%11 = zext i1 %10 to i32
br label %12
12: ; preds = %4, %1
%13 = phi i32 [ 0, %1 ], [ %11, %4 ]
ret i32 %13
}
int disable_interrupts(void) {
  int enabled = are_interrupts_enabled();
  asm("cli");
}


x86 assembly (clang, -O0):
<disable_interrupts>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x0,%al
call   1030 <are_interrupts_enabled@plt>
mov    %eax,-0x8(%rbp)
cli
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<disable_interrupts>:
push   %rax
xor    %eax,%eax
call   1030 <are_interrupts_enabled@plt>
cli
pop    %rcx
ret

LLVM IR (-O0):
define i32 @disable_interrupts() {
%1 = alloca i32
%2 = alloca i32
%3 = call i32 (...) @are_interrupts_enabled()
store i32 %3, i32* %2
%4 = load i32, i32* %1
ret i32 %4
}

LLVM IR (-O2):
define i32 @disable_interrupts() {
%1 = tail call i32 (...) @are_interrupts_enabled()
tail call void asm sideeffect "cli", "~{dirflag},~{fpsr},~{flags}"()
ret i32 undef
}
Pause() {}


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

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

LLVM IR (-O0):
define i32 @Pause() {
%1 = alloca i32
%2 = load i32, i32* %1
ret i32 %2
}

LLVM IR (-O2):
define i32 @Pause() {
ret i32 undef
}
int putchar_x(c)
int c;
{ return putchar(c); }


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

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

LLVM IR (-O0):
define i32 @putchar_x(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = call i32 (i32, ...) bitcast (i32 (...)* @putchar to i32 (i32, ...)*)(i32 %3)
ret i32 %4
}

LLVM IR (-O2):
define i32 @putchar_x(i32 %0) {
%2 = tail call i32 (i32, ...) bitcast (i32 (...)* @putchar to i32 (i32, ...)*)(i32 %0)
ret i32 %2
}
/* Variables and functions */
int /*<<< orphan*/ RLIM_INFINITY;
int /*<<< orphan*/ cdecl_func__RLIM_INFINITY(int /*<<< orphan*/);
void cdecl_expr__RLIM_INFINITY() { cdecl_func__RLIM_INFINITY(RLIM_INFINITY); }


x86 assembly (clang, -O0):
<cdecl_expr__RLIM_INFINITY>:
push   %rbp
mov    %rsp,%rbp
mov    0x2ec5(%rip),%rax
mov    (%rax),%edi
call   1030 <cdecl_func__RLIM_INFINITY@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<cdecl_expr__RLIM_INFINITY>:
mov    0x2ec9(%rip),%rax
mov    (%rax),%edi
jmp    1030 <cdecl_func__RLIM_INFINITY@plt>

LLVM IR (-O0):
@RLIM_INFINITY = global i32 0
define void @cdecl_expr__RLIM_INFINITY() {
%1 = load i32, i32* @RLIM_INFINITY
%2 = call i32 @cdecl_func__RLIM_INFINITY(i32 %1)
ret void
}

LLVM IR (-O2):
@RLIM_INFINITY = global i32 0
define void @cdecl_expr__RLIM_INFINITY() {
%1 = load i32, i32* @RLIM_INFINITY
%2 = tail call i32 @cdecl_func__RLIM_INFINITY(i32 %1)
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ PBE2PARAM;

/* Variables and functions */
scalar_t__ ASN1_item_new(int /*<<< orphan*/ *);
int /*<<< orphan*/ PBE2PARAM_it;
PBE2PARAM *PBE2PARAM_new(void) {
  return (PBE2PARAM *)ASN1_item_new(&PBE2PARAM_it);
}


x86 assembly (clang, -O0):
<PBE2PARAM_new>:
push   %rbp
mov    %rsp,%rbp
mov    0x2ec5(%rip),%rdi
call   1030 <ASN1_item_new@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<PBE2PARAM_new>:
mov    0x2ec9(%rip),%rdi
jmp    1030 <ASN1_item_new@plt>

LLVM IR (-O0):
@PBE2PARAM_it = global i32 0
define i32* @PBE2PARAM_new() {
%1 = call i64 @ASN1_item_new(i32* @PBE2PARAM_it)
%2 = inttoptr i64 %1 to i32*
ret i32* %2
}

LLVM IR (-O2):
@PBE2PARAM_it = global i32 0
define i32* @PBE2PARAM_new() {
%1 = tail call i64 @ASN1_item_new(i32* @PBE2PARAM_it)
%2 = inttoptr i64 %1 to i32*
ret i32* %2
}
void openhpsdr_input(void) {}


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

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

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

LLVM IR (-O2):
define void @openhpsdr_input() {
ret void
}
void first_MRIState(_loc, _Base_MRIState) int *_loc, *_Base_MRIState;
{ MRIState_FIRST_FNC_OBJ(_loc, _Base_MRIState); }


x86 assembly (clang, -O0):
<first_MRIState>:
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    $0x0,%al
call   1030 <MRIState_FIRST_FNC_OBJ@plt>
add    $0x10,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
define void @first_MRIState(i32* %0, i32* %1) {
%3 = alloca i32*
%4 = alloca i32*
store i32* %0, i32** %3
store i32* %1, i32** %4
%5 = load i32*, i32** %3
%6 = load i32*, i32** %4
%7 = call i32 (i32*, i32*, ...) bitcast (i32 (...)* @MRIState_FIRST_FNC_OBJ to i32 (i32*, i32*, ...)*)(i32* %5, i32* %6)
ret void
}

LLVM IR (-O2):
define void @first_MRIState(i32* %0, i32* %1) {
%3 = tail call i32 (i32*, i32*, ...) bitcast (i32 (...)* @MRIState_FIRST_FNC_OBJ to i32 (i32*, i32*, ...)*)(i32* %0, i32* %1)
ret void
}
void gtk_tree_path_get_type() {}


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

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

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

LLVM IR (-O2):
define void @gtk_tree_path_get_type() {
ret void
}
/* Variables and functions */
int add(int, int);
int main_entry(int a, int b) { return add(a, b); }


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

x86 assembly (clang, -O2):
<main_entry>:
jmp    1030 <add@plt>

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

LLVM IR (-O2):
define i32 @main_entry(i32 %0, i32 %1) {
%3 = tail call i32 @add(i32 %0, i32 %1)
ret i32 %3
}
/* Variables and functions */
int /*<<< orphan*/ I2C_Put(int, int, unsigned char);
void mpu_threshold_set(unsigned char val) {
  ;
  if (val != 0xFF) {
    if (val > (99)) {
      val = (99);
    }
    if (val < (1)) {
      val = (1);
    }
  }
  I2C_Put(0xA6, 0x24, val);
}


x86 assembly (clang, -O0):
<mpu_threshold_set>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %dil,%al
mov    %al,-0x1(%rbp)
movzbl -0x1(%rbp),%eax
cmp    $0xff,%eax
je     1154 <mpu_threshold_set+0x44>
movzbl -0x1(%rbp),%eax
cmp    $0x63,%eax
jle    113e <mpu_threshold_set+0x2e>
movb   $0x63,-0x1(%rbp)
movzbl -0x1(%rbp),%eax
cmp    $0x1,%eax
jge    114f <mpu_threshold_set+0x3f>
movb   $0x1,-0x1(%rbp)
jmp    1154 <mpu_threshold_set+0x44>
mov    $0xa6,%edi
mov    $0x24,%esi
movzbl -0x1(%rbp),%edx
call   1030 <I2C_Put@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<mpu_threshold_set>:
cmp    $0x63,%dil
mov    $0x63,%eax
cmovb  %edi,%eax
test   %eax,%eax
mov    $0x1,%ecx
cmovne %eax,%ecx
cmp    $0xff,%dil
mov    $0xff,%edx
cmovne %ecx,%edx
mov    $0xa6,%edi
mov    $0x24,%esi
jmp    1030 <I2C_Put@plt>

LLVM IR (-O0):
define void @mpu_threshold_set(i8 zeroext %0) {
%2 = alloca i8
store i8 %0, i8* %2
%3 = load i8, i8* %2
%4 = zext i8 %3 to i32
%5 = icmp ne i32 %4, 255
br i1 %5, label %6, label %17
6: ; preds = %1
%7 = load i8, i8* %2
%8 = zext i8 %7 to i32
%9 = icmp sgt i32 %8, 99
br i1 %9, label %10, label %11
10: ; preds = %6
store i8 99, i8* %2
br label %11
11: ; preds = %10, %6
%12 = load i8, i8* %2
%13 = zext i8 %12 to i32
%14 = icmp slt i32 %13, 1
br i1 %14, label %15, label %16
15: ; preds = %11
store i8 1, i8* %2
br label %16
16: ; preds = %15, %11
br label %17
17: ; preds = %16, %1
%18 = load i8, i8* %2
%19 = call i32 @I2C_Put(i32 166, i32 36, i8 zeroext %18)
ret void
}

LLVM IR (-O2):
define void @mpu_threshold_set(i8 zeroext %0) {
%2 = icmp eq i8 %0, -1
%3 = icmp ult i8 %0, 99
%4 = select i1 %3, i8 %0, i8 99
%5 = icmp eq i8 %4, 0
%6 = select i1 %5, i8 1, i8 %4
%7 = select i1 %2, i8 -1, i8 %6
%8 = tail call i32 @I2C_Put(i32 166, i32 36, i8 zeroext %7)
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ uint32_t;

/* Variables and functions */
int /*<<< orphan*/ IntEnable(int /*<<< orphan*/);
int /*<<< orphan*/ IntRegister(int /*<<< orphan*/, void (*)());
int /*<<< orphan*/ _SysExcIntNumberGet();
void SysExcIntRegister(void (*pfnHandler)(void)) {
  uint32_t ui32Int;
  ui32Int = _SysExcIntNumberGet();
  ;
  IntRegister(ui32Int, pfnHandler);
  IntEnable(ui32Int);
}


x86 assembly (clang, -O0):
<SysExcIntRegister>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    $0x0,%al
call   1040 <_SysExcIntNumberGet@plt>
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%edi
mov    -0x8(%rbp),%rsi
call   1050 <IntRegister@plt>
mov    -0xc(%rbp),%edi
call   1030 <IntEnable@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<SysExcIntRegister>:
push   %rbp
push   %rbx
push   %rax
mov    %rdi,%rbx
xor    %eax,%eax
call   1040 <_SysExcIntNumberGet@plt>
mov    %eax,%ebp
mov    %eax,%edi
mov    %rbx,%rsi
call   1050 <IntRegister@plt>
mov    %ebp,%edi
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1030 <IntEnable@plt>

LLVM IR (-O0):
define void @SysExcIntRegister(void ()* %0) {
%2 = alloca void ()*
%3 = alloca i32
store void ()* %0, void ()** %2
%4 = call i32 (...) @_SysExcIntNumberGet()
store i32 %4, i32* %3
%5 = load i32, i32* %3
%6 = load void ()*, void ()** %2
%7 = bitcast void ()* %6 to void (...)*
%8 = call i32 @IntRegister(i32 %5, void (...)* %7)
%9 = load i32, i32* %3
%10 = call i32 @IntEnable(i32 %9)
ret void
}

LLVM IR (-O2):
define void @SysExcIntRegister(void ()* %0) {
%2 = tail call i32 (...) @_SysExcIntNumberGet()
%3 = bitcast void ()* %0 to void (...)*
%4 = tail call i32 @IntRegister(i32 %2, void (...)* %3)
%5 = tail call i32 @IntEnable(i32 %2)
ret void
}
void initialize_array(double v[], int n) {
  int i;
  for (i = 0; i < n; i++) {
    v[i] = 0;
  }
}


x86 assembly (clang, -O0):
<initialize_array>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
movl   $0x0,-0x10(%rbp)
mov    -0x10(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    113c <initialize_array+0x3c>
mov    -0x8(%rbp),%rax
movslq -0x10(%rbp),%rcx
xorps  %xmm0,%xmm0
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
jmp    1112 <initialize_array+0x12>
pop    %rbp
ret

x86 assembly (clang, -O2):
<initialize_array>:
test   %esi,%esi
jle    1126 <initialize_array+0x16>
push   %rax
mov    %esi,%edx
shl    $0x3,%rdx
xor    %esi,%esi
call   1030 <memset@plt>
add    $0x8,%rsp
ret

LLVM IR (-O0):
define void @initialize_array(double* %0, i32 %1) {
%3 = alloca double*
%4 = alloca i32
%5 = alloca i32
store double* %0, double** %3
store i32 %1, i32* %4
store i32 0, i32* %5
br label %6
6: ; preds = %15, %2
%7 = load i32, i32* %5
%8 = load i32, i32* %4
%9 = icmp slt i32 %7, %8
br i1 %9, label %10, label %18
10: ; preds = %6
%11 = load double*, double** %3
%12 = load i32, i32* %5
%13 = sext i32 %12 to i64
%14 = getelementptr inbounds double, double* %11, i64 %13
store double 0.000000e+00, double* %14
br label %15
15: ; preds = %10
%16 = load i32, i32* %5
%17 = add nsw i32 %16, 1
store i32 %17, i32* %5
br label %6
18: ; preds = %6
ret void
}

LLVM IR (-O2):
define void @initialize_array(double* nocapture writeonly %0, i32 %1) {
%3 = icmp sgt i32 %1, 0
br i1 %3, label %4, label %8
4: ; preds = %2
%5 = bitcast double* %0 to i8*
%6 = zext i32 %1 to i64
%7 = shl nuw nsw i64 %6, 3
br label %8
8: ; preds = %4, %2
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int);
void print_i32(int i) { printf("%d\n", i); }


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

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

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

LLVM IR (-O2):
@.str = [4 x i8] c"%d\0A\00"
define void @print_i32(i32 %0) {
%2 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, char const *, char const *, int);
void putOffset(const char *base, const char *name, int offset) {
  printf("%%define %s.%s\t\t(%d)\n", base, name, offset);
}


x86 assembly (clang, -O0):
<putOffset>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    -0x8(%rbp),%rsi
mov    -0x10(%rbp),%rdx
mov    -0x14(%rbp),%ecx
lea    0xecb(%rip),%rdi
call   1030 <printf@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<putOffset>:
mov    %edx,%ecx
mov    %rsi,%rdx
mov    %rdi,%rsi
lea    0xee1(%rip),%rdi
jmp    1030 <printf@plt>

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

LLVM IR (-O2):
@.str = [22 x i8] c"%%define %s.%s\09\09(%d)\0A\00"
define void @putOffset(i8* %0, i8* %1, i32 %2) {
%4 = tail call i32 @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i8* %0, i8* %1, i32 %2)
ret void
}
int return_int_3() { return 1073741824; }


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

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

LLVM IR (-O0):
define i32 @return_int_3() {
ret i32 1073741824
}

LLVM IR (-O2):
define i32 @return_int_3() {
ret i32 1073741824
}
/* Variables and functions */
double M_PI;
double degToRad(double angle) { return (M_PI / 180.0) * angle; }


x86 assembly (clang, -O0):
<degToRad>:
push   %rbp
mov    %rsp,%rbp
movsd  %xmm0,-0x8(%rbp)
mov    0x2ed8(%rip),%rax
movsd  (%rax),%xmm0
movsd  0xee4(%rip),%xmm1
divsd  %xmm1,%xmm0
mulsd  -0x8(%rbp),%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<degToRad>:
mov    0x2ee1(%rip),%rax
movsd  (%rax),%xmm1
divsd  0xeed(%rip),%xmm1
mulsd  %xmm1,%xmm0
ret

LLVM IR (-O0):
@M_PI = global double 0.000000e+00
define double @degToRad(double %0) {
%2 = alloca double
store double %0, double* %2
%3 = load double, double* @M_PI
%4 = fdiv double %3, 1.800000e+02
%5 = load double, double* %2
%6 = fmul double %4, %5
ret double %6
}

LLVM IR (-O2):
@M_PI = global double 0.000000e+00
define double @degToRad(double %0) {
%2 = load double, double* @M_PI
%3 = fdiv double %2, 1.800000e+02
%4 = fmul double %3, %0
ret double %4
}
/* Variables and functions */
scalar_t__ floor(double);
double cub(double phase) {
  phase -= floor(phase + 0.5);
  return phase * (5.19615242270663188 - 20.7846096908265275 * phase * phase);
}


x86 assembly (clang, -O0):
<cub>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movsd  %xmm0,-0x8(%rbp)
movsd  0xeeb(%rip),%xmm0
addsd  -0x8(%rbp),%xmm0
call   1030 <floor@plt>
cvtsi2sd %rax,%xmm1
movsd  -0x8(%rbp),%xmm0
subsd  %xmm1,%xmm0
movsd  %xmm0,-0x8(%rbp)
movsd  -0x8(%rbp),%xmm0
movsd  0xeb9(%rip),%xmm1
mulsd  -0x8(%rbp),%xmm1
movsd  -0x8(%rbp),%xmm2
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm1
movsd  0xe84(%rip),%xmm2
addsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<cub>:
push   %rax
movapd %xmm0,%xmm1
movsd  %xmm0,(%rsp)
movsd  0xede(%rip),%xmm0
addsd  %xmm1,%xmm0
call   1030 <floor@plt>
xorps  %xmm0,%xmm0
cvtsi2sd %rax,%xmm0
movsd  (%rsp),%xmm1
subsd  %xmm0,%xmm1
movsd  0xec4(%rip),%xmm0
mulsd  %xmm1,%xmm0
mulsd  %xmm1,%xmm0
addsd  0xebc(%rip),%xmm0
mulsd  %xmm1,%xmm0
pop    %rax
ret

LLVM IR (-O0):
define double @cub(double %0) {
%2 = alloca double
store double %0, double* %2
%3 = load double, double* %2
%4 = fadd double %3, 5.000000e-01
%5 = call i64 @floor(double %4)
%6 = sitofp i64 %5 to double
%7 = load double, double* %2
%8 = fsub double %7, %6
store double %8, double* %2
%9 = load double, double* %2
%10 = load double, double* %2
%11 = fmul double 0x4034C8DC2E423980, %10
%12 = load double, double* %2
%13 = fneg double %11
%14 = call double @llvm.fmuladd.f64(double %13, double %12, double 0x4014C8DC2E423980)
%15 = fmul double %9, %14
ret double %15
}

LLVM IR (-O2):
define double @cub(double %0) {
%2 = fadd double %0, 5.000000e-01
%3 = tail call i64 @floor(double %2)
%4 = sitofp i64 %3 to double
%5 = fsub double %0, %4
%6 = fmul double %5, 0xC034C8DC2E423980
%7 = tail call double @llvm.fmuladd.f64(double %6, double %5, double 0x4014C8DC2E423980)
%8 = fmul double %5, %7
ret double %8
}