xunge/DecIR huggingface dataset:
/* Variables and functions */
double sumArray(double *, int);
double roundArray(double d[], int size) {
  return sumArray(d, size) / (double)size;
}


x86 assembly (clang, -O0):
<roundArray>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
call   1030 <sumArray@plt>
cvtsi2sdl -0xc(%rbp),%xmm1
divsd  %xmm1,%xmm0
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<roundArray>:
push   %rbx
mov    %esi,%ebx
call   1030 <sumArray@plt>
cvtsi2sd %ebx,%xmm1
divsd  %xmm1,%xmm0
pop    %rbx
ret

LLVM IR (-O0):
define double @roundArray(double* %0, i32 %1) {
%3 = alloca double*
%4 = alloca i32
store double* %0, double** %3
store i32 %1, i32* %4
%5 = load double*, double** %3
%6 = load i32, i32* %4
%7 = call double @sumArray(double* %5, i32 %6)
%8 = load i32, i32* %4
%9 = sitofp i32 %8 to double
%10 = fdiv double %7, %9
ret double %10
}

LLVM IR (-O2):
define double @roundArray(double* %0, i32 %1) {
%3 = tail call double @sumArray(double* %0, i32 %1)
%4 = sitofp i32 %1 to double
%5 = fdiv double %3, %4
ret double %5
}
unsigned char getpsc(unsigned char address) { return address & 0x7; }


x86 assembly (clang, -O0):
<getpsc>:
push   %rbp
mov    %rsp,%rbp
mov    %dil,%al
mov    %al,-0x1(%rbp)
movzbl -0x1(%rbp),%eax
and    $0x7,%eax
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<getpsc>:
mov    %edi,%eax
and    $0x7,%al
ret

LLVM IR (-O0):
define zeroext i8 @getpsc(i8 zeroext %0) {
%2 = alloca i8
store i8 %0, i8* %2
%3 = load i8, i8* %2
%4 = zext i8 %3 to i32
%5 = and i32 %4, 7
%6 = trunc i32 %5 to i8
ret i8 %6
}

LLVM IR (-O2):
define zeroext i8 @getpsc(i8 zeroext %0) {
%2 = and i8 %0, 7
ret i8 %2
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int);
int main(void) {
  int salary;
  printf("My salary is %d.", salary);
  return 0;
}


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

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

LLVM IR (-O0):
@.str = [17 x i8] c"My salary is %d.\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
store i32 0, i32* %1
%3 = load i32, i32* %2
%4 = call i32 @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0), i32 %3)
ret i32 0
}

LLVM IR (-O2):
@.str = [17 x i8] c"My salary is %d.\00"
define i32 @main() {
%1 = tail call i32 @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0), i32 undef)
ret i32 0
}
void g_io_channel_get_type() {}


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

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

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

LLVM IR (-O2):
define void @g_io_channel_get_type() {
ret void
}
void snd_ak4114_resume(struct ak4114 *chip) {}


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

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

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

LLVM IR (-O2):
%struct.ak4114 = type opaque
define void @snd_ak4114_resume(%struct.ak4114* nocapture %0) {
ret void
}
void d2i_ASN1_BIT_STRING(void) {}


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

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

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

LLVM IR (-O2):
define void @d2i_ASN1_BIT_STRING() {
ret void
}
int load_conf(const char *file) { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @load_conf(i8* nocapture readnone %0) {
ret i32 0
}
/* Variables and functions */
double garan2();
double GARandomFloat() { return garan2(); }


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

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

LLVM IR (-O0):
define double @GARandomFloat() {
%1 = call double (...) @garan2()
ret double %1
}

LLVM IR (-O2):
define double @GARandomFloat() {
%1 = tail call double (...) @garan2()
ret double %1
}
/* Variables and functions */
int /*<<< orphan*/ _con_out(char);
int /*<<< orphan*/ pdr(short);
void pdri(short r) {
  _con_out((char)'(');
  pdr(r);
  _con_out((char)')');
}


x86 assembly (clang, -O0):
<pdri>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %di,%ax
mov    %ax,-0x2(%rbp)
mov    $0x28,%edi
call   1030 <_con_out@plt>
movswl -0x2(%rbp),%edi
call   1040 <pdr@plt>
mov    $0x29,%edi
call   1030 <_con_out@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<pdri>:
push   %rbx
mov    %edi,%ebx
mov    $0x28,%edi
call   1030 <_con_out@plt>
mov    %ebx,%edi
call   1040 <pdr@plt>
mov    $0x29,%edi
pop    %rbx
jmp    1030 <_con_out@plt>

LLVM IR (-O0):
define void @pdri(i16 signext %0) {
%2 = alloca i16
store i16 %0, i16* %2
%3 = call i32 @_con_out(i8 signext 40)
%4 = load i16, i16* %2
%5 = call i32 @pdr(i16 signext %4)
%6 = call i32 @_con_out(i8 signext 41)
ret void
}

LLVM IR (-O2):
define void @pdri(i16 signext %0) {
%2 = tail call i32 @_con_out(i8 signext 40)
%3 = tail call i32 @pdr(i16 signext %0)
%4 = tail call i32 @_con_out(i8 signext 41)
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ uint32_t;

/* Variables and functions */
int /*<<< orphan*/ by_at(int /*<<< orphan*/);
void xor_by_at(uint32_t x) {
  by_at(x);
  xor();
}


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

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

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

LLVM IR (-O2):
define void @xor_by_at(i32 %0) {
%2 = tail call i32 @by_at(i32 %0)
%3 = tail call i32 (...) @xor()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, char *, char *);
scalar_t__ strlen(char *);
void imagetag_cmdline_print_version(void) {
  printf("%s %s\n", (strlen("imagetag") ? "imagetag" : "imagetag"), "2.0.0");
}


x86 assembly (clang, -O0):
<imagetag_cmdline_print_version>:
push   %rbp
mov    %rsp,%rbp
lea    0xedc(%rip),%rdi
call   1030 <strlen@plt>
lea    0xed0(%rip),%rsi
cmp    $0x0,%rax
cmovne %rsi,%rsi
lea    0xeba(%rip),%rdi
lea    0xec3(%rip),%rdx
call   1040 <printf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<imagetag_cmdline_print_version>:
lea    0xee9(%rip),%rdi
lea    0xee9(%rip),%rsi
lea    0xeeb(%rip),%rdx
jmp    1030 <printf@plt>

LLVM IR (-O0):
@.str = [7 x i8] c"%s %s\0A\00"
@.str.1 = [9 x i8] c"imagetag\00"
@.str.2 = [6 x i8] c"2.0.0\00"
define void @imagetag_cmdline_print_version() {
%1 = call i64 @strlen(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0))
%2 = icmp ne i64 %1, 0
%3 = zext i1 %2 to i64
%4 = select i1 %2, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0)
%5 = call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i8* %4, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [7 x i8] c"%s %s\0A\00"
@.str.1 = [9 x i8] c"imagetag\00"
@.str.2 = [6 x i8] c"2.0.0\00"
define void @imagetag_cmdline_print_version() {
%1 = tail call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0))
ret void
}
/* Variables and functions */
int EX_OK;
int /*<<< orphan*/ get_statistics(char *);
int main(int argc, char **argv) {
  get_statistics((argc > 1) ? argv[1] : "ipw0");
  return EX_OK;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpl   $0x1,-0x8(%rbp)
jle    1141 <main+0x31>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rax
mov    %rax,-0x18(%rbp)
jmp    1151 <main+0x41>
lea    0xeb8(%rip),%rax
mov    %rax,-0x18(%rbp)
jmp    1151 <main+0x41>
mov    -0x18(%rbp),%rdi
call   1030 <get_statistics@plt>
mov    0x2e7f(%rip),%rax
mov    (%rax),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
cmp    $0x2,%edi
jl     111c <main+0xc>
mov    0x8(%rsi),%rdi
jmp    1123 <main+0x13>
lea    0xedd(%rip),%rdi
call   1030 <get_statistics@plt>
mov    0x2eb1(%rip),%rax
mov    (%rax),%eax
pop    %rcx
ret

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

LLVM IR (-O2):
@.str = [5 x i8] c"ipw0\00"
@EX_OK = global i32 0
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = icmp sgt i32 %0, 1
br i1 %3, label %4, label %7
4: ; preds = %2
%5 = getelementptr inbounds i8*, i8** %1, i64 1
%6 = load i8*, i8** %5
br label %7
7: ; preds = %2, %4
%8 = phi i8* [ %6, %4 ], [ getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), %2 ]
%9 = tail call i32 @get_statistics(i8* %8)
%10 = load i32, i32* @EX_OK
ret i32 %10
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
void draw_x(int x) {
  for (int i = 0; i < x; i++)
    printf("\n");
}


x86 assembly (clang, -O0):
<draw_x>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
mov    -0x8(%rbp),%eax
cmp    -0x4(%rbp),%eax
jge    1148 <draw_x+0x38>
lea    0xecb(%rip),%rdi
call   1030 <printf@plt>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1122 <draw_x+0x12>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<draw_x>:
push   %rbx
test   %edi,%edi
jle    112f <draw_x+0x1f>
mov    %edi,%ebx
nopw   0x0(%rax,%rax,1)
mov    $0xa,%edi
call   1030 <putchar@plt>
add    $0xffffffff,%ebx
jne    1120 <draw_x+0x10>
pop    %rbx
ret

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

LLVM IR (-O2):
define void @draw_x(i32 %0) {
%2 = icmp sgt i32 %0, 0
br i1 %2, label %4, label %3
3: ; preds = %4, %1
ret void
4: ; preds = %1, %4
%5 = phi i32 [ %7, %4 ], [ 0, %1 ]
%6 = tail call i32 @putchar(i32 10)
%7 = add nuw nsw i32 %5, 1
%8 = icmp eq i32 %7, %0
br i1 %8, label %3, label %4
}
void http_finalise(void) {}


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

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

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

LLVM IR (-O2):
define void @http_finalise() {
ret void
}
/* Variables and functions */
scalar_t__ sqrt(int);
void do_some_work(void) {
  int i;
  double sum = 0;
  for (i = 0; i < 1000; i++) {
    sum += sqrt(i);
  }
}


x86 assembly (clang, -O0):
<do_some_work>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x10(%rbp)
movl   $0x0,-0x4(%rbp)
cmpl   $0x3e8,-0x4(%rbp)
jge    1159 <do_some_work+0x49>
mov    -0x4(%rbp),%edi
call   1030 <sqrt@plt>
cvtsi2sd %rax,%xmm0
addsd  -0x10(%rbp),%xmm0
movsd  %xmm0,-0x10(%rbp)
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    1127 <do_some_work+0x17>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<do_some_work>:
push   %rbx
xor    %ebx,%ebx
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
mov    %ebx,%edi
call   1030 <sqrt@plt>
lea    0x1(%rbx),%edi
call   1030 <sqrt@plt>
lea    0x2(%rbx),%edi
call   1030 <sqrt@plt>
lea    0x3(%rbx),%edi
call   1030 <sqrt@plt>
lea    0x4(%rbx),%edi
call   1030 <sqrt@plt>
lea    0x5(%rbx),%edi
call   1030 <sqrt@plt>
lea    0x6(%rbx),%edi
call   1030 <sqrt@plt>
lea    0x7(%rbx),%edi
call   1030 <sqrt@plt>
lea    0x8(%rbx),%edi
call   1030 <sqrt@plt>
lea    0x9(%rbx),%edi
call   1030 <sqrt@plt>
add    $0xa,%ebx
cmp    $0x3e8,%ebx
jne    1120 <do_some_work+0x10>
pop    %rbx
ret

LLVM IR (-O0):
define void @do_some_work() {
%1 = alloca i32
%2 = alloca double
store double 0.000000e+00, double* %2
store i32 0, i32* %1
br label %3
3: ; preds = %12, %0
%4 = load i32, i32* %1
%5 = icmp slt i32 %4, 1000
br i1 %5, label %6, label %15
6: ; preds = %3
%7 = load i32, i32* %1
%8 = call i64 @sqrt(i32 %7)
%9 = sitofp i64 %8 to double
%10 = load double, double* %2
%11 = fadd double %10, %9
store double %11, double* %2
br label %12
12: ; preds = %6
%13 = load i32, i32* %1
%14 = add nsw i32 %13, 1
store i32 %14, i32* %1
br label %3
15: ; preds = %3
ret void
}

LLVM IR (-O2):
define void @do_some_work() {
br label %1
1: ; preds = %1, %0
%2 = phi i32 [ 0, %0 ], [ %22, %1 ]
%3 = tail call i64 @sqrt(i32 %2)
%4 = or i32 %2, 1
%5 = tail call i64 @sqrt(i32 %4)
%6 = add nuw nsw i32 %2, 2
%7 = tail call i64 @sqrt(i32 %6)
%8 = add nuw nsw i32 %2, 3
%9 = tail call i64 @sqrt(i32 %8)
%10 = add nuw nsw i32 %2, 4
%11 = tail call i64 @sqrt(i32 %10)
%12 = add nuw nsw i32 %2, 5
%13 = tail call i64 @sqrt(i32 %12)
%14 = add nuw nsw i32 %2, 6
%15 = tail call i64 @sqrt(i32 %14)
%16 = add nuw nsw i32 %2, 7
%17 = tail call i64 @sqrt(i32 %16)
%18 = add nuw nsw i32 %2, 8
%19 = tail call i64 @sqrt(i32 %18)
%20 = add nuw nsw i32 %2, 9
%21 = tail call i64 @sqrt(i32 %20)
%22 = add nuw nsw i32 %2, 10
%23 = icmp eq i32 %22, 1000
br i1 %23, label %24, label %1
24: ; preds = %1
ret void
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ isupper(int);
void t_isupper_0x3e() {
  Assert_real((isupper(62) == 0),
              "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/"
              "2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/"
              "dg/z88dk/test/suites/ctype/test_isupper.c",
              315, ("isupper should be 0 for >"));
}


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

x86 assembly (clang, -O2):
<t_isupper_0x3e>:
push   %rax
mov    $0x3e,%edi
call   1030 <isupper@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
lea    0xec5(%rip),%rsi
lea    0xf66(%rip),%rcx
mov    $0x13b,%edx
pop    %rax
jmp    1040 <Assert_real@plt>

LLVM IR (-O0):
@.str = [168 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_isupper.c\00"
@.str.1 = [26 x i8] c"isupper should be 0 for >\00"
define void @t_isupper_0x3e() {
%1 = call i64 @isupper(i32 62)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 315, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [168 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_isupper.c\00"
@.str.1 = [26 x i8] c"isupper should be 0 for >\00"
define void @t_isupper_0x3e() {
%1 = tail call i64 @isupper(i32 62)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = tail call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 315, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Variables and functions */
scalar_t__ strncmp(char *, char *, int);
int os_islocaladdr(char *hostaddr) {
  if (strncmp(hostaddr, "127.", 4) == 0)
    return 1;
  return 0;
}


x86 assembly (clang, -O0):
<os_islocaladdr>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
lea    0xed9(%rip),%rsi
mov    $0x4,%edx
call   1030 <strncmp@plt>
cmp    $0x0,%rax
jne    1147 <os_islocaladdr+0x37>
movl   $0x1,-0x4(%rbp)
jmp    114e <os_islocaladdr+0x3e>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<os_islocaladdr>:
push   %rax
lea    0xee8(%rip),%rsi
mov    $0x4,%edx
call   1030 <strncmp@plt>
xor    %ecx,%ecx
test   %rax,%rax
sete   %cl
mov    %ecx,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [5 x i8] c"127.\00"
define i32 @os_islocaladdr(i8* %0) {
%2 = alloca i32
%3 = alloca i8*
store i8* %0, i8** %3
%4 = load i8*, i8** %3
%5 = call i64 @strncmp(i8* %4, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32 4)
%6 = icmp eq i64 %5, 0
br i1 %6, label %7, label %8
7: ; preds = %1
store i32 1, i32* %2
br label %9
8: ; preds = %1
store i32 0, i32* %2
br label %9
9: ; preds = %8, %7
%10 = load i32, i32* %2
ret i32 %10
}

LLVM IR (-O2):
@.str = [5 x i8] c"127.\00"
define i32 @os_islocaladdr(i8* %0) {
%2 = tail call i64 @strncmp(i8* %0, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32 4)
%3 = icmp eq i64 %2, 0
%4 = zext i1 %3 to i32
ret i32 %4
}
/* Type definitions */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
long ftell(int /*<<< orphan*/ *);
long c_ftell_(FILE **stream) { return ftell(*stream); }


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

x86 assembly (clang, -O2):
<c_ftell_>:
mov    (%rdi),%rdi
jmp    1030 <ftell@plt>

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

LLVM IR (-O2):
define i64 @c_ftell_(i32** nocapture %0) {
%2 = load i32*, i32** %0
%3 = tail call i64 @ftell(i32* %2)
ret i64 %3
}
/* Type definitions */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
int /*<<< orphan*/ fprintf(int /*<<< orphan*/ *, char *, char *);
int /*<<< orphan*/ sprintf(char *, char *, int, char const *);
void send_status(FILE *client, int code, const char *reason_phrase) {
  char status[256];
  sprintf(status, "HTTP/1.1 %d %s\r\n", code, reason_phrase);
  fprintf(client, "%s", status);
}


x86 assembly (clang, -O0):
<send_status>:
push   %rbp
mov    %rsp,%rbp
sub    $0x120,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %rdx,-0x18(%rbp)
lea    -0x120(%rbp),%rdi
mov    -0xc(%rbp),%edx
mov    -0x18(%rbp),%rcx
lea    0xeb5(%rip),%rsi
call   1040 <sprintf@plt>
mov    -0x8(%rbp),%rdi
lea    -0x120(%rbp),%rdx
lea    0xeaf(%rip),%rsi
call   1030 <fprintf@plt>
add    $0x120,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<send_status>:
push   %r14
push   %rbx
sub    $0x108,%rsp
mov    %rdx,%rcx
mov    %esi,%edx
mov    %rdi,%rbx
lea    0xec7(%rip),%rsi
mov    %rsp,%r14
mov    %r14,%rdi
call   1040 <sprintf@plt>
mov    %r14,%rdi
mov    %rbx,%rsi
call   1030 <fputs@plt>
add    $0x108,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
@.str = [17 x i8] c"HTTP/1.1 %d %s\0D\0A\00"
@.str.1 = [3 x i8] c"%s\00"
define void @send_status(i32* %0, i32 %1, i8* %2) {
%4 = alloca i32*
%5 = alloca i32
%6 = alloca i8*
%7 = alloca [256 x i8]
store i32* %0, i32** %4
store i32 %1, i32* %5
store i8* %2, i8** %6
%8 = getelementptr inbounds [256 x i8], [256 x i8]* %7, i64 0, i64 0
%9 = load i32, i32* %5
%10 = load i8*, i8** %6
%11 = call i32 @sprintf(i8* %8, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0), i32 %9, i8* %10)
%12 = load i32*, i32** %4
%13 = getelementptr inbounds [256 x i8], [256 x i8]* %7, i64 0, i64 0
%14 = call i32 @fprintf(i32* %12, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i8* %13)
ret void
}

LLVM IR (-O2):
@.str = [17 x i8] c"HTTP/1.1 %d %s\0D\0A\00"
define void @send_status(i32* nocapture %0, i32 %1, i8* %2) {
%4 = alloca [256 x i8]
%5 = getelementptr inbounds [256 x i8], [256 x i8]* %4, i64 0, i64 0
%6 = call i32 @sprintf(i8* %5, i8* dereferenceable(1) getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0), i32 %1, i8* %2)
%7 = call i32 @fputs(i8* %5, i32* %0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ RSTATPROG;
int /*<<< orphan*/ RSTATVERS_ORIG;
int /*<<< orphan*/ RSTATVERS_SWTCH;
int /*<<< orphan*/ RSTATVERS_TIME;
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ rpcb_unset(int /*<<< orphan*/, int /*<<< orphan*/,
                              int /*<<< orphan*/ *);
void cleanup(int dummy) {
  (void)rpcb_unset(RSTATPROG, RSTATVERS_TIME, NULL);
  (void)rpcb_unset(RSTATPROG, RSTATVERS_SWTCH, NULL);
  (void)rpcb_unset(RSTATPROG, RSTATVERS_ORIG, NULL);
  exit(0);
}


x86 assembly (clang, -O0):
<cleanup>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    0x2e9e(%rip),%rax
mov    (%rax),%edi
mov    0x2e85(%rip),%rax
mov    (%rax),%esi
xor    %eax,%eax
mov    %eax,%edx
call   1030 <rpcb_unset@plt>
mov    0x2e83(%rip),%rax
mov    (%rax),%edi
mov    0x2e8a(%rip),%rax
mov    (%rax),%esi
xor    %eax,%eax
mov    %eax,%edx
call   1030 <rpcb_unset@plt>
mov    0x2e68(%rip),%rax
mov    (%rax),%edi
mov    0x2e77(%rip),%rax
mov    (%rax),%esi
xor    %eax,%eax
mov    %eax,%edx
call   1030 <rpcb_unset@plt>
xor    %edi,%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<cleanup>:
push   %rbx
mov    0x2ea8(%rip),%rbx
mov    (%rbx),%edi
mov    0x2e8f(%rip),%rax
mov    (%rax),%esi
xor    %edx,%edx
call   1030 <rpcb_unset@plt>
mov    (%rbx),%edi
mov    0x2e9d(%rip),%rax
mov    (%rax),%esi
xor    %edx,%edx
call   1030 <rpcb_unset@plt>
mov    (%rbx),%edi
mov    0x2e93(%rip),%rax
mov    (%rax),%esi
xor    %edx,%edx
call   1030 <rpcb_unset@plt>
xor    %edi,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@RSTATPROG = global i32 0
@RSTATVERS_TIME = global i32 0
@RSTATVERS_SWTCH = global i32 0
@RSTATVERS_ORIG = global i32 0
define void @cleanup(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* @RSTATPROG
%4 = load i32, i32* @RSTATVERS_TIME
%5 = call i32 @rpcb_unset(i32 %3, i32 %4, i32* null)
%6 = load i32, i32* @RSTATPROG
%7 = load i32, i32* @RSTATVERS_SWTCH
%8 = call i32 @rpcb_unset(i32 %6, i32 %7, i32* null)
%9 = load i32, i32* @RSTATPROG
%10 = load i32, i32* @RSTATVERS_ORIG
%11 = call i32 @rpcb_unset(i32 %9, i32 %10, i32* null)
%12 = call i32 @exit(i32 0)
unreachable
}

LLVM IR (-O2):
@RSTATPROG = global i32 0
@RSTATVERS_TIME = global i32 0
@RSTATVERS_SWTCH = global i32 0
@RSTATVERS_ORIG = global i32 0
define void @cleanup(i32 %0) {
%2 = load i32, i32* @RSTATPROG
%3 = load i32, i32* @RSTATVERS_TIME
%4 = tail call i32 @rpcb_unset(i32 %2, i32 %3, i32* null)
%5 = load i32, i32* @RSTATPROG
%6 = load i32, i32* @RSTATVERS_SWTCH
%7 = tail call i32 @rpcb_unset(i32 %5, i32 %6, i32* null)
%8 = load i32, i32* @RSTATPROG
%9 = load i32, i32* @RSTATVERS_ORIG
%10 = tail call i32 @rpcb_unset(i32 %8, i32 %9, i32* null)
%11 = tail call i32 @exit(i32 0)
unreachable
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int, int);
int main() {
  int i = 0;
  for (i; i < 256; i++) {
    printf("%d %c\n", i, i);
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
cmpl   $0x100,-0x8(%rbp)
jge    1153 <main+0x43>
mov    -0x8(%rbp),%esi
mov    -0x8(%rbp),%edx
lea    0xec0(%rip),%rdi
call   1030 <printf@plt>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1126 <main+0x16>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

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

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

LLVM IR (-O2):
@.str = [7 x i8] c"%d %c\0A\00"
define i32 @main() {
br label %1
1: ; preds = %0, %1
%2 = phi i32 [ 0, %0 ], [ %4, %1 ]
%3 = tail call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i32 %2, i32 %2)
%4 = add nuw nsw i32 %2, 1
%5 = icmp eq i32 %4, 256
br i1 %5, label %6, label %1
6: ; preds = %1
ret i32 0
}
/* Variables and functions */
int increment(int);
int /*<<< orphan*/ other_function();
int /*<<< orphan*/ printf(char *, int);
int main(int argc, char *argv[]) {
  printf("increment(1): %d\n", increment(1));
  other_function();
  return 0;
}


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

x86 assembly (clang, -O2):
<main>:
push   %rax
mov    $0x1,%edi
call   1030 <increment@plt>
lea    0xebe(%rip),%rdi
mov    %eax,%esi
call   1040 <printf@plt>
xor    %eax,%eax
call   1050 <other_function@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [18 x i8] c"increment(1): %d\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 @increment(i32 1)
%7 = call i32 @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0), i32 %6)
%8 = call i32 (...) @other_function()
ret i32 0
}

LLVM IR (-O2):
@.str = [18 x i8] c"increment(1): %d\0A\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @increment(i32 1)
%4 = tail call i32 @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0), i32 %3)
%5 = tail call i32 (...) @other_function()
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ assert(int);
int main() {
  assert((2 ^ 3) == 3);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
xor    %edi,%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
store i32 0, i32* %1
%2 = call i32 @assert(i32 0)
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 @assert(i32 0)
ret i32 0
}
/* Type definitions */
struct quat {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ quat_inverse(float *, float *);
__attribute__((always_)) struct quat *psquat_inverse(struct quat *result,
                                                     struct quat *a) {
  quat_inverse((float *)result, (float *)a);
  return result;
}


x86 assembly (clang, -O0):
<psquat_inverse>:
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 <quat_inverse@plt>
mov    -0x8(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<psquat_inverse>:
push   %rbx
mov    %rdi,%rbx
call   1030 <quat_inverse@plt>
mov    %rbx,%rax
pop    %rbx
ret

LLVM IR (-O0):
%struct.quat = type { i32 }
define %struct.quat* @psquat_inverse(%struct.quat* %0, %struct.quat* %1) {
%3 = alloca %struct.quat*
%4 = alloca %struct.quat*
store %struct.quat* %0, %struct.quat** %3
store %struct.quat* %1, %struct.quat** %4
%5 = load %struct.quat*, %struct.quat** %3
%6 = bitcast %struct.quat* %5 to float*
%7 = load %struct.quat*, %struct.quat** %4
%8 = bitcast %struct.quat* %7 to float*
%9 = call i32 @quat_inverse(float* %6, float* %8)
%10 = load %struct.quat*, %struct.quat** %3
ret %struct.quat* %10
}

LLVM IR (-O2):
%struct.quat = type { i32 }
define %struct.quat* @psquat_inverse(%struct.quat* returned %0, %struct.quat* %1) {
%3 = bitcast %struct.quat* %0 to float*
%4 = bitcast %struct.quat* %1 to float*
%5 = tail call i32 @quat_inverse(float* %3, float* %4)
ret %struct.quat* %0
}
int _power_of_2_upper_bound(int v) {
  int i = 0;
  while ((1 << i) < v && i < 31)
    i++;
  return (1 << i);
}


x86 assembly (clang, -O0):
<_power_of_2_upper_bound>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
mov    -0x8(%rbp),%ecx
mov    $0x1,%eax
shl    %cl,%eax
mov    %eax,%ecx
xor    %eax,%eax
cmp    -0x4(%rbp),%ecx
mov    %al,-0x9(%rbp)
jge    1132 <_power_of_2_upper_bound+0x32>
cmpl   $0x1f,-0x8(%rbp)
setl   %al
mov    %al,-0x9(%rbp)
mov    -0x9(%rbp),%al
test   $0x1,%al
jne    1142 <_power_of_2_upper_bound+0x42>
jmp    1150 <_power_of_2_upper_bound+0x50>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    110e <_power_of_2_upper_bound+0xe>
mov    -0x8(%rbp),%ecx
mov    $0x1,%eax
shl    %cl,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<_power_of_2_upper_bound>:
xor    %ecx,%ecx
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
mov    $0x1,%eax
shl    %cl,%eax
cmp    $0x1e,%ecx
ja     1123 <_power_of_2_upper_bound+0x23>
add    $0x1,%ecx
cmp    %edi,%eax
jl     1110 <_power_of_2_upper_bound+0x10>
ret

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

LLVM IR (-O2):
define i32 @_power_of_2_upper_bound(i32 %0) {
br label %2
2: ; preds = %2, %1
%3 = phi i32 [ 0, %1 ], [ %8, %2 ]
%4 = shl nuw i32 1, %3
%5 = icmp slt i32 %4, %0
%6 = icmp ult i32 %3, 31
%7 = and i1 %6, %5
%8 = add nuw nsw i32 %3, 1
br i1 %7, label %2, label %9
9: ; preds = %2
ret i32 %4
}
/* Type definitions */
typedef int /*<<< orphan*/ __u64;

/* Variables and functions */
int hea_test_u64_bit(int /*<<< orphan*/ const, int);
int hea_cq_aer_eq_disabled_err_check(const __u64 *aer) {
  return hea_test_u64_bit(*aer, 10);
}


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

x86 assembly (clang, -O2):
<hea_cq_aer_eq_disabled_err_check>:
mov    (%rdi),%edi
mov    $0xa,%esi
jmp    1030 <hea_test_u64_bit@plt>

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

LLVM IR (-O2):
define i32 @hea_cq_aer_eq_disabled_err_check(i32* nocapture %0) {
%2 = load i32, i32* %0
%3 = tail call i32 @hea_test_u64_bit(i32 %2, i32 10)
ret i32 %3
}
_Bool maxLengthExceeded(char *numeralString) {
  int maxLength = 16;
  return strlen(numeralString) >= maxLength ? 1 : 0;
}


x86 assembly (clang, -O0):
<maxLengthExceeded>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
movl   $0x10,-0xc(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <strlen@plt>
mov    %rax,%rdx
movslq -0xc(%rbp),%rsi
xor    %eax,%eax
mov    $0x1,%ecx
cmp    %rsi,%rdx
cmovae %ecx,%eax
cmp    $0x0,%eax
setne  %al
and    $0x1,%al
movzbl %al,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<maxLengthExceeded>:
push   %rax
call   1030 <strlen@plt>
cmp    $0x10,%rax
setae  %al
pop    %rcx
ret

LLVM IR (-O0):
define zeroext i1 @maxLengthExceeded(i8* %0) {
%2 = alloca i8*
%3 = alloca i32
store i8* %0, i8** %2
store i32 16, i32* %3
%4 = load i8*, i8** %2
%5 = call i64 @strlen(i8* %4)
%6 = load i32, i32* %3
%7 = sext i32 %6 to i64
%8 = icmp uge i64 %5, %7
%9 = zext i1 %8 to i64
%10 = select i1 %8, i32 1, i32 0
%11 = icmp ne i32 %10, 0
ret i1 %11
}

LLVM IR (-O2):
define zeroext i1 @maxLengthExceeded(i8* nocapture %0) {
%2 = tail call i64 @strlen(i8* dereferenceable(1) %0)
%3 = icmp ugt i64 %2, 15
ret i1 %3
}
const char *hithere_LTX_get_salutation(void) { return "Hi there"; }


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

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

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

LLVM IR (-O2):
@.str = [9 x i8] c"Hi there\00"
define i8* @hithere_LTX_get_salutation() {
ret i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0)
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int);
int main(int argc) {
  printf("Number of command line arguments passed: %d\n", argc);
  return 0;
}


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

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

LLVM IR (-O0):
@.str = [45 x i8] c"Number of command line arguments passed: %d\0A\00"
define i32 @main(i32 %0) {
%2 = alloca i32
%3 = alloca i32
store i32 0, i32* %2
store i32 %0, i32* %3
%4 = load i32, i32* %3
%5 = call i32 @printf(i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str, i64 0, i64 0), i32 %4)
ret i32 0
}

LLVM IR (-O2):
@.str = [45 x i8] c"Number of command line arguments passed: %d\0A\00"
define i32 @main(i32 %0) {
%2 = tail call i32 @printf(i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str, i64 0, i64 0), i32 %0)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ unlink(char const *);
void bm_atom_destroy(const char *fname) { unlink(fname); }


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

x86 assembly (clang, -O2):
<bm_atom_destroy>:
jmp    1030 <unlink@plt>

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

LLVM IR (-O2):
define void @bm_atom_destroy(i8* nocapture %0) {
%2 = tail call i32 @unlink(i8* %0)
ret void
}
/* Variables and functions */
scalar_t__ f(int, int);
int main() {
  f(1, 2);
  1 + f(1, 2);
  f(1, 2) + 1;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
mov    $0x1,%edi
mov    $0x2,%esi
call   1030 <f@plt>
mov    $0x1,%edi
mov    $0x2,%esi
call   1030 <f@plt>
mov    $0x1,%edi
mov    $0x2,%esi
call   1030 <f@plt>
xor    %eax,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
mov    $0x1,%edi
mov    $0x2,%esi
call   1030 <f@plt>
mov    $0x1,%edi
mov    $0x2,%esi
call   1030 <f@plt>
mov    $0x1,%edi
mov    $0x2,%esi
call   1030 <f@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @main() {
%1 = call i64 @f(i32 1, i32 2)
%2 = call i64 @f(i32 1, i32 2)
%3 = add nsw i64 1, %2
%4 = call i64 @f(i32 1, i32 2)
%5 = add nsw i64 %4, 1
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i64 @f(i32 1, i32 2)
%2 = tail call i64 @f(i32 1, i32 2)
%3 = tail call i64 @f(i32 1, i32 2)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ NETX_PFIFO_BASE(int);
int /*<<< orphan*/ writel(unsigned int, int /*<<< orphan*/);
int pfifo_push(int no, unsigned int pointer) {
  writel(pointer, NETX_PFIFO_BASE(no));
  return 0;
}


x86 assembly (clang, -O0):
<pfifo_push>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x8(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0x4(%rbp),%edi
call   1030 <NETX_PFIFO_BASE@plt>
mov    -0xc(%rbp),%edi
mov    %eax,%esi
call   1040 <writel@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<pfifo_push>:
push   %rbx
mov    %esi,%ebx
call   1030 <NETX_PFIFO_BASE@plt>
mov    %ebx,%edi
mov    %eax,%esi
call   1040 <writel@plt>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
define i32 @pfifo_push(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 = call i32 @NETX_PFIFO_BASE(i32 %6)
%8 = call i32 @writel(i32 %5, i32 %7)
ret i32 0
}

LLVM IR (-O2):
define i32 @pfifo_push(i32 %0, i32 %1) {
%3 = tail call i32 @NETX_PFIFO_BASE(i32 %0)
%4 = tail call i32 @writel(i32 %1, i32 %3)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ *strchr(char *, int);
int characterIsVowel(char c) {
  int charAsInt = (int)c;
  return strchr("aeiouAEIOU", charAsInt) != NULL;
}


x86 assembly (clang, -O0):
<characterIsVowel>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %dil,%al
mov    %al,-0x1(%rbp)
movsbl -0x1(%rbp),%eax
mov    %eax,-0x8(%rbp)
mov    -0x8(%rbp),%esi
lea    0xed1(%rip),%rdi
call   1030 <strchr@plt>
cmp    $0x0,%rax
setne  %al
and    $0x1,%al
movzbl %al,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<characterIsVowel>:
push   %rax
mov    %edi,%esi
lea    0xee6(%rip),%rdi
call   1030 <strchr@plt>
xor    %ecx,%ecx
test   %rax,%rax
setne  %cl
mov    %ecx,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [11 x i8] c"aeiouAEIOU\00"
define i32 @characterIsVowel(i8 signext %0) {
%2 = alloca i8
%3 = alloca i32
store i8 %0, i8* %2
%4 = load i8, i8* %2
%5 = sext i8 %4 to i32
store i32 %5, i32* %3
%6 = load i32, i32* %3
%7 = call i32* @strchr(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0), i32 %6)
%8 = icmp ne i32* %7, null
%9 = zext i1 %8 to i32
ret i32 %9
}

LLVM IR (-O2):
@.str = [11 x i8] c"aeiouAEIOU\00"
define i32 @characterIsVowel(i8 signext %0) {
%2 = sext i8 %0 to i32
%3 = tail call i32* @strchr(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0), i32 %2)
%4 = icmp ne i32* %3, null
%5 = zext i1 %4 to i32
ret i32 %5
}
/* Variables and functions */
int random();
int random_errno_generator(void) {
  int r = 1;
  r += random() % 132;
  return r;
}


x86 assembly (clang, -O0):
<random_errno_generator>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x1,-0x4(%rbp)
mov    $0x0,%al
call   1030 <random@plt>
mov    $0x84,%ecx
cltd
idiv   %ecx
add    -0x4(%rbp),%edx
mov    %edx,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<random_errno_generator>:
push   %rax
xor    %eax,%eax
call   1030 <random@plt>
cltq
imul   $0x3e0f83e1,%rax,%rcx
mov    %rcx,%rdx
shr    $0x3f,%rdx
sar    $0x25,%rcx
add    %edx,%ecx
mov    %ecx,%edx
shl    $0x7,%edx
lea    (%rdx,%rcx,4),%ecx
neg    %ecx
add    %ecx,%eax
add    $0x1,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @random_errno_generator() {
%1 = alloca i32
store i32 1, i32* %1
%2 = call i32 (...) @random()
%3 = srem i32 %2, 132
%4 = load i32, i32* %1
%5 = add nsw i32 %4, %3
store i32 %5, i32* %1
%6 = load i32, i32* %1
ret i32 %6
}

LLVM IR (-O2):
define i32 @random_errno_generator() {
%1 = tail call i32 (...) @random()
%2 = srem i32 %1, 132
%3 = add nsw i32 %2, 1
ret i32 %3
}
/* Variables and functions */
int /*<<< orphan*/ sleep(int);
int /*<<< orphan*/ system(char *);
int main(int argc, char *argv[]) {
  system("whoami");
  sleep(10);
  system("whoami");
  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   1030 <system@plt>
mov    $0xa,%edi
call   1040 <sleep@plt>
lea    0xead(%rip),%rdi
call   1030 <system@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
lea    0xed8(%rip),%rbx
mov    %rbx,%rdi
call   1030 <system@plt>
mov    $0xa,%edi
call   1040 <sleep@plt>
mov    %rbx,%rdi
call   1030 <system@plt>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [7 x i8] c"whoami\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 @system(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0))
%7 = call i32 @sleep(i32 10)
%8 = call i32 @system(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@.str = [7 x i8] c"whoami\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @system(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0))
%4 = tail call i32 @sleep(i32 10)
%5 = tail call i32 @system(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0))
ret i32 0
}
int postdec_arg_ptr(int *p) {
  int *q;
  q = p - 1;
  __builtin_prefetch(p--, 0, 0);
  return p == q;
}


x86 assembly (clang, -O0):
<postdec_arg_ptr>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
add    $0xfffffffffffffffc,%rax
mov    %rax,-0x10(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,%rcx
add    $0xfffffffffffffffc,%rcx
mov    %rcx,-0x8(%rbp)
prefetchnta (%rax)
mov    -0x8(%rbp),%rax
cmp    -0x10(%rbp),%rax
sete   %al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

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

LLVM IR (-O0):
define i32 @postdec_arg_ptr(i32* %0) {
%2 = alloca i32*
%3 = alloca i32*
store i32* %0, i32** %2
%4 = load i32*, i32** %2
%5 = getelementptr inbounds i32, i32* %4, i64 -1
store i32* %5, i32** %3
%6 = load i32*, i32** %2
%7 = getelementptr inbounds i32, i32* %6, i32 -1
store i32* %7, i32** %2
%8 = bitcast i32* %6 to i8*
%9 = load i32*, i32** %2
%10 = load i32*, i32** %3
%11 = icmp eq i32* %9, %10
%12 = zext i1 %11 to i32
ret i32 %12
}

LLVM IR (-O2):
define i32 @postdec_arg_ptr(i32* nocapture %0) {
%2 = bitcast i32* %0 to i8*
tail call void @llvm.prefetch.p0i8(i8* %2, i32 0, i32 0, i32 1)
ret i32 1
}
/* Type definitions */
struct gdev_time {
  int dummy;
};

/* Variables and functions */
scalar_t__ gdev_time_eq(struct gdev_time *, struct gdev_time *);
int gdev_time_lt(struct gdev_time *, struct gdev_time *);
int gdev_time_le(struct gdev_time *x, struct gdev_time *y) {
  if (gdev_time_eq(x, y))
    return 1;
  else
    return gdev_time_lt(x, y);
}


x86 assembly (clang, -O0):
<gdev_time_le>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
call   1030 <gdev_time_eq@plt>
cmp    $0x0,%rax
je     1153 <gdev_time_le+0x33>
movl   $0x1,-0x4(%rbp)
jmp    1163 <gdev_time_le+0x43>
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
call   1040 <gdev_time_lt@plt>
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<gdev_time_le>:
push   %r14
push   %rbx
push   %rax
mov    %rsi,%r14
mov    %rdi,%rbx
call   1030 <gdev_time_eq@plt>
test   %rax,%rax
je     1141 <gdev_time_le+0x21>
mov    $0x1,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret
mov    %rbx,%rdi
mov    %r14,%rsi
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1040 <gdev_time_lt@plt>

LLVM IR (-O0):
%struct.gdev_time = type { i32 }
define i32 @gdev_time_le(%struct.gdev_time* %0, %struct.gdev_time* %1) {
%3 = alloca i32
%4 = alloca %struct.gdev_time*
%5 = alloca %struct.gdev_time*
store %struct.gdev_time* %0, %struct.gdev_time** %4
store %struct.gdev_time* %1, %struct.gdev_time** %5
%6 = load %struct.gdev_time*, %struct.gdev_time** %4
%7 = load %struct.gdev_time*, %struct.gdev_time** %5
%8 = call i64 @gdev_time_eq(%struct.gdev_time* %6, %struct.gdev_time* %7)
%9 = icmp ne i64 %8, 0
br i1 %9, label %10, label %11
10: ; preds = %2
store i32 1, i32* %3
br label %15
11: ; preds = %2
%12 = load %struct.gdev_time*, %struct.gdev_time** %4
%13 = load %struct.gdev_time*, %struct.gdev_time** %5
%14 = call i32 @gdev_time_lt(%struct.gdev_time* %12, %struct.gdev_time* %13)
store i32 %14, i32* %3
br label %15
15: ; preds = %11, %10
%16 = load i32, i32* %3
ret i32 %16
}

LLVM IR (-O2):
%struct.gdev_time = type { i32 }
define i32 @gdev_time_le(%struct.gdev_time* %0, %struct.gdev_time* %1) {
%3 = tail call i64 @gdev_time_eq(%struct.gdev_time* %0, %struct.gdev_time* %1)
%4 = icmp eq i64 %3, 0
br i1 %4, label %5, label %7
5: ; preds = %2
%6 = tail call i32 @gdev_time_lt(%struct.gdev_time* %0, %struct.gdev_time* %1)
br label %7
7: ; preds = %2, %5
%8 = phi i32 [ %6, %5 ], [ 1, %2 ]
ret i32 %8
}
/* Type definitions */
typedef scalar_t__ uint8_t;
typedef int uint16_t;
typedef int /*<<< orphan*/ p;

/* Variables and functions */
uint16_t scrypt_le16dec(const void *pp) {
  const uint8_t *p = (uint8_t const *)pp;
  return ((uint16_t)(p[0]) + ((uint16_t)(p[1]) << 8));
}


x86 assembly (clang, -O0):
<scrypt_le16dec>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rax
mov    (%rax),%rax
mov    -0x10(%rbp),%rcx
mov    0x8(%rcx),%rcx
shl    $0x8,%ecx
add    %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<scrypt_le16dec>:
mov    0x8(%rdi),%eax
shl    $0x8,%eax
add    (%rdi),%eax
ret

LLVM IR (-O0):
define i32 @scrypt_le16dec(i8* %0) {
%2 = alloca i8*
%3 = alloca i64*
store i8* %0, i8** %2
%4 = load i8*, i8** %2
%5 = bitcast i8* %4 to i64*
store i64* %5, i64** %3
%6 = load i64*, i64** %3
%7 = getelementptr inbounds i64, i64* %6, i64 0
%8 = load i64, i64* %7
%9 = trunc i64 %8 to i32
%10 = load i64*, i64** %3
%11 = getelementptr inbounds i64, i64* %10, i64 1
%12 = load i64, i64* %11
%13 = trunc i64 %12 to i32
%14 = shl i32 %13, 8
%15 = add nsw i32 %9, %14
ret i32 %15
}

LLVM IR (-O2):
define i32 @scrypt_le16dec(i8* nocapture %0) {
%2 = bitcast i8* %0 to i64*
%3 = load i64, i64* %2
%4 = trunc i64 %3 to i32
%5 = getelementptr inbounds i8, i8* %0, i64 8
%6 = bitcast i8* %5 to i64*
%7 = load i64, i64* %6
%8 = trunc i64 %7 to i32
%9 = shl i32 %8, 8
%10 = add nsw i32 %9, %4
ret i32 %10
}