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

/* Variables and functions */
int /*<<< orphan*/ __infer_nondet_int();
wint_t towupper(wint_t wc) { return __infer_nondet_int(); }


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

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

LLVM IR (-O0):
define i32 @towupper(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = call i32 (...) @__infer_nondet_int()
ret i32 %3
}

LLVM IR (-O2):
define i32 @towupper(i32 %0) {
%2 = tail call i32 (...) @__infer_nondet_int()
ret i32 %2
}
/* Type definitions */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
int /*<<< orphan*/ fwrite(char *, int, int, int /*<<< orphan*/ *);
void write_pe_signature(FILE *file) {
  char buffer[4];
  buffer[0] = 'P';
  buffer[1] = 'E';
  buffer[2] = 0;
  buffer[3] = 0;
  fwrite(buffer, 1, 4, file);
}


x86 assembly (clang, -O0):
<write_pe_signature>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
movb   $0x50,-0xc(%rbp)
movb   $0x45,-0xb(%rbp)
movb   $0x0,-0xa(%rbp)
movb   $0x0,-0x9(%rbp)
lea    -0xc(%rbp),%rdi
mov    -0x8(%rbp),%rcx
mov    $0x1,%esi
mov    $0x4,%edx
call   1030 <fwrite@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<write_pe_signature>:
push   %rax
mov    %rdi,%rcx
movl   $0x4550,0x4(%rsp)
lea    0x4(%rsp),%rdi
mov    $0x1,%esi
mov    $0x4,%edx
call   1030 <fwrite@plt>
pop    %rax
ret

LLVM IR (-O0):
define void @write_pe_signature(i32* %0) {
%2 = alloca i32*
%3 = alloca [4 x i8]
store i32* %0, i32** %2
%4 = getelementptr inbounds [4 x i8], [4 x i8]* %3, i64 0, i64 0
store i8 80, i8* %4
%5 = getelementptr inbounds [4 x i8], [4 x i8]* %3, i64 0, i64 1
store i8 69, i8* %5
%6 = getelementptr inbounds [4 x i8], [4 x i8]* %3, i64 0, i64 2
store i8 0, i8* %6
%7 = getelementptr inbounds [4 x i8], [4 x i8]* %3, i64 0, i64 3
store i8 0, i8* %7
%8 = getelementptr inbounds [4 x i8], [4 x i8]* %3, i64 0, i64 0
%9 = load i32*, i32** %2
%10 = call i32 @fwrite(i8* %8, i32 1, i32 4, i32* %9)
ret void
}

LLVM IR (-O2):
define void @write_pe_signature(i32* nocapture %0) {
%2 = alloca [4 x i8]
%3 = getelementptr inbounds [4 x i8], [4 x i8]* %2, i64 0, i64 0
store i8 80, i8* %3
%4 = getelementptr inbounds [4 x i8], [4 x i8]* %2, i64 0, i64 1
store i8 69, i8* %4
%5 = getelementptr inbounds [4 x i8], [4 x i8]* %2, i64 0, i64 2
store i8 0, i8* %5
%6 = getelementptr inbounds [4 x i8], [4 x i8]* %2, i64 0, i64 3
store i8 0, i8* %6
%7 = call i32 @fwrite(i8* %3, i32 1, i32 4, i32* %0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ emitln(char *);
int /*<<< orphan*/ match(char);
int /*<<< orphan*/ term();
void subtract(void) {
  match('-');
  term();
  emitln("SUB (SP)+,D0");
  emitln("NEG D0");
}


x86 assembly (clang, -O0):
<subtract>:
push   %rbp
mov    %rsp,%rbp
mov    $0x2d,%edi
call   1050 <match@plt>
mov    $0x0,%al
call   1040 <term@plt>
lea    0xeb4(%rip),%rdi
call   1030 <emitln@plt>
lea    0xeb5(%rip),%rdi
call   1030 <emitln@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<subtract>:
push   %rax
mov    $0x2d,%edi
call   1050 <match@plt>
xor    %eax,%eax
call   1040 <term@plt>
lea    0xeb7(%rip),%rdi
call   1030 <emitln@plt>
lea    0xeb8(%rip),%rdi
pop    %rax
jmp    1030 <emitln@plt>

LLVM IR (-O0):
@.str = [13 x i8] c"SUB (SP)+,D0\00"
@.str.1 = [7 x i8] c"NEG D0\00"
define void @subtract() {
%1 = call i32 @match(i8 signext 45)
%2 = call i32 (...) @term()
%3 = call i32 @emitln(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
%4 = call i32 @emitln(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [13 x i8] c"SUB (SP)+,D0\00"
@.str.1 = [7 x i8] c"NEG D0\00"
define void @subtract() {
%1 = tail call i32 @match(i8 signext 45)
%2 = tail call i32 (...) @term()
%3 = tail call i32 @emitln(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
%4 = tail call i32 @emitln(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0))
ret void
}
void rop3_62_1_1(unsigned char *D, unsigned char S, unsigned char T) {
  unsigned char stk1;
  unsigned char stk2;
  unsigned char stk3;
  unsigned char stk4;
  stk4 = ~S;
  stk3 = *D & stk4;
  stk2 = T | stk3;
  stk1 = S ^ stk2;
  *D = (stk1 & (~S) & (~T)) | (*D & S) | (*D & T);
}


x86 assembly (clang, -O0):
<rop3_62_1_1>:
push   %rbp
mov    %rsp,%rbp
mov    %dl,%al
mov    %sil,%cl
mov    %rdi,-0x8(%rbp)
mov    %cl,-0x9(%rbp)
mov    %al,-0xa(%rbp)
movzbl -0x9(%rbp),%eax
xor    $0xffffffff,%eax
mov    %al,-0xe(%rbp)
mov    -0x8(%rbp),%rax
movzbl (%rax),%eax
movzbl -0xe(%rbp),%ecx
and    %ecx,%eax
mov    %al,-0xd(%rbp)
movzbl -0xa(%rbp),%eax
movzbl -0xd(%rbp),%ecx
or     %ecx,%eax
mov    %al,-0xc(%rbp)
movzbl -0x9(%rbp),%eax
movzbl -0xc(%rbp),%ecx
xor    %ecx,%eax
mov    %al,-0xb(%rbp)
movzbl -0xb(%rbp),%eax
movzbl -0x9(%rbp),%ecx
xor    $0xffffffff,%ecx
and    %ecx,%eax
movzbl -0xa(%rbp),%ecx
xor    $0xffffffff,%ecx
and    %ecx,%eax
mov    -0x8(%rbp),%rcx
movzbl (%rcx),%ecx
movzbl -0x9(%rbp),%edx
and    %edx,%ecx
or     %ecx,%eax
mov    -0x8(%rbp),%rcx
movzbl (%rcx),%ecx
movzbl -0xa(%rbp),%edx
and    %edx,%ecx
or     %ecx,%eax
mov    %al,%cl
mov    -0x8(%rbp),%rax
mov    %cl,(%rax)
pop    %rbp
ret

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

LLVM IR (-O0):
define void @rop3_62_1_1(i8* %0, i8 zeroext %1, i8 zeroext %2) {
%4 = alloca i8*
%5 = alloca i8
%6 = alloca i8
%7 = alloca i8
%8 = alloca i8
%9 = alloca i8
%10 = alloca i8
store i8* %0, i8** %4
store i8 %1, i8* %5
store i8 %2, i8* %6
%11 = load i8, i8* %5
%12 = zext i8 %11 to i32
%13 = xor i32 %12, -1
%14 = trunc i32 %13 to i8
store i8 %14, i8* %10
%15 = load i8*, i8** %4
%16 = load i8, i8* %15
%17 = zext i8 %16 to i32
%18 = load i8, i8* %10
%19 = zext i8 %18 to i32
%20 = and i32 %17, %19
%21 = trunc i32 %20 to i8
store i8 %21, i8* %9
%22 = load i8, i8* %6
%23 = zext i8 %22 to i32
%24 = load i8, i8* %9
%25 = zext i8 %24 to i32
%26 = or i32 %23, %25
%27 = trunc i32 %26 to i8
store i8 %27, i8* %8
%28 = load i8, i8* %5
%29 = zext i8 %28 to i32
%30 = load i8, i8* %8
%31 = zext i8 %30 to i32
%32 = xor i32 %29, %31
%33 = trunc i32 %32 to i8
store i8 %33, i8* %7
%34 = load i8, i8* %7
%35 = zext i8 %34 to i32
%36 = load i8, i8* %5
%37 = zext i8 %36 to i32
%38 = xor i32 %37, -1
%39 = and i32 %35, %38
%40 = load i8, i8* %6
%41 = zext i8 %40 to i32
%42 = xor i32 %41, -1
%43 = and i32 %39, %42
%44 = load i8*, i8** %4
%45 = load i8, i8* %44
%46 = zext i8 %45 to i32
%47 = load i8, i8* %5
%48 = zext i8 %47 to i32
%49 = and i32 %46, %48
%50 = or i32 %43, %49
%51 = load i8*, i8** %4
%52 = load i8, i8* %51
%53 = zext i8 %52 to i32
%54 = load i8, i8* %6
%55 = zext i8 %54 to i32
%56 = and i32 %53, %55
%57 = or i32 %50, %56
%58 = trunc i32 %57 to i8
%59 = load i8*, i8** %4
store i8 %58, i8* %59
ret void
}

LLVM IR (-O2):
define void @rop3_62_1_1(i8* nocapture %0, i8 zeroext %1, i8 zeroext %2) {
ret void
}
void exit_thread_io(struct task_struct *me) {}


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

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

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

LLVM IR (-O2):
%struct.task_struct = type opaque
define void @exit_thread_io(%struct.task_struct* nocapture %0) {
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ uint64_t;
typedef int /*<<< orphan*/ off_t;

/* Variables and functions */
int /*<<< orphan*/ read_msr_single_core(int, int /*<<< orphan*/,
                                        int /*<<< orphan*/,
                                        int /*<<< orphan*/ *);
void read_msr(int socket, off_t msr, uint64_t *val) {
  read_msr_single_core(socket, 0, msr, val);
}


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

x86 assembly (clang, -O2):
<read_msr>:
mov    %rdx,%rcx
mov    %esi,%edx
xor    %esi,%esi
jmp    1030 <read_msr_single_core@plt>

LLVM IR (-O0):
define void @read_msr(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 @read_msr_single_core(i32 %7, i32 0, i32 %8, i32* %9)
ret void
}

LLVM IR (-O2):
define void @read_msr(i32 %0, i32 %1, i32* %2) {
%4 = tail call i32 @read_msr_single_core(i32 %0, i32 0, i32 %1, i32* %2)
ret void
}
int test_imm_A0int64_highword_mem(long long *val) {
  return ((*val >> 32) & (0xA0 << 0)) ? -20 : -40;
}


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

x86 assembly (clang, -O2):
<test_imm_A0int64_highword_mem>:
testb  $0xa0,0x4(%rdi)
mov    $0xffffffd8,%ecx
mov    $0xffffffec,%eax
cmove  %ecx,%eax
ret

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

LLVM IR (-O2):
define i32 @test_imm_A0int64_highword_mem(i64* nocapture %0) {
%2 = load i64, i64* %0
%3 = and i64 %2, 687194767360
%4 = icmp eq i64 %3, 0
%5 = select i1 %4, i32 -40, i32 -20
ret i32 %5
}
/* Type definitions */
typedef int uint32_t;

/* Variables and functions */
int /*<<< orphan*/ _HibernateWriteComplete();
void HibernateRTCDisable(void) {
  (*((volatile uint32_t *)(0x400FC010))) &= ~0x00000001;
  _HibernateWriteComplete();
}


x86 assembly (clang, -O0):
<HibernateRTCDisable>:
push   %rbp
mov    %rsp,%rbp
mov    $0x400fc010,%eax
mov    (%rax),%ecx
and    $0xfffffffe,%ecx
mov    $0x400fc010,%eax
mov    %ecx,(%rax)
mov    $0x0,%al
call   1030 <_HibernateWriteComplete@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<HibernateRTCDisable>:
andl   $0xfffffffe,0x400fc010
fe
xor    %eax,%eax
jmp    1030 <_HibernateWriteComplete@plt>

LLVM IR (-O0):
define void @HibernateRTCDisable() {
%1 = load volatile i32, i32* inttoptr (i64 1074774032 to i32*)
%2 = and i32 %1, -2
store volatile i32 %2, i32* inttoptr (i64 1074774032 to i32*)
%3 = call i32 (...) @_HibernateWriteComplete()
ret void
}

LLVM IR (-O2):
define void @HibernateRTCDisable() {
%1 = load volatile i32, i32* inttoptr (i64 1074774032 to i32*)
%2 = and i32 %1, -2
store volatile i32 %2, i32* inttoptr (i64 1074774032 to i32*)
%3 = tail call i32 (...) @_HibernateWriteComplete()
ret void
}
/* Variables and functions */
void *(Memento_label)(void *ptr, const char *label) { return ptr; }


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

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

LLVM IR (-O0):
define i8* @Memento_label(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
store i8* %0, i8** %3
store i8* %1, i8** %4
%5 = load i8*, i8** %3
ret i8* %5
}

LLVM IR (-O2):
define i8* @Memento_label(i8* readnone returned %0, i8* nocapture readnone %1) {
ret i8* %0
}
/* Variables and functions */
int /*<<< orphan*/ is_interruptible();
int read_cop0_status();
int /*<<< orphan*/ write_cop0_status(int);
void enableinterrupt(void) {
  if (!is_interruptible()) {
    write_cop0_status((read_cop0_status() & ~0x00000002 & ~0x00000004) |
                      0x00000001);
  }
}


x86 assembly (clang, -O0):
<enableinterrupt>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1050 <is_interruptible@plt>
cmp    $0x0,%eax
jne    115b <enableinterrupt+0x2b>
mov    $0x0,%al
call   1040 <read_cop0_status@plt>
mov    %eax,%edi
and    $0xfffffffd,%edi
and    $0xfffffffb,%edi
or     $0x1,%edi
call   1030 <write_cop0_status@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<enableinterrupt>:
push   %rax
xor    %eax,%eax
call   1050 <is_interruptible@plt>
test   %eax,%eax
je     113e <enableinterrupt+0xe>
pop    %rax
ret
xor    %eax,%eax
call   1040 <read_cop0_status@plt>
and    $0xfffffff8,%eax
lea    0x1(%rax),%edi
pop    %rax
jmp    1030 <write_cop0_status@plt>

LLVM IR (-O0):
define void @enableinterrupt() {
%1 = call i32 (...) @is_interruptible()
%2 = icmp ne i32 %1, 0
br i1 %2, label %9, label %3
3: ; preds = %0
%4 = call i32 (...) @read_cop0_status()
%5 = and i32 %4, -3
%6 = and i32 %5, -5
%7 = or i32 %6, 1
%8 = call i32 @write_cop0_status(i32 %7)
br label %9
9: ; preds = %3, %0
ret void
}

LLVM IR (-O2):
define void @enableinterrupt() {
%1 = tail call i32 (...) @is_interruptible()
%2 = icmp eq i32 %1, 0
br i1 %2, label %3, label %8
3: ; preds = %0
%4 = tail call i32 (...) @read_cop0_status()
%5 = and i32 %4, -8
%6 = or i32 %5, 1
%7 = tail call i32 @write_cop0_status(i32 %6)
br label %8
8: ; preds = %3, %0
ret void
}
/* Variables and functions */
double dstrb_log_gamma_function(double const);
double exp(double const);
double dstrb_beta_function(const double x, const double y) {
  const double gx = dstrb_log_gamma_function(x);
  const double gy = dstrb_log_gamma_function(y);
  const double gz = dstrb_log_gamma_function(x + y);
  const double logbeta = gx + gy - gz;
  return exp(logbeta);
}


x86 assembly (clang, -O0):
<dstrb_beta_function>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
movsd  -0x8(%rbp),%xmm0
call   1030 <dstrb_log_gamma_function@plt>
movsd  %xmm0,-0x18(%rbp)
movsd  -0x10(%rbp),%xmm0
call   1030 <dstrb_log_gamma_function@plt>
movsd  %xmm0,-0x20(%rbp)
movsd  -0x8(%rbp),%xmm0
addsd  -0x10(%rbp),%xmm0
call   1030 <dstrb_log_gamma_function@plt>
movsd  %xmm0,-0x28(%rbp)
movsd  -0x18(%rbp),%xmm0
addsd  -0x20(%rbp),%xmm0
subsd  -0x28(%rbp),%xmm0
movsd  %xmm0,-0x30(%rbp)
movsd  -0x30(%rbp),%xmm0
call   1040 <exp@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<dstrb_beta_function>:
sub    $0x28,%rsp
movsd  %xmm1,0x8(%rsp)
movsd  %xmm0,0x18(%rsp)
call   1030 <dstrb_log_gamma_function@plt>
movsd  %xmm0,0x20(%rsp)
movsd  0x8(%rsp),%xmm0
call   1030 <dstrb_log_gamma_function@plt>
movsd  %xmm0,0x10(%rsp)
movsd  0x18(%rsp),%xmm0
addsd  0x8(%rsp),%xmm0
call   1030 <dstrb_log_gamma_function@plt>
movsd  0x10(%rsp),%xmm1
addsd  0x20(%rsp),%xmm1
subsd  %xmm0,%xmm1
movapd %xmm1,%xmm0
add    $0x28,%rsp
jmp    1040 <exp@plt>

LLVM IR (-O0):
define double @dstrb_beta_function(double %0, double %1) {
%3 = alloca double
%4 = alloca double
%5 = alloca double
%6 = alloca double
%7 = alloca double
%8 = alloca double
store double %0, double* %3
store double %1, double* %4
%9 = load double, double* %3
%10 = call double @dstrb_log_gamma_function(double %9)
store double %10, double* %5
%11 = load double, double* %4
%12 = call double @dstrb_log_gamma_function(double %11)
store double %12, double* %6
%13 = load double, double* %3
%14 = load double, double* %4
%15 = fadd double %13, %14
%16 = call double @dstrb_log_gamma_function(double %15)
store double %16, double* %7
%17 = load double, double* %5
%18 = load double, double* %6
%19 = fadd double %17, %18
%20 = load double, double* %7
%21 = fsub double %19, %20
store double %21, double* %8
%22 = load double, double* %8
%23 = call double @exp(double %22)
ret double %23
}

LLVM IR (-O2):
define double @dstrb_beta_function(double %0, double %1) {
%3 = tail call double @dstrb_log_gamma_function(double %0)
%4 = tail call double @dstrb_log_gamma_function(double %1)
%5 = fadd double %0, %1
%6 = tail call double @dstrb_log_gamma_function(double %5)
%7 = fadd double %3, %4
%8 = fsub double %7, %6
%9 = tail call double @exp(double %8)
ret double %9
}
/* Type definitions */
typedef scalar_t__ uint32_t;

/* Variables and functions */
void EPIModeSet(uint32_t ui32Base, uint32_t ui32Mode) {
  ;

  ;
  (*((volatile uint32_t *)(ui32Base + 0x00000000))) = ui32Mode;
}


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

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

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

LLVM IR (-O2):
define void @EPIModeSet(i64 %0, i64 %1) {
%3 = inttoptr i64 %0 to i64*
store volatile i64 %1, i64* %3
ret void
}
/* Variables and functions */
int /*<<< orphan*/ fpclassify(long double);
void uninitvar_fpclassify(void) {
  float f;
  (void)fpclassify(f);
  double d;
  (void)fpclassify(d);
  long double ld;
  (void)fpclassify(ld);
}


x86 assembly (clang, -O0):
<uninitvar_fpclassify>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
flds   -0x4(%rbp)
mov    %rsp,%rax
fstpt  (%rax)
call   1030 <fpclassify@plt>
fldl   -0x10(%rbp)
mov    %rsp,%rax
fstpt  (%rax)
call   1030 <fpclassify@plt>
fldt   -0x20(%rbp)
mov    %rsp,%rax
fstpt  (%rax)
call   1030 <fpclassify@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<uninitvar_fpclassify>:
sub    $0x18,%rsp
call   1030 <fpclassify@plt>
call   1030 <fpclassify@plt>
call   1030 <fpclassify@plt>
add    $0x18,%rsp
ret

LLVM IR (-O0):
define void @uninitvar_fpclassify() {
%1 = alloca float
%2 = alloca double
%3 = alloca x86_fp80
%4 = load float, float* %1
%5 = fpext float %4 to x86_fp80
%6 = call i32 @fpclassify(x86_fp80 %5)
%7 = load double, double* %2
%8 = fpext double %7 to x86_fp80
%9 = call i32 @fpclassify(x86_fp80 %8)
%10 = load x86_fp80, x86_fp80* %3
%11 = call i32 @fpclassify(x86_fp80 %10)
ret void
}

LLVM IR (-O2):
define void @uninitvar_fpclassify() {
%1 = tail call i32 @fpclassify(x86_fp80 undef)
%2 = tail call i32 @fpclassify(x86_fp80 undef)
%3 = tail call i32 @fpclassify(x86_fp80 undef)
ret void
}
/* Variables and functions */
void *malloc(int);
void default_mutex_create(void **mutex) {
  *mutex = malloc(sizeof(int));
  *(int *)*mutex = 0;
}


x86 assembly (clang, -O0):
<default_mutex_create>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    $0x4,%edi
call   1030 <malloc@plt>
mov    %rax,%rcx
mov    -0x8(%rbp),%rax
mov    %rcx,(%rax)
mov    -0x8(%rbp),%rax
mov    (%rax),%rax
movl   $0x0,(%rax)
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<default_mutex_create>:
push   %rbx
mov    %rdi,%rbx
mov    $0x4,%edi
call   1030 <malloc@plt>
mov    %rax,(%rbx)
movl   $0x0,(%rax)
pop    %rbx
ret

LLVM IR (-O0):
define void @default_mutex_create(i8** %0) {
%2 = alloca i8**
store i8** %0, i8*** %2
%3 = call i8* @malloc(i32 4)
%4 = load i8**, i8*** %2
store i8* %3, i8** %4
%5 = load i8**, i8*** %2
%6 = load i8*, i8** %5
%7 = bitcast i8* %6 to i32*
store i32 0, i32* %7
ret void
}

LLVM IR (-O2):
define void @default_mutex_create(i8** nocapture writeonly %0) {
%2 = tail call dereferenceable_or_null(4) i8* @malloc(i32 4)
store i8* %2, i8** %0
%3 = bitcast i8* %2 to i32*
store i32 0, i32* %3
ret void
}
void create_empty_dir(const char dir[]) {
  make_dir(dir, 0700);
  do {
    seatest_assert_true(is_dir(dir), __FUNCTION__, 53);
  } while (0);
}


x86 assembly (clang, -O0):
<create_empty_dir>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
mov    $0x1c0,%esi
mov    $0x0,%al
call   1050 <make_dir@plt>
mov    -0x8(%rbp),%rdi
mov    $0x0,%al
call   1040 <is_dir@plt>
mov    %eax,%edi
lea    0xea0(%rip),%rsi
mov    $0x35,%edx
mov    $0x0,%al
call   1030 <seatest_assert_true@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<create_empty_dir>:
push   %rbx
mov    %rdi,%rbx
mov    $0x1c0,%esi
xor    %eax,%eax
call   1050 <make_dir@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <is_dir@plt>
lea    0xeaf(%rip),%rsi
mov    %eax,%edi
mov    $0x35,%edx
xor    %eax,%eax
pop    %rbx
jmp    1030 <seatest_assert_true@plt>

LLVM IR (-O0):
@__FUNCTION__.create_empty_dir = [17 x i8] c"create_empty_dir\00"
define void @create_empty_dir(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @make_dir to i32 (i8*, i32, ...)*)(i8* %3, i32 448)
br label %5
5: ; preds = %1
%6 = load i8*, i8** %2
%7 = call i32 (i8*, ...) bitcast (i32 (...)* @is_dir to i32 (i8*, ...)*)(i8* %6)
%8 = call i32 (i32, i8*, i32, ...) bitcast (i32 (...)* @seatest_assert_true to i32 (i32, i8*, i32, ...)*)(i32 %7, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @__FUNCTION__.create_empty_dir, i64 0, i64 0), i32 53)
br label %9
9: ; preds = %5
ret void
}

LLVM IR (-O2):
@__FUNCTION__.create_empty_dir = [17 x i8] c"create_empty_dir\00"
define void @create_empty_dir(i8* %0) {
%2 = tail call i32 (i8*, i32, ...) bitcast (i32 (...)* @make_dir to i32 (i8*, i32, ...)*)(i8* %0, i32 448)
%3 = tail call i32 (i8*, ...) bitcast (i32 (...)* @is_dir to i32 (i8*, ...)*)(i8* %0)
%4 = tail call i32 (i32, i8*, i32, ...) bitcast (i32 (...)* @seatest_assert_true to i32 (i32, i8*, i32, ...)*)(i32 %3, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @__FUNCTION__.create_empty_dir, i64 0, i64 0), i32 53)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ BASM_PP_AddIncludePathFront(char *);
int /*<<< orphan*/ printf(char *, char *);
void ccAddInclude(char *path) {
  int i;
  printf("Add include '%s'\n", path);
  BASM_PP_AddIncludePathFront(path);
}


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

x86 assembly (clang, -O2):
<ccAddInclude>:
push   %rbx
mov    %rdi,%rbx
lea    0xed5(%rip),%rdi
mov    %rbx,%rsi
call   1030 <printf@plt>
mov    %rbx,%rdi
pop    %rbx
jmp    1040 <BASM_PP_AddIncludePathFront@plt>

LLVM IR (-O0):
@.str = [18 x i8] c"Add include '%s'\0A\00"
define void @ccAddInclude(i8* %0) {
%2 = alloca i8*
%3 = alloca i32
store i8* %0, i8** %2
%4 = load i8*, i8** %2
%5 = call i32 @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0), i8* %4)
%6 = load i8*, i8** %2
%7 = call i32 @BASM_PP_AddIncludePathFront(i8* %6)
ret void
}

LLVM IR (-O2):
@.str = [18 x i8] c"Add include '%s'\0A\00"
define void @ccAddInclude(i8* %0) {
%2 = tail call i32 @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0), i8* %0)
%3 = tail call i32 @BASM_PP_AddIncludePathFront(i8* %0)
ret void
}
/* Variables and functions */
int strlen(const char *p) {
  const char *q = p;
  while (*p)
    p++;
  return p - q;
}


x86 assembly (clang, -O0):
<strlen>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x10(%rbp)
mov    -0x8(%rbp),%rax
cmpb   $0x0,(%rax)
je     112e <strlen+0x2e>
mov    -0x8(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x8(%rbp)
jmp    1110 <strlen+0x10>
mov    -0x8(%rbp),%rax
mov    -0x10(%rbp),%rcx
sub    %rcx,%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<strlen>:
mov    $0xffffffff,%eax
cs nopw 0x0(%rax,%rax,1)
nop
add    $0x1,%eax
cmpb   $0x0,(%rdi)
lea    0x1(%rdi),%rdi
jne    1110 <strlen+0x10>
ret

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

LLVM IR (-O2):
define i32 @strlen(i8* %0) {
br label %2
2: ; preds = %2, %1
%3 = phi i8* [ %0, %1 ], [ %6, %2 ]
%4 = load i8, i8* %3
%5 = icmp eq i8 %4, 0
%6 = getelementptr inbounds i8, i8* %3, i64 1
br i1 %5, label %7, label %2
7: ; preds = %2
%8 = ptrtoint i8* %3 to i64
%9 = ptrtoint i8* %0 to i64
%10 = sub i64 %8, %9
%11 = trunc i64 %10 to i32
ret i32 %11
}
void PinLock(unsigned long ulOutEnable) {
  if (((*((volatile unsigned long *)(0x00000400))) & 0xFFFF) >= 2) {
    (*((volatile unsigned long *)(0x4402E000 + 0x00000190))) = ~ulOutEnable;
    (*((volatile unsigned long *)(0x4402E000 + 0x0000016C))) |= (3 << 24);
  }
}


x86 assembly (clang, -O0):
<PinLock>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    $0x400,%eax
mov    (%rax),%rax
and    $0xffff,%rax
cmp    $0x2,%rax
jb     1147 <PinLock+0x47>
mov    -0x8(%rbp),%rcx
xor    $0xffffffffffffffff,%rcx
mov    $0x4402e190,%eax
mov    %rcx,(%rax)
mov    $0x4402e16c,%eax
mov    (%rax),%rcx
or     $0x3000000,%rcx
mov    $0x4402e16c,%eax
mov    %rcx,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<PinLock>:
testq  $0xfffe,0x400
je     1125 <PinLock+0x25>
not    %rdi
mov    %rdi,0x4402e190
44
orq    $0x3000000,0x4402e16c
ret

LLVM IR (-O0):
define void @PinLock(i64 %0) {
%2 = alloca i64
store i64 %0, i64* %2
%3 = load volatile i64, i64* inttoptr (i64 1024 to i64*)
%4 = and i64 %3, 65535
%5 = icmp uge i64 %4, 2
br i1 %5, label %6, label %11
6: ; preds = %1
%7 = load i64, i64* %2
%8 = xor i64 %7, -1
store volatile i64 %8, i64* inttoptr (i64 1141039504 to i64*)
%9 = load volatile i64, i64* inttoptr (i64 1141039468 to i64*)
%10 = or i64 %9, 50331648
store volatile i64 %10, i64* inttoptr (i64 1141039468 to i64*)
br label %11
11: ; preds = %6, %1
ret void
}

LLVM IR (-O2):
define void @PinLock(i64 %0) {
%2 = load volatile i64, i64* inttoptr (i64 1024 to i64*)
%3 = and i64 %2, 65534
%4 = icmp eq i64 %3, 0
br i1 %4, label %9, label %5
5: ; preds = %1
%6 = xor i64 %0, -1
store volatile i64 %6, i64* inttoptr (i64 1141039504 to i64*)
%7 = load volatile i64, i64* inttoptr (i64 1141039468 to i64*)
%8 = or i64 %7, 50331648
store volatile i64 %8, i64* inttoptr (i64 1141039468 to i64*)
br label %9
9: ; preds = %5, %1
ret void
}
int tolower(c)
int c;
{ return (isupper(c) ? (c ^ 0x20) : (c)); }


x86 assembly (clang, -O0):
<tolower>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%edi
call   1030 <isupper@plt>
cmp    $0x0,%eax
je     113a <tolower+0x2a>
mov    -0x4(%rbp),%eax
xor    $0x20,%eax
mov    %eax,-0x8(%rbp)
jmp    1140 <tolower+0x30>
mov    -0x4(%rbp),%eax
mov    %eax,-0x8(%rbp)
mov    -0x8(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<tolower>:
push   %rbx
mov    %edi,%ebx
call   1030 <isupper@plt>
mov    %ebx,%ecx
xor    $0x20,%ecx
test   %eax,%eax
cmove  %ebx,%ecx
mov    %ecx,%eax
pop    %rbx
ret

LLVM IR (-O0):
define i32 @tolower(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = call i32 @isupper(i32 %3)
%5 = icmp ne i32 %4, 0
br i1 %5, label %6, label %9
6: ; preds = %1
%7 = load i32, i32* %2
%8 = xor i32 %7, 32
br label %11
9: ; preds = %1
%10 = load i32, i32* %2
br label %11
11: ; preds = %9, %6
%12 = phi i32 [ %8, %6 ], [ %10, %9 ]
ret i32 %12
}

LLVM IR (-O2):
define i32 @tolower(i32 %0) {
%2 = tail call i32 @isupper(i32 %0)
%3 = icmp eq i32 %2, 0
%4 = xor i32 %0, 32
%5 = select i1 %3, i32 %0, i32 %4
ret i32 %5
}
/* Type definitions */
struct fid_fabric {
  int dummy;
};
struct fid {
  int dummy;
};

/* Variables and functions */
int gnix_fabric_trywait(struct fid_fabric *, struct fid **, int);
int fi_trywait(struct fid_fabric *fabric, struct fid **fids, int count) {
  return gnix_fabric_trywait(fabric, fids, count);
}


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

x86 assembly (clang, -O2):
<fi_trywait>:
jmp    1030 <gnix_fabric_trywait@plt>

LLVM IR (-O0):
%struct.fid_fabric = type { i32 }
%struct.fid = type { i32 }
define i32 @fi_trywait(%struct.fid_fabric* %0, %struct.fid** %1, i32 %2) {
%4 = alloca %struct.fid_fabric*
%5 = alloca %struct.fid**
%6 = alloca i32
store %struct.fid_fabric* %0, %struct.fid_fabric** %4
store %struct.fid** %1, %struct.fid*** %5
store i32 %2, i32* %6
%7 = load %struct.fid_fabric*, %struct.fid_fabric** %4
%8 = load %struct.fid**, %struct.fid*** %5
%9 = load i32, i32* %6
%10 = call i32 @gnix_fabric_trywait(%struct.fid_fabric* %7, %struct.fid** %8, i32 %9)
ret i32 %10
}

LLVM IR (-O2):
%struct.fid_fabric = type { i32 }
%struct.fid = type { i32 }
define i32 @fi_trywait(%struct.fid_fabric* %0, %struct.fid** %1, i32 %2) {
%4 = tail call i32 @gnix_fabric_trywait(%struct.fid_fabric* %0, %struct.fid** %1, i32 %2)
ret i32 %4
}
/* Variables and functions */
int /*<<< orphan*/ EX_USAGE;
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ fputs(char *, int /*<<< orphan*/);
int /*<<< orphan*/ stderr;
void emit_help(void) {
  fputs("Usage: getpof [-0] [-r] [-q] [-x] filename [dir ..]\n", stderr);
  exit(EX_USAGE);
}


x86 assembly (clang, -O0):
<emit_help>:
push   %rbp
mov    %rsp,%rbp
mov    0x2ead(%rip),%rax
mov    (%rax),%esi
lea    0xecc(%rip),%rdi
call   1030 <fputs@plt>
mov    0x2ea8(%rip),%rax
mov    (%rax),%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<emit_help>:
push   %rax
mov    0x2eb0(%rip),%rax
mov    (%rax),%esi
lea    0xecf(%rip),%rdi
call   1030 <fputs@plt>
mov    0x2eab(%rip),%rax
mov    (%rax),%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@.str = [53 x i8] c"Usage: getpof [-0] [-r] [-q] [-x] filename [dir ..]\0A\00"
@stderr = global i32 0
@EX_USAGE = global i32 0
define void @emit_help() {
%1 = load i32, i32* @stderr
%2 = call i32 @fputs(i8* getelementptr inbounds ([53 x i8], [53 x i8]* @.str, i64 0, i64 0), i32 %1)
%3 = load i32, i32* @EX_USAGE
%4 = call i32 @exit(i32 %3)
unreachable
}

LLVM IR (-O2):
@.str = [53 x i8] c"Usage: getpof [-0] [-r] [-q] [-x] filename [dir ..]\0A\00"
@stderr = global i32 0
@EX_USAGE = global i32 0
define void @emit_help() {
%1 = load i32, i32* @stderr
%2 = tail call i32 @fputs(i8* getelementptr inbounds ([53 x i8], [53 x i8]* @.str, i64 0, i64 0), i32 %1)
%3 = load i32, i32* @EX_USAGE
%4 = tail call i32 @exit(i32 %3)
unreachable
}
/* Variables and functions */
int /*<<< orphan*/ print_greetings_unpatched();
void local_print_greetings(void) { print_greetings_unpatched(); }


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

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

LLVM IR (-O0):
define void @local_print_greetings() {
%1 = call i32 (...) @print_greetings_unpatched()
ret void
}

LLVM IR (-O2):
define void @local_print_greetings() {
%1 = tail call i32 (...) @print_greetings_unpatched()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ adb_close(int);
int adb_connect(char const *);
scalar_t__ adb_status(int);
int adb_command(const char *service) {
  int fd = adb_connect(service);
  if (fd < 0) {
    return -1;
  }
  if (adb_status(fd)) {
    adb_close(fd);
    return -1;
  }
  return 0;
}


x86 assembly (clang, -O0):
<adb_command>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
call   1040 <adb_connect@plt>
mov    %eax,-0x14(%rbp)
cmpl   $0x0,-0x14(%rbp)
jge    115e <adb_command+0x2e>
movl   $0xffffffff,-0x4(%rbp)
jmp    118b <adb_command+0x5b>
mov    -0x14(%rbp),%edi
call   1030 <adb_status@plt>
cmp    $0x0,%rax
je     1184 <adb_command+0x54>
mov    -0x14(%rbp),%edi
call   1050 <adb_close@plt>
movl   $0xffffffff,-0x4(%rbp)
jmp    118b <adb_command+0x5b>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<adb_command>:
push   %rbp
push   %rbx
push   %rax
call   1040 <adb_connect@plt>
mov    $0xffffffff,%ebx
test   %eax,%eax
js     115a <adb_command+0x2a>
mov    %eax,%ebp
mov    %eax,%edi
call   1030 <adb_status@plt>
test   %rax,%rax
je     1158 <adb_command+0x28>
mov    %ebp,%edi
call   1050 <adb_close@plt>
jmp    115a <adb_command+0x2a>
xor    %ebx,%ebx
mov    %ebx,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

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

LLVM IR (-O2):
define i32 @adb_command(i8* %0) {
%2 = tail call i32 @adb_connect(i8* %0)
%3 = icmp slt i32 %2, 0
br i1 %3, label %9, label %4
4: ; preds = %1
%5 = tail call i64 @adb_status(i32 %2)
%6 = icmp eq i64 %5, 0
br i1 %6, label %9, label %7
7: ; preds = %4
%8 = tail call i32 @adb_close(i32 %2)
br label %9
9: ; preds = %4, %1, %7
%10 = phi i32 [ -1, %7 ], [ -1, %1 ], [ 0, %4 ]
ret i32 %10
}
/* Variables and functions */
int /*<<< orphan*/ __rcu_read_unlock();
void rcu_read_unlock(void) {
  do {
  } while (0);
  (void)0;
  __rcu_read_unlock();
}


x86 assembly (clang, -O0):
<rcu_read_unlock>:
push   %rbp
mov    %rsp,%rbp
jmp    1119 <rcu_read_unlock+0x9>
jmp    111e <rcu_read_unlock+0xe>
mov    $0x0,%al
call   1030 <__rcu_read_unlock@plt>
pop    %rbp
ret

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

LLVM IR (-O0):
define void @rcu_read_unlock() {
br label %1
1: ; preds = %0
br label %2
2: ; preds = %1
%3 = call i32 (...) @__rcu_read_unlock()
ret void
}

LLVM IR (-O2):
define void @rcu_read_unlock() {
%1 = tail call i32 (...) @__rcu_read_unlock()
ret void
}
int execute_ustat() { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @execute_ustat() {
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ strcmp(char const *, char const *);
int is_equal_key(const char *key1, const char *key2) {
  return !strcmp(key1, key2);
}


x86 assembly (clang, -O0):
<is_equal_key>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1030 <strcmp@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):
<is_equal_key>:
push   %rax
call   1030 <strcmp@plt>
xor    %ecx,%ecx
test   %eax,%eax
sete   %cl
mov    %ecx,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @is_equal_key(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
store i8* %0, i8** %3
store i8* %1, i8** %4
%5 = load i8*, i8** %3
%6 = load i8*, i8** %4
%7 = call i32 @strcmp(i8* %5, i8* %6)
%8 = icmp ne i32 %7, 0
%9 = xor i1 %8, true
%10 = zext i1 %9 to i32
ret i32 %10
}

LLVM IR (-O2):
define i32 @is_equal_key(i8* nocapture %0, i8* nocapture %1) {
%3 = tail call i32 @strcmp(i8* dereferenceable(1) %0, i8* dereferenceable(1) %1)
%4 = icmp eq i32 %3, 0
%5 = zext i1 %4 to i32
ret i32 %5
}
/* Type definitions */
struct usb_hcd {
  int dummy;
};
struct ft313_hcd {
  int dummy;
};

/* Variables and functions */
scalar_t__ ehci_is_TDI(struct ft313_hcd *);
struct ft313_hcd *hcd_to_ft313(struct usb_hcd *);
void ft313_relinquish_port(struct usb_hcd *hcd, int portnum) {
  struct ft313_hcd *ft313 = hcd_to_ft313(hcd);
  if (ehci_is_TDI(ft313))
    return;
}


x86 assembly (clang, -O0):
<ft313_relinquish_port>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0x8(%rbp),%rdi
call   1040 <hcd_to_ft313@plt>
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rdi
call   1030 <ehci_is_TDI@plt>
cmp    $0x0,%rax
je     1154 <ft313_relinquish_port+0x34>
jmp    1154 <ft313_relinquish_port+0x34>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ft313_relinquish_port>:
push   %rax
call   1040 <hcd_to_ft313@plt>
mov    %rax,%rdi
pop    %rax
jmp    1030 <ehci_is_TDI@plt>

LLVM IR (-O0):
%struct.usb_hcd = type { i32 }
%struct.ft313_hcd = type { i32 }
define void @ft313_relinquish_port(%struct.usb_hcd* %0, i32 %1) {
%3 = alloca %struct.usb_hcd*
%4 = alloca i32
%5 = alloca %struct.ft313_hcd*
store %struct.usb_hcd* %0, %struct.usb_hcd** %3
store i32 %1, i32* %4
%6 = load %struct.usb_hcd*, %struct.usb_hcd** %3
%7 = call %struct.ft313_hcd* @hcd_to_ft313(%struct.usb_hcd* %6)
store %struct.ft313_hcd* %7, %struct.ft313_hcd** %5
%8 = load %struct.ft313_hcd*, %struct.ft313_hcd** %5
%9 = call i64 @ehci_is_TDI(%struct.ft313_hcd* %8)
%10 = icmp ne i64 %9, 0
br i1 %10, label %11, label %12
11: ; preds = %2
br label %12
12: ; preds = %11, %2
ret void
}

LLVM IR (-O2):
%struct.usb_hcd = type { i32 }
%struct.ft313_hcd = type { i32 }
define void @ft313_relinquish_port(%struct.usb_hcd* %0, i32 %1) {
%3 = tail call %struct.ft313_hcd* @hcd_to_ft313(%struct.usb_hcd* %0)
%4 = tail call i64 @ehci_is_TDI(%struct.ft313_hcd* %3)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ assert(int *);
int *malloc(int);
int *identity(int *a) {
  int *ret = malloc(sizeof(int));
  assert(ret);
  *ret = *a;
  return ret;
}


x86 assembly (clang, -O0):
<identity>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    $0x4,%edi
call   1040 <malloc@plt>
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
call   1030 <assert@plt>
mov    -0x8(%rbp),%rax
mov    (%rax),%ecx
mov    -0x10(%rbp),%rax
mov    %ecx,(%rax)
mov    -0x10(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<identity>:
push   %r14
push   %rbx
push   %rax
mov    %rdi,%r14
mov    $0x4,%edi
call   1040 <malloc@plt>
mov    %rax,%rbx
mov    %rax,%rdi
call   1030 <assert@plt>
mov    (%r14),%eax
mov    %eax,(%rbx)
mov    %rbx,%rax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

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

LLVM IR (-O2):
define i32* @identity(i32* nocapture %0) {
%2 = tail call i32* @malloc(i32 4)
%3 = tail call i32 @assert(i32* %2)
%4 = load i32, i32* %0
store i32 %4, i32* %2
ret i32* %2
}
/* Type definitions */
typedef int uint8_t;
typedef int uint32_t;

/* Variables and functions */
void rtp_set_timestamp(uint8_t *p_rtp, uint32_t i_timestamp) {
  p_rtp[4] = (i_timestamp >> 24) & 0xff;
  p_rtp[5] = (i_timestamp >> 16) & 0xff;
  p_rtp[6] = (i_timestamp >> 8) & 0xff;
  p_rtp[7] = i_timestamp & 0xff;
}


x86 assembly (clang, -O0):
<rtp_set_timestamp>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0xc(%rbp),%ecx
sar    $0x18,%ecx
and    $0xff,%ecx
mov    -0x8(%rbp),%rax
mov    %ecx,0x10(%rax)
mov    -0xc(%rbp),%ecx
sar    $0x10,%ecx
and    $0xff,%ecx
mov    -0x8(%rbp),%rax
mov    %ecx,0x14(%rax)
mov    -0xc(%rbp),%ecx
sar    $0x8,%ecx
and    $0xff,%ecx
mov    -0x8(%rbp),%rax
mov    %ecx,0x18(%rax)
mov    -0xc(%rbp),%ecx
and    $0xff,%ecx
mov    -0x8(%rbp),%rax
mov    %ecx,0x1c(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<rtp_set_timestamp>:
mov    %esi,%eax
mov    %esi,%ecx
movzbl %ah,%edx
movzbl %al,%esi
shr    $0x18,%eax
mov    %eax,0x10(%rdi)
shr    $0x10,%ecx
movzbl %cl,%eax
mov    %eax,0x14(%rdi)
mov    %edx,0x18(%rdi)
mov    %esi,0x1c(%rdi)
ret

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

LLVM IR (-O2):
define void @rtp_set_timestamp(i32* nocapture writeonly %0, i32 %1) {
%3 = lshr i32 %1, 24
%4 = getelementptr inbounds i32, i32* %0, i64 4
store i32 %3, i32* %4
%5 = lshr i32 %1, 16
%6 = and i32 %5, 255
%7 = getelementptr inbounds i32, i32* %0, i64 5
store i32 %6, i32* %7
%8 = lshr i32 %1, 8
%9 = and i32 %8, 255
%10 = getelementptr inbounds i32, i32* %0, i64 6
store i32 %9, i32* %10
%11 = and i32 %1, 255
%12 = getelementptr inbounds i32, i32* %0, i64 7
store i32 %11, i32* %12
ret void
}
int check_data(void *vdata, void *vref) { return 1; }


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

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

LLVM IR (-O0):
define i32 @check_data(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
store i8* %0, i8** %3
store i8* %1, i8** %4
ret i32 1
}

LLVM IR (-O2):
define i32 @check_data(i8* nocapture readnone %0, i8* nocapture readnone %1) {
ret i32 1
}
/* Variables and functions */
int /*<<< orphan*/ SetMotorsAndTime(int /*<<< orphan*/, int /*<<< orphan*/, int,
                                    int);
int third(int seq) {
  SetMotorsAndTime(0, 0, 100, 50);
  return 1;
}


x86 assembly (clang, -O0):
<third>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
xor    %esi,%esi
mov    $0x64,%edx
mov    $0x32,%ecx
mov    %esi,%edi
call   1030 <SetMotorsAndTime@plt>
mov    $0x1,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<third>:
push   %rax
xor    %edi,%edi
xor    %esi,%esi
mov    $0x64,%edx
mov    $0x32,%ecx
call   1030 <SetMotorsAndTime@plt>
mov    $0x1,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @third(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = call i32 @SetMotorsAndTime(i32 0, i32 0, i32 100, i32 50)
ret i32 1
}

LLVM IR (-O2):
define i32 @third(i32 %0) {
%2 = tail call i32 @SetMotorsAndTime(i32 0, i32 0, i32 100, i32 50)
ret i32 1
}
unsigned short int f77(unsigned short int x, unsigned int y) {
  return (x << y) + (x >> ((-y) & (8 * sizeof(unsigned short) - 1)));
}


x86 assembly (clang, -O0):
<f77>:
push   %rbp
mov    %rsp,%rbp
mov    %di,%ax
mov    %ax,-0x2(%rbp)
mov    %esi,-0x8(%rbp)
movzwl -0x2(%rbp),%eax
mov    -0x8(%rbp),%ecx
shl    %cl,%eax
movzwl -0x2(%rbp),%edx
xor    %ecx,%ecx
sub    -0x8(%rbp),%ecx
mov    %ecx,%ecx
and    $0xf,%rcx
sar    %cl,%edx
mov    %edx,%ecx
add    %ecx,%eax
movzwl %ax,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<f77>:
mov    %esi,%ecx
mov    %edi,%eax
shl    %cl,%eax
neg    %cl
and    $0xf,%cl
shr    %cl,%edi
add    %edi,%eax
ret

LLVM IR (-O0):
define zeroext i16 @f77(i16 zeroext %0, i32 %1) {
%3 = alloca i16
%4 = alloca i32
store i16 %0, i16* %3
store i32 %1, i32* %4
%5 = load i16, i16* %3
%6 = zext i16 %5 to i32
%7 = load i32, i32* %4
%8 = shl i32 %6, %7
%9 = load i16, i16* %3
%10 = zext i16 %9 to i32
%11 = load i32, i32* %4
%12 = sub i32 0, %11
%13 = zext i32 %12 to i64
%14 = and i64 %13, 15
%15 = trunc i64 %14 to i32
%16 = ashr i32 %10, %15
%17 = add nsw i32 %8, %16
%18 = trunc i32 %17 to i16
ret i16 %18
}

LLVM IR (-O2):
define zeroext i16 @f77(i16 zeroext %0, i32 %1) {
%3 = zext i16 %0 to i32
%4 = shl i32 %3, %1
%5 = sub i32 0, %1
%6 = and i32 %5, 15
%7 = lshr i32 %3, %6
%8 = add nsw i32 %7, %4
%9 = trunc i32 %8 to i16
ret i16 %9
}
/* Variables and functions */
int pow(int, int);
int /*<<< orphan*/ printf(char *, int);
int main() {
  int result1, result2, result3, result4, result5, result;
  result1 = pow(1, 2);
  result2 = pow(2, 3);
  result3 = pow(3, 4);
  result4 = pow(5, 6);
  result = result1 + result2 + result3 + result4;
  printf("最后结果是:%d \n", result);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0x1,%edi
mov    $0x2,%esi
call   1040 <pow@plt>
mov    %eax,-0x8(%rbp)
mov    $0x2,%edi
mov    $0x3,%esi
call   1040 <pow@plt>
mov    %eax,-0xc(%rbp)
mov    $0x3,%edi
mov    $0x4,%esi
call   1040 <pow@plt>
mov    %eax,-0x10(%rbp)
mov    $0x5,%edi
mov    $0x6,%esi
call   1040 <pow@plt>
mov    %eax,-0x14(%rbp)
mov    -0x8(%rbp),%eax
add    -0xc(%rbp),%eax
add    -0x10(%rbp),%eax
add    -0x14(%rbp),%eax
mov    %eax,-0x1c(%rbp)
mov    -0x1c(%rbp),%esi
lea    0xe70(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r14
push   %rbx
mov    $0x1,%edi
mov    $0x2,%esi
call   1040 <pow@plt>
mov    %eax,%r14d
mov    $0x2,%edi
mov    $0x3,%esi
call   1040 <pow@plt>
mov    %eax,%ebp
mov    $0x3,%edi
mov    $0x4,%esi
call   1040 <pow@plt>
mov    %eax,%ebx
mov    $0x5,%edi
mov    $0x6,%esi
call   1040 <pow@plt>
add    %r14d,%ebp
add    %ebx,%ebp
add    %eax,%ebp
lea    0xe8b(%rip),%rdi
mov    %ebp,%esi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rbx
pop    %r14
pop    %rbp
ret

LLVM IR (-O0):
@.str = [21 x i8] c"\E6\9C\80\E5\90\8E\E7\BB\93\E6\9E\9C\E6\98\AF:%d \0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
store i32 0, i32* %1
%8 = call i32 @pow(i32 1, i32 2)
store i32 %8, i32* %2
%9 = call i32 @pow(i32 2, i32 3)
store i32 %9, i32* %3
%10 = call i32 @pow(i32 3, i32 4)
store i32 %10, i32* %4
%11 = call i32 @pow(i32 5, i32 6)
store i32 %11, i32* %5
%12 = load i32, i32* %2
%13 = load i32, i32* %3
%14 = add nsw i32 %12, %13
%15 = load i32, i32* %4
%16 = add nsw i32 %14, %15
%17 = load i32, i32* %5
%18 = add nsw i32 %16, %17
store i32 %18, i32* %7
%19 = load i32, i32* %7
%20 = call i32 @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0), i32 %19)
ret i32 0
}

LLVM IR (-O2):
@.str = [21 x i8] c"\E6\9C\80\E5\90\8E\E7\BB\93\E6\9E\9C\E6\98\AF:%d \0A\00"
define i32 @main() {
%1 = tail call i32 @pow(i32 1, i32 2)
%2 = tail call i32 @pow(i32 2, i32 3)
%3 = tail call i32 @pow(i32 3, i32 4)
%4 = tail call i32 @pow(i32 5, i32 6)
%5 = add nsw i32 %2, %1
%6 = add nsw i32 %5, %3
%7 = add nsw i32 %6, %4
%8 = tail call i32 @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0), i32 %7)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ syscall_write(int, char *, int);
void write_char(char c) { syscall_write(1, &c, 1); }


x86 assembly (clang, -O0):
<write_char>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %dil,%al
mov    %al,-0x1(%rbp)
mov    $0x1,%edx
lea    -0x1(%rbp),%rsi
mov    %edx,%edi
call   1030 <syscall_write@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<write_char>:
push   %rax
mov    %dil,0x7(%rsp)
lea    0x7(%rsp),%rsi
mov    $0x1,%edi
mov    $0x1,%edx
call   1030 <syscall_write@plt>
pop    %rax
ret

LLVM IR (-O0):
define void @write_char(i8 signext %0) {
%2 = alloca i8
store i8 %0, i8* %2
%3 = call i32 @syscall_write(i32 1, i8* %2, i32 1)
ret void
}

LLVM IR (-O2):
define void @write_char(i8 signext %0) {
%2 = alloca i8
store i8 %0, i8* %2
%3 = call i32 @syscall_write(i32 1, i8* %2, i32 1)
ret void
}