xunge/DecIR huggingface dataset:
/* Variables and functions */
double exp(double);
double sqrt(double);
double ComputeGaussianLikelihood(double value, double mean, double var) {
  return (exp(-(((value - mean) * (value - mean))) / (2 * var)) / 2.506628 /
          sqrt(var));
}


x86 assembly (clang, -O0):
<ComputeGaussianLikelihood>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
movsd  %xmm2,-0x18(%rbp)
movsd  -0x8(%rbp),%xmm0
subsd  -0x10(%rbp),%xmm0
movsd  -0x8(%rbp),%xmm1
subsd  -0x10(%rbp),%xmm1
mulsd  %xmm1,%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  0xe9a(%rip),%xmm1
mulsd  -0x18(%rbp),%xmm1
divsd  %xmm1,%xmm0
call   1030 <exp@plt>
movsd  0xe7c(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x20(%rbp)
movsd  -0x18(%rbp),%xmm0
call   1040 <sqrt@plt>
movaps %xmm0,%xmm1
movsd  -0x20(%rbp),%xmm0
divsd  %xmm1,%xmm0
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ComputeGaussianLikelihood>:
push   %rax
movsd  %xmm2,(%rsp)
subsd  %xmm1,%xmm0
movapd 0xece(%rip),%xmm1
xorpd  %xmm0,%xmm1
mulsd  %xmm1,%xmm0
movapd %xmm2,%xmm1
addsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
call   1030 <exp@plt>
movsd  (%rsp),%xmm1
movapd %xmm0,%xmm2
divsd  0xeb4(%rip),%xmm2
xorpd  %xmm0,%xmm0
ucomisd %xmm0,%xmm1
jb     116f <ComputeGaussianLikelihood+0x4f>
xorps  %xmm0,%xmm0
sqrtsd %xmm1,%xmm0
jmp    1182 <ComputeGaussianLikelihood+0x62>
movapd %xmm1,%xmm0
movsd  %xmm2,(%rsp)
call   1040 <sqrt@plt>
movsd  (%rsp),%xmm2
divsd  %xmm0,%xmm2
movapd %xmm2,%xmm0
pop    %rax
ret

LLVM IR (-O0):
define double @ComputeGaussianLikelihood(double %0, double %1, double %2) {
%4 = alloca double
%5 = alloca double
%6 = alloca double
store double %0, double* %4
store double %1, double* %5
store double %2, double* %6
%7 = load double, double* %4
%8 = load double, double* %5
%9 = fsub double %7, %8
%10 = load double, double* %4
%11 = load double, double* %5
%12 = fsub double %10, %11
%13 = fmul double %9, %12
%14 = fneg double %13
%15 = load double, double* %6
%16 = fmul double 2.000000e+00, %15
%17 = fdiv double %14, %16
%18 = call double @exp(double %17)
%19 = fdiv double %18, 0x40040D92FB19E732
%20 = load double, double* %6
%21 = call double @sqrt(double %20)
%22 = fdiv double %19, %21
ret double %22
}

LLVM IR (-O2):
define double @ComputeGaussianLikelihood(double %0, double %1, double %2) {
%4 = fsub double %0, %1
%5 = fneg double %4
%6 = fmul double %4, %5
%7 = fmul double %2, 2.000000e+00
%8 = fdiv double %6, %7
%9 = tail call double @exp(double %8)
%10 = fdiv double %9, 0x40040D92FB19E732
%11 = tail call double @sqrt(double %2)
%12 = fdiv double %10, %11
ret double %12
}
int is_valid_card_suite(char c) {
  switch (c) {
  case 's':
  case 'd':
  case 'h':
  case 'c':
    return 1;
  default:
    return 0;
  }
}


x86 assembly (clang, -O0):
<is_valid_card_suite>:
push   %rbp
mov    %rsp,%rbp
mov    %dil,%al
mov    %al,-0x5(%rbp)
movsbl -0x5(%rbp),%eax
mov    %eax,-0xc(%rbp)
add    $0xffffff9d,%eax
sub    $0x2,%eax
jb     1144 <is_valid_card_suite+0x44>
jmp    1122 <is_valid_card_suite+0x22>
mov    -0xc(%rbp),%eax
sub    $0x68,%eax
je     1144 <is_valid_card_suite+0x44>
jmp    1133 <is_valid_card_suite+0x33>
mov    -0xc(%rbp),%eax
sub    $0x73,%eax
jne    1150 <is_valid_card_suite+0x50>
jmp    1144 <is_valid_card_suite+0x44>
movl   $0x1,-0x4(%rbp)
jmp    1157 <is_valid_card_suite+0x57>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_valid_card_suite>:
add    $0xffffff9d,%edi
cmp    $0x10,%edi
ja     1118 <is_valid_card_suite+0x18>
mov    $0x1,%eax
mov    $0x10023,%ecx
bt     %edi,%ecx
jae    1118 <is_valid_card_suite+0x18>
ret
xor    %eax,%eax
ret

LLVM IR (-O0):
define i32 @is_valid_card_suite(i8 signext %0) {
%2 = alloca i32
%3 = alloca i8
store i8 %0, i8* %3
%4 = load i8, i8* %3
%5 = sext i8 %4 to i32
switch i32 %5, label %7 [
i32 115, label %6
i32 100, label %6
i32 104, label %6
i32 99, label %6
]
6: ; preds = %1, %1, %1, %1
store i32 1, i32* %2
br label %8
7: ; preds = %1
store i32 0, i32* %2
br label %8
8: ; preds = %7, %6
%9 = load i32, i32* %2
ret i32 %9
}

LLVM IR (-O2):
define i32 @is_valid_card_suite(i8 signext %0) {
%2 = sext i8 %0 to i32
switch i32 %2, label %3 [
i32 115, label %4
i32 100, label %4
i32 104, label %4
i32 99, label %4
]
3: ; preds = %1
br label %4
4: ; preds = %1, %1, %1, %1, %3
%5 = phi i32 [ 0, %3 ], [ 1, %1 ], [ 1, %1 ], [ 1, %1 ], [ 1, %1 ]
ret i32 %5
}
/* Variables and functions */
int rand();
int main(int argc, char **argv) {
  int x, y;
  int r = rand();
  if (r > 0) {
    y = rand();
    x = 42;
  } else {
    rand();
    y = rand();
    x = 7;
  }
  return x;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    $0x0,%al
call   1030 <rand@plt>
mov    %eax,-0x1c(%rbp)
cmpl   $0x0,-0x1c(%rbp)
jle    1150 <main+0x40>
mov    $0x0,%al
call   1030 <rand@plt>
mov    %eax,-0x18(%rbp)
movl   $0x2a,-0x14(%rbp)
jmp    1168 <main+0x58>
mov    $0x0,%al
call   1030 <rand@plt>
mov    $0x0,%al
call   1030 <rand@plt>
mov    %eax,-0x18(%rbp)
movl   $0x7,-0x14(%rbp)
mov    -0x14(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
xor    %eax,%eax
call   1030 <rand@plt>
mov    %eax,%ebx
xor    %eax,%eax
call   1030 <rand@plt>
mov    $0x2a,%eax
test   %ebx,%ebx
jle    112c <main+0x1c>
pop    %rbx
ret
xor    %eax,%eax
call   1030 <rand@plt>
mov    $0x7,%eax
pop    %rbx
ret

LLVM IR (-O0):
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%9 = call i32 (...) @rand()
store i32 %9, i32* %8
%10 = load i32, i32* %8
%11 = icmp sgt i32 %10, 0
br i1 %11, label %12, label %14
12: ; preds = %2
%13 = call i32 (...) @rand()
store i32 %13, i32* %7
store i32 42, i32* %6
br label %17
14: ; preds = %2
%15 = call i32 (...) @rand()
%16 = call i32 (...) @rand()
store i32 %16, i32* %7
store i32 7, i32* %6
br label %17
17: ; preds = %14, %12
%18 = load i32, i32* %6
ret i32 %18
}

LLVM IR (-O2):
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 (...) @rand()
%4 = icmp sgt i32 %3, 0
%5 = tail call i32 (...) @rand()
br i1 %4, label %8, label %6
6: ; preds = %2
%7 = tail call i32 (...) @rand()
br label %8
8: ; preds = %2, %6
%9 = phi i32 [ 7, %6 ], [ 42, %2 ]
ret i32 %9
}
void ClearScreen() {
  char *video = (char *)0xB8000;
  int i = 0;
  while (i < 80 * 25 * 2) {
    *video++ = 0;
    *video++ = 7;
    i++;
  }
}


x86 assembly (clang, -O0):
<ClearScreen>:
push   %rbp
mov    %rsp,%rbp
mov    $0xb8000,%eax
mov    %rax,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
cmpl   $0xfa0,-0xc(%rbp)
jge    1153 <ClearScreen+0x53>
mov    -0x8(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x8(%rbp)
movb   $0x0,(%rax)
mov    -0x8(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x8(%rbp)
movb   $0x7,(%rax)
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    1114 <ClearScreen+0x14>
pop    %rbp
ret

x86 assembly (clang, -O2):
<ClearScreen>:
mov    $0x18,%eax
mov    $0xb8000,%ecx
movaps 0xeef(%rip),%xmm0
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
movaps %xmm0,-0x30(%rcx,%rax,2)
movaps %xmm0,-0x20(%rcx,%rax,2)
movaps %xmm0,-0x10(%rcx,%rax,2)
movaps %xmm0,(%rcx,%rax,2)
add    $0x20,%rax
cmp    $0xfb8,%rax
jne    1120 <ClearScreen+0x20>
ret

LLVM IR (-O0):
define void @ClearScreen() {
%1 = alloca i8*
%2 = alloca i32
store i8* inttoptr (i64 753664 to i8*), i8** %1
store i32 0, i32* %2
br label %3
3: ; preds = %6, %0
%4 = load i32, i32* %2
%5 = icmp slt i32 %4, 4000
br i1 %5, label %6, label %13
6: ; preds = %3
%7 = load i8*, i8** %1
%8 = getelementptr inbounds i8, i8* %7, i32 1
store i8* %8, i8** %1
store i8 0, i8* %7
%9 = load i8*, i8** %1
%10 = getelementptr inbounds i8, i8* %9, i32 1
store i8* %10, i8** %1
store i8 7, i8* %9
%11 = load i32, i32* %2
%12 = add nsw i32 %11, 1
store i32 %12, i32* %2
br label %3
13: ; preds = %3
ret void
}

LLVM IR (-O2):
define void @ClearScreen() {
br label %1
1: ; preds = %1, %0
%2 = phi i64 [ 0, %0 ], [ %18, %1 ]
%3 = shl nuw i64 %2, 1
%4 = shl nuw i64 %2, 1
%5 = or i64 %4, 16
%6 = getelementptr inbounds i8, i8* inttoptr (i64 753664 to i8*), i64 %3
%7 = bitcast i8* %6 to <16 x i8>*
%8 = getelementptr inbounds i8, i8* inttoptr (i64 753664 to i8*), i64 %5
%9 = bitcast i8* %8 to <16 x i8>*
store <16 x i8> <i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7>, <16 x i8>* %7
store <16 x i8> <i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7>, <16 x i8>* %9
%10 = or i64 %2, 16
%11 = shl nuw i64 %10, 1
%12 = shl nuw i64 %10, 1
%13 = or i64 %12, 16
%14 = getelementptr inbounds i8, i8* inttoptr (i64 753664 to i8*), i64 %11
%15 = bitcast i8* %14 to <16 x i8>*
%16 = getelementptr inbounds i8, i8* inttoptr (i64 753664 to i8*), i64 %13
%17 = bitcast i8* %16 to <16 x i8>*
store <16 x i8> <i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7>, <16 x i8>* %15
store <16 x i8> <i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7, i8 0, i8 7>, <16 x i8>* %17
%18 = add nuw nsw i64 %2, 32
%19 = icmp eq i64 %18, 4000
br i1 %19, label %20, label %1
20: ; preds = %1
ret void
}
/* Variables and functions */
int /*<<< orphan*/ WNOHANG;
scalar_t__ waitpid(int, int /*<<< orphan*/ *, int /*<<< orphan*/);
void sigchld_handler(int s __attribute__((unused))) {
  while (waitpid(-1, NULL, WNOHANG) > 0) {
    ;
  }
}


x86 assembly (clang, -O0):
<sigchld_handler>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    0x2ec6(%rip),%rax
mov    (%rax),%edx
mov    $0xffffffff,%edi
xor    %eax,%eax
mov    %eax,%esi
call   1030 <waitpid@plt>
cmp    $0x0,%rax
jle    1141 <sigchld_handler+0x31>
jmp    111b <sigchld_handler+0xb>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<sigchld_handler>:
push   %rbx
mov    0x2ed0(%rip),%rbx
nopl   0x0(%rax,%rax,1)
mov    (%rbx),%edx
mov    $0xffffffff,%edi
xor    %esi,%esi
call   1030 <waitpid@plt>
test   %rax,%rax
jg     1120 <sigchld_handler+0x10>
pop    %rbx
ret

LLVM IR (-O0):
@WNOHANG = global i32 0
define void @sigchld_handler(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
br label %3
3: ; preds = %7, %1
%4 = load i32, i32* @WNOHANG
%5 = call i64 @waitpid(i32 -1, i32* null, i32 %4)
%6 = icmp sgt i64 %5, 0
br i1 %6, label %7, label %8
7: ; preds = %3
br label %3
8: ; preds = %3
ret void
}

LLVM IR (-O2):
@WNOHANG = global i32 0
define void @sigchld_handler(i32 %0) {
br label %2
2: ; preds = %2, %1
%3 = load i32, i32* @WNOHANG
%4 = tail call i64 @waitpid(i32 -1, i32* null, i32 %3)
%5 = icmp sgt i64 %4, 0
br i1 %5, label %2, label %6
6: ; preds = %2
ret void
}
/* Type definitions */
struct lifo {
  int dummy;
};

/* Variables and functions */
double asinh(double);
double pop(struct lifo *);
double opr_asinh(struct lifo *stack) {
  double op = pop(stack);
  return asinh(op);
}


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

x86 assembly (clang, -O2):
<opr_asinh>:
push   %rax
call   1030 <pop@plt>
pop    %rax
jmp    1040 <asinh@plt>

LLVM IR (-O0):
%struct.lifo = type { i32 }
define double @opr_asinh(%struct.lifo* %0) {
%2 = alloca %struct.lifo*
%3 = alloca double
store %struct.lifo* %0, %struct.lifo** %2
%4 = load %struct.lifo*, %struct.lifo** %2
%5 = call double @pop(%struct.lifo* %4)
store double %5, double* %3
%6 = load double, double* %3
%7 = call double @asinh(double %6)
ret double %7
}

LLVM IR (-O2):
%struct.lifo = type { i32 }
define double @opr_asinh(%struct.lifo* %0) {
%2 = tail call double @pop(%struct.lifo* %0)
%3 = tail call double @asinh(double %2)
ret double %3
}
/* Variables and functions */
int /*<<< orphan*/ int80(int, char *, char *, char *, int /*<<< orphan*/,
                         int /*<<< orphan*/, int /*<<< orphan*/);
char getDay() {
  char y;
  char mo;
  char d;
  int80(7, &d, &mo, &y, 0, 0, 0);
  return d;
}


x86 assembly (clang, -O0):
<getDay>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x7,%edi
lea    -0x3(%rbp),%rsi
lea    -0x2(%rbp),%rdx
lea    -0x1(%rbp),%rcx
xor    %r9d,%r9d
mov    %r9d,%r8d
movl   $0x0,(%rsp)
call   1030 <int80@plt>
movsbl -0x3(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<getDay>:
sub    $0x18,%rsp
movl   $0x0,(%rsp)
lea    0x15(%rsp),%rsi
lea    0x16(%rsp),%rdx
lea    0x17(%rsp),%rcx
mov    $0x7,%edi
xor    %r8d,%r8d
xor    %r9d,%r9d
call   1030 <int80@plt>
mov    0x15(%rsp),%al
add    $0x18,%rsp
ret

LLVM IR (-O0):
define signext i8 @getDay() {
%1 = alloca i8
%2 = alloca i8
%3 = alloca i8
%4 = call i32 @int80(i32 7, i8* %3, i8* %2, i8* %1, i32 0, i32 0, i32 0)
%5 = load i8, i8* %3
ret i8 %5
}

LLVM IR (-O2):
define signext i8 @getDay() {
%1 = alloca i8
%2 = alloca i8
%3 = alloca i8
%4 = call i32 @int80(i32 7, i8* %3, i8* %2, i8* %1, i32 0, i32 0, i32 0)
%5 = load i8, i8* %3
ret i8 %5
}
/* Type definitions */
typedef int /*<<< orphan*/ uint8_t;

/* Variables and functions */
int /*<<< orphan*/ SHA256(int /*<<< orphan*/ const *, size_t,
                          int /*<<< orphan*/ *);
void hash_digest(uint8_t *output, const uint8_t *input, size_t len) {
  SHA256(input, len, output);
}


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

x86 assembly (clang, -O2):
<hash_digest>:
mov    %rdi,%rax
mov    %rsi,%rdi
mov    %rdx,%rsi
mov    %rax,%rdx
jmp    1030 <SHA256@plt>

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

LLVM IR (-O2):
define void @hash_digest(i32* %0, i32* %1, i64 %2) {
%4 = tail call i32 @SHA256(i32* %1, i64 %2, i32* %0)
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ WINDOW;

/* Variables and functions */
int /*<<< orphan*/ box(int /*<<< orphan*/ *, int /*<<< orphan*/,
                       int /*<<< orphan*/);
int /*<<< orphan*/ wclear(int /*<<< orphan*/ *);
void wclearbox(WINDOW *win) {
  wclear(win);
  box(win, 0, 0);
}


x86 assembly (clang, -O0):
<wclearbox>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1040 <wclear@plt>
mov    -0x8(%rbp),%rdi
xor    %edx,%edx
mov    %edx,%esi
call   1030 <box@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<wclearbox>:
push   %rbx
mov    %rdi,%rbx
call   1040 <wclear@plt>
mov    %rbx,%rdi
xor    %esi,%esi
xor    %edx,%edx
pop    %rbx
jmp    1030 <box@plt>

LLVM IR (-O0):
define void @wclearbox(i32* %0) {
%2 = alloca i32*
store i32* %0, i32** %2
%3 = load i32*, i32** %2
%4 = call i32 @wclear(i32* %3)
%5 = load i32*, i32** %2
%6 = call i32 @box(i32* %5, i32 0, i32 0)
ret void
}

LLVM IR (-O2):
define void @wclearbox(i32* %0) {
%2 = tail call i32 @wclear(i32* %0)
%3 = tail call i32 @box(i32* %0, i32 0, i32 0)
ret void
}
/* Type definitions */
struct rtnl_link {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ rtnl_link_put(struct rtnl_link *);
void _nl_auto_rtnl_link_fcn(struct rtnl_link **v) {
  if (*v)
    rtnl_link_put(*v);
}


x86 assembly (clang, -O0):
<_nl_auto_rtnl_link_fcn>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
cmpq   $0x0,(%rax)
je     1136 <_nl_auto_rtnl_link_fcn+0x26>
mov    -0x8(%rbp),%rax
mov    (%rax),%rdi
call   1030 <rtnl_link_put@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<_nl_auto_rtnl_link_fcn>:
mov    (%rdi),%rdi
test   %rdi,%rdi
je     111d <_nl_auto_rtnl_link_fcn+0xd>
jmp    1030 <rtnl_link_put@plt>
ret

LLVM IR (-O0):
%struct.rtnl_link = type { i32 }
define void @_nl_auto_rtnl_link_fcn(%struct.rtnl_link** %0) {
%2 = alloca %struct.rtnl_link**
store %struct.rtnl_link** %0, %struct.rtnl_link*** %2
%3 = load %struct.rtnl_link**, %struct.rtnl_link*** %2
%4 = load %struct.rtnl_link*, %struct.rtnl_link** %3
%5 = icmp ne %struct.rtnl_link* %4, null
br i1 %5, label %6, label %10
6: ; preds = %1
%7 = load %struct.rtnl_link**, %struct.rtnl_link*** %2
%8 = load %struct.rtnl_link*, %struct.rtnl_link** %7
%9 = call i32 @rtnl_link_put(%struct.rtnl_link* %8)
br label %10
10: ; preds = %6, %1
ret void
}

LLVM IR (-O2):
%struct.rtnl_link = type { i32 }
define void @_nl_auto_rtnl_link_fcn(%struct.rtnl_link** nocapture %0) {
%2 = load %struct.rtnl_link*, %struct.rtnl_link** %0
%3 = icmp eq %struct.rtnl_link* %2, null
br i1 %3, label %6, label %4
4: ; preds = %1
%5 = tail call i32 @rtnl_link_put(%struct.rtnl_link* %2)
br label %6
6: ; preds = %4, %1
ret void
}
/* Type definitions */
typedef float uint16_t;

/* Variables and functions */
float Saturatef(float, float, float);
float Si7021RelHumidityRawToPercent(uint16_t raw) {
  float percent = (125.0f * raw) / 65536.0f - 6.0f;
  return Saturatef(percent, 0.0f, 100.0f);
}


x86 assembly (clang, -O0):
<Si7021RelHumidityRawToPercent>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movss  %xmm0,-0x4(%rbp)
movss  0xee7(%rip),%xmm0
mulss  -0x4(%rbp),%xmm0
movss  0xed6(%rip),%xmm1
divss  %xmm1,%xmm0
movss  0xec6(%rip),%xmm1
subss  %xmm1,%xmm0
movss  %xmm0,-0x8(%rbp)
movss  -0x8(%rbp),%xmm0
xorps  %xmm1,%xmm1
movss  0xea9(%rip),%xmm2
call   1030 <Saturatef@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<Si7021RelHumidityRawToPercent>:
mulss  0xee8(%rip),%xmm0
mulss  0xee4(%rip),%xmm0
addss  0xee0(%rip),%xmm0
movss  0xedc(%rip),%xmm2
xorps  %xmm1,%xmm1
jmp    1030 <Saturatef@plt>

LLVM IR (-O0):
define float @Si7021RelHumidityRawToPercent(float %0) {
%2 = alloca float
%3 = alloca float
store float %0, float* %2
%4 = load float, float* %2
%5 = fmul float 1.250000e+02, %4
%6 = fdiv float %5, 6.553600e+04
%7 = fsub float %6, 6.000000e+00
store float %7, float* %3
%8 = load float, float* %3
%9 = call float @Saturatef(float %8, float 0.000000e+00, float 1.000000e+02)
ret float %9
}

LLVM IR (-O2):
define float @Si7021RelHumidityRawToPercent(float %0) {
%2 = fmul float %0, 1.250000e+02
%3 = fmul float %2, 0x3EF0000000000000
%4 = fadd float %3, -6.000000e+00
%5 = tail call float @Saturatef(float %4, float 0.000000e+00, float 1.000000e+02)
ret float %5
}
/* Type definitions */
struct b_tonegen {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ setMIDIDrawBar(struct b_tonegen *, int, unsigned char);
void setDrawbar15(void *d, unsigned char v) {
  setMIDIDrawBar((struct b_tonegen *)d, 15, v);
}


x86 assembly (clang, -O0):
<setDrawbar15>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %sil,%al
mov    %rdi,-0x8(%rbp)
mov    %al,-0x9(%rbp)
mov    -0x8(%rbp),%rdi
mov    $0xf,%esi
movzbl -0x9(%rbp),%edx
call   1030 <setMIDIDrawBar@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<setDrawbar15>:
mov    %esi,%edx
mov    $0xf,%esi
jmp    1030 <setMIDIDrawBar@plt>

LLVM IR (-O0):
%struct.b_tonegen = type { i32 }
define void @setDrawbar15(i8* %0, i8 zeroext %1) {
%3 = alloca i8*
%4 = alloca i8
store i8* %0, i8** %3
store i8 %1, i8* %4
%5 = load i8*, i8** %3
%6 = bitcast i8* %5 to %struct.b_tonegen*
%7 = load i8, i8* %4
%8 = call i32 @setMIDIDrawBar(%struct.b_tonegen* %6, i32 15, i8 zeroext %7)
ret void
}

LLVM IR (-O2):
%struct.b_tonegen = type { i32 }
define void @setDrawbar15(i8* %0, i8 zeroext %1) {
%3 = bitcast i8* %0 to %struct.b_tonegen*
%4 = tail call i32 @setMIDIDrawBar(%struct.b_tonegen* %3, i32 15, i8 zeroext %1)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ wdctl_command(int);
void wdctl_show_trusted_pan_domains(void) { wdctl_command(31); }


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

x86 assembly (clang, -O2):
<wdctl_show_trusted_pan_domains>:
mov    $0x1f,%edi
jmp    1030 <wdctl_command@plt>

LLVM IR (-O0):
define void @wdctl_show_trusted_pan_domains() {
%1 = call i32 @wdctl_command(i32 31)
ret void
}

LLVM IR (-O2):
define void @wdctl_show_trusted_pan_domains() {
%1 = tail call i32 @wdctl_command(i32 31)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ xPL_shutdown();
int /*<<< orphan*/ xPL_stopHub();
void hubShutdownHandler(int onSignal) {
  xPL_stopHub();
  xPL_shutdown();
  exit(0);
}


x86 assembly (clang, -O0):
<hubShutdownHandler>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    $0x0,%al
call   1030 <xPL_stopHub@plt>
mov    $0x0,%al
call   1050 <xPL_shutdown@plt>
xor    %edi,%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<hubShutdownHandler>:
push   %rax
xor    %eax,%eax
call   1030 <xPL_stopHub@plt>
xor    %eax,%eax
call   1050 <xPL_shutdown@plt>
xor    %edi,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
define void @hubShutdownHandler(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = call i32 (...) @xPL_stopHub()
%4 = call i32 (...) @xPL_shutdown()
%5 = call i32 @exit(i32 0)
unreachable
}

LLVM IR (-O2):
define void @hubShutdownHandler(i32 %0) {
%2 = tail call i32 (...) @xPL_stopHub()
%3 = tail call i32 (...) @xPL_shutdown()
%4 = tail call i32 @exit(i32 0)
unreachable
}
int mpl115_i2c_init(struct device *dev) { return 0; }


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

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

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

LLVM IR (-O2):
%struct.device = type opaque
define i32 @mpl115_i2c_init(%struct.device* nocapture readnone %0) {
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ arg_short2(short, short);
void arg_short1(short i) { arg_short2(i, i + 1); }


x86 assembly (clang, -O0):
<arg_short1>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %di,%ax
mov    %ax,-0x2(%rbp)
mov    -0x2(%rbp),%cx
movswl -0x2(%rbp),%eax
add    $0x1,%eax
movswl %cx,%edi
movswl %ax,%esi
call   1030 <arg_short2@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<arg_short1>:
lea    0x1(%rdi),%eax
movswl %ax,%esi
jmp    1030 <arg_short2@plt>

LLVM IR (-O0):
define void @arg_short1(i16 signext %0) {
%2 = alloca i16
store i16 %0, i16* %2
%3 = load i16, i16* %2
%4 = load i16, i16* %2
%5 = sext i16 %4 to i32
%6 = add nsw i32 %5, 1
%7 = trunc i32 %6 to i16
%8 = call i32 @arg_short2(i16 signext %3, i16 signext %7)
ret void
}

LLVM IR (-O2):
define void @arg_short1(i16 signext %0) {
%2 = add i16 %0, 1
%3 = tail call i32 @arg_short2(i16 signext %0, i16 signext %2)
ret void
}
/* Type definitions */
typedef int uint32_t;

/* Variables and functions */
void lightsOn(void) { (*((volatile uint32_t *)0x4003100C)) = 0x01; }


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

x86 assembly (clang, -O2):
<lightsOn>:
movl   $0x1,0x4003100c
ret

LLVM IR (-O0):
define void @lightsOn() {
store volatile i32 1, i32* inttoptr (i64 1073942540 to i32*)
ret void
}

LLVM IR (-O2):
define void @lightsOn() {
store volatile i32 1, i32* inttoptr (i64 1073942540 to i32*)
ret void
}
void rt_sendrecvscanline(void *voidhandle) {}


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

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

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

LLVM IR (-O2):
define void @rt_sendrecvscanline(i8* nocapture %0) {
ret void
}
int test_imm_90uint64_lowword_reg(unsigned long long val) {
  return ((val) & (0x90 << 0)) ? -20 : -40;
}


x86 assembly (clang, -O0):
<test_imm_90uint64_lowword_reg>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdx
and    $0x90,%rdx
mov    $0xffffffd8,%eax
mov    $0xffffffec,%ecx
cmp    $0x0,%rdx
cmovne %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_imm_90uint64_lowword_reg>:
test   $0x90,%dil
mov    $0xffffffd8,%ecx
mov    $0xffffffec,%eax
cmove  %ecx,%eax
ret

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

LLVM IR (-O2):
define i32 @test_imm_90uint64_lowword_reg(i64 %0) {
%2 = and i64 %0, 144
%3 = icmp eq i64 %2, 0
%4 = select i1 %3, i32 -40, i32 -20
ret i32 %4
}
int xstrlen(const char *str) {
  register int n = 0;
  while (*str++)
    n++;
  return n;
}


x86 assembly (clang, -O0):
<xstrlen>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x8(%rbp)
cmpb   $0x0,(%rax)
je     1135 <xstrlen+0x35>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    110f <xstrlen+0xf>
mov    -0xc(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<xstrlen>:
cmpb   $0x0,(%rdi)
je     111c <xstrlen+0x1c>
xor    %eax,%eax
nopw   0x0(%rax,%rax,1)
cmpb   $0x0,0x1(%rdi,%rax,1)
lea    0x1(%rax),%rax
jne    1110 <xstrlen+0x10>
ret
xor    %eax,%eax
ret

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

LLVM IR (-O2):
define i32 @xstrlen(i8* nocapture %0) {
%2 = load i8, i8* %0
%3 = icmp eq i8 %2, 0
br i1 %3, label %11, label %4
4: ; preds = %1, %4
%5 = phi i32 [ %8, %4 ], [ 0, %1 ]
%6 = phi i8* [ %7, %4 ], [ %0, %1 ]
%7 = getelementptr inbounds i8, i8* %6, i64 1
%8 = add nuw nsw i32 %5, 1
%9 = load i8, i8* %7
%10 = icmp eq i8 %9, 0
br i1 %10, label %11, label %4
11: ; preds = %4, %1
%12 = phi i32 [ 0, %1 ], [ %8, %4 ]
ret i32 %12
}
/* Variables and functions */
int /*<<< orphan*/ parallel_clr_ndac(int);
int /*<<< orphan*/ parallel_set_ndac(int);
void parallel_emu_set_ndac(unsigned char val) {
  if (val) {
    parallel_set_ndac(0x01);
  } else {
    parallel_clr_ndac(~0x01);
  }
}


x86 assembly (clang, -O0):
<parallel_emu_set_ndac>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %dil,%al
mov    %al,-0x1(%rbp)
cmpb   $0x0,-0x1(%rbp)
je     1147 <parallel_emu_set_ndac+0x27>
mov    $0x1,%edi
call   1040 <parallel_set_ndac@plt>
jmp    1151 <parallel_emu_set_ndac+0x31>
mov    $0xfffffffe,%edi
call   1030 <parallel_clr_ndac@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<parallel_emu_set_ndac>:
test   %edi,%edi
je     112e <parallel_emu_set_ndac+0xe>
mov    $0x1,%edi
jmp    1040 <parallel_set_ndac@plt>
mov    $0xfffffffe,%edi
jmp    1030 <parallel_clr_ndac@plt>

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

LLVM IR (-O2):
define void @parallel_emu_set_ndac(i8 zeroext %0) {
%2 = icmp eq i8 %0, 0
br i1 %2, label %5, label %3
3: ; preds = %1
%4 = tail call i32 @parallel_set_ndac(i32 1)
br label %7
5: ; preds = %1
%6 = tail call i32 @parallel_clr_ndac(i32 -2)
br label %7
7: ; preds = %5, %3
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ uint8_t;

/* Variables and functions */
int /*<<< orphan*/ get_port(int /*<<< orphan*/, int /*<<< orphan*/, int, int);
uint8_t read_interrupt_status(uint8_t address, uint8_t port) {
  return get_port(address, port, 0x0E, 0x0F);
}


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

x86 assembly (clang, -O2):
<read_interrupt_status>:
mov    $0xe,%edx
mov    $0xf,%ecx
jmp    1030 <get_port@plt>

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

LLVM IR (-O2):
define i32 @read_interrupt_status(i32 %0, i32 %1) {
%3 = tail call i32 @get_port(i32 %0, i32 %1, i32 14, i32 15)
ret i32 %3
}
/* Type definitions */
struct S {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ non_existent(struct S *, int);
void hooray7(struct S *p) { non_existent(p, 7); }


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

x86 assembly (clang, -O2):
<hooray7>:
mov    $0x7,%esi
jmp    1030 <non_existent@plt>

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

LLVM IR (-O2):
%struct.S = type { i32 }
define void @hooray7(%struct.S* %0) {
%2 = tail call i32 @non_existent(%struct.S* %0, i32 7)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, int, char const *,
                           char const *);
int getpid();
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ stderr;
void error_handler(const char *name, const char *descr) {
  printf("ERROR\n");
  fprintf(stderr, "pid: %d, name: %s, %s\n", getpid(), name, descr);
  exit(0);
}


x86 assembly (clang, -O0):
<error_handler>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
lea    0xea9(%rip),%rdi
call   1040 <printf@plt>
mov    0x2e7d(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x14(%rbp)
mov    $0x0,%al
call   1030 <getpid@plt>
mov    -0x14(%rbp),%edi
mov    %eax,%edx
mov    -0x8(%rbp),%rcx
mov    -0x10(%rbp),%r8
lea    0xe84(%rip),%rsi
call   1050 <fprintf@plt>
xor    %edi,%edi
call   1060 <exit@plt>

x86 assembly (clang, -O2):
<error_handler>:
push   %rbp
push   %r14
push   %rbx
mov    %rsi,%r14
mov    %rdi,%rbx
lea    0xec6(%rip),%rdi
call   1030 <puts@plt>
mov    0x2e83(%rip),%rax
mov    (%rax),%ebp
xor    %eax,%eax
call   1040 <getpid@plt>
lea    0xe93(%rip),%rsi
mov    %ebp,%edi
mov    %eax,%edx
mov    %rbx,%rcx
mov    %r14,%r8
call   1050 <fprintf@plt>
xor    %edi,%edi
call   1060 <exit@plt>

LLVM IR (-O0):
@.str = [7 x i8] c"ERROR\0A\00"
@stderr = global i32 0
@.str.1 = [23 x i8] c"pid: %d, name: %s, %s\0A\00"
define void @error_handler(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
store i8* %0, i8** %3
store i8* %1, i8** %4
%5 = call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0))
%6 = load i32, i32* @stderr
%7 = call i32 (...) @getpid()
%8 = load i8*, i8** %3
%9 = load i8*, i8** %4
%10 = call i32 @fprintf(i32 %6, i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.1, i64 0, i64 0), i32 %7, i8* %8, i8* %9)
%11 = call i32 @exit(i32 0)
unreachable
}

LLVM IR (-O2):
@stderr = global i32 0
@.str.1 = [23 x i8] c"pid: %d, name: %s, %s\0A\00"
@str = [6 x i8] c"ERROR\00"
define void @error_handler(i8* %0, i8* %1) {
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @str, i64 0, i64 0))
%4 = load i32, i32* @stderr
%5 = tail call i32 (...) @getpid()
%6 = tail call i32 @fprintf(i32 %4, i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.1, i64 0, i64 0), i32 %5, i8* %0, i8* %1)
%7 = tail call i32 @exit(i32 0)
unreachable
}
void show_help() {}


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

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

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

LLVM IR (-O2):
define void @show_help() {
ret void
}
/* Variables and functions */
scalar_t__ isspace(char);
char scanc();
char skip_space() {
  char c;
  while (isspace(c = scanc()))
    ;
  return (c);
}


x86 assembly (clang, -O0):
<skip_space>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x0,%al
call   1040 <scanc@plt>
mov    %al,-0x1(%rbp)
movsbl %al,%edi
call   1030 <isspace@plt>
cmp    $0x0,%rax
je     1149 <skip_space+0x29>
jmp    1128 <skip_space+0x8>
movsbl -0x1(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<skip_space>:
push   %rbx
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
xor    %eax,%eax
call   1040 <scanc@plt>
mov    %eax,%ebx
movsbl %al,%edi
call   1030 <isspace@plt>
test   %rax,%rax
jne    1130 <skip_space+0x10>
mov    %ebx,%eax
pop    %rbx
ret

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

LLVM IR (-O2):
define signext i8 @skip_space() {
br label %1
1: ; preds = %1, %0
%2 = tail call signext i8 (...) @scanc()
%3 = tail call i64 @isspace(i8 signext %2)
%4 = icmp eq i64 %3, 0
br i1 %4, label %5, label %1
5: ; preds = %1
ret i8 %2
}
/* Variables and functions */
int /*<<< orphan*/ __VERIFIER_assert(int);
unsigned int __VERIFIER_nondet_uint();
int main() {
  unsigned int n = __VERIFIER_nondet_uint();
  unsigned int x = n, y = 0;
  while (x > 0) {
    x--;
    y++;
  }
  __VERIFIER_assert(y != n);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0x0,%al
call   1040 <__VERIFIER_nondet_uint@plt>
mov    %eax,-0x8(%rbp)
mov    -0x8(%rbp),%eax
mov    %eax,-0xc(%rbp)
movl   $0x0,-0x10(%rbp)
cmpl   $0x0,-0xc(%rbp)
jbe    1167 <main+0x47>
mov    -0xc(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0xc(%rbp)
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
jmp    1146 <main+0x26>
mov    -0x10(%rbp),%eax
cmp    -0x8(%rbp),%eax
setne  %al
and    $0x1,%al
movzbl %al,%edi
call   1030 <__VERIFIER_assert@plt>
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
store i32 0, i32* %1
%5 = call i32 (...) @__VERIFIER_nondet_uint()
store i32 %5, i32* %2
%6 = load i32, i32* %2
store i32 %6, i32* %3
store i32 0, i32* %4
br label %7
7: ; preds = %10, %0
%8 = load i32, i32* %3
%9 = icmp ugt i32 %8, 0
br i1 %9, label %10, label %15
10: ; preds = %7
%11 = load i32, i32* %3
%12 = add i32 %11, -1
store i32 %12, i32* %3
%13 = load i32, i32* %4
%14 = add i32 %13, 1
store i32 %14, i32* %4
br label %7
15: ; preds = %7
%16 = load i32, i32* %4
%17 = load i32, i32* %2
%18 = icmp ne i32 %16, %17
%19 = zext i1 %18 to i32
%20 = call i32 @__VERIFIER_assert(i32 %19)
%21 = load i32, i32* %1
ret i32 %21
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 (...) @__VERIFIER_nondet_uint()
%2 = tail call i32 @__VERIFIER_assert(i32 0)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ F_OK;
int /*<<< orphan*/ access(char const *, int /*<<< orphan*/);
bool fexists(const char *p) { return !access(p, F_OK); }


x86 assembly (clang, -O0):
<fexists>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
mov    0x2eb1(%rip),%rax
mov    (%rax),%esi
call   1030 <access@plt>
cmp    $0x0,%eax
setne  %al
xor    $0xff,%al
and    $0x1,%al
movzbl %al,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<fexists>:
push   %rax
mov    0x2ec0(%rip),%rax
mov    (%rax),%esi
call   1030 <access@plt>
xor    %ecx,%ecx
test   %eax,%eax
sete   %cl
mov    %ecx,%eax
pop    %rcx
ret

LLVM IR (-O0):
@F_OK = global i32 0
define i32 @fexists(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = load i32, i32* @F_OK
%5 = call i32 @access(i8* %3, i32 %4)
%6 = icmp ne i32 %5, 0
%7 = xor i1 %6, true
%8 = zext i1 %7 to i32
ret i32 %8
}

LLVM IR (-O2):
@F_OK = global i32 0
define i32 @fexists(i8* nocapture %0) {
%2 = load i32, i32* @F_OK
%3 = tail call i32 @access(i8* %0, i32 %2)
%4 = icmp eq i32 %3, 0
%5 = zext i1 %4 to i32
ret i32 %5
}
/* Variables and functions */
int has_dns_cap();
int has_http_cap();
int has_https_cap();
int has_ping_cap();
int caps_flags() {
  return has_http_cap() | has_https_cap() | has_ping_cap() | has_dns_cap();
}


x86 assembly (clang, -O0):
<caps_flags>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x0,%al
call   1040 <has_http_cap@plt>
mov    %eax,-0xc(%rbp)
mov    $0x0,%al
call   1060 <has_https_cap@plt>
mov    %eax,%ecx
mov    -0xc(%rbp),%eax
or     %ecx,%eax
mov    %eax,-0x8(%rbp)
mov    $0x0,%al
call   1030 <has_ping_cap@plt>
mov    %eax,%ecx
mov    -0x8(%rbp),%eax
or     %ecx,%eax
mov    %eax,-0x4(%rbp)
mov    $0x0,%al
call   1050 <has_dns_cap@plt>
mov    %eax,%ecx
mov    -0x4(%rbp),%eax
or     %ecx,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<caps_flags>:
push   %rbp
push   %rbx
push   %rax
xor    %eax,%eax
call   1040 <has_http_cap@plt>
mov    %eax,%ebx
xor    %eax,%eax
call   1060 <has_https_cap@plt>
mov    %eax,%ebp
or     %ebx,%ebp
xor    %eax,%eax
call   1030 <has_ping_cap@plt>
mov    %eax,%ebx
xor    %eax,%eax
call   1050 <has_dns_cap@plt>
or     %ebx,%eax
or     %ebp,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
define i32 @caps_flags() {
%1 = call i32 (...) @has_http_cap()
%2 = call i32 (...) @has_https_cap()
%3 = or i32 %1, %2
%4 = call i32 (...) @has_ping_cap()
%5 = or i32 %3, %4
%6 = call i32 (...) @has_dns_cap()
%7 = or i32 %5, %6
ret i32 %7
}

LLVM IR (-O2):
define i32 @caps_flags() {
%1 = tail call i32 (...) @has_http_cap()
%2 = tail call i32 (...) @has_https_cap()
%3 = or i32 %2, %1
%4 = tail call i32 (...) @has_ping_cap()
%5 = or i32 %3, %4
%6 = tail call i32 (...) @has_dns_cap()
%7 = or i32 %5, %6
ret i32 %7
}
/* Variables and functions */
scalar_t__ chdir(char const *);
int /*<<< orphan*/ fail(char *, char const *);
void xchdir(const char *dir) {
  if (chdir(dir) < 0)
    fail("cannot change directory to %s", dir);
}


x86 assembly (clang, -O0):
<xchdir>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1040 <chdir@plt>
cmp    $0x0,%rax
jge    114f <xchdir+0x2f>
mov    -0x8(%rbp),%rsi
lea    0xeb6(%rip),%rdi
call   1030 <fail@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<xchdir>:
push   %rbx
mov    %rdi,%rbx
call   1040 <chdir@plt>
test   %rax,%rax
js     1130 <xchdir+0x10>
pop    %rbx
ret
lea    0xec9(%rip),%rdi
mov    %rbx,%rsi
pop    %rbx
jmp    1030 <fail@plt>

LLVM IR (-O0):
@.str = [30 x i8] c"cannot change directory to %s\00"
define void @xchdir(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = call i64 @chdir(i8* %3)
%5 = icmp slt i64 %4, 0
br i1 %5, label %6, label %9
6: ; preds = %1
%7 = load i8*, i8** %2
%8 = call i32 @fail(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str, i64 0, i64 0), i8* %7)
br label %9
9: ; preds = %6, %1
ret void
}

LLVM IR (-O2):
@.str = [30 x i8] c"cannot change directory to %s\00"
define void @xchdir(i8* %0) {
%2 = tail call i64 @chdir(i8* %0)
%3 = icmp slt i64 %2, 0
br i1 %3, label %4, label %6
4: ; preds = %1
%5 = tail call i32 @fail(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str, i64 0, i64 0), i8* %0)
br label %6
6: ; preds = %4, %1
ret void
}
int fib(int n) {
  if (n <= 0)
    return 0;
  if (n == 1)
    return 1;
  return fib(n - 1) + fib(n - 2);
}


x86 assembly (clang, -O0):
<fib>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x8(%rbp)
cmpl   $0x0,-0x8(%rbp)
jg     1131 <fib+0x21>
movl   $0x0,-0x4(%rbp)
jmp    116a <fib+0x5a>
cmpl   $0x1,-0x8(%rbp)
jne    1147 <fib+0x37>
movl   $0x1,-0x4(%rbp)
jmp    116a <fib+0x5a>
mov    -0x8(%rbp),%edi
sub    $0x1,%edi
call   1030 <fib@plt>
mov    %eax,-0xc(%rbp)
mov    -0x8(%rbp),%edi
sub    $0x2,%edi
call   1030 <fib@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):
<fib>:
push   %rbp
push   %r14
push   %rbx
test   %edi,%edi
jle    1140 <fib+0x30>
mov    %edi,%ebx
lea    -0x1(%rbx),%ebp
xor    %r14d,%r14d
test   %ebp,%ebp
je     1145 <fib+0x35>
lea    -0x1(%rbx),%edi
call   1030 <fib@plt>
lea    -0x2(%rbx),%ecx
add    %eax,%r14d
add    $0xfffffffe,%ebp
cmp    $0x2,%ebx
mov    %ecx,%ebx
ja     1120 <fib+0x10>
xor    %eax,%eax
jmp    114a <fib+0x3a>
xor    %r14d,%r14d
jmp    114d <fib+0x3d>
mov    $0x1,%eax
add    %eax,%r14d
mov    %r14d,%eax
pop    %rbx
pop    %r14
pop    %rbp
ret

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

LLVM IR (-O2):
define i32 @fib(i32 %0) {
%2 = icmp slt i32 %0, 1
br i1 %2, label %17, label %3
3: ; preds = %1, %7
%4 = phi i32 [ %10, %7 ], [ %0, %1 ]
%5 = phi i32 [ %11, %7 ], [ 0, %1 ]
%6 = icmp eq i32 %4, 1
br i1 %6, label %13, label %7
7: ; preds = %3
%8 = add nsw i32 %4, -1
%9 = tail call i32 @fib(i32 %8)
%10 = add nsw i32 %4, -2
%11 = add nsw i32 %9, %5
%12 = icmp ult i32 %4, 3
br i1 %12, label %13, label %3
13: ; preds = %3, %7
%14 = phi i32 [ %11, %7 ], [ %5, %3 ]
%15 = phi i32 [ 0, %7 ], [ 1, %3 ]
%16 = add nsw i32 %15, %14
br label %17
17: ; preds = %13, %1
%18 = phi i32 [ %16, %13 ], [ 0, %1 ]
ret i32 %18
}
/* Type definitions */
struct timeval {
  scalar_t__ tv_usec;
  scalar_t__ tv_sec;
};

/* Variables and functions */
int /*<<< orphan*/ gettimeofday(struct timeval *, int /*<<< orphan*/ *);
double get_time(void) {
  struct timeval tv;
  gettimeofday(&tv, NULL);
  return ((double)(tv.tv_sec) + (double)(tv.tv_usec) * 0.001 * 0.001);
}


x86 assembly (clang, -O0):
<get_time>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
lea    -0x10(%rbp),%rdi
xor    %eax,%eax
mov    %eax,%esi
call   1030 <gettimeofday@plt>
cvtsi2sdq -0x8(%rbp),%xmm1
cvtsi2sdq -0x10(%rbp),%xmm0
movsd  0xec7(%rip),%xmm2
mulsd  %xmm2,%xmm0
movsd  0xebb(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<get_time>:
sub    $0x18,%rsp
lea    0x8(%rsp),%rdi
xor    %esi,%esi
call   1030 <gettimeofday@plt>
cvtsi2sdq 0x10(%rsp),%xmm1
cvtsi2sdq 0x8(%rsp),%xmm0
movsd  0xeca(%rip),%xmm2
mulsd  %xmm2,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
add    $0x18,%rsp
ret

LLVM IR (-O0):
%struct.timeval = type { i64, i64 }
define double @get_time() {
%1 = alloca %struct.timeval
%2 = call i32 @gettimeofday(%struct.timeval* %1, i32* null)
%3 = getelementptr inbounds %struct.timeval, %struct.timeval* %1, i32 0, i32 1
%4 = load i64, i64* %3
%5 = sitofp i64 %4 to double
%6 = getelementptr inbounds %struct.timeval, %struct.timeval* %1, i32 0, i32 0
%7 = load i64, i64* %6
%8 = sitofp i64 %7 to double
%9 = fmul double %8, 1.000000e-03
%10 = call double @llvm.fmuladd.f64(double %9, double 1.000000e-03, double %5)
ret double %10
}

LLVM IR (-O2):
%struct.timeval = type { i64, i64 }
define double @get_time() {
%1 = alloca %struct.timeval
%2 = bitcast %struct.timeval* %1 to i8*
%3 = call i32 @gettimeofday(%struct.timeval* %1, i32* null)
%4 = getelementptr inbounds %struct.timeval, %struct.timeval* %1, i64 0, i32 1
%5 = load i64, i64* %4
%6 = sitofp i64 %5 to double
%7 = getelementptr inbounds %struct.timeval, %struct.timeval* %1, i64 0, i32 0
%8 = load i64, i64* %7
%9 = sitofp i64 %8 to double
%10 = fmul double %9, 1.000000e-03
%11 = tail call double @llvm.fmuladd.f64(double %10, double 1.000000e-03, double %6)
ret double %11
}
/* Variables and functions */
char **fspath_split(const char path[]) { return NULL; }


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

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

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

LLVM IR (-O2):
define noalias i8** @fspath_split(i8* nocapture readnone %0) {
ret i8** null
}
unsigned getval_237() { return 3284633928U; }


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

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

LLVM IR (-O0):
define i32 @getval_237() {
ret i32 -1010333368
}

LLVM IR (-O2):
define i32 @getval_237() {
ret i32 -1010333368
}
/* Variables and functions */
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, char *);
int /*<<< orphan*/ stdout;
void main_usage(int status) {
  fprintf(
      stdout,
      "\nUsage: %s <command> [options]\n\nCommand:\npe\tpaired-end sequence "
      "trimming\nse\tsingle-end sequence trimming\n\n--help, display this help "
      "and exit\n--version, output version information and exit\n\n",
      "sickle");
  exit(status);
}


x86 assembly (clang, -O0):
<main_usage>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    0x2eae(%rip),%rax
mov    (%rax),%edi
lea    0xec5(%rip),%rsi
lea    0xf7c(%rip),%rdx
call   1030 <fprintf@plt>
mov    -0x4(%rbp),%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<main_usage>:
push   %rbx
mov    %edi,%ebx
mov    0x2eb6(%rip),%rax
mov    (%rax),%edi
lea    0xecd(%rip),%rsi
lea    0xf84(%rip),%rdx
call   1030 <fprintf@plt>
mov    %ebx,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@stdout = global i32 0
@.str = [190 x i8] c"\0AUsage: %s <command> [options]\0A\0ACommand:\0Ape\09paired-end sequence trimming\0Ase\09single-end sequence trimming\0A\0A--help, display this help and exit\0A--version, output version information and exit\0A\0A\00"
@.str.1 = [7 x i8] c"sickle\00"
define void @main_usage(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* @stdout
%4 = call i32 @fprintf(i32 %3, i8* getelementptr inbounds ([190 x i8], [190 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0))
%5 = load i32, i32* %2
%6 = call i32 @exit(i32 %5)
unreachable
}

LLVM IR (-O2):
@stdout = global i32 0
@.str = [190 x i8] c"\0AUsage: %s <command> [options]\0A\0ACommand:\0Ape\09paired-end sequence trimming\0Ase\09single-end sequence trimming\0A\0A--help, display this help and exit\0A--version, output version information and exit\0A\0A\00"
@.str.1 = [7 x i8] c"sickle\00"
define void @main_usage(i32 %0) {
%2 = load i32, i32* @stdout
%3 = tail call i32 @fprintf(i32 %2, i8* getelementptr inbounds ([190 x i8], [190 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0))
%4 = tail call i32 @exit(i32 %0)
unreachable
}