xunge/DecIR huggingface dataset:
/* Variables and functions */
int /*<<< orphan*/ dxl_write_word(unsigned char, int, unsigned short);
void setTorqueLimit(unsigned char id, unsigned short limit) {
  dxl_write_word(id, (34), limit);
}


x86 assembly (clang, -O0):
<setTorqueLimit>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %si,%ax
mov    %dil,%cl
mov    %cl,-0x1(%rbp)
mov    %ax,-0x4(%rbp)
mov    -0x1(%rbp),%al
mov    $0x22,%esi
movzbl %al,%edi
movzwl -0x4(%rbp),%edx
call   1030 <dxl_write_word@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<setTorqueLimit>:
mov    %esi,%edx
mov    $0x22,%esi
jmp    1030 <dxl_write_word@plt>

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

LLVM IR (-O2):
define void @setTorqueLimit(i8 zeroext %0, i16 zeroext %1) {
%3 = tail call i32 @dxl_write_word(i8 zeroext %0, i32 34, i16 zeroext %1)
ret void
}
int f2(int *p, short *q, int s, int r, int t) { return *p + *q + r; }


x86 assembly (clang, -O0):
<f2>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    %ecx,-0x18(%rbp)
mov    %r8d,-0x1c(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%eax
mov    -0x10(%rbp),%rcx
movswl (%rcx),%ecx
add    %ecx,%eax
add    -0x18(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<f2>:
movswl (%rsi),%eax
add    (%rdi),%ecx
add    %ecx,%eax
ret

LLVM IR (-O0):
define i32 @f2(i32* %0, i16* %1, i32 %2, i32 %3, i32 %4) {
%6 = alloca i32*
%7 = alloca i16*
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
store i32* %0, i32** %6
store i16* %1, i16** %7
store i32 %2, i32* %8
store i32 %3, i32* %9
store i32 %4, i32* %10
%11 = load i32*, i32** %6
%12 = load i32, i32* %11
%13 = load i16*, i16** %7
%14 = load i16, i16* %13
%15 = sext i16 %14 to i32
%16 = add nsw i32 %12, %15
%17 = load i32, i32* %9
%18 = add nsw i32 %16, %17
ret i32 %18
}

LLVM IR (-O2):
define i32 @f2(i32* nocapture %0, i16* nocapture %1, i32 %2, i32 %3, i32 %4) {
%6 = load i32, i32* %0
%7 = load i16, i16* %1
%8 = sext i16 %7 to i32
%9 = add i32 %6, %3
%10 = add i32 %9, %8
ret i32 %10
}
/* Type definitions */
typedef int GLint;
typedef int GLenum;

/* Variables and functions */
#define GL_FOG_COLOR 135
#define GL_FOG_DENSITY 134
#define GL_FOG_DISTANCE_MODE_NV 133
#define GL_FOG_END 132
#define GL_FOG_INDEX 131
#define GL_FOG_MODE 130
#define GL_FOG_OFFSET_VALUE_SGIX 129
#define GL_FOG_START 128
__attribute__((visibility("internal"))) __attribute__((pure)) GLint
__glFogfv_size(GLenum e) {
  switch (e) {
  case GL_FOG_INDEX:
  case GL_FOG_DENSITY:
  case GL_FOG_START:
  case GL_FOG_END:
  case GL_FOG_MODE:
  case GL_FOG_OFFSET_VALUE_SGIX:
  case GL_FOG_DISTANCE_MODE_NV:
    return 1;
  case GL_FOG_COLOR:
    return 4;
  default:
    return 0;
  }
}


x86 assembly (clang, -O0):
<__glFogfv_size>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x8(%rbp)
mov    -0x8(%rbp),%eax
mov    %eax,-0xc(%rbp)
add    $0xffffff80,%eax
sub    $0x7,%eax
jb     1131 <__glFogfv_size+0x31>
jmp    111e <__glFogfv_size+0x1e>
mov    -0xc(%rbp),%eax
sub    $0x87,%eax
je     113d <__glFogfv_size+0x3d>
jmp    1149 <__glFogfv_size+0x49>
movl   $0x1,-0x4(%rbp)
jmp    1150 <__glFogfv_size+0x50>
movl   $0x4,-0x4(%rbp)
jmp    1150 <__glFogfv_size+0x50>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<__glFogfv_size>:
add    $0xffffff80,%edi
xor    %eax,%eax
cmp    $0x7,%edi
ja     1117 <__glFogfv_size+0x17>
movslq %edi,%rax
lea    0xeec(%rip),%rcx
mov    (%rcx,%rax,4),%eax
ret

LLVM IR (-O0):
define hidden i32 @__glFogfv_size(i32 %0) {
%2 = alloca i32
%3 = alloca i32
store i32 %0, i32* %3
%4 = load i32, i32* %3
switch i32 %4, label %7 [
i32 131, label %5
i32 134, label %5
i32 128, label %5
i32 132, label %5
i32 130, label %5
i32 129, label %5
i32 133, label %5
i32 135, label %6
]
5: ; preds = %1, %1, %1, %1, %1, %1, %1
store i32 1, i32* %2
br label %8
6: ; preds = %1
store i32 4, i32* %2
br label %8
7: ; preds = %1
store i32 0, i32* %2
br label %8
8: ; preds = %7, %6, %5
%9 = load i32, i32* %2
ret i32 %9
}

LLVM IR (-O2):
@switch.table.__glFogfv_size = [8 x i32] [i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 4]
define hidden i32 @__glFogfv_size(i32 %0) {
%2 = add i32 %0, -128
%3 = icmp ult i32 %2, 8
br i1 %3, label %4, label %8
4: ; preds = %1
%5 = sext i32 %2 to i64
%6 = getelementptr inbounds [8 x i32], [8 x i32]* @switch.table.__glFogfv_size, i64 0, i64 %5
%7 = load i32, i32* %6
br label %8
8: ; preds = %1, %4
%9 = phi i32 [ %7, %4 ], [ 0, %1 ]
ret i32 %9
}
/* Variables and functions */
int /*<<< orphan*/ BUG();
void outb(unsigned char x, unsigned long port) { BUG(); }


x86 assembly (clang, -O0):
<outb>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %dil,%al
mov    %al,-0x1(%rbp)
mov    %rsi,-0x10(%rbp)
mov    $0x0,%al
call   1030 <BUG@plt>
add    $0x10,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
define void @outb(i8 zeroext %0, i64 %1) {
%3 = alloca i8
%4 = alloca i64
store i8 %0, i8* %3
store i64 %1, i64* %4
%5 = call i32 (...) @BUG()
ret void
}

LLVM IR (-O2):
define void @outb(i8 zeroext %0, i64 %1) {
%3 = tail call i32 (...) @BUG()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ isalpha(int);
void t_isalpha_0x11() {
  Assert_real((isalpha(17) == 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_isalpha.c",
              90, ("isalpha should be 0 for 0x11"));
}


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

x86 assembly (clang, -O2):
<t_isalpha_0x11>:
push   %rax
mov    $0x11,%edi
call   1030 <isalpha@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
lea    0xec5(%rip),%rsi
lea    0xf66(%rip),%rcx
mov    $0x5a,%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_isalpha.c\00"
@.str.1 = [29 x i8] c"isalpha should be 0 for 0x11\00"
define void @t_isalpha_0x11() {
%1 = call i64 @isalpha(i32 17)
%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 90, 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_isalpha.c\00"
@.str.1 = [29 x i8] c"isalpha should be 0 for 0x11\00"
define void @t_isalpha_0x11() {
%1 = tail call i64 @isalpha(i32 17)
%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 90, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0))
ret void
}
void I2CMasterTimeoutSet(unsigned long ulBase, unsigned long ulValue) {
  ;
  (*((volatile unsigned long *)(ulBase + 0x00000024))) = ulValue;
}


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

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

LLVM IR (-O0):
define void @I2CMasterTimeoutSet(i64 %0, i64 %1) {
%3 = alloca i64
%4 = alloca i64
store i64 %0, i64* %3
store i64 %1, i64* %4
%5 = load i64, i64* %4
%6 = load i64, i64* %3
%7 = add i64 %6, 36
%8 = inttoptr i64 %7 to i64*
store volatile i64 %5, i64* %8
ret void
}

LLVM IR (-O2):
define void @I2CMasterTimeoutSet(i64 %0, i64 %1) {
%3 = add i64 %0, 36
%4 = inttoptr i64 %3 to i64*
store volatile i64 %1, i64* %4
ret void
}
int benchmark_fini() { return (0); }


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

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

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

LLVM IR (-O2):
define i32 @benchmark_fini() {
ret i32 0
}
int IsRootDirectory(const char *file) {
  while (*file == '/')
    file++;
  return *file == '\0';
}


x86 assembly (clang, -O0):
<IsRootDirectory>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x2f,%eax
jne    1129 <IsRootDirectory+0x29>
mov    -0x8(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x8(%rbp)
jmp    1108 <IsRootDirectory+0x8>
mov    -0x8(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x0,%eax
sete   %al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<IsRootDirectory>:
movzbl (%rdi),%ecx
add    $0x1,%rdi
cmp    $0x2f,%cl
je     1100 <IsRootDirectory>
xor    %eax,%eax
test   %cl,%cl
sete   %al
ret

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

LLVM IR (-O2):
define i32 @IsRootDirectory(i8* nocapture %0) {
br label %2
2: ; preds = %2, %1
%3 = phi i8* [ %0, %1 ], [ %6, %2 ]
%4 = load i8, i8* %3
%5 = icmp eq i8 %4, 47
%6 = getelementptr inbounds i8, i8* %3, i64 1
br i1 %5, label %2, label %7
7: ; preds = %2
%8 = icmp eq i8 %4, 0
%9 = zext i1 %8 to i32
ret i32 %9
}
/* Variables and functions */
double pow(double, double);
double qNT(double NT) {
  double q4, A = 98.96, B = -0.2232, C = -0.006457;
  if (NT > 100) {
    return 1;
  } else {
    q4 = A * pow(NT, (B + (C * NT)));
    return q4;
  }
}


x86 assembly (clang, -O0):
<qNT>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
movsd  %xmm0,-0x10(%rbp)
movsd  0xef3(%rip),%xmm0
movsd  %xmm0,-0x20(%rbp)
movsd  0xede(%rip),%xmm0
movsd  %xmm0,-0x28(%rbp)
movsd  0xec9(%rip),%xmm0
movsd  %xmm0,-0x30(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  0xeaf(%rip),%xmm1
ucomisd %xmm1,%xmm0
jbe    116d <qNT+0x5d>
movsd  0xebd(%rip),%xmm0
movsd  %xmm0,-0x8(%rbp)
jmp    11b3 <qNT+0xa3>
movsd  -0x20(%rbp),%xmm0
movsd  %xmm0,-0x38(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  -0x28(%rbp),%xmm2
movsd  -0x30(%rbp),%xmm1
movsd  -0x10(%rbp),%xmm3
mulsd  %xmm3,%xmm1
addsd  %xmm2,%xmm1
call   1030 <pow@plt>
movaps %xmm0,%xmm1
movsd  -0x38(%rbp),%xmm0
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x18(%rbp)
movsd  -0x18(%rbp),%xmm0
movsd  %xmm0,-0x8(%rbp)
movsd  -0x8(%rbp),%xmm0
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<qNT>:
push   %rax
ucomisd 0xeef(%rip),%xmm0
jbe    1125 <qNT+0x15>
movsd  0xedd(%rip),%xmm0
pop    %rax
ret
movsd  0xee3(%rip),%xmm1
mulsd  %xmm0,%xmm1
addsd  0xedf(%rip),%xmm1
call   1030 <pow@plt>
mulsd  0xeda(%rip),%xmm0
pop    %rax
ret

LLVM IR (-O0):
define double @qNT(double %0) {
%2 = alloca double
%3 = alloca double
%4 = alloca double
%5 = alloca double
%6 = alloca double
%7 = alloca double
store double %0, double* %3
store double 0x4058BD70A3D70A3D, double* %5
store double -2.232000e-01, double* %6
store double -6.457000e-03, double* %7
%8 = load double, double* %3
%9 = fcmp ogt double %8, 1.000000e+02
br i1 %9, label %10, label %11
10: ; preds = %1
store double 1.000000e+00, double* %2
br label %21
11: ; preds = %1
%12 = load double, double* %5
%13 = load double, double* %3
%14 = load double, double* %6
%15 = load double, double* %7
%16 = load double, double* %3
%17 = call double @llvm.fmuladd.f64(double %15, double %16, double %14)
%18 = call double @pow(double %13, double %17)
%19 = fmul double %12, %18
store double %19, double* %4
%20 = load double, double* %4
store double %20, double* %2
br label %21
21: ; preds = %11, %10
%22 = load double, double* %2
ret double %22
}

LLVM IR (-O2):
define double @qNT(double %0) {
%2 = fcmp ogt double %0, 1.000000e+02
br i1 %2, label %7, label %3
3: ; preds = %1
%4 = tail call double @llvm.fmuladd.f64(double %0, double -6.457000e-03, double -2.232000e-01)
%5 = tail call double @pow(double %0, double %4)
%6 = fmul double %5, 0x4058BD70A3D70A3D
br label %7
7: ; preds = %1, %3
%8 = phi double [ %6, %3 ], [ 1.000000e+00, %1 ]
ret double %8
}
/* Variables and functions */
int /*<<< orphan*/ __builtin_outl(unsigned int, int);
void spd_set_drb(void) {
  unsigned end_of_memory;
  unsigned device;
  end_of_memory = 0;
  device = 0x50;
  while (device <= 0x53) {
    unsigned side1_bits, side2_bits;
    int byte, byte2;
    side1_bits = side2_bits = -1;
    byte = -1;
    if (1) {
      side1_bits -= 25;
    }
    if (1) {
      end_of_memory += side1_bits;
    }
    __builtin_outl(end_of_memory, 0x1234);
    if (1) {
      end_of_memory += side2_bits;
    }
  }
}


x86 assembly (clang, -O0):
<spd_set_drb>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x50,-0x8(%rbp)
cmpl   $0x53,-0x8(%rbp)
ja     1172 <spd_set_drb+0x62>
movl   $0xffffffff,-0x10(%rbp)
movl   $0xffffffff,-0xc(%rbp)
movl   $0xffffffff,-0x14(%rbp)
mov    -0xc(%rbp),%eax
sub    $0x19,%eax
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%eax
add    -0x4(%rbp),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%edi
mov    $0x1234,%esi
call   1030 <__builtin_outl@plt>
mov    -0x10(%rbp),%eax
add    -0x4(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    1126 <spd_set_drb+0x16>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<spd_set_drb>:
push   %rbx
mov    $0xffffffe6,%ebx
cs nopw 0x0(%rax,%rax,1)
mov    %ebx,%edi
mov    $0x1234,%esi
call   1030 <__builtin_outl@plt>
add    $0xffffffe5,%ebx
jmp    1120 <spd_set_drb+0x10>

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

LLVM IR (-O2):
define void @spd_set_drb() {
br label %1
1: ; preds = %1, %0
%2 = phi i32 [ 0, %0 ], [ %5, %1 ]
%3 = add i32 %2, -26
%4 = tail call i32 @__builtin_outl(i32 %3, i32 4660)
%5 = add i32 %2, -27
br label %1
}
void foo235() {}


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

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

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

LLVM IR (-O2):
define void @foo235() {
ret void
}
void pcp_print_queue_stats(struct activity *a, int curr) {}


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

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

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

LLVM IR (-O2):
%struct.activity = type opaque
define void @pcp_print_queue_stats(%struct.activity* nocapture %0, i32 %1) {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ EXIT_FAILURE;
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *);
int /*<<< orphan*/ stderr;
void usage(void) {
  fprintf(stderr, "USAGE: --scale [This controls the plot length.] --width "
                  "[The desired width of plot.] --atom [a tolerance.]\n\n");
  exit(EXIT_FAILURE);
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
mov    0x2eb5(%rip),%rax
mov    (%rax),%edi
lea    0xecc(%rip),%rsi
call   1030 <fprintf@plt>
mov    0x2e98(%rip),%rax
mov    (%rax),%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<usage>:
push   %rax
mov    0x2eb8(%rip),%rax
mov    (%rax),%edi
lea    0xecf(%rip),%rsi
call   1030 <fprintf@plt>
mov    0x2e9b(%rip),%rax
mov    (%rax),%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [109 x i8] c"USAGE: --scale [This controls the plot length.] --width [The desired width of plot.] --atom [a tolerance.]\0A\0A\00"
@EXIT_FAILURE = global i32 0
define void @usage() {
%1 = load i32, i32* @stderr
%2 = call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([109 x i8], [109 x i8]* @.str, i64 0, i64 0))
%3 = load i32, i32* @EXIT_FAILURE
%4 = call i32 @exit(i32 %3)
unreachable
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [109 x i8] c"USAGE: --scale [This controls the plot length.] --width [The desired width of plot.] --atom [a tolerance.]\0A\0A\00"
@EXIT_FAILURE = global i32 0
define void @usage() {
%1 = load i32, i32* @stderr
%2 = tail call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([109 x i8], [109 x i8]* @.str, i64 0, i64 0))
%3 = load i32, i32* @EXIT_FAILURE
%4 = tail call i32 @exit(i32 %3)
unreachable
}
/* Variables and functions */
double gettop();
int /*<<< orphan*/ push(double);
void duptop() {
  double top = gettop();
  push(top);
}


x86 assembly (clang, -O0):
<duptop>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x0,%al
call   1030 <gettop@plt>
movsd  %xmm0,-0x8(%rbp)
movsd  -0x8(%rbp),%xmm0
call   1040 <push@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<duptop>:
push   %rax
xor    %eax,%eax
call   1030 <gettop@plt>
pop    %rax
jmp    1040 <push@plt>

LLVM IR (-O0):
define void @duptop() {
%1 = alloca double
%2 = call double (...) @gettop()
store double %2, double* %1
%3 = load double, double* %1
%4 = call i32 @push(double %3)
ret void
}

LLVM IR (-O2):
define void @duptop() {
%1 = tail call double (...) @gettop()
%2 = tail call i32 @push(double %1)
ret void
}
void ff_hevc_put_hevc_uni_pel_pixels12_10_sse4() {}


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

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

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

LLVM IR (-O2):
define void @ff_hevc_put_hevc_uni_pel_pixels12_10_sse4() {
ret void
}
int jeOklepaj(char c) { return (c == '(' || c == ')'); }


x86 assembly (clang, -O0):
<jeOklepaj>:
push   %rbp
mov    %rsp,%rbp
mov    %dil,%al
mov    %al,-0x1(%rbp)
movsbl -0x1(%rbp),%ecx
mov    $0x1,%al
cmp    $0x28,%ecx
mov    %al,-0x2(%rbp)
je     1129 <jeOklepaj+0x29>
movsbl -0x1(%rbp),%eax
cmp    $0x29,%eax
sete   %al
mov    %al,-0x2(%rbp)
mov    -0x2(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<jeOklepaj>:
and    $0xfe,%dil
xor    %eax,%eax
cmp    $0x28,%dil
sete   %al
ret

LLVM IR (-O0):
define i32 @jeOklepaj(i8 signext %0) {
%2 = alloca i8
store i8 %0, i8* %2
%3 = load i8, i8* %2
%4 = sext i8 %3 to i32
%5 = icmp eq i32 %4, 40
br i1 %5, label %10, label %6
6: ; preds = %1
%7 = load i8, i8* %2
%8 = sext i8 %7 to i32
%9 = icmp eq i32 %8, 41
br label %10
10: ; preds = %6, %1
%11 = phi i1 [ true, %1 ], [ %9, %6 ]
%12 = zext i1 %11 to i32
ret i32 %12
}

LLVM IR (-O2):
define i32 @jeOklepaj(i8 signext %0) {
%2 = and i8 %0, -2
%3 = icmp eq i8 %2, 40
%4 = zext i1 %3 to i32
ret i32 %4
}
int my_judge1(int x) { return x > 0; }


x86 assembly (clang, -O0):
<my_judge1>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
cmpl   $0x0,-0x4(%rbp)
setg   %al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<my_judge1>:
xor    %eax,%eax
test   %edi,%edi
setg   %al
ret

LLVM IR (-O0):
define i32 @my_judge1(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = icmp sgt i32 %3, 0
%5 = zext i1 %4 to i32
ret i32 %5
}

LLVM IR (-O2):
define i32 @my_judge1(i32 %0) {
%2 = icmp sgt i32 %0, 0
%3 = zext i1 %2 to i32
ret i32 %3
}
/* Variables and functions */
int /*<<< orphan*/ SIGTSTP;
int /*<<< orphan*/ newtResume();
int /*<<< orphan*/ newtSuspend();
int /*<<< orphan*/ raise(int /*<<< orphan*/);
void suspend(void *d) {
  newtSuspend();
  raise(SIGTSTP);
  newtResume();
}


x86 assembly (clang, -O0):
<suspend>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    $0x0,%al
call   1040 <newtSuspend@plt>
mov    0x2e9e(%rip),%rax
mov    (%rax),%edi
call   1030 <raise@plt>
mov    $0x0,%al
call   1050 <newtResume@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<suspend>:
push   %rax
xor    %eax,%eax
call   1040 <newtSuspend@plt>
mov    0x2ea9(%rip),%rax
mov    (%rax),%edi
call   1030 <raise@plt>
xor    %eax,%eax
pop    %rcx
jmp    1050 <newtResume@plt>

LLVM IR (-O0):
@SIGTSTP = global i32 0
define void @suspend(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = call i32 (...) @newtSuspend()
%4 = load i32, i32* @SIGTSTP
%5 = call i32 @raise(i32 %4)
%6 = call i32 (...) @newtResume()
ret void
}

LLVM IR (-O2):
@SIGTSTP = global i32 0
define void @suspend(i8* nocapture readnone %0) {
%2 = tail call i32 (...) @newtSuspend()
%3 = load i32, i32* @SIGTSTP
%4 = tail call i32 @raise(i32 %3)
%5 = tail call i32 (...) @newtResume()
ret void
}
void InitializeTimers() {}


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

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

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

LLVM IR (-O2):
define void @InitializeTimers() {
ret void
}
double vde_chain_nm4_sign(double x) { return x < 0 ? -1 : x > 0 ? 1 : x; }


x86 assembly (clang, -O0):
<vde_chain_nm4_sign>:
push   %rbp
mov    %rsp,%rbp
movsd  %xmm0,-0x8(%rbp)
xorps  %xmm0,%xmm0
ucomisd -0x8(%rbp),%xmm0
jbe    1129 <vde_chain_nm4_sign+0x29>
movsd  0xee9(%rip),%xmm0
movsd  %xmm0,-0x10(%rbp)
jmp    1161 <vde_chain_nm4_sign+0x61>
movsd  -0x8(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jbe    114d <vde_chain_nm4_sign+0x4d>
movsd  0xebd(%rip),%xmm0
movsd  %xmm0,-0x18(%rbp)
jmp    1157 <vde_chain_nm4_sign+0x57>
movsd  -0x8(%rbp),%xmm0
movsd  %xmm0,-0x18(%rbp)
movsd  -0x18(%rbp),%xmm0
movsd  %xmm0,-0x10(%rbp)
movsd  -0x10(%rbp),%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<vde_chain_nm4_sign>:
xorpd  %xmm1,%xmm1
xorpd  %xmm2,%xmm2
cmpltsd %xmm0,%xmm2
movsd  0xeeb(%rip),%xmm3
andpd  %xmm2,%xmm3
andnpd %xmm0,%xmm2
orpd   %xmm3,%xmm2
cmpltsd %xmm1,%xmm0
movapd %xmm0,%xmm1
andnpd %xmm2,%xmm1
movsd  0xed2(%rip),%xmm2
andpd  %xmm2,%xmm0
orpd   %xmm1,%xmm0
ret

LLVM IR (-O0):
define double @vde_chain_nm4_sign(double %0) {
%2 = alloca double
store double %0, double* %2
%3 = load double, double* %2
%4 = fcmp olt double %3, 0.000000e+00
br i1 %4, label %5, label %6
5: ; preds = %1
br label %14
6: ; preds = %1
%7 = load double, double* %2
%8 = fcmp ogt double %7, 0.000000e+00
br i1 %8, label %9, label %10
9: ; preds = %6
br label %12
10: ; preds = %6
%11 = load double, double* %2
br label %12
12: ; preds = %10, %9
%13 = phi double [ 1.000000e+00, %9 ], [ %11, %10 ]
br label %14
14: ; preds = %12, %5
%15 = phi double [ -1.000000e+00, %5 ], [ %13, %12 ]
ret double %15
}

LLVM IR (-O2):
define double @vde_chain_nm4_sign(double %0) {
%2 = fcmp olt double %0, 0.000000e+00
%3 = fcmp ogt double %0, 0.000000e+00
%4 = select i1 %3, double 1.000000e+00, double %0
%5 = select i1 %2, double -1.000000e+00, double %4
ret double %5
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int, int);
main(void) {
  int i;
  int n;
  n = 255;
  for (i = 0; i <= n; i++) {
    printf("\t%c - %d\n", i, i);
  }
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0xff,-0xc(%rbp)
movl   $0x0,-0x8(%rbp)
mov    -0x8(%rbp),%eax
cmp    -0xc(%rbp),%eax
jg     1159 <main+0x49>
mov    -0x8(%rbp),%esi
mov    -0x8(%rbp),%edx
lea    0xeba(%rip),%rdi
call   1030 <printf@plt>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    112d <main+0x1d>
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r14
push   %rbx
push   %rax
xor    %ebx,%ebx
lea    0xee3(%rip),%r14
nopl   (%rax)
mov    %r14,%rdi
mov    %ebx,%esi
mov    %ebx,%edx
call   1030 <printf@plt>
add    $0x1,%ebx
cmp    $0x100,%ebx
jne    1120 <main+0x10>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

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

LLVM IR (-O2):
@.str = [10 x i8] c"\09%c - %d\0A\00"
define i32 @main() {
br label %1
1: ; preds = %0, %1
%2 = phi i32 [ 0, %0 ], [ %4, %1 ]
%3 = tail call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), i32 %2, i32 %2)
%4 = add nuw nsw i32 %2, 1
%5 = icmp eq i32 %4, 256
br i1 %5, label %6, label %1
6: ; preds = %1
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int, int);
int /*<<< orphan*/ scanf(char *, int *, int *);
int main() {
  int a, b;
  scanf("%d %d", &a, &b);
  a = a + b;
  b = a - b;
  a = a - b;
  printf("%d %d\n", a, b);
  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
lea    -0xc(%rbp),%rdx
call   1040 <scanf@plt>
mov    -0x8(%rbp),%eax
add    -0xc(%rbp),%eax
mov    %eax,-0x8(%rbp)
mov    -0x8(%rbp),%eax
sub    -0xc(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0x8(%rbp),%eax
sub    -0xc(%rbp),%eax
mov    %eax,-0x8(%rbp)
mov    -0x8(%rbp),%esi
mov    -0xc(%rbp),%edx
lea    0xe9b(%rip),%rdi
call   1030 <printf@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
mov    %rsp,%rdx
call   1040 <scanf@plt>
mov    0x4(%rsp),%edx
mov    (%rsp),%esi
mov    %edx,(%rsp)
mov    %esi,0x4(%rsp)
lea    0xebc(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [6 x i8] c"%d %d\00"
@.str.1 = [7 x i8] c"%d %d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
store i32 0, i32* %1
%4 = call i32 @scanf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32* %2, i32* %3)
%5 = load i32, i32* %2
%6 = load i32, i32* %3
%7 = add nsw i32 %5, %6
store i32 %7, i32* %2
%8 = load i32, i32* %2
%9 = load i32, i32* %3
%10 = sub nsw i32 %8, %9
store i32 %10, i32* %3
%11 = load i32, i32* %2
%12 = load i32, i32* %3
%13 = sub nsw i32 %11, %12
store i32 %13, i32* %2
%14 = load i32, i32* %2
%15 = load i32, i32* %3
%16 = call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 %14, i32 %15)
ret i32 0
}

LLVM IR (-O2):
@.str = [6 x i8] c"%d %d\00"
@.str.1 = [7 x i8] c"%d %d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = bitcast i32* %1 to i8*
%4 = bitcast i32* %2 to i8*
%5 = call i32 @scanf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32* %1, i32* %2)
%6 = load i32, i32* %1
%7 = load i32, i32* %2
store i32 %6, i32* %2
store i32 %7, i32* %1
%8 = call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 %7, i32 %6)
ret i32 0
}
int pri_xdev(struct arg *arg) { return 1; }


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

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

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

LLVM IR (-O2):
%struct.arg = type opaque
define i32 @pri_xdev(%struct.arg* nocapture readnone %0) {
ret i32 1
}
/* Type definitions */
typedef int /*<<< orphan*/ uint8_t;
typedef int /*<<< orphan*/ uint32_t;

/* Variables and functions */
int /*<<< orphan*/ memcpy(int /*<<< orphan*/ *, int /*<<< orphan*/ *, int);
void store32_le(uint8_t dst[4], uint32_t w) { memcpy(dst, &w, sizeof w); }


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

x86 assembly (clang, -O2):
<store32_le>:
push   %rax
mov    %esi,0x4(%rsp)
lea    0x4(%rsp),%rsi
mov    $0x4,%edx
call   1030 <memcpy@plt>
pop    %rax
ret

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

LLVM IR (-O2):
define void @store32_le(i32* %0, i32 %1) {
%3 = alloca i32
store i32 %1, i32* %3
%4 = call i32 @memcpy(i32* %0, i32* %3, i32 4)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ fgets(char *, int, int /*<<< orphan*/);
int /*<<< orphan*/ printInitials(char *, int);
int /*<<< orphan*/ stdin;
int main(void) {
  char name[100];
  fgets(name, 100, stdin);
  printInitials(name, 100);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x70,%rsp
movl   $0x0,-0x4(%rbp)
lea    -0x70(%rbp),%rdi
mov    0x2eae(%rip),%rax
mov    (%rax),%edx
mov    $0x64,%esi
call   1030 <fgets@plt>
lea    -0x70(%rbp),%rdi
mov    $0x64,%esi
call   1040 <printInitials@plt>
xor    %eax,%eax
add    $0x70,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x70,%rsp
mov    0x2ebc(%rip),%rax
mov    (%rax),%edx
mov    %rsp,%rbx
mov    %rbx,%rdi
mov    $0x64,%esi
call   1030 <fgets@plt>
mov    %rbx,%rdi
mov    $0x64,%esi
call   1040 <printInitials@plt>
xor    %eax,%eax
add    $0x70,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@stdin = global i32 0
define i32 @main() {
%1 = alloca i32
%2 = alloca [100 x i8]
store i32 0, i32* %1
%3 = getelementptr inbounds [100 x i8], [100 x i8]* %2, i64 0, i64 0
%4 = load i32, i32* @stdin
%5 = call i32 @fgets(i8* %3, i32 100, i32 %4)
%6 = getelementptr inbounds [100 x i8], [100 x i8]* %2, i64 0, i64 0
%7 = call i32 @printInitials(i8* %6, i32 100)
ret i32 0
}

LLVM IR (-O2):
@stdin = global i32 0
define i32 @main() {
%1 = alloca [100 x i8]
%2 = getelementptr inbounds [100 x i8], [100 x i8]* %1, i64 0, i64 0
%3 = load i32, i32* @stdin
%4 = call i32 @fgets(i8* %2, i32 100, i32 %3)
%5 = call i32 @printInitials(i8* %2, i32 100)
ret i32 0
}
/* Type definitions */
typedef int /*<<< orphan*/ __u64;

/* Variables and functions */
__u64 bpf_ptr_to_u64(const void *ptr) { return (__u64)(unsigned long)ptr; }


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

x86 assembly (clang, -O2):
<bpf_ptr_to_u64>:
mov    %rdi,%rax
ret

LLVM IR (-O0):
define i32 @bpf_ptr_to_u64(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = ptrtoint i8* %3 to i64
%5 = trunc i64 %4 to i32
ret i32 %5
}

LLVM IR (-O2):
define i32 @bpf_ptr_to_u64(i8* %0) {
%2 = ptrtoint i8* %0 to i64
%3 = trunc i64 %2 to i32
ret i32 %3
}
/* Variables and functions */
unsigned int registerTimer(void *, unsigned int, char *);
unsigned int resolveBinding(void *, char *, void **);
unsigned int startTimer(void *handle, char *sid, unsigned int duration,
                        char *timer) {
  void *rulesBinding;
  unsigned int result = resolveBinding(handle, sid, &rulesBinding);
  if (result != 0) {
    return result;
  }
  return registerTimer(rulesBinding, duration, timer);
}


x86 assembly (clang, -O0):
<startTimer>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    %edx,-0x1c(%rbp)
mov    %rcx,-0x28(%rbp)
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
lea    -0x30(%rbp),%rdx
call   1040 <resolveBinding@plt>
mov    %eax,-0x34(%rbp)
cmpl   $0x0,-0x34(%rbp)
je     1160 <startTimer+0x40>
mov    -0x34(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    1173 <startTimer+0x53>
mov    -0x30(%rbp),%rdi
mov    -0x1c(%rbp),%esi
mov    -0x28(%rbp),%rdx
call   1030 <registerTimer@plt>
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<startTimer>:
push   %rbp
push   %rbx
push   %rax
mov    %rcx,%rbx
mov    %edx,%ebp
mov    %rsp,%rdx
call   1040 <resolveBinding@plt>
test   %eax,%eax
jne    1142 <startTimer+0x22>
mov    (%rsp),%rdi
mov    %ebp,%esi
mov    %rbx,%rdx
call   1030 <registerTimer@plt>
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
define i32 @startTimer(i8* %0, i8* %1, i32 %2, i8* %3) {
%5 = alloca i32
%6 = alloca i8*
%7 = alloca i8*
%8 = alloca i32
%9 = alloca i8*
%10 = alloca i8*
%11 = alloca i32
store i8* %0, i8** %6
store i8* %1, i8** %7
store i32 %2, i32* %8
store i8* %3, i8** %9
%12 = load i8*, i8** %6
%13 = load i8*, i8** %7
%14 = call i32 @resolveBinding(i8* %12, i8* %13, i8** %10)
store i32 %14, i32* %11
%15 = load i32, i32* %11
%16 = icmp ne i32 %15, 0
br i1 %16, label %17, label %19
17: ; preds = %4
%18 = load i32, i32* %11
store i32 %18, i32* %5
br label %24
19: ; preds = %4
%20 = load i8*, i8** %10
%21 = load i32, i32* %8
%22 = load i8*, i8** %9
%23 = call i32 @registerTimer(i8* %20, i32 %21, i8* %22)
store i32 %23, i32* %5
br label %24
24: ; preds = %19, %17
%25 = load i32, i32* %5
ret i32 %25
}

LLVM IR (-O2):
define i32 @startTimer(i8* %0, i8* %1, i32 %2, i8* %3) {
%5 = alloca i8*
%6 = bitcast i8** %5 to i8*
%7 = call i32 @resolveBinding(i8* %0, i8* %1, i8** %5)
%8 = icmp eq i32 %7, 0
br i1 %8, label %9, label %12
9: ; preds = %4
%10 = load i8*, i8** %5
%11 = call i32 @registerTimer(i8* %10, i32 %2, i8* %3)
br label %12
12: ; preds = %4, %9
%13 = phi i32 [ %11, %9 ], [ %7, %4 ]
ret i32 %13
}
/* Variables and functions */
int /*<<< orphan*/ ctrl_t_day_common();
int /*<<< orphan*/ goto_check();
void ctrl_t_day_tsinghua() {
  ctrl_t_day_common();
  goto_check();
}


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

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

LLVM IR (-O0):
define void @ctrl_t_day_tsinghua() {
%1 = call i32 (...) @ctrl_t_day_common()
%2 = call i32 (...) @goto_check()
ret void
}

LLVM IR (-O2):
define void @ctrl_t_day_tsinghua() {
%1 = tail call i32 (...) @ctrl_t_day_common()
%2 = tail call i32 (...) @goto_check()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ done_testing();
int /*<<< orphan*/ finish_group();
int /*<<< orphan*/ finish_sym();
int /*<<< orphan*/ init_group();
int /*<<< orphan*/ init_sym();
int /*<<< orphan*/ init_test();
int /*<<< orphan*/ test_coalesce();
int /*<<< orphan*/ test_place();
int /*<<< orphan*/ test_place_with();
int main(void) {
  init_test();
  init_sym();
  init_group();
  test_place();
  test_place_with();
  test_coalesce();
  finish_group();
  finish_sym();
  done_testing();
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   10b0 <init_test@plt>
mov    $0x0,%al
call   10a0 <init_sym@plt>
mov    $0x0,%al
call   1060 <init_group@plt>
mov    $0x0,%al
call   1050 <test_place@plt>
mov    $0x0,%al
call   1080 <test_place_with@plt>
mov    $0x0,%al
call   1040 <test_coalesce@plt>
mov    $0x0,%al
call   1030 <finish_group@plt>
mov    $0x0,%al
call   1090 <finish_sym@plt>
mov    $0x0,%al
call   1070 <done_testing@plt>
xor    %eax,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
xor    %eax,%eax
call   10b0 <init_test@plt>
xor    %eax,%eax
call   10a0 <init_sym@plt>
xor    %eax,%eax
call   1060 <init_group@plt>
xor    %eax,%eax
call   1050 <test_place@plt>
xor    %eax,%eax
call   1080 <test_place_with@plt>
xor    %eax,%eax
call   1040 <test_coalesce@plt>
xor    %eax,%eax
call   1030 <finish_group@plt>
xor    %eax,%eax
call   1090 <finish_sym@plt>
xor    %eax,%eax
call   1070 <done_testing@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @main() {
%1 = call i32 (...) @init_test()
%2 = call i32 (...) @init_sym()
%3 = call i32 (...) @init_group()
%4 = call i32 (...) @test_place()
%5 = call i32 (...) @test_place_with()
%6 = call i32 (...) @test_coalesce()
%7 = call i32 (...) @finish_group()
%8 = call i32 (...) @finish_sym()
%9 = call i32 (...) @done_testing()
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 (...) @init_test()
%2 = tail call i32 (...) @init_sym()
%3 = tail call i32 (...) @init_group()
%4 = tail call i32 (...) @test_place()
%5 = tail call i32 (...) @test_place_with()
%6 = tail call i32 (...) @test_coalesce()
%7 = tail call i32 (...) @finish_group()
%8 = tail call i32 (...) @finish_sym()
%9 = tail call i32 (...) @done_testing()
ret i32 0
}
int security_shm_shmat(struct shmid_kernel *shp, char *shmaddr, int shmflg) {
  return 0;
}


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

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

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

LLVM IR (-O2):
%struct.shmid_kernel = type opaque
define i32 @security_shm_shmat(%struct.shmid_kernel* nocapture readnone %0, i8* nocapture readnone %1, i32 %2) {
ret i32 0
}
char trie_get_child_char(int i) {
  int ascii = i + 97;
  char result = ascii;
  return result;
}


x86 assembly (clang, -O0):
<trie_get_child_char>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x61,%eax
mov    %eax,-0x8(%rbp)
mov    -0x8(%rbp),%eax
mov    %al,-0x9(%rbp)
movsbl -0x9(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<trie_get_child_char>:
lea    0x61(%rdi),%eax
ret

LLVM IR (-O0):
define signext i8 @trie_get_child_char(i32 %0) {
%2 = alloca i32
%3 = alloca i32
%4 = alloca i8
store i32 %0, i32* %2
%5 = load i32, i32* %2
%6 = add nsw i32 %5, 97
store i32 %6, i32* %3
%7 = load i32, i32* %3
%8 = trunc i32 %7 to i8
store i8 %8, i8* %4
%9 = load i8, i8* %4
ret i8 %9
}

LLVM IR (-O2):
define signext i8 @trie_get_child_char(i32 %0) {
%2 = trunc i32 %0 to i8
%3 = add i8 %2, 97
ret i8 %3
}
/* Variables and functions */
int /*<<< orphan*/ avl_tree_test();
int /*<<< orphan*/ linked_list_test();
int /*<<< orphan*/ salloc_test();
int main(void) {
  linked_list_test();
  salloc_test();
  avl_tree_test();
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0x0,%al
call   1050 <linked_list_test@plt>
mov    $0x0,%al
call   1030 <salloc_test@plt>
mov    $0x0,%al
call   1040 <avl_tree_test@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
xor    %eax,%eax
call   1050 <linked_list_test@plt>
xor    %eax,%eax
call   1030 <salloc_test@plt>
xor    %eax,%eax
call   1040 <avl_tree_test@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = call i32 (...) @linked_list_test()
%3 = call i32 (...) @salloc_test()
%4 = call i32 (...) @avl_tree_test()
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 (...) @linked_list_test()
%2 = tail call i32 (...) @salloc_test()
%3 = tail call i32 (...) @avl_tree_test()
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ err_exit(char *, int /*<<< orphan*/);
int strcmp(char const *, char const *);
int Strcmp(const char *s, const char *s2) {
  if (!s || !s2)
    err_exit("Strcmp(NULL)\n", 0);
  return strcmp(s, s2);
}


x86 assembly (clang, -O0):
<Strcmp>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpq   $0x0,-0x8(%rbp)
je     1146 <Strcmp+0x26>
cmpq   $0x0,-0x10(%rbp)
jne    1154 <Strcmp+0x34>
lea    0xeb3(%rip),%rdi
xor    %esi,%esi
call   1040 <err_exit@plt>
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1030 <strcmp@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<Strcmp>:
push   %r14
push   %rbx
push   %rax
mov    %rsi,%r14
mov    %rdi,%rbx
test   %rdi,%rdi
je     1134 <Strcmp+0x14>
test   %r14,%r14
jne    1142 <Strcmp+0x22>
lea    0xec5(%rip),%rdi
xor    %esi,%esi
call   1040 <err_exit@plt>
mov    %rbx,%rdi
mov    %r14,%rsi
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1030 <strcmp@plt>

LLVM IR (-O0):
@.str = [14 x i8] c"Strcmp(NULL)\0A\00"
define i32 @Strcmp(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 = icmp ne i8* %5, null
br i1 %6, label %7, label %10
7: ; preds = %2
%8 = load i8*, i8** %4
%9 = icmp ne i8* %8, null
br i1 %9, label %12, label %10
10: ; preds = %7, %2
%11 = call i32 @err_exit(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0), i32 0)
br label %12
12: ; preds = %10, %7
%13 = load i8*, i8** %3
%14 = load i8*, i8** %4
%15 = call i32 @strcmp(i8* %13, i8* %14)
ret i32 %15
}

LLVM IR (-O2):
@.str = [14 x i8] c"Strcmp(NULL)\0A\00"
define i32 @Strcmp(i8* %0, i8* %1) {
%3 = icmp ne i8* %0, null
%4 = icmp ne i8* %1, null
%5 = and i1 %3, %4
br i1 %5, label %8, label %6
6: ; preds = %2
%7 = tail call i32 @err_exit(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0), i32 0)
br label %8
8: ; preds = %2, %6
%9 = tail call i32 @strcmp(i8* dereferenceable(1) %0, i8* dereferenceable(1) %1)
ret i32 %9
}
void vendor_dev_string(unsigned long conf, char *vendorbuf, char *devbuf) {
  int vendor = (((conf) >> 24) & 0xff);
  int dev = (((conf) >> 12) & 0xfff);
  char *devstr;
  char *vendorstr;
  vendorbuf[0] = 0;
  devbuf[0] = 0;
}


x86 assembly (clang, -O0):
<vendor_dev_string>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x8(%rbp),%rax
shr    $0x18,%rax
and    $0xff,%rax
mov    %eax,-0x1c(%rbp)
mov    -0x8(%rbp),%rax
shr    $0xc,%rax
and    $0xfff,%rax
mov    %eax,-0x20(%rbp)
mov    -0x10(%rbp),%rax
movb   $0x0,(%rax)
mov    -0x18(%rbp),%rax
movb   $0x0,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<vendor_dev_string>:
movb   $0x0,(%rsi)
movb   $0x0,(%rdx)
ret

LLVM IR (-O0):
define void @vendor_dev_string(i64 %0, i8* %1, i8* %2) {
%4 = alloca i64
%5 = alloca i8*
%6 = alloca i8*
%7 = alloca i32
%8 = alloca i32
%9 = alloca i8*
%10 = alloca i8*
store i64 %0, i64* %4
store i8* %1, i8** %5
store i8* %2, i8** %6
%11 = load i64, i64* %4
%12 = lshr i64 %11, 24
%13 = and i64 %12, 255
%14 = trunc i64 %13 to i32
store i32 %14, i32* %7
%15 = load i64, i64* %4
%16 = lshr i64 %15, 12
%17 = and i64 %16, 4095
%18 = trunc i64 %17 to i32
store i32 %18, i32* %8
%19 = load i8*, i8** %5
%20 = getelementptr inbounds i8, i8* %19, i64 0
store i8 0, i8* %20
%21 = load i8*, i8** %6
%22 = getelementptr inbounds i8, i8* %21, i64 0
store i8 0, i8* %22
ret void
}

LLVM IR (-O2):
define void @vendor_dev_string(i64 %0, i8* nocapture writeonly %1, i8* nocapture writeonly %2) {
store i8 0, i8* %1
store i8 0, i8* %2
ret void
}
/* Variables and functions */
int errno;
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ perror(char const *);
int unlink(char const *);
void Unlink(const char *path) {
  int ret = unlink(path);
  if (ret == -1) {
    do {
      int e = errno;
      perror(path);
      exit(e);
    } while (0);
  }
}


x86 assembly (clang, -O0):
<Unlink>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <unlink@plt>
mov    %eax,-0xc(%rbp)
cmpl   $0xffffffff,-0xc(%rbp)
jne    1174 <Unlink+0x44>
jmp    1157 <Unlink+0x27>
mov    0x2e82(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
call   1040 <perror@plt>
mov    -0x10(%rbp),%edi
call   1050 <exit@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<Unlink>:
push   %rbp
push   %rbx
push   %rax
mov    %rdi,%rbx
call   1030 <unlink@plt>
cmp    $0xffffffff,%eax
je     1147 <Unlink+0x17>
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret
mov    0x2e92(%rip),%rax
mov    (%rax),%ebp
mov    %rbx,%rdi
call   1040 <perror@plt>
mov    %ebp,%edi
call   1050 <exit@plt>

LLVM IR (-O0):
@errno = global i32 0
define void @Unlink(i8* %0) {
%2 = alloca i8*
%3 = alloca i32
%4 = alloca i32
store i8* %0, i8** %2
%5 = load i8*, i8** %2
%6 = call i32 @unlink(i8* %5)
store i32 %6, i32* %3
%7 = load i32, i32* %3
%8 = icmp eq i32 %7, -1
br i1 %8, label %9, label %17
9: ; preds = %1
br label %10
10: ; preds = %9
%11 = load i32, i32* @errno
store i32 %11, i32* %4
%12 = load i8*, i8** %2
%13 = call i32 @perror(i8* %12)
%14 = load i32, i32* %4
%15 = call i32 @exit(i32 %14)
unreachable
16: ; No predecessors!
br label %17
17: ; preds = %16, %1
ret void
}

LLVM IR (-O2):
@errno = global i32 0
define void @Unlink(i8* nocapture %0) {
%2 = tail call i32 @unlink(i8* %0)
%3 = icmp eq i32 %2, -1
br i1 %3, label %4, label %8
4: ; preds = %1
%5 = load i32, i32* @errno
%6 = tail call i32 @perror(i8* %0)
%7 = tail call i32 @exit(i32 %5)
unreachable
8: ; preds = %1
ret void
}
/* Variables and functions */
int /*<<< orphan*/ fileno(int /*<<< orphan*/);
int isatty(int /*<<< orphan*/);
int /*<<< orphan*/ stdout;
int supports_color() { return isatty(fileno(stdout)); }


x86 assembly (clang, -O0):
<supports_color>:
push   %rbp
mov    %rsp,%rbp
mov    0x2eb5(%rip),%rax
mov    (%rax),%edi
call   1040 <fileno@plt>
mov    %eax,%edi
call   1030 <isatty@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<supports_color>:
push   %rax
mov    0x2eb8(%rip),%rax
mov    (%rax),%edi
call   1040 <fileno@plt>
mov    %eax,%edi
pop    %rax
jmp    1030 <isatty@plt>

LLVM IR (-O0):
@stdout = global i32 0
define i32 @supports_color() {
%1 = load i32, i32* @stdout
%2 = call i32 @fileno(i32 %1)
%3 = call i32 @isatty(i32 %2)
ret i32 %3
}

LLVM IR (-O2):
@stdout = global i32 0
define i32 @supports_color() {
%1 = load i32, i32* @stdout
%2 = tail call i32 @fileno(i32 %1)
%3 = tail call i32 @isatty(i32 %2)
ret i32 %3
}
const char *ccnxNotifyAPIAbout_Name(void) { return "ccnxNotifyAPI"; }


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

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

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

LLVM IR (-O2):
@.str = [14 x i8] c"ccnxNotifyAPI\00"
define i8* @ccnxNotifyAPIAbout_Name() {
ret i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0)
}