xunge/DecIR huggingface dataset:
int fibonacciRecursion(int number) {
  if (number == 1 || number == 2) {
    return 1;
  } else {
    return fibonacciRecursion(number - 1) + fibonacciRecursion(number - 2);
  }
}


x86 assembly (clang, -O0):
<fibonacciRecursion>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x8(%rbp)
cmpl   $0x1,-0x8(%rbp)
je     112f <fibonacciRecursion+0x1f>
cmpl   $0x2,-0x8(%rbp)
jne    113b <fibonacciRecursion+0x2b>
movl   $0x1,-0x4(%rbp)
jmp    115e <fibonacciRecursion+0x4e>
mov    -0x8(%rbp),%edi
sub    $0x1,%edi
call   1030 <fibonacciRecursion@plt>
mov    %eax,-0xc(%rbp)
mov    -0x8(%rbp),%edi
sub    $0x2,%edi
call   1030 <fibonacciRecursion@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):
<fibonacciRecursion>:
push   %rbp
push   %rbx
push   %rax
mov    %edi,%ebp
add    $0xffffffff,%ebp
mov    $0x1,%ebx
cmp    $0x2,%ebp
jb     1144 <fibonacciRecursion+0x34>
xor    %ebx,%ebx
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
mov    %ebp,%edi
call   1030 <fibonacciRecursion@plt>
add    %eax,%ebx
add    $0xfffffffe,%ebp
cmp    $0x1,%ebp
ja     1130 <fibonacciRecursion+0x20>
add    $0x1,%ebx
mov    %ebx,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

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

LLVM IR (-O2):
define i32 @fibonacciRecursion(i32 %0) {
%2 = add i32 %0, -1
%3 = icmp ult i32 %2, 2
br i1 %3, label %15, label %4
4: ; preds = %1, %4
%5 = phi i32 [ %11, %4 ], [ %2, %1 ]
%6 = phi i32 [ %9, %4 ], [ %0, %1 ]
%7 = phi i32 [ %10, %4 ], [ 0, %1 ]
%8 = tail call i32 @fibonacciRecursion(i32 %5)
%9 = add nsw i32 %6, -2
%10 = add nsw i32 %8, %7
%11 = add i32 %6, -3
%12 = icmp ult i32 %11, 2
br i1 %12, label %13, label %4
13: ; preds = %4
%14 = add i32 %10, 1
br label %15
15: ; preds = %13, %1
%16 = phi i32 [ 1, %1 ], [ %14, %13 ]
ret i32 %16
}
void foo120() {}


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

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

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

LLVM IR (-O2):
define void @foo120() {
ret void
}
float NormalizeAnglePositive(float angle) {
  while (angle < 0.0f)
    angle += 360.0f;
  while (angle >= 360.0f)
    angle -= 360.0f;
  return angle;
}


x86 assembly (clang, -O0):
<NormalizeAnglePositive>:
push   %rbp
mov    %rsp,%rbp
movss  %xmm0,-0x4(%rbp)
xorps  %xmm0,%xmm0
ucomiss -0x4(%rbp),%xmm0
jbe    112d <NormalizeAnglePositive+0x2d>
movss  0xee2(%rip),%xmm0
addss  -0x4(%rbp),%xmm0
movss  %xmm0,-0x4(%rbp)
jmp    1109 <NormalizeAnglePositive+0x9>
jmp    1132 <NormalizeAnglePositive+0x32>
movss  -0x4(%rbp),%xmm0
movss  0xec1(%rip),%xmm1
ucomiss %xmm1,%xmm0
jb     1163 <NormalizeAnglePositive+0x63>
movss  -0x4(%rbp),%xmm0
movss  0xeab(%rip),%xmm1
subss  %xmm1,%xmm0
movss  %xmm0,-0x4(%rbp)
jmp    1132 <NormalizeAnglePositive+0x32>
movss  -0x4(%rbp),%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<NormalizeAnglePositive>:
xorps  %xmm1,%xmm1
ucomiss %xmm0,%xmm1
jbe    1119 <NormalizeAnglePositive+0x19>
movss  0xef0(%rip),%xmm2
addss  %xmm2,%xmm0
ucomiss %xmm0,%xmm1
ja     1110 <NormalizeAnglePositive+0x10>
ucomiss 0xee0(%rip),%xmm0
jb     1149 <NormalizeAnglePositive+0x49>
movss  0xeda(%rip),%xmm1
movss  0xece(%rip),%xmm2
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
addss  %xmm1,%xmm0
ucomiss %xmm2,%xmm0
jae    1140 <NormalizeAnglePositive+0x40>
ret

LLVM IR (-O0):
define float @NormalizeAnglePositive(float %0) {
%2 = alloca float
store float %0, float* %2
br label %3
3: ; preds = %6, %1
%4 = load float, float* %2
%5 = fcmp olt float %4, 0.000000e+00
br i1 %5, label %6, label %9
6: ; preds = %3
%7 = load float, float* %2
%8 = fadd float %7, 3.600000e+02
store float %8, float* %2
br label %3
9: ; preds = %3
br label %10
10: ; preds = %13, %9
%11 = load float, float* %2
%12 = fcmp oge float %11, 3.600000e+02
br i1 %12, label %13, label %16
13: ; preds = %10
%14 = load float, float* %2
%15 = fsub float %14, 3.600000e+02
store float %15, float* %2
br label %10
16: ; preds = %10
%17 = load float, float* %2
ret float %17
}

LLVM IR (-O2):
define float @NormalizeAnglePositive(float %0) {
%2 = fcmp olt float %0, 0.000000e+00
br i1 %2, label %6, label %3
3: ; preds = %6, %1
%4 = phi float [ %0, %1 ], [ %8, %6 ]
%5 = fcmp ult float %4, 3.600000e+02
br i1 %5, label %14, label %10
6: ; preds = %1, %6
%7 = phi float [ %8, %6 ], [ %0, %1 ]
%8 = fadd float %7, 3.600000e+02
%9 = fcmp olt float %8, 0.000000e+00
br i1 %9, label %6, label %3
10: ; preds = %3, %10
%11 = phi float [ %12, %10 ], [ %4, %3 ]
%12 = fadd float %11, -3.600000e+02
%13 = fcmp ult float %12, 3.600000e+02
br i1 %13, label %14, label %10
14: ; preds = %10, %3
%15 = phi float [ %4, %3 ], [ %12, %10 ]
ret float %15
}
/* Variables and functions */
unsigned int S(unsigned int const *, int);
unsigned int Sum1(const unsigned int *x) {
  return S(x, 6) ^ S(x, 11) ^ S(x, 25);
}


x86 assembly (clang, -O0):
<Sum1>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
mov    $0x6,%esi
call   1030 <S@plt>
mov    %eax,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
mov    $0xb,%esi
call   1030 <S@plt>
mov    %eax,%ecx
mov    -0x10(%rbp),%eax
xor    %ecx,%eax
mov    %eax,-0xc(%rbp)
mov    -0x8(%rbp),%rdi
mov    $0x19,%esi
call   1030 <S@plt>
mov    %eax,%ecx
mov    -0xc(%rbp),%eax
xor    %ecx,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<Sum1>:
push   %rbp
push   %r14
push   %rbx
mov    %rdi,%rbx
mov    $0x6,%esi
call   1030 <S@plt>
mov    %eax,%r14d
mov    %rbx,%rdi
mov    $0xb,%esi
call   1030 <S@plt>
mov    %eax,%ebp
xor    %r14d,%ebp
mov    %rbx,%rdi
mov    $0x19,%esi
call   1030 <S@plt>
xor    %ebp,%eax
pop    %rbx
pop    %r14
pop    %rbp
ret

LLVM IR (-O0):
define i32 @Sum1(i32* %0) {
%2 = alloca i32*
store i32* %0, i32** %2
%3 = load i32*, i32** %2
%4 = call i32 @S(i32* %3, i32 6)
%5 = load i32*, i32** %2
%6 = call i32 @S(i32* %5, i32 11)
%7 = xor i32 %4, %6
%8 = load i32*, i32** %2
%9 = call i32 @S(i32* %8, i32 25)
%10 = xor i32 %7, %9
ret i32 %10
}

LLVM IR (-O2):
define i32 @Sum1(i32* %0) {
%2 = tail call i32 @S(i32* %0, i32 6)
%3 = tail call i32 @S(i32* %0, i32 11)
%4 = xor i32 %3, %2
%5 = tail call i32 @S(i32* %0, i32 25)
%6 = xor i32 %4, %5
ret i32 %6
}
/* Type definitions */
typedef enum xprt_stat { ____Placeholder_xprt_stat } xprt_stat;
typedef int /*<<< orphan*/ SVCXPRT;

/* Variables and functions */
int XPRT_IDLE;
enum xprt_stat rendezvous_stat(SVCXPRT *xprt) { return (XPRT_IDLE); }


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

x86 assembly (clang, -O2):
<rendezvous_stat>:
mov    0x2ee1(%rip),%rax
mov    (%rax),%eax
ret

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

LLVM IR (-O2):
@XPRT_IDLE = global i32 0
define i32 @rendezvous_stat(i32* nocapture readnone %0) {
%2 = load i32, i32* @XPRT_IDLE
ret i32 %2
}
int nulldev_close(void *dev) { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @nulldev_close(i8* nocapture readnone %0) {
ret i32 0
}
void av_lockmgr_register() {}


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

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

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

LLVM IR (-O2):
define void @av_lockmgr_register() {
ret void
}
void YUY2ToARGBRow_NEON() {}


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

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

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

LLVM IR (-O2):
define void @YUY2ToARGBRow_NEON() {
ret void
}
/* Variables and functions */
int force_exact(int);
int force_lb(int x) { return force_exact(x) + 1; }


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

x86 assembly (clang, -O2):
<force_lb>:
push   %rax
call   1030 <force_exact@plt>
add    $0x1,%eax
pop    %rcx
ret

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

LLVM IR (-O2):
define i32 @force_lb(i32 %0) {
%2 = tail call i32 @force_exact(i32 %0)
%3 = add nsw i32 %2, 1
ret i32 %3
}
int test6(int f) { return (f | 4) & 6; }


x86 assembly (clang, -O0):
<test6>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%eax
or     $0x4,%eax
and    $0x6,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<test6>:
and    $0x2,%edi
lea    0x4(%rdi),%eax
ret

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

LLVM IR (-O2):
define i32 @test6(i32 %0) {
%2 = and i32 %0, 2
%3 = or i32 %2, 4
ret i32 %3
}
/* Variables and functions */
int /*<<< orphan*/ gmx_h2order(int, char **);
int main(int argc, char *argv[]) {
  gmx_h2order(argc, argv);
  return 0;
}


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

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

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

LLVM IR (-O2):
define i32 @main(i32 %0, i8** %1) {
%3 = tail call i32 @gmx_h2order(i32 %0, i8** %1)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ LOG_ERR;
int /*<<< orphan*/ report(int /*<<< orphan*/, char *);
void log_watchtab_read(void) {
  report(LOG_ERR, "Error while reading from watchtab");
}


x86 assembly (clang, -O0):
<log_watchtab_read>:
push   %rbp
mov    %rsp,%rbp
mov    0x2ebd(%rip),%rax
mov    (%rax),%edi
lea    0xedc(%rip),%rsi
call   1030 <report@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<log_watchtab_read>:
mov    0x2ec1(%rip),%rax
mov    (%rax),%edi
lea    0xee0(%rip),%rsi
jmp    1030 <report@plt>

LLVM IR (-O0):
@LOG_ERR = global i32 0
@.str = [34 x i8] c"Error while reading from watchtab\00"
define void @log_watchtab_read() {
%1 = load i32, i32* @LOG_ERR
%2 = call i32 @report(i32 %1, i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@LOG_ERR = global i32 0
@.str = [34 x i8] c"Error while reading from watchtab\00"
define void @log_watchtab_read() {
%1 = load i32, i32* @LOG_ERR
%2 = tail call i32 @report(i32 %1, i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int, int);
int /*<<< orphan*/ swap(int *, int *);
int main(void) {
  int x = 100;
  int y = 200;
  printf("Befor swap: x=%d and y=%d\n", x, y);
  swap(&x, &y);
  printf("After swap: x=%d and y=%d\n", x, y);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x64,-0x8(%rbp)
movl   $0xc8,-0xc(%rbp)
mov    -0x8(%rbp),%esi
mov    -0xc(%rbp),%edx
lea    0xeb6(%rip),%rdi
call   1030 <printf@plt>
lea    -0x8(%rbp),%rdi
lea    -0xc(%rbp),%rsi
call   1040 <swap@plt>
mov    -0x8(%rbp),%esi
mov    -0xc(%rbp),%edx
lea    0xeb2(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
movl   $0x64,0x4(%rsp)
movl   $0xc8,(%rsp)
lea    0xec9(%rip),%rdi
mov    $0x64,%esi
mov    $0xc8,%edx
call   1030 <printf@plt>
lea    0x4(%rsp),%rdi
mov    %rsp,%rsi
call   1040 <swap@plt>
mov    0x4(%rsp),%esi
mov    (%rsp),%edx
lea    0xeba(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [27 x i8] c"Befor swap: x=%d and y=%d\0A\00"
@.str.1 = [27 x i8] c"After swap: x=%d and y=%d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
store i32 0, i32* %1
store i32 100, i32* %2
store i32 200, i32* %3
%4 = load i32, i32* %2
%5 = load i32, i32* %3
%6 = call i32 @printf(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str, i64 0, i64 0), i32 %4, i32 %5)
%7 = call i32 @swap(i32* %2, i32* %3)
%8 = load i32, i32* %2
%9 = load i32, i32* %3
%10 = call i32 @printf(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.1, i64 0, i64 0), i32 %8, i32 %9)
ret i32 0
}

LLVM IR (-O2):
@.str = [27 x i8] c"Befor swap: x=%d and y=%d\0A\00"
@.str.1 = [27 x i8] c"After swap: x=%d and y=%d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = bitcast i32* %1 to i8*
store i32 100, i32* %1
%4 = bitcast i32* %2 to i8*
store i32 200, i32* %2
%5 = tail call i32 @printf(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str, i64 0, i64 0), i32 100, i32 200)
%6 = call i32 @swap(i32* %1, i32* %2)
%7 = load i32, i32* %1
%8 = load i32, i32* %2
%9 = call i32 @printf(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.1, i64 0, i64 0), i32 %7, i32 %8)
ret i32 0
}
int test1() { return 42; }


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

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

LLVM IR (-O0):
define i32 @test1() {
ret i32 42
}

LLVM IR (-O2):
define i32 @test1() {
ret i32 42
}
unsigned int return_uint_1() { return 1073741824; }


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

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

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

LLVM IR (-O2):
define i32 @return_uint_1() {
ret i32 1073741824
}
/* Variables and functions */
int /*<<< orphan*/ rust_print(char *);
int main() {
  rust_print("hehe");
  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 <rust_print@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

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

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

LLVM IR (-O2):
@.str = [5 x i8] c"hehe\00"
define i32 @main() {
%1 = tail call i32 @rust_print(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ print_set(int, int *);
int /*<<< orphan*/ printf(char *, ...);
void print_dom_set(int size, int vertex_count, int *dom) {
  printf("\n%5d\n", size);
  print_set(vertex_count, dom);
  printf("\n");
}


x86 assembly (clang, -O0):
<print_dom_set>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %rdx,-0x10(%rbp)
mov    -0x4(%rbp),%esi
lea    0xec4(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x8(%rbp),%edi
mov    -0x10(%rbp),%rsi
call   1030 <print_set@plt>
lea    0xeae(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<print_dom_set>:
push   %rbp
push   %rbx
push   %rax
mov    %rdx,%rbx
mov    %esi,%ebp
mov    %edi,%esi
lea    0xebf(%rip),%rdi
xor    %eax,%eax
call   1050 <printf@plt>
mov    %ebp,%edi
mov    %rbx,%rsi
call   1030 <print_set@plt>
mov    $0xa,%edi
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1040 <putchar@plt>

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

LLVM IR (-O2):
@.str = [6 x i8] c"\0A%5d\0A\00"
define void @print_dom_set(i32 %0, i32 %1, i32* %2) {
%4 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 %0)
%5 = tail call i32 @print_set(i32 %1, i32* %2)
%6 = tail call i32 @putchar(i32 10)
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ int32_t;

/* Variables and functions */
void play_check(int32_t nocb) {}


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

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

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

LLVM IR (-O2):
define void @play_check(i32 %0) {
ret void
}
/* Type definitions */
typedef size_t uint32_t;

/* Variables and functions */
int /*<<< orphan*/ drawCharacterWithColor(char, size_t);
void drawStringWithColor(char *s, uint32_t color) {
  uint32_t i = 0;
  while (s[i] != '\0') {
    drawCharacterWithColor(s[i], color);
    ++i;
  }
}


x86 assembly (clang, -O0):
<drawStringWithColor>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
movq   $0x0,-0x18(%rbp)
mov    -0x8(%rbp),%rax
mov    -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x0,%eax
je     1165 <drawStringWithColor+0x55>
mov    -0x8(%rbp),%rax
mov    -0x18(%rbp),%rcx
mov    (%rax,%rcx,1),%al
mov    -0x10(%rbp),%rsi
movsbl %al,%edi
call   1030 <drawCharacterWithColor@plt>
mov    -0x18(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x18(%rbp)
jmp    1128 <drawStringWithColor+0x18>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<drawStringWithColor>:
push   %r14
push   %rbx
push   %rax
mov    (%rdi),%al
test   %al,%al
je     1146 <drawStringWithColor+0x36>
mov    %rsi,%r14
mov    %rdi,%rbx
add    $0x1,%rbx
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
movsbl %al,%edi
mov    %r14,%rsi
call   1030 <drawCharacterWithColor@plt>
movzbl (%rbx),%eax
add    $0x1,%rbx
test   %al,%al
jne    1130 <drawStringWithColor+0x20>
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

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

LLVM IR (-O2):
define void @drawStringWithColor(i8* nocapture %0, i64 %1) {
%3 = load i8, i8* %0
%4 = icmp eq i8 %3, 0
br i1 %4, label %13, label %5
5: ; preds = %2, %5
%6 = phi i8 [ %11, %5 ], [ %3, %2 ]
%7 = phi i64 [ %9, %5 ], [ 0, %2 ]
%8 = tail call i32 @drawCharacterWithColor(i8 signext %6, i64 %1)
%9 = add i64 %7, 1
%10 = getelementptr inbounds i8, i8* %0, i64 %9
%11 = load i8, i8* %10
%12 = icmp eq i8 %11, 0
br i1 %12, label %13, label %5
13: ; preds = %5, %2
ret void
}
int mv_nand_block_randomized(unsigned int block_index) {
  const unsigned int unrandomized_block_table[] = {0, 1, 2, 3, 4, 5, 6, 7, 8};
  int i;
  int randomized = (1);
  for (i = 0; i < (sizeof(unrandomized_block_table) /
                   sizeof(*unrandomized_block_table));
       i++) {
    if (block_index == unrandomized_block_table[i]) {
      randomized = (0);
      break;
    }
  }
  return randomized;
}


x86 assembly (clang, -O0):
<mv_nand_block_randomized>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
mov    %edi,-0x4(%rbp)
lea    -0x30(%rbp),%rdi
lea    0xeda(%rip),%rsi
mov    $0x24,%edx
call   1030 <memcpy@plt>
movl   $0x1,-0x38(%rbp)
movl   $0x0,-0x34(%rbp)
movslq -0x34(%rbp),%rax
cmp    $0x9,%rax
jae    117c <mv_nand_block_randomized+0x6c>
mov    -0x4(%rbp),%eax
movslq -0x34(%rbp),%rcx
cmp    -0x30(%rbp,%rcx,4),%eax
jne    1169 <mv_nand_block_randomized+0x59>
movl   $0x0,-0x38(%rbp)
jmp    117c <mv_nand_block_randomized+0x6c>
jmp    116e <mv_nand_block_randomized+0x5e>
mov    -0x34(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x34(%rbp)
jmp    113e <mv_nand_block_randomized+0x2e>
mov    -0x38(%rbp),%eax
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<mv_nand_block_randomized>:
xor    %eax,%eax
cmp    $0x9,%edi
setae  %al
ret

LLVM IR (-O0):
@__const.mv_nand_block_randomized.unrandomized_block_table = [9 x i32] [i32 0, i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, i32 7, i32 8]
define i32 @mv_nand_block_randomized(i32 %0) {
%2 = alloca i32
%3 = alloca [9 x i32]
%4 = alloca i32
%5 = alloca i32
store i32 %0, i32* %2
%6 = bitcast [9 x i32]* %3 to i8*
store i32 1, i32* %5
store i32 0, i32* %4
br label %7
7: ; preds = %20, %1
%8 = load i32, i32* %4
%9 = sext i32 %8 to i64
%10 = icmp ult i64 %9, 9
br i1 %10, label %11, label %23
11: ; preds = %7
%12 = load i32, i32* %2
%13 = load i32, i32* %4
%14 = sext i32 %13 to i64
%15 = getelementptr inbounds [9 x i32], [9 x i32]* %3, i64 0, i64 %14
%16 = load i32, i32* %15
%17 = icmp eq i32 %12, %16
br i1 %17, label %18, label %19
18: ; preds = %11
store i32 0, i32* %5
br label %23
19: ; preds = %11
br label %20
20: ; preds = %19
%21 = load i32, i32* %4
%22 = add nsw i32 %21, 1
store i32 %22, i32* %4
br label %7
23: ; preds = %18, %7
%24 = load i32, i32* %5
ret i32 %24
}

LLVM IR (-O2):
define i32 @mv_nand_block_randomized(i32 %0) {
%2 = icmp ugt i32 %0, 8
%3 = zext i1 %2 to i32
ret i32 %3
}
/* Variables and functions */
void *malloc(size_t);
int /*<<< orphan*/ memset(void *, int, size_t);
void *calloc(size_t num, size_t size) {
  void *ptr = malloc(num * size);
  if (ptr)
    memset(ptr, 0x00, num * size);
  return ptr;
}


x86 assembly (clang, -O0):
<calloc>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
imul   -0x10(%rbp),%rdi
call   1040 <malloc@plt>
mov    %rax,-0x18(%rbp)
cmpq   $0x0,-0x18(%rbp)
je     1161 <calloc+0x41>
mov    -0x18(%rbp),%rdi
mov    -0x8(%rbp),%rdx
imul   -0x10(%rbp),%rdx
xor    %esi,%esi
call   1030 <memset@plt>
mov    -0x18(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<calloc>:
push   %r14
push   %rbx
push   %rax
mov    %rdi,%rbx
imul   %rsi,%rbx
mov    %rbx,%rdi
call   1040 <malloc@plt>
mov    %rax,%r14
test   %rax,%rax
je     1148 <calloc+0x28>
mov    %r14,%rdi
xor    %esi,%esi
mov    %rbx,%rdx
call   1030 <memset@plt>
mov    %r14,%rax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

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

LLVM IR (-O2):
define i8* @calloc(i64 %0, i64 %1) {
%3 = mul i64 %1, %0
%4 = tail call i8* @malloc(i64 %3)
%5 = icmp eq i8* %4, null
br i1 %5, label %8, label %6
6: ; preds = %2
%7 = tail call i32 @memset(i8* %4, i32 0, i64 %3)
br label %8
8: ; preds = %6, %2
ret i8* %4
}
/* Type definitions */
typedef int /*<<< orphan*/ wint_t;
typedef int /*<<< orphan*/ locale_t;

/* Variables and functions */
int iswdigit(int /*<<< orphan*/);
int iswdigit_l(wint_t c, locale_t l) { return iswdigit(c); }


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

x86 assembly (clang, -O2):
<iswdigit_l>:
jmp    1030 <iswdigit@plt>

LLVM IR (-O0):
define i32 @iswdigit_l(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 @iswdigit(i32 %5)
ret i32 %6
}

LLVM IR (-O2):
define i32 @iswdigit_l(i32 %0, i32 %1) {
%3 = tail call i32 @iswdigit(i32 %0)
ret i32 %3
}
int rpathx_value() { return 5; }


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

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

LLVM IR (-O0):
define i32 @rpathx_value() {
ret i32 5
}

LLVM IR (-O2):
define i32 @rpathx_value() {
ret i32 5
}
/* Variables and functions */
char *malloc(int);
int /*<<< orphan*/ sprintf(char *, char *, int);
char *itoa(int value) {
  char *buff;
  buff = malloc(sizeof(char) * 16 + 1);
  sprintf(buff, "%d", value);
  return buff;
}


x86 assembly (clang, -O0):
<itoa>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    $0x11,%edi
call   1030 <malloc@plt>
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
mov    -0x4(%rbp),%edx
lea    0xeb9(%rip),%rsi
call   1040 <sprintf@plt>
mov    -0x10(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<itoa>:
push   %rbp
push   %rbx
push   %rax
mov    %edi,%ebp
mov    $0x11,%edi
call   1030 <malloc@plt>
mov    %rax,%rbx
lea    0xec7(%rip),%rsi
mov    %rax,%rdi
mov    %ebp,%edx
call   1040 <sprintf@plt>
mov    %rbx,%rax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%d\00"
define i8* @itoa(i32 %0) {
%2 = alloca i32
%3 = alloca i8*
store i32 %0, i32* %2
%4 = call i8* @malloc(i32 17)
store i8* %4, i8** %3
%5 = load i8*, i8** %3
%6 = load i32, i32* %2
%7 = call i32 @sprintf(i8* %5, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32 %6)
%8 = load i8*, i8** %3
ret i8* %8
}

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
define noalias i8* @itoa(i32 %0) {
%2 = tail call dereferenceable_or_null(17) i8* @malloc(i32 17)
%3 = tail call i32 @sprintf(i8* dereferenceable(1) %2, i8* dereferenceable(1) getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32 %0)
ret i8* %2
}
/* Variables and functions */
char *digit_to_word(int);
int /*<<< orphan*/ printf(char *, char *);
int /*<<< orphan*/ scanf(char *, int *);
int main() {
  int n = -1;
  scanf("%d", &n);
  printf("%s\n", digit_to_word(n));
  return 0;
}


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

x86 assembly (clang, -O2):
<main>:
push   %rax
movl   $0xffffffff,0x4(%rsp)
ff
lea    0xec0(%rip),%rdi
lea    0x4(%rsp),%rsi
call   1040 <scanf@plt>
mov    0x4(%rsp),%edi
call   1050 <digit_to_word@plt>
lea    0xea9(%rip),%rdi
mov    %rax,%rsi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%d\00"
@.str.1 = [4 x i8] c"%s\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
store i32 0, i32* %1
store i32 -1, i32* %2
%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 i8* @digit_to_word(i32 %4)
%6 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* %5)
ret i32 0
}

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
@.str.1 = [4 x i8] c"%s\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
store i32 -1, i32* %1
%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 i8* @digit_to_word(i32 %4)
%6 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* %5)
ret i32 0
}
/* Type definitions */
typedef int /*<<< orphan*/ uint16_t;

/* Variables and functions */
int /*<<< orphan*/ load_xmm(int, void *);
int /*<<< orphan*/ print_vec_uint16_hex(int /*<<< orphan*/ *);
int /*<<< orphan*/ printf(char *, int);
void print_xmm_uint16_hex(int i) {
  static uint16_t v[8];
  load_xmm(i, (void *)v);
  printf("xmm%d = ", i);
  print_vec_uint16_hex(v);
}


x86 assembly (clang, -O0):
<print_xmm_uint16_hex>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%edi
lea    0x2f0b(%rip),%rsi
call   1050 <load_xmm@plt>
mov    -0x4(%rbp),%esi
lea    0xeac(%rip),%rdi
call   1030 <printf@plt>
lea    0x2ef0(%rip),%rdi
call   1040 <print_vec_uint16_hex@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<print_xmm_uint16_hex>:
push   %r14
push   %rbx
push   %rax
mov    %edi,%ebx
lea    0x2f13(%rip),%r14
mov    %r14,%rsi
call   1050 <load_xmm@plt>
lea    0xeb4(%rip),%rdi
mov    %ebx,%esi
call   1030 <printf@plt>
mov    %r14,%rdi
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1040 <print_vec_uint16_hex@plt>

LLVM IR (-O0):
@print_xmm_uint16_hex.v = internal global [8 x i32] zeroinitializer
@.str = [9 x i8] c"xmm%d = \00"
define void @print_xmm_uint16_hex(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = call i32 @load_xmm(i32 %3, i8* bitcast ([8 x i32]* @print_xmm_uint16_hex.v to i8*))
%5 = load i32, i32* %2
%6 = call i32 @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i32 %5)
%7 = call i32 @print_vec_uint16_hex(i32* getelementptr inbounds ([8 x i32], [8 x i32]* @print_xmm_uint16_hex.v, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@print_xmm_uint16_hex.v = internal global [8 x i32] zeroinitializer
@.str = [9 x i8] c"xmm%d = \00"
define void @print_xmm_uint16_hex(i32 %0) {
%2 = tail call i32 @load_xmm(i32 %0, i8* bitcast ([8 x i32]* @print_xmm_uint16_hex.v to i8*))
%3 = tail call i32 @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i32 %0)
%4 = tail call i32 @print_vec_uint16_hex(i32* getelementptr inbounds ([8 x i32], [8 x i32]* @print_xmm_uint16_hex.v, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ xsi_register_didat(char *, char *);
extern void work_a_1956806361_3212880686_init() {
  xsi_register_didat(
      "work_a_1956806361_3212880686",
      "isim/tb_idea_isim_beh.exe.sim/work/a_1956806361_3212880686.didat");
}


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

x86 assembly (clang, -O2):
<work_a_1956806361_3212880686_init>:
lea    0xee9(%rip),%rdi
lea    0xeff(%rip),%rsi
jmp    1030 <xsi_register_didat@plt>

LLVM IR (-O0):
@.str = [29 x i8] c"work_a_1956806361_3212880686\00"
@.str.1 = [65 x i8] c"isim/tb_idea_isim_beh.exe.sim/work/a_1956806361_3212880686.didat\00"
define void @work_a_1956806361_3212880686_init() {
%1 = call i32 @xsi_register_didat(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([65 x i8], [65 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [29 x i8] c"work_a_1956806361_3212880686\00"
@.str.1 = [65 x i8] c"isim/tb_idea_isim_beh.exe.sim/work/a_1956806361_3212880686.didat\00"
define void @work_a_1956806361_3212880686_init() {
%1 = tail call i32 @xsi_register_didat(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([65 x i8], [65 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Type definitions */
typedef scalar_t__ uint;

/* Variables and functions */
uint bits(size_t n) {
  uint b = 0;
  while (n) {
    b++;
    n >>= 1;
  }
  return b;
}


x86 assembly (clang, -O0):
<bits>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
movq   $0x0,-0x10(%rbp)
cmpq   $0x0,-0x8(%rbp)
je     1138 <bits+0x38>
mov    -0x10(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x10(%rbp)
mov    -0x8(%rbp),%rax
shr    $0x1,%rax
mov    %rax,-0x8(%rbp)
jmp    1110 <bits+0x10>
mov    -0x10(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<bits>:
xor    %eax,%eax
test   %rdi,%rdi
je     1120 <bits+0x20>
mov    %rdi,%rcx
nopw   0x0(%rax,%rax,1)
add    $0x1,%rax
shr    %rcx
cmp    $0x1,%rdi
mov    %rcx,%rdi
ja     1110 <bits+0x10>
ret

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

LLVM IR (-O2):
define i64 @bits(i64 %0) {
%2 = icmp eq i64 %0, 0
br i1 %2, label %9, label %3
3: ; preds = %1, %3
%4 = phi i64 [ %6, %3 ], [ 0, %1 ]
%5 = phi i64 [ %7, %3 ], [ %0, %1 ]
%6 = add nuw nsw i64 %4, 1
%7 = lshr i64 %5, 1
%8 = icmp ult i64 %5, 2
br i1 %8, label %9, label %3
9: ; preds = %3, %1
%10 = phi i64 [ 0, %1 ], [ %6, %3 ]
ret i64 %10
}
/* Variables and functions */
char *readUTFlen(char **, char *, int *);
char *readUTF(char **pptr, char *enddata) {
  int len;
  return readUTFlen(pptr, enddata, &len);
}


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

x86 assembly (clang, -O2):
<readUTF>:
push   %rax
lea    0x4(%rsp),%rdx
call   1030 <readUTFlen@plt>
pop    %rcx
ret

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

LLVM IR (-O2):
define i8* @readUTF(i8** %0, i8* %1) {
%3 = alloca i32
%4 = bitcast i32* %3 to i8*
%5 = call i8* @readUTFlen(i8** %0, i8* %1, i32* %3)
ret i8* %5
}
/* Variables and functions */
int /*<<< orphan*/ SIGUSR1;
int /*<<< orphan*/ signal(int /*<<< orphan*/, void (*)());
int /*<<< orphan*/ sleep(int);
void HandleSigusr1() {
  signal(SIGUSR1, HandleSigusr1);
  sleep(1);
}


x86 assembly (clang, -O0):
<HandleSigusr1>:
push   %rbp
mov    %rsp,%rbp
mov    0x2eb5(%rip),%rax
mov    (%rax),%edi
mov    0x2ec4(%rip),%rsi
call   1030 <signal@plt>
mov    $0x1,%edi
call   1040 <sleep@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<HandleSigusr1>:
push   %rax
mov    0x2eb8(%rip),%rax
mov    (%rax),%edi
mov    0x2ec7(%rip),%rsi
call   1030 <signal@plt>
mov    $0x1,%edi
pop    %rax
jmp    1040 <sleep@plt>

LLVM IR (-O0):
@SIGUSR1 = global i32 0
define void @HandleSigusr1() {
%1 = load i32, i32* @SIGUSR1
%2 = call i32 @signal(i32 %1, void (...)* bitcast (void ()* @HandleSigusr1 to void (...)*))
%3 = call i32 @sleep(i32 1)
ret void
}

LLVM IR (-O2):
@SIGUSR1 = global i32 0
define void @HandleSigusr1() {
%1 = load i32, i32* @SIGUSR1
%2 = tail call i32 @signal(i32 %1, void (...)* bitcast (void ()* @HandleSigusr1 to void (...)*))
%3 = tail call i32 @sleep(i32 1)
ret void
}
int randomnextsock(int i) { return 1; }


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

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

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

LLVM IR (-O2):
define i32 @randomnextsock(i32 %0) {
ret i32 1
}
void diff_set(s, t) {
  register int i, v;
  itr(t, i, v, del_set(s, v));
}


x86 assembly (clang, -O0):
<diff_set>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x8(%rbp),%eax
mov    %eax,-0x1c(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x18(%rbp)
mov    -0x10(%rbp),%eax
mov    %eax,-0x14(%rbp)
mov    -0x4(%rbp),%edi
mov    -0x10(%rbp),%esi
mov    $0x0,%al
call   1030 <del_set@plt>
mov    -0x1c(%rbp),%edi
mov    -0x18(%rbp),%esi
mov    -0x14(%rbp),%edx
mov    %eax,%ecx
mov    $0x0,%al
call   1040 <itr@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<diff_set>:
push   %rbx
mov    %esi,%ebx
xor    %eax,%eax
call   1030 <del_set@plt>
mov    %ebx,%edi
mov    %eax,%ecx
xor    %eax,%eax
pop    %rbx
jmp    1040 <itr@plt>

LLVM IR (-O0):
define void @diff_set(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
store i32 %0, i32* %3
store i32 %1, i32* %4
%7 = load i32, i32* %4
%8 = load i32, i32* %5
%9 = load i32, i32* %6
%10 = load i32, i32* %3
%11 = load i32, i32* %6
%12 = call i32 (i32, i32, ...) bitcast (i32 (...)* @del_set to i32 (i32, i32, ...)*)(i32 %10, i32 %11)
%13 = call i32 (i32, i32, i32, i32, ...) bitcast (i32 (...)* @itr to i32 (i32, i32, i32, i32, ...)*)(i32 %7, i32 %8, i32 %9, i32 %12)
ret void
}

LLVM IR (-O2):
define void @diff_set(i32 %0, i32 %1) {
%3 = tail call i32 (i32, i32, ...) bitcast (i32 (...)* @del_set to i32 (i32, i32, ...)*)(i32 %0, i32 undef)
%4 = tail call i32 (i32, i32, i32, i32, ...) bitcast (i32 (...)* @itr to i32 (i32, i32, i32, i32, ...)*)(i32 %1, i32 undef, i32 undef, i32 %3)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ EIO;
int /*<<< orphan*/ errno;
__attribute__((weak)) int _open(const char *buf, int flags, int mode) {
  (void)buf;
  (void)flags;
  (void)mode;
  errno = EIO;
  return (-1);
}


x86 assembly (clang, -O0):
<_open>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %edx,-0x10(%rbp)
mov    0x2ecb(%rip),%rax
mov    (%rax),%ecx
mov    0x2eba(%rip),%rax
mov    %ecx,(%rax)
mov    $0xffffffff,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<_open>:
mov    0x2ed9(%rip),%rax
mov    (%rax),%eax
mov    0x2ec8(%rip),%rcx
mov    %eax,(%rcx)
mov    $0xffffffff,%eax
ret

LLVM IR (-O0):
@EIO = global i32 0
@errno = global i32 0
define weak i32 @_open(i8* %0, i32 %1, i32 %2) {
%4 = alloca i8*
%5 = alloca i32
%6 = alloca i32
store i8* %0, i8** %4
store i32 %1, i32* %5
store i32 %2, i32* %6
%7 = load i8*, i8** %4
%8 = load i32, i32* %5
%9 = load i32, i32* %6
%10 = load i32, i32* @EIO
store i32 %10, i32* @errno
ret i32 -1
}

LLVM IR (-O2):
@EIO = global i32 0
@errno = global i32 0
define weak i32 @_open(i8* %0, i32 %1, i32 %2) {
%4 = load i32, i32* @EIO
store i32 %4, i32* @errno
ret i32 -1
}
void gtk_image_set_from_icon_name() {}


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

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

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

LLVM IR (-O2):
define void @gtk_image_set_from_icon_name() {
ret void
}
/* Variables and functions */
bool whitespacep(char c) {
  return c == ' ' || c == '	' || c == 10 || c == 13;
}


x86 assembly (clang, -O0):
<whitespacep>:
push   %rbp
mov    %rsp,%rbp
mov    %dil,%al
mov    %al,-0x1(%rbp)
movsbl -0x1(%rbp),%ecx
mov    $0x1,%al
cmp    $0x20,%ecx
mov    %al,-0x2(%rbp)
je     114d <whitespacep+0x4d>
movsbl -0x1(%rbp),%ecx
mov    $0x1,%al
cmp    $0x9,%ecx
mov    %al,-0x2(%rbp)
je     114d <whitespacep+0x4d>
movsbl -0x1(%rbp),%ecx
mov    $0x1,%al
cmp    $0xa,%ecx
mov    %al,-0x2(%rbp)
je     114d <whitespacep+0x4d>
movsbl -0x1(%rbp),%eax
cmp    $0xd,%eax
sete   %al
mov    %al,-0x2(%rbp)
mov    -0x2(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<whitespacep>:
cmp    $0x20,%dil
ja     1120 <whitespacep+0x20>
mov    $0x1,%eax
movzbl %dil,%ecx
movabs $0x100000600,%rdx
bt     %rcx,%rdx
jae    1120 <whitespacep+0x20>
ret
xor    %eax,%eax
cmp    $0xd,%dil
sete   %al
ret

LLVM IR (-O0):
define i32 @whitespacep(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, 32
br i1 %5, label %18, label %6
6: ; preds = %1
%7 = load i8, i8* %2
%8 = sext i8 %7 to i32
%9 = icmp eq i32 %8, 9
br i1 %9, label %18, label %10
10: ; preds = %6
%11 = load i8, i8* %2
%12 = sext i8 %11 to i32
%13 = icmp eq i32 %12, 10
br i1 %13, label %18, label %14
14: ; preds = %10
%15 = load i8, i8* %2
%16 = sext i8 %15 to i32
%17 = icmp eq i32 %16, 13
br label %18
18: ; preds = %14, %10, %6, %1
%19 = phi i1 [ true, %10 ], [ true, %6 ], [ true, %1 ], [ %17, %14 ]
%20 = zext i1 %19 to i32
ret i32 %20
}

LLVM IR (-O2):
define i32 @whitespacep(i8 signext %0) {
switch i8 %0, label %2 [
i8 32, label %5
i8 10, label %5
i8 9, label %5
]
2: ; preds = %1
%3 = icmp eq i8 %0, 13
%4 = zext i1 %3 to i32
br label %5
5: ; preds = %1, %1, %1, %2
%6 = phi i32 [ 1, %1 ], [ %4, %2 ], [ 1, %1 ], [ 1, %1 ]
ret i32 %6
}
/* Variables and functions */
int /*<<< orphan*/ writeToFile(char *, char *);
void showLeft() {
  writeToFile("/sys/class/gpio/gpio61/value", "1");
  writeToFile("/sys/class/gpio/gpio44/value", "0");
}


x86 assembly (clang, -O0):
<showLeft>:
push   %rbp
mov    %rsp,%rbp
lea    0xee5(%rip),%rdi
lea    0xefb(%rip),%rsi
call   1030 <writeToFile@plt>
lea    0xef1(%rip),%rdi
lea    0xf07(%rip),%rsi
call   1030 <writeToFile@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<showLeft>:
push   %rax
lea    0xee8(%rip),%rdi
lea    0xefe(%rip),%rsi
call   1030 <writeToFile@plt>
lea    0xef4(%rip),%rdi
lea    0xf0a(%rip),%rsi
pop    %rax
jmp    1030 <writeToFile@plt>

LLVM IR (-O0):
@.str = [29 x i8] c"/sys/class/gpio/gpio61/value\00"
@.str.1 = [2 x i8] c"1\00"
@.str.2 = [29 x i8] c"/sys/class/gpio/gpio44/value\00"
@.str.3 = [2 x i8] c"0\00"
define void @showLeft() {
%1 = call i32 @writeToFile(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%2 = call i32 @writeToFile(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [29 x i8] c"/sys/class/gpio/gpio61/value\00"
@.str.1 = [2 x i8] c"1\00"
@.str.2 = [29 x i8] c"/sys/class/gpio/gpio44/value\00"
@.str.3 = [2 x i8] c"0\00"
define void @showLeft() {
%1 = tail call i32 @writeToFile(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%2 = tail call i32 @writeToFile(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ cbmarch_iec_setrelease(int, int, int);
void cbm_iec_setrelease(int HandleDevice, int Set, int Release) {
  ;
  cbmarch_iec_setrelease(HandleDevice, Set, Release);
  return;
}


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

x86 assembly (clang, -O2):
<cbm_iec_setrelease>:
jmp    1030 <cbmarch_iec_setrelease@plt>

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

LLVM IR (-O2):
define void @cbm_iec_setrelease(i32 %0, i32 %1, i32 %2) {
%4 = tail call i32 @cbmarch_iec_setrelease(i32 %0, i32 %1, i32 %2)
ret void
}
/* Type definitions */
struct pstruct {
  int dummy;
};
struct mngmsg {
  int dummy;
};
struct beststr {
  int dummy;
};
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
void showalign(FILE *fp, unsigned char *aa0, unsigned char *aa1, int maxn,
               struct beststr **bptr, int nbest, int qlib,
               const struct mngmsg *m_msg, struct pstruct *ppst, void *f_str,
               char *info_gstring2) {}


x86 assembly (clang, -O0):
<showalign>:
push   %rbp
mov    %rsp,%rbp
mov    0x30(%rbp),%rax
mov    0x28(%rbp),%rax
mov    0x20(%rbp),%rax
mov    0x18(%rbp),%rax
mov    0x10(%rbp),%eax
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %ecx,-0x1c(%rbp)
mov    %r8,-0x28(%rbp)
mov    %r9d,-0x2c(%rbp)
pop    %rbp
ret

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

LLVM IR (-O0):
%struct.beststr = type { i32 }
%struct.mngmsg = type { i32 }
%struct.pstruct = type { i32 }
define void @showalign(i32* %0, i8* %1, i8* %2, i32 %3, %struct.beststr** %4, i32 %5, i32 %6, %struct.mngmsg* %7, %struct.pstruct* %8, i8* %9, i8* %10) {
%12 = alloca i32*
%13 = alloca i8*
%14 = alloca i8*
%15 = alloca i32
%16 = alloca %struct.beststr**
%17 = alloca i32
%18 = alloca i32
%19 = alloca %struct.mngmsg*
%20 = alloca %struct.pstruct*
%21 = alloca i8*
%22 = alloca i8*
store i32* %0, i32** %12
store i8* %1, i8** %13
store i8* %2, i8** %14
store i32 %3, i32* %15
store %struct.beststr** %4, %struct.beststr*** %16
store i32 %5, i32* %17
store i32 %6, i32* %18
store %struct.mngmsg* %7, %struct.mngmsg** %19
store %struct.pstruct* %8, %struct.pstruct** %20
store i8* %9, i8** %21
store i8* %10, i8** %22
ret void
}

LLVM IR (-O2):
%struct.beststr = type { i32 }
%struct.mngmsg = type { i32 }
%struct.pstruct = type { i32 }
define void @showalign(i32* nocapture %0, i8* nocapture %1, i8* nocapture %2, i32 %3, %struct.beststr** nocapture %4, i32 %5, i32 %6, %struct.mngmsg* nocapture %7, %struct.pstruct* nocapture %8, i8* nocapture %9, i8* nocapture %10) {
ret void
}