xunge/DecIR huggingface dataset:
__attribute__((no, noclone)) short foo12(short arg) {
  short ret = 1;
  if (arg + 1 < ((!0) ? -(1 << (sizeof(char) * 8 - 1)) : 0) ||
      arg + 1 > ((!0) ? ((1 << (sizeof(char) * 8 - 1)) - 1)
                      : ((1 << (sizeof(char) * 8)) - 1)))
    return ret;
  arg = arg + 1;
  ret = (unsigned char)arg;
  return arg;
}


x86 assembly (clang, -O0):
<foo12>:
push   %rbp
mov    %rsp,%rbp
mov    %di,%ax
mov    %ax,-0x4(%rbp)
movw   $0x1,-0x6(%rbp)
movswl -0x4(%rbp),%eax
add    $0x1,%eax
cmp    $0xffffff80,%eax
jl     1131 <foo12+0x31>
movswl -0x4(%rbp),%eax
add    $0x1,%eax
cmp    $0x7f,%eax
jle    113e <foo12+0x3e>
mov    -0x6(%rbp),%ax
mov    %ax,-0x2(%rbp)
jmp    115c <foo12+0x5c>
movswl -0x4(%rbp),%eax
add    $0x1,%eax
mov    %ax,-0x4(%rbp)
mov    -0x4(%rbp),%ax
movzbl %al,%eax
mov    %ax,-0x6(%rbp)
mov    -0x4(%rbp),%ax
mov    %ax,-0x2(%rbp)
movswl -0x2(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<foo12>:
lea    0x1(%rdi),%ecx
add    $0xffffff81,%edi
movzwl %di,%eax
cmp    $0xff00,%eax
mov    $0x1,%eax
cmovae %ecx,%eax
ret

LLVM IR (-O0):
define signext i16 @foo12(i16 signext %0) {
%2 = alloca i16
%3 = alloca i16
%4 = alloca i16
store i16 %0, i16* %3
store i16 1, i16* %4
%5 = load i16, i16* %3
%6 = sext i16 %5 to i32
%7 = add nsw i32 %6, 1
%8 = icmp slt i32 %7, -128
br i1 %8, label %14, label %9
9: ; preds = %1
%10 = load i16, i16* %3
%11 = sext i16 %10 to i32
%12 = add nsw i32 %11, 1
%13 = icmp sgt i32 %12, 127
br i1 %13, label %14, label %16
14: ; preds = %9, %1
%15 = load i16, i16* %4
store i16 %15, i16* %2
br label %25
16: ; preds = %9
%17 = load i16, i16* %3
%18 = sext i16 %17 to i32
%19 = add nsw i32 %18, 1
%20 = trunc i32 %19 to i16
store i16 %20, i16* %3
%21 = load i16, i16* %3
%22 = trunc i16 %21 to i8
%23 = zext i8 %22 to i16
store i16 %23, i16* %4
%24 = load i16, i16* %3
store i16 %24, i16* %2
br label %25
25: ; preds = %16, %14
%26 = load i16, i16* %2
ret i16 %26
}

LLVM IR (-O2):
define signext i16 @foo12(i16 signext %0) {
%2 = add i16 %0, 1
%3 = add i16 %0, -127
%4 = icmp ult i16 %3, -256
%5 = select i1 %4, i16 1, i16 %2
ret i16 %5
}
/* Variables and functions */
int /*<<< orphan*/ free(char *);
int /*<<< orphan*/ printf(char *, char *);
char *strutil_uppercase(char *);
int main(void) {
  char *str = "Hello, WORLD!";
  char *upper = strutil_uppercase(str);
  printf("Original:  \"%s\"\n", str);
  printf("Uppercase: \"%s\"\n", upper);
  free(upper);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeba(%rip),%rax
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
call   1050 <strutil_uppercase@plt>
mov    %rax,-0x18(%rbp)
mov    -0x10(%rbp),%rsi
lea    0xeac(%rip),%rdi
call   1040 <printf@plt>
mov    -0x18(%rbp),%rsi
lea    0xead(%rip),%rdi
call   1040 <printf@plt>
mov    -0x18(%rbp),%rdi
call   1030 <free@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r14
push   %rbx
push   %rax
lea    0xec5(%rip),%r14
mov    %r14,%rdi
call   1050 <strutil_uppercase@plt>
mov    %rax,%rbx
lea    0xec1(%rip),%rdi
mov    %r14,%rsi
call   1040 <printf@plt>
lea    0xec3(%rip),%rdi
mov    %rbx,%rsi
call   1040 <printf@plt>
mov    %rbx,%rdi
call   1030 <free@plt>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
@.str = [14 x i8] c"Hello, WORLD!\00"
@.str.1 = [17 x i8] c"Original: \22%s\22\0A\00"
@.str.2 = [17 x i8] c"Uppercase: \22%s\22\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i8*
%3 = alloca i8*
store i32 0, i32* %1
store i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0), i8** %2
%4 = load i8*, i8** %2
%5 = call i8* @strutil_uppercase(i8* %4)
store i8* %5, i8** %3
%6 = load i8*, i8** %2
%7 = call i32 @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.1, i64 0, i64 0), i8* %6)
%8 = load i8*, i8** %3
%9 = call i32 @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.2, i64 0, i64 0), i8* %8)
%10 = load i8*, i8** %3
%11 = call i32 @free(i8* %10)
ret i32 0
}

LLVM IR (-O2):
@.str = [14 x i8] c"Hello, WORLD!\00"
@.str.1 = [17 x i8] c"Original: \22%s\22\0A\00"
@.str.2 = [17 x i8] c"Uppercase: \22%s\22\0A\00"
define i32 @main() {
%1 = tail call i8* @strutil_uppercase(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0))
%3 = tail call i32 @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.2, i64 0, i64 0), i8* %1)
%4 = tail call i32 @free(i8* %1)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ ADM_dezalloc(void *);
void twolame_free(void **ptr_addr) {
  if (*ptr_addr != NULL) {
    ADM_dezalloc(*ptr_addr);
    *ptr_addr = NULL;
  }
}


x86 assembly (clang, -O0):
<twolame_free>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
cmpq   $0x0,(%rax)
je     1141 <twolame_free+0x31>
mov    -0x8(%rbp),%rax
mov    (%rax),%rdi
call   1030 <ADM_dezalloc@plt>
mov    -0x8(%rbp),%rax
movq   $0x0,(%rax)
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<twolame_free>:
push   %rbx
mov    %rdi,%rbx
mov    (%rdi),%rdi
test   %rdi,%rdi
je     1128 <twolame_free+0x18>
call   1030 <ADM_dezalloc@plt>
movq   $0x0,(%rbx)
pop    %rbx
ret

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

LLVM IR (-O2):
define void @twolame_free(i8** nocapture %0) {
%2 = load i8*, i8** %0
%3 = icmp eq i8* %2, null
br i1 %3, label %6, label %4
4: ; preds = %1
%5 = tail call i32 @ADM_dezalloc(i8* %2)
store i8* null, i8** %0
br label %6
6: ; preds = %4, %1
ret void
}
/* Variables and functions */
int _ada_use_c2phc4c(int, int *, int *, double *, int /*<<< orphan*/);
int syscon_quaddobl_Laurent_size_limit(int k, int *szl) {
  int fail;
  double *c;
  fail = _ada_use_c2phc4c(606, &k, szl, c, 0);
  return fail;
}


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

x86 assembly (clang, -O2):
<syscon_quaddobl_Laurent_size_limit>:
push   %rax
mov    %rsi,%rdx
mov    %edi,0x4(%rsp)
lea    0x4(%rsp),%rsi
mov    $0x25e,%edi
xor    %r8d,%r8d
call   1030 <_ada_use_c2phc4c@plt>
pop    %rcx
ret

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

LLVM IR (-O2):
define i32 @syscon_quaddobl_Laurent_size_limit(i32 %0, i32* %1) {
%3 = alloca i32
store i32 %0, i32* %3
%4 = call i32 @_ada_use_c2phc4c(i32 606, i32* %3, i32* %1, double* undef, i32 0)
ret i32 %4
}
void XDrawPoints() {}


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

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

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

LLVM IR (-O2):
define void @XDrawPoints() {
ret void
}
/* Variables and functions */
void *calloc(int, size_t);
int /*<<< orphan*/ dropbear_exit(char *);
void *m_malloc(size_t size) {
  void *ret;
  if (size == 0) {
    dropbear_exit("m_malloc failed");
  }
  ret = calloc(1, size);
  if (ret == NULL)
    dropbear_exit("m_malloc failed");
  return ret;
}


x86 assembly (clang, -O0):
<m_malloc>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
cmpq   $0x0,-0x8(%rbp)
jne    1143 <m_malloc+0x23>
lea    0xec2(%rip),%rdi
call   1040 <dropbear_exit@plt>
mov    -0x8(%rbp),%rsi
mov    $0x1,%edi
call   1030 <calloc@plt>
mov    %rax,-0x10(%rbp)
cmpq   $0x0,-0x10(%rbp)
jne    116c <m_malloc+0x4c>
lea    0xe99(%rip),%rdi
call   1040 <dropbear_exit@plt>
mov    -0x10(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<m_malloc>:
push   %rbx
mov    %rdi,%rbx
test   %rdi,%rdi
jne    1135 <m_malloc+0x15>
lea    0xed0(%rip),%rdi
call   1040 <dropbear_exit@plt>
mov    $0x1,%edi
mov    %rbx,%rsi
call   1030 <calloc@plt>
mov    %rax,%rbx
test   %rax,%rax
jne    1156 <m_malloc+0x36>
lea    0xeaf(%rip),%rdi
call   1040 <dropbear_exit@plt>
mov    %rbx,%rax
pop    %rbx
ret

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

LLVM IR (-O2):
@.str = [16 x i8] c"m_malloc failed\00"
define i8* @m_malloc(i64 %0) {
%2 = icmp eq i64 %0, 0
br i1 %2, label %3, label %5
3: ; preds = %1
%4 = tail call i32 @dropbear_exit(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str, i64 0, i64 0))
br label %5
5: ; preds = %3, %1
%6 = tail call i8* @calloc(i32 1, i64 %0)
%7 = icmp eq i8* %6, null
br i1 %7, label %8, label %10
8: ; preds = %5
%9 = tail call i32 @dropbear_exit(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str, i64 0, i64 0))
br label %10
10: ; preds = %8, %5
ret i8* %6
}
/* Type definitions */
typedef int /*<<< orphan*/ socklen_t;

/* Variables and functions */
int real_setsockopt(int, int, int, void const *, int /*<<< orphan*/);
int setsockopt(int fd, int level, int option_name, const void *option_value,
               socklen_t option_len) {
  return real_setsockopt(fd, level, option_name, option_value, option_len);
}


x86 assembly (clang, -O0):
<setsockopt>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %rcx,-0x18(%rbp)
mov    %r8d,-0x1c(%rbp)
mov    -0x4(%rbp),%edi
mov    -0x8(%rbp),%esi
mov    -0xc(%rbp),%edx
mov    -0x18(%rbp),%rcx
mov    -0x1c(%rbp),%r8d
call   1030 <real_setsockopt@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<setsockopt>:
jmp    1030 <real_setsockopt@plt>

LLVM IR (-O0):
define i32 @setsockopt(i32 %0, i32 %1, i32 %2, i8* %3, i32 %4) {
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i8*
%10 = alloca i32
store i32 %0, i32* %6
store i32 %1, i32* %7
store i32 %2, i32* %8
store i8* %3, i8** %9
store i32 %4, i32* %10
%11 = load i32, i32* %6
%12 = load i32, i32* %7
%13 = load i32, i32* %8
%14 = load i8*, i8** %9
%15 = load i32, i32* %10
%16 = call i32 @real_setsockopt(i32 %11, i32 %12, i32 %13, i8* %14, i32 %15)
ret i32 %16
}

LLVM IR (-O2):
define i32 @setsockopt(i32 %0, i32 %1, i32 %2, i8* %3, i32 %4) {
%6 = tail call i32 @real_setsockopt(i32 %0, i32 %1, i32 %2, i8* %3, i32 %4)
ret i32 %6
}
/* Variables and functions */
char *corta_string(char *);
int /*<<< orphan*/ printf(char *, char *);
int main(void) {
  char *s = "Campos verdes";
  while (*s != ' ') {
    s = corta_string(s);
  }
  s = corta_string(s);
  printf("%s\n", s);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeca(%rip),%rax
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x20,%eax
je     115c <main+0x3c>
mov    -0x10(%rbp),%rdi
call   1040 <corta_string@plt>
mov    %rax,-0x10(%rbp)
jmp    113a <main+0x1a>
mov    -0x10(%rbp),%rdi
call   1040 <corta_string@plt>
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rsi
lea    0xe9a(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xed8(%rip),%rax
nopl   0x0(%rax,%rax,1)
mov    %rax,%rdi
call   1040 <corta_string@plt>
cmpb   $0x20,(%rax)
jne    1130 <main+0x10>
mov    %rax,%rdi
call   1040 <corta_string@plt>
lea    0xec2(%rip),%rdi
mov    %rax,%rsi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rcx
ret

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

LLVM IR (-O2):
@.str = [14 x i8] c"Campos verdes\00"
@.str.1 = [4 x i8] c"%s\0A\00"
define i32 @main() {
br label %1
1: ; preds = %0, %1
%2 = phi i8* [ getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0), %0 ], [ %3, %1 ]
%3 = tail call i8* @corta_string(i8* %2)
%4 = load i8, i8* %3
%5 = icmp eq i8 %4, 32
br i1 %5, label %6, label %1
6: ; preds = %1
%7 = tail call i8* @corta_string(i8* %3)
%8 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* %7)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ unitTest();
int main(int argc, char **argv) {
  printf("Run unit Test:\n");
  unitTest();
  return 0;
}


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

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

LLVM IR (-O0):
@.str = [16 x i8] c"Run unit Test:\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%6 = call i32 @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str, i64 0, i64 0))
%7 = call i32 (...) @unitTest()
ret i32 0
}

LLVM IR (-O2):
@str = [15 x i8] c"Run unit Test:\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%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 (...) @unitTest()
ret i32 0
}
/* Type definitions */
struct ejson_driver_t {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ fflush(int /*<<< orphan*/);
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ stdout;
void d_open_data(struct ejson_driver_t *d) {
  printf("%% '");
  fflush(stdout);
}


x86 assembly (clang, -O0):
<d_open_data>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
lea    0xecd(%rip),%rdi
call   1030 <printf@plt>
mov    0x2ea1(%rip),%rax
mov    (%rax),%edi
call   1040 <fflush@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<d_open_data>:
push   %rax
lea    0xed8(%rip),%rdi
call   1030 <printf@plt>
mov    0x2eac(%rip),%rax
mov    (%rax),%edi
pop    %rax
jmp    1040 <fflush@plt>

LLVM IR (-O0):
%struct.ejson_driver_t = type { i32 }
@.str = [5 x i8] c"%% '\00"
@stdout = global i32 0
define void @d_open_data(%struct.ejson_driver_t* %0) {
%2 = alloca %struct.ejson_driver_t*
store %struct.ejson_driver_t* %0, %struct.ejson_driver_t** %2
%3 = call i32 @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%4 = load i32, i32* @stdout
%5 = call i32 @fflush(i32 %4)
ret void
}

LLVM IR (-O2):
%struct.ejson_driver_t = type { i32 }
@.str = [5 x i8] c"%% '\00"
@stdout = global i32 0
define void @d_open_data(%struct.ejson_driver_t* nocapture readnone %0) {
%2 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%3 = load i32, i32* @stdout
%4 = tail call i32 @fflush(i32 %3)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
void dot_trailer() { printf("}\n"); }


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

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

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

LLVM IR (-O2):
@str = [2 x i8] c"}\00"
define void @dot_trailer() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([2 x i8], [2 x i8]* @str, i64 0, i64 0))
ret void
}
void st_lld_stop_alarm(void) {}


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

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

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

LLVM IR (-O2):
define void @st_lld_stop_alarm() {
ret void
}
unsigned int popcountl(unsigned long value) {
  int i, bitcnt;
  int nbits = sizeof(unsigned long) * 8;
  for (i = 0, bitcnt = 0; i < nbits; i++) {
    if (value & ((unsigned long)1 << i))
      bitcnt++;
  }
  return bitcnt;
}


x86 assembly (clang, -O0):
<popcountl>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
movl   $0x40,-0x14(%rbp)
movl   $0x0,-0xc(%rbp)
movl   $0x0,-0x10(%rbp)
mov    -0xc(%rbp),%eax
cmp    -0x14(%rbp),%eax
jge    1164 <popcountl+0x64>
mov    -0x8(%rbp),%rax
mov    -0xc(%rbp),%ecx
mov    $0x1,%edx
shl    %cl,%rdx
mov    %rdx,%rcx
and    %rcx,%rax
cmp    $0x0,%rax
je     1151 <popcountl+0x51>
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
jmp    1156 <popcountl+0x56>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    111d <popcountl+0x1d>
mov    -0x10(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<popcountl>:
xor    %ecx,%ecx
xor    %eax,%eax
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
bt     %rcx,%rdi
adc    $0x0,%eax
lea    0x1(%rcx),%edx
movzbl %dl,%edx
bt     %rdx,%rdi
adc    $0x0,%eax
lea    0x2(%rcx),%edx
movzbl %dl,%edx
bt     %rdx,%rdi
adc    $0x0,%eax
lea    0x3(%rcx),%edx
movzbl %dl,%edx
bt     %rdx,%rdi
adc    $0x0,%eax
add    $0x4,%rcx
cmp    $0x40,%rcx
jne    1110 <popcountl+0x10>
ret

LLVM IR (-O0):
define i32 @popcountl(i64 %0) {
%2 = alloca i64
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store i64 %0, i64* %2
store i32 64, i32* %5
store i32 0, i32* %3
store i32 0, i32* %4
br label %6
6: ; preds = %21, %1
%7 = load i32, i32* %3
%8 = load i32, i32* %5
%9 = icmp slt i32 %7, %8
br i1 %9, label %10, label %24
10: ; preds = %6
%11 = load i64, i64* %2
%12 = load i32, i32* %3
%13 = zext i32 %12 to i64
%14 = shl i64 1, %13
%15 = and i64 %11, %14
%16 = icmp ne i64 %15, 0
br i1 %16, label %17, label %20
17: ; preds = %10
%18 = load i32, i32* %4
%19 = add nsw i32 %18, 1
store i32 %19, i32* %4
br label %20
20: ; preds = %17, %10
br label %21
21: ; preds = %20
%22 = load i32, i32* %3
%23 = add nsw i32 %22, 1
store i32 %23, i32* %3
br label %6
24: ; preds = %6
%25 = load i32, i32* %4
ret i32 %25
}

LLVM IR (-O2):
define i32 @popcountl(i64 %0) {
br label %2
2: ; preds = %2, %1
%3 = phi i64 [ 0, %1 ], [ %28, %2 ]
%4 = phi i32 [ 0, %1 ], [ %27, %2 ]
%5 = shl nuw i64 1, %3
%6 = and i64 %5, %0
%7 = icmp ne i64 %6, 0
%8 = zext i1 %7 to i32
%9 = add nuw nsw i32 %4, %8
%10 = or i64 %3, 1
%11 = shl nuw i64 1, %10
%12 = and i64 %11, %0
%13 = icmp ne i64 %12, 0
%14 = zext i1 %13 to i32
%15 = add nuw nsw i32 %9, %14
%16 = or i64 %3, 2
%17 = shl nuw i64 1, %16
%18 = and i64 %17, %0
%19 = icmp ne i64 %18, 0
%20 = zext i1 %19 to i32
%21 = add nuw nsw i32 %15, %20
%22 = or i64 %3, 3
%23 = shl nuw i64 1, %22
%24 = and i64 %23, %0
%25 = icmp ne i64 %24, 0
%26 = zext i1 %25 to i32
%27 = add nuw nsw i32 %21, %26
%28 = add nuw nsw i64 %3, 4
%29 = icmp eq i64 %28, 64
br i1 %29, label %30, label %2
30: ; preds = %2
ret i32 %27
}
/* Variables and functions */
int strcmp(char const *const, char const *const);
int image_paths_comparator(const void *__attribute__((nonnull)) const left,
                           const void *__attribute__((nonnull)) const right) {
  const char *const left_path = *(const char **)left;
  const char *const right_path = *(const char **)right;
  return strcmp(left_path, right_path);
}


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

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

LLVM IR (-O0):
define i32 @image_paths_comparator(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
%5 = alloca i8*
%6 = alloca i8*
store i8* %0, i8** %3
store i8* %1, i8** %4
%7 = load i8*, i8** %3
%8 = bitcast i8* %7 to i8**
%9 = load i8*, i8** %8
store i8* %9, i8** %5
%10 = load i8*, i8** %4
%11 = bitcast i8* %10 to i8**
%12 = load i8*, i8** %11
store i8* %12, i8** %6
%13 = load i8*, i8** %5
%14 = load i8*, i8** %6
%15 = call i32 @strcmp(i8* %13, i8* %14)
ret i32 %15
}

LLVM IR (-O2):
define i32 @image_paths_comparator(i8* nocapture %0, i8* nocapture %1) {
%3 = bitcast i8* %0 to i8**
%4 = load i8*, i8** %3
%5 = bitcast i8* %1 to i8**
%6 = load i8*, i8** %5
%7 = tail call i32 @strcmp(i8* dereferenceable(1) %4, i8* dereferenceable(1) %6)
ret i32 %7
}
/* Variables and functions */
size_t childr(size_t ix) { return (ix + 1) * 2; }


x86 assembly (clang, -O0):
<childr>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
add    $0x1,%rax
shl    $0x1,%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<childr>:
lea    (%rdi,%rdi,1),%rax
add    $0x2,%rax
ret

LLVM IR (-O0):
define i64 @childr(i64 %0) {
%2 = alloca i64
store i64 %0, i64* %2
%3 = load i64, i64* %2
%4 = add i64 %3, 1
%5 = mul i64 %4, 2
ret i64 %5
}

LLVM IR (-O2):
define i64 @childr(i64 %0) {
%2 = shl i64 %0, 1
%3 = add i64 %2, 2
ret i64 %3
}
void b43_nphy_xmitpower(struct b43_wldev *dev) {}


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

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

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

LLVM IR (-O2):
%struct.b43_wldev = type opaque
define void @b43_nphy_xmitpower(%struct.b43_wldev* nocapture %0) {
ret void
}
void avio_wb64() {}


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

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

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

LLVM IR (-O2):
define void @avio_wb64() {
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ time_t;
struct tm {
  int dummy;
};

/* Variables and functions */
struct tm *localtime(int /*<<< orphan*/ *);
int /*<<< orphan*/ strftime(char *, int, char *, struct tm *);
int /*<<< orphan*/ time(int /*<<< orphan*/ *);
char *get_sendtime(char *_time_buffer) {
  time_t rawtime;
  struct tm *timeinfo;
  time(&rawtime);
  timeinfo = localtime(&rawtime);
  strftime(_time_buffer, 80, "%Y%m%d%H%M%S", timeinfo);
  return _time_buffer;
}


x86 assembly (clang, -O0):
<get_sendtime>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
lea    -0xc(%rbp),%rdi
call   1040 <time@plt>
lea    -0xc(%rbp),%rdi
call   1030 <localtime@plt>
mov    %rax,-0x18(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x18(%rbp),%rcx
mov    $0x50,%esi
lea    0xe9a(%rip),%rdx
call   1050 <strftime@plt>
mov    -0x8(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<get_sendtime>:
push   %r14
push   %rbx
push   %rax
mov    %rdi,%rbx
lea    0x4(%rsp),%r14
mov    %r14,%rdi
call   1040 <time@plt>
mov    %r14,%rdi
call   1030 <localtime@plt>
lea    0xead(%rip),%rdx
mov    %rbx,%rdi
mov    $0x50,%esi
mov    %rax,%rcx
call   1050 <strftime@plt>
mov    %rbx,%rax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
%struct.tm = type { i32 }
@.str = [13 x i8] c"%Y%m%d%H%M%S\00"
define i8* @get_sendtime(i8* %0) {
%2 = alloca i8*
%3 = alloca i32
%4 = alloca %struct.tm*
store i8* %0, i8** %2
%5 = call i32 @time(i32* %3)
%6 = call %struct.tm* @localtime(i32* %3)
store %struct.tm* %6, %struct.tm** %4
%7 = load i8*, i8** %2
%8 = load %struct.tm*, %struct.tm** %4
%9 = call i32 @strftime(i8* %7, i32 80, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), %struct.tm* %8)
%10 = load i8*, i8** %2
ret i8* %10
}

LLVM IR (-O2):
%struct.tm = type { i32 }
@.str = [13 x i8] c"%Y%m%d%H%M%S\00"
define i8* @get_sendtime(i8* returned %0) {
%2 = alloca i32
%3 = bitcast i32* %2 to i8*
%4 = call i32 @time(i32* %2)
%5 = call %struct.tm* @localtime(i32* %2)
%6 = call i32 @strftime(i8* %0, i32 80, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), %struct.tm* %5)
ret i8* %0
}
/* Variables and functions */
int /*<<< orphan*/ cs2ecb();
void cs2ecb_(void) { cs2ecb(); }


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

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

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

LLVM IR (-O2):
define void @cs2ecb_() {
%1 = tail call i32 (...) @cs2ecb()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ free(void *);
void __attribute__((no, noclone)) unoptimized_free(void *ptr) { free(ptr); }


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

x86 assembly (clang, -O2):
<unoptimized_free>:
jmp    1030 <free@plt>

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

LLVM IR (-O2):
define void @unoptimized_free(i8* nocapture %0) {
%2 = tail call i32 @free(i8* %0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ abort();
double bar(double);
unsigned long i386_cpuid();
int main(int argc, char **argv) {
  unsigned long cpu_facilities;
  cpu_facilities = i386_cpuid();
  if (!(cpu_facilities & (1 << 23)))
    return 0;
  if (bar(116.0) != 117.0)
    abort();
  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    $0x0,%al
call   1050 <i386_cpuid@plt>
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
and    $0x800000,%rax
cmp    $0x0,%rax
jne    1171 <main+0x41>
movl   $0x0,-0x4(%rbp)
jmp    11a9 <main+0x79>
movsd  0xe8f(%rip),%xmm0
call   1040 <bar@plt>
movsd  0xe7a(%rip),%xmm1
ucomisd %xmm1,%xmm0
jne    119b <main+0x6b>
jp     119b <main+0x6b>
jmp    11a2 <main+0x72>
mov    $0x0,%al
call   1030 <abort@plt>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
xor    %eax,%eax
call   1050 <i386_cpuid@plt>
test   $0x800000,%eax
je     1158 <main+0x28>
movsd  0xeb9(%rip),%xmm0
call   1040 <bar@plt>
ucomisd 0xeb4(%rip),%xmm0
jne    115c <main+0x2c>
jp     115c <main+0x2c>
xor    %eax,%eax
pop    %rcx
ret
xor    %eax,%eax
call   1030 <abort@plt>

LLVM IR (-O0):
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i64
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%7 = call i64 (...) @i386_cpuid()
store i64 %7, i64* %6
%8 = load i64, i64* %6
%9 = and i64 %8, 8388608
%10 = icmp ne i64 %9, 0
br i1 %10, label %12, label %11
11: ; preds = %2
store i32 0, i32* %3
br label %18
12: ; preds = %2
%13 = call double @bar(double 1.160000e+02)
%14 = fcmp une double %13, 1.170000e+02
br i1 %14, label %15, label %17
15: ; preds = %12
%16 = call i32 (...) @abort()
unreachable
17: ; preds = %12
store i32 0, i32* %3
br label %18
18: ; preds = %17, %11
%19 = load i32, i32* %3
ret i32 %19
}

LLVM IR (-O2):
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i64 (...) @i386_cpuid()
%4 = and i64 %3, 8388608
%5 = icmp eq i64 %4, 0
br i1 %5, label %11, label %6
6: ; preds = %2
%7 = tail call double @bar(double 1.160000e+02)
%8 = fcmp une double %7, 1.170000e+02
br i1 %8, label %9, label %11
9: ; preds = %6
%10 = tail call i32 (...) @abort()
unreachable
11: ; preds = %6, %2
ret i32 0
}
/* Variables and functions */
int munmap(void *, size_t);
int munmap_free_blocks(void *mem, unsigned num_blocks) {
  size_t len;
  if (!mem) {
    return 1;
  }
  len = num_blocks * (4UL * 1024UL);
  return munmap(mem, len);
}


x86 assembly (clang, -O0):
<munmap_free_blocks>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %esi,-0x14(%rbp)
cmpq   $0x0,-0x10(%rbp)
jne    1136 <munmap_free_blocks+0x26>
movl   $0x1,-0x4(%rbp)
jmp    1151 <munmap_free_blocks+0x41>
mov    -0x14(%rbp),%eax
shl    $0xc,%rax
mov    %rax,-0x20(%rbp)
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1030 <munmap@plt>
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<munmap_free_blocks>:
test   %rdi,%rdi
je     1120 <munmap_free_blocks+0x10>
mov    %esi,%esi
shl    $0xc,%rsi
jmp    1030 <munmap@plt>
mov    $0x1,%eax
ret

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

LLVM IR (-O2):
define i32 @munmap_free_blocks(i8* %0, i32 %1) {
%3 = icmp eq i8* %0, null
br i1 %3, label %8, label %4
4: ; preds = %2
%5 = zext i32 %1 to i64
%6 = shl nuw nsw i64 %5, 12
%7 = tail call i32 @munmap(i8* %0, i64 %6)
br label %8
8: ; preds = %2, %4
%9 = phi i32 [ %7, %4 ], [ 1, %2 ]
ret i32 %9
}
/* Variables and functions */
int strlen(const char *str) {
  int len = 0;
  while (*str != '\0') {
    len++;
    str++;
  }
  return len;
}


x86 assembly (clang, -O0):
<strlen>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
mov    -0x8(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x0,%eax
je     1139 <strlen+0x39>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
mov    -0x8(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x8(%rbp)
jmp    110f <strlen+0xf>
mov    -0xc(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<strlen>:
cmpb   $0x0,(%rdi)
je     111c <strlen+0x1c>
xor    %eax,%eax
nopw   0x0(%rax,%rax,1)
cmpb   $0x0,0x1(%rdi,%rax,1)
lea    0x1(%rax),%rax
jne    1110 <strlen+0x10>
ret
xor    %eax,%eax
ret

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

LLVM IR (-O2):
define i32 @strlen(i8* nocapture %0) {
%2 = load i8, i8* %0
%3 = icmp eq i8 %2, 0
br i1 %3, label %11, label %4
4: ; preds = %1, %4
%5 = phi i32 [ %7, %4 ], [ 0, %1 ]
%6 = phi i8* [ %8, %4 ], [ %0, %1 ]
%7 = add nuw nsw i32 %5, 1
%8 = getelementptr inbounds i8, i8* %6, i64 1
%9 = load i8, i8* %8
%10 = icmp eq i8 %9, 0
br i1 %10, label %11, label %4
11: ; preds = %4, %1
%12 = phi i32 [ 0, %1 ], [ %7, %4 ]
ret i32 %12
}
const char *Tuple_Name(void) { return "Tuple"; }


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

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

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

LLVM IR (-O2):
@.str = [6 x i8] c"Tuple\00"
define i8* @Tuple_Name() {
ret i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0)
}
void RandomFunc(unsigned char input[1], unsigned char output[1]) {
  unsigned char state[1];
  unsigned char local1;
  {
    state[0UL] = (input[0UL] - 51238316UL) - (unsigned char)191;
    local1 = 0UL;
    while (local1 < (unsigned char)0) {
      state[0UL] |= (state[0UL] & (unsigned char)15) << 3UL;
      local1++;
    }
    output[0UL] = (state[0UL] ^ 707305405UL) ^
                  967835152UL * (454761159UL >> (unsigned char)253);
  }
}


x86 assembly (clang, -O0):
<RandomFunc>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
movzbl (%rax),%eax
sub    $0x30dd5ac,%rax
sub    $0xbf,%rax
mov    %al,-0x11(%rbp)
movb   $0x0,-0x12(%rbp)
movzbl -0x12(%rbp),%eax
cmp    $0x0,%eax
jge    1153 <RandomFunc+0x53>
movzbl -0x11(%rbp),%ecx
and    $0xf,%ecx
shl    $0x3,%ecx
movzbl -0x11(%rbp),%eax
or     %ecx,%eax
mov    %al,-0x11(%rbp)
mov    -0x12(%rbp),%al
add    $0x1,%al
mov    %al,-0x12(%rbp)
jmp    1126 <RandomFunc+0x26>
movzbl -0x11(%rbp),%eax
xor    $0x2a289fbd,%rax
xor    %rcx,%rax
mov    %al,%cl
mov    -0x10(%rbp),%rax
mov    %cl,(%rax)
pop    %rbp
ret

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

LLVM IR (-O0):
define void @RandomFunc(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
%5 = alloca [1 x i8]
%6 = alloca i8
store i8* %0, i8** %3
store i8* %1, i8** %4
%7 = load i8*, i8** %3
%8 = getelementptr inbounds i8, i8* %7, i64 0
%9 = load i8, i8* %8
%10 = zext i8 %9 to i64
%11 = sub i64 %10, 51238316
%12 = sub i64 %11, 191
%13 = trunc i64 %12 to i8
%14 = getelementptr inbounds [1 x i8], [1 x i8]* %5, i64 0, i64 0
store i8 %13, i8* %14
store i8 0, i8* %6
br label %15
15: ; preds = %19, %2
%16 = load i8, i8* %6
%17 = zext i8 %16 to i32
%18 = icmp slt i32 %17, 0
br i1 %18, label %19, label %32
19: ; preds = %15
%20 = getelementptr inbounds [1 x i8], [1 x i8]* %5, i64 0, i64 0
%21 = load i8, i8* %20
%22 = zext i8 %21 to i32
%23 = and i32 %22, 15
%24 = shl i32 %23, 3
%25 = getelementptr inbounds [1 x i8], [1 x i8]* %5, i64 0, i64 0
%26 = load i8, i8* %25
%27 = zext i8 %26 to i32
%28 = or i32 %27, %24
%29 = trunc i32 %28 to i8
store i8 %29, i8* %25
%30 = load i8, i8* %6
%31 = add i8 %30, 1
store i8 %31, i8* %6
br label %15
32: ; preds = %15
%33 = getelementptr inbounds [1 x i8], [1 x i8]* %5, i64 0, i64 0
%34 = load i8, i8* %33
%35 = zext i8 %34 to i64
%36 = xor i64 %35, 707305405
%37 = xor i64 %36, poison
%38 = trunc i64 %37 to i8
%39 = load i8*, i8** %4
%40 = getelementptr inbounds i8, i8* %39, i64 0
store i8 %38, i8* %40
ret void
}

LLVM IR (-O2):
define void @RandomFunc(i8* nocapture %0, i8* nocapture %1) {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ GlobalsDeinit();
int /*<<< orphan*/ LOG_DEBUG;
int /*<<< orphan*/ SIGINT;
int /*<<< orphan*/ SIG_DFL;
int /*<<< orphan*/ raise(int /*<<< orphan*/);
int /*<<< orphan*/ save_state();
int /*<<< orphan*/ set_signal(int /*<<< orphan*/, int /*<<< orphan*/);
int /*<<< orphan*/ syslog(int /*<<< orphan*/, char *);
void handle_sigint(void) {
  syslog(LOG_DEBUG, "Interrupt Signal");
  save_state();
  GlobalsDeinit();
  set_signal(SIGINT, SIG_DFL);
  raise(SIGINT);
}


x86 assembly (clang, -O0):
<handle_sigint>:
push   %rbp
mov    %rsp,%rbp
mov    0x2e75(%rip),%rax
mov    (%rax),%edi
lea    0xe9c(%rip),%rsi
call   1070 <syslog@plt>
mov    $0x0,%al
call   1060 <save_state@plt>
mov    $0x0,%al
call   1040 <GlobalsDeinit@plt>
mov    0x2e6a(%rip),%rax
mov    (%rax),%edi
mov    0x2e51(%rip),%rax
mov    (%rax),%esi
call   1050 <set_signal@plt>
mov    0x2e53(%rip),%rax
mov    (%rax),%edi
call   1030 <raise@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<handle_sigint>:
push   %rbx
mov    0x2e78(%rip),%rax
mov    (%rax),%edi
lea    0xe9f(%rip),%rsi
call   1070 <syslog@plt>
xor    %eax,%eax
call   1060 <save_state@plt>
xor    %eax,%eax
call   1040 <GlobalsDeinit@plt>
mov    0x2e6d(%rip),%rbx
mov    (%rbx),%edi
mov    0x2e54(%rip),%rax
mov    (%rax),%esi
call   1050 <set_signal@plt>
mov    (%rbx),%edi
pop    %rbx
jmp    1030 <raise@plt>

LLVM IR (-O0):
@LOG_DEBUG = global i32 0
@.str = [17 x i8] c"Interrupt Signal\00"
@SIGINT = global i32 0
@SIG_DFL = global i32 0
define void @handle_sigint() {
%1 = load i32, i32* @LOG_DEBUG
%2 = call i32 @syslog(i32 %1, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0))
%3 = call i32 (...) @save_state()
%4 = call i32 (...) @GlobalsDeinit()
%5 = load i32, i32* @SIGINT
%6 = load i32, i32* @SIG_DFL
%7 = call i32 @set_signal(i32 %5, i32 %6)
%8 = load i32, i32* @SIGINT
%9 = call i32 @raise(i32 %8)
ret void
}

LLVM IR (-O2):
@LOG_DEBUG = global i32 0
@.str = [17 x i8] c"Interrupt Signal\00"
@SIGINT = global i32 0
@SIG_DFL = global i32 0
define void @handle_sigint() {
%1 = load i32, i32* @LOG_DEBUG
%2 = tail call i32 @syslog(i32 %1, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0))
%3 = tail call i32 (...) @save_state()
%4 = tail call i32 (...) @GlobalsDeinit()
%5 = load i32, i32* @SIGINT
%6 = load i32, i32* @SIG_DFL
%7 = tail call i32 @set_signal(i32 %5, i32 %6)
%8 = load i32, i32* @SIGINT
%9 = tail call i32 @raise(i32 %8)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ prepare_dynamic_update();
void dynamic_init(void) { prepare_dynamic_update(); }


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

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

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

LLVM IR (-O2):
define void @dynamic_init() {
%1 = tail call i32 (...) @prepare_dynamic_update()
ret void
}
/* Variables and functions */
int Test_Jpeg_Display(int, char **);
int main(int argc, char **argv) { return Test_Jpeg_Display(argc, argv); }


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
call   1030 <Test_Jpeg_Display@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
jmp    1030 <Test_Jpeg_Display@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 @Test_Jpeg_Display(i32 %6, i8** %7)
ret i32 %8
}

LLVM IR (-O2):
define i32 @main(i32 %0, i8** %1) {
%3 = tail call i32 @Test_Jpeg_Display(i32 %0, i8** %1)
ret i32 %3
}
/* Variables and functions */
int /*<<< orphan*/ func(int);
int main() {
  int i;
  for (i = 0; i < 100; i++) {
    func(1000);
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
cmpl   $0x64,-0x8(%rbp)
jge    1148 <main+0x38>
mov    $0x3e8,%edi
call   1030 <func@plt>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1126 <main+0x16>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
mov    $0x64,%ebx
cs nopw 0x0(%rax,%rax,1)
mov    $0x3e8,%edi
call   1030 <func@plt>
add    $0xffffffff,%ebx
jne    1120 <main+0x10>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
store i32 0, i32* %1
store i32 0, i32* %2
br label %3
3: ; preds = %8, %0
%4 = load i32, i32* %2
%5 = icmp slt i32 %4, 100
br i1 %5, label %6, label %11
6: ; preds = %3
%7 = call i32 @func(i32 1000)
br label %8
8: ; preds = %6
%9 = load i32, i32* %2
%10 = add nsw i32 %9, 1
store i32 %10, i32* %2
br label %3
11: ; preds = %3
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
br label %1
1: ; preds = %0, %1
%2 = phi i32 [ 0, %0 ], [ %4, %1 ]
%3 = tail call i32 @func(i32 1000)
%4 = add nuw nsw i32 %2, 1
%5 = icmp eq i32 %4, 100
br i1 %5, label %6, label %1
6: ; preds = %1
ret i32 0
}
/* Forward declarations */
typedef struct TYPE_4__ TYPE_1__;

/* Type definitions */
struct TYPE_4__ {
  scalar_t__ p_type;
};
typedef TYPE_1__ Elf64_Phdr;

/* Variables and functions */
scalar_t__ PT_DYNAMIC;
Elf64_Phdr *find_dynamic(Elf64_Phdr *phdr) {
  for (; phdr->p_type != PT_DYNAMIC; phdr++)
    ;
  return phdr;
}


x86 assembly (clang, -O0):
<find_dynamic>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%rax
mov    0x2ec2(%rip),%rcx
cmp    (%rcx),%rax
je     1135 <find_dynamic+0x35>
jmp    1124 <find_dynamic+0x24>
mov    -0x8(%rbp),%rax
add    $0x8,%rax
mov    %rax,-0x8(%rbp)
jmp    1108 <find_dynamic+0x8>
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<find_dynamic>:
mov    %rdi,%rax
mov    0x2ece(%rip),%rcx
mov    (%rcx),%rcx
add    $0xfffffffffffffff8,%rax
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
mov    %rax,%rdx
add    $0x8,%rax
cmp    %rcx,0x8(%rdx)
jne    1120 <find_dynamic+0x20>
ret

LLVM IR (-O0):
%struct.TYPE_4__ = type { i64 }
@PT_DYNAMIC = global i64 0
define %struct.TYPE_4__* @find_dynamic(%struct.TYPE_4__* %0) {
%2 = alloca %struct.TYPE_4__*
store %struct.TYPE_4__* %0, %struct.TYPE_4__** %2
br label %3
3: ; preds = %10, %1
%4 = load %struct.TYPE_4__*, %struct.TYPE_4__** %2
%5 = getelementptr inbounds %struct.TYPE_4__, %struct.TYPE_4__* %4, i32 0, i32 0
%6 = load i64, i64* %5
%7 = load i64, i64* @PT_DYNAMIC
%8 = icmp ne i64 %6, %7
br i1 %8, label %9, label %13
9: ; preds = %3
br label %10
10: ; preds = %9
%11 = load %struct.TYPE_4__*, %struct.TYPE_4__** %2
%12 = getelementptr inbounds %struct.TYPE_4__, %struct.TYPE_4__* %11, i32 1
store %struct.TYPE_4__* %12, %struct.TYPE_4__** %2
br label %3
13: ; preds = %3
%14 = load %struct.TYPE_4__*, %struct.TYPE_4__** %2
ret %struct.TYPE_4__* %14
}

LLVM IR (-O2):
%struct.TYPE_4__ = type { i64 }
@PT_DYNAMIC = global i64 0
define %struct.TYPE_4__* @find_dynamic(%struct.TYPE_4__* %0) {
%2 = load i64, i64* @PT_DYNAMIC
br label %3
3: ; preds = %3, %1
%4 = phi %struct.TYPE_4__* [ %0, %1 ], [ %8, %3 ]
%5 = getelementptr inbounds %struct.TYPE_4__, %struct.TYPE_4__* %4, i64 0, i32 0
%6 = load i64, i64* %5
%7 = icmp eq i64 %6, %2
%8 = getelementptr inbounds %struct.TYPE_4__, %struct.TYPE_4__* %4, i64 1
br i1 %7, label %9, label %3
9: ; preds = %3
ret %struct.TYPE_4__* %4
}
/* Variables and functions */
size_t base64_decoded_size(size_t);
char *malloc(size_t);
char *base64_alloc_decode_buffer(size_t input_size) {
  size_t decoded_size = base64_decoded_size(input_size);
  char *buffer = malloc(decoded_size + 1);
  buffer[decoded_size] = 0;
  return buffer;
}


x86 assembly (clang, -O0):
<base64_alloc_decode_buffer>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <base64_decoded_size@plt>
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
add    $0x1,%rdi
call   1040 <malloc@plt>
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
mov    -0x10(%rbp),%rcx
movb   $0x0,(%rax,%rcx,1)
mov    -0x18(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<base64_alloc_decode_buffer>:
push   %rbx
call   1030 <base64_decoded_size@plt>
mov    %rax,%rbx
lea    0x1(%rax),%rdi
call   1040 <malloc@plt>
movb   $0x0,(%rax,%rbx,1)
pop    %rbx
ret

LLVM IR (-O0):
define i8* @base64_alloc_decode_buffer(i64 %0) {
%2 = alloca i64
%3 = alloca i64
%4 = alloca i8*
store i64 %0, i64* %2
%5 = load i64, i64* %2
%6 = call i64 @base64_decoded_size(i64 %5)
store i64 %6, i64* %3
%7 = load i64, i64* %3
%8 = add i64 %7, 1
%9 = call i8* @malloc(i64 %8)
store i8* %9, i8** %4
%10 = load i8*, i8** %4
%11 = load i64, i64* %3
%12 = getelementptr inbounds i8, i8* %10, i64 %11
store i8 0, i8* %12
%13 = load i8*, i8** %4
ret i8* %13
}

LLVM IR (-O2):
define noalias i8* @base64_alloc_decode_buffer(i64 %0) {
%2 = tail call i64 @base64_decoded_size(i64 %0)
%3 = add i64 %2, 1
%4 = tail call i8* @malloc(i64 %3)
%5 = getelementptr inbounds i8, i8* %4, i64 %2
store i8 0, i8* %5
ret i8* %4
}
/* Variables and functions */
int /*<<< orphan*/ mergeSort(int *, int /*<<< orphan*/, int);
int /*<<< orphan*/ printIntArray(int *, int /*<<< orphan*/, int);
int main() {
  int size = 10;
  int arr[] = {9, 10, 8, 5, 1, 2, 4, 3, 6, 7};
  printIntArray(arr, 0, size - 1);
  mergeSort(arr, 0, size - 1);
  printIntArray(arr, 0, size - 1);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0xa,-0x8(%rbp)
lea    -0x30(%rbp),%rdi
lea    0xeaf(%rip),%rsi
mov    $0x28,%edx
call   1030 <memcpy@plt>
lea    -0x30(%rbp),%rdi
mov    -0x8(%rbp),%edx
sub    $0x1,%edx
xor    %esi,%esi
call   1050 <printIntArray@plt>
lea    -0x30(%rbp),%rdi
mov    -0x8(%rbp),%edx
sub    $0x1,%edx
xor    %esi,%esi
call   1040 <mergeSort@plt>
lea    -0x30(%rbp),%rdi
mov    -0x8(%rbp),%edx
sub    $0x1,%edx
xor    %esi,%esi
call   1050 <printIntArray@plt>
xor    %eax,%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x30,%rsp
mov    0xef4(%rip),%rax
mov    %rax,0x20(%rsp)
movaps 0xed8(%rip),%xmm0
movaps %xmm0,0x10(%rsp)
movaps 0xebc(%rip),%xmm0
movaps %xmm0,(%rsp)
mov    %rsp,%rbx
mov    %rbx,%rdi
xor    %esi,%esi
mov    $0x9,%edx
call   1040 <printIntArray@plt>
mov    %rbx,%rdi
xor    %esi,%esi
mov    $0x9,%edx
call   1030 <mergeSort@plt>
mov    %rbx,%rdi
xor    %esi,%esi
mov    $0x9,%edx
call   1040 <printIntArray@plt>
xor    %eax,%eax
add    $0x30,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@__const.main.arr = [10 x i32] [i32 9, i32 10, i32 8, i32 5, i32 1, i32 2, i32 4, i32 3, i32 6, i32 7]
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca [10 x i32]
store i32 0, i32* %1
store i32 10, i32* %2
%4 = bitcast [10 x i32]* %3 to i8*
%5 = getelementptr inbounds [10 x i32], [10 x i32]* %3, i64 0, i64 0
%6 = load i32, i32* %2
%7 = sub nsw i32 %6, 1
%8 = call i32 @printIntArray(i32* %5, i32 0, i32 %7)
%9 = getelementptr inbounds [10 x i32], [10 x i32]* %3, i64 0, i64 0
%10 = load i32, i32* %2
%11 = sub nsw i32 %10, 1
%12 = call i32 @mergeSort(i32* %9, i32 0, i32 %11)
%13 = getelementptr inbounds [10 x i32], [10 x i32]* %3, i64 0, i64 0
%14 = load i32, i32* %2
%15 = sub nsw i32 %14, 1
%16 = call i32 @printIntArray(i32* %13, i32 0, i32 %15)
ret i32 0
}

LLVM IR (-O2):
@__const.main.arr = [10 x i32] [i32 9, i32 10, i32 8, i32 5, i32 1, i32 2, i32 4, i32 3, i32 6, i32 7]
define i32 @main() {
%1 = alloca [10 x i32]
%2 = bitcast [10 x i32]* %1 to i8*
%3 = getelementptr inbounds [10 x i32], [10 x i32]* %1, i64 0, i64 0
%4 = call i32 @printIntArray(i32* %3, i32 0, i32 9)
%5 = call i32 @mergeSort(i32* %3, i32 0, i32 9)
%6 = call i32 @printIntArray(i32* %3, i32 0, i32 9)
ret i32 0
}