xunge/DecIR huggingface dataset:
/* Variables and functions */
int /*<<< orphan*/ do_expression();
int /*<<< orphan*/ eat_blanks();
int /*<<< orphan*/ puts(char *);
void do_return(void) {
  eat_blanks();
  do_expression();
  puts("\tloadrr R7, R1");
  puts("\tret");
}


x86 assembly (clang, -O0):
<do_return>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1040 <eat_blanks@plt>
mov    $0x0,%al
call   1050 <do_expression@plt>
lea    0xeb7(%rip),%rdi
call   1030 <puts@plt>
lea    0xeba(%rip),%rdi
call   1030 <puts@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<do_return>:
push   %rax
xor    %eax,%eax
call   1040 <eat_blanks@plt>
xor    %eax,%eax
call   1050 <do_expression@plt>
lea    0xeba(%rip),%rdi
call   1030 <puts@plt>
lea    0xebd(%rip),%rdi
pop    %rax
jmp    1030 <puts@plt>

LLVM IR (-O0):
@.str = [15 x i8] c"\09loadrr R7, R1\00"
@.str.1 = [5 x i8] c"\09ret\00"
define void @do_return() {
%1 = call i32 (...) @eat_blanks()
%2 = call i32 (...) @do_expression()
%3 = call i32 @puts(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0))
%4 = call i32 @puts(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [15 x i8] c"\09loadrr R7, R1\00"
@.str.1 = [5 x i8] c"\09ret\00"
define void @do_return() {
%1 = tail call i32 (...) @eat_blanks()
%2 = tail call i32 (...) @do_expression()
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0))
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0))
ret void
}
void EVP_ecdsa(void) {}


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

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

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

LLVM IR (-O2):
define void @EVP_ecdsa() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ EINVAL;
int /*<<< orphan*/ errno;
int uart_unlink(const char *name __attribute__((unused))) {
  errno = EINVAL;
  return -1;
}


x86 assembly (clang, -O0):
<uart_unlink>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    0x2ec9(%rip),%rax
mov    (%rax),%ecx
mov    0x2ec8(%rip),%rax
mov    %ecx,(%rax)
mov    $0xffffffff,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<uart_unlink>:
mov    0x2ed1(%rip),%rax
mov    (%rax),%eax
mov    0x2ed0(%rip),%rcx
mov    %eax,(%rcx)
mov    $0xffffffff,%eax
ret

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

LLVM IR (-O2):
@EINVAL = global i32 0
@errno = global i32 0
define i32 @uart_unlink(i8* nocapture readnone %0) {
%2 = load i32, i32* @EINVAL
store i32 %2, i32* @errno
ret i32 -1
}
void USB_LP_IRQHandler(void) {}


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

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

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

LLVM IR (-O2):
define void @USB_LP_IRQHandler() {
ret void
}
char CHAR2BCD2(char input) {
  char high = 0;
  while (input >= 10) {
    high++;
    input -= 10;
  }
  return (high << 4) | input;
}


x86 assembly (clang, -O0):
<CHAR2BCD2>:
push   %rbp
mov    %rsp,%rbp
mov    %dil,%al
mov    %al,-0x1(%rbp)
movb   $0x0,-0x2(%rbp)
movsbl -0x1(%rbp),%eax
cmp    $0xa,%eax
jl     1132 <CHAR2BCD2+0x32>
mov    -0x2(%rbp),%al
add    $0x1,%al
mov    %al,-0x2(%rbp)
movsbl -0x1(%rbp),%eax
sub    $0xa,%eax
mov    %al,-0x1(%rbp)
jmp    110e <CHAR2BCD2+0xe>
movsbl -0x2(%rbp),%eax
shl    $0x4,%eax
movsbl -0x1(%rbp),%ecx
or     %ecx,%eax
movsbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<CHAR2BCD2>:
mov    %edi,%eax
cmp    $0xa,%al
jl     113f <CHAR2BCD2+0x3f>
movzbl %al,%ecx
cmp    $0x13,%al
mov    $0x13,%edx
cmovl  %ecx,%edx
mov    %eax,%ecx
sub    %dl,%cl
add    $0x9,%cl
movzbl %cl,%ecx
imul   $0xcd,%ecx,%ecx
shr    $0xb,%ecx
mov    %ecx,%edx
add    %edx,%edx
lea    (%rdx,%rdx,4),%edx
neg    %edx
add    %al,%dl
add    $0xf6,%dl
shl    $0x4,%cl
add    $0x10,%cl
mov    %edx,%eax
or     %cl,%al
ret
xor    %ecx,%ecx
or     %cl,%al
ret

LLVM IR (-O0):
define signext i8 @CHAR2BCD2(i8 signext %0) {
%2 = alloca i8
%3 = alloca i8
store i8 %0, i8* %2
store i8 0, i8* %3
br label %4
4: ; preds = %8, %1
%5 = load i8, i8* %2
%6 = sext i8 %5 to i32
%7 = icmp sge i32 %6, 10
br i1 %7, label %8, label %15
8: ; preds = %4
%9 = load i8, i8* %3
%10 = add i8 %9, 1
store i8 %10, i8* %3
%11 = load i8, i8* %2
%12 = sext i8 %11 to i32
%13 = sub nsw i32 %12, 10
%14 = trunc i32 %13 to i8
store i8 %14, i8* %2
br label %4
15: ; preds = %4
%16 = load i8, i8* %3
%17 = sext i8 %16 to i32
%18 = shl i32 %17, 4
%19 = load i8, i8* %2
%20 = sext i8 %19 to i32
%21 = or i32 %18, %20
%22 = trunc i32 %21 to i8
ret i8 %22
}

LLVM IR (-O2):
define signext i8 @CHAR2BCD2(i8 signext %0) {
%2 = icmp sgt i8 %0, 9
br i1 %2, label %3, label %13
3: ; preds = %1
%4 = add nuw i8 %0, 9
%5 = call i8 @llvm.smin.i8(i8 %0, i8 19)
%6 = sub nuw i8 %4, %5
%7 = udiv i8 %6, 10
%8 = mul nsw i8 %7, -10
%9 = add nsw i8 %0, -10
%10 = add nsw i8 %8, %9
%11 = shl nuw i8 %7, 4
%12 = add nuw i8 %11, 16
br label %13
13: ; preds = %3, %1
%14 = phi i8 [ %0, %1 ], [ %10, %3 ]
%15 = phi i8 [ 0, %1 ], [ %12, %3 ]
%16 = or i8 %15, %14
ret i8 %16
}
int in_def_clean_binds(void *drv_data, int *b, int *db) { return 1; }


x86 assembly (clang, -O0):
<in_def_clean_binds>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    $0x1,%eax
pop    %rbp
ret

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

LLVM IR (-O0):
define i32 @in_def_clean_binds(i8* %0, i32* %1, i32* %2) {
%4 = alloca i8*
%5 = alloca i32*
%6 = alloca i32*
store i8* %0, i8** %4
store i32* %1, i32** %5
store i32* %2, i32** %6
ret i32 1
}

LLVM IR (-O2):
define i32 @in_def_clean_binds(i8* nocapture readnone %0, i32* nocapture readnone %1, i32* nocapture readnone %2) {
ret i32 1
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int);
int main() {
  int age = 10;
  int height = 72;
  printf("\aI am %d years old.\n", age);
  printf("I am %d inches tall.\n", height);
  return 0;
}


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

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

LLVM IR (-O0):
@.str = [21 x i8] c"\07I am %d years old.\0A\00"
@.str.1 = [22 x i8] c"I am %d inches tall.\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
store i32 0, i32* %1
store i32 10, i32* %2
store i32 72, i32* %3
%4 = load i32, i32* %2
%5 = call i32 @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0), i32 %4)
%6 = load i32, i32* %3
%7 = call i32 @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.1, i64 0, i64 0), i32 %6)
ret i32 0
}

LLVM IR (-O2):
@.str = [21 x i8] c"\07I am %d years old.\0A\00"
@.str.1 = [22 x i8] c"I am %d inches tall.\0A\00"
define i32 @main() {
%1 = tail call i32 @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0), i32 10)
%2 = tail call i32 @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.1, i64 0, i64 0), i32 72)
ret i32 0
}
int fun1066() { return 1066; }


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

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

LLVM IR (-O0):
define i32 @fun1066() {
ret i32 1066
}

LLVM IR (-O2):
define i32 @fun1066() {
ret i32 1066
}
/* Type definitions */
typedef int /*<<< orphan*/ responseCode;

/* Variables and functions */
int /*<<< orphan*/ send(int, int *, int, int /*<<< orphan*/);
void handle_help(int fd) {
  int responseCode = 2;
  send(fd, &responseCode, sizeof(responseCode), 0);
}


x86 assembly (clang, -O0):
<handle_help>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
movl   $0x2,-0x8(%rbp)
mov    -0x4(%rbp),%edi
lea    -0x8(%rbp),%rsi
mov    $0x4,%edx
xor    %ecx,%ecx
call   1030 <send@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<handle_help>:
push   %rax
movl   $0x2,0x4(%rsp)
lea    0x4(%rsp),%rsi
mov    $0x4,%edx
xor    %ecx,%ecx
call   1030 <send@plt>
pop    %rax
ret

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

LLVM IR (-O2):
define void @handle_help(i32 %0) {
%2 = alloca i32
%3 = bitcast i32* %2 to i8*
store i32 2, i32* %2
%4 = call i32 @send(i32 %0, i32* %2, i32 4, i32 0)
ret void
}
/* Type definitions */
typedef int uint8_t;

/* Variables and functions */
int is_not_exported_symbol(const uint8_t n_type) {
  const uint8_t mask = (0x01 | 0xe0);
  return ((n_type & mask) - 0x01);
}


x86 assembly (clang, -O0):
<is_not_exported_symbol>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
movl   $0xe1,-0x8(%rbp)
mov    -0x4(%rbp),%eax
and    $0xe1,%eax
sub    $0x1,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_not_exported_symbol>:
and    $0xe1,%edi
lea    -0x1(%rdi),%eax
ret

LLVM IR (-O0):
define i32 @is_not_exported_symbol(i32 %0) {
%2 = alloca i32
%3 = alloca i32
store i32 %0, i32* %2
store i32 225, i32* %3
%4 = load i32, i32* %2
%5 = and i32 %4, 225
%6 = sub nsw i32 %5, 1
ret i32 %6
}

LLVM IR (-O2):
define i32 @is_not_exported_symbol(i32 %0) {
%2 = and i32 %0, 225
%3 = add nsw i32 %2, -1
ret i32 %3
}
/* Type definitions */
typedef int uint64_t;

/* Variables and functions */
uint64_t geopm_region_id_unset_hint(uint64_t hint_type, uint64_t region_id) {
  return (region_id & (~hint_type));
}


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

x86 assembly (clang, -O2):
<geopm_region_id_unset_hint>:
mov    %edi,%eax
not    %eax
and    %esi,%eax
ret

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

LLVM IR (-O2):
define i32 @geopm_region_id_unset_hint(i32 %0, i32 %1) {
%3 = xor i32 %0, -1
%4 = and i32 %3, %1
ret i32 %4
}
/* Variables and functions */
int /*<<< orphan*/ EINVAL;
int /*<<< orphan*/ errno;
int /*<<< orphan*/ putenv(char *);
int /*<<< orphan*/ *strchr(char const *, char);
int unsetenv(const char *name) {
  if ((name == NULL) || !*name || (strchr(name, '=') != NULL)) {
    errno = EINVAL;
    return -1;
  }
  putenv((char *)name);
  return 0;
}


x86 assembly (clang, -O0):
<unsetenv>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x10(%rbp)
cmpq   $0x0,-0x10(%rbp)
je     115c <unsetenv+0x3c>
mov    -0x10(%rbp),%rax
cmpb   $0x0,(%rax)
je     115c <unsetenv+0x3c>
mov    -0x10(%rbp),%rdi
mov    $0x3d,%esi
call   1030 <strchr@plt>
cmp    $0x0,%rax
je     117a <unsetenv+0x5a>
mov    0x2e75(%rip),%rax
mov    (%rax),%ecx
mov    0x2e74(%rip),%rax
mov    %ecx,(%rax)
movl   $0xffffffff,-0x4(%rbp)
jmp    118a <unsetenv+0x6a>
mov    -0x10(%rbp),%rdi
call   1040 <putenv@plt>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<unsetenv>:
push   %rbx
test   %rdi,%rdi
je     1140 <unsetenv+0x20>
mov    %rdi,%rbx
cmpb   $0x0,(%rdi)
je     1140 <unsetenv+0x20>
mov    %rbx,%rdi
mov    $0x3d,%esi
call   1030 <strchr@plt>
test   %rax,%rax
je     1159 <unsetenv+0x39>
mov    0x2e91(%rip),%rax
mov    (%rax),%eax
mov    0x2e90(%rip),%rcx
mov    %eax,(%rcx)
mov    $0xffffffff,%eax
pop    %rbx
ret
mov    %rbx,%rdi
call   1040 <putenv@plt>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
@EINVAL = global i32 0
@errno = global i32 0
define i32 @unsetenv(i8* %0) {
%2 = alloca i32
%3 = alloca i8*
store i8* %0, i8** %3
%4 = load i8*, i8** %3
%5 = icmp eq i8* %4, null
br i1 %5, label %14, label %6
6: ; preds = %1
%7 = load i8*, i8** %3
%8 = load i8, i8* %7
%9 = icmp ne i8 %8, 0
br i1 %9, label %10, label %14
10: ; preds = %6
%11 = load i8*, i8** %3
%12 = call i32* @strchr(i8* %11, i8 signext 61)
%13 = icmp ne i32* %12, null
br i1 %13, label %14, label %16
14: ; preds = %10, %6, %1
%15 = load i32, i32* @EINVAL
store i32 %15, i32* @errno
store i32 -1, i32* %2
br label %19
16: ; preds = %10
%17 = load i8*, i8** %3
%18 = call i32 @putenv(i8* %17)
store i32 0, i32* %2
br label %19
19: ; preds = %16, %14
%20 = load i32, i32* %2
ret i32 %20
}

LLVM IR (-O2):
@EINVAL = global i32 0
@errno = global i32 0
define i32 @unsetenv(i8* %0) {
%2 = icmp eq i8* %0, null
br i1 %2, label %9, label %3
3: ; preds = %1
%4 = load i8, i8* %0
%5 = icmp eq i8 %4, 0
br i1 %5, label %9, label %6
6: ; preds = %3
%7 = tail call i32* @strchr(i8* %0, i8 signext 61)
%8 = icmp eq i32* %7, null
br i1 %8, label %11, label %9
9: ; preds = %6, %3, %1
%10 = load i32, i32* @EINVAL
store i32 %10, i32* @errno
br label %13
11: ; preds = %6
%12 = tail call i32 @putenv(i8* %0)
br label %13
13: ; preds = %11, %9
%14 = phi i32 [ -1, %9 ], [ 0, %11 ]
ret i32 %14
}
/* Variables and functions */
int /*<<< orphan*/ *strchr(char const *, char);
int osapi_is_filename(const char *file) {
  if (strchr(file, '/') == NULL)
    return 1;
  return 0;
}


x86 assembly (clang, -O0):
<osapi_is_filename>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
mov    $0x2f,%esi
call   1030 <strchr@plt>
cmp    $0x0,%rax
jne    1140 <osapi_is_filename+0x30>
movl   $0x1,-0x4(%rbp)
jmp    1147 <osapi_is_filename+0x37>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<osapi_is_filename>:
push   %rax
mov    $0x2f,%esi
call   1030 <strchr@plt>
xor    %ecx,%ecx
test   %rax,%rax
sete   %cl
mov    %ecx,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @osapi_is_filename(i8* %0) {
%2 = alloca i32
%3 = alloca i8*
store i8* %0, i8** %3
%4 = load i8*, i8** %3
%5 = call i32* @strchr(i8* %4, i8 signext 47)
%6 = icmp eq i32* %5, null
br i1 %6, label %7, label %8
7: ; preds = %1
store i32 1, i32* %2
br label %9
8: ; preds = %1
store i32 0, i32* %2
br label %9
9: ; preds = %8, %7
%10 = load i32, i32* %2
ret i32 %10
}

LLVM IR (-O2):
define i32 @osapi_is_filename(i8* %0) {
%2 = tail call i32* @strchr(i8* %0, i8 signext 47)
%3 = icmp eq i32* %2, null
%4 = zext i1 %3 to i32
ret i32 %4
}
/* Variables and functions */
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *);
int /*<<< orphan*/ stderr;
void badusage(void) {
  fprintf(stderr,
          "Usage: fsaor [-ip d/s[dr]] [-op d/s] [-silent] [-v] [-l/-h]\n");
  fprintf(stderr, "       filename1 filename2 outfilename\n");
  exit(1);
}


x86 assembly (clang, -O0):
<badusage>:
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    0xef4(%rip),%rsi
call   1030 <fprintf@plt>
mov    $0x1,%edi
call   1040 <exit@plt>

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

LLVM IR (-O0):
@stderr = global i32 0
@.str = [61 x i8] c"Usage: fsaor [-ip d/s[dr]] [-op d/s] [-silent] [-v] [-l/-h]\0A\00"
@.str.1 = [40 x i8] c" filename1 filename2 outfilename\0A\00"
define void @badusage() {
%1 = load i32, i32* @stderr
%2 = call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([61 x i8], [61 x i8]* @.str, i64 0, i64 0))
%3 = load i32, i32* @stderr
%4 = call i32 @fprintf(i32 %3, i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str.1, i64 0, i64 0))
%5 = call i32 @exit(i32 1)
unreachable
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [61 x i8] c"Usage: fsaor [-ip d/s[dr]] [-op d/s] [-silent] [-v] [-l/-h]\0A\00"
@.str.1 = [40 x i8] c" filename1 filename2 outfilename\0A\00"
define void @badusage() {
%1 = load i32, i32* @stderr
%2 = tail call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([61 x i8], [61 x i8]* @.str, i64 0, i64 0))
%3 = load i32, i32* @stderr
%4 = tail call i32 @fprintf(i32 %3, i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str.1, i64 0, i64 0))
%5 = tail call i32 @exit(i32 1)
unreachable
}
void RTAvloIOPortRemove(void) {}


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

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

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

LLVM IR (-O2):
define void @RTAvloIOPortRemove() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int);
int main(void) {
  printf("%p\n", NULL);
  printf("%p\n", (void *)(!NULL));
  printf("%ld\n", (long)NULL);
  printf("%d\n", !NULL);
  return 0;
}


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

x86 assembly (clang, -O2):
<main>:
push   %rbx
lea    0xee8(%rip),%rbx
mov    %rbx,%rdi
xor    %esi,%esi
call   1030 <printf@plt>
mov    %rbx,%rdi
mov    $0x1,%esi
call   1030 <printf@plt>
lea    0xece(%rip),%rdi
xor    %esi,%esi
call   1030 <printf@plt>
lea    0xec5(%rip),%rdi
mov    $0x1,%esi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [4 x i8] c"%p\0A\00"
@.str.1 = [5 x i8] c"%ld\0A\00"
@.str.2 = [4 x i8] c"%d\0A\00"
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 0)
%3 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 ptrtoint (i8* inttoptr (i64 1 to i8*) to i32))
%4 = call i32 @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i32 0)
%5 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 1)
ret i32 0
}

LLVM IR (-O2):
@.str = [4 x i8] c"%p\0A\00"
@.str.1 = [5 x i8] c"%ld\0A\00"
@.str.2 = [4 x i8] c"%d\0A\00"
define i32 @main() {
%1 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 0)
%2 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 1)
%3 = tail call i32 @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i32 0)
%4 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 1)
ret i32 0
}
int vifm_system(char command[]) {
  {
    log_prefix("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
               "outputs/2022-01-22/02-19-57/repos/cosminadrianpopescu/vifm/"
               "refs/heads/master/src/utils/utils.c",
               __FUNCTION__, 71);
    log_vifm_state();
    log_msg(("Shell command: %s"), command);
  };
  return run_in_shell_no_cls(command);
}


x86 assembly (clang, -O0):
<vifm_system>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
lea    0xead(%rip),%rdi
lea    0xf3d(%rip),%rsi
mov    $0x47,%edx
mov    $0x0,%al
call   1030 <log_prefix@plt>
mov    $0x0,%al
call   1050 <log_vifm_state@plt>
mov    -0x8(%rbp),%rsi
lea    0xf2b(%rip),%rdi
mov    $0x0,%al
call   1060 <log_msg@plt>
mov    -0x8(%rbp),%rdi
mov    $0x0,%al
call   1040 <run_in_shell_no_cls@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<vifm_system>:
push   %rbx
mov    %rdi,%rbx
lea    0xeb5(%rip),%rdi
lea    0xf45(%rip),%rsi
mov    $0x47,%edx
xor    %eax,%eax
call   1030 <log_prefix@plt>
xor    %eax,%eax
call   1050 <log_vifm_state@plt>
lea    0xf37(%rip),%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   1060 <log_msg@plt>
mov    %rbx,%rdi
xor    %eax,%eax
pop    %rbx
jmp    1040 <run_in_shell_no_cls@plt>

LLVM IR (-O0):
@.str = [151 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/cosminadrianpopescu/vifm/refs/heads/master/src/utils/utils.c\00"
@__FUNCTION__.vifm_system = [12 x i8] c"vifm_system\00"
@.str.1 = [18 x i8] c"Shell command: %s\00"
define i32 @vifm_system(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = call i32 (i8*, i8*, i32, ...) bitcast (i32 (...)* @log_prefix to i32 (i8*, i8*, i32, ...)*)(i8* getelementptr inbounds ([151 x i8], [151 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([12 x i8], [12 x i8]* @__FUNCTION__.vifm_system, i64 0, i64 0), i32 71)
%4 = call i32 (...) @log_vifm_state()
%5 = load i8*, i8** %2
%6 = call i32 (i8*, i8*, ...) bitcast (i32 (...)* @log_msg to i32 (i8*, i8*, ...)*)(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.1, i64 0, i64 0), i8* %5)
%7 = load i8*, i8** %2
%8 = call i32 (i8*, ...) bitcast (i32 (...)* @run_in_shell_no_cls to i32 (i8*, ...)*)(i8* %7)
ret i32 %8
}

LLVM IR (-O2):
@.str = [151 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/cosminadrianpopescu/vifm/refs/heads/master/src/utils/utils.c\00"
@__FUNCTION__.vifm_system = [12 x i8] c"vifm_system\00"
@.str.1 = [18 x i8] c"Shell command: %s\00"
define i32 @vifm_system(i8* %0) {
%2 = tail call i32 (i8*, i8*, i32, ...) bitcast (i32 (...)* @log_prefix to i32 (i8*, i8*, i32, ...)*)(i8* getelementptr inbounds ([151 x i8], [151 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([12 x i8], [12 x i8]* @__FUNCTION__.vifm_system, i64 0, i64 0), i32 71)
%3 = tail call i32 (...) @log_vifm_state()
%4 = tail call i32 (i8*, i8*, ...) bitcast (i32 (...)* @log_msg to i32 (i8*, i8*, ...)*)(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.1, i64 0, i64 0), i8* %0)
%5 = tail call i32 (i8*, ...) bitcast (i32 (...)* @run_in_shell_no_cls to i32 (i8*, ...)*)(i8* %0)
ret i32 %5
}
void RTProcCreateEx(void) {}


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

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

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

LLVM IR (-O2):
define void @RTProcCreateEx() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ scc3();
void caller3() { scc3(); }


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

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

LLVM IR (-O0):
define void @caller3() {
%1 = call i32 (...) @scc3()
ret void
}

LLVM IR (-O2):
define void @caller3() {
%1 = tail call i32 (...) @scc3()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ calendar_date(int, int *, int *, int *);
int julian_day(int, int, int);
int day_of_year(int jday) {
  int y, m, d;
  calendar_date(jday, &y, &m, &d);
  return jday - julian_day(y, 1, 1);
}


x86 assembly (clang, -O0):
<day_of_year>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%edi
lea    -0x8(%rbp),%rsi
lea    -0xc(%rbp),%rdx
lea    -0x10(%rbp),%rcx
call   1040 <calendar_date@plt>
mov    -0x4(%rbp),%eax
mov    %eax,-0x14(%rbp)
mov    -0x8(%rbp),%edi
mov    $0x1,%edx
mov    %edx,%esi
call   1030 <julian_day@plt>
mov    %eax,%ecx
mov    -0x14(%rbp),%eax
sub    %ecx,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<day_of_year>:
push   %rbx
sub    $0x10,%rsp
mov    %edi,%ebx
lea    0x4(%rsp),%rsi
lea    0xc(%rsp),%rdx
lea    0x8(%rsp),%rcx
call   1040 <calendar_date@plt>
mov    0x4(%rsp),%edi
mov    $0x1,%esi
mov    $0x1,%edx
call   1030 <julian_day@plt>
sub    %eax,%ebx
mov    %ebx,%eax
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
define i32 @day_of_year(i32 %0) {
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store i32 %0, i32* %2
%6 = load i32, i32* %2
%7 = call i32 @calendar_date(i32 %6, i32* %3, i32* %4, i32* %5)
%8 = load i32, i32* %2
%9 = load i32, i32* %3
%10 = call i32 @julian_day(i32 %9, i32 1, i32 1)
%11 = sub nsw i32 %8, %10
ret i32 %11
}

LLVM IR (-O2):
define i32 @day_of_year(i32 %0) {
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = bitcast i32* %2 to i8*
%6 = bitcast i32* %3 to i8*
%7 = bitcast i32* %4 to i8*
%8 = call i32 @calendar_date(i32 %0, i32* %2, i32* %3, i32* %4)
%9 = load i32, i32* %2
%10 = call i32 @julian_day(i32 %9, i32 1, i32 1)
%11 = sub nsw i32 %0, %10
ret i32 %11
}
/* Variables and functions */
int /*<<< orphan*/ abort_crypto_lib(char *);
void check_valid_asymmetric_key_item_size(int size) {
  if (size != 10 + 2048)
    abort_crypto_lib("Illegal size for asymmetric key item");
}


x86 assembly (clang, -O0):
<check_valid_asymmetric_key_item_size>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
cmpl   $0x80a,-0x4(%rbp)
je     1134 <check_valid_asymmetric_key_item_size+0x24>
lea    0xed1(%rip),%rdi
call   1030 <abort_crypto_lib@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<check_valid_asymmetric_key_item_size>:
cmp    $0x80a,%edi
jne    1119 <check_valid_asymmetric_key_item_size+0x9>
ret
lea    0xee0(%rip),%rdi
jmp    1030 <abort_crypto_lib@plt>

LLVM IR (-O0):
@.str = [37 x i8] c"Illegal size for asymmetric key item\00"
define void @check_valid_asymmetric_key_item_size(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = icmp ne i32 %3, 2058
br i1 %4, label %5, label %7
5: ; preds = %1
%6 = call i32 @abort_crypto_lib(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str, i64 0, i64 0))
br label %7
7: ; preds = %5, %1
ret void
}

LLVM IR (-O2):
@.str = [37 x i8] c"Illegal size for asymmetric key item\00"
define void @check_valid_asymmetric_key_item_size(i32 %0) {
%2 = icmp eq i32 %0, 2058
br i1 %2, label %5, label %3
3: ; preds = %1
%4 = tail call i32 @abort_crypto_lib(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str, i64 0, i64 0))
br label %5
5: ; preds = %3, %1
ret void
}
int board_is_c3_sample(void) { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @board_is_c3_sample() {
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ bar(int);
void foo(void) {
  int i = 0, j = 0;
#pragma omp parallel firstprivate(i) private(j)
  {
#pragma omp for
    for (i = 0; i < 2; i++)
      bar(i);
#pragma omp for
    for (j = 0; j < 2; j++)
      bar(j);
  }
}


x86 assembly (clang, -O0):
<foo>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
movl   $0x0,-0x4(%rbp)
cmpl   $0x2,-0x4(%rbp)
jge    114d <foo+0x3d>
mov    -0x4(%rbp),%edi
call   1030 <bar@plt>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    112d <foo+0x1d>
movl   $0x0,-0x8(%rbp)
cmpl   $0x2,-0x8(%rbp)
jge    1174 <foo+0x64>
mov    -0x8(%rbp),%edi
call   1030 <bar@plt>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1154 <foo+0x44>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<foo>:
push   %rax
xor    %edi,%edi
call   1030 <bar@plt>
mov    $0x1,%edi
call   1030 <bar@plt>
xor    %edi,%edi
call   1030 <bar@plt>
mov    $0x1,%edi
pop    %rax
jmp    1030 <bar@plt>

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

LLVM IR (-O2):
define void @foo() {
%1 = tail call i32 @bar(i32 0)
%2 = tail call i32 @bar(i32 1)
%3 = tail call i32 @bar(i32 0)
%4 = tail call i32 @bar(i32 1)
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ __m128i;

/* Variables and functions */
int /*<<< orphan*/ _mm_add_epi32(int /*<<< orphan*/ const,
                                 int /*<<< orphan*/ const);
int /*<<< orphan*/ _mm_madd_epi16(int /*<<< orphan*/ const,
                                  int /*<<< orphan*/ const);
__m128i mm_madd_add_epi16_sse2(const __m128i *const src_1,
                               const __m128i *const src_2,
                               const __m128i *const ker_1,
                               const __m128i *const ker_2) {
  const __m128i madd_1 = _mm_madd_epi16(*src_1, *ker_1);
  const __m128i madd_2 = _mm_madd_epi16(*src_2, *ker_2);
  return _mm_add_epi32(madd_1, madd_2);
}


x86 assembly (clang, -O0):
<mm_madd_add_epi16_sse2>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%edi
mov    -0x18(%rbp),%rax
mov    (%rax),%esi
call   1040 <_mm_madd_epi16@plt>
mov    %eax,-0x24(%rbp)
mov    -0x10(%rbp),%rax
mov    (%rax),%edi
mov    -0x20(%rbp),%rax
mov    (%rax),%esi
call   1040 <_mm_madd_epi16@plt>
mov    %eax,-0x28(%rbp)
mov    -0x24(%rbp),%edi
mov    -0x28(%rbp),%esi
call   1030 <_mm_add_epi32@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<mm_madd_add_epi16_sse2>:
push   %rbp
push   %r14
push   %rbx
mov    %rcx,%r14
mov    %rsi,%rbx
mov    (%rdi),%edi
mov    (%rdx),%esi
call   1040 <_mm_madd_epi16@plt>
mov    %eax,%ebp
mov    (%rbx),%edi
mov    (%r14),%esi
call   1040 <_mm_madd_epi16@plt>
mov    %ebp,%edi
mov    %eax,%esi
pop    %rbx
pop    %r14
pop    %rbp
jmp    1030 <_mm_add_epi32@plt>

LLVM IR (-O0):
define i32 @mm_madd_add_epi16_sse2(i32* %0, i32* %1, i32* %2, i32* %3) {
%5 = alloca i32*
%6 = alloca i32*
%7 = alloca i32*
%8 = alloca i32*
%9 = alloca i32
%10 = alloca i32
store i32* %0, i32** %5
store i32* %1, i32** %6
store i32* %2, i32** %7
store i32* %3, i32** %8
%11 = load i32*, i32** %5
%12 = load i32, i32* %11
%13 = load i32*, i32** %7
%14 = load i32, i32* %13
%15 = call i32 @_mm_madd_epi16(i32 %12, i32 %14)
store i32 %15, i32* %9
%16 = load i32*, i32** %6
%17 = load i32, i32* %16
%18 = load i32*, i32** %8
%19 = load i32, i32* %18
%20 = call i32 @_mm_madd_epi16(i32 %17, i32 %19)
store i32 %20, i32* %10
%21 = load i32, i32* %9
%22 = load i32, i32* %10
%23 = call i32 @_mm_add_epi32(i32 %21, i32 %22)
ret i32 %23
}

LLVM IR (-O2):
define i32 @mm_madd_add_epi16_sse2(i32* nocapture %0, i32* nocapture %1, i32* nocapture %2, i32* nocapture %3) {
%5 = load i32, i32* %0
%6 = load i32, i32* %2
%7 = tail call i32 @_mm_madd_epi16(i32 %5, i32 %6)
%8 = load i32, i32* %1
%9 = load i32, i32* %3
%10 = tail call i32 @_mm_madd_epi16(i32 %8, i32 %9)
%11 = tail call i32 @_mm_add_epi32(i32 %7, i32 %10)
ret i32 %11
}
/* Variables and functions */
int /*<<< orphan*/ curs_set(int);
int /*<<< orphan*/ endwin();
void shutdown(void) {
  curs_set(1);
  endwin();
}


x86 assembly (clang, -O0):
<shutdown>:
push   %rbp
mov    %rsp,%rbp
mov    $0x1,%edi
call   1040 <curs_set@plt>
mov    $0x0,%al
call   1030 <endwin@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<shutdown>:
push   %rax
mov    $0x1,%edi
call   1040 <curs_set@plt>
xor    %eax,%eax
pop    %rcx
jmp    1030 <endwin@plt>

LLVM IR (-O0):
define void @shutdown() {
%1 = call i32 @curs_set(i32 1)
%2 = call i32 (...) @endwin()
ret void
}

LLVM IR (-O2):
define void @shutdown() {
%1 = tail call i32 @curs_set(i32 1)
%2 = tail call i32 (...) @endwin()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ jerry_port_console(char *, char *);
void print_help(char *name) {
  jerry_port_console("Usage: %s [OPTION]... [FILE]...\n"
                     "\n"
                     "Options:\n"
                     "  -h, --help\n"
                     "\n",
                     name);
}


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

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

LLVM IR (-O0):
@.str = [57 x i8] c"Usage: %s [OPTION]... [FILE]...\0A\0AOptions:\0A -h, --help\0A\0A\00"
define void @print_help(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = call i32 @jerry_port_console(i8* getelementptr inbounds ([57 x i8], [57 x i8]* @.str, i64 0, i64 0), i8* %3)
ret void
}

LLVM IR (-O2):
@.str = [57 x i8] c"Usage: %s [OPTION]... [FILE]...\0A\0AOptions:\0A -h, --help\0A\0A\00"
define void @print_help(i8* %0) {
%2 = tail call i32 @jerry_port_console(i8* getelementptr inbounds ([57 x i8], [57 x i8]* @.str, i64 0, i64 0), i8* %0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ EXIT_SUCCESS;
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ printf(char *, char *);
int main(int UNUSED_argc __attribute__((__unused__)),
         char **UNUSED_argv __attribute__((__unused__))) {
  printf("Hello, %s! \n", "Word");
  exit(EXIT_SUCCESS);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
lea    0xec3(%rip),%rdi
lea    0xec9(%rip),%rsi
call   1030 <printf@plt>
mov    0x2e90(%rip),%rax
mov    (%rax),%edi
call   1040 <exit@plt>

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

LLVM IR (-O0):
@.str = [13 x i8] c"Hello, %s! \0A\00"
@.str.1 = [5 x i8] c"Word\00"
@EXIT_SUCCESS = global i32 0
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%6 = call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0))
%7 = load i32, i32* @EXIT_SUCCESS
%8 = call i32 @exit(i32 %7)
unreachable
}

LLVM IR (-O2):
@.str = [13 x i8] c"Hello, %s! \0A\00"
@.str.1 = [5 x i8] c"Word\00"
@EXIT_SUCCESS = global i32 0
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0))
%4 = load i32, i32* @EXIT_SUCCESS
%5 = tail call i32 @exit(i32 %4)
unreachable
}
int GF1_Detect(void) { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @GF1_Detect() {
ret i32 0
}
/* Variables and functions */
scalar_t__ RemoveGPSExif(char const *, int);
int /*<<< orphan*/ printf(char *, char const *);
int RemoveGPSTags(const char *File, int NoChangeMtime) {
  if (RemoveGPSExif(File, NoChangeMtime)) {
    printf(("%s: Removed GPS tags.\n"), File);
    return 1;
  } else {
    printf(("%s: Tag removal failure.\n"), File);
    return 0;
  }
}


x86 assembly (clang, -O0):
<RemoveGPSTags>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %esi,-0x14(%rbp)
mov    -0x10(%rbp),%rdi
mov    -0x14(%rbp),%esi
call   1040 <RemoveGPSExif@plt>
cmp    $0x0,%rax
je     1161 <RemoveGPSTags+0x41>
mov    -0x10(%rbp),%rsi
lea    0xeb0(%rip),%rdi
call   1030 <printf@plt>
movl   $0x1,-0x4(%rbp)
jmp    1178 <RemoveGPSTags+0x58>
mov    -0x10(%rbp),%rsi
lea    0xeab(%rip),%rdi
call   1030 <printf@plt>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<RemoveGPSTags>:
push   %rbp
push   %rbx
push   %rax
mov    %rdi,%rbx
call   1040 <RemoveGPSExif@plt>
xor    %ebp,%ebp
test   %rax,%rax
setne  %bpl
lea    0xedc(%rip),%rax
lea    0xebe(%rip),%rdi
cmove  %rax,%rdi
mov    %rbx,%rsi
call   1030 <printf@plt>
mov    %ebp,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
@.str = [23 x i8] c"%s: Removed GPS tags.\0A\00"
@.str.1 = [26 x i8] c"%s: Tag removal failure.\0A\00"
define i32 @RemoveGPSTags(i8* %0, i32 %1) {
%3 = alloca i32
%4 = alloca i8*
%5 = alloca i32
store i8* %0, i8** %4
store i32 %1, i32* %5
%6 = load i8*, i8** %4
%7 = load i32, i32* %5
%8 = call i64 @RemoveGPSExif(i8* %6, i32 %7)
%9 = icmp ne i64 %8, 0
br i1 %9, label %10, label %13
10: ; preds = %2
%11 = load i8*, i8** %4
%12 = call i32 @printf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str, i64 0, i64 0), i8* %11)
store i32 1, i32* %3
br label %16
13: ; preds = %2
%14 = load i8*, i8** %4
%15 = call i32 @printf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.1, i64 0, i64 0), i8* %14)
store i32 0, i32* %3
br label %16
16: ; preds = %13, %10
%17 = load i32, i32* %3
ret i32 %17
}

LLVM IR (-O2):
@.str = [23 x i8] c"%s: Removed GPS tags.\0A\00"
@.str.1 = [26 x i8] c"%s: Tag removal failure.\0A\00"
define i32 @RemoveGPSTags(i8* %0, i32 %1) {
%3 = tail call i64 @RemoveGPSExif(i8* %0, i32 %1)
%4 = icmp eq i64 %3, 0
%5 = select i1 %4, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str, i64 0, i64 0)
%6 = xor i1 %4, true
%7 = zext i1 %6 to i32
%8 = tail call i32 @printf(i8* %5, i8* %0)
ret i32 %7
}
int _nxweb_setup_listening_socket(int fd) { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @_nxweb_setup_listening_socket(i32 %0) {
ret i32 0
}
float fadd32(float x, float y) { return x + y; }


x86 assembly (clang, -O0):
<fadd32>:
push   %rbp
mov    %rsp,%rbp
movss  %xmm0,-0x4(%rbp)
movss  %xmm1,-0x8(%rbp)
movss  -0x4(%rbp),%xmm0
addss  -0x8(%rbp),%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<fadd32>:
addss  %xmm1,%xmm0
ret

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

LLVM IR (-O2):
define float @fadd32(float %0, float %1) {
%3 = fadd float %0, %1
ret float %3
}
void _setNULL(char *str, int value, int size) {
  int i;
  for (i = 0; i < size; i++) {
    str[i] = value;
  }
}


x86 assembly (clang, -O0):
<_setNULL>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %edx,-0x10(%rbp)
movl   $0x0,-0x14(%rbp)
mov    -0x14(%rbp),%eax
cmp    -0x10(%rbp),%eax
jge    113f <_setNULL+0x3f>
mov    -0xc(%rbp),%eax
mov    %al,%dl
mov    -0x8(%rbp),%rax
movslq -0x14(%rbp),%rcx
mov    %dl,(%rax,%rcx,1)
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    1115 <_setNULL+0x15>
pop    %rbp
ret

x86 assembly (clang, -O2):
<_setNULL>:
test   %edx,%edx
jle    1120 <_setNULL+0x10>
push   %rax
mov    %edx,%edx
call   1030 <memset@plt>
add    $0x8,%rsp
ret

LLVM IR (-O0):
define void @_setNULL(i8* %0, i32 %1, i32 %2) {
%4 = alloca i8*
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
store i8* %0, i8** %4
store i32 %1, i32* %5
store i32 %2, i32* %6
store i32 0, i32* %7
br label %8
8: ; preds = %19, %3
%9 = load i32, i32* %7
%10 = load i32, i32* %6
%11 = icmp slt i32 %9, %10
br i1 %11, label %12, label %22
12: ; preds = %8
%13 = load i32, i32* %5
%14 = trunc i32 %13 to i8
%15 = load i8*, i8** %4
%16 = load i32, i32* %7
%17 = sext i32 %16 to i64
%18 = getelementptr inbounds i8, i8* %15, i64 %17
store i8 %14, i8* %18
br label %19
19: ; preds = %12
%20 = load i32, i32* %7
%21 = add nsw i32 %20, 1
store i32 %21, i32* %7
br label %8
22: ; preds = %8
ret void
}

LLVM IR (-O2):
define void @_setNULL(i8* nocapture writeonly %0, i32 %1, i32 %2) {
%4 = icmp sgt i32 %2, 0
br i1 %4, label %5, label %8
5: ; preds = %3
%6 = trunc i32 %1 to i8
%7 = zext i32 %2 to i64
br label %8
8: ; preds = %5, %3
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, double);
int /*<<< orphan*/ scanf(char *, int *, int *);
int main() {
  int spentTime, averageSpeed;
  scanf("%d %d", &spentTime, &averageSpeed);
  double averageDistance = spentTime * averageSpeed;
  double neededFuel = averageDistance / 12.0;
  printf("%.3lf\n", neededFuel);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xed2(%rip),%rdi
lea    -0x8(%rbp),%rsi
lea    -0xc(%rbp),%rdx
call   1040 <scanf@plt>
mov    -0x8(%rbp),%eax
imul   -0xc(%rbp),%eax
cvtsi2sd %eax,%xmm0
movsd  %xmm0,-0x18(%rbp)
movsd  -0x18(%rbp),%xmm0
movsd  0xea0(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x20(%rbp)
movsd  -0x20(%rbp),%xmm0
lea    0xe99(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xee0(%rip),%rdi
lea    0x4(%rsp),%rsi
mov    %rsp,%rdx
call   1040 <scanf@plt>
mov    (%rsp),%eax
imul   0x4(%rsp),%eax
cvtsi2sd %eax,%xmm0
divsd  0xeb7(%rip),%xmm0
lea    0xebe(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [6 x i8] c"%d %d\00"
@.str.1 = [7 x i8] c"%.3lf\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca double
%5 = alloca double
store i32 0, i32* %1
%6 = call i32 @scanf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32* %2, i32* %3)
%7 = load i32, i32* %2
%8 = load i32, i32* %3
%9 = mul nsw i32 %7, %8
%10 = sitofp i32 %9 to double
store double %10, double* %4
%11 = load double, double* %4
%12 = fdiv double %11, 1.200000e+01
store double %12, double* %5
%13 = load double, double* %5
%14 = call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), double %13)
ret i32 0
}

LLVM IR (-O2):
@.str = [6 x i8] c"%d %d\00"
@.str.1 = [7 x i8] c"%.3lf\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = bitcast i32* %1 to i8*
%4 = bitcast i32* %2 to i8*
%5 = call i32 @scanf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32* %1, i32* %2)
%6 = load i32, i32* %1
%7 = load i32, i32* %2
%8 = mul nsw i32 %7, %6
%9 = sitofp i32 %8 to double
%10 = fdiv double %9, 1.200000e+01
%11 = call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), double %10)
ret i32 0
}
/* Type definitions */
typedef int /*<<< orphan*/ pthread_mutex_t;

/* Variables and functions */
int errno;
int pthread_mutex_trylock(int /*<<< orphan*/ *);
int tosMutex_trylock(pthread_mutex_t *mx) {
  int res = 0;
  res = pthread_mutex_trylock(mx);
  if (res) {
    errno = res;
    res = -1;
  }
  return res;
}


x86 assembly (clang, -O0):
<tosMutex_trylock>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <pthread_mutex_trylock@plt>
mov    %eax,-0xc(%rbp)
cmpl   $0x0,-0xc(%rbp)
je     114c <tosMutex_trylock+0x3c>
mov    -0xc(%rbp),%ecx
mov    0x2e9d(%rip),%rax
mov    %ecx,(%rax)
movl   $0xffffffff,-0xc(%rbp)
mov    -0xc(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<tosMutex_trylock>:
push   %rax
call   1030 <pthread_mutex_trylock@plt>
test   %eax,%eax
je     112a <tosMutex_trylock+0x1a>
mov    0x2ebf(%rip),%rcx
mov    %eax,(%rcx)
mov    $0xffffffff,%eax
pop    %rcx
ret
xor    %eax,%eax
pop    %rcx
ret

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

LLVM IR (-O2):
@errno = global i32 0
define i32 @tosMutex_trylock(i32* %0) {
%2 = tail call i32 @pthread_mutex_trylock(i32* %0)
%3 = icmp eq i32 %2, 0
br i1 %3, label %5, label %4
4: ; preds = %1
store i32 %2, i32* @errno
br label %5
5: ; preds = %4, %1
%6 = phi i32 [ -1, %4 ], [ 0, %1 ]
ret i32 %6
}
void g_tree_remove() {}


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

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

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

LLVM IR (-O2):
define void @g_tree_remove() {
ret void
}
void remove_barometer_sensor(struct ssp_data *data) { return; }


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

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

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

LLVM IR (-O2):
%struct.ssp_data = type opaque
define void @remove_barometer_sensor(%struct.ssp_data* nocapture %0) {
ret void
}
char *TF2st(int var, char *t, char *f) {
  if (var)
    return t;
  else
    return f;
}


x86 assembly (clang, -O0):
<TF2st>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0xc(%rbp)
mov    %rsi,-0x18(%rbp)
mov    %rdx,-0x20(%rbp)
cmpl   $0x0,-0xc(%rbp)
je     1126 <TF2st+0x26>
mov    -0x18(%rbp),%rax
mov    %rax,-0x8(%rbp)
jmp    112e <TF2st+0x2e>
mov    -0x20(%rbp),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<TF2st>:
mov    %rsi,%rax
test   %edi,%edi
cmove  %rdx,%rax
ret

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

LLVM IR (-O2):
define i8* @TF2st(i32 %0, i8* readnone %1, i8* readnone %2) {
%4 = icmp eq i32 %0, 0
%5 = select i1 %4, i8* %2, i8* %1
ret i8* %5
}
/* Variables and functions */
int /*<<< orphan*/ kd_put(char);
void kd_newl() { kd_put('\n'); }


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

x86 assembly (clang, -O2):
<kd_newl>:
mov    $0xa,%edi
jmp    1030 <kd_put@plt>

LLVM IR (-O0):
define void @kd_newl() {
%1 = call i32 @kd_put(i8 signext 10)
ret void
}

LLVM IR (-O2):
define void @kd_newl() {
%1 = tail call i32 @kd_put(i8 signext 10)
ret void
}