xunge/DecIR huggingface dataset:
int isWS(char c) {
  if (c == ' ' || c == '\n' || c == '\t' || c == '\r')
    return 1;
  else
    return 0;
}


x86 assembly (clang, -O0):
<isWS>:
push   %rbp
mov    %rsp,%rbp
mov    %dil,%al
mov    %al,-0x5(%rbp)
movsbl -0x5(%rbp),%eax
cmp    $0x20,%eax
je     113e <isWS+0x3e>
movsbl -0x5(%rbp),%eax
cmp    $0xa,%eax
je     113e <isWS+0x3e>
movsbl -0x5(%rbp),%eax
cmp    $0x9,%eax
je     113e <isWS+0x3e>
movsbl -0x5(%rbp),%eax
cmp    $0xd,%eax
jne    114a <isWS+0x4a>
movl   $0x1,-0x4(%rbp)
jmp    1151 <isWS+0x51>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

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

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

LLVM IR (-O2):
define i32 @isWS(i8 signext %0) {
switch i8 %0, label %2 [
i8 32, label %3
i8 13, label %3
i8 10, label %3
i8 9, label %3
]
2: ; preds = %1
br label %3
3: ; preds = %1, %1, %1, %1, %2
%4 = phi i32 [ 0, %2 ], [ 1, %1 ], [ 1, %1 ], [ 1, %1 ], [ 1, %1 ]
ret i32 %4
}
void batadv_nc_skb_store_sniffed_unicast(struct batadv_priv *bat_priv,
                                         struct sk_buff *skb) {
  return;
}


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

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

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

LLVM IR (-O2):
%struct.batadv_priv = type opaque
%struct.sk_buff = type opaque
define void @batadv_nc_skb_store_sniffed_unicast(%struct.batadv_priv* nocapture %0, %struct.sk_buff* nocapture %1) {
ret void
}
/* Variables and functions */
void *really_do_leak(size_t);
void *do_leak(size_t sz) { return really_do_leak(sz); }


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

x86 assembly (clang, -O2):
<do_leak>:
jmp    1030 <really_do_leak@plt>

LLVM IR (-O0):
define i8* @do_leak(i64 %0) {
%2 = alloca i64
store i64 %0, i64* %2
%3 = load i64, i64* %2
%4 = call i8* @really_do_leak(i64 %3)
ret i8* %4
}

LLVM IR (-O2):
define i8* @do_leak(i64 %0) {
%2 = tail call i8* @really_do_leak(i64 %0)
ret i8* %2
}
int do_067() { return 67; }


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

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

LLVM IR (-O0):
define i32 @do_067() {
ret i32 67
}

LLVM IR (-O2):
define i32 @do_067() {
ret i32 67
}
/* Variables and functions */
int /*<<< orphan*/ C67_asm(char *, int, int, int);
void C67_SUBSP(int r, int v) { C67_asm("SUBSP.L", v, r, v); }


x86 assembly (clang, -O0):
<C67_SUBSP>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x8(%rbp),%esi
mov    -0x4(%rbp),%edx
mov    -0x8(%rbp),%ecx
lea    0xed2(%rip),%rdi
call   1030 <C67_asm@plt>
add    $0x10,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
@.str = [8 x i8] c"SUBSP.L\00"
define void @C67_SUBSP(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 = load i32, i32* %3
%7 = load i32, i32* %4
%8 = call i32 @C67_asm(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i32 %5, i32 %6, i32 %7)
ret void
}

LLVM IR (-O2):
@.str = [8 x i8] c"SUBSP.L\00"
define void @C67_SUBSP(i32 %0, i32 %1) {
%3 = tail call i32 @C67_asm(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i32 %1, i32 %0, i32 %1)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ func3();
int /*<<< orphan*/ printf(char *);
int main(int argc, char *argv[]) {
  printf("Hello from subdir2/subdir3/prog3.c\n");
  func3();
  return 0;
}


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

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

LLVM IR (-O0):
@.str = [36 x i8] c"Hello from subdir2/subdir3/prog3.c\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%6 = call i32 @printf(i8* getelementptr inbounds ([36 x i8], [36 x i8]* @.str, i64 0, i64 0))
%7 = call i32 (...) @func3()
ret i32 0
}

LLVM IR (-O2):
@str = [35 x i8] c"Hello from subdir2/subdir3/prog3.c\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([35 x i8], [35 x i8]* @str, i64 0, i64 0))
%4 = tail call i32 (...) @func3()
ret i32 0
}
const char *ZSTD_versionString(void) { return "1.4.9"; }


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

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

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

LLVM IR (-O2):
@.str = [6 x i8] c"1.4.9\00"
define i8* @ZSTD_versionString() {
ret i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0)
}
/* Variables and functions */
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ printf(char *, char *);
void _Q_fge(void) {
  printf("Unimplemented %s called, exiting\n", "_Q_fge");
  exit(-1);
}


x86 assembly (clang, -O0):
<_Q_fge>:
push   %rbp
mov    %rsp,%rbp
lea    0xed5(%rip),%rdi
lea    0xef0(%rip),%rsi
call   1030 <printf@plt>
mov    $0xffffffff,%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<_Q_fge>:
push   %rax
lea    0xed8(%rip),%rdi
lea    0xef3(%rip),%rsi
call   1030 <printf@plt>
mov    $0xffffffff,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@.str = [34 x i8] c"Unimplemented %s called, exiting\0A\00"
@.str.1 = [7 x i8] c"_Q_fge\00"
define void @_Q_fge() {
%1 = call i32 @printf(i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0))
%2 = call i32 @exit(i32 -1)
unreachable
}

LLVM IR (-O2):
@.str = [34 x i8] c"Unimplemented %s called, exiting\0A\00"
@.str.1 = [7 x i8] c"_Q_fge\00"
define void @_Q_fge() {
%1 = tail call i32 @printf(i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0))
%2 = tail call i32 @exit(i32 -1)
unreachable
}
/* Variables and functions */
int /*<<< orphan*/ TDETraderParse_initFlex(char const *);
int /*<<< orphan*/ kiotraderparse();
void TDETraderParse_mainParse(const char *_code) {
  TDETraderParse_initFlex(_code);
  kiotraderparse();
}


x86 assembly (clang, -O0):
<TDETraderParse_mainParse>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <TDETraderParse_initFlex@plt>
mov    $0x0,%al
call   1040 <kiotraderparse@plt>
add    $0x10,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
define void @TDETraderParse_mainParse(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = call i32 @TDETraderParse_initFlex(i8* %3)
%5 = call i32 (...) @kiotraderparse()
ret void
}

LLVM IR (-O2):
define void @TDETraderParse_mainParse(i8* %0) {
%2 = tail call i32 @TDETraderParse_initFlex(i8* %0)
%3 = tail call i32 (...) @kiotraderparse()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *);
int /*<<< orphan*/ stderr;
void usage(char *s) {
  fprintf(stderr, "usage: gf_example_2 w - w must be between 1 and 32\n");
  exit(1);
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    0x2ead(%rip),%rax
mov    (%rax),%edi
lea    0xec4(%rip),%rsi
call   1030 <fprintf@plt>
mov    $0x1,%edi
call   1040 <exit@plt>

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

LLVM IR (-O0):
@stderr = global i32 0
@.str = [52 x i8] c"usage: gf_example_2 w - w must be between 1 and 32\0A\00"
define void @usage(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i32, i32* @stderr
%4 = call i32 @fprintf(i32 %3, i8* getelementptr inbounds ([52 x i8], [52 x i8]* @.str, i64 0, i64 0))
%5 = call i32 @exit(i32 1)
unreachable
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [52 x i8] c"usage: gf_example_2 w - w must be between 1 and 32\0A\00"
define void @usage(i8* nocapture readnone %0) {
%2 = load i32, i32* @stderr
%3 = tail call i32 @fprintf(i32 %2, i8* getelementptr inbounds ([52 x i8], [52 x i8]* @.str, i64 0, i64 0))
%4 = tail call i32 @exit(i32 1)
unreachable
}
/* Variables and functions */
int /*<<< orphan*/ ol(char *);
dec() { ol("DCX H"); }


x86 assembly (clang, -O0):
<dec>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
lea    0xee1(%rip),%rdi
call   1030 <ol@plt>
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<dec>:
lea    0xee9(%rip),%rdi
jmp    1030 <ol@plt>

LLVM IR (-O0):
@.str = [6 x i8] c"DCX H\00"
define i32 @dec() {
%1 = alloca i32
%2 = call i32 @ol(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
%3 = load i32, i32* %1
ret i32 %3
}

LLVM IR (-O2):
@.str = [6 x i8] c"DCX H\00"
define i32 @dec() {
%1 = tail call i32 @ol(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
ret i32 undef
}
/* Type definitions */
typedef int /*<<< orphan*/ int32_t;

/* Variables and functions */
int /*<<< orphan*/ UP3D_GetParameter(int);
int32_t UP3D_GetTimeRemaining() { return UP3D_GetParameter(0x4D); }


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

x86 assembly (clang, -O2):
<UP3D_GetTimeRemaining>:
mov    $0x4d,%edi
jmp    1030 <UP3D_GetParameter@plt>

LLVM IR (-O0):
define i32 @UP3D_GetTimeRemaining() {
%1 = call i32 @UP3D_GetParameter(i32 77)
ret i32 %1
}

LLVM IR (-O2):
define i32 @UP3D_GetTimeRemaining() {
%1 = tail call i32 @UP3D_GetParameter(i32 77)
ret i32 %1
}
int sum(int x, int y) {
  int z;
  z = x * y;
  return z;
}


x86 assembly (clang, -O0):
<sum>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x4(%rbp),%eax
imul   -0x8(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<sum>:
mov    %edi,%eax
imul   %esi,%eax
ret

LLVM IR (-O0):
define i32 @sum(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store i32 %0, i32* %3
store i32 %1, i32* %4
%6 = load i32, i32* %3
%7 = load i32, i32* %4
%8 = mul nsw i32 %6, %7
store i32 %8, i32* %5
%9 = load i32, i32* %5
ret i32 %9
}

LLVM IR (-O2):
define i32 @sum(i32 %0, i32 %1) {
%3 = mul nsw i32 %1, %0
ret i32 %3
}
double kappa(double Mu, double Pr, double R, double gamma) {
  return -Mu * R * gamma / (Pr * (1 - gamma));
}


x86 assembly (clang, -O0):
<kappa>:
push   %rbp
mov    %rsp,%rbp
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
movsd  %xmm2,-0x18(%rbp)
movsd  %xmm3,-0x20(%rbp)
movsd  -0x8(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  -0x18(%rbp),%xmm0
mulsd  -0x20(%rbp),%xmm0
movsd  -0x10(%rbp),%xmm1
movsd  0xeb5(%rip),%xmm2
subsd  -0x20(%rbp),%xmm2
mulsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<kappa>:
xorpd  0xef8(%rip),%xmm0
mulsd  %xmm2,%xmm0
mulsd  %xmm3,%xmm0
movsd  0xef8(%rip),%xmm2
subsd  %xmm3,%xmm2
mulsd  %xmm1,%xmm2
divsd  %xmm2,%xmm0
ret

LLVM IR (-O0):
define double @kappa(double %0, double %1, double %2, double %3) {
%5 = alloca double
%6 = alloca double
%7 = alloca double
%8 = alloca double
store double %0, double* %5
store double %1, double* %6
store double %2, double* %7
store double %3, double* %8
%9 = load double, double* %5
%10 = fneg double %9
%11 = load double, double* %7
%12 = fmul double %10, %11
%13 = load double, double* %8
%14 = fmul double %12, %13
%15 = load double, double* %6
%16 = load double, double* %8
%17 = fsub double 1.000000e+00, %16
%18 = fmul double %15, %17
%19 = fdiv double %14, %18
ret double %19
}

LLVM IR (-O2):
define double @kappa(double %0, double %1, double %2, double %3) {
%5 = fneg double %0
%6 = fmul double %5, %2
%7 = fmul double %6, %3
%8 = fsub double 1.000000e+00, %3
%9 = fmul double %8, %1
%10 = fdiv double %7, %9
ret double %10
}
/* Variables and functions */
void *allocate(size_t);
int /*<<< orphan*/ memcpy(void *, void const *, size_t);
void *copy_array_impl(void const *from, size_t size_in_bytes) {
  void *result = allocate(size_in_bytes);
  memcpy(result, from, size_in_bytes);
  return result;
}


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

x86 assembly (clang, -O2):
<copy_array_impl>:
push   %r15
push   %r14
push   %rbx
mov    %rsi,%r15
mov    %rdi,%r14
mov    %rsi,%rdi
call   1040 <allocate@plt>
mov    %rax,%rbx
mov    %rax,%rdi
mov    %r14,%rsi
mov    %r15,%rdx
call   1030 <memcpy@plt>
mov    %rbx,%rax
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
define i8* @copy_array_impl(i8* %0, i64 %1) {
%3 = alloca i8*
%4 = alloca i64
%5 = alloca i8*
store i8* %0, i8** %3
store i64 %1, i64* %4
%6 = load i64, i64* %4
%7 = call i8* @allocate(i64 %6)
store i8* %7, i8** %5
%8 = load i8*, i8** %5
%9 = load i8*, i8** %3
%10 = load i64, i64* %4
%11 = call i32 @memcpy(i8* %8, i8* %9, i64 %10)
%12 = load i8*, i8** %5
ret i8* %12
}

LLVM IR (-O2):
define i8* @copy_array_impl(i8* %0, i64 %1) {
%3 = tail call i8* @allocate(i64 %1)
%4 = tail call i32 @memcpy(i8* %3, i8* %0, i64 %1)
ret i8* %3
}
void neg_s(float *source, float *target) { *target = -(*source); }


x86 assembly (clang, -O0):
<neg_s>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
movss  (%rax),%xmm0
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mov    -0x10(%rbp),%rax
movss  %xmm0,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<neg_s>:
movss  (%rdi),%xmm0
xorps  0xef5(%rip),%xmm0
movss  %xmm0,(%rsi)
ret

LLVM IR (-O0):
define void @neg_s(float* %0, float* %1) {
%3 = alloca float*
%4 = alloca float*
store float* %0, float** %3
store float* %1, float** %4
%5 = load float*, float** %3
%6 = load float, float* %5
%7 = fneg float %6
%8 = load float*, float** %4
store float %7, float* %8
ret void
}

LLVM IR (-O2):
define void @neg_s(float* nocapture %0, float* nocapture writeonly %1) {
%3 = load float, float* %0
%4 = fneg float %3
store float %4, float* %1
ret void
}
/* Variables and functions */
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, char *);
int /*<<< orphan*/ stderr;
void Abort(char msg[]) {
  fprintf(stderr, "%s\n", msg);
  exit(0);
}


x86 assembly (clang, -O0):
<Abort>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    0x2ead(%rip),%rax
mov    (%rax),%edi
mov    -0x8(%rbp),%rdx
lea    0xec0(%rip),%rsi
call   1030 <fprintf@plt>
xor    %edi,%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<Abort>:
push   %rax
mov    %rdi,%rdx
mov    0x2eb5(%rip),%rax
mov    (%rax),%edi
lea    0xecc(%rip),%rsi
call   1030 <fprintf@plt>
xor    %edi,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [4 x i8] c"%s\0A\00"
define void @Abort(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i32, i32* @stderr
%4 = load i8*, i8** %2
%5 = call i32 @fprintf(i32 %3, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* %4)
%6 = call i32 @exit(i32 0)
unreachable
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [4 x i8] c"%s\0A\00"
define void @Abort(i8* %0) {
%2 = load i32, i32* @stderr
%3 = tail call i32 @fprintf(i32 %2, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* %0)
%4 = tail call i32 @exit(i32 0)
unreachable
}
/* Variables and functions */
int /*<<< orphan*/ styledOutput(char *, char *);
void outerr(char *tmp) { styledOutput("err", tmp); }


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

x86 assembly (clang, -O2):
<outerr>:
mov    %rdi,%rsi
lea    0xee6(%rip),%rdi
jmp    1030 <styledOutput@plt>

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

LLVM IR (-O2):
@.str = [4 x i8] c"err\00"
define void @outerr(i8* %0) {
%2 = tail call i32 @styledOutput(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* %0)
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ int64_t;

/* Variables and functions */
int64_t x(int64_t x) { return x; }


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

x86 assembly (clang, -O2):
<x>:
mov    %edi,%eax
ret

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

LLVM IR (-O2):
define i32 @x(i32 returned %0) {
ret i32 %0
}
/* Type definitions */
typedef unsigned long volatile uint32_t;

/* Variables and functions */
uint32_t GPIO_getEventMultiDio(uint32_t dioMask) {
  ;
  return ((*((volatile unsigned long *)(0x40022000 + 0x000000E0))) & dioMask);
}


x86 assembly (clang, -O0):
<GPIO_getEventMultiDio>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    $0x400220e0,%eax
mov    (%rax),%rax
mov    -0x8(%rbp),%rcx
and    %rcx,%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<GPIO_getEventMultiDio>:
mov    %rdi,-0x8(%rsp)
mov    0x400220e0,%rax
40
and    -0x8(%rsp),%rax
ret

LLVM IR (-O0):
define i64 @GPIO_getEventMultiDio(i64 %0) {
%2 = alloca i64
store volatile i64 %0, i64* %2
%3 = load volatile i64, i64* inttoptr (i64 1073881312 to i64*)
%4 = load volatile i64, i64* %2
%5 = and i64 %3, %4
ret i64 %5
}

LLVM IR (-O2):
define i64 @GPIO_getEventMultiDio(i64 %0) {
%2 = alloca i64
store volatile i64 %0, i64* %2
%3 = load volatile i64, i64* inttoptr (i64 1073881312 to i64*)
%4 = load volatile i64, i64* %2
%5 = and i64 %4, %3
ret i64 %5
}
/* Type definitions */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
int /*<<< orphan*/ putc(int, int /*<<< orphan*/ *);
void putint(int n, FILE *fp) {
  putc(n >> 8, fp);
  putc(n & 0377, fp);
}


x86 assembly (clang, -O0):
<putint>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x4(%rbp),%edi
sar    $0x8,%edi
mov    -0x10(%rbp),%rsi
call   1030 <putc@plt>
mov    -0x4(%rbp),%edi
and    $0xff,%edi
mov    -0x10(%rbp),%rsi
call   1030 <putc@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<putint>:
push   %rbp
push   %rbx
push   %rax
mov    %rsi,%rbx
mov    %edi,%ebp
sar    $0x8,%edi
call   1030 <putc@plt>
movzbl %bpl,%edi
mov    %rbx,%rsi
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1030 <putc@plt>

LLVM IR (-O0):
define void @putint(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 = ashr i32 %5, 8
%7 = load i32*, i32** %4
%8 = call i32 @putc(i32 %6, i32* %7)
%9 = load i32, i32* %3
%10 = and i32 %9, 255
%11 = load i32*, i32** %4
%12 = call i32 @putc(i32 %10, i32* %11)
ret void
}

LLVM IR (-O2):
define void @putint(i32 %0, i32* nocapture %1) {
%3 = ashr i32 %0, 8
%4 = tail call i32 @putc(i32 %3, i32* %1)
%5 = and i32 %0, 255
%6 = tail call i32 @putc(i32 %5, i32* %1)
ret void
}
/* Type definitions */
typedef int uint32_t;

/* Variables and functions */
int /*<<< orphan*/ ASSERT(int);
void ADCSequenceEnable(uint32_t ui32Base, uint32_t ui32SequenceNum) {
  ASSERT((ui32Base == 0x40038000) || (ui32Base == 0x40039000));
  ASSERT(ui32SequenceNum < 4);
  (*((volatile uint32_t *)(ui32Base + 0x00000000))) |= 1 << ui32SequenceNum;
}


x86 assembly (clang, -O0):
<ADCSequenceEnable>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    $0x1,%al
cmpl   $0x40038000,-0x4(%rbp)
mov    %al,-0x9(%rbp)
je     113d <ADCSequenceEnable+0x2d>
cmpl   $0x40039000,-0x4(%rbp)
sete   %al
mov    %al,-0x9(%rbp)
mov    -0x9(%rbp),%al
and    $0x1,%al
movzbl %al,%edi
call   1030 <ASSERT@plt>
cmpl   $0x4,-0x8(%rbp)
setl   %al
and    $0x1,%al
movzbl %al,%edi
call   1030 <ASSERT@plt>
mov    -0x8(%rbp),%ecx
mov    $0x1,%edx
shl    %cl,%edx
mov    -0x4(%rbp),%eax
add    $0x0,%eax
cltq
mov    (%rax),%ecx
or     %edx,%ecx
mov    %ecx,(%rax)
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ADCSequenceEnable>:
push   %rbp
push   %rbx
push   %rax
mov    %esi,%ebx
mov    %edi,%ebp
mov    %edi,%eax
and    $0xffffefff,%eax
xor    %edi,%edi
cmp    $0x40038000,%eax
sete   %dil
call   1030 <ASSERT@plt>
xor    %edi,%edi
cmp    $0x4,%ebx
setl   %dil
call   1030 <ASSERT@plt>
mov    $0x1,%eax
mov    %ebx,%ecx
shl    %cl,%eax
movslq %ebp,%rcx
or     %eax,(%rcx)
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
define void @ADCSequenceEnable(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 = icmp eq i32 %5, 1073971200
br i1 %6, label %10, label %7
7: ; preds = %2
%8 = load i32, i32* %3
%9 = icmp eq i32 %8, 1073975296
br label %10
10: ; preds = %7, %2
%11 = phi i1 [ true, %2 ], [ %9, %7 ]
%12 = zext i1 %11 to i32
%13 = call i32 @ASSERT(i32 %12)
%14 = load i32, i32* %4
%15 = icmp slt i32 %14, 4
%16 = zext i1 %15 to i32
%17 = call i32 @ASSERT(i32 %16)
%18 = load i32, i32* %4
%19 = shl i32 1, %18
%20 = load i32, i32* %3
%21 = add nsw i32 %20, 0
%22 = sext i32 %21 to i64
%23 = inttoptr i64 %22 to i32*
%24 = load volatile i32, i32* %23
%25 = or i32 %24, %19
store volatile i32 %25, i32* %23
ret void
}

LLVM IR (-O2):
define void @ADCSequenceEnable(i32 %0, i32 %1) {
%3 = and i32 %0, -4097
%4 = icmp eq i32 %3, 1073971200
%5 = zext i1 %4 to i32
%6 = tail call i32 @ASSERT(i32 %5)
%7 = icmp slt i32 %1, 4
%8 = zext i1 %7 to i32
%9 = tail call i32 @ASSERT(i32 %8)
%10 = shl nuw i32 1, %1
%11 = sext i32 %0 to i64
%12 = inttoptr i64 %11 to i32*
%13 = load volatile i32, i32* %12
%14 = or i32 %13, %10
store volatile i32 %14, i32* %12
ret void
}
/* Type definitions */
struct sockaddr {
  int dummy;
};
struct ifreq {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ SIOCGIFBRDADDR;
struct sockaddr *if_addr_value(char const *, struct ifreq *,
                               int /*<<< orphan*/);
struct sockaddr *if_bcast(const char *iface, struct ifreq *r) {
  return if_addr_value(iface, r, SIOCGIFBRDADDR);
}


x86 assembly (clang, -O0):
<if_bcast>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
mov    0x2eb1(%rip),%rax
mov    (%rax),%edx
call   1030 <if_addr_value@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<if_bcast>:
mov    0x2ec9(%rip),%rax
mov    (%rax),%edx
jmp    1030 <if_addr_value@plt>

LLVM IR (-O0):
%struct.sockaddr = type { i32 }
%struct.ifreq = type { i32 }
@SIOCGIFBRDADDR = global i32 0
define %struct.sockaddr* @if_bcast(i8* %0, %struct.ifreq* %1) {
%3 = alloca i8*
%4 = alloca %struct.ifreq*
store i8* %0, i8** %3
store %struct.ifreq* %1, %struct.ifreq** %4
%5 = load i8*, i8** %3
%6 = load %struct.ifreq*, %struct.ifreq** %4
%7 = load i32, i32* @SIOCGIFBRDADDR
%8 = call %struct.sockaddr* @if_addr_value(i8* %5, %struct.ifreq* %6, i32 %7)
ret %struct.sockaddr* %8
}

LLVM IR (-O2):
%struct.sockaddr = type { i32 }
%struct.ifreq = type { i32 }
@SIOCGIFBRDADDR = global i32 0
define %struct.sockaddr* @if_bcast(i8* %0, %struct.ifreq* %1) {
%3 = load i32, i32* @SIOCGIFBRDADDR
%4 = tail call %struct.sockaddr* @if_addr_value(i8* %0, %struct.ifreq* %1, i32 %3)
ret %struct.sockaddr* %4
}
/* Variables and functions */
int mk_wcwidth(unsigned int);
int fl_wcwidth(unsigned int ucs) { return mk_wcwidth(ucs); }


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

x86 assembly (clang, -O2):
<fl_wcwidth>:
jmp    1030 <mk_wcwidth@plt>

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

LLVM IR (-O2):
define i32 @fl_wcwidth(i32 %0) {
%2 = tail call i32 @mk_wcwidth(i32 %0)
ret i32 %2
}
/* Variables and functions */
int /*<<< orphan*/ compute(int);
int example_set_var3(int *array, int array_size) {
  compute(10);
  return 0;
}


x86 assembly (clang, -O0):
<example_set_var3>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    $0xa,%edi
call   1030 <compute@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<example_set_var3>:
push   %rax
mov    $0xa,%edi
call   1030 <compute@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @example_set_var3(i32* %0, i32 %1) {
%3 = alloca i32*
%4 = alloca i32
store i32* %0, i32** %3
store i32 %1, i32* %4
%5 = call i32 @compute(i32 10)
ret i32 0
}

LLVM IR (-O2):
define i32 @example_set_var3(i32* nocapture readnone %0, i32 %1) {
%3 = tail call i32 @compute(i32 10)
ret i32 0
}
/* Type definitions */
typedef scalar_t__ uint;

/* Variables and functions */
int neq(uint x, uint y) { return x != y; }


x86 assembly (clang, -O0):
<neq>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
cmp    -0x10(%rbp),%rax
setne  %al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<neq>:
xor    %eax,%eax
cmp    %rsi,%rdi
setne  %al
ret

LLVM IR (-O0):
define i32 @neq(i64 %0, i64 %1) {
%3 = alloca i64
%4 = alloca i64
store i64 %0, i64* %3
store i64 %1, i64* %4
%5 = load i64, i64* %3
%6 = load i64, i64* %4
%7 = icmp ne i64 %5, %6
%8 = zext i1 %7 to i32
ret i32 %8
}

LLVM IR (-O2):
define i32 @neq(i64 %0, i64 %1) {
%3 = icmp ne i64 %0, %1
%4 = zext i1 %3 to i32
ret i32 %4
}
char *hash_plugin_detailed(void) {
  return ("pwsafe - Password Safe passphrase plugin\n"
          "------------------------------------------------\n"
          "Use this module to crack Password Safe pwsafe files\n"
          "Input should be a Password Safe pwsafe (specified with -f)\n"
          "\nAuthor: Dhiru Kholia <dhiru at openwall.com>\n");
}


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

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

LLVM IR (-O0):
@.str = [248 x i8] c"pwsafe - Password Safe passphrase plugin\0A------------------------------------------------\0AUse this module to crack Password Safe pwsafe files\0AInput should be a Password Safe pwsafe (specified with -f)\0A\0AAuthor: Dhiru Kholia <dhiru at openwall.com>\0A\00"
define i8* @hash_plugin_detailed() {
ret i8* getelementptr inbounds ([248 x i8], [248 x i8]* @.str, i64 0, i64 0)
}

LLVM IR (-O2):
@.str = [248 x i8] c"pwsafe - Password Safe passphrase plugin\0A------------------------------------------------\0AUse this module to crack Password Safe pwsafe files\0AInput should be a Password Safe pwsafe (specified with -f)\0A\0AAuthor: Dhiru Kholia <dhiru at openwall.com>\0A\00"
define i8* @hash_plugin_detailed() {
ret i8* getelementptr inbounds ([248 x i8], [248 x i8]* @.str, i64 0, i64 0)
}
long pcount_do(unsigned long x) {
  long result = 0;
  do {
    result += x & 0x1;
    x >>= 1;
  } while (x);
  return result;
}


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

x86 assembly (clang, -O2):
<pcount_do>:
xor    %eax,%eax
mov    %rdi,%rcx
cs nopw 0x0(%rax,%rax,1)
nop
mov    %edi,%edx
and    $0x1,%edx
add    %rdx,%rax
shr    %rcx
cmp    $0x1,%rdi
mov    %rcx,%rdi
ja     1110 <pcount_do+0x10>
ret

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

LLVM IR (-O2):
define i64 @pcount_do(i64 %0) {
br label %2
2: ; preds = %2, %1
%3 = phi i64 [ %0, %1 ], [ %7, %2 ]
%4 = phi i64 [ 0, %1 ], [ %6, %2 ]
%5 = and i64 %3, 1
%6 = add i64 %4, %5
%7 = lshr i64 %3, 1
%8 = icmp ult i64 %3, 2
br i1 %8, label %9, label %2
9: ; preds = %2
ret i64 %6
}
/* Variables and functions */
int /*<<< orphan*/ cgpush();
int /*<<< orphan*/ commit();
int /*<<< orphan*/ gentext();
void genpush(void) {
  gentext();
  commit();
  cgpush();
}


x86 assembly (clang, -O0):
<genpush>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1040 <gentext@plt>
mov    $0x0,%al
call   1050 <commit@plt>
mov    $0x0,%al
call   1030 <cgpush@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<genpush>:
push   %rax
xor    %eax,%eax
call   1040 <gentext@plt>
xor    %eax,%eax
call   1050 <commit@plt>
xor    %eax,%eax
pop    %rcx
jmp    1030 <cgpush@plt>

LLVM IR (-O0):
define void @genpush() {
%1 = call i32 (...) @gentext()
%2 = call i32 (...) @commit()
%3 = call i32 (...) @cgpush()
ret void
}

LLVM IR (-O2):
define void @genpush() {
%1 = tail call i32 (...) @gentext()
%2 = tail call i32 (...) @commit()
%3 = tail call i32 (...) @cgpush()
ret void
}
unsigned long TimerCapture2Get(unsigned long ulBase) {

  ;
  return (*((volatile unsigned long *)(ulBase + 0x00000038)));
}


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

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

LLVM IR (-O0):
define i64 @TimerCapture2Get(i64 %0) {
%2 = alloca i64
store i64 %0, i64* %2
%3 = load i64, i64* %2
%4 = add i64 %3, 56
%5 = inttoptr i64 %4 to i64*
%6 = load volatile i64, i64* %5
ret i64 %6
}

LLVM IR (-O2):
define i64 @TimerCapture2Get(i64 %0) {
%2 = add i64 %0, 56
%3 = inttoptr i64 %2 to i64*
%4 = load volatile i64, i64* %3
ret i64 %4
}
/* Variables and functions */
int /*<<< orphan*/ pypysig_setflag(int);
void pypysig_reinstall(int signum) { pypysig_setflag(signum); }


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

x86 assembly (clang, -O2):
<pypysig_reinstall>:
jmp    1030 <pypysig_setflag@plt>

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

LLVM IR (-O2):
define void @pypysig_reinstall(i32 %0) {
%2 = tail call i32 @pypysig_setflag(i32 %0)
ret void
}
int mp_mp3_get_lsf(unsigned char *hbuf) {
  unsigned long newhead =
      hbuf[0] << 24 | hbuf[1] << 16 | hbuf[2] << 8 | hbuf[3];
  if (newhead & ((long)1 << 20)) {
    return (newhead & ((long)1 << 19)) ? 0x0 : 0x1;
  }
  return 1;
}


x86 assembly (clang, -O0):
<mp_mp3_get_lsf>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
movzbl (%rax),%eax
shl    $0x18,%eax
mov    -0x10(%rbp),%rcx
movzbl 0x1(%rcx),%ecx
shl    $0x10,%ecx
or     %ecx,%eax
mov    -0x10(%rbp),%rcx
movzbl 0x2(%rcx),%ecx
shl    $0x8,%ecx
or     %ecx,%eax
mov    -0x10(%rbp),%rcx
movzbl 0x3(%rcx),%ecx
or     %ecx,%eax
cltq
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
and    $0x100000,%rax
cmp    $0x0,%rax
je     1171 <mp_mp3_get_lsf+0x71>
mov    -0x18(%rbp),%rdx
and    $0x80000,%rdx
mov    $0x1,%eax
xor    %ecx,%ecx
cmp    $0x0,%rdx
cmovne %ecx,%eax
mov    %eax,-0x4(%rbp)
jmp    1178 <mp_mp3_get_lsf+0x78>
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<mp_mp3_get_lsf>:
movzbl 0x1(%rdi),%eax
xor    %ecx,%ecx
test   $0x8,%al
sete   %cl
test   $0x10,%al
mov    $0x1,%eax
cmovne %ecx,%eax
ret

LLVM IR (-O0):
define i32 @mp_mp3_get_lsf(i8* %0) {
%2 = alloca i32
%3 = alloca i8*
%4 = alloca i64
store i8* %0, i8** %3
%5 = load i8*, i8** %3
%6 = getelementptr inbounds i8, i8* %5, i64 0
%7 = load i8, i8* %6
%8 = zext i8 %7 to i32
%9 = shl i32 %8, 24
%10 = load i8*, i8** %3
%11 = getelementptr inbounds i8, i8* %10, i64 1
%12 = load i8, i8* %11
%13 = zext i8 %12 to i32
%14 = shl i32 %13, 16
%15 = or i32 %9, %14
%16 = load i8*, i8** %3
%17 = getelementptr inbounds i8, i8* %16, i64 2
%18 = load i8, i8* %17
%19 = zext i8 %18 to i32
%20 = shl i32 %19, 8
%21 = or i32 %15, %20
%22 = load i8*, i8** %3
%23 = getelementptr inbounds i8, i8* %22, i64 3
%24 = load i8, i8* %23
%25 = zext i8 %24 to i32
%26 = or i32 %21, %25
%27 = sext i32 %26 to i64
store i64 %27, i64* %4
%28 = load i64, i64* %4
%29 = and i64 %28, 1048576
%30 = icmp ne i64 %29, 0
br i1 %30, label %31, label %37
31: ; preds = %1
%32 = load i64, i64* %4
%33 = and i64 %32, 524288
%34 = icmp ne i64 %33, 0
%35 = zext i1 %34 to i64
%36 = select i1 %34, i32 0, i32 1
store i32 %36, i32* %2
br label %38
37: ; preds = %1
store i32 1, i32* %2
br label %38
38: ; preds = %37, %31
%39 = load i32, i32* %2
ret i32 %39
}

LLVM IR (-O2):
define i32 @mp_mp3_get_lsf(i8* nocapture %0) {
%2 = getelementptr inbounds i8, i8* %0, i64 1
%3 = load i8, i8* %2
%4 = zext i8 %3 to i32
%5 = and i32 %4, 16
%6 = icmp eq i32 %5, 0
%7 = lshr i32 %4, 3
%8 = and i32 %7, 1
%9 = xor i32 %8, 1
%10 = select i1 %6, i32 1, i32 %9
ret i32 %10
}
void av_copy_packet_side_data() {}


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

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

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

LLVM IR (-O2):
define void @av_copy_packet_side_data() {
ret void
}
int right_ch(int i, int k) { return (i + 1) * k; }


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

x86 assembly (clang, -O2):
<right_ch>:
lea    0x1(%rdi),%eax
imul   %esi,%eax
ret

LLVM IR (-O0):
define i32 @right_ch(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 = add nsw i32 %5, 1
%7 = load i32, i32* %4
%8 = mul nsw i32 %6, %7
ret i32 %8
}

LLVM IR (-O2):
define i32 @right_ch(i32 %0, i32 %1) {
%3 = add nsw i32 %0, 1
%4 = mul nsw i32 %3, %1
ret i32 %4
}
/* Variables and functions */
int /*<<< orphan*/ DumpNum(char *, int /*<<< orphan*/);
int /*<<< orphan*/ GetCodeCellDump();
int /*<<< orphan*/ StrDump(char *);
void DumpVariable() {
  StrDump("_DOVAR");
  DumpNum("\t%ld", GetCodeCellDump());
}


x86 assembly (clang, -O0):
<DumpVariable>:
push   %rbp
mov    %rsp,%rbp
lea    0xec5(%rip),%rdi
call   1040 <StrDump@plt>
mov    $0x0,%al
call   1050 <GetCodeCellDump@plt>
mov    %eax,%esi
lea    0xeb7(%rip),%rdi
call   1030 <DumpNum@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<DumpVariable>:
push   %rax
lea    0xec8(%rip),%rdi
call   1040 <StrDump@plt>
xor    %eax,%eax
call   1050 <GetCodeCellDump@plt>
lea    0xebc(%rip),%rdi
mov    %eax,%esi
pop    %rax
jmp    1030 <DumpNum@plt>

LLVM IR (-O0):
@.str = [7 x i8] c"_DOVAR\00"
@.str.1 = [5 x i8] c"\09%ld\00"
define void @DumpVariable() {
%1 = call i32 @StrDump(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0))
%2 = call i32 (...) @GetCodeCellDump()
%3 = call i32 @DumpNum(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i32 %2)
ret void
}

LLVM IR (-O2):
@.str = [7 x i8] c"_DOVAR\00"
@.str.1 = [5 x i8] c"\09%ld\00"
define void @DumpVariable() {
%1 = tail call i32 @StrDump(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 (...) @GetCodeCellDump()
%3 = tail call i32 @DumpNum(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i32 %2)
ret void
}
/* Variables and functions */
bool sb_is_pow2(size_t n) { return n && (n & (n - 1)) == 0; }


x86 assembly (clang, -O0):
<sb_is_pow2>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
xor    %eax,%eax
cmpq   $0x0,-0x8(%rbp)
mov    %al,-0x9(%rbp)
je     1131 <sb_is_pow2+0x31>
mov    -0x8(%rbp),%rax
mov    -0x8(%rbp),%rcx
sub    $0x1,%rcx
and    %rcx,%rax
cmp    $0x0,%rax
sete   %al
mov    %al,-0x9(%rbp)
mov    -0x9(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<sb_is_pow2>:
test   %rdi,%rdi
je     1112 <sb_is_pow2+0x12>
lea    -0x1(%rdi),%rcx
xor    %eax,%eax
test   %rcx,%rdi
sete   %al
ret
xor    %eax,%eax
ret

LLVM IR (-O0):
define i32 @sb_is_pow2(i64 %0) {
%2 = alloca i64
store i64 %0, i64* %2
%3 = load i64, i64* %2
%4 = icmp ne i64 %3, 0
br i1 %4, label %5, label %11
5: ; preds = %1
%6 = load i64, i64* %2
%7 = load i64, i64* %2
%8 = sub i64 %7, 1
%9 = and i64 %6, %8
%10 = icmp eq i64 %9, 0
br label %11
11: ; preds = %5, %1
%12 = phi i1 [ false, %1 ], [ %10, %5 ]
%13 = zext i1 %12 to i32
ret i32 %13
}

LLVM IR (-O2):
define i32 @sb_is_pow2(i64 %0) {
%2 = icmp eq i64 %0, 0
br i1 %2, label %7, label %3
3: ; preds = %1
%4 = tail call i64 @llvm.ctpop.i64(i64 %0)
%5 = icmp ult i64 %4, 2
%6 = zext i1 %5 to i32
br label %7
7: ; preds = %3, %1
%8 = phi i32 [ 0, %1 ], [ %6, %3 ]
ret i32 %8
}
void foo(void) {
  int *p = 0;
  *p = 42;
}


x86 assembly (clang, -O0):
<foo>:
push   %rbp
mov    %rsp,%rbp
movq   $0x0,-0x8(%rbp)
mov    -0x8(%rbp),%rax
movl   $0x2a,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
LLVM IR (-O0):
define void @foo() {
%1 = alloca i32*
store i32* null, i32** %1
%2 = load i32*, i32** %1
store i32 42, i32* %2
ret void
}

LLVM IR (-O2):
/* Variables and functions */
int errno;
int ret_err(int err) {
  errno = err;
  return -1;
}


x86 assembly (clang, -O0):
<ret_err>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%ecx
mov    0x2ecf(%rip),%rax
mov    %ecx,(%rax)
mov    $0xffffffff,%eax
pop    %rbp
ret

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

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

LLVM IR (-O2):
@errno = global i32 0
define i32 @ret_err(i32 %0) {
store i32 %0, i32* @errno
ret i32 -1
}
/* Variables and functions */
int /*<<< orphan*/ assert(int);
int main() {
  int i;
  int j;
  i = j;
  while (i < 5) {
    i = i + 1;
    j = j + 1;
  }
  assert(i == j);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x8(%rbp)
cmpl   $0x5,-0x8(%rbp)
jge    1146 <main+0x36>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    1125 <main+0x15>
mov    -0x8(%rbp),%eax
cmp    -0xc(%rbp),%eax
sete   %al
and    $0x1,%al
movzbl %al,%edi
call   1030 <assert@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

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

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

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 @assert(i32 0)
ret i32 0
}
float mpxmVToPressure(float v) { return (v / 1.24f) * 101.3f; }


x86 assembly (clang, -O0):
<mpxmVToPressure>:
push   %rbp
mov    %rsp,%rbp
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
movss  0xeee(%rip),%xmm1
divss  %xmm1,%xmm0
movss  0xede(%rip),%xmm1
mulss  %xmm1,%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<mpxmVToPressure>:
divss  0xef8(%rip),%xmm0
mulss  0xef4(%rip),%xmm0
ret

LLVM IR (-O0):
define float @mpxmVToPressure(float %0) {
%2 = alloca float
store float %0, float* %2
%3 = load float, float* %2
%4 = fdiv float %3, 0x3FF3D70A40000000
%5 = fmul float %4, 0x4059533340000000
ret float %5
}

LLVM IR (-O2):
define float @mpxmVToPressure(float %0) {
%2 = fdiv float %0, 0x3FF3D70A40000000
%3 = fmul float %2, 0x4059533340000000
ret float %3
}
/* Variables and functions */
int /*<<< orphan*/ assert(int /*<<< orphan*/);
void default_cmos_layout_get_fn(void) { assert(0); }


x86 assembly (clang, -O0):
<default_cmos_layout_get_fn>:
push   %rbp
mov    %rsp,%rbp
xor    %edi,%edi
call   1030 <assert@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<default_cmos_layout_get_fn>:
xor    %edi,%edi
jmp    1030 <assert@plt>

LLVM IR (-O0):
define void @default_cmos_layout_get_fn() {
%1 = call i32 @assert(i32 0)
ret void
}

LLVM IR (-O2):
define void @default_cmos_layout_get_fn() {
%1 = tail call i32 @assert(i32 0)
ret void
}
/* Type definitions */
typedef int uint16_t;

/* Variables and functions */
uint16_t return_uint16() { return 42; }


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

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

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

LLVM IR (-O2):
define i32 @return_uint16() {
ret i32 42
}
/* Variables and functions */
int evaluateExpression();
int /*<<< orphan*/ printf(char *, ...);
void main() {
  printf("Enter the evaluate expression,end with '#'\n");
  printf("The result is:"
         "%d"
         "\n",
         evaluateExpression());
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
lea    0xed5(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    $0x0,%al
call   1040 <evaluateExpression@plt>
mov    %eax,%esi
lea    0xeea(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xeda(%rip),%rdi
call   1030 <puts@plt>
xor    %eax,%eax
call   1050 <evaluateExpression@plt>
lea    0xeb5(%rip),%rdi
mov    %eax,%esi
xor    %eax,%eax
pop    %rcx
jmp    1040 <printf@plt>

LLVM IR (-O0):
@.str = [44 x i8] c"Enter the evaluate expression,end with '#'\0A\00"
@.str.1 = [18 x i8] c"The result is:%d\0A\00"
define void @main() {
%1 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([44 x i8], [44 x i8]* @.str, i64 0, i64 0))
%2 = call i32 (...) @evaluateExpression()
%3 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.1, i64 0, i64 0), i32 %2)
ret void
}

LLVM IR (-O2):
@.str.1 = [18 x i8] c"The result is:%d\0A\00"
@str = [43 x i8] c"Enter the evaluate expression,end with '#'\00"
define void @main() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([43 x i8], [43 x i8]* @str, i64 0, i64 0))
%2 = tail call i32 (...) @evaluateExpression()
%3 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @.str.1, i64 0, i64 0), i32 %2)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int);
foo(int a[][4], int i) { printf("%d", a[0][3]); }


x86 assembly (clang, -O0):
<foo>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %esi,-0x14(%rbp)
mov    -0x10(%rbp),%rax
mov    0xc(%rax),%esi
lea    0xed3(%rip),%rdi
call   1030 <printf@plt>
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<foo>:
mov    0xc(%rdi),%esi
lea    0xee6(%rip),%rdi
jmp    1030 <printf@plt>

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

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
define i32 @foo([4 x i32]* nocapture %0, i32 %1) {
%3 = getelementptr inbounds [4 x i32], [4 x i32]* %0, i64 0, i64 3
%4 = load i32, i32* %3
%5 = tail call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32 %4)
ret i32 undef
}
/* Type definitions */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
long ftell(int /*<<< orphan*/ *);
__attribute__((__weak__, __always___)) long softboundmpx_ftell(FILE *stream) {
  return ftell(stream);
}


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

x86 assembly (clang, -O2):
<softboundmpx_ftell>:
jmp    1030 <ftell@plt>

LLVM IR (-O0):
define weak i64 @softboundmpx_ftell(i32* %0) {
%2 = alloca i32*
store i32* %0, i32** %2
%3 = load i32*, i32** %2
%4 = call i64 @ftell(i32* %3)
ret i64 %4
}

LLVM IR (-O2):
define weak i64 @softboundmpx_ftell(i32* %0) {
%2 = tail call i64 @ftell(i32* %0)
ret i64 %2
}
void gtk_file_chooser_set_local_only() {}


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

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

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

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