xunge/DecIR huggingface dataset:
int long_float_ge_xxxx(long a, long b) {
  if (a < 0) {
    a = 0x8000000000000000lu - a;
  }
  if (b < 0) {
    b = 0x8000000000000000lu - b;
  }
  return a >= b;
}


x86 assembly (clang, -O0):
<long_float_ge_xxxx>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpq   $0x0,-0x8(%rbp)
jge    1129 <long_float_ge_xxxx+0x29>
movabs $0x8000000000000000,%rax
sub    -0x8(%rbp),%rax
mov    %rax,-0x8(%rbp)
cmpq   $0x0,-0x10(%rbp)
jge    1146 <long_float_ge_xxxx+0x46>
movabs $0x8000000000000000,%rax
sub    -0x10(%rbp),%rax
mov    %rax,-0x10(%rbp)
mov    -0x8(%rbp),%rax
cmp    -0x10(%rbp),%rax
setge  %al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<long_float_ge_xxxx>:
movabs $0x8000000000000000,%rcx
mov    %rcx,%rdx
sub    %rdi,%rdx
test   %rdi,%rdi
cmovns %rdi,%rdx
sub    %rsi,%rcx
test   %rsi,%rsi
cmovns %rsi,%rcx
xor    %eax,%eax
cmp    %rcx,%rdx
setge  %al
ret

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

LLVM IR (-O2):
define i32 @long_float_ge_xxxx(i64 %0, i64 %1) {
%3 = icmp slt i64 %0, 0
%4 = sub i64 -9223372036854775808, %0
%5 = select i1 %3, i64 %4, i64 %0
%6 = icmp slt i64 %1, 0
%7 = sub i64 -9223372036854775808, %1
%8 = select i1 %6, i64 %7, i64 %1
%9 = icmp sge i64 %5, %8
%10 = zext i1 %9 to i32
ret i32 %10
}
char valid_symbol(char c) {
  if (c >= '0' && c <= '9') {
    return c;
  }
  if (c >= 'a' && c <= 'z') {
    return c;
  }
  if (c >= 'A' && c <= 'Z') {
    return c;
  }
  return '_';
}


x86 assembly (clang, -O0):
<valid_symbol>:
push   %rbp
mov    %rsp,%rbp
mov    %dil,%al
mov    %al,-0x2(%rbp)
movsbl -0x2(%rbp),%eax
cmp    $0x30,%eax
jl     112f <valid_symbol+0x2f>
movsbl -0x2(%rbp),%eax
cmp    $0x39,%eax
jg     112f <valid_symbol+0x2f>
mov    -0x2(%rbp),%al
mov    %al,-0x1(%rbp)
jmp    117d <valid_symbol+0x7d>
movsbl -0x2(%rbp),%eax
cmp    $0x61,%eax
jl     1154 <valid_symbol+0x54>
movsbl -0x2(%rbp),%eax
cmp    $0x7a,%eax
jg     1154 <valid_symbol+0x54>
mov    -0x2(%rbp),%al
mov    %al,-0x1(%rbp)
jmp    117d <valid_symbol+0x7d>
movsbl -0x2(%rbp),%eax
cmp    $0x41,%eax
jl     1179 <valid_symbol+0x79>
movsbl -0x2(%rbp),%eax
cmp    $0x5a,%eax
jg     1179 <valid_symbol+0x79>
mov    -0x2(%rbp),%al
mov    %al,-0x1(%rbp)
jmp    117d <valid_symbol+0x7d>
movb   $0x5f,-0x1(%rbp)
movsbl -0x1(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<valid_symbol>:
mov    %edi,%eax
and    $0xdf,%al
add    $0xbf,%al
cmp    $0x1a,%al
mov    $0x5f,%eax
cmovb  %edi,%eax
lea    -0x30(%rdi),%ecx
cmp    $0xa,%cl
cmovb  %edi,%eax
ret

LLVM IR (-O0):
define signext i8 @valid_symbol(i8 signext %0) {
%2 = alloca i8
%3 = alloca i8
store i8 %0, i8* %3
%4 = load i8, i8* %3
%5 = sext i8 %4 to i32
%6 = icmp sge i32 %5, 48
br i1 %6, label %7, label %13
7: ; preds = %1
%8 = load i8, i8* %3
%9 = sext i8 %8 to i32
%10 = icmp sle i32 %9, 57
br i1 %10, label %11, label %13
11: ; preds = %7
%12 = load i8, i8* %3
store i8 %12, i8* %2
br label %34
13: ; preds = %7, %1
%14 = load i8, i8* %3
%15 = sext i8 %14 to i32
%16 = icmp sge i32 %15, 97
br i1 %16, label %17, label %23
17: ; preds = %13
%18 = load i8, i8* %3
%19 = sext i8 %18 to i32
%20 = icmp sle i32 %19, 122
br i1 %20, label %21, label %23
21: ; preds = %17
%22 = load i8, i8* %3
store i8 %22, i8* %2
br label %34
23: ; preds = %17, %13
%24 = load i8, i8* %3
%25 = sext i8 %24 to i32
%26 = icmp sge i32 %25, 65
br i1 %26, label %27, label %33
27: ; preds = %23
%28 = load i8, i8* %3
%29 = sext i8 %28 to i32
%30 = icmp sle i32 %29, 90
br i1 %30, label %31, label %33
31: ; preds = %27
%32 = load i8, i8* %3
store i8 %32, i8* %2
br label %34
33: ; preds = %27, %23
store i8 95, i8* %2
br label %34
34: ; preds = %33, %31, %21, %11
%35 = load i8, i8* %2
ret i8 %35
}

LLVM IR (-O2):
define signext i8 @valid_symbol(i8 signext %0) {
%2 = add i8 %0, -48
%3 = icmp ult i8 %2, 10
%4 = and i8 %0, -33
%5 = add i8 %4, -65
%6 = icmp ult i8 %5, 26
%7 = or i1 %3, %6
%8 = select i1 %7, i8 %0, i8 95
ret i8 %8
}
int test_imm_9Aint16_mem(short *val) {
  return ((*val) & (-0x9A << 0)) ? -20 : -40;
}


x86 assembly (clang, -O0):
<test_imm_9Aint16_mem>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
movswl (%rax),%edx
and    $0xffffff66,%edx
mov    $0xffffffd8,%eax
mov    $0xffffffec,%ecx
cmp    $0x0,%edx
cmovne %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_imm_9Aint16_mem>:
movzwl (%rdi),%eax
test   $0xff66,%eax
mov    $0xffffffd8,%ecx
mov    $0xffffffec,%eax
cmove  %ecx,%eax
ret

LLVM IR (-O0):
define i32 @test_imm_9Aint16_mem(i16* %0) {
%2 = alloca i16*
store i16* %0, i16** %2
%3 = load i16*, i16** %2
%4 = load i16, i16* %3
%5 = sext i16 %4 to i32
%6 = and i32 %5, -154
%7 = icmp ne i32 %6, 0
%8 = zext i1 %7 to i64
%9 = select i1 %7, i32 -20, i32 -40
ret i32 %9
}

LLVM IR (-O2):
define i32 @test_imm_9Aint16_mem(i16* nocapture %0) {
%2 = load i16, i16* %0
%3 = and i16 %2, -154
%4 = icmp eq i16 %3, 0
%5 = select i1 %4, i32 -40, i32 -20
ret i32 %5
}
/* Variables and functions */
double astro_julday_d(int, int, double);
double astro_mjd_d(int year, int month, double day) {
  return astro_julday_d(year, month, day) - 2400000.5;
}


x86 assembly (clang, -O0):
<astro_mjd_d>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
movsd  %xmm0,-0x10(%rbp)
mov    -0x4(%rbp),%edi
mov    -0x8(%rbp),%esi
movsd  -0x10(%rbp),%xmm0
call   1030 <astro_julday_d@plt>
movsd  0xec5(%rip),%xmm1
subsd  %xmm1,%xmm0
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<astro_mjd_d>:
push   %rax
call   1030 <astro_julday_d@plt>
addsd  0xee2(%rip),%xmm0
pop    %rax
ret

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

LLVM IR (-O2):
define double @astro_mjd_d(i32 %0, i32 %1, double %2) {
%4 = tail call double @astro_julday_d(i32 %0, i32 %1, double %2)
%5 = fadd double %4, 0xC1424F8040000000
ret double %5
}
/* Type definitions */
struct activity {
  int dummy;
};

/* Variables and functions */
int get_usb_nr();
int wrap_get_usb_nr(struct activity *a) {
  int n = 0;
  if ((n = get_usb_nr()) >= 0)
    return (n + 5);
  return 0;
}


x86 assembly (clang, -O0):
<wrap_get_usb_nr>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
movl   $0x0,-0x14(%rbp)
mov    $0x0,%al
call   1030 <get_usb_nr@plt>
mov    %eax,-0x14(%rbp)
cmp    $0x0,%eax
jl     1144 <wrap_get_usb_nr+0x34>
mov    -0x14(%rbp),%eax
add    $0x5,%eax
mov    %eax,-0x4(%rbp)
jmp    114b <wrap_get_usb_nr+0x3b>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<wrap_get_usb_nr>:
push   %rbx
xor    %ebx,%ebx
xor    %eax,%eax
call   1030 <get_usb_nr@plt>
lea    0x5(%rax),%ecx
test   %eax,%eax
cmovs  %ebx,%ecx
mov    %ecx,%eax
pop    %rbx
ret

LLVM IR (-O0):
%struct.activity = type { i32 }
define i32 @wrap_get_usb_nr(%struct.activity* %0) {
%2 = alloca i32
%3 = alloca %struct.activity*
%4 = alloca i32
store %struct.activity* %0, %struct.activity** %3
store i32 0, i32* %4
%5 = call i32 (...) @get_usb_nr()
store i32 %5, i32* %4
%6 = icmp sge i32 %5, 0
br i1 %6, label %7, label %10
7: ; preds = %1
%8 = load i32, i32* %4
%9 = add nsw i32 %8, 5
store i32 %9, i32* %2
br label %11
10: ; preds = %1
store i32 0, i32* %2
br label %11
11: ; preds = %10, %7
%12 = load i32, i32* %2
ret i32 %12
}

LLVM IR (-O2):
%struct.activity = type { i32 }
define i32 @wrap_get_usb_nr(%struct.activity* nocapture readnone %0) {
%2 = tail call i32 (...) @get_usb_nr()
%3 = add nsw i32 %2, 5
%4 = icmp slt i32 %2, 0
%5 = select i1 %4, i32 0, i32 %3
ret i32 %5
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ scanf(char *, int *);
int /*<<< orphan*/ ts_deter(int);
int main(void) {
  int n;
  printf("Please give the dimension of the matrix:\n");
  scanf("%d", &n);
  ts_deter(n);
  return 0;
}


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

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xecb(%rip),%rdi
call   1030 <puts@plt>
lea    0xebc(%rip),%rdi
lea    0x4(%rsp),%rsi
call   1050 <scanf@plt>
mov    0x4(%rsp),%edi
call   1040 <ts_deter@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [42 x i8] c"Please give the dimension of the matrix:\0A\00"
@.str.1 = [3 x i8] c"%d\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
store i32 0, i32* %1
%3 = call i32 @printf(i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str, i64 0, i64 0))
%4 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %2)
%5 = load i32, i32* %2
%6 = call i32 @ts_deter(i32 %5)
ret i32 0
}

LLVM IR (-O2):
@.str.1 = [3 x i8] c"%d\00"
@str = [41 x i8] c"Please give the dimension of the matrix:\00"
define i32 @main() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([41 x i8], [41 x i8]* @str, i64 0, i64 0))
%4 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %1)
%5 = load i32, i32* %1
%6 = call i32 @ts_deter(i32 %5)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ bad_guy(int *);
void bad_guy_test() {
  int *ptr = 0;
  bad_guy(ptr);
}


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

x86 assembly (clang, -O2):
<bad_guy_test>:
xor    %edi,%edi
jmp    1030 <bad_guy@plt>

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

LLVM IR (-O2):
define void @bad_guy_test() {
%1 = tail call i32 @bad_guy(i32* null)
ret void
}
/* Type definitions */
typedef int uint8_t;
typedef scalar_t__ uint64_t;

/* Variables and functions */
int /*<<< orphan*/ __wleu64(int *, scalar_t__);
int i2c_transact(int, int, int *, int, int /*<<< orphan*/);
int i2c_write_leuint64(int fd, int chip_addr, int reg, uint64_t value) {
  uint8_t data[1 + sizeof(uint64_t)];
  data[0] = reg;
  __wleu64(&data[1], (uint64_t)value);
  return i2c_transact(fd, chip_addr, data, 1 + sizeof(uint64_t), 0);
}


x86 assembly (clang, -O0):
<i2c_write_leuint64>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %rcx,-0x18(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x40(%rbp)
lea    -0x40(%rbp),%rdi
add    $0x4,%rdi
mov    -0x18(%rbp),%rsi
call   1040 <__wleu64@plt>
mov    -0x4(%rbp),%edi
mov    -0x8(%rbp),%esi
lea    -0x40(%rbp),%rdx
mov    $0x9,%ecx
xor    %r8d,%r8d
call   1030 <i2c_transact@plt>
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<i2c_write_leuint64>:
push   %rbp
push   %rbx
sub    $0x28,%rsp
mov    %esi,%ebx
mov    %edi,%ebp
mov    %edx,(%rsp)
lea    0x4(%rsp),%rdi
mov    %rcx,%rsi
call   1040 <__wleu64@plt>
mov    %rsp,%rdx
mov    %ebp,%edi
mov    %ebx,%esi
mov    $0x9,%ecx
xor    %r8d,%r8d
call   1030 <i2c_transact@plt>
add    $0x28,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
define i32 @i2c_write_leuint64(i32 %0, i32 %1, i32 %2, i64 %3) {
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i64
%9 = alloca [9 x i32]
store i32 %0, i32* %5
store i32 %1, i32* %6
store i32 %2, i32* %7
store i64 %3, i64* %8
%10 = load i32, i32* %7
%11 = getelementptr inbounds [9 x i32], [9 x i32]* %9, i64 0, i64 0
store i32 %10, i32* %11
%12 = getelementptr inbounds [9 x i32], [9 x i32]* %9, i64 0, i64 1
%13 = load i64, i64* %8
%14 = call i32 @__wleu64(i32* %12, i64 %13)
%15 = load i32, i32* %5
%16 = load i32, i32* %6
%17 = getelementptr inbounds [9 x i32], [9 x i32]* %9, i64 0, i64 0
%18 = call i32 @i2c_transact(i32 %15, i32 %16, i32* %17, i32 9, i32 0)
ret i32 %18
}

LLVM IR (-O2):
define i32 @i2c_write_leuint64(i32 %0, i32 %1, i32 %2, i64 %3) {
%5 = alloca [9 x i32]
%6 = bitcast [9 x i32]* %5 to i8*
%7 = getelementptr inbounds [9 x i32], [9 x i32]* %5, i64 0, i64 0
store i32 %2, i32* %7
%8 = getelementptr inbounds [9 x i32], [9 x i32]* %5, i64 0, i64 1
%9 = call i32 @__wleu64(i32* %8, i64 %3)
%10 = call i32 @i2c_transact(i32 %0, i32 %1, i32* %7, i32 9, i32 0)
ret i32 %10
}
/* Variables and functions */
char *strrchr(char const *, char);
char *git_find_last_dir_sep(const char *path) { return strrchr(path, '/'); }


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

x86 assembly (clang, -O2):
<git_find_last_dir_sep>:
mov    $0x2f,%esi
jmp    1030 <strrchr@plt>

LLVM IR (-O0):
define i8* @git_find_last_dir_sep(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = call i8* @strrchr(i8* %3, i8 signext 47)
ret i8* %4
}

LLVM IR (-O2):
define i8* @git_find_last_dir_sep(i8* %0) {
%2 = tail call i8* @strrchr(i8* dereferenceable(1) %0, i8 signext 47)
ret i8* %2
}
char *rvl_colour_end() { return "[97m"; }


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

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

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

LLVM IR (-O2):
@.str = [6 x i8] c"\1B[97m\00"
define i8* @rvl_colour_end() {
ret i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0)
}
/* Variables and functions */
int /*<<< orphan*/ assert_str_equal_(char *, int, char *, char *);
void test_str_equal_fail() {
  assert_str_equal_("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                    "outputs/2022-01-22/02-19-57/repos/hughbien/assertive/refs/"
                    "heads/master/test/fail_test.c",
                    22, ("lorem"), ("ipsum"));
}


x86 assembly (clang, -O0):
<test_str_equal_fail>:
push   %rbp
mov    %rsp,%rbp
lea    0xee5(%rip),%rdi
mov    $0x16,%esi
lea    0xf69(%rip),%rdx
lea    0xf68(%rip),%rcx
call   1030 <assert_str_equal_@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_str_equal_fail>:
lea    0xee9(%rip),%rdi
lea    0xf72(%rip),%rdx
lea    0xf71(%rip),%rcx
mov    $0x16,%esi
jmp    1030 <assert_str_equal_@plt>

LLVM IR (-O0):
@.str = [144 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/hughbien/assertive/refs/heads/master/test/fail_test.c\00"
@.str.1 = [6 x i8] c"lorem\00"
@.str.2 = [6 x i8] c"ipsum\00"
define void @test_str_equal_fail() {
%1 = call i32 @assert_str_equal_(i8* getelementptr inbounds ([144 x i8], [144 x i8]* @.str, i64 0, i64 0), i32 22, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [144 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/hughbien/assertive/refs/heads/master/test/fail_test.c\00"
@.str.1 = [6 x i8] c"lorem\00"
@.str.2 = [6 x i8] c"ipsum\00"
define void @test_str_equal_fail() {
%1 = tail call i32 @assert_str_equal_(i8* getelementptr inbounds ([144 x i8], [144 x i8]* @.str, i64 0, i64 0), i32 22, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.2, i64 0, i64 0))
ret void
}
__complex__ double f(__complex__ double x, __complex__ double y) {
  x += y;
  return x;
}


x86 assembly (clang, -O0):
<f>:
push   %rbp
mov    %rsp,%rbp
movsd  %xmm0,-0x20(%rbp)
movsd  %xmm1,-0x18(%rbp)
movsd  %xmm2,-0x30(%rbp)
movsd  %xmm3,-0x28(%rbp)
movsd  -0x30(%rbp),%xmm3
movsd  -0x28(%rbp),%xmm2
movsd  -0x20(%rbp),%xmm1
movsd  -0x18(%rbp),%xmm0
addsd  %xmm3,%xmm1
addsd  %xmm2,%xmm0
movsd  %xmm1,-0x20(%rbp)
movsd  %xmm0,-0x18(%rbp)
movsd  -0x20(%rbp),%xmm1
movsd  -0x18(%rbp),%xmm0
movsd  %xmm1,-0x10(%rbp)
movsd  %xmm0,-0x8(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  -0x8(%rbp),%xmm1
pop    %rbp
ret

x86 assembly (clang, -O2):
<f>:
addsd  %xmm2,%xmm0
addsd  %xmm3,%xmm1
ret

LLVM IR (-O0):
define { double, double } @f(double %0, double %1, double %2, double %3) {
%5 = alloca { double, double }
%6 = alloca { double, double }
%7 = alloca { double, double }
%8 = getelementptr inbounds { double, double }, { double, double }* %6, i32 0, i32 0
store double %0, double* %8
%9 = getelementptr inbounds { double, double }, { double, double }* %6, i32 0, i32 1
store double %1, double* %9
%10 = getelementptr inbounds { double, double }, { double, double }* %7, i32 0, i32 0
store double %2, double* %10
%11 = getelementptr inbounds { double, double }, { double, double }* %7, i32 0, i32 1
store double %3, double* %11
%12 = getelementptr inbounds { double, double }, { double, double }* %7, i32 0, i32 0
%13 = load double, double* %12
%14 = getelementptr inbounds { double, double }, { double, double }* %7, i32 0, i32 1
%15 = load double, double* %14
%16 = getelementptr inbounds { double, double }, { double, double }* %6, i32 0, i32 0
%17 = load double, double* %16
%18 = getelementptr inbounds { double, double }, { double, double }* %6, i32 0, i32 1
%19 = load double, double* %18
%20 = fadd double %17, %13
%21 = fadd double %19, %15
%22 = getelementptr inbounds { double, double }, { double, double }* %6, i32 0, i32 0
%23 = getelementptr inbounds { double, double }, { double, double }* %6, i32 0, i32 1
store double %20, double* %22
store double %21, double* %23
%24 = getelementptr inbounds { double, double }, { double, double }* %6, i32 0, i32 0
%25 = load double, double* %24
%26 = getelementptr inbounds { double, double }, { double, double }* %6, i32 0, i32 1
%27 = load double, double* %26
%28 = getelementptr inbounds { double, double }, { double, double }* %5, i32 0, i32 0
%29 = getelementptr inbounds { double, double }, { double, double }* %5, i32 0, i32 1
store double %25, double* %28
store double %27, double* %29
%30 = load { double, double }, { double, double }* %5
ret { double, double } %30
}

LLVM IR (-O2):
define { double, double } @f(double %0, double %1, double %2, double %3) {
%5 = fadd double %0, %2
%6 = fadd double %1, %3
%7 = insertvalue { double, double } poison, double %5, 0
%8 = insertvalue { double, double } %7, double %6, 1
ret { double, double } %8
}
/* Type definitions */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
scalar_t__ fprintf(int /*<<< orphan*/ *, char *, int);
int /*<<< orphan*/ perror(char *);
int /*<<< orphan*/ rewind(int /*<<< orphan*/ *);
void __set(FILE *stream, int value, char *err_msg) {
  rewind(stream);
  if (fprintf(stream, "%d", value) < 0)
    perror(err_msg);
}


x86 assembly (clang, -O0):
<__set>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <rewind@plt>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%edx
lea    0xea6(%rip),%rsi
call   1040 <fprintf@plt>
cmp    $0x0,%rax
jge    1172 <__set+0x42>
mov    -0x18(%rbp),%rdi
call   1050 <perror@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<__set>:
push   %rbp
push   %r14
push   %rbx
mov    %rdx,%r14
mov    %esi,%ebp
mov    %rdi,%rbx
call   1030 <rewind@plt>
lea    0xeb8(%rip),%rsi
mov    %rbx,%rdi
mov    %ebp,%edx
call   1040 <fprintf@plt>
test   %rax,%rax
js     115c <__set+0x2c>
pop    %rbx
pop    %r14
pop    %rbp
ret
mov    %r14,%rdi
pop    %rbx
pop    %r14
pop    %rbp
jmp    1050 <perror@plt>

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

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
define void @__set(i32* nocapture %0, i32 %1, i8* nocapture %2) {
%4 = tail call i32 @rewind(i32* %0)
%5 = tail call i64 @fprintf(i32* %0, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32 %1)
%6 = icmp slt i64 %5, 0
br i1 %6, label %7, label %9
7: ; preds = %3
%8 = tail call i32 @perror(i8* %2)
br label %9
9: ; preds = %7, %3
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, char *);
int /*<<< orphan*/ starbar();
int main(void) {
  starbar();
  printf("%s\n", "GIGATHINK, INC.");
  printf("%s\n", "101 Megabuk Plaza");
  printf("%s\n", "Megapolis, CA 94904");
  starbar();
  return 0;
}


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

x86 assembly (clang, -O2):
<main>:
push   %rbx
xor    %eax,%eax
call   1040 <starbar@plt>
lea    0xed1(%rip),%rbx
lea    0xece(%rip),%rsi
mov    %rbx,%rdi
call   1030 <printf@plt>
lea    0xecf(%rip),%rsi
mov    %rbx,%rdi
call   1030 <printf@plt>
lea    0xed2(%rip),%rsi
mov    %rbx,%rdi
call   1030 <printf@plt>
xor    %eax,%eax
call   1040 <starbar@plt>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [4 x i8] c"%s\0A\00"
@.str.1 = [16 x i8] c"GIGATHINK, INC.\00"
@.str.2 = [18 x i8] c"101 Megabuk Plaza\00"
@.str.3 = [20 x i8] c"Megapolis, CA 94904\00"
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = call i32 (...) @starbar()
%3 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.1, i64 0, i64 0))
%4 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.2, i64 0, i64 0))
%5 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.3, i64 0, i64 0))
%6 = call i32 (...) @starbar()
ret i32 0
}

LLVM IR (-O2):
@.str = [4 x i8] c"%s\0A\00"
@.str.1 = [16 x i8] c"GIGATHINK, INC.\00"
@.str.2 = [18 x i8] c"101 Megabuk Plaza\00"
@.str.3 = [20 x i8] c"Megapolis, CA 94904\00"
define i32 @main() {
%1 = tail call i32 (...) @starbar()
%2 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.1, i64 0, i64 0))
%3 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.2, i64 0, i64 0))
%4 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.3, i64 0, i64 0))
%5 = tail call i32 (...) @starbar()
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ gen(char *);
void cgshr(void) { gen("sarl\t%cl,%eax"); }


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

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

LLVM IR (-O0):
@.str = [14 x i8] c"sarl\09%cl,%eax\00"
define void @cgshr() {
%1 = call i32 @gen(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [14 x i8] c"sarl\09%cl,%eax\00"
define void @cgshr() {
%1 = tail call i32 @gen(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0))
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
int _clipboard_close(int /*<<< orphan*/ *);
int clipboard_close(FILE *s) { return _clipboard_close(s); }


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

x86 assembly (clang, -O2):
<clipboard_close>:
jmp    1030 <_clipboard_close@plt>

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

LLVM IR (-O2):
define i32 @clipboard_close(i32* %0) {
%2 = tail call i32 @_clipboard_close(i32* %0)
ret i32 %2
}
/* Variables and functions */
int /*<<< orphan*/ strncpy(char *, char *, int);
char *strrchr(char *, char);
void obd_uuid2fsname(char *buf, char *uuid, int buflen) {
  char *p;
  strncpy(buf, uuid, buflen - 1);
  buf[buflen - 1] = '\0';
  p = strrchr(buf, '-');
  if (p) {
    *p = '\0';
  }
}


x86 assembly (clang, -O0):
<obd_uuid2fsname>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
mov    -0x14(%rbp),%edx
sub    $0x1,%edx
call   1030 <strncpy@plt>
mov    -0x8(%rbp),%rax
mov    -0x14(%rbp),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
movb   $0x0,(%rax,%rcx,1)
mov    -0x8(%rbp),%rdi
mov    $0x2d,%esi
call   1040 <strrchr@plt>
mov    %rax,-0x20(%rbp)
cmpq   $0x0,-0x20(%rbp)
je     117b <obd_uuid2fsname+0x5b>
mov    -0x20(%rbp),%rax
movb   $0x0,(%rax)
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<obd_uuid2fsname>:
push   %r14
push   %rbx
push   %rax
mov    %rdi,%rbx
movslq %edx,%r14
lea    -0x1(%r14),%rdx
call   1030 <strncpy@plt>
movb   $0x0,-0x1(%rbx,%r14,1)
mov    %rbx,%rdi
mov    $0x2d,%esi
call   1040 <strrchr@plt>
test   %rax,%rax
je     114e <obd_uuid2fsname+0x2e>
movb   $0x0,(%rax)
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
define void @obd_uuid2fsname(i8* %0, i8* %1, i32 %2) {
%4 = alloca i8*
%5 = alloca i8*
%6 = alloca i32
%7 = alloca i8*
store i8* %0, i8** %4
store i8* %1, i8** %5
store i32 %2, i32* %6
%8 = load i8*, i8** %4
%9 = load i8*, i8** %5
%10 = load i32, i32* %6
%11 = sub nsw i32 %10, 1
%12 = call i32 @strncpy(i8* %8, i8* %9, i32 %11)
%13 = load i8*, i8** %4
%14 = load i32, i32* %6
%15 = sub nsw i32 %14, 1
%16 = sext i32 %15 to i64
%17 = getelementptr inbounds i8, i8* %13, i64 %16
store i8 0, i8* %17
%18 = load i8*, i8** %4
%19 = call i8* @strrchr(i8* %18, i8 signext 45)
store i8* %19, i8** %7
%20 = load i8*, i8** %7
%21 = icmp ne i8* %20, null
br i1 %21, label %22, label %24
22: ; preds = %3
%23 = load i8*, i8** %7
store i8 0, i8* %23
br label %24
24: ; preds = %22, %3
ret void
}

LLVM IR (-O2):
define void @obd_uuid2fsname(i8* %0, i8* %1, i32 %2) {
%4 = add nsw i32 %2, -1
%5 = tail call i32 @strncpy(i8* %0, i8* %1, i32 %4)
%6 = sext i32 %4 to i64
%7 = getelementptr inbounds i8, i8* %0, i64 %6
store i8 0, i8* %7
%8 = tail call i8* @strrchr(i8* dereferenceable(1) %0, i8 signext 45)
%9 = icmp eq i8* %8, null
br i1 %9, label %11, label %10
10: ; preds = %3
store i8 0, i8* %8
br label %11
11: ; preds = %10, %3
ret void
}
void _Block_object_assign(void *dst, const void *src, int flag) {}


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

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

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

LLVM IR (-O2):
define void @_Block_object_assign(i8* nocapture %0, i8* nocapture %1, i32 %2) {
ret void
}
/* Forward declarations */
typedef struct TYPE_2__ TYPE_1__;

/* Type definitions */
struct TYPE_2__ {
  int global_auto_repeat;
};
typedef TYPE_1__ XKeyboardState;

/* Variables and functions */
void set_XKeyboardState_global_auto_repeat(void *_p, int _v) {
  ((XKeyboardState *)_p)->global_auto_repeat = (int)_v;
}


x86 assembly (clang, -O0):
<set_XKeyboardState_global_auto_repeat>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0xc(%rbp),%ecx
mov    -0x8(%rbp),%rax
mov    %ecx,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<set_XKeyboardState_global_auto_repeat>:
mov    %esi,(%rdi)
ret

LLVM IR (-O0):
%struct.TYPE_2__ = type { i32 }
define void @set_XKeyboardState_global_auto_repeat(i8* %0, i32 %1) {
%3 = alloca i8*
%4 = alloca i32
store i8* %0, i8** %3
store i32 %1, i32* %4
%5 = load i32, i32* %4
%6 = load i8*, i8** %3
%7 = bitcast i8* %6 to %struct.TYPE_2__*
%8 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %7, i32 0, i32 0
store i32 %5, i32* %8
ret void
}

LLVM IR (-O2):
define void @set_XKeyboardState_global_auto_repeat(i8* nocapture writeonly %0, i32 %1) {
%3 = bitcast i8* %0 to i32*
store i32 %1, i32* %3
ret void
}
unsigned long mhs_diff_time(unsigned long now, unsigned long stamp) {
  if (stamp > now) {
    return ((0xFFFFFFFF - stamp) + now + 1);
  } else {
    return (now - stamp);
  }
}


x86 assembly (clang, -O0):
<mhs_diff_time>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    -0x18(%rbp),%rax
cmp    -0x10(%rbp),%rax
jbe    1134 <mhs_diff_time+0x34>
mov    $0xffffffff,%eax
sub    -0x18(%rbp),%rax
add    -0x10(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x8(%rbp)
jmp    1140 <mhs_diff_time+0x40>
mov    -0x10(%rbp),%rax
sub    -0x18(%rbp),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<mhs_diff_time>:
movabs $0x100000000,%rax
add    %rdi,%rax
cmp    %rsi,%rdi
cmovae %rdi,%rax
sub    %rsi,%rax
ret

LLVM IR (-O0):
define i64 @mhs_diff_time(i64 %0, i64 %1) {
%3 = alloca i64
%4 = alloca i64
%5 = alloca i64
store i64 %0, i64* %4
store i64 %1, i64* %5
%6 = load i64, i64* %5
%7 = load i64, i64* %4
%8 = icmp ugt i64 %6, %7
br i1 %8, label %9, label %15
9: ; preds = %2
%10 = load i64, i64* %5
%11 = sub i64 4294967295, %10
%12 = load i64, i64* %4
%13 = add i64 %11, %12
%14 = add i64 %13, 1
store i64 %14, i64* %3
br label %19
15: ; preds = %2
%16 = load i64, i64* %4
%17 = load i64, i64* %5
%18 = sub i64 %16, %17
store i64 %18, i64* %3
br label %19
19: ; preds = %15, %9
%20 = load i64, i64* %3
ret i64 %20
}

LLVM IR (-O2):
define i64 @mhs_diff_time(i64 %0, i64 %1) {
%3 = icmp ult i64 %0, %1
%4 = add i64 %0, 4294967296
%5 = select i1 %3, i64 %4, i64 %0
%6 = sub i64 %5, %1
ret i64 %6
}
void XSharpDrawStringXft(void *dpy, unsigned long drawable, void *gc,
                         void *fontSet, int x, int y, const char *str,
                         int style, void *clipRegion,
                         unsigned long colorValue) {}


x86 assembly (clang, -O0):
<XSharpDrawStringXft>:
push   %rbp
mov    %rsp,%rbp
mov    0x28(%rbp),%rax
mov    0x20(%rbp),%rax
mov    0x18(%rbp),%eax
mov    0x10(%rbp),%rax
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8d,-0x24(%rbp)
mov    %r9d,-0x28(%rbp)
pop    %rbp
ret

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

LLVM IR (-O0):
define void @XSharpDrawStringXft(i8* %0, i64 %1, i8* %2, i8* %3, i32 %4, i32 %5, i8* %6, i32 %7, i8* %8, i64 %9) {
%11 = alloca i8*
%12 = alloca i64
%13 = alloca i8*
%14 = alloca i8*
%15 = alloca i32
%16 = alloca i32
%17 = alloca i8*
%18 = alloca i32
%19 = alloca i8*
%20 = alloca i64
store i8* %0, i8** %11
store i64 %1, i64* %12
store i8* %2, i8** %13
store i8* %3, i8** %14
store i32 %4, i32* %15
store i32 %5, i32* %16
store i8* %6, i8** %17
store i32 %7, i32* %18
store i8* %8, i8** %19
store i64 %9, i64* %20
ret void
}

LLVM IR (-O2):
define void @XSharpDrawStringXft(i8* nocapture %0, i64 %1, i8* nocapture %2, i8* nocapture %3, i32 %4, i32 %5, i8* nocapture %6, i32 %7, i8* nocapture %8, i64 %9) {
ret void
}
double max(double x, double y) { return (x > y) ? x : y; }


x86 assembly (clang, -O0):
<max>:
push   %rbp
mov    %rsp,%rbp
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
movsd  -0x8(%rbp),%xmm0
ucomisd -0x10(%rbp),%xmm0
jbe    112d <max+0x2d>
movsd  -0x8(%rbp),%xmm0
movsd  %xmm0,-0x18(%rbp)
jmp    1137 <max+0x37>
movsd  -0x10(%rbp),%xmm0
movsd  %xmm0,-0x18(%rbp)
movsd  -0x18(%rbp),%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<max>:
maxsd  %xmm1,%xmm0
ret

LLVM IR (-O0):
define double @max(double %0, double %1) {
%3 = alloca double
%4 = alloca double
store double %0, double* %3
store double %1, double* %4
%5 = load double, double* %3
%6 = load double, double* %4
%7 = fcmp ogt double %5, %6
br i1 %7, label %8, label %10
8: ; preds = %2
%9 = load double, double* %3
br label %12
10: ; preds = %2
%11 = load double, double* %4
br label %12
12: ; preds = %10, %8
%13 = phi double [ %9, %8 ], [ %11, %10 ]
ret double %13
}

LLVM IR (-O2):
define double @max(double %0, double %1) {
%3 = fcmp ogt double %0, %1
%4 = select i1 %3, double %0, double %1
ret double %4
}
/* Variables and functions */
int /*<<< orphan*/ cov_log(long double, char *, char *);
void cov_spec_log(long double ideal, long double delta, char *fn) {
  cov_log(ideal, "ideal", fn);
  cov_log(delta, "delta", fn);
}


x86 assembly (clang, -O0):
<cov_spec_log>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
fldt   0x20(%rbp)
fldt   0x10(%rbp)
fstpt  -0x10(%rbp)
fstpt  -0x20(%rbp)
mov    %rdi,-0x28(%rbp)
fldt   -0x10(%rbp)
mov    -0x28(%rbp),%rsi
mov    %rsp,%rax
fstpt  (%rax)
lea    0xec5(%rip),%rdi
call   1030 <cov_log@plt>
fldt   -0x20(%rbp)
mov    -0x28(%rbp),%rsi
mov    %rsp,%rax
fstpt  (%rax)
lea    0xeb3(%rip),%rdi
call   1030 <cov_log@plt>
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<cov_spec_log>:
push   %rbx
sub    $0x20,%rsp
mov    %rdi,%rbx
fldt   0x40(%rsp)
fstpt  0x14(%rsp)
fldt   0x30(%rsp)
fstpt  (%rsp)
lea    0xed2(%rip),%rdi
mov    %rbx,%rsi
call   1030 <cov_log@plt>
fldt   0x14(%rsp)
fstpt  (%rsp)
lea    0xec2(%rip),%rdi
mov    %rbx,%rsi
call   1030 <cov_log@plt>
add    $0x20,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [6 x i8] c"ideal\00"
@.str.1 = [6 x i8] c"delta\00"
define void @cov_spec_log(x86_fp80 %0, x86_fp80 %1, i8* %2) {
%4 = alloca x86_fp80
%5 = alloca x86_fp80
%6 = alloca i8*
store x86_fp80 %0, x86_fp80* %4
store x86_fp80 %1, x86_fp80* %5
store i8* %2, i8** %6
%7 = load x86_fp80, x86_fp80* %4
%8 = load i8*, i8** %6
%9 = call i32 @cov_log(x86_fp80 %7, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i8* %8)
%10 = load x86_fp80, x86_fp80* %5
%11 = load i8*, i8** %6
%12 = call i32 @cov_log(x86_fp80 %10, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.1, i64 0, i64 0), i8* %11)
ret void
}

LLVM IR (-O2):
@.str = [6 x i8] c"ideal\00"
@.str.1 = [6 x i8] c"delta\00"
define void @cov_spec_log(x86_fp80 %0, x86_fp80 %1, i8* %2) {
%4 = tail call i32 @cov_log(x86_fp80 %0, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i8* %2)
%5 = tail call i32 @cov_log(x86_fp80 %1, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.1, i64 0, i64 0), i8* %2)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ ENOSYS;
int /*<<< orphan*/ __set_errno(int /*<<< orphan*/);
int munlockall(void) {
  __set_errno(ENOSYS);
  return -1;
}


x86 assembly (clang, -O0):
<munlockall>:
push   %rbp
mov    %rsp,%rbp
mov    0x2ecd(%rip),%rax
mov    (%rax),%edi
call   1030 <__set_errno@plt>
mov    $0xffffffff,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<munlockall>:
push   %rax
mov    0x2ed0(%rip),%rax
mov    (%rax),%edi
call   1030 <__set_errno@plt>
mov    $0xffffffff,%eax
pop    %rcx
ret

LLVM IR (-O0):
@ENOSYS = global i32 0
define i32 @munlockall() {
%1 = load i32, i32* @ENOSYS
%2 = call i32 @__set_errno(i32 %1)
ret i32 -1
}

LLVM IR (-O2):
@ENOSYS = global i32 0
define i32 @munlockall() {
%1 = load i32, i32* @ENOSYS
%2 = tail call i32 @__set_errno(i32 %1)
ret i32 -1
}
/* Variables and functions */
double pow(double, double);
double _rohair(double dem, double t0, double dT) {
  return (349.467 * pow((((t0 - dT) - 0.0065 * dem) / (t0 - dT)), 5.26) / t0);
}


x86 assembly (clang, -O0):
<_rohair>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
movsd  %xmm2,-0x18(%rbp)
movsd  -0x10(%rbp),%xmm1
subsd  -0x18(%rbp),%xmm1
movsd  -0x8(%rbp),%xmm0
movsd  0xed2(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  -0x10(%rbp),%xmm1
subsd  -0x18(%rbp),%xmm1
divsd  %xmm1,%xmm0
movsd  0xeac(%rip),%xmm1
call   1030 <pow@plt>
movaps %xmm0,%xmm1
movsd  0xe94(%rip),%xmm0
mulsd  %xmm1,%xmm0
divsd  -0x10(%rbp),%xmm0
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<_rohair>:
push   %rax
movsd  %xmm1,(%rsp)
movapd %xmm1,%xmm3
subsd  %xmm2,%xmm3
mulsd  0xeda(%rip),%xmm0
addsd  %xmm3,%xmm0
divsd  %xmm3,%xmm0
movsd  0xed2(%rip),%xmm1
call   1030 <pow@plt>
mulsd  0xecd(%rip),%xmm0
divsd  (%rsp),%xmm0
pop    %rax
ret

LLVM IR (-O0):
define double @_rohair(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* %6
%9 = fsub double %7, %8
%10 = load double, double* %4
%11 = call double @llvm.fmuladd.f64(double 0xBF7A9FBE76C8B439, double %10, double %9)
%12 = load double, double* %5
%13 = load double, double* %6
%14 = fsub double %12, %13
%15 = fdiv double %11, %14
%16 = call double @pow(double %15, double 5.260000e+00)
%17 = fmul double 3.494670e+02, %16
%18 = load double, double* %5
%19 = fdiv double %17, %18
ret double %19
}

LLVM IR (-O2):
define double @_rohair(double %0, double %1, double %2) {
%4 = fsub double %1, %2
%5 = tail call double @llvm.fmuladd.f64(double %0, double 0xBF7A9FBE76C8B439, double %4)
%6 = fdiv double %5, %4
%7 = tail call double @pow(double %6, double 5.260000e+00)
%8 = fmul double %7, 3.494670e+02
%9 = fdiv double %8, %1
ret double %9
}
/* Variables and functions */
int /*<<< orphan*/ cwrapper_q_sortrev_int(int *, int /*<<< orphan*/, int);
void quicksortrev_int_(int numbers[], int *array_size) {
  cwrapper_q_sortrev_int(numbers, 0, (*array_size) - 1);
}


x86 assembly (clang, -O0):
<quicksortrev_int_>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rax
mov    (%rax),%edx
sub    $0x1,%edx
xor    %esi,%esi
call   1030 <cwrapper_q_sortrev_int@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<quicksortrev_int_>:
mov    (%rsi),%edx
add    $0xffffffff,%edx
xor    %esi,%esi
jmp    1030 <cwrapper_q_sortrev_int@plt>

LLVM IR (-O0):
define void @quicksortrev_int_(i32* %0, i32* %1) {
%3 = alloca i32*
%4 = alloca i32*
store i32* %0, i32** %3
store i32* %1, i32** %4
%5 = load i32*, i32** %3
%6 = load i32*, i32** %4
%7 = load i32, i32* %6
%8 = sub nsw i32 %7, 1
%9 = call i32 @cwrapper_q_sortrev_int(i32* %5, i32 0, i32 %8)
ret void
}

LLVM IR (-O2):
define void @quicksortrev_int_(i32* %0, i32* nocapture %1) {
%3 = load i32, i32* %1
%4 = add nsw i32 %3, -1
%5 = tail call i32 @cwrapper_q_sortrev_int(i32* %0, i32 0, i32 %4)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ func();
main() {
  int i;
  for (i = 0; i < 10; ++i)
    func();
}


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

x86 assembly (clang, -O2):
<main>:
push   %rax
xor    %eax,%eax
call   1030 <func@plt>
xor    %eax,%eax
call   1030 <func@plt>
xor    %eax,%eax
call   1030 <func@plt>
xor    %eax,%eax
call   1030 <func@plt>
xor    %eax,%eax
call   1030 <func@plt>
xor    %eax,%eax
call   1030 <func@plt>
xor    %eax,%eax
call   1030 <func@plt>
xor    %eax,%eax
call   1030 <func@plt>
xor    %eax,%eax
call   1030 <func@plt>
xor    %eax,%eax
call   1030 <func@plt>
xor    %eax,%eax
pop    %rcx
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, 10
br i1 %5, label %6, label %11
6: ; preds = %3
%7 = call i32 (...) @func()
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
%12 = load i32, i32* %1
ret i32 %12
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 (...) @func()
%2 = tail call i32 (...) @func()
%3 = tail call i32 (...) @func()
%4 = tail call i32 (...) @func()
%5 = tail call i32 (...) @func()
%6 = tail call i32 (...) @func()
%7 = tail call i32 (...) @func()
%8 = tail call i32 (...) @func()
%9 = tail call i32 (...) @func()
%10 = tail call i32 (...) @func()
ret i32 0
}
/* Variables and functions */
int tsl2561_write_byte_data(void *, int, int);
int tsl2561_disable(void *_tsl) {
  return tsl2561_write_byte_data(_tsl, (0x80) | 0x00, 0x00);
}


x86 assembly (clang, -O0):
<tsl2561_disable>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
mov    $0x80,%esi
xor    %edx,%edx
call   1030 <tsl2561_write_byte_data@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<tsl2561_disable>:
mov    $0x80,%esi
xor    %edx,%edx
jmp    1030 <tsl2561_write_byte_data@plt>

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

LLVM IR (-O2):
define i32 @tsl2561_disable(i8* %0) {
%2 = tail call i32 @tsl2561_write_byte_data(i8* %0, i32 128, i32 0)
ret i32 %2
}
/* Variables and functions */
scalar_t__ strncmp(char const *, char *, int);
int is_http_url(const char *name) { return strncmp(name, "http://", 7) == 0; }


x86 assembly (clang, -O0):
<is_http_url>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
lea    0xed9(%rip),%rsi
mov    $0x7,%edx
call   1030 <strncmp@plt>
cmp    $0x0,%rax
sete   %al
and    $0x1,%al
movzbl %al,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_http_url>:
push   %rax
lea    0xee8(%rip),%rsi
mov    $0x7,%edx
call   1030 <strncmp@plt>
xor    %ecx,%ecx
test   %rax,%rax
sete   %cl
mov    %ecx,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [8 x i8] c"http://\00"
define i32 @is_http_url(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = call i64 @strncmp(i8* %3, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i32 7)
%5 = icmp eq i64 %4, 0
%6 = zext i1 %5 to i32
ret i32 %6
}

LLVM IR (-O2):
@.str = [8 x i8] c"http://\00"
define i32 @is_http_url(i8* %0) {
%2 = tail call i64 @strncmp(i8* %0, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i32 7)
%3 = icmp eq i64 %2, 0
%4 = zext i1 %3 to i32
ret i32 %4
}
/* Variables and functions */
double RAND_MAX;
scalar_t__ random();
int /*<<< orphan*/ setRandom();
void workHard(unsigned low, unsigned high) {
  double rv;
  unsigned us, j;
  high = high - low;
  rv = ((double)random()) / RAND_MAX;
  us = low + (unsigned)(rv * high);
  for (j = 0; j < us; j++) {
  };
  setRandom();
}


x86 assembly (clang, -O0):
<workHard>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x8(%rbp),%eax
mov    -0x4(%rbp),%ecx
sub    %ecx,%eax
mov    %eax,-0x8(%rbp)
xor    %eax,%eax
call   1040 <random@plt>
cvtsi2sd %rax,%xmm0
mov    0x2e9c(%rip),%rax
movsd  (%rax),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x10(%rbp)
mov    -0x4(%rbp),%eax
movsd  -0x10(%rbp),%xmm0
mov    -0x8(%rbp),%ecx
cvtsi2sd %rcx,%xmm1
mulsd  %xmm1,%xmm0
cvttsd2si %xmm0,%rcx
add    %ecx,%eax
mov    %eax,-0x14(%rbp)
movl   $0x0,-0x18(%rbp)
mov    -0x18(%rbp),%eax
cmp    -0x14(%rbp),%eax
jae    119d <workHard+0x7d>
jmp    118f <workHard+0x6f>
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
jmp    117e <workHard+0x5e>
mov    $0x0,%al
call   1030 <setRandom@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<workHard>:
push   %rax
xor    %eax,%eax
call   1040 <random@plt>
xor    %eax,%eax
pop    %rcx
jmp    1030 <setRandom@plt>

LLVM IR (-O0):
@RAND_MAX = global double 0.000000e+00
define void @workHard(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca double
%6 = alloca i32
%7 = alloca i32
store i32 %0, i32* %3
store i32 %1, i32* %4
%8 = load i32, i32* %4
%9 = load i32, i32* %3
%10 = sub i32 %8, %9
store i32 %10, i32* %4
%11 = call i64 (...) @random()
%12 = sitofp i64 %11 to double
%13 = load double, double* @RAND_MAX
%14 = fdiv double %12, %13
store double %14, double* %5
%15 = load i32, i32* %3
%16 = load double, double* %5
%17 = load i32, i32* %4
%18 = uitofp i32 %17 to double
%19 = fmul double %16, %18
%20 = fptoui double %19 to i32
%21 = add i32 %15, %20
store i32 %21, i32* %6
store i32 0, i32* %7
br label %22
22: ; preds = %27, %2
%23 = load i32, i32* %7
%24 = load i32, i32* %6
%25 = icmp ult i32 %23, %24
br i1 %25, label %26, label %30
26: ; preds = %22
br label %27
27: ; preds = %26
%28 = load i32, i32* %7
%29 = add i32 %28, 1
store i32 %29, i32* %7
br label %22
30: ; preds = %22
%31 = call i32 (...) @setRandom()
ret void
}

LLVM IR (-O2):
@RAND_MAX = global double 0.000000e+00
define void @workHard(i32 %0, i32 %1) {
%3 = tail call i64 (...) @random()
%4 = tail call i32 (...) @setRandom()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
int pa_context_unload_module() {
  printf("NOT IMPLEMENTED:"
         "pa_context_unload_module"
         "\n");
}


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

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

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

LLVM IR (-O2):
@str = [41 x i8] c"NOT IMPLEMENTED:pa_context_unload_module\00"
define i32 @pa_context_unload_module() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([41 x i8], [41 x i8]* @str, i64 0, i64 0))
ret i32 undef
}
char *SafeStr(const void *ss) { return ss ? (char *)ss : (char *)""; }


x86 assembly (clang, -O0):
<SafeStr>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
cmpq   $0x0,-0x8(%rbp)
je     1120 <SafeStr+0x20>
mov    -0x8(%rbp),%rax
mov    %rax,-0x10(%rbp)
jmp    1130 <SafeStr+0x30>
lea    0xed9(%rip),%rax
mov    %rax,-0x10(%rbp)
jmp    1130 <SafeStr+0x30>
mov    -0x10(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<SafeStr>:
test   %rdi,%rdi
lea    0xef6(%rip),%rax
cmovne %rdi,%rax
ret

LLVM IR (-O0):
@.str = [1 x i8] zeroinitializer
define i8* @SafeStr(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = icmp ne i8* %3, null
br i1 %4, label %5, label %7
5: ; preds = %1
%6 = load i8*, i8** %2
br label %8
7: ; preds = %1
br label %8
8: ; preds = %7, %5
%9 = phi i8* [ %6, %5 ], [ getelementptr inbounds ([1 x i8], [1 x i8]* @.str, i64 0, i64 0), %7 ]
ret i8* %9
}

LLVM IR (-O2):
@.str = [1 x i8] zeroinitializer
define i8* @SafeStr(i8* readnone %0) {
%2 = icmp eq i8* %0, null
%3 = select i1 %2, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str, i64 0, i64 0), i8* %0
ret i8* %3
}