xunge/DecIR huggingface dataset:
int rtc_add_group(struct rtc_device *rtc, const struct attribute_group *grp) {
  return 0;
}


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

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

LLVM IR (-O0):
%struct.rtc_device = type opaque
%struct.attribute_group = type opaque
define i32 @rtc_add_group(%struct.rtc_device* %0, %struct.attribute_group* %1) {
%3 = alloca %struct.rtc_device*
%4 = alloca %struct.attribute_group*
store %struct.rtc_device* %0, %struct.rtc_device** %3
store %struct.attribute_group* %1, %struct.attribute_group** %4
ret i32 0
}

LLVM IR (-O2):
%struct.rtc_device = type opaque
%struct.attribute_group = type opaque
define i32 @rtc_add_group(%struct.rtc_device* nocapture readnone %0, %struct.attribute_group* nocapture readnone %1) {
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ WriteToSMBus(int, int, int, int);
void I2CRebootSlow(void) {
  WriteToSMBus(0x10, 0x02, 1, 0x40);
  while (1)
    ;
}


x86 assembly (clang, -O0):
<I2CRebootSlow>:
push   %rbp
mov    %rsp,%rbp
mov    $0x10,%edi
mov    $0x2,%esi
mov    $0x1,%edx
mov    $0x40,%ecx
call   1030 <WriteToSMBus@plt>
jmp    112d <I2CRebootSlow+0x1d>

x86 assembly (clang, -O2):
<I2CRebootSlow>:
push   %rax
mov    $0x10,%edi
mov    $0x2,%esi
mov    $0x1,%edx
mov    $0x40,%ecx
call   1030 <WriteToSMBus@plt>
nopw   0x0(%rax,%rax,1)
jmp    1130 <I2CRebootSlow+0x20>

LLVM IR (-O0):
define void @I2CRebootSlow() {
%1 = call i32 @WriteToSMBus(i32 16, i32 2, i32 1, i32 64)
br label %2
2: ; preds = %0, %2
br label %2
}

LLVM IR (-O2):
define void @I2CRebootSlow() {
%1 = tail call i32 @WriteToSMBus(i32 16, i32 2, i32 1, i32 64)
br label %2
2: ; preds = %0, %2
br label %2
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int, int);
void my_print(int *a, int size) {
  int i;
  for (i = 1; i <= size; ++i) {
    printf("%3d:%6d\n", i, a[i]);
  }
}


x86 assembly (clang, -O0):
<my_print>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
movl   $0x1,-0x10(%rbp)
mov    -0x10(%rbp),%eax
cmp    -0xc(%rbp),%eax
jg     115a <my_print+0x4a>
mov    -0x10(%rbp),%esi
mov    -0x8(%rbp),%rax
movslq -0x10(%rbp),%rcx
mov    (%rax,%rcx,4),%edx
lea    0xeb9(%rip),%rdi
call   1030 <printf@plt>
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
jmp    1126 <my_print+0x16>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<my_print>:
push   %r15
push   %r14
push   %r12
push   %rbx
push   %rax
test   %esi,%esi
jle    1157 <my_print+0x47>
mov    %esi,%r15d
mov    %rdi,%r14
add    $0x1,%r15d
mov    $0x1,%ebx
lea    0xece(%rip),%r12
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
mov    (%r14,%rbx,4),%edx
mov    %r12,%rdi
mov    %ebx,%esi
call   1030 <printf@plt>
add    $0x1,%rbx
cmp    %rbx,%r15
jne    1140 <my_print+0x30>
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@.str = [9 x i8] c"%3d:%6d\0A\00"
define void @my_print(i32* %0, i32 %1) {
%3 = alloca i32*
%4 = alloca i32
%5 = alloca i32
store i32* %0, i32** %3
store i32 %1, i32* %4
store i32 1, i32* %5
br label %6
6: ; preds = %18, %2
%7 = load i32, i32* %5
%8 = load i32, i32* %4
%9 = icmp sle i32 %7, %8
br i1 %9, label %10, label %21
10: ; preds = %6
%11 = load i32, i32* %5
%12 = load i32*, i32** %3
%13 = load i32, i32* %5
%14 = sext i32 %13 to i64
%15 = getelementptr inbounds i32, i32* %12, i64 %14
%16 = load i32, i32* %15
%17 = call i32 @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i32 %11, i32 %16)
br label %18
18: ; preds = %10
%19 = load i32, i32* %5
%20 = add nsw i32 %19, 1
store i32 %20, i32* %5
br label %6
21: ; preds = %6
ret void
}

LLVM IR (-O2):
@.str = [9 x i8] c"%3d:%6d\0A\00"
define void @my_print(i32* nocapture %0, i32 %1) {
%3 = icmp slt i32 %1, 1
br i1 %3, label %15, label %4
4: ; preds = %2
%5 = add nuw i32 %1, 1
%6 = zext i32 %5 to i64
br label %7
7: ; preds = %4, %7
%8 = phi i64 [ 1, %4 ], [ %13, %7 ]
%9 = getelementptr inbounds i32, i32* %0, i64 %8
%10 = load i32, i32* %9
%11 = trunc i64 %8 to i32
%12 = tail call i32 @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i32 %11, i32 %10)
%13 = add nuw nsw i64 %8, 1
%14 = icmp eq i64 %13, %6
br i1 %14, label %15, label %7
15: ; preds = %7, %2
ret void
}
int PR19074_positive(int x) {
  switch (x) {
  case 0:
    return 0;
  default:
    break;
  }
}


x86 assembly (clang, -O0):
<PR19074_positive>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x8(%rbp)
mov    -0x8(%rbp),%eax
test   %eax,%eax
jne    1123 <PR19074_positive+0x23>
jmp    1117 <PR19074_positive+0x17>
movl   $0x0,-0x4(%rbp)
jmp    1128 <PR19074_positive+0x28>
jmp    1128 <PR19074_positive+0x28>
mov    -0x4(%rbp),%eax
pop    %rbp
ret

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

LLVM IR (-O0):
define i32 @PR19074_positive(i32 %0) {
%2 = alloca i32
%3 = alloca i32
store i32 %0, i32* %3
%4 = load i32, i32* %3
switch i32 %4, label %6 [
i32 0, label %5
]
5: ; preds = %1
store i32 0, i32* %2
br label %7
6: ; preds = %1
br label %7
7: ; preds = %5, %6
%8 = load i32, i32* %2
ret i32 %8
}

LLVM IR (-O2):
define i32 @PR19074_positive(i32 %0) {
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
int main(void) {
  printf("\n\tCrypto\n");
  return 0;
}


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

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

LLVM IR (-O0):
@.str = [10 x i8] c"\0A\09Crypto\0A\00"
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@str = [9 x i8] c"\0A\09Crypto\00"
define i32 @main() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @str, i64 0, i64 0))
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ numFingers(int);
int /*<<< orphan*/ pickColour();
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ quitTime();
int main() {
  do {
    numFingers(3);
    printf("\n");
    pickColour();
    printf("\n");
  } while (!quitTime());
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0x3,%edi
call   1060 <numFingers@plt>
lea    0xea0(%rip),%rdi
call   1050 <printf@plt>
mov    $0x0,%al
call   1030 <pickColour@plt>
lea    0xe8d(%rip),%rdi
call   1050 <printf@plt>
mov    $0x0,%al
call   1040 <quitTime@plt>
cmp    $0x0,%eax
setne  %al
xor    $0xff,%al
test   $0x1,%al
jne    114f <main+0xf>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
mov    $0x3,%edi
call   1060 <numFingers@plt>
mov    $0xa,%edi
call   1040 <putchar@plt>
xor    %eax,%eax
call   1030 <pickColour@plt>
mov    $0xa,%edi
call   1040 <putchar@plt>
xor    %eax,%eax
call   1050 <quitTime@plt>
test   %eax,%eax
je     1150 <main+0x10>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [2 x i8] c"\0A\00"
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
br label %2
2: ; preds = %7, %0
%3 = call i32 @numFingers(i32 3)
%4 = call i32 @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%5 = call i32 (...) @pickColour()
%6 = call i32 @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
br label %7
7: ; preds = %2
%8 = call i32 (...) @quitTime()
%9 = icmp ne i32 %8, 0
%10 = xor i1 %9, true
br i1 %10, label %2, label %11
11: ; preds = %7
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
br label %1
1: ; preds = %1, %0
%2 = tail call i32 @numFingers(i32 3)
%3 = tail call i32 @putchar(i32 10)
%4 = tail call i32 (...) @pickColour()
%5 = tail call i32 @putchar(i32 10)
%6 = tail call i32 (...) @quitTime()
%7 = icmp eq i32 %6, 0
br i1 %7, label %1, label %8
8: ; preds = %1
ret i32 0
}
/* Type definitions */
typedef int /*<<< orphan*/ uint32_t;

/* Variables and functions */
void PortF_Output(uint32_t data) {
  (*((volatile uint32_t *)0x400253FC)) = data;
}


x86 assembly (clang, -O0):
<PortF_Output>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%ecx
mov    $0x400253fc,%eax
mov    %ecx,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<PortF_Output>:
mov    %edi,0x400253fc
ret

LLVM IR (-O0):
define void @PortF_Output(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
store volatile i32 %3, i32* inttoptr (i64 1073894396 to i32*)
ret void
}

LLVM IR (-O2):
define void @PortF_Output(i32 %0) {
store volatile i32 %0, i32* inttoptr (i64 1073894396 to i32*)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
void wakeup(int signum) { printf("alarm received from kernel\n"); }


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

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

LLVM IR (-O0):
@.str = [28 x i8] c"alarm received from kernel\0A\00"
define void @wakeup(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = call i32 @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@str = [27 x i8] c"alarm received from kernel\00"
define void @wakeup(i32 %0) {
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([27 x i8], [27 x i8]* @str, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ free(void *);
void free_cvector(char *v, int nl, int nh) { free((void *)(v + nl)); }


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

x86 assembly (clang, -O2):
<free_cvector>:
movslq %esi,%rax
add    %rax,%rdi
jmp    1030 <free@plt>

LLVM IR (-O0):
define void @free_cvector(i8* %0, i32 %1, i32 %2) {
%4 = alloca i8*
%5 = alloca i32
%6 = alloca i32
store i8* %0, i8** %4
store i32 %1, i32* %5
store i32 %2, i32* %6
%7 = load i8*, i8** %4
%8 = load i32, i32* %5
%9 = sext i32 %8 to i64
%10 = getelementptr inbounds i8, i8* %7, i64 %9
%11 = call i32 @free(i8* %10)
ret void
}

LLVM IR (-O2):
define void @free_cvector(i8* nocapture %0, i32 %1, i32 %2) {
%4 = sext i32 %1 to i64
%5 = getelementptr inbounds i8, i8* %0, i64 %4
%6 = tail call i32 @free(i8* %5)
ret void
}
/* Forward declarations */
typedef struct TYPE_2__ TYPE_1__;

/* Type definitions */
struct TYPE_2__ {
  int mwidth;
};
typedef TYPE_1__ Screen;

/* Variables and functions */
void set_Screen_mwidth(void *_p, int _v) { ((Screen *)_p)->mwidth = (int)_v; }


x86 assembly (clang, -O0):
<set_Screen_mwidth>:
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_Screen_mwidth>:
mov    %esi,(%rdi)
ret

LLVM IR (-O0):
%struct.TYPE_2__ = type { i32 }
define void @set_Screen_mwidth(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_Screen_mwidth(i8* nocapture writeonly %0, i32 %1) {
%3 = bitcast i8* %0 to i32*
store i32 %1, i32* %3
ret void
}
/* Variables and functions */
scalar_t__ COND_LE();
int /*<<< orphan*/ EA_AY_AI_8();
int /*<<< orphan*/ m68ki_write_8(int /*<<< orphan*/, int);
void m68k_op_sle_8_ai(void) {
  m68ki_write_8(EA_AY_AI_8(), COND_LE() ? 0xff : 0);
}


x86 assembly (clang, -O0):
<m68k_op_sle_8_ai>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x0,%al
call   1030 <EA_AY_AI_8@plt>
mov    %eax,-0x4(%rbp)
mov    $0x0,%al
call   1040 <COND_LE@plt>
mov    -0x4(%rbp),%edi
mov    %rax,%rcx
xor    %esi,%esi
mov    $0xff,%eax
cmp    $0x0,%rcx
cmovne %eax,%esi
call   1050 <m68ki_write_8@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<m68k_op_sle_8_ai>:
push   %rbp
push   %rbx
push   %rax
xor    %ebp,%ebp
xor    %eax,%eax
call   1030 <EA_AY_AI_8@plt>
mov    %eax,%ebx
xor    %eax,%eax
call   1040 <COND_LE@plt>
test   %rax,%rax
mov    $0xff,%esi
cmove  %ebp,%esi
mov    %ebx,%edi
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1050 <m68ki_write_8@plt>

LLVM IR (-O0):
define void @m68k_op_sle_8_ai() {
%1 = call i32 (...) @EA_AY_AI_8()
%2 = call i64 (...) @COND_LE()
%3 = icmp ne i64 %2, 0
%4 = zext i1 %3 to i64
%5 = select i1 %3, i32 255, i32 0
%6 = call i32 @m68ki_write_8(i32 %1, i32 %5)
ret void
}

LLVM IR (-O2):
define void @m68k_op_sle_8_ai() {
%1 = tail call i32 (...) @EA_AY_AI_8()
%2 = tail call i64 (...) @COND_LE()
%3 = icmp eq i64 %2, 0
%4 = select i1 %3, i32 0, i32 255
%5 = tail call i32 @m68ki_write_8(i32 %1, i32 %4)
ret void
}
/* Type definitions */
typedef int int16_t;

/* Variables and functions */
int readRegister(int, int);
int16_t readX(int file) {
  int16_t result = 0;
  result = readRegister(file, (0x32)) | (readRegister(file, (0x32) + 1) << 8);
  return result;
}


x86 assembly (clang, -O0):
<readX>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
mov    -0x4(%rbp),%edi
mov    $0x32,%esi
call   1030 <readRegister@plt>
mov    %eax,-0xc(%rbp)
mov    -0x4(%rbp),%edi
mov    $0x33,%esi
call   1030 <readRegister@plt>
mov    %eax,%ecx
mov    -0xc(%rbp),%eax
shl    $0x8,%ecx
or     %ecx,%eax
mov    %eax,-0x8(%rbp)
mov    -0x8(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<readX>:
push   %rbp
push   %rbx
push   %rax
mov    %edi,%ebx
mov    $0x32,%esi
call   1030 <readRegister@plt>
mov    %eax,%ebp
mov    %ebx,%edi
mov    $0x33,%esi
call   1030 <readRegister@plt>
shl    $0x8,%eax
or     %ebp,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
define i32 @readX(i32 %0) {
%2 = alloca i32
%3 = alloca i32
store i32 %0, i32* %2
store i32 0, i32* %3
%4 = load i32, i32* %2
%5 = call i32 @readRegister(i32 %4, i32 50)
%6 = load i32, i32* %2
%7 = call i32 @readRegister(i32 %6, i32 51)
%8 = shl i32 %7, 8
%9 = or i32 %5, %8
store i32 %9, i32* %3
%10 = load i32, i32* %3
ret i32 %10
}

LLVM IR (-O2):
define i32 @readX(i32 %0) {
%2 = tail call i32 @readRegister(i32 %0, i32 50)
%3 = tail call i32 @readRegister(i32 %0, i32 51)
%4 = shl i32 %3, 8
%5 = or i32 %4, %2
ret i32 %5
}
/* Type definitions */
typedef int /*<<< orphan*/ time_t;
struct tm {
  int dummy;
};

/* Variables and functions */
struct tm *gmtime(int /*<<< orphan*/ *);
int /*<<< orphan*/ strftime(char *, int, char *, struct tm *);
int /*<<< orphan*/ time(int /*<<< orphan*/ *);
void make_date(char d[], int buf_size) {
  time_t timep;
  struct tm *time_inf;
  timep = time(NULL);
  time_inf = gmtime(&timep);
  strftime(d, buf_size, "%a, %b %d %H:%M:%S %G", time_inf);
}


x86 assembly (clang, -O0):
<make_date>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
xor    %eax,%eax
mov    %eax,%edi
call   1030 <time@plt>
mov    %eax,-0x10(%rbp)
lea    -0x10(%rbp),%rdi
call   1050 <gmtime@plt>
mov    %rax,-0x18(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
mov    -0x18(%rbp),%rcx
lea    0xe96(%rip),%rdx
call   1040 <strftime@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<make_date>:
push   %rbp
push   %rbx
push   %rax
mov    %esi,%ebp
mov    %rdi,%rbx
xor    %edi,%edi
call   1030 <time@plt>
mov    %eax,0x4(%rsp)
lea    0x4(%rsp),%rdi
call   1050 <gmtime@plt>
lea    0xeac(%rip),%rdx
mov    %rbx,%rdi
mov    %ebp,%esi
mov    %rax,%rcx
call   1040 <strftime@plt>
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
%struct.tm = type { i32 }
@.str = [22 x i8] c"%a, %b %d %H:%M:%S %G\00"
define void @make_date(i8* %0, i32 %1) {
%3 = alloca i8*
%4 = alloca i32
%5 = alloca i32
%6 = alloca %struct.tm*
store i8* %0, i8** %3
store i32 %1, i32* %4
%7 = call i32 @time(i32* null)
store i32 %7, i32* %5
%8 = call %struct.tm* @gmtime(i32* %5)
store %struct.tm* %8, %struct.tm** %6
%9 = load i8*, i8** %3
%10 = load i32, i32* %4
%11 = load %struct.tm*, %struct.tm** %6
%12 = call i32 @strftime(i8* %9, i32 %10, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), %struct.tm* %11)
ret void
}

LLVM IR (-O2):
%struct.tm = type { i32 }
@.str = [22 x i8] c"%a, %b %d %H:%M:%S %G\00"
define void @make_date(i8* %0, i32 %1) {
%3 = alloca i32
%4 = bitcast i32* %3 to i8*
%5 = tail call i32 @time(i32* null)
store i32 %5, i32* %3
%6 = call %struct.tm* @gmtime(i32* %3)
%7 = call i32 @strftime(i8* %0, i32 %1, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), %struct.tm* %6)
ret void
}
int counter_team(int tid) {
  if (tid == 0)
    return 0;
  else if (tid == 1)
    return 2;
  else if (tid == 2)
    return 1;
  return -1;
}


x86 assembly (clang, -O0):
<counter_team>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x8(%rbp)
cmpl   $0x0,-0x8(%rbp)
jne    111d <counter_team+0x1d>
movl   $0x0,-0x4(%rbp)
jmp    115a <counter_team+0x5a>
cmpl   $0x1,-0x8(%rbp)
jne    1133 <counter_team+0x33>
movl   $0x2,-0x4(%rbp)
jmp    115a <counter_team+0x5a>
cmpl   $0x2,-0x8(%rbp)
jne    1149 <counter_team+0x49>
movl   $0x1,-0x4(%rbp)
jmp    115a <counter_team+0x5a>
jmp    114e <counter_team+0x4e>
jmp    1153 <counter_team+0x53>
movl   $0xffffffff,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<counter_team>:
mov    $0xffffffff,%eax
cmp    $0x2,%edi
ja     1117 <counter_team+0x17>
movslq %edi,%rax
lea    0xeec(%rip),%rcx
mov    (%rcx,%rax,4),%eax
ret

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

LLVM IR (-O2):
@switch.table.counter_team = [3 x i32] [i32 0, i32 2, i32 1]
define i32 @counter_team(i32 %0) {
%2 = icmp ult i32 %0, 3
br i1 %2, label %3, label %7
3: ; preds = %1
%4 = sext i32 %0 to i64
%5 = getelementptr inbounds [3 x i32], [3 x i32]* @switch.table.counter_team, i64 0, i64 %4
%6 = load i32, i32* %5
br label %7
7: ; preds = %1, %3
%8 = phi i32 [ %6, %3 ], [ -1, %1 ]
ret i32 %8
}
/* Variables and functions */
double exp(double);
int log(int);
double blastzScoreToWuExpectation(int bzScore, double databaseSize) {
  double logProbOne = -log(2) * bzScore / 32.1948;
  return databaseSize * exp(logProbOne);
}


x86 assembly (clang, -O0):
<blastzScoreToWuExpectation>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
movsd  %xmm0,-0x10(%rbp)
mov    $0x2,%edi
call   1040 <log@plt>
mov    %eax,%ecx
xor    %eax,%eax
sub    %ecx,%eax
imul   -0x4(%rbp),%eax
cvtsi2sd %eax,%xmm0
movsd  0xeb0(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x18(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  %xmm0,-0x20(%rbp)
movsd  -0x18(%rbp),%xmm0
call   1030 <exp@plt>
movaps %xmm0,%xmm1
movsd  -0x20(%rbp),%xmm0
mulsd  %xmm1,%xmm0
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<blastzScoreToWuExpectation>:
push   %rbx
sub    $0x10,%rsp
movsd  %xmm0,0x8(%rsp)
mov    %edi,%ebx
mov    $0x2,%edi
call   1040 <log@plt>
imul   %ebx,%eax
neg    %eax
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
divsd  0xeb5(%rip),%xmm0
call   1030 <exp@plt>
mulsd  0x8(%rsp),%xmm0
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
define double @blastzScoreToWuExpectation(i32 %0, double %1) {
%3 = alloca i32
%4 = alloca double
%5 = alloca double
store i32 %0, i32* %3
store double %1, double* %4
%6 = call i32 @log(i32 2)
%7 = sub nsw i32 0, %6
%8 = load i32, i32* %3
%9 = mul nsw i32 %7, %8
%10 = sitofp i32 %9 to double
%11 = fdiv double %10, 3.219480e+01
store double %11, double* %5
%12 = load double, double* %4
%13 = load double, double* %5
%14 = call double @exp(double %13)
%15 = fmul double %12, %14
ret double %15
}

LLVM IR (-O2):
define double @blastzScoreToWuExpectation(i32 %0, double %1) {
%3 = tail call i32 @log(i32 2)
%4 = mul i32 %3, %0
%5 = sub i32 0, %4
%6 = sitofp i32 %5 to double
%7 = fdiv double %6, 3.219480e+01
%8 = tail call double @exp(double %7)
%9 = fmul double %8, %1
ret double %9
}
void ff_hevc_put_hevc_bi_qpel_hv24_10_sse4() {}


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

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

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

LLVM IR (-O2):
define void @ff_hevc_put_hevc_bi_qpel_hv24_10_sse4() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ pthread_exit(void *);
void emb_exit_thread(void) {
  int retval = 0;
  pthread_exit((void *)&retval);
}


x86 assembly (clang, -O0):
<emb_exit_thread>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    -0x4(%rbp),%rdi
call   1030 <pthread_exit@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<emb_exit_thread>:
push   %rax
movl   $0x0,0x4(%rsp)
lea    0x4(%rsp),%rdi
call   1030 <pthread_exit@plt>
pop    %rax
ret

LLVM IR (-O0):
define void @emb_exit_thread() {
%1 = alloca i32
store i32 0, i32* %1
%2 = bitcast i32* %1 to i8*
%3 = call i32 @pthread_exit(i8* %2)
ret void
}

LLVM IR (-O2):
define void @emb_exit_thread() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
store i32 0, i32* %1
%3 = call i32 @pthread_exit(i8* %2)
ret void
}
/* Type definitions */
struct userlist {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ msgreply(struct userlist *, char const *, char *);
int msg_utf8(const char *replyto, struct userlist *user,
             const char *CANTUSE_data __attribute__((unused))) {
  msgreply(user, replyto,
           "Per cambiare provvisoriamente il tuo charset in utf-8 digita "
           "/charset utf-8 oppure fai mela+S, seleziona il server (Azzurra), "
           "fai Show Details e seleziona il charset manualmente per cambiarlo "
           "definitivamente.");
  return (0);
}


x86 assembly (clang, -O0):
<msg_utf8>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x10(%rbp),%rdi
mov    -0x8(%rbp),%rsi
lea    0xecd(%rip),%rdx
call   1030 <msgreply@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<msg_utf8>:
push   %rax
mov    %rdi,%rax
lea    0xee5(%rip),%rdx
mov    %rsi,%rdi
mov    %rax,%rsi
call   1030 <msgreply@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
%struct.userlist = type { i32 }
@.str = [209 x i8] c"Per cambiare provvisoriamente il tuo charset in utf-8 digita /charset utf-8 oppure fai mela+S, seleziona il server (Azzurra), fai Show Details e seleziona il charset manualmente per cambiarlo definitivamente.\00"
define i32 @msg_utf8(i8* %0, %struct.userlist* %1, i8* %2) {
%4 = alloca i8*
%5 = alloca %struct.userlist*
%6 = alloca i8*
store i8* %0, i8** %4
store %struct.userlist* %1, %struct.userlist** %5
store i8* %2, i8** %6
%7 = load %struct.userlist*, %struct.userlist** %5
%8 = load i8*, i8** %4
%9 = call i32 @msgreply(%struct.userlist* %7, i8* %8, i8* getelementptr inbounds ([209 x i8], [209 x i8]* @.str, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
%struct.userlist = type { i32 }
@.str = [209 x i8] c"Per cambiare provvisoriamente il tuo charset in utf-8 digita /charset utf-8 oppure fai mela+S, seleziona il server (Azzurra), fai Show Details e seleziona il charset manualmente per cambiarlo definitivamente.\00"
define i32 @msg_utf8(i8* %0, %struct.userlist* %1, i8* nocapture readnone %2) {
%4 = tail call i32 @msgreply(%struct.userlist* %1, i8* %0, i8* getelementptr inbounds ([209 x i8], [209 x i8]* @.str, i64 0, i64 0))
ret i32 0
}
/* Type definitions */
struct cli_def {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ cli_error(struct cli_def *, char *);
void request_abort_cb(struct cli_def *cli) { cli_error(cli, "\nCancelled."); }


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

x86 assembly (clang, -O2):
<request_abort_cb>:
lea    0xee9(%rip),%rsi
jmp    1030 <cli_error@plt>

LLVM IR (-O0):
%struct.cli_def = type { i32 }
@.str = [12 x i8] c"\0ACancelled.\00"
define void @request_abort_cb(%struct.cli_def* %0) {
%2 = alloca %struct.cli_def*
store %struct.cli_def* %0, %struct.cli_def** %2
%3 = load %struct.cli_def*, %struct.cli_def** %2
%4 = call i32 @cli_error(%struct.cli_def* %3, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
%struct.cli_def = type { i32 }
@.str = [12 x i8] c"\0ACancelled.\00"
define void @request_abort_cb(%struct.cli_def* %0) {
%2 = tail call i32 @cli_error(%struct.cli_def* %0, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0))
ret void
}
/* Variables and functions */
void *malloc(size_t);
int /*<<< orphan*/ mem_assert(void *);
void *malloc_assert(size_t size) {
  void *mem = malloc(size);
  mem_assert(mem);
  return mem;
}


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

x86 assembly (clang, -O2):
<malloc_assert>:
push   %rbx
call   1030 <malloc@plt>
mov    %rax,%rbx
mov    %rax,%rdi
call   1040 <mem_assert@plt>
mov    %rbx,%rax
pop    %rbx
ret

LLVM IR (-O0):
define i8* @malloc_assert(i64 %0) {
%2 = alloca i64
%3 = alloca i8*
store i64 %0, i64* %2
%4 = load i64, i64* %2
%5 = call i8* @malloc(i64 %4)
store i8* %5, i8** %3
%6 = load i8*, i8** %3
%7 = call i32 @mem_assert(i8* %6)
%8 = load i8*, i8** %3
ret i8* %8
}

LLVM IR (-O2):
define i8* @malloc_assert(i64 %0) {
%2 = tail call i8* @malloc(i64 %0)
%3 = tail call i32 @mem_assert(i8* %2)
ret i8* %2
}
/* Variables and functions */
int tag_hash(const char *name) {
  uintptr_t l = (uintptr_t)name;
  int res = 0;
  while (l) {
    res ^= l;
    l >>= 12;
  }
  return res & 4095;
}


x86 assembly (clang, -O0):
<tag_hash>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x10(%rbp)
movl   $0x0,-0x14(%rbp)
cmpq   $0x0,-0x10(%rbp)
je     1141 <tag_hash+0x41>
mov    -0x10(%rbp),%rcx
movslq -0x14(%rbp),%rax
xor    %rcx,%rax
mov    %eax,-0x14(%rbp)
mov    -0x10(%rbp),%rax
shr    $0xc,%rax
mov    %rax,-0x10(%rbp)
jmp    1117 <tag_hash+0x17>
mov    -0x14(%rbp),%eax
and    $0xfff,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<tag_hash>:
xor    %eax,%eax
test   %rdi,%rdi
je     1127 <tag_hash+0x27>
mov    %rdi,%rcx
nopw   0x0(%rax,%rax,1)
xor    %edi,%eax
shr    $0xc,%rcx
cmp    $0xfff,%rdi
mov    %rcx,%rdi
ja     1110 <tag_hash+0x10>
and    $0xfff,%eax
ret

LLVM IR (-O0):
define i32 @tag_hash(i8* %0) {
%2 = alloca i8*
%3 = alloca i64
%4 = alloca i32
store i8* %0, i8** %2
%5 = load i8*, i8** %2
%6 = ptrtoint i8* %5 to i64
store i64 %6, i64* %3
store i32 0, i32* %4
br label %7
7: ; preds = %10, %1
%8 = load i64, i64* %3
%9 = icmp ne i64 %8, 0
br i1 %9, label %10, label %18
10: ; preds = %7
%11 = load i64, i64* %3
%12 = load i32, i32* %4
%13 = sext i32 %12 to i64
%14 = xor i64 %13, %11
%15 = trunc i64 %14 to i32
store i32 %15, i32* %4
%16 = load i64, i64* %3
%17 = lshr i64 %16, 12
store i64 %17, i64* %3
br label %7
18: ; preds = %7
%19 = load i32, i32* %4
%20 = and i32 %19, 4095
ret i32 %20
}

LLVM IR (-O2):
define i32 @tag_hash(i8* %0) {
%2 = icmp eq i8* %0, null
br i1 %2, label %14, label %3
3: ; preds = %1
%4 = ptrtoint i8* %0 to i64
br label %5
5: ; preds = %3, %5
%6 = phi i32 [ %9, %5 ], [ 0, %3 ]
%7 = phi i64 [ %10, %5 ], [ %4, %3 ]
%8 = trunc i64 %7 to i32
%9 = xor i32 %6, %8
%10 = lshr i64 %7, 12
%11 = icmp ult i64 %7, 4096
br i1 %11, label %12, label %5
12: ; preds = %5
%13 = and i32 %9, 4095
br label %14
14: ; preds = %12, %1
%15 = phi i32 [ 0, %1 ], [ %13, %12 ]
ret i32 %15
}
/* Variables and functions */
int /*<<< orphan*/ framebuf_put_char(char);
void framebuf_write(char *str) {
  char c;
  while ((c = *str++) != '\0')
    framebuf_put_char(c);
}


x86 assembly (clang, -O0):
<framebuf_write>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x8(%rbp)
mov    (%rax),%al
mov    %al,-0x9(%rbp)
movsbl %al,%eax
cmp    $0x0,%eax
je     114a <framebuf_write+0x3a>
movsbl -0x9(%rbp),%edi
call   1030 <framebuf_put_char@plt>
jmp    111c <framebuf_write+0xc>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<framebuf_write>:
push   %rbx
mov    (%rdi),%al
test   %al,%al
je     1133 <framebuf_write+0x23>
mov    %rdi,%rbx
add    $0x1,%rbx
xchg   %ax,%ax
movsbl %al,%edi
call   1030 <framebuf_put_char@plt>
movzbl (%rbx),%eax
add    $0x1,%rbx
test   %al,%al
jne    1120 <framebuf_write+0x10>
pop    %rbx
ret

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

LLVM IR (-O2):
define void @framebuf_write(i8* nocapture %0) {
%2 = load i8, i8* %0
%3 = icmp eq i8 %2, 0
br i1 %3, label %11, label %4
4: ; preds = %1, %4
%5 = phi i8 [ %9, %4 ], [ %2, %1 ]
%6 = phi i8* [ %7, %4 ], [ %0, %1 ]
%7 = getelementptr inbounds i8, i8* %6, i64 1
%8 = tail call i32 @framebuf_put_char(i8 signext %5)
%9 = load i8, i8* %7
%10 = icmp eq i8 %9, 0
br i1 %10, label %11, label %4
11: ; preds = %4, %1
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ time_t;
struct tm {
  int tm_year;
};

/* Variables and functions */
struct tm *localtime(int /*<<< orphan*/ *);
int /*<<< orphan*/ time(int /*<<< orphan*/ *);
int current_year() {
  struct tm *local;
  time_t t;
  t = time(NULL);
  local = localtime(&t);
  return local->tm_year + 1900;
}


x86 assembly (clang, -O0):
<current_year>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
xor    %eax,%eax
mov    %eax,%edi
call   1040 <time@plt>
mov    %eax,-0xc(%rbp)
lea    -0xc(%rbp),%rdi
call   1030 <localtime@plt>
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%eax
add    $0x76c,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<current_year>:
push   %rax
xor    %edi,%edi
call   1040 <time@plt>
mov    %eax,0x4(%rsp)
lea    0x4(%rsp),%rdi
call   1030 <localtime@plt>
mov    $0x76c,%ecx
add    (%rax),%ecx
mov    %ecx,%eax
pop    %rcx
ret

LLVM IR (-O0):
%struct.tm = type { i32 }
define i32 @current_year() {
%1 = alloca %struct.tm*
%2 = alloca i32
%3 = call i32 @time(i32* null)
store i32 %3, i32* %2
%4 = call %struct.tm* @localtime(i32* %2)
store %struct.tm* %4, %struct.tm** %1
%5 = load %struct.tm*, %struct.tm** %1
%6 = getelementptr inbounds %struct.tm, %struct.tm* %5, i32 0, i32 0
%7 = load i32, i32* %6
%8 = add nsw i32 %7, 1900
ret i32 %8
}

LLVM IR (-O2):
%struct.tm = type { i32 }
define i32 @current_year() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
%3 = tail call i32 @time(i32* null)
store i32 %3, i32* %1
%4 = call %struct.tm* @localtime(i32* %1)
%5 = getelementptr inbounds %struct.tm, %struct.tm* %4, i64 0, i32 0
%6 = load i32, i32* %5
%7 = add nsw i32 %6, 1900
ret i32 %7
}
/* Variables and functions */
int re_match(char const *, char *);
int validate_restrictive_filename(const char *str) {
  if (!str)
    return 0;
  return re_match(str, "^[-_.a-zA-Z0-9]+$");
}


x86 assembly (clang, -O0):
<validate_restrictive_filename>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x10(%rbp)
cmpq   $0x0,-0x10(%rbp)
jne    1133 <validate_restrictive_filename+0x23>
movl   $0x0,-0x4(%rbp)
jmp    1146 <validate_restrictive_filename+0x36>
mov    -0x10(%rbp),%rdi
lea    0xec2(%rip),%rsi
call   1030 <re_match@plt>
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<validate_restrictive_filename>:
test   %rdi,%rdi
je     1121 <validate_restrictive_filename+0x11>
lea    0xee4(%rip),%rsi
jmp    1030 <re_match@plt>
xor    %eax,%eax
ret

LLVM IR (-O0):
@.str = [18 x i8] c"^[-_.a-zA-Z0-9]+$\00"
define i32 @validate_restrictive_filename(i8* %0) {
%2 = alloca i32
%3 = alloca i8*
store i8* %0, i8** %3
%4 = load i8*, i8** %3
%5 = icmp ne i8* %4, null
br i1 %5, label %7, label %6
6: ; preds = %1
store i32 0, i32* %2
br label %10
7: ; preds = %1
%8 = load i8*, i8** %3
%9 = call i32 @re_match(i8* %8, i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0))
store i32 %9, i32* %2
br label %10
10: ; preds = %7, %6
%11 = load i32, i32* %2
ret i32 %11
}

LLVM IR (-O2):
@.str = [18 x i8] c"^[-_.a-zA-Z0-9]+$\00"
define i32 @validate_restrictive_filename(i8* %0) {
%2 = icmp eq i8* %0, null
br i1 %2, label %5, label %3
3: ; preds = %1
%4 = tail call i32 @re_match(i8* %0, i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0))
br label %5
5: ; preds = %1, %3
%6 = phi i32 [ %4, %3 ], [ 0, %1 ]
ret i32 %6
}
/* Type definitions */
typedef int in_addr_t;

/* Variables and functions */
int match_ip4(in_addr_t addr1, in_addr_t addr2, in_addr_t mask) {
  return ((addr1 & mask) == (addr2 & mask)) ? 1 : 0;
}


x86 assembly (clang, -O0):
<match_ip4>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    -0x4(%rbp),%edx
and    -0xc(%rbp),%edx
mov    -0x8(%rbp),%esi
and    -0xc(%rbp),%esi
xor    %eax,%eax
mov    $0x1,%ecx
cmp    %esi,%edx
cmove  %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<match_ip4>:
xor    %esi,%edi
xor    %eax,%eax
test   %edx,%edi
sete   %al
ret

LLVM IR (-O0):
define i32 @match_ip4(i32 %0, i32 %1, i32 %2) {
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
store i32 %0, i32* %4
store i32 %1, i32* %5
store i32 %2, i32* %6
%7 = load i32, i32* %4
%8 = load i32, i32* %6
%9 = and i32 %7, %8
%10 = load i32, i32* %5
%11 = load i32, i32* %6
%12 = and i32 %10, %11
%13 = icmp eq i32 %9, %12
%14 = zext i1 %13 to i64
%15 = select i1 %13, i32 1, i32 0
ret i32 %15
}

LLVM IR (-O2):
define i32 @match_ip4(i32 %0, i32 %1, i32 %2) {
%4 = xor i32 %1, %0
%5 = and i32 %4, %2
%6 = icmp eq i32 %5, 0
%7 = zext i1 %6 to i32
ret i32 %7
}
/* Variables and functions */
int /*<<< orphan*/ EXIT_SUCCESS;
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ print(int, char, char, char, char, char);
int main(void) {
  print(5, 'a', 'b', 'c', 'd', 'e');
  exit(EXIT_SUCCESS);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0x5,%edi
mov    $0x61,%esi
mov    $0x62,%edx
mov    $0x63,%ecx
mov    $0x64,%r8d
mov    $0x65,%r9d
call   1030 <print@plt>
mov    0x2e85(%rip),%rax
mov    (%rax),%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<main>:
push   %rax
mov    $0x5,%edi
mov    $0x61,%esi
mov    $0x62,%edx
mov    $0x63,%ecx
mov    $0x64,%r8d
mov    $0x65,%r9d
call   1030 <print@plt>
mov    0x2e93(%rip),%rax
mov    (%rax),%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@EXIT_SUCCESS = global i32 0
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = call i32 @print(i32 5, i8 signext 97, i8 signext 98, i8 signext 99, i8 signext 100, i8 signext 101)
%3 = load i32, i32* @EXIT_SUCCESS
%4 = call i32 @exit(i32 %3)
unreachable
}

LLVM IR (-O2):
@EXIT_SUCCESS = global i32 0
define i32 @main() {
%1 = tail call i32 @print(i32 5, i8 signext 97, i8 signext 98, i8 signext 99, i8 signext 100, i8 signext 101)
%2 = load i32, i32* @EXIT_SUCCESS
%3 = tail call i32 @exit(i32 %2)
unreachable
}
void ScaleRowDown38_2_Box_NEON() {}


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

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

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

LLVM IR (-O2):
define void @ScaleRowDown38_2_Box_NEON() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
__attribute__((hotpatch)) __attribute__((always_)) void hp3(void) {
  printf("hello, world!\n");
}


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

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

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

LLVM IR (-O2):
@str = [14 x i8] c"hello, world!\00"
define void @hp3() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([14 x i8], [14 x i8]* @str, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ p18_adc();
int /*<<< orphan*/ p18_eeprom();
int /*<<< orphan*/ p18_int_pin();
int /*<<< orphan*/ p18_int_portb();
int /*<<< orphan*/ p18_mssp();
int /*<<< orphan*/ p18_tmr0();
int /*<<< orphan*/ p18_tmr1();
int /*<<< orphan*/ p18_tmr2();
int /*<<< orphan*/ p18_tmr3();
int /*<<< orphan*/ p18_wdt();
int /*<<< orphan*/ serial(int /*<<< orphan*/);
void PIC18F4620_periferic(void) {
  p18_mssp();
  p18_adc();
  p18_int_pin();
  p18_int_portb();
  p18_tmr0();
  p18_wdt();
  p18_eeprom();
  p18_tmr1();
  p18_tmr2();
  p18_tmr3();
  serial(0);
  ;
}


x86 assembly (clang, -O0):
<PIC18F4620_periferic>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   10c0 <p18_mssp@plt>
mov    $0x0,%al
call   1030 <p18_adc@plt>
mov    $0x0,%al
call   1070 <p18_int_pin@plt>
mov    $0x0,%al
call   1080 <p18_int_portb@plt>
mov    $0x0,%al
call   1050 <p18_tmr0@plt>
mov    $0x0,%al
call   1090 <p18_wdt@plt>
mov    $0x0,%al
call   10d0 <p18_eeprom@plt>
mov    $0x0,%al
call   10a0 <p18_tmr1@plt>
mov    $0x0,%al
call   1040 <p18_tmr2@plt>
mov    $0x0,%al
call   10b0 <p18_tmr3@plt>
xor    %edi,%edi
call   1060 <serial@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<PIC18F4620_periferic>:
push   %rax
xor    %eax,%eax
call   10c0 <p18_mssp@plt>
xor    %eax,%eax
call   1030 <p18_adc@plt>
xor    %eax,%eax
call   1070 <p18_int_pin@plt>
xor    %eax,%eax
call   1080 <p18_int_portb@plt>
xor    %eax,%eax
call   1050 <p18_tmr0@plt>
xor    %eax,%eax
call   1090 <p18_wdt@plt>
xor    %eax,%eax
call   10d0 <p18_eeprom@plt>
xor    %eax,%eax
call   10a0 <p18_tmr1@plt>
xor    %eax,%eax
call   1040 <p18_tmr2@plt>
xor    %eax,%eax
call   10b0 <p18_tmr3@plt>
xor    %edi,%edi
pop    %rax
jmp    1060 <serial@plt>

LLVM IR (-O0):
define void @PIC18F4620_periferic() {
%1 = call i32 (...) @p18_mssp()
%2 = call i32 (...) @p18_adc()
%3 = call i32 (...) @p18_int_pin()
%4 = call i32 (...) @p18_int_portb()
%5 = call i32 (...) @p18_tmr0()
%6 = call i32 (...) @p18_wdt()
%7 = call i32 (...) @p18_eeprom()
%8 = call i32 (...) @p18_tmr1()
%9 = call i32 (...) @p18_tmr2()
%10 = call i32 (...) @p18_tmr3()
%11 = call i32 @serial(i32 0)
ret void
}

LLVM IR (-O2):
define void @PIC18F4620_periferic() {
%1 = tail call i32 (...) @p18_mssp()
%2 = tail call i32 (...) @p18_adc()
%3 = tail call i32 (...) @p18_int_pin()
%4 = tail call i32 (...) @p18_int_portb()
%5 = tail call i32 (...) @p18_tmr0()
%6 = tail call i32 (...) @p18_wdt()
%7 = tail call i32 (...) @p18_eeprom()
%8 = tail call i32 (...) @p18_tmr1()
%9 = tail call i32 (...) @p18_tmr2()
%10 = tail call i32 (...) @p18_tmr3()
%11 = tail call i32 @serial(i32 0)
ret void
}
/* Variables and functions */
char *getenv(char *);
void getenvTest(char *home) {
  home = getenv("HOME");
  if (home != 0) {
    char d = home[0];
  }
}


x86 assembly (clang, -O0):
<getenvTest>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
lea    0xedd(%rip),%rdi
call   1030 <getenv@plt>
mov    %rax,-0x8(%rbp)
cmpq   $0x0,-0x8(%rbp)
je     1140 <getenvTest+0x30>
mov    -0x8(%rbp),%rax
mov    (%rax),%al
mov    %al,-0x9(%rbp)
add    $0x10,%rsp
pop    %rbp
ret

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

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

LLVM IR (-O2):
@.str = [5 x i8] c"HOME\00"
define void @getenvTest(i8* nocapture %0) {
%2 = tail call i8* @getenv(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
ret void
}
/* Variables and functions */
double M_PI;
double sin(double);
double sf(double n) { return sin(0.075 * M_PI * n); }


x86 assembly (clang, -O0):
<sf>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movsd  %xmm0,-0x8(%rbp)
movsd  0xedb(%rip),%xmm0
mov    0x2ebc(%rip),%rax
mulsd  (%rax),%xmm0
mulsd  -0x8(%rbp),%xmm0
call   1030 <sin@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<sf>:
mov    0x2ed1(%rip),%rax
movsd  (%rax),%xmm1
mulsd  0xedd(%rip),%xmm1
mulsd  %xmm1,%xmm0
jmp    1030 <sin@plt>

LLVM IR (-O0):
@M_PI = global double 0.000000e+00
define double @sf(double %0) {
%2 = alloca double
store double %0, double* %2
%3 = load double, double* @M_PI
%4 = fmul double 0x3FB3333333333333, %3
%5 = load double, double* %2
%6 = fmul double %4, %5
%7 = call double @sin(double %6)
ret double %7
}

LLVM IR (-O2):
@M_PI = global double 0.000000e+00
define double @sf(double %0) {
%2 = load double, double* @M_PI
%3 = fmul double %2, 0x3FB3333333333333
%4 = fmul double %3, %0
%5 = tail call double @sin(double %4)
ret double %5
}
/* Variables and functions */
int /*<<< orphan*/ glLightfv(unsigned int, unsigned int, float *);
void Lightfv(unsigned int l, unsigned int p, float v[4]) { glLightfv(l, p, v); }


x86 assembly (clang, -O0):
<Lightfv>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %rdx,-0x10(%rbp)
mov    -0x4(%rbp),%edi
mov    -0x8(%rbp),%esi
mov    -0x10(%rbp),%rdx
call   1030 <glLightfv@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<Lightfv>:
jmp    1030 <glLightfv@plt>

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

LLVM IR (-O2):
define void @Lightfv(i32 %0, i32 %1, float* %2) {
%4 = tail call i32 @glLightfv(i32 %0, i32 %1, float* %2)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ addvv(float *, float const *);
int dotvv(float const *, float const *);
int /*<<< orphan*/ mulvf(float *, float const *, int);
void reflect(float *r, const float *I, const float *N) {
  mulvf(r, N, -2 * dotvv(N, I));
  addvv(r, I);
}


x86 assembly (clang, -O0):
<reflect>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x28(%rbp)
mov    -0x18(%rbp),%rax
mov    %rax,-0x20(%rbp)
mov    -0x18(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1040 <dotvv@plt>
mov    -0x28(%rbp),%rdi
mov    -0x20(%rbp),%rsi
imul   $0xfffffffe,%eax,%edx
call   1050 <mulvf@plt>
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1030 <addvv@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<reflect>:
push   %r15
push   %r14
push   %rbx
mov    %rdx,%rbx
mov    %rsi,%r14
mov    %rdi,%r15
mov    %rdx,%rdi
call   1040 <dotvv@plt>
lea    (%rax,%rax,1),%edx
neg    %edx
mov    %r15,%rdi
mov    %rbx,%rsi
call   1050 <mulvf@plt>
mov    %r15,%rdi
mov    %r14,%rsi
pop    %rbx
pop    %r14
pop    %r15
jmp    1030 <addvv@plt>

LLVM IR (-O0):
define void @reflect(float* %0, float* %1, float* %2) {
%4 = alloca float*
%5 = alloca float*
%6 = alloca float*
store float* %0, float** %4
store float* %1, float** %5
store float* %2, float** %6
%7 = load float*, float** %4
%8 = load float*, float** %6
%9 = load float*, float** %6
%10 = load float*, float** %5
%11 = call i32 @dotvv(float* %9, float* %10)
%12 = mul nsw i32 -2, %11
%13 = call i32 @mulvf(float* %7, float* %8, i32 %12)
%14 = load float*, float** %4
%15 = load float*, float** %5
%16 = call i32 @addvv(float* %14, float* %15)
ret void
}

LLVM IR (-O2):
define void @reflect(float* %0, float* %1, float* %2) {
%4 = tail call i32 @dotvv(float* %2, float* %1)
%5 = mul nsw i32 %4, -2
%6 = tail call i32 @mulvf(float* %0, float* %2, i32 %5)
%7 = tail call i32 @addvv(float* %0, float* %1)
ret void
}
int verify_benchmark(int r) {
  int expected = 2455;
  if (r != expected)
    return 0;
  return 1;
}


x86 assembly (clang, -O0):
<verify_benchmark>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x8(%rbp)
movl   $0x997,-0xc(%rbp)
mov    -0x8(%rbp),%eax
cmp    -0xc(%rbp),%eax
je     1126 <verify_benchmark+0x26>
movl   $0x0,-0x4(%rbp)
jmp    112d <verify_benchmark+0x2d>
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<verify_benchmark>:
xor    %eax,%eax
cmp    $0x997,%edi
sete   %al
ret

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

LLVM IR (-O2):
define i32 @verify_benchmark(i32 %0) {
%2 = icmp eq i32 %0, 2455
%3 = zext i1 %2 to i32
ret i32 %3
}
void flush_input(void) {}


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

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

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

LLVM IR (-O2):
define void @flush_input() {
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ uint32_t;

/* Variables and functions */
uint32_t s2u32(void *s) { return *((uint32_t *)s); }


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

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

LLVM IR (-O0):
define i32 @s2u32(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = bitcast i8* %3 to i32*
%5 = load i32, i32* %4
ret i32 %5
}

LLVM IR (-O2):
define i32 @s2u32(i8* nocapture %0) {
%2 = bitcast i8* %0 to i32*
%3 = load i32, i32* %2
ret i32 %3
}