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

/* Variables and functions */
int /*<<< orphan*/ feupdateenv(int /*<<< orphan*/ *);
void uninitvar_feupdateenv(void) {
  fenv_t *envp;
  (void)feupdateenv(envp);
}


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

x86 assembly (clang, -O2):
<uninitvar_feupdateenv>:
jmp    1030 <feupdateenv@plt>

LLVM IR (-O0):
define void @uninitvar_feupdateenv() {
%1 = alloca i32*
%2 = load i32*, i32** %1
%3 = call i32 @feupdateenv(i32* %2)
ret void
}

LLVM IR (-O2):
define void @uninitvar_feupdateenv() {
%1 = tail call i32 @feupdateenv(i32* undef)
ret void
}
void add_wait_queue(void) { nsc_assert(0, __func__); }


x86 assembly (clang, -O0):
<add_wait_queue>:
push   %rbp
mov    %rsp,%rbp
xor    %edi,%edi
lea    0xee3(%rip),%rsi
mov    $0x0,%al
call   1030 <nsc_assert@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<add_wait_queue>:
lea    0xee9(%rip),%rsi
xor    %edi,%edi
xor    %eax,%eax
jmp    1030 <nsc_assert@plt>

LLVM IR (-O0):
@__func__.add_wait_queue = [15 x i8] c"add_wait_queue\00"
define void @add_wait_queue() {
%1 = call i32 (i32, i8*, ...) bitcast (i32 (...)* @nsc_assert to i32 (i32, i8*, ...)*)(i32 0, i8* getelementptr inbounds ([15 x i8], [15 x i8]* @__func__.add_wait_queue, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@__func__.add_wait_queue = [15 x i8] c"add_wait_queue\00"
define void @add_wait_queue() {
%1 = tail call i32 (i32, i8*, ...) bitcast (i32 (...)* @nsc_assert to i32 (i32, i8*, ...)*)(i32 0, i8* getelementptr inbounds ([15 x i8], [15 x i8]* @__func__.add_wait_queue, i64 0, i64 0))
ret void
}
int empty_function(void) { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @empty_function() {
ret i32 0
}
/* Variables and functions */
int bar(int);
int main(int argc, char *argv[]) {
  int sum;
  sum = bar(100);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    $0x64,%edi
call   1030 <bar@plt>
mov    %eax,-0x14(%rbp)
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%7 = call i32 @bar(i32 100)
store i32 %7, i32* %6
ret i32 0
}

LLVM IR (-O2):
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @bar(i32 100)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ CurrMem();
int /*<<< orphan*/ PrintHRBytes(int /*<<< orphan*/);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *);
int /*<<< orphan*/ stderr;
void PrintCurrMem(void) {
  fprintf(stderr, "[i] Current Heap memory: ");
  PrintHRBytes(CurrMem());
  fprintf(stderr, "\n");
}


x86 assembly (clang, -O0):
<PrintCurrMem>:
push   %rbp
mov    %rsp,%rbp
mov    0x2ea5(%rip),%rax
mov    (%rax),%edi
lea    0xebc(%rip),%rsi
call   1040 <fprintf@plt>
mov    $0x0,%al
call   1030 <CurrMem@plt>
mov    %eax,%edi
call   1050 <PrintHRBytes@plt>
mov    0x2e82(%rip),%rax
mov    (%rax),%edi
lea    0xeb3(%rip),%rsi
call   1040 <fprintf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<PrintCurrMem>:
push   %rbx
mov    0x2ea8(%rip),%rbx
mov    (%rbx),%edi
lea    0xebf(%rip),%rsi
call   1040 <fprintf@plt>
xor    %eax,%eax
call   1030 <CurrMem@plt>
mov    %eax,%edi
call   1050 <PrintHRBytes@plt>
mov    (%rbx),%edi
lea    0xebd(%rip),%rsi
pop    %rbx
jmp    1040 <fprintf@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [26 x i8] c"[i] Current Heap memory: \00"
@.str.1 = [2 x i8] c"\0A\00"
define void @PrintCurrMem() {
%1 = load i32, i32* @stderr
%2 = call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str, i64 0, i64 0))
%3 = call i32 (...) @CurrMem()
%4 = call i32 @PrintHRBytes(i32 %3)
%5 = load i32, i32* @stderr
%6 = call i32 @fprintf(i32 %5, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [26 x i8] c"[i] Current Heap memory: \00"
@.str.1 = [2 x i8] c"\0A\00"
define void @PrintCurrMem() {
%1 = load i32, i32* @stderr
%2 = tail call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str, i64 0, i64 0))
%3 = tail call i32 (...) @CurrMem()
%4 = tail call i32 @PrintHRBytes(i32 %3)
%5 = load i32, i32* @stderr
%6 = tail call i32 @fprintf(i32 %5, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
ret void
}
int test_fun(int x, int y) {
  int c = 0;
  while (x >= y + 1) {
    y = y + 1;
    c = c + 1;
  }
  return c;
}


x86 assembly (clang, -O0):
<test_fun>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
mov    -0x4(%rbp),%eax
mov    -0x8(%rbp),%ecx
add    $0x1,%ecx
cmp    %ecx,%eax
jl     1139 <test_fun+0x39>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    1111 <test_fun+0x11>
mov    -0xc(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_fun>:
xor    %eax,%eax
sub    %esi,%edi
cmovg  %edi,%eax
ret

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

LLVM IR (-O2):
define i32 @test_fun(i32 %0, i32 %1) {
%3 = icmp sgt i32 %0, %1
%4 = sub i32 %0, %1
%5 = select i1 %3, i32 %4, i32 0
ret i32 %5
}
int read(int fd, char *buf, int nbytes) { return 0; }


x86 assembly (clang, -O0):
<read>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
xor    %eax,%eax
pop    %rbp
ret

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

LLVM IR (-O0):
define i32 @read(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
ret i32 0
}

LLVM IR (-O2):
define i32 @read(i32 %0, i8* nocapture readnone %1, i32 %2) {
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ pqueue_get();
void *worker(void *arg) {
  while (1) {
    pqueue_get();
  }
  return NULL;
}


x86 assembly (clang, -O0):
<worker>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    $0x0,%al
call   1030 <pqueue_get@plt>
jmp    111c <worker+0xc>

x86 assembly (clang, -O2):
<worker>:
push   %rax
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
xor    %eax,%eax
call   1030 <pqueue_get@plt>
jmp    1120 <worker+0x10>

LLVM IR (-O0):
define i8* @worker(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
br label %3
3: ; preds = %1, %3
%4 = call i32 (...) @pqueue_get()
br label %3
}

LLVM IR (-O2):
define noalias i8* @worker(i8* nocapture readnone %0) {
br label %2
2: ; preds = %1, %2
%3 = tail call i32 (...) @pqueue_get()
br label %2
}
/* Type definitions */
typedef unsigned long volatile uint32_t;

/* Variables and functions */
void PWMIntDisable(uint32_t ui32Base, uint32_t ui32GenFault) {
  ;

  ;
  (*((volatile unsigned long *)(ui32Base + 0x00000014))) &= ~(ui32GenFault);
}


x86 assembly (clang, -O0):
<PWMIntDisable>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x10(%rbp),%rdx
xor    $0xffffffffffffffff,%rdx
mov    -0x8(%rbp),%rax
mov    0x14(%rax),%rcx
and    %rdx,%rcx
mov    %rcx,0x14(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<PWMIntDisable>:
mov    %rdi,-0x8(%rsp)
mov    %rsi,-0x10(%rsp)
mov    -0x10(%rsp),%rax
not    %rax
mov    -0x8(%rsp),%rcx
and    %rax,0x14(%rcx)
ret

LLVM IR (-O0):
define void @PWMIntDisable(i64 %0, i64 %1) {
%3 = alloca i64
%4 = alloca i64
store volatile i64 %0, i64* %3
store volatile i64 %1, i64* %4
%5 = load volatile i64, i64* %4
%6 = xor i64 %5, -1
%7 = load volatile i64, i64* %3
%8 = add i64 %7, 20
%9 = inttoptr i64 %8 to i64*
%10 = load volatile i64, i64* %9
%11 = and i64 %10, %6
store volatile i64 %11, i64* %9
ret void
}

LLVM IR (-O2):
define void @PWMIntDisable(i64 %0, i64 %1) {
%3 = alloca i64
%4 = alloca i64
store volatile i64 %0, i64* %3
store volatile i64 %1, i64* %4
%5 = load volatile i64, i64* %4
%6 = xor i64 %5, -1
%7 = load volatile i64, i64* %3
%8 = add i64 %7, 20
%9 = inttoptr i64 %8 to i64*
%10 = load volatile i64, i64* %9
%11 = and i64 %10, %6
store volatile i64 %11, i64* %9
ret void
}
/* Variables and functions */
int /*<<< orphan*/ cmd_init();
int ui_init_cmddisp(void) {
  cmd_init();
  return 0;
}


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

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

LLVM IR (-O0):
define i32 @ui_init_cmddisp() {
%1 = call i32 (...) @cmd_init()
ret i32 0
}

LLVM IR (-O2):
define i32 @ui_init_cmddisp() {
%1 = tail call i32 (...) @cmd_init()
ret i32 0
}
void test() {
  char a;
  unsigned int b;
  a = 15;
  b = 39;
  a = b;
}


x86 assembly (clang, -O0):
<test>:
push   %rbp
mov    %rsp,%rbp
movb   $0xf,-0x1(%rbp)
movl   $0x27,-0x8(%rbp)
mov    -0x8(%rbp),%eax
mov    %al,-0x1(%rbp)
pop    %rbp
ret

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

LLVM IR (-O0):
define void @test() {
%1 = alloca i8
%2 = alloca i32
store i8 15, i8* %1
store i32 39, i32* %2
%3 = load i32, i32* %2
%4 = trunc i32 %3 to i8
store i8 %4, i8* %1
ret void
}

LLVM IR (-O2):
define void @test() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ isalnum(int);
void t_isalnum_0xd1() {
  Assert_real((isalnum(209) == 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_isalnum.c",
              1050, ("isalnum should be 0 for 0xd1"));
}


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

x86 assembly (clang, -O2):
<t_isalnum_0xd1>:
push   %rax
mov    $0xd1,%edi
call   1030 <isalnum@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
lea    0xec5(%rip),%rsi
lea    0xf66(%rip),%rcx
mov    $0x41a,%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_isalnum.c\00"
@.str.1 = [29 x i8] c"isalnum should be 0 for 0xd1\00"
define void @t_isalnum_0xd1() {
%1 = call i64 @isalnum(i32 209)
%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 1050, 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_isalnum.c\00"
@.str.1 = [29 x i8] c"isalnum should be 0 for 0xd1\00"
define void @t_isalnum_0xd1() {
%1 = tail call i64 @isalnum(i32 209)
%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 1050, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0))
ret void
}
int get_utf8_char_len(unsigned char ch) {
  if ((ch & 0x80) == 0)
    return 1;
  switch (ch & 0xf0) {
  case 0xf0:
    return 4;
  case 0xe0:
    return 3;
  default:
    return 2;
  }
}


x86 assembly (clang, -O0):
<get_utf8_char_len>:
push   %rbp
mov    %rsp,%rbp
mov    %dil,%al
mov    %al,-0x5(%rbp)
movzbl -0x5(%rbp),%eax
and    $0x80,%eax
cmp    $0x0,%eax
jne    1128 <get_utf8_char_len+0x28>
movl   $0x1,-0x4(%rbp)
jmp    1174 <get_utf8_char_len+0x74>
movzbl -0x5(%rbp),%eax
and    $0xfffffff0,%eax
mov    %eax,-0xc(%rbp)
sub    $0xe0,%eax
je     1161 <get_utf8_char_len+0x61>
jmp    1142 <get_utf8_char_len+0x42>
mov    -0xc(%rbp),%eax
sub    $0xf0,%eax
jne    116d <get_utf8_char_len+0x6d>
jmp    1155 <get_utf8_char_len+0x55>
movl   $0x4,-0x4(%rbp)
jmp    1174 <get_utf8_char_len+0x74>
movl   $0x3,-0x4(%rbp)
jmp    1174 <get_utf8_char_len+0x74>
movl   $0x2,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<get_utf8_char_len>:
mov    $0x1,%eax
test   %dil,%dil
js     110b <get_utf8_char_len+0xb>
ret
mov    %edi,%eax
and    $0xf0,%al
xor    %ecx,%ecx
cmp    $0xe0,%al
sete   %cl
or     $0x2,%ecx
cmp    $0xf0,%dil
mov    $0x4,%eax
cmovb  %ecx,%eax
ret

LLVM IR (-O0):
define i32 @get_utf8_char_len(i8 zeroext %0) {
%2 = alloca i32
%3 = alloca i8
store i8 %0, i8* %3
%4 = load i8, i8* %3
%5 = zext i8 %4 to i32
%6 = and i32 %5, 128
%7 = icmp eq i32 %6, 0
br i1 %7, label %8, label %9
8: ; preds = %1
store i32 1, i32* %2
br label %16
9: ; preds = %1
%10 = load i8, i8* %3
%11 = zext i8 %10 to i32
%12 = and i32 %11, 240
switch i32 %12, label %15 [
i32 240, label %13
i32 224, label %14
]
13: ; preds = %9
store i32 4, i32* %2
br label %16
14: ; preds = %9
store i32 3, i32* %2
br label %16
15: ; preds = %9
store i32 2, i32* %2
br label %16
16: ; preds = %15, %14, %13, %8
%17 = load i32, i32* %2
ret i32 %17
}

LLVM IR (-O2):
define i32 @get_utf8_char_len(i8 zeroext %0) {
%2 = icmp sgt i8 %0, -1
br i1 %2, label %9, label %3
3: ; preds = %1
%4 = and i8 %0, -16
%5 = icmp eq i8 %4, -32
%6 = select i1 %5, i32 3, i32 2
%7 = icmp ugt i8 %0, -17
%8 = select i1 %7, i32 4, i32 %6
br label %9
9: ; preds = %3, %1
%10 = phi i32 [ 1, %1 ], [ %8, %3 ]
ret i32 %10
}
/* Variables and functions */
int /*<<< orphan*/
_test_consulta_debe_permitir_consultar_un_elemento_sin_sacarlo();
int /*<<< orphan*/
_test_pone_y_saca_deben_permitir_poner_y_sacar_elementos_de_la_pila();
int /*<<< orphan*/ _test_vacia_debe_indicar_si_la_pila_esta_vacia();
void pilad_tests() {
  _test_vacia_debe_indicar_si_la_pila_esta_vacia();
  _test_pone_y_saca_deben_permitir_poner_y_sacar_elementos_de_la_pila();
  _test_consulta_debe_permitir_consultar_un_elemento_sin_sacarlo();
}


x86 assembly (clang, -O0):
<pilad_tests>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1030 <_test_vacia_debe_indicar_si_la_pila_esta_vacia@plt>
mov    $0x0,%al
call   1040 <_test_pone_y_saca_deben_permitir_poner_y_sacar_elementos_de_la_pila@plt>
mov    $0x0,%al
call   1050 <_test_consulta_debe_permitir_consultar_un_elemento_sin_sacarlo@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<pilad_tests>:
push   %rax
xor    %eax,%eax
call   1030 <_test_vacia_debe_indicar_si_la_pila_esta_vacia@plt>
xor    %eax,%eax
call   1040 <_test_pone_y_saca_deben_permitir_poner_y_sacar_elementos_de_la_pila@plt>
xor    %eax,%eax
pop    %rcx
jmp    1050 <_test_consulta_debe_permitir_consultar_un_elemento_sin_sacarlo@plt>

LLVM IR (-O0):
define void @pilad_tests() {
%1 = call i32 (...) @_test_vacia_debe_indicar_si_la_pila_esta_vacia()
%2 = call i32 (...) @_test_pone_y_saca_deben_permitir_poner_y_sacar_elementos_de_la_pila()
%3 = call i32 (...) @_test_consulta_debe_permitir_consultar_un_elemento_sin_sacarlo()
ret void
}

LLVM IR (-O2):
define void @pilad_tests() {
%1 = tail call i32 (...) @_test_vacia_debe_indicar_si_la_pila_esta_vacia()
%2 = tail call i32 (...) @_test_pone_y_saca_deben_permitir_poner_y_sacar_elementos_de_la_pila()
%3 = tail call i32 (...) @_test_consulta_debe_permitir_consultar_un_elemento_sin_sacarlo()
ret void
}
void net_close(void) {}


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

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

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

LLVM IR (-O2):
define void @net_close() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ isspace(int);
void t_isspace_0x6a() {
  Assert_real((isspace(106) == 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_isspace.c",
              535, ("isspace should be 0 for j"));
}


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

x86 assembly (clang, -O2):
<t_isspace_0x6a>:
push   %rax
mov    $0x6a,%edi
call   1030 <isspace@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
lea    0xec5(%rip),%rsi
lea    0xf66(%rip),%rcx
mov    $0x217,%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_isspace.c\00"
@.str.1 = [26 x i8] c"isspace should be 0 for j\00"
define void @t_isspace_0x6a() {
%1 = call i64 @isspace(i32 106)
%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 535, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [168 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_isspace.c\00"
@.str.1 = [26 x i8] c"isspace should be 0 for j\00"
define void @t_isspace_0x6a() {
%1 = tail call i64 @isspace(i32 106)
%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 535, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.1, i64 0, i64 0))
ret void
}
unsigned long GenerateRandomNumber(void) {
  static unsigned long randSeed = 99887766;
  randSeed = (randSeed * 196314165) + 907633515;
  return randSeed;
}


x86 assembly (clang, -O0):
<GenerateRandomNumber>:
push   %rbp
mov    %rsp,%rbp
imul   $0xbb38435,0x2f11(%rip),%rax
35 84 b3 0b
add    $0x3619636b,%rax
mov    %rax,0x2f04(%rip)
mov    0x2efd(%rip),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<GenerateRandomNumber>:
imul   $0xbb38435,0x2f15(%rip),%rax
35 84 b3 0b
add    $0x3619636b,%rax
mov    %rax,0x2f08(%rip)
ret

LLVM IR (-O0):
@GenerateRandomNumber.randSeed = internal global i64 99887766
define i64 @GenerateRandomNumber() {
%1 = load i64, i64* @GenerateRandomNumber.randSeed
%2 = mul i64 %1, 196314165
%3 = add i64 %2, 907633515
store i64 %3, i64* @GenerateRandomNumber.randSeed
%4 = load i64, i64* @GenerateRandomNumber.randSeed
ret i64 %4
}

LLVM IR (-O2):
@GenerateRandomNumber.randSeed = internal unnamed_addr global i64 99887766
define i64 @GenerateRandomNumber() {
%1 = load i64, i64* @GenerateRandomNumber.randSeed
%2 = mul i64 %1, 196314165
%3 = add i64 %2, 907633515
store i64 %3, i64* @GenerateRandomNumber.randSeed
ret i64 %3
}
int main(argc, argv)
char **argv;
int argc;
{
  do_main(argc, argv);
  exit(0);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%edi
mov    -0x10(%rbp),%rsi
mov    $0x0,%al
call   1030 <do_main@plt>
xor    %edi,%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<main>:
push   %rax
xor    %eax,%eax
call   1030 <do_main@plt>
xor    %edi,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%6 = load i32, i32* %4
%7 = load i8**, i8*** %5
%8 = call i32 (i32, i8**, ...) bitcast (i32 (...)* @do_main to i32 (i32, i8**, ...)*)(i32 %6, i8** %7)
unreachable
}

LLVM IR (-O2):
define i32 @main(i32 %0, i8** %1) {
%3 = tail call i32 (i32, i8**, ...) bitcast (i32 (...)* @do_main to i32 (i32, i8**, ...)*)(i32 %0, i8** %1)
tail call void @exit(i32 0)
unreachable
}
/* Variables and functions */
double measure();
int /*<<< orphan*/ printf(char *, double);
void *start_routine(void *arg) {
  double t = measure();
  printf("time per call: %.3g\n", t);
  return arg;
}


x86 assembly (clang, -O0):
<start_routine>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    $0x0,%al
call   1040 <measure@plt>
movsd  %xmm0,-0x10(%rbp)
movsd  -0x10(%rbp),%xmm0
lea    0xebc(%rip),%rdi
call   1030 <printf@plt>
mov    -0x8(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<start_routine>:
push   %rbx
mov    %rdi,%rbx
xor    %eax,%eax
call   1040 <measure@plt>
lea    0xece(%rip),%rdi
call   1030 <printf@plt>
mov    %rbx,%rax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [21 x i8] c"time per call: %.3g\0A\00"
define i8* @start_routine(i8* %0) {
%2 = alloca i8*
%3 = alloca double
store i8* %0, i8** %2
%4 = call double (...) @measure()
store double %4, double* %3
%5 = load double, double* %3
%6 = call i32 @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0), double %5)
%7 = load i8*, i8** %2
ret i8* %7
}

LLVM IR (-O2):
@.str = [21 x i8] c"time per call: %.3g\0A\00"
define i8* @start_routine(i8* readnone returned %0) {
%2 = tail call double (...) @measure()
%3 = tail call i32 @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0), double %2)
ret i8* %0
}
/* Variables and functions */
int readchar();
int readint(int n) {
  int v = 0;
  while (n--)
    v = v * 2 + readchar() - '0';
  return v;
}


x86 assembly (clang, -O0):
<readint>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
mov    -0x4(%rbp),%eax
mov    %eax,%ecx
add    $0xffffffff,%ecx
mov    %ecx,-0x4(%rbp)
cmp    $0x0,%eax
je     1158 <readint+0x48>
mov    -0x8(%rbp),%eax
shl    $0x1,%eax
mov    %eax,-0xc(%rbp)
mov    $0x0,%al
call   1030 <readchar@plt>
mov    %eax,%ecx
mov    -0xc(%rbp),%eax
add    %ecx,%eax
sub    $0x30,%eax
mov    %eax,-0x8(%rbp)
jmp    1122 <readint+0x12>
mov    -0x8(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<readint>:
push   %rbp
push   %rbx
push   %rax
test   %edi,%edi
je     1134 <readint+0x24>
mov    %edi,%ebp
xor    %ebx,%ebx
nopl   0x0(%rax,%rax,1)
xor    %eax,%eax
call   1030 <readchar@plt>
lea    (%rax,%rbx,2),%ebx
add    $0xffffffd0,%ebx
add    $0xffffffff,%ebp
jne    1120 <readint+0x10>
jmp    1136 <readint+0x26>
xor    %ebx,%ebx
mov    %ebx,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
define i32 @readint(i32 %0) {
%2 = alloca i32
%3 = alloca i32
store i32 %0, i32* %2
store i32 0, i32* %3
br label %4
4: ; preds = %8, %1
%5 = load i32, i32* %2
%6 = add nsw i32 %5, -1
store i32 %6, i32* %2
%7 = icmp ne i32 %5, 0
br i1 %7, label %8, label %14
8: ; preds = %4
%9 = load i32, i32* %3
%10 = mul nsw i32 %9, 2
%11 = call i32 (...) @readchar()
%12 = add nsw i32 %10, %11
%13 = sub nsw i32 %12, 48
store i32 %13, i32* %3
br label %4
14: ; preds = %4
%15 = load i32, i32* %3
ret i32 %15
}

LLVM IR (-O2):
define i32 @readint(i32 %0) {
%2 = icmp eq i32 %0, 0
br i1 %2, label %12, label %3
3: ; preds = %1, %3
%4 = phi i32 [ %10, %3 ], [ 0, %1 ]
%5 = phi i32 [ %6, %3 ], [ %0, %1 ]
%6 = add nsw i32 %5, -1
%7 = shl nsw i32 %4, 1
%8 = tail call i32 (...) @readchar()
%9 = add i32 %7, -48
%10 = add i32 %9, %8
%11 = icmp eq i32 %6, 0
br i1 %11, label %12, label %3
12: ; preds = %3, %1
%13 = phi i32 [ 0, %1 ], [ %10, %3 ]
ret i32 %13
}
/* Variables and functions */
int /*<<< orphan*/ hello_func();
int main(int argc, char *argv[]) {
  hello_func();
  return 0;
}


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

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

LLVM IR (-O0):
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%6 = call i32 (...) @hello_func()
ret i32 0
}

LLVM IR (-O2):
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 (...) @hello_func()
ret i32 0
}
void destructor() {}


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

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

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

LLVM IR (-O2):
define void @destructor() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ write(char *, char *, int /*<<< orphan*/ *);
void pre_task() { write("json-task.json", "\t{", NULL); }


x86 assembly (clang, -O0):
<pre_task>:
push   %rbp
mov    %rsp,%rbp
lea    0xee5(%rip),%rdi
lea    0xeed(%rip),%rsi
xor    %eax,%eax
mov    %eax,%edx
call   1030 <write@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<pre_task>:
lea    0xee9(%rip),%rdi
lea    0xef1(%rip),%rsi
xor    %edx,%edx
jmp    1030 <write@plt>

LLVM IR (-O0):
@.str = [15 x i8] c"json-task.json\00"
@.str.1 = [3 x i8] c"\09{\00"
define void @pre_task() {
%1 = call i32 @write(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* null)
ret void
}

LLVM IR (-O2):
@.str = [15 x i8] c"json-task.json\00"
@.str.1 = [3 x i8] c"\09{\00"
define void @pre_task() {
%1 = tail call i32 @write(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* null)
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ arr;

/* Variables and functions */
scalar_t__ findMaxMultupleOf3(int *, int);
int /*<<< orphan*/ printf(char *);
int main() {
  int arr[] = {7, 7, 7, 7, 2, 2, 2};
  int size = sizeof(arr) / sizeof(arr[0]);
  if (findMaxMultupleOf3(arr, size) == 0)
    printf("Not Possible");
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movl   $0x0,-0x4(%rbp)
mov    0xeca(%rip),%rax
mov    %rax,-0x20(%rbp)
mov    0xec7(%rip),%rax
mov    %rax,-0x18(%rbp)
mov    0xec4(%rip),%rax
mov    %rax,-0x10(%rbp)
mov    0xec2(%rip),%eax
mov    %eax,-0x8(%rbp)
movl   $0x7,-0x24(%rbp)
lea    -0x20(%rbp),%rdi
mov    -0x24(%rbp),%esi
call   1040 <findMaxMultupleOf3@plt>
cmp    $0x0,%rax
jne    1182 <main+0x62>
lea    0xe9f(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
sub    $0x28,%rsp
movups 0xee1(%rip),%xmm0
movups %xmm0,0xc(%rsp)
movaps 0xec9(%rip),%xmm0
movaps %xmm0,(%rsp)
mov    %rsp,%rdi
mov    $0x7,%esi
call   1040 <findMaxMultupleOf3@plt>
test   %rax,%rax
jne    1159 <main+0x39>
lea    0xec8(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x28,%rsp
ret

LLVM IR (-O0):
@__const.main.arr = [7 x i32] [i32 7, i32 7, i32 7, i32 7, i32 2, i32 2, i32 2]
@.str = [13 x i8] c"Not Possible\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [7 x i32]
%3 = alloca i32
store i32 0, i32* %1
%4 = bitcast [7 x i32]* %2 to i8*
store i32 7, i32* %3
%5 = getelementptr inbounds [7 x i32], [7 x i32]* %2, i64 0, i64 0
%6 = load i32, i32* %3
%7 = call i64 @findMaxMultupleOf3(i32* %5, i32 %6)
%8 = icmp eq i64 %7, 0
br i1 %8, label %9, label %11
9: ; preds = %0
%10 = call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
br label %11
11: ; preds = %9, %0
ret i32 0
}

LLVM IR (-O2):
@__const.main.arr = [7 x i32] [i32 7, i32 7, i32 7, i32 7, i32 2, i32 2, i32 2]
@.str = [13 x i8] c"Not Possible\00"
define i32 @main() {
%1 = alloca [7 x i32]
%2 = bitcast [7 x i32]* %1 to i8*
%3 = getelementptr inbounds [7 x i32], [7 x i32]* %1, i64 0, i64 0
%4 = call i64 @findMaxMultupleOf3(i32* %3, i32 7)
%5 = icmp eq i64 %4, 0
br i1 %5, label %6, label %8
6: ; preds = %0
%7 = call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
br label %8
8: ; preds = %6, %0
ret i32 0
}
/* Type definitions */
typedef int int64_t;

/* Variables and functions */
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, int);
int /*<<< orphan*/ stderr;
void error_not_bool(int64_t val) {
  fprintf(stderr, "expected a boolean: %#010x\n", val);
  exit(1);
}


x86 assembly (clang, -O0):
<error_not_bool>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    0x2eae(%rip),%rax
mov    (%rax),%edi
mov    -0x4(%rbp),%edx
lea    0xec2(%rip),%rsi
call   1030 <fprintf@plt>
mov    $0x1,%edi
call   1040 <exit@plt>

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

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

LLVM IR (-O2):
@stderr = global i32 0
@.str = [28 x i8] c"expected a boolean: %x\0A\00"
define void @error_not_bool(i32 %0) {
%2 = load i32, i32* @stderr
%3 = tail call i32 @fprintf(i32 %2, i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str, i64 0, i64 0), i32 %0)
%4 = tail call i32 @exit(i32 1)
unreachable
}
/* Variables and functions */
int /*<<< orphan*/ _bad_stack_set(int);
void stack_instruction(void) { _bad_stack_set(0xffa10000); }


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

x86 assembly (clang, -O2):
<stack_instruction>:
mov    $0xffa10000,%edi
jmp    1030 <_bad_stack_set@plt>

LLVM IR (-O0):
define void @stack_instruction() {
%1 = call i32 @_bad_stack_set(i32 -6225920)
ret void
}

LLVM IR (-O2):
define void @stack_instruction() {
%1 = tail call i32 @_bad_stack_set(i32 -6225920)
ret void
}
/* Variables and functions */
scalar_t__ malloc(int);
int main() {
  char *str;
  int i;
  str = (char *)malloc(40000);
  for (i = 0; i < 40000; i++) {
    str[i] = 's';
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0x9c40,%edi
call   1030 <malloc@plt>
mov    %rax,-0x10(%rbp)
movl   $0x0,-0x14(%rbp)
cmpl   $0x9c40,-0x14(%rbp)
jge    115b <main+0x4b>
mov    -0x10(%rbp),%rax
movslq -0x14(%rbp),%rcx
movb   $0x73,(%rax,%rcx,1)
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    1134 <main+0x24>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
mov    $0x9c40,%edi
call   1040 <malloc@plt>
mov    $0x9c40,%edx
mov    %rax,%rdi
mov    $0x73,%esi
call   1030 <memset@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca i8*
%3 = alloca i32
store i32 0, i32* %1
%4 = call i64 @malloc(i32 40000)
%5 = inttoptr i64 %4 to i8*
store i8* %5, i8** %2
store i32 0, i32* %3
br label %6
6: ; preds = %14, %0
%7 = load i32, i32* %3
%8 = icmp slt i32 %7, 40000
br i1 %8, label %9, label %17
9: ; preds = %6
%10 = load i8*, i8** %2
%11 = load i32, i32* %3
%12 = sext i32 %11 to i64
%13 = getelementptr inbounds i8, i8* %10, i64 %12
store i8 115, i8* %13
br label %14
14: ; preds = %9
%15 = load i32, i32* %3
%16 = add nsw i32 %15, 1
store i32 %16, i32* %3
br label %6
17: ; preds = %6
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i64 @malloc(i32 40000)
%2 = inttoptr i64 %1 to i8*
ret i32 0
}
/* Variables and functions */
char *get_wonlost_stats_key(char const *, char const *, int /*<<< orphan*/ *);
const char *get_wonlost_stats(const char *me, const char *opponent) {
  char *s = get_wonlost_stats_key(me, opponent, NULL);
  if (s)
    return s;
  return "0-0";
}


x86 assembly (clang, -O0):
<get_wonlost_stats>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
xor    %eax,%eax
mov    %eax,%edx
call   1030 <get_wonlost_stats_key@plt>
mov    %rax,-0x20(%rbp)
cmpq   $0x0,-0x20(%rbp)
je     114d <get_wonlost_stats+0x3d>
mov    -0x20(%rbp),%rax
mov    %rax,-0x8(%rbp)
jmp    1158 <get_wonlost_stats+0x48>
lea    0xeac(%rip),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<get_wonlost_stats>:
push   %rax
xor    %edx,%edx
call   1030 <get_wonlost_stats_key@plt>
test   %rax,%rax
lea    0xede(%rip),%rcx
cmove  %rcx,%rax
pop    %rcx
ret

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

LLVM IR (-O2):
@.str = [4 x i8] c"0-0\00"
define i8* @get_wonlost_stats(i8* %0, i8* %1) {
%3 = tail call i8* @get_wonlost_stats_key(i8* %0, i8* %1, i32* null)
%4 = icmp eq i8* %3, null
%5 = select i1 %4, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* %3
ret i8* %5
}
void bpt(p, a, s) struct h8_opcode *p;
char *a;
int s;
{
  printf("saved_state.exception = SIGTRAP;\n");
  printf("npc = pc;\n");
}


x86 assembly (clang, -O0):
<bpt>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
lea    0xed6(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xeea(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
add    $0x20,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
%struct.h8_opcode = type opaque
@.str = [34 x i8] c"saved_state.exception = SIGTRAP;\0A\00"
@.str.1 = [11 x i8] c"npc = pc;\0A\00"
define void @bpt(%struct.h8_opcode* %0, i8* %1, i32 %2) {
%4 = alloca %struct.h8_opcode*
%5 = alloca i8*
%6 = alloca i32
store %struct.h8_opcode* %0, %struct.h8_opcode** %4
store i8* %1, i8** %5
store i32 %2, i32* %6
%7 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str, i64 0, i64 0))
%8 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
%struct.h8_opcode = type opaque
@str = [33 x i8] c"saved_state.exception = SIGTRAP;\00"
@str.2 = [10 x i8] c"npc = pc;\00"
define void @bpt(%struct.h8_opcode* nocapture readnone %0, i8* nocapture readnone %1, i32 %2) {
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([33 x i8], [33 x i8]* @str, i64 0, i64 0))
%5 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @str.2, i64 0, i64 0))
ret void
}
int lower(int c) { return c >= 'A' && c <= 'Z' ? c += 'a' - 'A' : c; }


x86 assembly (clang, -O0):
<lower>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
cmpl   $0x41,-0x4(%rbp)
jl     112c <lower+0x2c>
cmpl   $0x5a,-0x4(%rbp)
jg     112c <lower+0x2c>
mov    -0x4(%rbp),%eax
add    $0x20,%eax
mov    %eax,-0x4(%rbp)
mov    %eax,-0x8(%rbp)
jmp    1132 <lower+0x32>
mov    -0x4(%rbp),%eax
mov    %eax,-0x8(%rbp)
mov    -0x8(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<lower>:
lea    -0x41(%rdi),%ecx
lea    0x20(%rdi),%eax
cmp    $0x1a,%ecx
cmovae %edi,%eax
ret

LLVM IR (-O0):
define i32 @lower(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = icmp sge i32 %3, 65
br i1 %4, label %5, label %11
5: ; preds = %1
%6 = load i32, i32* %2
%7 = icmp sle i32 %6, 90
br i1 %7, label %8, label %11
8: ; preds = %5
%9 = load i32, i32* %2
%10 = add nsw i32 %9, 32
store i32 %10, i32* %2
br label %13
11: ; preds = %5, %1
%12 = load i32, i32* %2
br label %13
13: ; preds = %11, %8
%14 = phi i32 [ %10, %8 ], [ %12, %11 ]
ret i32 %14
}

LLVM IR (-O2):
define i32 @lower(i32 %0) {
%2 = add i32 %0, -65
%3 = icmp ult i32 %2, 26
%4 = add nsw i32 %0, 32
%5 = select i1 %3, i32 %4, i32 %0
ret i32 %5
}
/* Type definitions */
typedef int uint8_t;

/* Variables and functions */
int /*<<< orphan*/ parsePTStoString(int *);
int main(int argc, char **argv) {
  uint8_t pts[] = {0x27, 0x4E, 0xA3, 0x83, 0x1B};
  parsePTStoString(pts);
  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    0xed3(%rip),%rax
mov    %rax,-0x30(%rbp)
mov    0xed0(%rip),%rax
mov    %rax,-0x28(%rbp)
mov    0xece(%rip),%eax
mov    %eax,-0x20(%rbp)
lea    -0x30(%rbp),%rdi
call   1030 <parsePTStoString@plt>
xor    %eax,%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
sub    $0x18,%rsp
mov    0xef6(%rip),%eax
mov    %eax,0x10(%rsp)
movaps 0xedb(%rip),%xmm0
movaps %xmm0,(%rsp)
mov    %rsp,%rdi
call   1030 <parsePTStoString@plt>
xor    %eax,%eax
add    $0x18,%rsp
ret

LLVM IR (-O0):
@__const.main.pts = [5 x i32] [i32 39, i32 78, i32 163, i32 131, i32 27]
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca [5 x i32]
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%7 = bitcast [5 x i32]* %6 to i8*
%8 = getelementptr inbounds [5 x i32], [5 x i32]* %6, i64 0, i64 0
%9 = call i32 @parsePTStoString(i32* %8)
ret i32 0
}

LLVM IR (-O2):
@__const.main.pts = [5 x i32] [i32 39, i32 78, i32 163, i32 131, i32 27]
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = alloca [5 x i32]
%4 = bitcast [5 x i32]* %3 to i8*
%5 = getelementptr inbounds [5 x i32], [5 x i32]* %3, i64 0, i64 0
%6 = call i32 @parsePTStoString(i32* %5)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ frontend_version();
int /*<<< orphan*/ newline();
int /*<<< orphan*/ output_line(char *);
int /*<<< orphan*/ output_string(char *);
void header(void) {
  output_string("; Small C Debug\n;\tCoder (ac0)\n;");
  frontend_version();
  newline();
  output_line("\t;program area SMALLC_GENERATED is RELOCATABLE");
  output_line("\t.module SMALLC_GENERATED");
}


x86 assembly (clang, -O0):
<header>:
push   %rbp
mov    %rsp,%rbp
lea    0xeb5(%rip),%rdi
call   1040 <output_string@plt>
mov    $0x0,%al
call   1050 <frontend_version@plt>
mov    $0x0,%al
call   1030 <newline@plt>
lea    0xebb(%rip),%rdi
call   1060 <output_line@plt>
lea    0xede(%rip),%rdi
call   1060 <output_line@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<header>:
push   %rax
lea    0xeb8(%rip),%rdi
call   1040 <output_string@plt>
xor    %eax,%eax
call   1050 <frontend_version@plt>
xor    %eax,%eax
call   1030 <newline@plt>
lea    0xebe(%rip),%rdi
call   1060 <output_line@plt>
lea    0xee1(%rip),%rdi
pop    %rax
jmp    1060 <output_line@plt>

LLVM IR (-O0):
@.str = [32 x i8] c"; Small C Debug\0A;\09Coder (ac0)\0A;\00"
@.str.1 = [47 x i8] c"\09;program area SMALLC_GENERATED is RELOCATABLE\00"
@.str.2 = [26 x i8] c"\09.module SMALLC_GENERATED\00"
define void @header() {
%1 = call i32 @output_string(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str, i64 0, i64 0))
%2 = call i32 (...) @frontend_version()
%3 = call i32 (...) @newline()
%4 = call i32 @output_line(i8* getelementptr inbounds ([47 x i8], [47 x i8]* @.str.1, i64 0, i64 0))
%5 = call i32 @output_line(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.2, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [32 x i8] c"; Small C Debug\0A;\09Coder (ac0)\0A;\00"
@.str.1 = [47 x i8] c"\09;program area SMALLC_GENERATED is RELOCATABLE\00"
@.str.2 = [26 x i8] c"\09.module SMALLC_GENERATED\00"
define void @header() {
%1 = tail call i32 @output_string(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 (...) @frontend_version()
%3 = tail call i32 (...) @newline()
%4 = tail call i32 @output_line(i8* getelementptr inbounds ([47 x i8], [47 x i8]* @.str.1, i64 0, i64 0))
%5 = tail call i32 @output_line(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.2, i64 0, i64 0))
ret void
}
void message_handler_req_lib_amf_csiquiescingcomplete(void *conn, void *msg) {}


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

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

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

LLVM IR (-O2):
define void @message_handler_req_lib_amf_csiquiescingcomplete(i8* nocapture %0, i8* nocapture %1) {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *);
int /*<<< orphan*/ stdout;
int usage(void) {
  fprintf(stdout, "resv_unwritten <-f path> <-s start> <-l length>\n");
  fprintf(stdout, "Example:\n"
                  "       resv_unwritten -f /storage/testifle "
                  "-s 0 -l 1073741824\n");
  exit(1);
}


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

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

LLVM IR (-O0):
@stdout = global i32 0
@.str = [49 x i8] c"resv_unwritten <-f path> <-s start> <-l length>\0A\00"
@.str.1 = [72 x i8] c"Example:\0A resv_unwritten -f /storage/testifle -s 0 -l 1073741824\0A\00"
define i32 @usage() {
%1 = load i32, i32* @stdout
%2 = call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([49 x i8], [49 x i8]* @.str, i64 0, i64 0))
%3 = load i32, i32* @stdout
%4 = call i32 @fprintf(i32 %3, i8* getelementptr inbounds ([72 x i8], [72 x i8]* @.str.1, i64 0, i64 0))
%5 = call i32 @exit(i32 1)
unreachable
}

LLVM IR (-O2):
@stdout = global i32 0
@.str = [49 x i8] c"resv_unwritten <-f path> <-s start> <-l length>\0A\00"
@.str.1 = [72 x i8] c"Example:\0A resv_unwritten -f /storage/testifle -s 0 -l 1073741824\0A\00"
define i32 @usage() {
%1 = load i32, i32* @stdout
%2 = tail call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([49 x i8], [49 x i8]* @.str, i64 0, i64 0))
%3 = load i32, i32* @stdout
%4 = tail call i32 @fprintf(i32 %3, i8* getelementptr inbounds ([72 x i8], [72 x i8]* @.str.1, i64 0, i64 0))
%5 = tail call i32 @exit(i32 1)
unreachable
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, double, double);
int /*<<< orphan*/ scanf(char *, double *);
int main() {
  double meter = 0.0;
  double km = 0.0;
  scanf("%lf", &meter);
  km = meter / 1000.0;
  printf("%lf meters = %lf km\n", meter, km);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x10(%rbp)
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x18(%rbp)
lea    0xec2(%rip),%rdi
lea    -0x10(%rbp),%rsi
call   1040 <scanf@plt>
movsd  -0x10(%rbp),%xmm0
movsd  0xea4(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x18(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  -0x18(%rbp),%xmm1
lea    0xe96(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
movq   $0x0,(%rsp)
lea    0xed8(%rip),%rdi
mov    %rsp,%rsi
call   1040 <scanf@plt>
movsd  (%rsp),%xmm0
movapd %xmm0,%xmm1
divsd  0xeb7(%rip),%xmm1
lea    0xebc(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [4 x i8] c"%lf\00"
@.str.1 = [21 x i8] c"%lf meters = %lf km\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca double
%3 = alloca double
store i32 0, i32* %1
store double 0.000000e+00, double* %2
store double 0.000000e+00, double* %3
%4 = call i32 @scanf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), double* %2)
%5 = load double, double* %2
%6 = fdiv double %5, 1.000000e+03
store double %6, double* %3
%7 = load double, double* %2
%8 = load double, double* %3
%9 = call i32 @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.1, i64 0, i64 0), double %7, double %8)
ret i32 0
}

LLVM IR (-O2):
@.str = [4 x i8] c"%lf\00"
@.str.1 = [21 x i8] c"%lf meters = %lf km\0A\00"
define i32 @main() {
%1 = alloca double
%2 = bitcast double* %1 to i8*
store double 0.000000e+00, double* %1
%3 = call i32 @scanf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), double* %1)
%4 = load double, double* %1
%5 = fdiv double %4, 1.000000e+03
%6 = call i32 @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.1, i64 0, i64 0), double %4, double %5)
ret i32 0
}
int f_r(int (*ptr)(int *, int *), int first, int sec) {
  int rez = 0;
  rez = ((*ptr)(&first, &sec));
  return rez;
}


x86 assembly (clang, -O0):
<f_r>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %edx,-0x10(%rbp)
movl   $0x0,-0x14(%rbp)
lea    -0xc(%rbp),%rdi
lea    -0x10(%rbp),%rsi
call   *-0x8(%rbp)
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<f_r>:
push   %rax
mov    %rdi,%rax
mov    %esi,0x4(%rsp)
mov    %edx,(%rsp)
lea    0x4(%rsp),%rdi
mov    %rsp,%rsi
call   *%rax
pop    %rcx
ret

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

LLVM IR (-O2):
define i32 @f_r(i32 (i32*, i32*)* nocapture %0, i32 %1, i32 %2) {
%4 = alloca i32
%5 = alloca i32
store i32 %1, i32* %4
store i32 %2, i32* %5
%6 = call i32 %0(i32* %4, i32* %5)
ret i32 %6
}