xunge/DecIR huggingface dataset:
/* Variables and functions */
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, char const *,
                           unsigned int, char const *, char const *);
int /*<<< orphan*/ stderr;
void unittest_fail(const char *expr, const char *file, unsigned int line,
                   const char *func) {
  fprintf(stderr, "%s:%i: %s: Unittest '%s' failed\n", file, line, func, expr);
}


x86 assembly (clang, -O0):
<unittest_fail>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    %rcx,-0x20(%rbp)
mov    0x2eb2(%rip),%rax
mov    (%rax),%edi
mov    -0x10(%rbp),%rdx
mov    -0x14(%rbp),%ecx
mov    -0x20(%rbp),%r8
mov    -0x8(%rbp),%r9
lea    0xeba(%rip),%rsi
call   1030 <fprintf@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<unittest_fail>:
mov    %rcx,%r8
mov    %edx,%ecx
mov    %rsi,%rdx
mov    %rdi,%r9
mov    0x2ebe(%rip),%rax
mov    (%rax),%edi
lea    0xed5(%rip),%rsi
jmp    1030 <fprintf@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [33 x i8] c"%s:%i: %s: Unittest '%s' failed\0A\00"
define void @unittest_fail(i8* %0, i8* %1, i32 %2, i8* %3) {
%5 = alloca i8*
%6 = alloca i8*
%7 = alloca i32
%8 = alloca i8*
store i8* %0, i8** %5
store i8* %1, i8** %6
store i32 %2, i32* %7
store i8* %3, i8** %8
%9 = load i32, i32* @stderr
%10 = load i8*, i8** %6
%11 = load i32, i32* %7
%12 = load i8*, i8** %8
%13 = load i8*, i8** %5
%14 = call i32 @fprintf(i32 %9, i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str, i64 0, i64 0), i8* %10, i32 %11, i8* %12, i8* %13)
ret void
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [33 x i8] c"%s:%i: %s: Unittest '%s' failed\0A\00"
define void @unittest_fail(i8* %0, i8* %1, i32 %2, i8* %3) {
%5 = load i32, i32* @stderr
%6 = tail call i32 @fprintf(i32 %5, i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str, i64 0, i64 0), i8* %1, i32 %2, i8* %3, i8* %0)
ret void
}
void XSetOMValues() {}


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

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

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

LLVM IR (-O2):
define void @XSetOMValues() {
ret void
}
void fc73(int n) {
  {
    typedef int(*b)[n];
    {
      typedef int(*c)[n];
      0;
    }
    {
      typedef int(*d)[n];
      goto a;
      0;
    }
  a:;
    typedef int(*e)[n];
    0;
  };
  {
    typedef int(*f)[n];
    {
      typedef int(*g)[n];
      0;
    };
    {
      typedef int(*h)[n];
      0;
    };
    ;
    typedef int(*i)[n];
    0;
  };
  ;
  typedef int(*j)[n];
  0;
}


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

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

LLVM IR (-O0):
define void @fc73(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = zext i32 %3 to i64
%5 = load i32, i32* %2
%6 = zext i32 %5 to i64
%7 = load i32, i32* %2
%8 = zext i32 %7 to i64
br label %9
9: ; preds = %1
%10 = load i32, i32* %2
%11 = zext i32 %10 to i64
%12 = load i32, i32* %2
%13 = zext i32 %12 to i64
%14 = load i32, i32* %2
%15 = zext i32 %14 to i64
%16 = load i32, i32* %2
%17 = zext i32 %16 to i64
%18 = load i32, i32* %2
%19 = zext i32 %18 to i64
%20 = load i32, i32* %2
%21 = zext i32 %20 to i64
ret void
}

LLVM IR (-O2):
define void @fc73(i32 %0) {
ret void
}
void fun_base_v1(int a) { return; }


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

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

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

LLVM IR (-O2):
define void @fun_base_v1(i32 %0) {
ret void
}
/* Variables and functions */
char *getenv(const char *varname) { return NULL; }


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

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

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

LLVM IR (-O2):
define noalias i8* @getenv(i8* nocapture readnone %0) {
ret i8* null
}
/* Variables and functions */
int /*<<< orphan*/ display_set_cursor(int /*<<< orphan*/, int /*<<< orphan*/);
int /*<<< orphan*/ lc75710_display_hal_init();
void display_init(void) {
  lc75710_display_hal_init();
  display_set_cursor(0, 0);
}


x86 assembly (clang, -O0):
<display_init>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1030 <lc75710_display_hal_init@plt>
xor    %esi,%esi
mov    %esi,%edi
call   1040 <display_set_cursor@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<display_init>:
push   %rax
xor    %eax,%eax
call   1030 <lc75710_display_hal_init@plt>
xor    %edi,%edi
xor    %esi,%esi
pop    %rax
jmp    1040 <display_set_cursor@plt>

LLVM IR (-O0):
define void @display_init() {
%1 = call i32 (...) @lc75710_display_hal_init()
%2 = call i32 @display_set_cursor(i32 0, i32 0)
ret void
}

LLVM IR (-O2):
define void @display_init() {
%1 = tail call i32 (...) @lc75710_display_hal_init()
%2 = tail call i32 @display_set_cursor(i32 0, i32 0)
ret void
}
int is_box_placeable(char ch) { return ch != '#' && ch != 'x'; }


x86 assembly (clang, -O0):
<is_box_placeable>:
push   %rbp
mov    %rsp,%rbp
mov    %dil,%al
mov    %al,-0x1(%rbp)
movsbl -0x1(%rbp),%ecx
xor    %eax,%eax
cmp    $0x23,%ecx
mov    %al,-0x2(%rbp)
je     1129 <is_box_placeable+0x29>
movsbl -0x1(%rbp),%eax
cmp    $0x78,%eax
setne  %al
mov    %al,-0x2(%rbp)
mov    -0x2(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_box_placeable>:
cmp    $0x23,%dil
setne  %al
cmp    $0x78,%dil
setne  %cl
and    %al,%cl
movzbl %cl,%eax
ret

LLVM IR (-O0):
define i32 @is_box_placeable(i8 signext %0) {
%2 = alloca i8
store i8 %0, i8* %2
%3 = load i8, i8* %2
%4 = sext i8 %3 to i32
%5 = icmp ne i32 %4, 35
br i1 %5, label %6, label %10
6: ; preds = %1
%7 = load i8, i8* %2
%8 = sext i8 %7 to i32
%9 = icmp ne i32 %8, 120
br label %10
10: ; preds = %6, %1
%11 = phi i1 [ false, %1 ], [ %9, %6 ]
%12 = zext i1 %11 to i32
ret i32 %12
}

LLVM IR (-O2):
define i32 @is_box_placeable(i8 signext %0) {
%2 = icmp ne i8 %0, 35
%3 = icmp ne i8 %0, 120
%4 = and i1 %2, %3
%5 = zext i1 %4 to i32
ret i32 %5
}
/* Variables and functions */
int EOF;
int get(void *arg) {
  const unsigned char **s = arg;
  unsigned char c = **s;
  if (!c)
    return EOF;
  (*s)++;
  return c;
}


x86 assembly (clang, -O0):
<get>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
mov    (%rax),%rax
mov    (%rax),%al
mov    %al,-0x19(%rbp)
cmpb   $0x0,-0x19(%rbp)
jne    1137 <get+0x37>
mov    0x2ebb(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x4(%rbp)
jmp    114c <get+0x4c>
mov    -0x18(%rbp),%rax
mov    (%rax),%rcx
add    $0x1,%rcx
mov    %rcx,(%rax)
movzbl -0x19(%rbp),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<get>:
mov    (%rdi),%rcx
movzbl (%rcx),%eax
test   %eax,%eax
je     1112 <get+0x12>
add    $0x1,%rcx
mov    %rcx,(%rdi)
ret
mov    0x2ecf(%rip),%rax
mov    (%rax),%eax
ret

LLVM IR (-O0):
@EOF = global i32 0
define i32 @get(i8* %0) {
%2 = alloca i32
%3 = alloca i8*
%4 = alloca i8**
%5 = alloca i8
store i8* %0, i8** %3
%6 = load i8*, i8** %3
%7 = bitcast i8* %6 to i8**
store i8** %7, i8*** %4
%8 = load i8**, i8*** %4
%9 = load i8*, i8** %8
%10 = load i8, i8* %9
store i8 %10, i8* %5
%11 = load i8, i8* %5
%12 = icmp ne i8 %11, 0
br i1 %12, label %15, label %13
13: ; preds = %1
%14 = load i32, i32* @EOF
store i32 %14, i32* %2
br label %21
15: ; preds = %1
%16 = load i8**, i8*** %4
%17 = load i8*, i8** %16
%18 = getelementptr inbounds i8, i8* %17, i32 1
store i8* %18, i8** %16
%19 = load i8, i8* %5
%20 = zext i8 %19 to i32
store i32 %20, i32* %2
br label %21
21: ; preds = %15, %13
%22 = load i32, i32* %2
ret i32 %22
}

LLVM IR (-O2):
@EOF = global i32 0
define i32 @get(i8* nocapture %0) {
%2 = bitcast i8* %0 to i8**
%3 = load i8*, i8** %2
%4 = load i8, i8* %3
%5 = icmp eq i8 %4, 0
br i1 %5, label %6, label %8
6: ; preds = %1
%7 = load i32, i32* @EOF
br label %11
8: ; preds = %1
%9 = getelementptr inbounds i8, i8* %3, i64 1
store i8* %9, i8** %2
%10 = zext i8 %4 to i32
br label %11
11: ; preds = %8, %6
%12 = phi i32 [ %10, %8 ], [ %7, %6 ]
ret i32 %12
}
/* Variables and functions */
int /*<<< orphan*/ print(char *);
int /*<<< orphan*/ test_alignas();
int /*<<< orphan*/ test_alignof();
int /*<<< orphan*/ test_constexpr();
void testmain() {
  print("alignment");
  test_alignas();
  test_alignof();
  test_constexpr();
}


x86 assembly (clang, -O0):
<testmain>:
push   %rbp
mov    %rsp,%rbp
lea    0xeb5(%rip),%rdi
call   1040 <print@plt>
mov    $0x0,%al
call   1050 <test_alignas@plt>
mov    $0x0,%al
call   1030 <test_alignof@plt>
mov    $0x0,%al
call   1060 <test_constexpr@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<testmain>:
push   %rax
lea    0xeb8(%rip),%rdi
call   1040 <print@plt>
xor    %eax,%eax
call   1050 <test_alignas@plt>
xor    %eax,%eax
call   1030 <test_alignof@plt>
xor    %eax,%eax
pop    %rcx
jmp    1060 <test_constexpr@plt>

LLVM IR (-O0):
@.str = [10 x i8] c"alignment\00"
define void @testmain() {
%1 = call i32 @print(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0))
%2 = call i32 (...) @test_alignas()
%3 = call i32 (...) @test_alignof()
%4 = call i32 (...) @test_constexpr()
ret void
}

LLVM IR (-O2):
@.str = [10 x i8] c"alignment\00"
define void @testmain() {
%1 = tail call i32 @print(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 (...) @test_alignas()
%3 = tail call i32 (...) @test_alignof()
%4 = tail call i32 (...) @test_constexpr()
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
scalar_t__ fgets(char *, int, int /*<<< orphan*/ *);
int /*<<< orphan*/ parse_line(char *, char *);
void parse_sgml(FILE *in, char *input_name) {
  static char line[1000];
  while (fgets(line, 1000, in)) {
    parse_line(line, input_name);
  }
}


x86 assembly (clang, -O0):
<parse_sgml>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdx
lea    0x2f05(%rip),%rdi
mov    $0x3e8,%esi
call   1030 <fgets@plt>
cmp    $0x0,%rax
je     1164 <parse_sgml+0x44>
mov    -0x10(%rbp),%rsi
lea    0x2ee6(%rip),%rdi
call   1040 <parse_line@plt>
jmp    1130 <parse_sgml+0x10>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<parse_sgml>:
push   %r15
push   %r14
push   %rbx
mov    %rsi,%r14
mov    %rdi,%r15
lea    0x2f0e(%rip),%rdi
mov    $0x3e8,%esi
mov    %r15,%rdx
call   1030 <fgets@plt>
test   %rax,%rax
je     1170 <parse_sgml+0x50>
lea    0x2ef5(%rip),%rbx
nopl   0x0(%rax,%rax,1)
mov    %rbx,%rdi
mov    %r14,%rsi
call   1040 <parse_line@plt>
mov    %rbx,%rdi
mov    $0x3e8,%esi
mov    %r15,%rdx
call   1030 <fgets@plt>
test   %rax,%rax
jne    1150 <parse_sgml+0x30>
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@parse_sgml.line = internal global [1000 x i8] zeroinitializer
define void @parse_sgml(i32* %0, i8* %1) {
%3 = alloca i32*
%4 = alloca i8*
store i32* %0, i32** %3
store i8* %1, i8** %4
br label %5
5: ; preds = %9, %2
%6 = load i32*, i32** %3
%7 = call i64 @fgets(i8* getelementptr inbounds ([1000 x i8], [1000 x i8]* @parse_sgml.line, i64 0, i64 0), i32 1000, i32* %6)
%8 = icmp ne i64 %7, 0
br i1 %8, label %9, label %12
9: ; preds = %5
%10 = load i8*, i8** %4
%11 = call i32 @parse_line(i8* getelementptr inbounds ([1000 x i8], [1000 x i8]* @parse_sgml.line, i64 0, i64 0), i8* %10)
br label %5
12: ; preds = %5
ret void
}

LLVM IR (-O2):
@parse_sgml.line = internal global [1000 x i8] zeroinitializer
define void @parse_sgml(i32* nocapture %0, i8* %1) {
%3 = tail call i64 @fgets(i8* getelementptr inbounds ([1000 x i8], [1000 x i8]* @parse_sgml.line, i64 0, i64 0), i32 1000, i32* %0)
%4 = icmp eq i64 %3, 0
br i1 %4, label %9, label %5
5: ; preds = %2, %5
%6 = tail call i32 @parse_line(i8* getelementptr inbounds ([1000 x i8], [1000 x i8]* @parse_sgml.line, i64 0, i64 0), i8* %1)
%7 = tail call i64 @fgets(i8* getelementptr inbounds ([1000 x i8], [1000 x i8]* @parse_sgml.line, i64 0, i64 0), i32 1000, i32* %0)
%8 = icmp eq i64 %7, 0
br i1 %8, label %9, label %5
9: ; preds = %5, %2
ret void
}
double sin_integ1(const double kr, const double sinkr, const double coskr) {
  return sinkr - kr * coskr;
}


x86 assembly (clang, -O0):
<sin_integ1>:
push   %rbp
mov    %rsp,%rbp
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
movsd  %xmm2,-0x18(%rbp)
movsd  -0x10(%rbp),%xmm1
movsd  -0x8(%rbp),%xmm0
movsd  -0x18(%rbp),%xmm2
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<sin_integ1>:
mulsd  %xmm2,%xmm0
subsd  %xmm0,%xmm1
movapd %xmm1,%xmm0
ret

LLVM IR (-O0):
define double @sin_integ1(double %0, double %1, double %2) {
%4 = alloca double
%5 = alloca double
%6 = alloca double
store double %0, double* %4
store double %1, double* %5
store double %2, double* %6
%7 = load double, double* %5
%8 = load double, double* %4
%9 = load double, double* %6
%10 = fneg double %8
%11 = call double @llvm.fmuladd.f64(double %10, double %9, double %7)
ret double %11
}

LLVM IR (-O2):
define double @sin_integ1(double %0, double %1, double %2) {
%4 = fneg double %0
%5 = tail call double @llvm.fmuladd.f64(double %4, double %2, double %1)
ret double %5
}
void fvp(void *p) {}


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

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

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

LLVM IR (-O2):
define void @fvp(i8* nocapture %0) {
ret void
}
/* Type definitions */
typedef scalar_t__ uint8_t;
typedef int /*<<< orphan*/ uint32_t;

/* Variables and functions */
int /*<<< orphan*/ memcpy(scalar_t__ *, scalar_t__ *, int);
int /*<<< orphan*/ strtol(scalar_t__ *, int /*<<< orphan*/ *, int);
uint32_t get_int32(uint8_t *data) {
  uint8_t temp[9];
  memcpy(temp, data, 8);
  temp[8] = 0;
  return strtol(temp, NULL, 16);
}


x86 assembly (clang, -O0):
<get_int32>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
mov    %rdi,-0x8(%rbp)
lea    -0x50(%rbp),%rdi
mov    -0x8(%rbp),%rsi
mov    $0x8,%edx
call   1040 <memcpy@plt>
movq   $0x0,-0x10(%rbp)
lea    -0x50(%rbp),%rdi
xor    %eax,%eax
mov    %eax,%esi
mov    $0x10,%edx
call   1030 <strtol@plt>
add    $0x50,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<get_int32>:
push   %rbx
sub    $0x50,%rsp
mov    %rdi,%rsi
mov    %rsp,%rbx
mov    %rbx,%rdi
mov    $0x8,%edx
call   1040 <memcpy@plt>
movq   $0x0,0x40(%rsp)
mov    %rbx,%rdi
xor    %esi,%esi
mov    $0x10,%edx
call   1030 <strtol@plt>
add    $0x50,%rsp
pop    %rbx
ret

LLVM IR (-O0):
define i32 @get_int32(i64* %0) {
%2 = alloca i64*
%3 = alloca [9 x i64]
store i64* %0, i64** %2
%4 = getelementptr inbounds [9 x i64], [9 x i64]* %3, i64 0, i64 0
%5 = load i64*, i64** %2
%6 = call i32 @memcpy(i64* %4, i64* %5, i32 8)
%7 = getelementptr inbounds [9 x i64], [9 x i64]* %3, i64 0, i64 8
store i64 0, i64* %7
%8 = getelementptr inbounds [9 x i64], [9 x i64]* %3, i64 0, i64 0
%9 = call i32 @strtol(i64* %8, i32* null, i32 16)
ret i32 %9
}

LLVM IR (-O2):
define i32 @get_int32(i64* %0) {
%2 = alloca [9 x i64]
%3 = bitcast [9 x i64]* %2 to i8*
%4 = getelementptr inbounds [9 x i64], [9 x i64]* %2, i64 0, i64 0
%5 = call i32 @memcpy(i64* %4, i64* %0, i32 8)
%6 = getelementptr inbounds [9 x i64], [9 x i64]* %2, i64 0, i64 8
store i64 0, i64* %6
%7 = call i32 @strtol(i64* nocapture %4, i32* null, i32 16)
ret i32 %7
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, char *);
int main(void) {
  int i;
  char line[81];
  void readLine(char buffer[]);
  for (i = 0; i < 3; ++i) {
    readLine(line);
    printf("%s\n\n", line);
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x60,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
cmpl   $0x3,-0x8(%rbp)
jge    1167 <main+0x47>
lea    -0x60(%rbp),%rdi
call   1040 <readLine@plt>
lea    -0x60(%rbp),%rsi
lea    0xeac(%rip),%rdi
call   1030 <printf@plt>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1136 <main+0x16>
xor    %eax,%eax
add    $0x60,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r14
push   %rbx
sub    $0x58,%rsp
mov    %rsp,%rbx
mov    %rbx,%rdi
call   1040 <readLine@plt>
lea    0xec7(%rip),%r14
mov    %r14,%rdi
mov    %rbx,%rsi
call   1030 <printf@plt>
mov    %rbx,%rdi
call   1040 <readLine@plt>
mov    %r14,%rdi
mov    %rbx,%rsi
call   1030 <printf@plt>
mov    %rbx,%rdi
call   1040 <readLine@plt>
mov    %r14,%rdi
mov    %rbx,%rsi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x58,%rsp
pop    %rbx
pop    %r14
ret

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

LLVM IR (-O2):
@.str = [5 x i8] c"%s\0A\0A\00"
define i32 @main() {
%1 = alloca [81 x i8]
%2 = getelementptr inbounds [81 x i8], [81 x i8]* %1, i64 0, i64 0
%3 = call i32 @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i8* %2)
%4 = call i32 @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i8* %2)
%5 = call i32 @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i8* %2)
ret i32 0
}
void hpgl_background(int color) { color = color; }


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

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

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

LLVM IR (-O2):
define void @hpgl_background(i32 %0) {
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ pthread_attr_t;

/* Variables and functions */
int pthread_attr_setstackaddr(pthread_attr_t *attr, void *stackaddr) {
  (void)attr;
  (void)stackaddr;
  return 0;
}


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

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

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

LLVM IR (-O2):
define i32 @pthread_attr_setstackaddr(i32* nocapture readnone %0, i8* nocapture readnone %1) {
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int);
void test_while(int nr) {
  while (nr-- > 0)
    printf("%d\n", nr);
}


x86 assembly (clang, -O0):
<test_while>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%eax
mov    %eax,%ecx
add    $0xffffffff,%ecx
mov    %ecx,-0x4(%rbp)
cmp    $0x0,%eax
jle    1143 <test_while+0x33>
mov    -0x4(%rbp),%esi
lea    0xec7(%rip),%rdi
call   1030 <printf@plt>
jmp    111b <test_while+0xb>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_while>:
push   %r14
push   %rbx
push   %rax
test   %edi,%edi
jle    1143 <test_while+0x33>
mov    %edi,%ebx
add    $0x1,%ebx
lea    0xedc(%rip),%r14
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
lea    -0x2(%rbx),%esi
mov    %r14,%rdi
call   1030 <printf@plt>
add    $0xffffffff,%ebx
cmp    $0x1,%ebx
ja     1130 <test_while+0x20>
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
@.str = [4 x i8] c"%d\0A\00"
define void @test_while(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
br label %3
3: ; preds = %7, %1
%4 = load i32, i32* %2
%5 = add nsw i32 %4, -1
store i32 %5, i32* %2
%6 = icmp sgt i32 %4, 0
br i1 %6, label %7, label %10
7: ; preds = %3
%8 = load i32, i32* %2
%9 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %8)
br label %3
10: ; preds = %3
ret void
}

LLVM IR (-O2):
@.str = [4 x i8] c"%d\0A\00"
define void @test_while(i32 %0) {
%2 = icmp sgt i32 %0, 0
br i1 %2, label %3, label %8
3: ; preds = %1, %3
%4 = phi i32 [ %5, %3 ], [ %0, %1 ]
%5 = add nsw i32 %4, -1
%6 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %5)
%7 = icmp ugt i32 %4, 1
br i1 %7, label %3, label %8
8: ; preds = %3, %1
ret void
}
int process_create() { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @process_create() {
ret i32 0
}
int omp_get_thread_num() { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @omp_get_thread_num() {
ret i32 0
}
int f(int (*sum)(void)) { return sum(); }


x86 assembly (clang, -O0):
<f>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
call   *-0x8(%rbp)
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<f>:
jmp    *%rdi

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

LLVM IR (-O2):
define i32 @f(i32 ()* nocapture %0) {
%2 = tail call i32 %0()
ret i32 %2
}
const char *Zip_Brief(void) { return "Multiple Iterator"; }


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

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

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

LLVM IR (-O2):
@.str = [18 x i8] c"Multiple Iterator\00"
define i8* @Zip_Brief() {
ret i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0)
}
/* Variables and functions */
int /*<<< orphan*/ EXIT_FAILURE;
int execv(char const *, char *const *);
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ perror(char *);
void execv_or_die(const char *path, char *const argv[]) {
  if (execv(path, argv) == -1) {
    perror("error calling execv()");
    exit(EXIT_FAILURE);
  }
}


x86 assembly (clang, -O0):
<execv_or_die>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1050 <execv@plt>
cmp    $0xffffffff,%eax
jne    1170 <execv_or_die+0x40>
lea    0xea3(%rip),%rdi
call   1030 <perror@plt>
mov    0x2e77(%rip),%rax
mov    (%rax),%edi
call   1040 <exit@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<execv_or_die>:
push   %rax
call   1050 <execv@plt>
cmp    $0xffffffff,%eax
je     113d <execv_or_die+0xd>
pop    %rax
ret
lea    0xebc(%rip),%rdi
call   1030 <perror@plt>
mov    0x2e90(%rip),%rax
mov    (%rax),%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@.str = [22 x i8] c"error calling execv()\00"
@EXIT_FAILURE = global i32 0
define void @execv_or_die(i8* %0, i8** %1) {
%3 = alloca i8*
%4 = alloca i8**
store i8* %0, i8** %3
store i8** %1, i8*** %4
%5 = load i8*, i8** %3
%6 = load i8**, i8*** %4
%7 = call i32 @execv(i8* %5, i8** %6)
%8 = icmp eq i32 %7, -1
br i1 %8, label %9, label %13
9: ; preds = %2
%10 = call i32 @perror(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0))
%11 = load i32, i32* @EXIT_FAILURE
%12 = call i32 @exit(i32 %11)
unreachable
13: ; preds = %2
ret void
}

LLVM IR (-O2):
@.str = [22 x i8] c"error calling execv()\00"
@EXIT_FAILURE = global i32 0
define void @execv_or_die(i8* %0, i8** %1) {
%3 = tail call i32 @execv(i8* %0, i8** %1)
%4 = icmp eq i32 %3, -1
br i1 %4, label %5, label %9
5: ; preds = %2
%6 = tail call i32 @perror(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0))
%7 = load i32, i32* @EXIT_FAILURE
%8 = tail call i32 @exit(i32 %7)
unreachable
9: ; preds = %2
ret void
}
/* Variables and functions */
long random();
void *randomPtr(void) {
  long int x = random();
  return (void *)x;
}


x86 assembly (clang, -O0):
<randomPtr>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x0,%al
call   1030 <random@plt>
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
define i8* @randomPtr() {
%1 = alloca i64
%2 = call i64 (...) @random()
store i64 %2, i64* %1
%3 = load i64, i64* %1
%4 = inttoptr i64 %3 to i8*
ret i8* %4
}

LLVM IR (-O2):
define i8* @randomPtr() {
%1 = tail call i64 (...) @random()
%2 = inttoptr i64 %1 to i8*
ret i8* %2
}
void swap(int *a, int *b) {
  int w = *a;
  *a = *b;
  *b = w;
}


x86 assembly (clang, -O0):
<swap>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%eax
mov    %eax,-0x14(%rbp)
mov    -0x10(%rbp),%rax
mov    (%rax),%ecx
mov    -0x8(%rbp),%rax
mov    %ecx,(%rax)
mov    -0x14(%rbp),%ecx
mov    -0x10(%rbp),%rax
mov    %ecx,(%rax)
pop    %rbp
ret

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

LLVM IR (-O0):
define void @swap(i32* %0, i32* %1) {
%3 = alloca i32*
%4 = alloca i32*
%5 = alloca i32
store i32* %0, i32** %3
store i32* %1, i32** %4
%6 = load i32*, i32** %3
%7 = load i32, i32* %6
store i32 %7, i32* %5
%8 = load i32*, i32** %4
%9 = load i32, i32* %8
%10 = load i32*, i32** %3
store i32 %9, i32* %10
%11 = load i32, i32* %5
%12 = load i32*, i32** %4
store i32 %11, i32* %12
ret void
}

LLVM IR (-O2):
define void @swap(i32* nocapture %0, i32* nocapture %1) {
%3 = load i32, i32* %0
%4 = load i32, i32* %1
store i32 %4, i32* %0
store i32 %3, i32* %1
ret void
}
/* Type definitions */
struct list_head {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ __list_splice(struct list_head *, struct list_head *);
int /*<<< orphan*/ list_empty(struct list_head *);
void list_splice(struct list_head *list, struct list_head *head) {
  if (!list_empty(list))
    __list_splice(list, head);
}


x86 assembly (clang, -O0):
<list_splice>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
call   1040 <list_empty@plt>
cmp    $0x0,%eax
jne    114f <list_splice+0x2f>
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1030 <__list_splice@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<list_splice>:
push   %r14
push   %rbx
push   %rax
mov    %rsi,%r14
mov    %rdi,%rbx
call   1040 <list_empty@plt>
test   %eax,%eax
je     113b <list_splice+0x1b>
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret
mov    %rbx,%rdi
mov    %r14,%rsi
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1030 <__list_splice@plt>

LLVM IR (-O0):
%struct.list_head = type { i32 }
define void @list_splice(%struct.list_head* %0, %struct.list_head* %1) {
%3 = alloca %struct.list_head*
%4 = alloca %struct.list_head*
store %struct.list_head* %0, %struct.list_head** %3
store %struct.list_head* %1, %struct.list_head** %4
%5 = load %struct.list_head*, %struct.list_head** %3
%6 = call i32 @list_empty(%struct.list_head* %5)
%7 = icmp ne i32 %6, 0
br i1 %7, label %12, label %8
8: ; preds = %2
%9 = load %struct.list_head*, %struct.list_head** %3
%10 = load %struct.list_head*, %struct.list_head** %4
%11 = call i32 @__list_splice(%struct.list_head* %9, %struct.list_head* %10)
br label %12
12: ; preds = %8, %2
ret void
}

LLVM IR (-O2):
%struct.list_head = type { i32 }
define void @list_splice(%struct.list_head* %0, %struct.list_head* %1) {
%3 = tail call i32 @list_empty(%struct.list_head* %0)
%4 = icmp eq i32 %3, 0
br i1 %4, label %5, label %7
5: ; preds = %2
%6 = tail call i32 @__list_splice(%struct.list_head* %0, %struct.list_head* %1)
br label %7
7: ; preds = %5, %2
ret void
}
void f2(int n) {
  int a = 0;
  while (n--) {
    a *= 1.01;
  }
}


x86 assembly (clang, -O0):
<f2>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
mov    -0x4(%rbp),%eax
mov    %eax,%ecx
add    $0xffffffff,%ecx
mov    %ecx,-0x4(%rbp)
cmp    $0x0,%eax
je     113f <f2+0x3f>
cvtsi2sdl -0x8(%rbp),%xmm0
movsd  0xed1(%rip),%xmm1
mulsd  %xmm1,%xmm0
cvttsd2si %xmm0,%eax
mov    %eax,-0x8(%rbp)
jmp    110e <f2+0xe>
pop    %rbp
ret

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

LLVM IR (-O0):
define void @f2(i32 %0) {
%2 = alloca i32
%3 = alloca i32
store i32 %0, i32* %2
store i32 0, i32* %3
br label %4
4: ; preds = %8, %1
%5 = load i32, i32* %2
%6 = add nsw i32 %5, -1
store i32 %6, i32* %2
%7 = icmp ne i32 %5, 0
br i1 %7, label %8, label %13
8: ; preds = %4
%9 = load i32, i32* %3
%10 = sitofp i32 %9 to double
%11 = fmul double %10, 1.010000e+00
%12 = fptosi double %11 to i32
store i32 %12, i32* %3
br label %4
13: ; preds = %4
ret void
}

LLVM IR (-O2):
define void @f2(i32 %0) {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ sched_yield();
int /*<<< orphan*/ sleep(int);
int main() {
  sched_yield();
  sleep(1);
  return 0;
}


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

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

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = call i32 (...) @sched_yield()
%3 = call i32 @sleep(i32 1)
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 (...) @sched_yield()
%2 = tail call i32 @sleep(i32 1)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ CLI_TMP(int /*<<< orphan*/, int, int, int, char *, char *,
                           char);
int main(int argc, char *argv[]) {
  char d[10] = "ABC";
  CLI_TMP(0, 10, 20, 30, d, "ddsfssf", 'c');
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    0xed3(%rip),%rax
mov    %rax,-0x1a(%rbp)
mov    0xed0(%rip),%ax
mov    %ax,-0x12(%rbp)
lea    -0x1a(%rbp),%r8
xor    %edi,%edi
mov    $0xa,%esi
mov    $0x14,%edx
mov    $0x1e,%ecx
lea    0xeb2(%rip),%r9
movl   $0x63,(%rsp)
call   1030 <CLI_TMP@plt>
xor    %eax,%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
sub    $0x18,%rsp
movw   $0x0,0x10(%rsp)
movq   $0x434241,0x8(%rsp)
movl   $0x63,(%rsp)
lea    0xed8(%rip),%r9
lea    0x8(%rsp),%r8
xor    %edi,%edi
mov    $0xa,%esi
mov    $0x14,%edx
mov    $0x1e,%ecx
call   1030 <CLI_TMP@plt>
xor    %eax,%eax
add    $0x18,%rsp
ret

LLVM IR (-O0):
@__const.main.d = [10 x i8] c"ABC\00\00\00\00\00\00\00"
@.str = [8 x i8] c"ddsfssf\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca [10 x i8]
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%7 = bitcast [10 x i8]* %6 to i8*
%8 = getelementptr inbounds [10 x i8], [10 x i8]* %6, i64 0, i64 0
%9 = call i32 @CLI_TMP(i32 0, i32 10, i32 20, i32 30, i8* %8, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i8 signext 99)
ret i32 0
}

LLVM IR (-O2):
@__const.main.d = [10 x i8] c"ABC\00\00\00\00\00\00\00"
@.str = [8 x i8] c"ddsfssf\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = alloca [10 x i8]
%4 = getelementptr inbounds [10 x i8], [10 x i8]* %3, i64 0, i64 0
%5 = call i32 @CLI_TMP(i32 0, i32 10, i32 20, i32 30, i8* %4, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i8 signext 99)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ ipc_close_slave();
int /*<<< orphan*/ ipc_unlock();
void cleanup_and_exit(int ret) {
  ipc_unlock();
  ipc_close_slave();
  exit(ret);
}


x86 assembly (clang, -O0):
<cleanup_and_exit>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    $0x0,%al
call   1030 <ipc_unlock@plt>
mov    $0x0,%al
call   1040 <ipc_close_slave@plt>
mov    -0x4(%rbp),%edi
call   1050 <exit@plt>

x86 assembly (clang, -O2):
<cleanup_and_exit>:
push   %rbx
mov    %edi,%ebx
xor    %eax,%eax
call   1030 <ipc_unlock@plt>
xor    %eax,%eax
call   1040 <ipc_close_slave@plt>
mov    %ebx,%edi
call   1050 <exit@plt>

LLVM IR (-O0):
define void @cleanup_and_exit(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = call i32 (...) @ipc_unlock()
%4 = call i32 (...) @ipc_close_slave()
%5 = load i32, i32* %2
%6 = call i32 @exit(i32 %5)
unreachable
}

LLVM IR (-O2):
define void @cleanup_and_exit(i32 %0) {
%2 = tail call i32 (...) @ipc_unlock()
%3 = tail call i32 (...) @ipc_close_slave()
%4 = tail call i32 @exit(i32 %0)
unreachable
}
__attribute__((always_)) float brotli_min_float(float a, float b) {
  return a < b ? a : b;
}


x86 assembly (clang, -O0):
<brotli_min_float>:
push   %rbp
mov    %rsp,%rbp
movss  %xmm0,-0x4(%rbp)
movss  %xmm1,-0x8(%rbp)
movss  -0x4(%rbp),%xmm1
movss  -0x8(%rbp),%xmm0
ucomiss %xmm1,%xmm0
jbe    1130 <brotli_min_float+0x30>
movss  -0x4(%rbp),%xmm0
movss  %xmm0,-0xc(%rbp)
jmp    113a <brotli_min_float+0x3a>
movss  -0x8(%rbp),%xmm0
movss  %xmm0,-0xc(%rbp)
movss  -0xc(%rbp),%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<brotli_min_float>:
minss  %xmm1,%xmm0
ret

LLVM IR (-O0):
define float @brotli_min_float(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 = fcmp olt float %5, %6
br i1 %7, label %8, label %10
8: ; preds = %2
%9 = load float, float* %3
br label %12
10: ; preds = %2
%11 = load float, float* %4
br label %12
12: ; preds = %10, %8
%13 = phi float [ %9, %8 ], [ %11, %10 ]
ret float %13
}

LLVM IR (-O2):
define float @brotli_min_float(float %0, float %1) {
%3 = fcmp olt float %0, %1
%4 = select i1 %3, float %0, float %1
ret float %4
}
/* Variables and functions */
int /*<<< orphan*/ Adrian();
int /*<<< orphan*/ Pedro();
int /*<<< orphan*/ david();
int /*<<< orphan*/ misael();
int /*<<< orphan*/ misael2();
int /*<<< orphan*/ printf(char *);
int main(void) {
  printf("Hola mundo\n");
  Pedro();
  david();
  Adrian();
  misael();
  misael2();
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
lea    0xe95(%rip),%rdi
call   1060 <printf@plt>
mov    $0x0,%al
call   1040 <Pedro@plt>
mov    $0x0,%al
call   1080 <david@plt>
mov    $0x0,%al
call   1030 <Adrian@plt>
mov    $0x0,%al
call   1070 <misael@plt>
mov    $0x0,%al
call   1050 <misael2@plt>
xor    %eax,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xe98(%rip),%rdi
call   1050 <puts@plt>
xor    %eax,%eax
call   1040 <Pedro@plt>
xor    %eax,%eax
call   1080 <david@plt>
xor    %eax,%eax
call   1030 <Adrian@plt>
xor    %eax,%eax
call   1070 <misael@plt>
xor    %eax,%eax
call   1060 <misael2@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [12 x i8] c"Hola mundo\0A\00"
define i32 @main() {
%1 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0))
%2 = call i32 (...) @Pedro()
%3 = call i32 (...) @david()
%4 = call i32 (...) @Adrian()
%5 = call i32 (...) @misael()
%6 = call i32 (...) @misael2()
ret i32 0
}

LLVM IR (-O2):
@str = [11 x i8] c"Hola mundo\00"
define i32 @main() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @str, i64 0, i64 0))
%2 = tail call i32 (...) @Pedro()
%3 = tail call i32 (...) @david()
%4 = tail call i32 (...) @Adrian()
%5 = tail call i32 (...) @misael()
%6 = tail call i32 (...) @misael2()
ret i32 0
}
/* Variables and functions */
scalar_t__ isalnum(char);
is_hostvar_char(char c) { return isalnum(c) || c == '_'; }


x86 assembly (clang, -O0):
<is_hostvar_char>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %dil,%al
mov    %al,-0x1(%rbp)
movsbl -0x1(%rbp),%edi
call   1030 <isalnum@plt>
mov    %rax,%rcx
mov    $0x1,%al
cmp    $0x0,%rcx
mov    %al,-0x2(%rbp)
jne    1146 <is_hostvar_char+0x36>
movsbl -0x1(%rbp),%eax
cmp    $0x5f,%eax
sete   %al
mov    %al,-0x2(%rbp)
mov    -0x2(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_hostvar_char>:
push   %rbx
mov    %edi,%ebx
call   1030 <isalnum@plt>
test   %rax,%rax
setne  %al
cmp    $0x5f,%bl
sete   %cl
or     %al,%cl
movzbl %cl,%eax
pop    %rbx
ret

LLVM IR (-O0):
define i32 @is_hostvar_char(i8 signext %0) {
%2 = alloca i8
store i8 %0, i8* %2
%3 = load i8, i8* %2
%4 = call i64 @isalnum(i8 signext %3)
%5 = icmp ne i64 %4, 0
br i1 %5, label %10, label %6
6: ; preds = %1
%7 = load i8, i8* %2
%8 = sext i8 %7 to i32
%9 = icmp eq i32 %8, 95
br label %10
10: ; preds = %6, %1
%11 = phi i1 [ true, %1 ], [ %9, %6 ]
%12 = zext i1 %11 to i32
ret i32 %12
}

LLVM IR (-O2):
define i32 @is_hostvar_char(i8 signext %0) {
%2 = tail call i64 @isalnum(i8 signext %0)
%3 = icmp ne i64 %2, 0
%4 = icmp eq i8 %0, 95
%5 = or i1 %4, %3
%6 = zext i1 %5 to i32
ret i32 %6
}
unsigned getval_229() { return 3525362315U; }


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

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

LLVM IR (-O0):
define i32 @getval_229() {
ret i32 -769604981
}

LLVM IR (-O2):
define i32 @getval_229() {
ret i32 -769604981
}
/* Variables and functions */
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ printf(char *, int);
void terminate(int sig) {
  printf("Shutdown called on signal %d\n", sig);
  exit(0);
}


x86 assembly (clang, -O0):
<terminate>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%esi
lea    0xecb(%rip),%rdi
call   1030 <printf@plt>
xor    %edi,%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<terminate>:
push   %rax
mov    %edi,%esi
lea    0xed6(%rip),%rdi
call   1030 <printf@plt>
xor    %edi,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@.str = [30 x i8] c"Shutdown called on signal %d\0A\00"
define void @terminate(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = call i32 @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str, i64 0, i64 0), i32 %3)
%5 = call i32 @exit(i32 0)
unreachable
}

LLVM IR (-O2):
@.str = [30 x i8] c"Shutdown called on signal %d\0A\00"
define void @terminate(i32 %0) {
%2 = tail call i32 @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str, i64 0, i64 0), i32 %0)
%3 = tail call i32 @exit(i32 0)
unreachable
}
void RandomFunc(unsigned char input[1], unsigned char output[1]) {
  unsigned char state[1];
  unsigned char local1;
  {
    state[0UL] = (input[0UL] + 51238316UL) + (unsigned char)234;
    local1 = 0UL;
    while (local1 < (unsigned char)0) {
      state[0UL] = state[local1] + state[0UL];
      state[0UL] += state[0UL];
      local1 += 2UL;
    }
    output[0UL] = state[0UL] + 724560680UL;
  }
}


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
add    $0x30dd5ac,%rax
add    $0xea,%rax
mov    %al,-0x11(%rbp)
movb   $0x0,-0x12(%rbp)
movzbl -0x12(%rbp),%eax
cmp    $0x0,%eax
jge    1162 <RandomFunc+0x62>
movzbl -0x12(%rbp),%eax
movzbl -0x11(%rbp,%rax,1),%eax
movzbl -0x11(%rbp),%ecx
add    %ecx,%eax
mov    %al,-0x11(%rbp)
movzbl -0x11(%rbp),%ecx
movzbl -0x11(%rbp),%eax
add    %ecx,%eax
mov    %al,-0x11(%rbp)
movzbl -0x12(%rbp),%eax
add    $0x2,%rax
mov    %al,-0x12(%rbp)
jmp    1126 <RandomFunc+0x26>
movzbl -0x11(%rbp),%eax
add    $0x2b2feb28,%rax
mov    %al,%cl
mov    -0x10(%rbp),%rax
mov    %cl,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<RandomFunc>:
mov    (%rdi),%al
add    $0xbe,%al
mov    %al,(%rsi)
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 = add i64 %10, 51238316
%12 = add i64 %11, 234
%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 %43
19: ; preds = %15
%20 = load i8, i8* %6
%21 = zext i8 %20 to i64
%22 = getelementptr inbounds [1 x i8], [1 x i8]* %5, i64 0, i64 %21
%23 = load i8, i8* %22
%24 = zext i8 %23 to i32
%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 = add nsw i32 %24, %27
%29 = trunc i32 %28 to i8
%30 = getelementptr inbounds [1 x i8], [1 x i8]* %5, i64 0, i64 0
store i8 %29, i8* %30
%31 = getelementptr inbounds [1 x i8], [1 x i8]* %5, i64 0, i64 0
%32 = load i8, i8* %31
%33 = zext i8 %32 to i32
%34 = getelementptr inbounds [1 x i8], [1 x i8]* %5, i64 0, i64 0
%35 = load i8, i8* %34
%36 = zext i8 %35 to i32
%37 = add nsw i32 %36, %33
%38 = trunc i32 %37 to i8
store i8 %38, i8* %34
%39 = load i8, i8* %6
%40 = zext i8 %39 to i64
%41 = add i64 %40, 2
%42 = trunc i64 %41 to i8
store i8 %42, i8* %6
br label %15
43: ; preds = %15
%44 = getelementptr inbounds [1 x i8], [1 x i8]* %5, i64 0, i64 0
%45 = load i8, i8* %44
%46 = zext i8 %45 to i64
%47 = add i64 %46, 724560680
%48 = trunc i64 %47 to i8
%49 = load i8*, i8** %4
%50 = getelementptr inbounds i8, i8* %49, i64 0
store i8 %48, i8* %50
ret void
}

LLVM IR (-O2):
define void @RandomFunc(i8* nocapture %0, i8* nocapture writeonly %1) {
%3 = load i8, i8* %0
%4 = add i8 %3, -66
store i8 %4, i8* %1
ret void
}
/* Variables and functions */
int /*<<< orphan*/ f(int);
int /*<<< orphan*/ g(int);
int /*<<< orphan*/ h(int);
void main(int i) {
  f(1);
  g(1);
  g(1);
  h(1);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    $0x1,%edi
call   1040 <f@plt>
mov    $0x1,%edi
call   1050 <g@plt>
mov    $0x1,%edi
call   1050 <g@plt>
mov    $0x1,%edi
call   1030 <h@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
mov    $0x1,%edi
call   1040 <f@plt>
mov    $0x1,%edi
call   1050 <g@plt>
mov    $0x1,%edi
call   1050 <g@plt>
mov    $0x1,%edi
pop    %rax
jmp    1030 <h@plt>

LLVM IR (-O0):
define void @main(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = call i32 @f(i32 1)
%4 = call i32 @g(i32 1)
%5 = call i32 @g(i32 1)
%6 = call i32 @h(i32 1)
ret void
}

LLVM IR (-O2):
define void @main(i32 %0) {
%2 = tail call i32 @f(i32 1)
%3 = tail call i32 @g(i32 1)
%4 = tail call i32 @g(i32 1)
%5 = tail call i32 @h(i32 1)
ret void
}
/* Type definitions */
typedef int uint32_t;

/* Variables and functions */
int /*<<< orphan*/ ASSERT(int);
uint32_t EPIIntErrorStatus(uint32_t ui32Base) {
  ASSERT(ui32Base == 0x400D0000);
  return ((*((volatile uint32_t *)(ui32Base + 0x0000021C))));
}


x86 assembly (clang, -O0):
<EPIIntErrorStatus>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
cmpl   $0x400d0000,-0x4(%rbp)
sete   %al
and    $0x1,%al
movzbl %al,%edi
call   1030 <ASSERT@plt>
mov    -0x4(%rbp),%eax
add    $0x21c,%eax
cltq
mov    (%rax),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<EPIIntErrorStatus>:
push   %rbx
mov    %edi,%ebx
xor    %edi,%edi
cmp    $0x400d0000,%ebx
sete   %dil
call   1030 <ASSERT@plt>
movslq %ebx,%rax
mov    0x21c(%rax),%eax
pop    %rbx
ret

LLVM IR (-O0):
define i32 @EPIIntErrorStatus(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = icmp eq i32 %3, 1074593792
%5 = zext i1 %4 to i32
%6 = call i32 @ASSERT(i32 %5)
%7 = load i32, i32* %2
%8 = add nsw i32 %7, 540
%9 = sext i32 %8 to i64
%10 = inttoptr i64 %9 to i32*
%11 = load volatile i32, i32* %10
ret i32 %11
}

LLVM IR (-O2):
define i32 @EPIIntErrorStatus(i32 %0) {
%2 = icmp eq i32 %0, 1074593792
%3 = zext i1 %2 to i32
%4 = tail call i32 @ASSERT(i32 %3)
%5 = add nsw i32 %0, 540
%6 = sext i32 %5 to i64
%7 = inttoptr i64 %6 to i32*
%8 = load volatile i32, i32* %7
ret i32 %8
}
/* Variables and functions */
scalar_t__ Menu_Count();
int /*<<< orphan*/ Menus_ActivateByName(int /*<<< orphan*/);
int /*<<< orphan*/ UI_Argv(int);
int /*<<< orphan*/ trap_Key_SetCatcher(int);
void UI_Menu_f(void) {
  if (Menu_Count() > 0) {
    trap_Key_SetCatcher(0x0002);
    Menus_ActivateByName(UI_Argv(1));
  }
}


x86 assembly (clang, -O0):
<UI_Menu_f>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1060 <Menu_Count@plt>
cmp    $0x0,%rax
jle    1170 <UI_Menu_f+0x30>
mov    $0x2,%edi
call   1050 <trap_Key_SetCatcher@plt>
mov    $0x1,%edi
call   1030 <UI_Argv@plt>
mov    %eax,%edi
call   1040 <Menus_ActivateByName@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<UI_Menu_f>:
push   %rax
xor    %eax,%eax
call   1060 <Menu_Count@plt>
test   %rax,%rax
jle    1169 <UI_Menu_f+0x29>
mov    $0x2,%edi
call   1050 <trap_Key_SetCatcher@plt>
mov    $0x1,%edi
call   1030 <UI_Argv@plt>
mov    %eax,%edi
pop    %rax
jmp    1040 <Menus_ActivateByName@plt>
pop    %rax
ret

LLVM IR (-O0):
define void @UI_Menu_f() {
%1 = call i64 (...) @Menu_Count()
%2 = icmp sgt i64 %1, 0
br i1 %2, label %3, label %7
3: ; preds = %0
%4 = call i32 @trap_Key_SetCatcher(i32 2)
%5 = call i32 @UI_Argv(i32 1)
%6 = call i32 @Menus_ActivateByName(i32 %5)
br label %7
7: ; preds = %3, %0
ret void
}

LLVM IR (-O2):
define void @UI_Menu_f() {
%1 = tail call i64 (...) @Menu_Count()
%2 = icmp sgt i64 %1, 0
br i1 %2, label %3, label %7
3: ; preds = %0
%4 = tail call i32 @trap_Key_SetCatcher(i32 2)
%5 = tail call i32 @UI_Argv(i32 1)
%6 = tail call i32 @Menus_ActivateByName(i32 %5)
br label %7
7: ; preds = %3, %0
ret void
}
/* Variables and functions */
int /*<<< orphan*/ net_cleanup();
int /*<<< orphan*/ topo_cleanup();
__attribute__((visibility("default"))) int sahn_cleanup() {
  net_cleanup();
  topo_cleanup();
  return 0;
}


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

x86 assembly (clang, -O2):
<sahn_cleanup>:
push   %rax
xor    %eax,%eax
call   1040 <net_cleanup@plt>
xor    %eax,%eax
call   1030 <topo_cleanup@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @sahn_cleanup() {
%1 = call i32 (...) @net_cleanup()
%2 = call i32 (...) @topo_cleanup()
ret i32 0
}

LLVM IR (-O2):
define i32 @sahn_cleanup() {
%1 = tail call i32 (...) @net_cleanup()
%2 = tail call i32 (...) @topo_cleanup()
ret i32 0
}
/* Variables and functions */
size_t getArrayLength(void *context) { return 4; }


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

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

LLVM IR (-O0):
define i64 @getArrayLength(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
ret i64 4
}

LLVM IR (-O2):
define i64 @getArrayLength(i8* nocapture readnone %0) {
ret i64 4
}