xunge/DecIR huggingface dataset:
/* Variables and functions */
int /*<<< orphan*/ printf(char *, ...);
void usage(char *prog) {
  printf("Convert gdal_contour generated dbf to JOSM import ready dbf.by "
         "jjm2473\n\n");
  printf("Usage: %s [<options>] <srcfile> <destfile>\n", prog);
  printf("The options are:\n"
         "\t-l: print log\n"
         "\t-i <Major> <Medium>: Contour level interval,default value is 100 "
         "50\n");
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
lea    0xedd(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x8(%rbp),%rsi
lea    0xf14(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf32(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<usage>:
push   %rbx
mov    %rdi,%rbx
lea    0xf01(%rip),%rdi
call   1030 <puts@plt>
lea    0xec9(%rip),%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xf2c(%rip),%rdi
pop    %rbx
jmp    1030 <puts@plt>

LLVM IR (-O0):
@.str = [73 x i8] c"Convert gdal_contour generated dbf to JOSM import ready dbf.by jjm2473\0A\0A\00"
@.str.1 = [44 x i8] c"Usage: %s [<options>] <srcfile> <destfile>\0A\00"
@.str.2 = [102 x i8] c"The options are:\0A\09-l: print log\0A\09-i <Major> <Medium>: Contour level interval,default value is 100 50\0A\00"
define void @usage(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([73 x i8], [73 x i8]* @.str, i64 0, i64 0))
%4 = load i8*, i8** %2
%5 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([44 x i8], [44 x i8]* @.str.1, i64 0, i64 0), i8* %4)
%6 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([102 x i8], [102 x i8]* @.str.2, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str.1 = [44 x i8] c"Usage: %s [<options>] <srcfile> <destfile>\0A\00"
@str = [72 x i8] c"Convert gdal_contour generated dbf to JOSM import ready dbf.by jjm2473\0A\00"
@str.3 = [101 x i8] c"The options are:\0A\09-l: print log\0A\09-i <Major> <Medium>: Contour level interval,default value is 100 50\00"
define void @usage(i8* %0) {
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([72 x i8], [72 x i8]* @str, i64 0, i64 0))
%3 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([44 x i8], [44 x i8]* @.str.1, i64 0, i64 0), i8* %0)
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([101 x i8], [101 x i8]* @str.3, i64 0, i64 0))
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
int /*<<< orphan*/ fprintf(int /*<<< orphan*/ *, char *, ...);
int /*<<< orphan*/ om_html_entities(int /*<<< orphan*/ *, char *);
void om_html_print_report_link(FILE *fp, char *report) {
  fprintf(fp,
          "<tr><td align=\"left\" class=\"reportlink\" colspan=\"3\"><a "
          "href=\"#%s\">",
          report);
  om_html_entities(fp, report);
  fprintf(fp, "</a></td></tr>\n");
  return;
}


x86 assembly (clang, -O0):
<om_html_print_report_link>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rdx
lea    0xec1(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1040 <om_html_entities@plt>
mov    -0x8(%rbp),%rdi
lea    0xee5(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<om_html_print_report_link>:
push   %r14
push   %rbx
push   %rax
mov    %rsi,%r14
mov    %rdi,%rbx
lea    0xebf(%rip),%rsi
mov    %r14,%rdx
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    %rbx,%rdi
mov    %r14,%rsi
call   1040 <om_html_entities@plt>
lea    0xee6(%rip),%rdi
mov    $0xf,%esi
mov    $0x1,%edx
mov    %rbx,%rcx
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1050 <fwrite@plt>

LLVM IR (-O0):
@.str = [67 x i8] c"<tr><td align=\22left\22 class=\22reportlink\22 colspan=\223\22><a href=\22#%s\22>\00"
@.str.1 = [16 x i8] c"</a></td></tr>\0A\00"
define void @om_html_print_report_link(i32* %0, i8* %1) {
%3 = alloca i32*
%4 = alloca i8*
store i32* %0, i32** %3
store i8* %1, i8** %4
%5 = load i32*, i32** %3
%6 = load i8*, i8** %4
%7 = call i32 (i32*, i8*, ...) @fprintf(i32* %5, i8* getelementptr inbounds ([67 x i8], [67 x i8]* @.str, i64 0, i64 0), i8* %6)
%8 = load i32*, i32** %3
%9 = load i8*, i8** %4
%10 = call i32 @om_html_entities(i32* %8, i8* %9)
%11 = load i32*, i32** %3
%12 = call i32 (i32*, i8*, ...) @fprintf(i32* %11, i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [67 x i8] c"<tr><td align=\22left\22 class=\22reportlink\22 colspan=\223\22><a href=\22#%s\22>\00"
@.str.1 = [16 x i8] c"</a></td></tr>\0A\00"
define void @om_html_print_report_link(i32* %0, i8* %1) {
%3 = tail call i32 (i32*, i8*, ...) @fprintf(i32* %0, i8* getelementptr inbounds ([67 x i8], [67 x i8]* @.str, i64 0, i64 0), i8* %1)
%4 = tail call i32 @om_html_entities(i32* %0, i8* %1)
%5 = tail call i64 @fwrite(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.1, i64 0, i64 0), i64 15, i64 1, i32* %0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ SYS_gettid;
int /*<<< orphan*/ printf(char *, unsigned int);
int /*<<< orphan*/ pthread_exit(int /*<<< orphan*/ *);
scalar_t__ syscall(int /*<<< orphan*/);
void *identify(void *nothing) {
  (void)nothing;
  printf("I am %d\n", (unsigned)syscall(SYS_gettid));
  pthread_exit(NULL);
}


x86 assembly (clang, -O0):
<identify>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x10(%rbp)
mov    0x2ea5(%rip),%rax
mov    (%rax),%edi
call   1040 <syscall@plt>
mov    %eax,%esi
lea    0xead(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
mov    %eax,%edi
call   1050 <pthread_exit@plt>
mov    -0x8(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<identify>:
push   %rax
mov    0x2eb0(%rip),%rax
mov    (%rax),%edi
call   1040 <syscall@plt>
lea    0xeba(%rip),%rdi
mov    %eax,%esi
call   1030 <printf@plt>
xor    %edi,%edi
pop    %rax
jmp    1050 <pthread_exit@plt>

LLVM IR (-O0):
@.str = [9 x i8] c"I am %d\0A\00"
@SYS_gettid = global i32 0
define i8* @identify(i8* %0) {
%2 = alloca i8*
%3 = alloca i8*
store i8* %0, i8** %3
%4 = load i8*, i8** %3
%5 = load i32, i32* @SYS_gettid
%6 = call i64 @syscall(i32 %5)
%7 = trunc i64 %6 to i32
%8 = call i32 @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i32 %7)
%9 = call i32 @pthread_exit(i32* null)
%10 = load i8*, i8** %2
ret i8* %10
}

LLVM IR (-O2):
@.str = [9 x i8] c"I am %d\0A\00"
@SYS_gettid = global i32 0
define noalias i8* @identify(i8* nocapture readnone %0) {
%2 = load i32, i32* @SYS_gettid
%3 = tail call i64 @syscall(i32 %2)
%4 = trunc i64 %3 to i32
%5 = tail call i32 @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i32 %4)
%6 = tail call i32 @pthread_exit(i32* null)
ret i8* undef
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
void stop() { printf("\nStop(): \n"); }


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

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

LLVM IR (-O0):
@.str = [11 x i8] c"\0AStop(): \0A\00"
define void @stop() {
%1 = call i32 @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@str = [10 x i8] c"\0AStop(): \00"
define void @stop() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @str, i64 0, i64 0))
ret void
}
/* Type definitions */
struct name_ent {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ kfree(struct name_ent *);
void name_put(struct name_ent *ent) { kfree(ent); }


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

x86 assembly (clang, -O2):
<name_put>:
jmp    1030 <kfree@plt>

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

LLVM IR (-O2):
%struct.name_ent = type { i32 }
define void @name_put(%struct.name_ent* %0) {
%2 = tail call i32 @kfree(%struct.name_ent* %0)
ret void
}
void f(void) {
  int a;
  a = sizeof(int);
}


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

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

LLVM IR (-O0):
define void @f() {
%1 = alloca i32
store i32 4, i32* %1
ret void
}

LLVM IR (-O2):
define void @f() {
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
int EOF;
int fgetc(int /*<<< orphan*/ *);
int checkbin(FILE *f) {
  int c;
  while (1) {
    c = fgetc(f);
    if (c == EOF) {
      return 0;
    } else if (c == '\n') {
      return 0;
    } else if (c == '\r') {
      return 1;
    }
  }
}


x86 assembly (clang, -O0):
<checkbin>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
call   1030 <fgetc@plt>
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%eax
mov    0x2eb6(%rip),%rcx
cmp    (%rcx),%eax
jne    1146 <checkbin+0x36>
movl   $0x0,-0x4(%rbp)
jmp    1181 <checkbin+0x71>
cmpl   $0xa,-0x14(%rbp)
jne    115c <checkbin+0x4c>
movl   $0x0,-0x4(%rbp)
jmp    1181 <checkbin+0x71>
cmpl   $0xd,-0x14(%rbp)
jne    1172 <checkbin+0x62>
movl   $0x1,-0x4(%rbp)
jmp    1181 <checkbin+0x71>
jmp    1177 <checkbin+0x67>
jmp    117c <checkbin+0x6c>
jmp    111c <checkbin+0xc>
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<checkbin>:
push   %r14
push   %rbx
push   %rax
mov    %rdi,%rbx
mov    0x2eca(%rip),%r14
xchg   %ax,%ax
mov    %rbx,%rdi
call   1030 <fgetc@plt>
mov    %eax,%ecx
xor    %eax,%eax
cmp    (%r14),%ecx
je     1140 <checkbin+0x30>
cmp    $0xa,%ecx
je     1140 <checkbin+0x30>
cmp    $0xd,%ecx
jne    1120 <checkbin+0x10>
mov    $0x1,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
@EOF = global i32 0
define i32 @checkbin(i32* %0) {
%2 = alloca i32
%3 = alloca i32*
%4 = alloca i32
store i32* %0, i32** %3
br label %5
5: ; preds = %1, %22
%6 = load i32*, i32** %3
%7 = call i32 @fgetc(i32* %6)
store i32 %7, i32* %4
%8 = load i32, i32* %4
%9 = load i32, i32* @EOF
%10 = icmp eq i32 %8, %9
br i1 %10, label %11, label %12
11: ; preds = %5
store i32 0, i32* %2
br label %23
12: ; preds = %5
%13 = load i32, i32* %4
%14 = icmp eq i32 %13, 10
br i1 %14, label %15, label %16
15: ; preds = %12
store i32 0, i32* %2
br label %23
16: ; preds = %12
%17 = load i32, i32* %4
%18 = icmp eq i32 %17, 13
br i1 %18, label %19, label %20
19: ; preds = %16
store i32 1, i32* %2
br label %23
20: ; preds = %16
br label %21
21: ; preds = %20
br label %22
22: ; preds = %21
br label %5
23: ; preds = %19, %15, %11
%24 = load i32, i32* %2
ret i32 %24
}

LLVM IR (-O2):
@EOF = global i32 0
define i32 @checkbin(i32* nocapture %0) {
br label %2
2: ; preds = %6, %1
%3 = tail call i32 @fgetc(i32* %0)
%4 = load i32, i32* @EOF
%5 = icmp eq i32 %3, %4
br i1 %5, label %7, label %6
6: ; preds = %2
switch i32 %3, label %2 [
i32 10, label %7
i32 13, label %8
]
7: ; preds = %2, %6
br label %8
8: ; preds = %6, %7
%9 = phi i32 [ 0, %7 ], [ 1, %6 ]
ret i32 %9
}
/* Variables and functions */
float plogisticf(float);
float dlogisticf(float x) {
  const float p = plogisticf(x);
  return p * (1.0f - p);
}


x86 assembly (clang, -O0):
<dlogisticf>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
call   1030 <plogisticf@plt>
movss  %xmm0,-0x8(%rbp)
movss  -0x8(%rbp),%xmm0
movss  0xec7(%rip),%xmm1
subss  -0x8(%rbp),%xmm1
mulss  %xmm1,%xmm0
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<dlogisticf>:
push   %rax
call   1030 <plogisticf@plt>
movss  0xee2(%rip),%xmm1
subss  %xmm0,%xmm1
mulss  %xmm1,%xmm0
pop    %rax
ret

LLVM IR (-O0):
define float @dlogisticf(float %0) {
%2 = alloca float
%3 = alloca float
store float %0, float* %2
%4 = load float, float* %2
%5 = call float @plogisticf(float %4)
store float %5, float* %3
%6 = load float, float* %3
%7 = load float, float* %3
%8 = fsub float 1.000000e+00, %7
%9 = fmul float %6, %8
ret float %9
}

LLVM IR (-O2):
define float @dlogisticf(float %0) {
%2 = tail call float @plogisticf(float %0)
%3 = fsub float 1.000000e+00, %2
%4 = fmul float %2, %3
ret float %4
}
/* Variables and functions */
int /*<<< orphan*/ noroom();
char *realloc(char *, size_t);
char *ralloc(char *p, size_t n) {
  char *q = realloc(p, n);
  if (q == NULL)
    noroom();
  return (q);
}


x86 assembly (clang, -O0):
<ralloc>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1040 <realloc@plt>
mov    %rax,-0x18(%rbp)
cmpq   $0x0,-0x18(%rbp)
jne    1153 <ralloc+0x33>
mov    $0x0,%al
call   1030 <noroom@plt>
mov    -0x18(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ralloc>:
push   %rbx
call   1040 <realloc@plt>
mov    %rax,%rbx
test   %rax,%rax
jne    1135 <ralloc+0x15>
xor    %eax,%eax
call   1030 <noroom@plt>
mov    %rbx,%rax
pop    %rbx
ret

LLVM IR (-O0):
define i8* @ralloc(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 i8*, i8** %3
%7 = load i64, i64* %4
%8 = call i8* @realloc(i8* %6, i64 %7)
store i8* %8, i8** %5
%9 = load i8*, i8** %5
%10 = icmp eq i8* %9, null
br i1 %10, label %11, label %13
11: ; preds = %2
%12 = call i32 (...) @noroom()
br label %13
13: ; preds = %11, %2
%14 = load i8*, i8** %5
ret i8* %14
}

LLVM IR (-O2):
define noalias i8* @ralloc(i8* nocapture %0, i64 %1) {
%3 = tail call i8* @realloc(i8* %0, i64 %1)
%4 = icmp eq i8* %3, null
br i1 %4, label %5, label %7
5: ; preds = %2
%6 = tail call i32 (...) @noroom()
br label %7
7: ; preds = %5, %2
ret i8* %3
}
/* Variables and functions */
int rom_present(char *);
int tgui9440_available() { return rom_present("9440.vbi"); }


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

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

LLVM IR (-O0):
@.str = [9 x i8] c"9440.vbi\00"
define i32 @tgui9440_available() {
%1 = call i32 @rom_present(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0))
ret i32 %1
}

LLVM IR (-O2):
@.str = [9 x i8] c"9440.vbi\00"
define i32 @tgui9440_available() {
%1 = tail call i32 @rom_present(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0))
ret i32 %1
}
int putch(int Ch) { return (Ch); }


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

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

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

LLVM IR (-O2):
define i32 @putch(i32 returned %0) {
ret i32 %0
}
int s_socket_bsd_uninit(void) { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @s_socket_bsd_uninit() {
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ printError(char *);
int /*<<< orphan*/ printErrors(char *, int);
int main() {
  printError("This message is from the main() function.");
  printErrors("This is displays several of the same message.", 4);
  return 0;
}


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

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xed8(%rip),%rdi
call   1040 <printError@plt>
lea    0xef6(%rip),%rdi
mov    $0x4,%esi
call   1030 <printErrors@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [42 x i8] c"This message is from the main() function.\00"
@.str.1 = [46 x i8] c"This is displays several of the same message.\00"
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = call i32 @printError(i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str, i64 0, i64 0))
%3 = call i32 @printErrors(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.1, i64 0, i64 0), i32 4)
ret i32 0
}

LLVM IR (-O2):
@.str = [42 x i8] c"This message is from the main() function.\00"
@.str.1 = [46 x i8] c"This is displays several of the same message.\00"
define i32 @main() {
%1 = tail call i32 @printError(i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 @printErrors(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.1, i64 0, i64 0), i32 4)
ret i32 0
}
void g_int_hash() {}


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

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

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

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


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

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

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

LLVM IR (-O2):
define void @tsx_init() {
ret void
}
int plip_none(struct net_device *dev, struct net_local *nl,
              struct plip_local *snd, struct plip_local *rcv) {
  { return (0); }
}


x86 assembly (clang, -O0):
<plip_none>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
xor    %eax,%eax
pop    %rbp
ret

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

LLVM IR (-O0):
%struct.net_device = type opaque
%struct.net_local = type opaque
%struct.plip_local = type opaque
define i32 @plip_none(%struct.net_device* %0, %struct.net_local* %1, %struct.plip_local* %2, %struct.plip_local* %3) {
%5 = alloca %struct.net_device*
%6 = alloca %struct.net_local*
%7 = alloca %struct.plip_local*
%8 = alloca %struct.plip_local*
store %struct.net_device* %0, %struct.net_device** %5
store %struct.net_local* %1, %struct.net_local** %6
store %struct.plip_local* %2, %struct.plip_local** %7
store %struct.plip_local* %3, %struct.plip_local** %8
ret i32 0
}

LLVM IR (-O2):
%struct.net_device = type opaque
%struct.net_local = type opaque
%struct.plip_local = type opaque
define i32 @plip_none(%struct.net_device* nocapture readnone %0, %struct.net_local* nocapture readnone %1, %struct.plip_local* nocapture readnone %2, %struct.plip_local* nocapture readnone %3) {
ret i32 0
}
int emac1_ifoutbroadcastpkts_set(unsigned int dev_id,
                                 union emac1_ifoutbroadcastpkts_u *value) {
  return 1;
}


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

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

LLVM IR (-O0):
%union.emac1_ifoutbroadcastpkts_u = type opaque
define i32 @emac1_ifoutbroadcastpkts_set(i32 %0, %union.emac1_ifoutbroadcastpkts_u* %1) {
%3 = alloca i32
%4 = alloca %union.emac1_ifoutbroadcastpkts_u*
store i32 %0, i32* %3
store %union.emac1_ifoutbroadcastpkts_u* %1, %union.emac1_ifoutbroadcastpkts_u** %4
ret i32 1
}

LLVM IR (-O2):
%union.emac1_ifoutbroadcastpkts_u = type opaque
define i32 @emac1_ifoutbroadcastpkts_set(i32 %0, %union.emac1_ifoutbroadcastpkts_u* nocapture readnone %1) {
ret i32 1
}
/* Variables and functions */
int errno;
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, char *, char *, int);
int /*<<< orphan*/ stderr;
char *strerror(int);
void warn(char *str) {
  int saved_errno = errno;
  fprintf(stderr, "WARN: %s (%s, %i)\n", str, strerror(saved_errno),
          saved_errno);
}


x86 assembly (clang, -O0):
<warn>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    0x2ea5(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0xc(%rbp)
mov    0x2ea1(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x1c(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    -0xc(%rbp),%edi
call   1040 <strerror@plt>
mov    -0x1c(%rbp),%edi
mov    -0x18(%rbp),%rdx
mov    %rax,%rcx
mov    -0xc(%rbp),%r8d
lea    0xe97(%rip),%rsi
call   1030 <fprintf@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<warn>:
push   %rbp
push   %r14
push   %rbx
mov    %rdi,%r14
mov    0x2eaa(%rip),%rax
mov    (%rax),%ebp
mov    0x2ea9(%rip),%rax
mov    (%rax),%ebx
mov    %ebp,%edi
call   1040 <strerror@plt>
lea    0xeb9(%rip),%rsi
mov    %ebx,%edi
mov    %r14,%rdx
mov    %rax,%rcx
mov    %ebp,%r8d
pop    %rbx
pop    %r14
pop    %rbp
jmp    1030 <fprintf@plt>

LLVM IR (-O0):
@errno = global i32 0
@stderr = global i32 0
@.str = [19 x i8] c"WARN: %s (%s, %i)\0A\00"
define void @warn(i8* %0) {
%2 = alloca i8*
%3 = alloca i32
store i8* %0, i8** %2
%4 = load i32, i32* @errno
store i32 %4, i32* %3
%5 = load i32, i32* @stderr
%6 = load i8*, i8** %2
%7 = load i32, i32* %3
%8 = call i8* @strerror(i32 %7)
%9 = load i32, i32* %3
%10 = call i32 @fprintf(i32 %5, i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0), i8* %6, i8* %8, i32 %9)
ret void
}

LLVM IR (-O2):
@errno = global i32 0
@stderr = global i32 0
@.str = [19 x i8] c"WARN: %s (%s, %i)\0A\00"
define void @warn(i8* %0) {
%2 = load i32, i32* @errno
%3 = load i32, i32* @stderr
%4 = tail call i8* @strerror(i32 %2)
%5 = tail call i32 @fprintf(i32 %3, i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0), i8* %0, i8* %4, i32 %2)
ret void
}
void fa15(void) {
P0A:
  goto P0A;
  ({
    p01A:
      goto p01A;
      goto a;
    a:
      ({
        P012A:
          goto P012A;
          0;
      });
    P01B:
      goto P01B;
      ({
        P013A:
          goto P013A;
          0;
      });
    P01C:
      goto P01C;
      0;
  });
P0B:
  goto P0B;
  ({
    P02A:
      goto P02A;
      ({
        P024A:
          goto P024A;
          0;
      });
    P02B:
      goto P02B;
      ({
        P025A:
          goto P025A;
          0;
      });
    P02C:
      goto P02C;
      0;
  });
P0C:
  goto P0C;
  0;
P0D:
  goto P0D;
}


x86 assembly (clang, -O0):
<fa15>:
push   %rbp
mov    %rsp,%rbp
jmp    1104 <fa15+0x4>

x86 assembly (clang, -O2):
<fa15>:
jmp    1100 <fa15>

LLVM IR (-O0):
define void @fa15() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
br label %7
7: ; preds = %7, %0
br label %7
8: ; No predecessors!
br label %9
9: ; preds = %9, %8
br label %9
10: ; No predecessors!
br label %11
11: ; preds = %11, %10
br label %11
12: ; preds = %12
br label %12
13: ; No predecessors!
br label %14
14: ; preds = %14, %13
br label %14
15: ; preds = %15
br label %15
16: ; preds = %16
br label %16
17: ; No predecessors!
br label %18
18: ; preds = %18, %17
br label %18
19: ; No predecessors!
br label %20
20: ; preds = %20, %19
br label %20
21: ; preds = %21
br label %21
22: ; No predecessors!
br label %23
23: ; preds = %23, %22
br label %23
24: ; preds = %24
br label %24
25: ; preds = %25
br label %25
26: ; preds = %26
br label %26
}

LLVM IR (-O2):
define void @fa15() {
br label %1
1: ; preds = %1, %0
br label %1
}
/* Variables and functions */
char *min_str(char *, char *);
int min_str_3(char *_0, char *_1, char *_2) {
  return (min_str(_0, _1) == _0 ? (min_str(_0, _2) == _0 ? 0 : 2)
                                : (min_str(_1, _2) == _1 ? 1 : 2));
}


x86 assembly (clang, -O0):
<min_str_3>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1030 <min_str@plt>
cmp    -0x8(%rbp),%rax
jne    1164 <min_str_3+0x54>
mov    -0x8(%rbp),%rdi
mov    -0x18(%rbp),%rsi
call   1030 <min_str@plt>
mov    %rax,%rdx
mov    -0x8(%rbp),%rsi
mov    $0x2,%eax
xor    %ecx,%ecx
cmp    %rsi,%rdx
cmove  %ecx,%eax
mov    %eax,-0x1c(%rbp)
jmp    118b <min_str_3+0x7b>
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
call   1030 <min_str@plt>
mov    %rax,%rdx
mov    -0x10(%rbp),%rsi
mov    $0x2,%eax
mov    $0x1,%ecx
cmp    %rsi,%rdx
cmove  %ecx,%eax
mov    %eax,-0x1c(%rbp)
mov    -0x1c(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<min_str_3>:
push   %rbp
push   %r15
push   %r14
push   %rbx
push   %rax
mov    %rdx,%r14
mov    %rsi,%rbx
mov    %rdi,%r15
call   1030 <min_str@plt>
xor    %ebp,%ebp
cmp    %r15,%rax
setne  %bpl
cmove  %r15,%rbx
mov    %rbx,%rdi
mov    %r14,%rsi
call   1030 <min_str@plt>
cmp    %rbx,%rax
mov    $0x2,%eax
cmove  %ebp,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
define i32 @min_str_3(i8* %0, i8* %1, i8* %2) {
%4 = alloca i8*
%5 = alloca i8*
%6 = alloca i8*
store i8* %0, i8** %4
store i8* %1, i8** %5
store i8* %2, i8** %6
%7 = load i8*, i8** %4
%8 = load i8*, i8** %5
%9 = call i8* @min_str(i8* %7, i8* %8)
%10 = load i8*, i8** %4
%11 = icmp eq i8* %9, %10
br i1 %11, label %12, label %20
12: ; preds = %3
%13 = load i8*, i8** %4
%14 = load i8*, i8** %6
%15 = call i8* @min_str(i8* %13, i8* %14)
%16 = load i8*, i8** %4
%17 = icmp eq i8* %15, %16
%18 = zext i1 %17 to i64
%19 = select i1 %17, i32 0, i32 2
br label %28
20: ; preds = %3
%21 = load i8*, i8** %5
%22 = load i8*, i8** %6
%23 = call i8* @min_str(i8* %21, i8* %22)
%24 = load i8*, i8** %5
%25 = icmp eq i8* %23, %24
%26 = zext i1 %25 to i64
%27 = select i1 %25, i32 1, i32 2
br label %28
28: ; preds = %20, %12
%29 = phi i32 [ %19, %12 ], [ %27, %20 ]
ret i32 %29
}

LLVM IR (-O2):
define i32 @min_str_3(i8* %0, i8* %1, i8* %2) {
%4 = tail call i8* @min_str(i8* %0, i8* %1)
%5 = icmp eq i8* %4, %0
%6 = select i1 %5, i8* %0, i8* %1
%7 = xor i1 %5, true
%8 = zext i1 %7 to i32
%9 = tail call i8* @min_str(i8* %6, i8* %2)
%10 = icmp eq i8* %9, %6
%11 = select i1 %10, i32 %8, i32 2
ret i32 %11
}
void _gfortran_caf_sync_all(int *stat, char *errmsg __attribute__((unused)),
                            int errmsg_len __attribute__((unused))) {
  if (stat)
    *stat = 0;
}


x86 assembly (clang, -O0):
<_gfortran_caf_sync_all>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
cmpq   $0x0,-0x8(%rbp)
je     1124 <_gfortran_caf_sync_all+0x24>
mov    -0x8(%rbp),%rax
movl   $0x0,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<_gfortran_caf_sync_all>:
test   %rdi,%rdi
je     110b <_gfortran_caf_sync_all+0xb>
movl   $0x0,(%rdi)
ret

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

LLVM IR (-O2):
define void @_gfortran_caf_sync_all(i32* writeonly %0, i8* nocapture readnone %1, i32 %2) {
%4 = icmp eq i32* %0, null
br i1 %4, label %6, label %5
5: ; preds = %3
store i32 0, i32* %0
br label %6
6: ; preds = %5, %3
ret void
}
/* Variables and functions */
char *basename_get_base_name(char *, int /*<<< orphan*/);
char *basename_get_filename(char *argv_0) {
  return basename_get_base_name(argv_0, 0);
}


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

x86 assembly (clang, -O2):
<basename_get_filename>:
xor    %esi,%esi
jmp    1030 <basename_get_base_name@plt>

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

LLVM IR (-O2):
define i8* @basename_get_filename(i8* %0) {
%2 = tail call i8* @basename_get_base_name(i8* %0, i32 0)
ret i8* %2
}
void g_string_insert_unichar() {}


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

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

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

LLVM IR (-O2):
define void @g_string_insert_unichar() {
ret void
}
long double dotProduct(long double *m1, long double *m2) {
  long double dprod;
  dprod = m1[0] * m2[0] + m1[1] * m2[1] + m1[2] * m2[2];
  return dprod;
}


x86 assembly (clang, -O0):
<dotProduct>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rcx
fldt   (%rcx)
mov    -0x10(%rbp),%rax
fldt   (%rax)
fldt   0x10(%rcx)
fldt   0x10(%rax)
fmulp  %st,%st(1)
fxch   %st(2)
fmulp  %st,%st(1)
faddp  %st,%st(1)
fldt   0x20(%rcx)
fldt   0x20(%rax)
fmulp  %st,%st(1)
faddp  %st,%st(1)
fstpt  -0x20(%rbp)
fldt   -0x20(%rbp)
pop    %rbp
ret

x86 assembly (clang, -O2):
<dotProduct>:
fldt   (%rdi)
fldt   (%rsi)
fmulp  %st,%st(1)
fldt   0x10(%rdi)
fldt   0x10(%rsi)
fmulp  %st,%st(1)
faddp  %st,%st(1)
fldt   0x20(%rdi)
fldt   0x20(%rsi)
fmulp  %st,%st(1)
faddp  %st,%st(1)
ret

LLVM IR (-O0):
define x86_fp80 @dotProduct(x86_fp80* %0, x86_fp80* %1) {
%3 = alloca x86_fp80*
%4 = alloca x86_fp80*
%5 = alloca x86_fp80
store x86_fp80* %0, x86_fp80** %3
store x86_fp80* %1, x86_fp80** %4
%6 = load x86_fp80*, x86_fp80** %3
%7 = getelementptr inbounds x86_fp80, x86_fp80* %6, i64 0
%8 = load x86_fp80, x86_fp80* %7
%9 = load x86_fp80*, x86_fp80** %4
%10 = getelementptr inbounds x86_fp80, x86_fp80* %9, i64 0
%11 = load x86_fp80, x86_fp80* %10
%12 = load x86_fp80*, x86_fp80** %3
%13 = getelementptr inbounds x86_fp80, x86_fp80* %12, i64 1
%14 = load x86_fp80, x86_fp80* %13
%15 = load x86_fp80*, x86_fp80** %4
%16 = getelementptr inbounds x86_fp80, x86_fp80* %15, i64 1
%17 = load x86_fp80, x86_fp80* %16
%18 = fmul x86_fp80 %14, %17
%19 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %8, x86_fp80 %11, x86_fp80 %18)
%20 = load x86_fp80*, x86_fp80** %3
%21 = getelementptr inbounds x86_fp80, x86_fp80* %20, i64 2
%22 = load x86_fp80, x86_fp80* %21
%23 = load x86_fp80*, x86_fp80** %4
%24 = getelementptr inbounds x86_fp80, x86_fp80* %23, i64 2
%25 = load x86_fp80, x86_fp80* %24
%26 = call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %22, x86_fp80 %25, x86_fp80 %19)
store x86_fp80 %26, x86_fp80* %5
%27 = load x86_fp80, x86_fp80* %5
ret x86_fp80 %27
}

LLVM IR (-O2):
define x86_fp80 @dotProduct(x86_fp80* nocapture %0, x86_fp80* nocapture %1) {
%3 = load x86_fp80, x86_fp80* %0
%4 = load x86_fp80, x86_fp80* %1
%5 = getelementptr inbounds x86_fp80, x86_fp80* %0, i64 1
%6 = load x86_fp80, x86_fp80* %5
%7 = getelementptr inbounds x86_fp80, x86_fp80* %1, i64 1
%8 = load x86_fp80, x86_fp80* %7
%9 = fmul x86_fp80 %6, %8
%10 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %3, x86_fp80 %4, x86_fp80 %9)
%11 = getelementptr inbounds x86_fp80, x86_fp80* %0, i64 2
%12 = load x86_fp80, x86_fp80* %11
%13 = getelementptr inbounds x86_fp80, x86_fp80* %1, i64 2
%14 = load x86_fp80, x86_fp80* %13
%15 = tail call x86_fp80 @llvm.fmuladd.f80(x86_fp80 %12, x86_fp80 %14, x86_fp80 %10)
ret x86_fp80 %15
}
/* Forward declarations */
typedef struct TYPE_2__ TYPE_1__;

/* Type definitions */
struct TYPE_2__ {
  scalar_t__ same_screen;
};
typedef TYPE_1__ XKeyReleasedEvent;

/* Variables and functions */
int get_XKeyReleasedEvent_same_screen(void *_p) {
  return (int)((XKeyReleasedEvent *)_p)->same_screen;
}


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

x86 assembly (clang, -O2):
<get_XKeyReleasedEvent_same_screen>:
mov    (%rdi),%eax
ret

LLVM IR (-O0):
%struct.TYPE_2__ = type { i64 }
define i32 @get_XKeyReleasedEvent_same_screen(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = bitcast i8* %3 to %struct.TYPE_2__*
%5 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %4, i32 0, i32 0
%6 = load i64, i64* %5
%7 = trunc i64 %6 to i32
ret i32 %7
}

LLVM IR (-O2):
define i32 @get_XKeyReleasedEvent_same_screen(i8* nocapture %0) {
%2 = bitcast i8* %0 to i64*
%3 = load i64, i64* %2
%4 = trunc i64 %3 to i32
ret i32 %4
}
void SSMR3PutU64(void) {}


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

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

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

LLVM IR (-O2):
define void @SSMR3PutU64() {
ret void
}
/* Type definitions */
struct stat {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ _exit(int);
int _fstat(const char *path, struct stat *buf) {
  _exit(-1);
  return -1;
}


x86 assembly (clang, -O0):
<_fstat>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    $0xffffffff,%edi
call   1030 <_exit@plt>

x86 assembly (clang, -O2):
<_fstat>:
push   %rax
mov    $0xffffffff,%edi
call   1030 <_exit@plt>

LLVM IR (-O0):
%struct.stat = type { i32 }
define i32 @_fstat(i8* %0, %struct.stat* %1) {
%3 = alloca i8*
%4 = alloca %struct.stat*
store i8* %0, i8** %3
store %struct.stat* %1, %struct.stat** %4
%5 = call i32 @_exit(i32 -1)
unreachable
}

LLVM IR (-O2):
%struct.stat = type { i32 }
define i32 @_fstat(i8* nocapture readnone %0, %struct.stat* nocapture readnone %1) {
%3 = tail call i32 @_exit(i32 -1)
unreachable
}
/* Variables and functions */
int /*<<< orphan*/ msf_frame_to_msf(long, int *, int *, int *);
int /*<<< orphan*/ sprintf(char *, char *, int, int, int);
char *time_frame_to_mmssff(long f) {
  static char msf[9];
  int minutes, seconds, frames;
  msf_frame_to_msf(f, &minutes, &seconds, &frames);
  sprintf(msf, "%02d:%02d:%02d", minutes, seconds, frames);
  return msf;
}


x86 assembly (clang, -O0):
<time_frame_to_mmssff>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
lea    -0xc(%rbp),%rsi
lea    -0x10(%rbp),%rdx
lea    -0x14(%rbp),%rcx
call   1030 <msf_frame_to_msf@plt>
mov    -0xc(%rbp),%edx
mov    -0x10(%rbp),%ecx
mov    -0x14(%rbp),%r8d
lea    0x2edf(%rip),%rdi
lea    0xea7(%rip),%rsi
call   1040 <sprintf@plt>
lea    0x2ecc(%rip),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<time_frame_to_mmssff>:
push   %rbx
sub    $0x10,%rsp
lea    0xc(%rsp),%rsi
lea    0x8(%rsp),%rdx
lea    0x4(%rsp),%rcx
call   1030 <msf_frame_to_msf@plt>
mov    0xc(%rsp),%edx
mov    0x8(%rsp),%ecx
mov    0x4(%rsp),%r8d
lea    0x2ee4(%rip),%rbx
lea    0xeac(%rip),%rsi
mov    %rbx,%rdi
call   1040 <sprintf@plt>
mov    %rbx,%rax
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@time_frame_to_mmssff.msf = internal global [9 x i8] zeroinitializer
@.str = [15 x i8] c"%02d:%02d:%02d\00"
define i8* @time_frame_to_mmssff(i64 %0) {
%2 = alloca i64
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store i64 %0, i64* %2
%6 = load i64, i64* %2
%7 = call i32 @msf_frame_to_msf(i64 %6, i32* %3, i32* %4, i32* %5)
%8 = load i32, i32* %3
%9 = load i32, i32* %4
%10 = load i32, i32* %5
%11 = call i32 @sprintf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @time_frame_to_mmssff.msf, i64 0, i64 0), i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0), i32 %8, i32 %9, i32 %10)
ret i8* getelementptr inbounds ([9 x i8], [9 x i8]* @time_frame_to_mmssff.msf, i64 0, i64 0)
}

LLVM IR (-O2):
@time_frame_to_mmssff.msf = internal global [9 x i8] zeroinitializer
@.str = [15 x i8] c"%02d:%02d:%02d\00"
define i8* @time_frame_to_mmssff(i64 %0) {
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = bitcast i32* %2 to i8*
%6 = bitcast i32* %3 to i8*
%7 = bitcast i32* %4 to i8*
%8 = call i32 @msf_frame_to_msf(i64 %0, i32* %2, i32* %3, i32* %4)
%9 = load i32, i32* %2
%10 = load i32, i32* %3
%11 = load i32, i32* %4
%12 = call i32 @sprintf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @time_frame_to_mmssff.msf, i64 0, i64 0), i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0), i32 %9, i32 %10, i32 %11)
ret i8* getelementptr inbounds ([9 x i8], [9 x i8]* @time_frame_to_mmssff.msf, i64 0, i64 0)
}
/* Variables and functions */
int /*<<< orphan*/ foo(int *, int, int);
void good_bar_two(int i) {
  int buf[50];
  if (i <= 50)
    foo(buf, 50, i - 1);
}


x86 assembly (clang, -O0):
<good_bar_two>:
push   %rbp
mov    %rsp,%rbp
sub    $0xd0,%rsp
mov    %edi,-0x4(%rbp)
cmpl   $0x32,-0x4(%rbp)
jg     113f <good_bar_two+0x2f>
lea    -0xd0(%rbp),%rdi
mov    -0x4(%rbp),%edx
sub    $0x1,%edx
mov    $0x32,%esi
call   1030 <foo@plt>
add    $0xd0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<good_bar_two>:
cmp    $0x32,%edi
jg     1135 <good_bar_two+0x25>
sub    $0xc8,%rsp
mov    %edi,%edx
add    $0xffffffff,%edx
mov    %rsp,%rdi
mov    $0x32,%esi
call   1030 <foo@plt>
add    $0xc8,%rsp
ret

LLVM IR (-O0):
define void @good_bar_two(i32 %0) {
%2 = alloca i32
%3 = alloca [50 x i32]
store i32 %0, i32* %2
%4 = load i32, i32* %2
%5 = icmp sle i32 %4, 50
br i1 %5, label %6, label %11
6: ; preds = %1
%7 = getelementptr inbounds [50 x i32], [50 x i32]* %3, i64 0, i64 0
%8 = load i32, i32* %2
%9 = sub nsw i32 %8, 1
%10 = call i32 @foo(i32* %7, i32 50, i32 %9)
br label %11
11: ; preds = %6, %1
ret void
}

LLVM IR (-O2):
define void @good_bar_two(i32 %0) {
%2 = alloca [50 x i32]
%3 = bitcast [50 x i32]* %2 to i8*
%4 = icmp slt i32 %0, 51
br i1 %4, label %5, label %9
5: ; preds = %1
%6 = getelementptr inbounds [50 x i32], [50 x i32]* %2, i64 0, i64 0
%7 = add nsw i32 %0, -1
%8 = call i32 @foo(i32* %6, i32 50, i32 %7)
br label %9
9: ; preds = %5, %1
ret void
}
/* Type definitions */
typedef int uint64_t;
typedef int uint32_t;

/* Variables and functions */
void TimerLoadSet64(uint32_t ui32Base, uint64_t ui64Value) {
  ;
  (*((volatile uint32_t *)(ui32Base + 0x0000002C))) = ui64Value >> 32;
  (*((volatile uint32_t *)(ui32Base + 0x00000028))) = ui64Value & 0xffffffff;
}


x86 assembly (clang, -O0):
<TimerLoadSet64>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x8(%rbp),%eax
mov    $0x20,%ecx
sar    %cl,%eax
mov    %eax,%ecx
mov    -0x4(%rbp),%eax
add    $0x2c,%eax
cltq
mov    %ecx,(%rax)
mov    -0x8(%rbp),%ecx
and    $0xffffffff,%ecx
mov    -0x4(%rbp),%eax
add    $0x28,%eax
cltq
mov    %ecx,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<TimerLoadSet64>:
movslq %edi,%rax
mov    %esi,0x28(%rax)
ret

LLVM IR (-O0):
define void @TimerLoadSet64(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
store i32 %0, i32* %3
store i32 %1, i32* %4
%5 = load i32, i32* %4
%6 = ashr i32 %5, 32
%7 = load i32, i32* %3
%8 = add nsw i32 %7, 44
%9 = sext i32 %8 to i64
%10 = inttoptr i64 %9 to i32*
store volatile i32 %6, i32* %10
%11 = load i32, i32* %4
%12 = and i32 %11, -1
%13 = load i32, i32* %3
%14 = add nsw i32 %13, 40
%15 = sext i32 %14 to i64
%16 = inttoptr i64 %15 to i32*
store volatile i32 %12, i32* %16
ret void
}

LLVM IR (-O2):
define void @TimerLoadSet64(i32 %0, i32 %1) {
%3 = add nsw i32 %0, 44
%4 = sext i32 %3 to i64
%5 = inttoptr i64 %4 to i32*
store volatile i32 poison, i32* %5
%6 = add nsw i32 %0, 40
%7 = sext i32 %6 to i64
%8 = inttoptr i64 %7 to i32*
store volatile i32 %1, i32* %8
ret void
}
/* Type definitions */
struct nb_random {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ nb_random_close_file(struct nb_random *);
void nb_random_destroy(struct nb_random *random) {
  nb_random_close_file(random);
}


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

x86 assembly (clang, -O2):
<nb_random_destroy>:
jmp    1030 <nb_random_close_file@plt>

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

LLVM IR (-O2):
%struct.nb_random = type { i32 }
define void @nb_random_destroy(%struct.nb_random* %0) {
%2 = tail call i32 @nb_random_close_file(%struct.nb_random* %0)
ret void
}
/* Variables and functions */
int sqrt(int);
int is_prime(int number) {
  int factor;
  int maxlimit;
  maxlimit = sqrt(number);
  for (factor = 3; factor <= maxlimit; factor++) {
    if (number % factor != 0)
      continue;
    else
      return 0;
  }
  return 1;
}


x86 assembly (clang, -O0):
<is_prime>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x8(%rbp)
mov    -0x8(%rbp),%edi
call   1030 <sqrt@plt>
mov    %eax,-0x10(%rbp)
movl   $0x3,-0xc(%rbp)
mov    -0xc(%rbp),%eax
cmp    -0x10(%rbp),%eax
jg     1168 <is_prime+0x58>
mov    -0x8(%rbp),%eax
cltd
idivl  -0xc(%rbp)
cmp    $0x0,%edx
je     114e <is_prime+0x3e>
jmp    115a <is_prime+0x4a>
movl   $0x0,-0x4(%rbp)
jmp    116f <is_prime+0x5f>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    112d <is_prime+0x1d>
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_prime>:
push   %rbx
mov    %edi,%ebx
call   1030 <sqrt@plt>
mov    $0x1,%ecx
cmp    $0x3,%eax
jl     114f <is_prime+0x3f>
mov    %eax,%esi
neg    %esi
mov    $0x3,%edi
nopl   0x0(%rax,%rax,1)
mov    %ebx,%eax
cltd
idiv   %edi
test   %edx,%edx
je     114d <is_prime+0x3d>
lea    (%rsi,%rdi,1),%eax
add    $0x1,%eax
mov    %edi,%edx
add    $0x1,%edx
mov    %edx,%edi
cmp    $0x1,%eax
jne    1130 <is_prime+0x20>
jmp    114f <is_prime+0x3f>
xor    %ecx,%ecx
mov    %ecx,%eax
pop    %rbx
ret

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

LLVM IR (-O2):
define i32 @is_prime(i32 %0) {
%2 = tail call i32 @sqrt(i32 %0)
%3 = icmp slt i32 %2, 3
br i1 %3, label %11, label %7
4: ; preds = %7
%5 = add nuw i32 %8, 1
%6 = icmp eq i32 %8, %2
br i1 %6, label %11, label %7
7: ; preds = %1, %4
%8 = phi i32 [ %5, %4 ], [ 3, %1 ]
%9 = srem i32 %0, %8
%10 = icmp eq i32 %9, 0
br i1 %10, label %11, label %4
11: ; preds = %7, %4, %1
%12 = phi i32 [ 1, %1 ], [ 1, %4 ], [ 0, %7 ]
ret i32 %12
}
/* Variables and functions */
int /*<<< orphan*/ EXIT_SUCCESS;
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ separationTexte();
void quitter(void) {
  separationTexte();
  printf("Au revoir ! :)\n\n");
  exit(EXIT_SUCCESS);
}


x86 assembly (clang, -O0):
<quitter>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1040 <separationTexte@plt>
lea    0xebe(%rip),%rdi
call   1030 <printf@plt>
mov    0x2e92(%rip),%rax
mov    (%rax),%edi
call   1050 <exit@plt>

x86 assembly (clang, -O2):
<quitter>:
push   %rax
xor    %eax,%eax
call   1040 <separationTexte@plt>
lea    0xec1(%rip),%rdi
call   1030 <puts@plt>
mov    0x2e95(%rip),%rax
mov    (%rax),%edi
call   1050 <exit@plt>

LLVM IR (-O0):
@.str = [17 x i8] c"Au revoir ! :)\0A\0A\00"
@EXIT_SUCCESS = global i32 0
define void @quitter() {
%1 = call i32 (...) @separationTexte()
%2 = call i32 @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0))
%3 = load i32, i32* @EXIT_SUCCESS
%4 = call i32 @exit(i32 %3)
unreachable
}

LLVM IR (-O2):
@EXIT_SUCCESS = global i32 0
@str = [16 x i8] c"Au revoir ! :)\0A\00"
define void @quitter() {
%1 = tail call i32 (...) @separationTexte()
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @str, i64 0, i64 0))
%3 = load i32, i32* @EXIT_SUCCESS
%4 = tail call i32 @exit(i32 %3)
unreachable
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ isdigit(int);
void t_isdigit_0xf3() {
  Assert_real((isdigit(243) == 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_isdigit.c",
              1220, ("isdigit should be 0 for 0xf3"));
}


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

x86 assembly (clang, -O2):
<t_isdigit_0xf3>:
push   %rax
mov    $0xf3,%edi
call   1030 <isdigit@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
lea    0xec5(%rip),%rsi
lea    0xf66(%rip),%rcx
mov    $0x4c4,%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_isdigit.c\00"
@.str.1 = [29 x i8] c"isdigit should be 0 for 0xf3\00"
define void @t_isdigit_0xf3() {
%1 = call i64 @isdigit(i32 243)
%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 1220, i8* getelementptr inbounds ([29 x i8], [29 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_isdigit.c\00"
@.str.1 = [29 x i8] c"isdigit should be 0 for 0xf3\00"
define void @t_isdigit_0xf3() {
%1 = tail call i64 @isdigit(i32 243)
%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 1220, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ usleep(int);
void mySleep(int sleepMs) { usleep(sleepMs * 1000); }


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

x86 assembly (clang, -O2):
<mySleep>:
imul   $0x3e8,%edi,%edi
jmp    1030 <usleep@plt>

LLVM IR (-O0):
define void @mySleep(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = mul nsw i32 %3, 1000
%5 = call i32 @usleep(i32 %4)
ret void
}

LLVM IR (-O2):
define void @mySleep(i32 %0) {
%2 = mul nsw i32 %0, 1000
%3 = tail call i32 @usleep(i32 %2)
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ uint8_t;
typedef int /*<<< orphan*/ uint16_t;

/* Variables and functions */
int /*<<< orphan*/ read_word_data(int /*<<< orphan*/, int);
uint16_t get_bus_direction(uint8_t address) {
  return read_word_data(address, 0x00);
}


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

x86 assembly (clang, -O2):
<get_bus_direction>:
xor    %esi,%esi
jmp    1030 <read_word_data@plt>

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

LLVM IR (-O2):
define i32 @get_bus_direction(i32 %0) {
%2 = tail call i32 @read_word_data(i32 %0, i32 0)
ret i32 %2
}