xunge/DecIR huggingface dataset:
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
void usage() {
  printf("fft_mixed_radix_test -- test mixed-radix DFTs, compare to slow DFT "
         "method\n");
  printf("options (default values in []):\n");
  printf("  h     : print usage/help\n");
  printf("  n     : fft size\n");
}


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

x86 assembly (clang, -O2):
<usage>:
push   %rax
lea    0xee8(%rip),%rdi
call   1030 <puts@plt>
lea    0xf26(%rip),%rdi
call   1030 <puts@plt>
lea    0xf3a(%rip),%rdi
call   1030 <puts@plt>
lea    0xf49(%rip),%rdi
pop    %rax
jmp    1030 <puts@plt>

LLVM IR (-O0):
@.str = [75 x i8] c"fft_mixed_radix_test -- test mixed-radix DFTs, compare to slow DFT method\0A\00"
@.str.1 = [33 x i8] c"options (default values in []):\0A\00"
@.str.2 = [28 x i8] c" h : print usage/help\0A\00"
@.str.3 = [20 x i8] c" n : fft size\0A\00"
define void @usage() {
%1 = call i32 @printf(i8* getelementptr inbounds ([75 x i8], [75 x i8]* @.str, i64 0, i64 0))
%2 = call i32 @printf(i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.1, i64 0, i64 0))
%3 = call i32 @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.2, i64 0, i64 0))
%4 = call i32 @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.3, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@str = [74 x i8] c"fft_mixed_radix_test -- test mixed-radix DFTs, compare to slow DFT method\00"
@str.4 = [32 x i8] c"options (default values in []):\00"
@str.5 = [27 x i8] c" h : print usage/help\00"
@str.6 = [19 x i8] c" n : fft size\00"
define void @usage() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([74 x i8], [74 x i8]* @str, i64 0, i64 0))
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([32 x i8], [32 x i8]* @str.4, i64 0, i64 0))
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([27 x i8], [27 x i8]* @str.5, i64 0, i64 0))
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @str.6, i64 0, i64 0))
ret void
}
int main() {
  int cw = 0x033;
  __asm("fldcw %0" : : "m"(cw));
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
movl   $0x0,-0x4(%rbp)
movl   $0x33,-0x8(%rbp)
fldcw  -0x8(%rbp)
xor    %eax,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
movl   $0x33,-0x4(%rsp)
fldcw  -0x4(%rsp)
xor    %eax,%eax
ret

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

LLVM IR (-O2):
define i32 @main() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
store i32 51, i32* %1
ret i32 0
}
/* Variables and functions */
int _ada_use_c2phc4c(int, int *, int *, double *, int /*<<< orphan*/);
int sweep_set_standard_start(int n, double *c) {
  int fail, ptos[2];
  ptos[0] = 0;
  ptos[1] = 0;
  fail = _ada_use_c2phc4c(618, ptos, &n, c, 0);
  return fail;
}


x86 assembly (clang, -O0):
<sweep_set_standard_start>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
movl   $0x0,-0x1c(%rbp)
movl   $0x0,-0x18(%rbp)
lea    -0x1c(%rbp),%rsi
mov    -0x10(%rbp),%rcx
mov    $0x26a,%edi
lea    -0x4(%rbp),%rdx
xor    %r8d,%r8d
call   1030 <_ada_use_c2phc4c@plt>
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<sweep_set_standard_start>:
sub    $0x18,%rsp
mov    %rsi,%rcx
mov    %edi,0xc(%rsp)
movq   $0x0,0x10(%rsp)
lea    0x10(%rsp),%rsi
lea    0xc(%rsp),%rdx
mov    $0x26a,%edi
xor    %r8d,%r8d
call   1030 <_ada_use_c2phc4c@plt>
add    $0x18,%rsp
ret

LLVM IR (-O0):
define i32 @sweep_set_standard_start(i32 %0, double* %1) {
%3 = alloca i32
%4 = alloca double*
%5 = alloca i32
%6 = alloca [2 x i32]
store i32 %0, i32* %3
store double* %1, double** %4
%7 = getelementptr inbounds [2 x i32], [2 x i32]* %6, i64 0, i64 0
store i32 0, i32* %7
%8 = getelementptr inbounds [2 x i32], [2 x i32]* %6, i64 0, i64 1
store i32 0, i32* %8
%9 = getelementptr inbounds [2 x i32], [2 x i32]* %6, i64 0, i64 0
%10 = load double*, double** %4
%11 = call i32 @_ada_use_c2phc4c(i32 618, i32* %9, i32* %3, double* %10, i32 0)
store i32 %11, i32* %5
%12 = load i32, i32* %5
ret i32 %12
}

LLVM IR (-O2):
define i32 @sweep_set_standard_start(i32 %0, double* %1) {
%3 = alloca i32
%4 = alloca [2 x i32]
store i32 %0, i32* %3
%5 = bitcast [2 x i32]* %4 to i8*
%6 = getelementptr inbounds [2 x i32], [2 x i32]* %4, i64 0, i64 0
store i32 0, i32* %6
%7 = getelementptr inbounds [2 x i32], [2 x i32]* %4, i64 0, i64 1
store i32 0, i32* %7
%8 = call i32 @_ada_use_c2phc4c(i32 618, i32* %6, i32* %3, double* %1, i32 0)
ret i32 %8
}
/* Variables and functions */
int /*<<< orphan*/ EXIT_FAILURE;
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *);
int /*<<< orphan*/ stderr;
void help(void) {
  fprintf(stderr,
          "Usage: recreate_wsfile [-r] [-t] sec1 sec1_csum sec2 sec2_csum\n");
  exit(EXIT_FAILURE);
}


x86 assembly (clang, -O0):
<help>:
push   %rbp
mov    %rsp,%rbp
mov    0x2eb5(%rip),%rax
mov    (%rax),%edi
lea    0xecc(%rip),%rsi
call   1030 <fprintf@plt>
mov    0x2e98(%rip),%rax
mov    (%rax),%edi
call   1040 <exit@plt>

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

LLVM IR (-O0):
@stderr = global i32 0
@.str = [64 x i8] c"Usage: recreate_wsfile [-r] [-t] sec1 sec1_csum sec2 sec2_csum\0A\00"
@EXIT_FAILURE = global i32 0
define void @help() {
%1 = load i32, i32* @stderr
%2 = call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([64 x i8], [64 x i8]* @.str, i64 0, i64 0))
%3 = load i32, i32* @EXIT_FAILURE
%4 = call i32 @exit(i32 %3)
unreachable
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [64 x i8] c"Usage: recreate_wsfile [-r] [-t] sec1 sec1_csum sec2 sec2_csum\0A\00"
@EXIT_FAILURE = global i32 0
define void @help() {
%1 = load i32, i32* @stderr
%2 = tail call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([64 x i8], [64 x i8]* @.str, i64 0, i64 0))
%3 = load i32, i32* @EXIT_FAILURE
%4 = tail call i32 @exit(i32 %3)
unreachable
}
/* Variables and functions */
int /*<<< orphan*/ perm(char *, int);
int main() {
  char c[] = {'a', 'b', 'c', 'd'};
  perm(c, 4);
}


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

x86 assembly (clang, -O2):
<main>:
push   %rax
movl   $0x64636261,0x4(%rsp)
64
lea    0x4(%rsp),%rdi
mov    $0x4,%esi
call   1030 <perm@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@__const.main.c = [4 x i8] c"abcd"
define i32 @main() {
%1 = alloca [4 x i8]
%2 = bitcast [4 x i8]* %1 to i8*
%3 = getelementptr inbounds [4 x i8], [4 x i8]* %1, i64 0, i64 0
%4 = call i32 @perm(i8* %3, i32 4)
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
store i32 1684234849, i32* %1
%3 = call i32 @perm(i8* %2, i32 4)
ret i32 0
}
/* Variables and functions */
char *malloc(int);
int /*<<< orphan*/ snprintf(char *, int, char *, int);
char *itoa(int n) {
  char *buf = malloc(sizeof(char) * 100);
  snprintf(buf, 100, "%d", n);
  return buf;
}


x86 assembly (clang, -O0):
<itoa>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    $0x64,%edi
call   1040 <malloc@plt>
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
mov    -0x4(%rbp),%ecx
mov    $0x64,%esi
lea    0xeb4(%rip),%rdx
call   1030 <snprintf@plt>
mov    -0x10(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<itoa>:
push   %rbp
push   %rbx
push   %rax
mov    %edi,%ebp
mov    $0x64,%edi
call   1040 <malloc@plt>
mov    %rax,%rbx
lea    0xec7(%rip),%rdx
mov    %rax,%rdi
mov    $0x64,%esi
mov    %ebp,%ecx
call   1030 <snprintf@plt>
mov    %rbx,%rax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%d\00"
define i8* @itoa(i32 %0) {
%2 = alloca i32
%3 = alloca i8*
store i32 %0, i32* %2
%4 = call i8* @malloc(i32 100)
store i8* %4, i8** %3
%5 = load i8*, i8** %3
%6 = load i32, i32* %2
%7 = call i32 @snprintf(i8* %5, i32 100, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32 %6)
%8 = load i8*, i8** %3
ret i8* %8
}

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
define i8* @itoa(i32 %0) {
%2 = tail call dereferenceable_or_null(100) i8* @malloc(i32 100)
%3 = tail call i32 @snprintf(i8* %2, i32 100, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32 %0)
ret i8* %2
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, char, char *, char);
int /*<<< orphan*/ strcpy(char *, char *);
int main(void) {
  char foo;
  char buf[6];
  char bar;
  foo = 'a';
  bar = 'z';
  strcpy(buf, "hello");
  buf[-1] = 'X';
  printf("%c %s %c\n", foo, buf, bar);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
movb   $0x61,-0x5(%rbp)
movb   $0x7a,-0xc(%rbp)
lea    -0xb(%rbp),%rdi
lea    0xebe(%rip),%rsi
call   1030 <strcpy@plt>
movb   $0x58,-0xc(%rbp)
mov    -0x5(%rbp),%al
lea    -0xb(%rbp),%rdx
lea    0xead(%rip),%rdi
movsbl %al,%esi
movsbl -0xc(%rbp),%ecx
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x10,%rsp
lea    0xed4(%rip),%rsi
lea    0xa(%rsp),%rbx
mov    %rbx,%rdi
call   1030 <strcpy@plt>
movb   $0x58,0x9(%rsp)
lea    0xec1(%rip),%rdi
mov    $0x61,%esi
mov    %rbx,%rdx
mov    $0x7a,%ecx
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [6 x i8] c"hello\00"
@.str.1 = [10 x i8] c"%c %s %c\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i8
%3 = alloca [6 x i8]
%4 = alloca i8
store i32 0, i32* %1
store i8 97, i8* %2
store i8 122, i8* %4
%5 = getelementptr inbounds [6 x i8], [6 x i8]* %3, i64 0, i64 0
%6 = call i32 @strcpy(i8* %5, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
%7 = getelementptr inbounds [6 x i8], [6 x i8]* %3, i64 0, i64 -1
store i8 88, i8* %7
%8 = load i8, i8* %2
%9 = getelementptr inbounds [6 x i8], [6 x i8]* %3, i64 0, i64 0
%10 = load i8, i8* %4
%11 = call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i8 signext %8, i8* %9, i8 signext %10)
ret i32 0
}

LLVM IR (-O2):
@.str = [6 x i8] c"hello\00"
@.str.1 = [10 x i8] c"%c %s %c\0A\00"
define i32 @main() {
%1 = alloca [6 x i8]
%2 = getelementptr inbounds [6 x i8], [6 x i8]* %1, i64 0, i64 0
%3 = call i32 @strcpy(i8* %2, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
%4 = getelementptr inbounds [6 x i8], [6 x i8]* %1, i64 0, i64 -1
store i8 88, i8* %4
%5 = call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i8 signext 97, i8* %2, i8 signext 122)
ret i32 0
}
void interrupt_block() { asm("cli"); }


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

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

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

LLVM IR (-O2):
define void @interrupt_block() {
tail call void asm sideeffect "cli", "~{dirflag},~{fpsr},~{flags}"()
ret void
}
/* Variables and functions */
long rand();
int /*<<< orphan*/ srand(int /*<<< orphan*/);
int /*<<< orphan*/ time(int /*<<< orphan*/ *);
long lrand() {
  srand(time(NULL));
  if (sizeof(int) < sizeof(long))
    return (long)(rand() << (sizeof(int) * 7)) | rand();
  return rand();
}


x86 assembly (clang, -O0):
<lrand>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
xor    %eax,%eax
mov    %eax,%edi
call   1040 <time@plt>
mov    %eax,%edi
call   1030 <srand@plt>
mov    $0x0,%al
call   1050 <rand@plt>
shl    $0x1c,%rax
mov    %rax,-0x8(%rbp)
mov    $0x0,%al
call   1050 <rand@plt>
mov    %rax,%rcx
mov    -0x8(%rbp),%rax
or     %rcx,%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<lrand>:
push   %rbx
xor    %edi,%edi
call   1040 <time@plt>
mov    %eax,%edi
call   1030 <srand@plt>
xor    %eax,%eax
call   1050 <rand@plt>
mov    %rax,%rbx
shl    $0x1c,%rbx
xor    %eax,%eax
call   1050 <rand@plt>
or     %rbx,%rax
pop    %rbx
ret

LLVM IR (-O0):
define i64 @lrand() {
%1 = call i32 @time(i32* null)
%2 = call i32 @srand(i32 %1)
%3 = call i64 (...) @rand()
%4 = shl i64 %3, 28
%5 = call i64 (...) @rand()
%6 = or i64 %4, %5
ret i64 %6
}

LLVM IR (-O2):
define i64 @lrand() {
%1 = tail call i32 @time(i32* null)
%2 = tail call i32 @srand(i32 %1)
%3 = tail call i64 (...) @rand()
%4 = shl i64 %3, 28
%5 = tail call i64 (...) @rand()
%6 = or i64 %4, %5
ret i64 %6
}
/* Type definitions */
struct timeval {
  int tv_sec;
  int tv_usec;
};

/* Variables and functions */
int /*<<< orphan*/ gettimeofday(struct timeval *, int /*<<< orphan*/ *);
unsigned long long currentTimeInMilliseconds() {
  struct timeval tv;
  gettimeofday(&tv, NULL);
  return ((tv.tv_sec * 1000) + (tv.tv_usec / 1000));
}


x86 assembly (clang, -O0):
<currentTimeInMilliseconds>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
lea    -0x8(%rbp),%rdi
xor    %eax,%eax
mov    %eax,%esi
call   1030 <gettimeofday@plt>
imul   $0x3e8,-0x8(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0x4(%rbp),%eax
mov    $0x3e8,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0xc(%rbp),%eax
add    %ecx,%eax
cltq
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<currentTimeInMilliseconds>:
push   %rax
mov    %rsp,%rdi
xor    %esi,%esi
call   1030 <gettimeofday@plt>
movslq (%rsp),%rax
imul   $0x3e8,%rax,%rcx
movslq 0x4(%rsp),%rax
imul   $0x10624dd3,%rax,%rax
mov    %rax,%rdx
shr    $0x3f,%rdx
sar    $0x26,%rax
add    %edx,%eax
cltq
add    %rcx,%rax
pop    %rcx
ret

LLVM IR (-O0):
%struct.timeval = type { i32, i32 }
define i64 @currentTimeInMilliseconds() {
%1 = alloca %struct.timeval
%2 = call i32 @gettimeofday(%struct.timeval* %1, i32* null)
%3 = getelementptr inbounds %struct.timeval, %struct.timeval* %1, i32 0, i32 0
%4 = load i32, i32* %3
%5 = mul nsw i32 %4, 1000
%6 = getelementptr inbounds %struct.timeval, %struct.timeval* %1, i32 0, i32 1
%7 = load i32, i32* %6
%8 = sdiv i32 %7, 1000
%9 = add nsw i32 %5, %8
%10 = sext i32 %9 to i64
ret i64 %10
}

LLVM IR (-O2):
%struct.timeval = type { i32, i32 }
define i64 @currentTimeInMilliseconds() {
%1 = alloca %struct.timeval
%2 = bitcast %struct.timeval* %1 to i8*
%3 = call i32 @gettimeofday(%struct.timeval* %1, i32* null)
%4 = getelementptr inbounds %struct.timeval, %struct.timeval* %1, i64 0, i32 0
%5 = load i32, i32* %4
%6 = mul nsw i32 %5, 1000
%7 = getelementptr inbounds %struct.timeval, %struct.timeval* %1, i64 0, i32 1
%8 = load i32, i32* %7
%9 = sdiv i32 %8, 1000
%10 = add nsw i32 %9, %6
%11 = sext i32 %10 to i64
ret i64 %11
}
/* Variables and functions */
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *);
int /*<<< orphan*/ stderr;
void help() {
  fprintf(stderr,
          "Usage: bis [OPTION]... [FILE]\n\n"
          "Options are:\n"
          "  -b SIZE[k]   specify block size (default: 200k)\n"
          "  -c           write to standard output\n"
          "  -d           decompress\n"
          "  -h           display this help message\n"
          "  -o OUTFILE   specify output file\n\n"
          "By default, append the .bis suffix when compressing and strip\n"
          "it when decompressing (if possible). If no input file is\n"
          "specified, read standard input and write to standard output.\n");
}


x86 assembly (clang, -O0):
<help>:
push   %rbp
mov    %rsp,%rbp
mov    0x2ec5(%rip),%rax
mov    (%rax),%edi
lea    0xedc(%rip),%rsi
call   1030 <fprintf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<help>:
mov    0x2ec9(%rip),%rax
mov    (%rax),%edi
lea    0xee0(%rip),%rsi
jmp    1030 <fprintf@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [418 x i8] c"Usage: bis [OPTION]... [FILE]\0A\0AOptions are:\0A -b SIZE[k] specify block size (default: 200k)\0A -c write to standard output\0A -d decompress\0A -h display this help message\0A -o OUTFILE specify output file\0A\0ABy default, append the .bis suffix when compressing and strip\0Ait when decompressing (if possible). If no input file is\0Aspecified, read standard input and write to standard output.\0A\00"
define void @help() {
%1 = load i32, i32* @stderr
%2 = call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([418 x i8], [418 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [418 x i8] c"Usage: bis [OPTION]... [FILE]\0A\0AOptions are:\0A -b SIZE[k] specify block size (default: 200k)\0A -c write to standard output\0A -d decompress\0A -h display this help message\0A -o OUTFILE specify output file\0A\0ABy default, append the .bis suffix when compressing and strip\0Ait when decompressing (if possible). If no input file is\0Aspecified, read standard input and write to standard output.\0A\00"
define void @help() {
%1 = load i32, i32* @stderr
%2 = tail call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([418 x i8], [418 x i8]* @.str, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ isodigit(int);
void t_isodigit_0x06() {
  Assert_real((isodigit(6) == 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_isodigit.c",
              35, ("isodigit should be 0 for 0x06"));
}


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

x86 assembly (clang, -O2):
<t_isodigit_0x06>:
push   %rax
mov    $0x6,%edi
call   1040 <isodigit@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
lea    0xec5(%rip),%rsi
lea    0xf67(%rip),%rcx
mov    $0x23,%edx
pop    %rax
jmp    1030 <Assert_real@plt>

LLVM IR (-O0):
@.str = [169 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_isodigit.c\00"
@.str.1 = [30 x i8] c"isodigit should be 0 for 0x06\00"
define void @t_isodigit_0x06() {
%1 = call i64 @isodigit(i32 6)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([169 x i8], [169 x i8]* @.str, i64 0, i64 0), i32 35, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [169 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_isodigit.c\00"
@.str.1 = [30 x i8] c"isodigit should be 0 for 0x06\00"
define void @t_isodigit_0x06() {
%1 = tail call i64 @isodigit(i32 6)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = tail call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([169 x i8], [169 x i8]* @.str, i64 0, i64 0), i32 35, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ assert(int /*<<< orphan*/);
int /*<<< orphan*/ cria_jogadores(int);
int get_quantidade_jogadores();
void test_cria_jogadores(void) {
  int QTDE_JOGADORES = 2;
  cria_jogadores(QTDE_JOGADORES);
  assert(get_quantidade_jogadores() == QTDE_JOGADORES && "test_cria_jogadores");
}


x86 assembly (clang, -O0):
<test_cria_jogadores>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x2,-0x4(%rbp)
mov    -0x4(%rbp),%edi
call   1040 <cria_jogadores@plt>
mov    $0x0,%al
call   1030 <get_quantidade_jogadores@plt>
mov    %eax,%ecx
xor    %eax,%eax
cmp    -0x4(%rbp),%ecx
mov    %al,-0x5(%rbp)
jne    1168 <test_cria_jogadores+0x38>
mov    $0x1,%al
mov    %al,-0x5(%rbp)
jmp    1168 <test_cria_jogadores+0x38>
mov    -0x5(%rbp),%al
and    $0x1,%al
movzbl %al,%edi
call   1050 <assert@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_cria_jogadores>:
push   %rax
mov    $0x2,%edi
call   1040 <cria_jogadores@plt>
xor    %eax,%eax
call   1030 <get_quantidade_jogadores@plt>
xor    %edi,%edi
cmp    $0x2,%eax
sete   %dil
pop    %rax
jmp    1050 <assert@plt>

LLVM IR (-O0):
@.str = [20 x i8] c"test_cria_jogadores\00"
define void @test_cria_jogadores() {
%1 = alloca i32
store i32 2, i32* %1
%2 = load i32, i32* %1
%3 = call i32 @cria_jogadores(i32 %2)
%4 = call i32 (...) @get_quantidade_jogadores()
%5 = load i32, i32* %1
%6 = icmp eq i32 %4, %5
br i1 %6, label %7, label %8
7: ; preds = %0
br label %8
8: ; preds = %7, %0
%9 = phi i1 [ false, %0 ], [ true, %7 ]
%10 = zext i1 %9 to i32
%11 = call i32 @assert(i32 %10)
ret void
}

LLVM IR (-O2):
define void @test_cria_jogadores() {
%1 = tail call i32 @cria_jogadores(i32 2)
%2 = tail call i32 (...) @get_quantidade_jogadores()
%3 = icmp eq i32 %2, 2
%4 = zext i1 %3 to i32
%5 = tail call i32 @assert(i32 %4)
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ pid_t;

/* Variables and functions */
int octave_kill_wrapper(pid_t pid, int signum) { return -1; }


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

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

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

LLVM IR (-O2):
define i32 @octave_kill_wrapper(i32 %0, i32 %1) {
ret i32 -1
}
void netxbig_init(void) {}


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

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

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

LLVM IR (-O2):
define void @netxbig_init() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ lt_fatal(char *, int, char *);
scalar_t__ malloc(size_t);
void *xmalloc(size_t num) {
  void *p = (void *)malloc(num);
  if (!p)
    lt_fatal("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/"
             "2022-01-22/02-19-57/repos/sim9108/SDKS/refs/heads/master/"
             "LibFontConfig/src/fc-scan/.libs/lt-fc-scan.c",
             311, "memory exhausted");
  return p;
}


x86 assembly (clang, -O0):
<xmalloc>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1040 <malloc@plt>
mov    %rax,-0x10(%rbp)
cmpq   $0x0,-0x10(%rbp)
jne    115c <xmalloc+0x3c>
lea    0xeb5(%rip),%rdi
mov    $0x137,%esi
lea    0xf4f(%rip),%rdx
call   1030 <lt_fatal@plt>
mov    -0x10(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<xmalloc>:
push   %rbx
call   1040 <malloc@plt>
mov    %rax,%rbx
test   %rax,%rax
jne    1146 <xmalloc+0x26>
lea    0xecb(%rip),%rdi
lea    0xf6a(%rip),%rdx
mov    $0x137,%esi
call   1030 <lt_fatal@plt>
mov    %rbx,%rax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [166 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/sim9108/SDKS/refs/heads/master/LibFontConfig/src/fc-scan/.libs/lt-fc-scan.c\00"
@.str.1 = [17 x i8] c"memory exhausted\00"
define i8* @xmalloc(i64 %0) {
%2 = alloca i64
%3 = alloca i8*
store i64 %0, i64* %2
%4 = load i64, i64* %2
%5 = call i64 @malloc(i64 %4)
%6 = inttoptr i64 %5 to i8*
store i8* %6, i8** %3
%7 = load i8*, i8** %3
%8 = icmp ne i8* %7, null
br i1 %8, label %11, label %9
9: ; preds = %1
%10 = call i32 @lt_fatal(i8* getelementptr inbounds ([166 x i8], [166 x i8]* @.str, i64 0, i64 0), i32 311, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.1, i64 0, i64 0))
br label %11
11: ; preds = %9, %1
%12 = load i8*, i8** %3
ret i8* %12
}

LLVM IR (-O2):
@.str = [166 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/sim9108/SDKS/refs/heads/master/LibFontConfig/src/fc-scan/.libs/lt-fc-scan.c\00"
@.str.1 = [17 x i8] c"memory exhausted\00"
define i8* @xmalloc(i64 %0) {
%2 = tail call i64 @malloc(i64 %0)
%3 = icmp eq i64 %2, 0
br i1 %3, label %4, label %6
4: ; preds = %1
%5 = tail call i32 @lt_fatal(i8* getelementptr inbounds ([166 x i8], [166 x i8]* @.str, i64 0, i64 0), i32 311, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.1, i64 0, i64 0))
br label %6
6: ; preds = %4, %1
%7 = inttoptr i64 %2 to i8*
ret i8* %7
}
/* Variables and functions */
int /*<<< orphan*/ free(void *);
void free_buffer_sample(void *key, void *val) { free(val); }


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

x86 assembly (clang, -O2):
<free_buffer_sample>:
mov    %rsi,%rdi
jmp    1030 <free@plt>

LLVM IR (-O0):
define void @free_buffer_sample(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
store i8* %0, i8** %3
store i8* %1, i8** %4
%5 = load i8*, i8** %4
%6 = call i32 @free(i8* %5)
ret void
}

LLVM IR (-O2):
define void @free_buffer_sample(i8* nocapture readnone %0, i8* nocapture %1) {
%3 = tail call i32 @free(i8* %1)
ret void
}
/* Variables and functions */
void *dbgMalloc(size_t);
int /*<<< orphan*/ memset(void *, int /*<<< orphan*/, size_t);
void *dbgCalloc(size_t size, size_t count) {
  void *ptr = dbgMalloc(size * count);
  if (ptr != NULL) {
    memset(ptr, 0, size * count);
  }
  return ptr;
}


x86 assembly (clang, -O0):
<dbgCalloc>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
imul   -0x10(%rbp),%rdi
call   1040 <dbgMalloc@plt>
mov    %rax,-0x18(%rbp)
cmpq   $0x0,-0x18(%rbp)
je     1161 <dbgCalloc+0x41>
mov    -0x18(%rbp),%rdi
mov    -0x8(%rbp),%rdx
imul   -0x10(%rbp),%rdx
xor    %esi,%esi
call   1030 <memset@plt>
mov    -0x18(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<dbgCalloc>:
push   %r14
push   %rbx
push   %rax
mov    %rdi,%rbx
imul   %rsi,%rbx
mov    %rbx,%rdi
call   1040 <dbgMalloc@plt>
mov    %rax,%r14
test   %rax,%rax
je     1148 <dbgCalloc+0x28>
mov    %r14,%rdi
xor    %esi,%esi
mov    %rbx,%rdx
call   1030 <memset@plt>
mov    %r14,%rax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

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

LLVM IR (-O2):
define i8* @dbgCalloc(i64 %0, i64 %1) {
%3 = mul i64 %1, %0
%4 = tail call i8* @dbgMalloc(i64 %3)
%5 = icmp eq i8* %4, null
br i1 %5, label %8, label %6
6: ; preds = %2
%7 = tail call i32 @memset(i8* %4, i32 0, i64 %3)
br label %8
8: ; preds = %6, %2
ret i8* %4
}
/* Variables and functions */
double drand48();
double gauss() { return (2.0 * drand48()) - 1.0; }


x86 assembly (clang, -O0):
<gauss>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1030 <drand48@plt>
addsd  %xmm0,%xmm0
movsd  0xed9(%rip),%xmm1
addsd  %xmm1,%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<gauss>:
push   %rax
xor    %eax,%eax
call   1030 <drand48@plt>
addsd  %xmm0,%xmm0
addsd  0xedc(%rip),%xmm0
pop    %rax
ret

LLVM IR (-O0):
define double @gauss() {
%1 = call double (...) @drand48()
%2 = call double @llvm.fmuladd.f64(double 2.000000e+00, double %1, double -1.000000e+00)
ret double %2
}

LLVM IR (-O2):
define double @gauss() {
%1 = tail call double (...) @drand48()
%2 = tail call double @llvm.fmuladd.f64(double %1, double 2.000000e+00, double -1.000000e+00)
ret double %2
}
/* Type definitions */
typedef int /*<<< orphan*/ portbuf;

/* Variables and functions */
int /*<<< orphan*/ snprintf(char *, int, char *, int);
const char *port_to_str(int port) {
  static char portbuf[16];
  snprintf(portbuf, sizeof(portbuf), "%d", port);
  return portbuf;
}


x86 assembly (clang, -O0):
<port_to_str>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%ecx
lea    0x2f1b(%rip),%rdi
mov    $0x10,%esi
lea    0xecf(%rip),%rdx
call   1030 <snprintf@plt>
lea    0x2f03(%rip),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<port_to_str>:
push   %rbx
mov    %edi,%ecx
lea    0x2f26(%rip),%rbx
lea    0xedf(%rip),%rdx
mov    %rbx,%rdi
mov    $0x10,%esi
call   1030 <snprintf@plt>
mov    %rbx,%rax
pop    %rbx
ret

LLVM IR (-O0):
@port_to_str.portbuf = internal global [16 x i8] zeroinitializer
@.str = [3 x i8] c"%d\00"
define i8* @port_to_str(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = call i32 @snprintf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @port_to_str.portbuf, i64 0, i64 0), i32 16, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32 %3)
ret i8* getelementptr inbounds ([16 x i8], [16 x i8]* @port_to_str.portbuf, i64 0, i64 0)
}

LLVM IR (-O2):
@port_to_str.portbuf = internal global [16 x i8] zeroinitializer
@.str = [3 x i8] c"%d\00"
define i8* @port_to_str(i32 %0) {
%2 = tail call i32 @snprintf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @port_to_str.portbuf, i64 0, i64 0), i32 16, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32 %0)
ret i8* getelementptr inbounds ([16 x i8], [16 x i8]* @port_to_str.portbuf, i64 0, i64 0)
}
/* Variables and functions */
int /*<<< orphan*/ _c_setbyte(int);
void PUSH_ES() {
  ;
  _c_setbyte(0x06);
  ;
}


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

x86 assembly (clang, -O2):
<PUSH_ES>:
mov    $0x6,%edi
jmp    1030 <_c_setbyte@plt>

LLVM IR (-O0):
define void @PUSH_ES() {
%1 = call i32 @_c_setbyte(i32 6)
ret void
}

LLVM IR (-O2):
define void @PUSH_ES() {
%1 = tail call i32 @_c_setbyte(i32 6)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ dcl_rc();
int /*<<< orphan*/ dcl_rd();
int /*<<< orphan*/ dcl_rf();
int /*<<< orphan*/ dcl_ri();
int /*<<< orphan*/ dcl_rll();
int /*<<< orphan*/ dcl_rp();
int /*<<< orphan*/ dcl_rs();
int /*<<< orphan*/ dcl_rv();
void test_1() {
  dcl_rv();
  dcl_rc();
  dcl_rs();
  dcl_ri();
  dcl_rll();
  dcl_rf();
  dcl_rd();
  dcl_rp();
}


x86 assembly (clang, -O0):
<test_1>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1090 <dcl_rv@plt>
mov    $0x0,%al
call   1030 <dcl_rc@plt>
mov    $0x0,%al
call   1040 <dcl_rs@plt>
mov    $0x0,%al
call   10a0 <dcl_ri@plt>
mov    $0x0,%al
call   1060 <dcl_rll@plt>
mov    $0x0,%al
call   1050 <dcl_rf@plt>
mov    $0x0,%al
call   1070 <dcl_rd@plt>
mov    $0x0,%al
call   1080 <dcl_rp@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_1>:
push   %rax
xor    %eax,%eax
call   1090 <dcl_rv@plt>
xor    %eax,%eax
call   1030 <dcl_rc@plt>
xor    %eax,%eax
call   1040 <dcl_rs@plt>
xor    %eax,%eax
call   10a0 <dcl_ri@plt>
xor    %eax,%eax
call   1060 <dcl_rll@plt>
xor    %eax,%eax
call   1050 <dcl_rf@plt>
xor    %eax,%eax
call   1070 <dcl_rd@plt>
xor    %eax,%eax
pop    %rcx
jmp    1080 <dcl_rp@plt>

LLVM IR (-O0):
define void @test_1() {
%1 = call i32 (...) @dcl_rv()
%2 = call i32 (...) @dcl_rc()
%3 = call i32 (...) @dcl_rs()
%4 = call i32 (...) @dcl_ri()
%5 = call i32 (...) @dcl_rll()
%6 = call i32 (...) @dcl_rf()
%7 = call i32 (...) @dcl_rd()
%8 = call i32 (...) @dcl_rp()
ret void
}

LLVM IR (-O2):
define void @test_1() {
%1 = tail call i32 (...) @dcl_rv()
%2 = tail call i32 (...) @dcl_rc()
%3 = tail call i32 (...) @dcl_rs()
%4 = tail call i32 (...) @dcl_ri()
%5 = tail call i32 (...) @dcl_rll()
%6 = tail call i32 (...) @dcl_rf()
%7 = tail call i32 (...) @dcl_rd()
%8 = tail call i32 (...) @dcl_rp()
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ clock_t;

/* Variables and functions */
int /*<<< orphan*/ clock();
int /*<<< orphan*/ printf(char *, int /*<<< orphan*/);
void time1_test() {
  clock_t clk1 = clock();
  printf("clk now %ld\n", clk1);
}


x86 assembly (clang, -O0):
<time1_test>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x0,%al
call   1030 <clock@plt>
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%esi
lea    0xec4(%rip),%rdi
call   1040 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<time1_test>:
push   %rax
xor    %eax,%eax
call   1030 <clock@plt>
lea    0xed1(%rip),%rdi
mov    %eax,%esi
pop    %rax
jmp    1040 <printf@plt>

LLVM IR (-O0):
@.str = [13 x i8] c"clk now %ld\0A\00"
define void @time1_test() {
%1 = alloca i32
%2 = call i32 (...) @clock()
store i32 %2, i32* %1
%3 = load i32, i32* %1
%4 = call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 %3)
ret void
}

LLVM IR (-O2):
@.str = [13 x i8] c"clk now %ld\0A\00"
define void @time1_test() {
%1 = tail call i32 (...) @clock()
%2 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 %1)
ret void
}
/* Variables and functions */
double fmod(double, double);
double emod(double a, double b) {
  double v = fmod(a, b);
  if ((b < 0) != (v < 0)) {
    v += b;
  }
  return v;
}


x86 assembly (clang, -O0):
<emod>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
movsd  -0x8(%rbp),%xmm0
movsd  -0x10(%rbp),%xmm1
call   1030 <fmod@plt>
movsd  %xmm0,-0x18(%rbp)
xorps  %xmm0,%xmm0
ucomisd -0x10(%rbp),%xmm0
seta   %al
and    $0x1,%al
movzbl %al,%eax
xorps  %xmm0,%xmm0
ucomisd -0x18(%rbp),%xmm0
seta   %cl
and    $0x1,%cl
movzbl %cl,%ecx
cmp    %ecx,%eax
je     116e <emod+0x5e>
movsd  -0x10(%rbp),%xmm0
addsd  -0x18(%rbp),%xmm0
movsd  %xmm0,-0x18(%rbp)
movsd  -0x18(%rbp),%xmm0
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<emod>:
push   %rax
movsd  %xmm1,(%rsp)
call   1030 <fmod@plt>
movsd  (%rsp),%xmm2
xorpd  %xmm1,%xmm1
ucomisd %xmm2,%xmm1
setbe  %al
ucomisd %xmm0,%xmm1
seta   %cl
xor    %al,%cl
je     113e <emod+0x2e>
movsd  0xec2(%rip),%xmm2
addsd  %xmm2,%xmm0
pop    %rax
ret

LLVM IR (-O0):
define double @emod(double %0, double %1) {
%3 = alloca double
%4 = alloca double
%5 = alloca double
store double %0, double* %3
store double %1, double* %4
%6 = load double, double* %3
%7 = load double, double* %4
%8 = call double @fmod(double %6, double %7)
store double %8, double* %5
%9 = load double, double* %4
%10 = fcmp olt double %9, 0.000000e+00
%11 = zext i1 %10 to i32
%12 = load double, double* %5
%13 = fcmp olt double %12, 0.000000e+00
%14 = zext i1 %13 to i32
%15 = icmp ne i32 %11, %14
br i1 %15, label %16, label %20
16: ; preds = %2
%17 = load double, double* %4
%18 = load double, double* %5
%19 = fadd double %18, %17
store double %19, double* %5
br label %20
20: ; preds = %16, %2
%21 = load double, double* %5
ret double %21
}

LLVM IR (-O2):
define double @emod(double %0, double %1) {
%3 = tail call double @fmod(double %0, double %1)
%4 = fcmp uge double %1, 0.000000e+00
%5 = fcmp olt double %3, 0.000000e+00
%6 = xor i1 %4, %5
%7 = select i1 %6, double -0.000000e+00, double %1
%8 = fadd double %3, %7
ret double %8
}
double aCelsius(double valor) {
  double c = (double)(valor - 32) * 5 / 9;
  return c;
}


x86 assembly (clang, -O0):
<aCelsius>:
push   %rbp
mov    %rsp,%rbp
movsd  %xmm0,-0x8(%rbp)
movsd  -0x8(%rbp),%xmm0
movsd  0xefa(%rip),%xmm1
subsd  %xmm1,%xmm0
movsd  0xee6(%rip),%xmm1
mulsd  %xmm1,%xmm0
movsd  0xed2(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x10(%rbp)
movsd  -0x10(%rbp),%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<aCelsius>:
addsd  0xef8(%rip),%xmm0
mulsd  0xef8(%rip),%xmm0
divsd  0xef8(%rip),%xmm0
ret

LLVM IR (-O0):
define double @aCelsius(double %0) {
%2 = alloca double
%3 = alloca double
store double %0, double* %2
%4 = load double, double* %2
%5 = fsub double %4, 3.200000e+01
%6 = fmul double %5, 5.000000e+00
%7 = fdiv double %6, 9.000000e+00
store double %7, double* %3
%8 = load double, double* %3
ret double %8
}

LLVM IR (-O2):
define double @aCelsius(double %0) {
%2 = fadd double %0, -3.200000e+01
%3 = fmul double %2, 5.000000e+00
%4 = fdiv double %3, 9.000000e+00
ret double %4
}
int mcd(int a, int b) {
  if (b == 0)
    return a;
  else
    return mcd(b, a % b);
}


x86 assembly (clang, -O0):
<mcd>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
cmpl   $0x0,-0xc(%rbp)
jne    1133 <mcd+0x23>
mov    -0x8(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    1147 <mcd+0x37>
mov    -0xc(%rbp),%edi
mov    -0x8(%rbp),%eax
cltd
idivl  -0xc(%rbp)
mov    %edx,%esi
call   1030 <mcd@plt>
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<mcd>:
mov    %edi,%eax
test   %esi,%esi
je     111d <mcd+0x1d>
mov    %esi,%edx
nopl   0x0(%rax,%rax,1)
mov    %edx,%ecx
cltd
idiv   %ecx
mov    %ecx,%eax
test   %edx,%edx
jne    1110 <mcd+0x10>
mov    %ecx,%eax
ret

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

LLVM IR (-O2):
define i32 @mcd(i32 %0, i32 %1) {
%3 = icmp eq i32 %1, 0
br i1 %3, label %9, label %4
4: ; preds = %2, %4
%5 = phi i32 [ %7, %4 ], [ %1, %2 ]
%6 = phi i32 [ %5, %4 ], [ %0, %2 ]
%7 = srem i32 %6, %5
%8 = icmp eq i32 %7, 0
br i1 %8, label %9, label %4
9: ; preds = %4, %2
%10 = phi i32 [ %0, %2 ], [ %5, %4 ]
ret i32 %10
}
/* Variables and functions */
scalar_t__ EuclDist(float *, float *, int);
float log(scalar_t__);
float EuclDistLog(float *f1, float *f2, int n) {
  return (((float)100000.0 * log(EuclDist(f1, f2, n) + 1)));
}


x86 assembly (clang, -O0):
<EuclDistLog>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
mov    -0x14(%rbp),%edx
call   1030 <EuclDist@plt>
mov    %rax,%rdi
add    $0x1,%rdi
call   1040 <log@plt>
movaps %xmm0,%xmm1
movss  0xea6(%rip),%xmm0
mulss  %xmm1,%xmm0
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<EuclDistLog>:
push   %rax
call   1030 <EuclDist@plt>
lea    0x1(%rax),%rdi
call   1040 <log@plt>
mulss  0xec9(%rip),%xmm0
pop    %rax
ret

LLVM IR (-O0):
define float @EuclDistLog(float* %0, float* %1, i32 %2) {
%4 = alloca float*
%5 = alloca float*
%6 = alloca i32
store float* %0, float** %4
store float* %1, float** %5
store i32 %2, i32* %6
%7 = load float*, float** %4
%8 = load float*, float** %5
%9 = load i32, i32* %6
%10 = call i64 @EuclDist(float* %7, float* %8, i32 %9)
%11 = add nsw i64 %10, 1
%12 = call float @log(i64 %11)
%13 = fmul float 1.000000e+05, %12
ret float %13
}

LLVM IR (-O2):
define float @EuclDistLog(float* %0, float* %1, i32 %2) {
%4 = tail call i64 @EuclDist(float* %0, float* %1, i32 %2)
%5 = add nsw i64 %4, 1
%6 = tail call float @log(i64 %5)
%7 = fmul float %6, 1.000000e+05
ret float %7
}
/* Variables and functions */
int /*<<< orphan*/ C67_asm(char *, int /*<<< orphan*/, int, int);
void C67_DPSP(int r, int v) { C67_asm("DPSP.L", 0, r, v); }


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

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

LLVM IR (-O0):
@.str = [7 x i8] c"DPSP.L\00"
define void @C67_DPSP(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
store i32 %0, i32* %3
store i32 %1, i32* %4
%5 = load i32, i32* %3
%6 = load i32, i32* %4
%7 = call i32 @C67_asm(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i32 0, i32 %5, i32 %6)
ret void
}

LLVM IR (-O2):
@.str = [7 x i8] c"DPSP.L\00"
define void @C67_DPSP(i32 %0, i32 %1) {
%3 = tail call i32 @C67_asm(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i32 0, i32 %0, i32 %1)
ret void
}
/* Variables and functions */
unsigned int BKDRHash(unsigned char *, int /*<<< orphan*/);
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ strlen(unsigned char *);
int main(int argc, char *argv[]) {
  unsigned char *str = argv[1];
  unsigned int hash = BKDRHash(str, strlen(str));
  if (hash == 0xbd9282b2)
    printf("You win!\n");
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rax
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
mov    %rax,-0x28(%rbp)
mov    -0x18(%rbp),%rdi
call   1030 <strlen@plt>
mov    -0x28(%rbp),%rdi
mov    %eax,%esi
call   1050 <BKDRHash@plt>
mov    %eax,-0x1c(%rbp)
cmpl   $0xbd9282b2,-0x1c(%rbp)
jne    118a <main+0x5a>
lea    0xe7b(%rip),%rdi
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
mov    0x8(%rsi),%rbx
mov    %rbx,%rdi
call   1040 <strlen@plt>
mov    %rbx,%rdi
mov    %eax,%esi
call   1050 <BKDRHash@plt>
cmp    $0xbd9282b2,%eax
jne    115a <main+0x2a>
lea    0xeab(%rip),%rdi
call   1030 <puts@plt>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [10 x i8] c"You win!\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i8*
%7 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%8 = load i8**, i8*** %5
%9 = getelementptr inbounds i8*, i8** %8, i64 1
%10 = load i8*, i8** %9
store i8* %10, i8** %6
%11 = load i8*, i8** %6
%12 = load i8*, i8** %6
%13 = call i32 @strlen(i8* %12)
%14 = call i32 @BKDRHash(i8* %11, i32 %13)
store i32 %14, i32* %7
%15 = load i32, i32* %7
%16 = icmp eq i32 %15, -1114471758
br i1 %16, label %17, label %19
17: ; preds = %2
%18 = call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0))
br label %19
19: ; preds = %17, %2
ret i32 0
}

LLVM IR (-O2):
@str = [9 x i8] c"You win!\00"
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = getelementptr inbounds i8*, i8** %1, i64 1
%4 = load i8*, i8** %3
%5 = tail call i32 @strlen(i8* %4)
%6 = tail call i32 @BKDRHash(i8* %4, i32 %5)
%7 = icmp eq i32 %6, -1114471758
br i1 %7, label %8, label %10
8: ; preds = %2
%9 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @str, i64 0, i64 0))
br label %10
10: ; preds = %8, %2
ret i32 0
}
/* Variables and functions */
unsigned short random();
int randport() {
  unsigned short port;
  port = random();
  while (port < 1024)
    port += 1024;
  return port;
}


x86 assembly (clang, -O0):
<randport>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x0,%al
call   1030 <random@plt>
mov    %ax,-0x2(%rbp)
movzwl -0x2(%rbp),%eax
cmp    $0x400,%eax
jge    1144 <randport+0x34>
movzwl -0x2(%rbp),%eax
add    $0x400,%eax
mov    %ax,-0x2(%rbp)
jmp    1123 <randport+0x13>
movzwl -0x2(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<randport>:
push   %rbx
xor    %ebx,%ebx
xor    %eax,%eax
call   1030 <random@plt>
mov    $0x400,%cx
sub    %ax,%cx
cmovb  %ebx,%ecx
add    $0x3ff,%ecx
and    $0xfffffc00,%ecx
add    %eax,%ecx
movzwl %cx,%eax
pop    %rbx
ret

LLVM IR (-O0):
define i32 @randport() {
%1 = alloca i16
%2 = call zeroext i16 (...) @random()
store i16 %2, i16* %1
br label %3
3: ; preds = %7, %0
%4 = load i16, i16* %1
%5 = zext i16 %4 to i32
%6 = icmp slt i32 %5, 1024
br i1 %6, label %7, label %12
7: ; preds = %3
%8 = load i16, i16* %1
%9 = zext i16 %8 to i32
%10 = add nsw i32 %9, 1024
%11 = trunc i32 %10 to i16
store i16 %11, i16* %1
br label %3
12: ; preds = %3
%13 = load i16, i16* %1
%14 = zext i16 %13 to i32
ret i32 %14
}

LLVM IR (-O2):
define i32 @randport() {
%1 = tail call zeroext i16 (...) @random()
%2 = call i16 @llvm.umax.i16(i16 %1, i16 1024)
%3 = add i16 %2, 1023
%4 = sub i16 %3, %1
%5 = and i16 %4, -1024
%6 = add i16 %1, %5
%7 = zext i16 %6 to i32
ret i32 %7
}
/* Variables and functions */
scalar_t__ malloc(int);
int /*<<< orphan*/ strncpy(char *, char *, int);
char *nv_strndup(char *s, int n) {
  char *m = (char *)malloc(n + 1);
  strncpy(m, s, n);
  m[n] = '\0';
  return (m);
}


x86 assembly (clang, -O0):
<nv_strndup>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0xc(%rbp),%edi
add    $0x1,%edi
call   1040 <malloc@plt>
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rdi
mov    -0x8(%rbp),%rsi
mov    -0xc(%rbp),%edx
call   1030 <strncpy@plt>
mov    -0x18(%rbp),%rax
movslq -0xc(%rbp),%rcx
movb   $0x0,(%rax,%rcx,1)
mov    -0x18(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<nv_strndup>:
push   %r15
push   %r14
push   %rbx
mov    %esi,%r15d
mov    %rdi,%r14
lea    0x1(%r15),%edi
call   1040 <malloc@plt>
mov    %rax,%rbx
mov    %rax,%rdi
mov    %r14,%rsi
mov    %r15d,%edx
call   1030 <strncpy@plt>
movslq %r15d,%rax
movb   $0x0,(%rbx,%rax,1)
mov    %rbx,%rax
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
define i8* @nv_strndup(i8* %0, i32 %1) {
%3 = alloca i8*
%4 = alloca i32
%5 = alloca i8*
store i8* %0, i8** %3
store i32 %1, i32* %4
%6 = load i32, i32* %4
%7 = add nsw i32 %6, 1
%8 = call i64 @malloc(i32 %7)
%9 = inttoptr i64 %8 to i8*
store i8* %9, i8** %5
%10 = load i8*, i8** %5
%11 = load i8*, i8** %3
%12 = load i32, i32* %4
%13 = call i32 @strncpy(i8* %10, i8* %11, i32 %12)
%14 = load i8*, i8** %5
%15 = load i32, i32* %4
%16 = sext i32 %15 to i64
%17 = getelementptr inbounds i8, i8* %14, i64 %16
store i8 0, i8* %17
%18 = load i8*, i8** %5
ret i8* %18
}

LLVM IR (-O2):
define i8* @nv_strndup(i8* %0, i32 %1) {
%3 = add nsw i32 %1, 1
%4 = tail call i64 @malloc(i32 %3)
%5 = inttoptr i64 %4 to i8*
%6 = tail call i32 @strncpy(i8* %5, i8* %0, i32 %1)
%7 = sext i32 %1 to i64
%8 = getelementptr inbounds i8, i8* %5, i64 %7
store i8 0, i8* %8
ret i8* %5
}
/* Variables and functions */
int tracepoint_probe_unregister(char *, void *);
__attribute__((always_)) int
unregister_trace_mm_pagevec_free(void (*probe)(struct page *page, int cold)) {
  return tracepoint_probe_unregister("mm_pagevec_free", (void *)probe);
}


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

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

LLVM IR (-O0):
%struct.page = type opaque
@.str = [16 x i8] c"mm_pagevec_free\00"
define i32 @unregister_trace_mm_pagevec_free(void (%struct.page*, i32)* %0) {
%2 = alloca void (%struct.page*, i32)*
store void (%struct.page*, i32)* %0, void (%struct.page*, i32)** %2
%3 = load void (%struct.page*, i32)*, void (%struct.page*, i32)** %2
%4 = bitcast void (%struct.page*, i32)* %3 to i8*
%5 = call i32 @tracepoint_probe_unregister(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str, i64 0, i64 0), i8* %4)
ret i32 %5
}

LLVM IR (-O2):
%struct.page = type opaque
@.str = [16 x i8] c"mm_pagevec_free\00"
define i32 @unregister_trace_mm_pagevec_free(void (%struct.page*, i32)* %0) {
%2 = bitcast void (%struct.page*, i32)* %0 to i8*
%3 = tail call i32 @tracepoint_probe_unregister(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str, i64 0, i64 0), i8* %2)
ret i32 %3
}
void foo112(int p) {}


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

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

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

LLVM IR (-O2):
define void @foo112(i32 %0) {
ret void
}