xunge/DecIR huggingface dataset:
/* Variables and functions */
int /*<<< orphan*/ printf(char *, char *);
int /*<<< orphan*/ strcat(char *, char *);
int main() {
  char last[] = "Washington";
  char first[] = "George ";
  strcat(first, last);
  printf("Hello, %s\n", first);
  return (0);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    0xeca(%rip),%rax
mov    %rax,-0xf(%rbp)
mov    0xec7(%rip),%ax
mov    %ax,-0x7(%rbp)
mov    0xebf(%rip),%al
mov    %al,-0x5(%rbp)
mov    0xeb6(%rip),%rax
mov    %rax,-0x17(%rbp)
lea    -0x17(%rbp),%rdi
lea    -0xf(%rbp),%rsi
call   1040 <strcat@plt>
lea    -0x17(%rbp),%rsi
lea    0xea2(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x20,%rsp
movabs $0x74676e6968736157,%rax
6e 67 74
mov    %rax,0x8(%rsp)
movl   $0x6e6f74,0xf(%rsp)
movabs $0x206567726f6547,%rax
mov    %rax,0x18(%rsp)
lea    0x18(%rsp),%rbx
lea    0x8(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <strcat@plt>
lea    0xea7(%rip),%rdi
mov    %rbx,%rsi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@__const.main.last = [11 x i8] c"Washington\00"
@__const.main.first = [8 x i8] c"George \00"
@.str = [11 x i8] c"Hello, %s\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [11 x i8]
%3 = alloca [8 x i8]
store i32 0, i32* %1
%4 = bitcast [11 x i8]* %2 to i8*
%5 = bitcast [8 x i8]* %3 to i8*
%6 = getelementptr inbounds [8 x i8], [8 x i8]* %3, i64 0, i64 0
%7 = getelementptr inbounds [11 x i8], [11 x i8]* %2, i64 0, i64 0
%8 = call i32 @strcat(i8* %6, i8* %7)
%9 = getelementptr inbounds [8 x i8], [8 x i8]* %3, i64 0, i64 0
%10 = call i32 @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0), i8* %9)
ret i32 0
}

LLVM IR (-O2):
@__const.main.last = [11 x i8] c"Washington\00"
@.str = [11 x i8] c"Hello, %s\0A\00"
define i32 @main() {
%1 = alloca [11 x i8]
%2 = alloca i64
%3 = getelementptr inbounds [11 x i8], [11 x i8]* %1, i64 0, i64 0
%4 = bitcast i64* %2 to i8*
store i64 9118694230680903, i64* %2
%5 = call i32 @strcat(i8* %4, i8* %3)
%6 = call i32 @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0), i8* %4)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, char *);
int /*<<< orphan*/ scanf(char *, char *);
int main(void) {
  char name[15];
  scanf("%s", name);
  printf("%spp\n", name);
  return 0;
}


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

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x10,%rsp
lea    0xed4(%rip),%rdi
lea    0x1(%rsp),%rbx
mov    %rbx,%rsi
call   1040 <scanf@plt>
lea    0xec3(%rip),%rdi
mov    %rbx,%rsi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%s\00"
@.str.1 = [6 x i8] c"%spp\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [15 x i8]
store i32 0, i32* %1
%3 = getelementptr inbounds [15 x i8], [15 x i8]* %2, i64 0, i64 0
%4 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* %3)
%5 = getelementptr inbounds [15 x i8], [15 x i8]* %2, i64 0, i64 0
%6 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.1, i64 0, i64 0), i8* %5)
ret i32 0
}

LLVM IR (-O2):
@.str = [3 x i8] c"%s\00"
@.str.1 = [6 x i8] c"%spp\0A\00"
define i32 @main() {
%1 = alloca [15 x i8]
%2 = getelementptr inbounds [15 x i8], [15 x i8]* %1, i64 0, i64 0
%3 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* %2)
%4 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.1, i64 0, i64 0), i8* %2)
ret i32 0
}
int ubi_dbg_is_bitflip(const struct ubi_device *ubi) { return 0; }


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

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

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

LLVM IR (-O2):
%struct.ubi_device = type opaque
define i32 @ubi_dbg_is_bitflip(%struct.ubi_device* nocapture readnone %0) {
ret i32 0
}
/* Type definitions */
struct timeval {
  scalar_t__ tv_usec;
  scalar_t__ tv_sec;
};

/* Variables and functions */
int /*<<< orphan*/ gettimeofday(struct timeval *, int /*<<< orphan*/ *);
long long get_ustime_sec(void) {
  struct timeval tv;
  long long ust;
  gettimeofday(&tv, NULL);
  ust = ((long long)tv.tv_sec) * 1000000;
  ust += tv.tv_usec;
  return ust;
}


x86 assembly (clang, -O0):
<get_ustime_sec>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
lea    -0x10(%rbp),%rdi
xor    %eax,%eax
mov    %eax,%esi
call   1030 <gettimeofday@plt>
imul   $0xf4240,-0x8(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    -0x10(%rbp),%rax
add    -0x18(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<get_ustime_sec>:
sub    $0x18,%rsp
lea    0x8(%rsp),%rdi
xor    %esi,%esi
call   1030 <gettimeofday@plt>
imul   $0xf4240,0x10(%rsp),%rax
add    0x8(%rsp),%rax
add    $0x18,%rsp
ret

LLVM IR (-O0):
%struct.timeval = type { i64, i64 }
define i64 @get_ustime_sec() {
%1 = alloca %struct.timeval
%2 = alloca i64
%3 = call i32 @gettimeofday(%struct.timeval* %1, i32* null)
%4 = getelementptr inbounds %struct.timeval, %struct.timeval* %1, i32 0, i32 1
%5 = load i64, i64* %4
%6 = mul nsw i64 %5, 1000000
store i64 %6, i64* %2
%7 = getelementptr inbounds %struct.timeval, %struct.timeval* %1, i32 0, i32 0
%8 = load i64, i64* %7
%9 = load i64, i64* %2
%10 = add nsw i64 %9, %8
store i64 %10, i64* %2
%11 = load i64, i64* %2
ret i64 %11
}

LLVM IR (-O2):
%struct.timeval = type { i64, i64 }
define i64 @get_ustime_sec() {
%1 = alloca %struct.timeval
%2 = bitcast %struct.timeval* %1 to i8*
%3 = call i32 @gettimeofday(%struct.timeval* %1, i32* null)
%4 = getelementptr inbounds %struct.timeval, %struct.timeval* %1, i64 0, i32 1
%5 = load i64, i64* %4
%6 = mul nsw i64 %5, 1000000
%7 = getelementptr inbounds %struct.timeval, %struct.timeval* %1, i64 0, i32 0
%8 = load i64, i64* %7
%9 = add nsw i64 %6, %8
ret i64 %9
}
int same_row(room1, room2) { return ((room1 / 3) == (room2 / 3)); }


x86 assembly (clang, -O0):
<same_row>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x4(%rbp),%eax
mov    $0x3,%ecx
cltd
idiv   %ecx
mov    %eax,-0xc(%rbp)
mov    -0x8(%rbp),%eax
mov    $0x3,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0xc(%rbp),%eax
cmp    %ecx,%eax
sete   %al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<same_row>:
movslq %edi,%rax
imul   $0x55555556,%rax,%rcx
mov    %rcx,%rax
shr    $0x3f,%rax
shr    $0x20,%rcx
add    %eax,%ecx
movslq %esi,%rax
imul   $0x55555556,%rax,%rdx
mov    %rdx,%rax
shr    $0x3f,%rax
shr    $0x20,%rdx
add    %eax,%edx
xor    %eax,%eax
cmp    %edx,%ecx
sete   %al
ret

LLVM IR (-O0):
define i32 @same_row(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 = sdiv i32 %5, 3
%7 = load i32, i32* %4
%8 = sdiv i32 %7, 3
%9 = icmp eq i32 %6, %8
%10 = zext i1 %9 to i32
ret i32 %10
}

LLVM IR (-O2):
define i32 @same_row(i32 %0, i32 %1) {
%3 = sdiv i32 %0, 3
%4 = sdiv i32 %1, 3
%5 = icmp eq i32 %3, %4
%6 = zext i1 %5 to i32
ret i32 %6
}
/* Variables and functions */
double dsfmt_gv_genrand_close_open();
double get_rand() { return dsfmt_gv_genrand_close_open(); }


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

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

LLVM IR (-O0):
define double @get_rand() {
%1 = call double (...) @dsfmt_gv_genrand_close_open()
ret double %1
}

LLVM IR (-O2):
define double @get_rand() {
%1 = tail call double (...) @dsfmt_gv_genrand_close_open()
ret double %1
}
/* Variables and functions */
void stub1();
__attribute__((visibility("hidden"))) void
__atexit_handler_wrapper(void *func) {
  if (func != NULL) {
    (*(void (*)(void))func)();
  }
}


x86 assembly (clang, -O0):
<__atexit_handler_wrapper>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
cmpq   $0x0,-0x8(%rbp)
je     111a <__atexit_handler_wrapper+0x1a>
call   *-0x8(%rbp)
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<__atexit_handler_wrapper>:
test   %rdi,%rdi
je     1107 <__atexit_handler_wrapper+0x7>
jmp    *%rdi
ret

LLVM IR (-O0):
define hidden void @__atexit_handler_wrapper(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 %8
5: ; preds = %1
%6 = load i8*, i8** %2
%7 = bitcast i8* %6 to void ()*
br label %8
8: ; preds = %5, %1
ret void
}

LLVM IR (-O2):
define hidden void @__atexit_handler_wrapper(i8* %0) {
%2 = icmp eq i8* %0, null
br i1 %2, label %5, label %3
3: ; preds = %1
%4 = bitcast i8* %0 to void ()*
tail call void %4()
br label %5
5: ; preds = %3, %1
ret void
}
/* Variables and functions */
int /*<<< orphan*/ assert(char *);
char *strstr(char *, char *);
char *find_body(char *response) {
  char *body;
  assert(response);
  body = strstr(response, "\r\n\r\n");
  assert(body);
  return body + 4;
}


x86 assembly (clang, -O0):
<find_body>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <assert@plt>
mov    -0x8(%rbp),%rdi
lea    0xec0(%rip),%rsi
call   1040 <strstr@plt>
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
call   1030 <assert@plt>
mov    -0x10(%rbp),%rax
add    $0x4,%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<find_body>:
push   %rbx
mov    %rdi,%rbx
call   1030 <assert@plt>
lea    0xed0(%rip),%rsi
mov    %rbx,%rdi
call   1040 <strstr@plt>
mov    %rax,%rbx
mov    %rax,%rdi
call   1030 <assert@plt>
add    $0x4,%rbx
mov    %rbx,%rax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [5 x i8] c"\0D\0A\0D\0A\00"
define i8* @find_body(i8* %0) {
%2 = alloca i8*
%3 = alloca i8*
store i8* %0, i8** %2
%4 = load i8*, i8** %2
%5 = call i32 @assert(i8* %4)
%6 = load i8*, i8** %2
%7 = call i8* @strstr(i8* %6, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
store i8* %7, i8** %3
%8 = load i8*, i8** %3
%9 = call i32 @assert(i8* %8)
%10 = load i8*, i8** %3
%11 = getelementptr inbounds i8, i8* %10, i64 4
ret i8* %11
}

LLVM IR (-O2):
@.str = [5 x i8] c"\0D\0A\0D\0A\00"
define i8* @find_body(i8* %0) {
%2 = tail call i32 @assert(i8* %0)
%3 = tail call i8* @strstr(i8* dereferenceable(1) %0, i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%4 = tail call i32 @assert(i8* %3)
%5 = getelementptr inbounds i8, i8* %3, i64 4
ret i8* %5
}
_Complex float f7() { return 1.0; }


x86 assembly (clang, -O0):
<f7>:
push   %rbp
mov    %rsp,%rbp
movl   $0x3f800000,-0x8(%rbp)
movl   $0x0,-0x4(%rbp)
movsd  -0x8(%rbp),%xmm0
pop    %rbp
ret

x86 assembly (clang, -O2):
<f7>:
movss  0xef8(%rip),%xmm0
ret

LLVM IR (-O0):
define <2 x float> @f7() {
%1 = alloca { float, float }
%2 = getelementptr inbounds { float, float }, { float, float }* %1, i32 0, i32 0
%3 = getelementptr inbounds { float, float }, { float, float }* %1, i32 0, i32 1
store float 1.000000e+00, float* %2
store float 0.000000e+00, float* %3
%4 = bitcast { float, float }* %1 to <2 x float>*
%5 = load <2 x float>, <2 x float>* %4
ret <2 x float> %5
}

LLVM IR (-O2):
define <2 x float> @f7() {
ret <2 x float> <float 1.000000e+00, float 0.000000e+00>
}
void gtk_adjustment_changed() {}


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

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

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

LLVM IR (-O2):
define void @gtk_adjustment_changed() {
ret void
}
/* Type definitions */
struct page {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ test_set_page_writeback(struct page *);
void set_page_writeback(struct page *page) { test_set_page_writeback(page); }


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

x86 assembly (clang, -O2):
<set_page_writeback>:
jmp    1030 <test_set_page_writeback@plt>

LLVM IR (-O0):
%struct.page = type { i32 }
define void @set_page_writeback(%struct.page* %0) {
%2 = alloca %struct.page*
store %struct.page* %0, %struct.page** %2
%3 = load %struct.page*, %struct.page** %2
%4 = call i32 @test_set_page_writeback(%struct.page* %3)
ret void
}

LLVM IR (-O2):
%struct.page = type { i32 }
define void @set_page_writeback(%struct.page* %0) {
%2 = tail call i32 @test_set_page_writeback(%struct.page* %0)
ret void
}
__attribute__((__weak__, __always___)) char *
softboundmpx___strdup(const char *s) {
  void *ret_ptr = strdup(s);
  __softboundmpx_strdup_handler(ret_ptr);
  return ret_ptr;
}


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

x86 assembly (clang, -O2):
<softboundmpx___strdup>:
push   %rbx
call   1040 <strdup@plt>
mov    %rax,%rbx
mov    %rax,%rdi
xor    %eax,%eax
call   1030 <__softboundmpx_strdup_handler@plt>
mov    %rbx,%rax
pop    %rbx
ret

LLVM IR (-O0):
define weak i8* @softboundmpx___strdup(i8* %0) {
%2 = alloca i8*
%3 = alloca i8*
store i8* %0, i8** %2
%4 = load i8*, i8** %2
%5 = call i8* @strdup(i8* %4)
store i8* %5, i8** %3
%6 = load i8*, i8** %3
%7 = call i32 (i8*, ...) bitcast (i32 (...)* @__softboundmpx_strdup_handler to i32 (i8*, ...)*)(i8* %6)
%8 = load i8*, i8** %3
ret i8* %8
}

LLVM IR (-O2):
define weak i8* @softboundmpx___strdup(i8* %0) {
%2 = tail call i8* @strdup(i8* %0)
%3 = tail call i32 (i8*, ...) bitcast (i32 (...)* @__softboundmpx_strdup_handler to i32 (i8*, ...)*)(i8* %2)
ret i8* %2
}
/* Variables and functions */
int EBADF;
int /*<<< orphan*/ close(int);
int errno;
void close_prot_errno_disarm_function(int *fd) {
  if (*fd >= 0) {
    int _e_ = errno;
    close(*fd);
    errno = _e_;
    *fd = -EBADF;
  };
}


x86 assembly (clang, -O0):
<close_prot_errno_disarm_function>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
cmpl   $0x0,(%rax)
jl     115d <close_prot_errno_disarm_function+0x4d>
mov    0x2eb0(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0xc(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%edi
call   1030 <close@plt>
mov    -0xc(%rbp),%ecx
mov    0x2e96(%rip),%rax
mov    %ecx,(%rax)
xor    %ecx,%ecx
mov    0x2e83(%rip),%rax
sub    (%rax),%ecx
mov    -0x8(%rbp),%rax
mov    %ecx,(%rax)
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<close_prot_errno_disarm_function>:
push   %rbp
push   %r14
push   %rbx
mov    %rdi,%rbx
mov    (%rdi),%edi
test   %edi,%edi
js     113c <close_prot_errno_disarm_function+0x2c>
mov    0x2ebc(%rip),%r14
mov    (%r14),%ebp
call   1030 <close@plt>
mov    %ebp,(%r14)
mov    0x2ea2(%rip),%rax
xor    %ecx,%ecx
sub    (%rax),%ecx
mov    %ecx,(%rbx)
pop    %rbx
pop    %r14
pop    %rbp
ret

LLVM IR (-O0):
@errno = global i32 0
@EBADF = global i32 0
define void @close_prot_errno_disarm_function(i32* %0) {
%2 = alloca i32*
%3 = alloca i32
store i32* %0, i32** %2
%4 = load i32*, i32** %2
%5 = load i32, i32* %4
%6 = icmp sge i32 %5, 0
br i1 %6, label %7, label %16
7: ; preds = %1
%8 = load i32, i32* @errno
store i32 %8, i32* %3
%9 = load i32*, i32** %2
%10 = load i32, i32* %9
%11 = call i32 @close(i32 %10)
%12 = load i32, i32* %3
store i32 %12, i32* @errno
%13 = load i32, i32* @EBADF
%14 = sub nsw i32 0, %13
%15 = load i32*, i32** %2
store i32 %14, i32* %15
br label %16
16: ; preds = %7, %1
ret void
}

LLVM IR (-O2):
@errno = global i32 0
@EBADF = global i32 0
define void @close_prot_errno_disarm_function(i32* nocapture %0) {
%2 = load i32, i32* %0
%3 = icmp sgt i32 %2, -1
br i1 %3, label %4, label %9
4: ; preds = %1
%5 = load i32, i32* @errno
%6 = tail call i32 @close(i32 %2)
store i32 %5, i32* @errno
%7 = load i32, i32* @EBADF
%8 = sub nsw i32 0, %7
store i32 %8, i32* %0
br label %9
9: ; preds = %4, %1
ret void
}
/* Variables and functions */
scalar_t__ round(double);
float roundf(float x) { return (float)round((double)x); }


x86 assembly (clang, -O0):
<roundf>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
call   1030 <round@plt>
cvtsi2ss %rax,%xmm0
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<roundf>:
push   %rax
cvtss2sd %xmm0,%xmm0
call   1030 <round@plt>
xorps  %xmm0,%xmm0
cvtsi2ss %rax,%xmm0
pop    %rax
ret

LLVM IR (-O0):
define float @roundf(float %0) {
%2 = alloca float
store float %0, float* %2
%3 = load float, float* %2
%4 = fpext float %3 to double
%5 = call i64 @round(double %4)
%6 = sitofp i64 %5 to float
ret float %6
}

LLVM IR (-O2):
define float @roundf(float %0) {
%2 = fpext float %0 to double
%3 = tail call i64 @round(double %2)
%4 = sitofp i64 %3 to float
ret float %4
}
int oddhs_get_activity(const double val) {
  int intval = (int)((((double)16384) * val) + 0.5);
  if (intval > 16384)
    intval = 16384;
  else if (intval < 0)
    intval = 0;
  return 16384 - intval;
}


x86 assembly (clang, -O0):
<oddhs_get_activity>:
push   %rbp
mov    %rsp,%rbp
movsd  %xmm0,-0x8(%rbp)
movsd  -0x8(%rbp),%xmm0
movsd  0xeea(%rip),%xmm1
mulsd  %xmm1,%xmm0
movsd  0xee6(%rip),%xmm1
addsd  %xmm1,%xmm0
cvttsd2si %xmm0,%eax
mov    %eax,-0xc(%rbp)
cmpl   $0x4000,-0xc(%rbp)
jle    1146 <oddhs_get_activity+0x46>
movl   $0x4000,-0xc(%rbp)
jmp    115c <oddhs_get_activity+0x5c>
cmpl   $0x0,-0xc(%rbp)
jge    1157 <oddhs_get_activity+0x57>
movl   $0x0,-0xc(%rbp)
jmp    115c <oddhs_get_activity+0x5c>
mov    $0x4000,%eax
sub    -0xc(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<oddhs_get_activity>:
mulsd  0xef8(%rip),%xmm0
addsd  0xef8(%rip),%xmm0
cvttsd2si %xmm0,%ecx
xor    %edx,%edx
test   %ecx,%ecx
mov    $0x0,%esi
cmovns %ecx,%esi
mov    $0x4000,%eax
sub    %esi,%eax
cmp    $0x4001,%ecx
cmovge %edx,%eax
ret

LLVM IR (-O0):
define i32 @oddhs_get_activity(double %0) {
%2 = alloca double
%3 = alloca i32
store double %0, double* %2
%4 = load double, double* %2
%5 = call double @llvm.fmuladd.f64(double 1.638400e+04, double %4, double 5.000000e-01)
%6 = fptosi double %5 to i32
store i32 %6, i32* %3
%7 = load i32, i32* %3
%8 = icmp sgt i32 %7, 16384
br i1 %8, label %9, label %10
9: ; preds = %1
store i32 16384, i32* %3
br label %15
10: ; preds = %1
%11 = load i32, i32* %3
%12 = icmp slt i32 %11, 0
br i1 %12, label %13, label %14
13: ; preds = %10
store i32 0, i32* %3
br label %14
14: ; preds = %13, %10
br label %15
15: ; preds = %14, %9
%16 = load i32, i32* %3
%17 = sub nsw i32 16384, %16
ret i32 %17
}

LLVM IR (-O2):
define i32 @oddhs_get_activity(double %0) {
%2 = tail call double @llvm.fmuladd.f64(double %0, double 1.638400e+04, double 5.000000e-01)
%3 = fptosi double %2 to i32
%4 = icmp sgt i32 %3, 16384
%5 = icmp sgt i32 %3, 0
%6 = select i1 %5, i32 %3, i32 0
%7 = sub nsw i32 16384, %6
%8 = select i1 %4, i32 0, i32 %7
ret i32 %8
}
unsigned short t1(unsigned short x) { return x--; }


x86 assembly (clang, -O0):
<t1>:
push   %rbp
mov    %rsp,%rbp
mov    %di,%ax
mov    %ax,-0x2(%rbp)
mov    -0x2(%rbp),%ax
mov    %ax,%cx
add    $0xffff,%cx
mov    %cx,-0x2(%rbp)
movzwl %ax,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<t1>:
mov    %edi,%eax
ret

LLVM IR (-O0):
define zeroext i16 @t1(i16 zeroext %0) {
%2 = alloca i16
store i16 %0, i16* %2
%3 = load i16, i16* %2
%4 = add i16 %3, -1
store i16 %4, i16* %2
ret i16 %3
}

LLVM IR (-O2):
define zeroext i16 @t1(i16 returned zeroext %0) {
ret i16 %0
}
unsigned setbits(unsigned x, int p, int n, unsigned y) {
  return x & ~(~(~0 << n) << (p + 1 - n)) | (y & ~(~0 << n)) << (p + 1 - n);
}


x86 assembly (clang, -O0):
<setbits>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %ecx,-0x10(%rbp)
mov    -0x4(%rbp),%eax
mov    -0xc(%rbp),%ecx
mov    $0xffffffff,%edx
shl    %cl,%edx
xor    $0xffffffff,%edx
mov    -0x8(%rbp),%ecx
add    $0x1,%ecx
sub    -0xc(%rbp),%ecx
shl    %cl,%edx
mov    %edx,%ecx
xor    $0xffffffff,%ecx
and    %ecx,%eax
mov    -0x10(%rbp),%edx
mov    -0xc(%rbp),%ecx
mov    $0xffffffff,%esi
shl    %cl,%esi
mov    %esi,%ecx
xor    $0xffffffff,%ecx
and    %ecx,%edx
mov    -0x8(%rbp),%ecx
add    $0x1,%ecx
sub    -0xc(%rbp),%ecx
shl    %cl,%edx
mov    %edx,%ecx
or     %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<setbits>:
mov    %ecx,%r8d
mov    %edx,%ecx
mov    $0xffffffff,%eax
shl    %cl,%eax
not    %eax
sub    %edx,%esi
lea    0x1(%rsi),%ecx
mov    %eax,%edx
shl    %cl,%edx
not    %edx
and    %edi,%edx
and    %r8d,%eax
shl    %cl,%eax
or     %edx,%eax
ret

LLVM IR (-O0):
define i32 @setbits(i32 %0, i32 %1, i32 %2, i32 %3) {
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
store i32 %0, i32* %5
store i32 %1, i32* %6
store i32 %2, i32* %7
store i32 %3, i32* %8
%9 = load i32, i32* %5
%10 = load i32, i32* %7
%11 = shl i32 -1, %10
%12 = xor i32 %11, -1
%13 = load i32, i32* %6
%14 = add nsw i32 %13, 1
%15 = load i32, i32* %7
%16 = sub nsw i32 %14, %15
%17 = shl i32 %12, %16
%18 = xor i32 %17, -1
%19 = and i32 %9, %18
%20 = load i32, i32* %8
%21 = load i32, i32* %7
%22 = shl i32 -1, %21
%23 = xor i32 %22, -1
%24 = and i32 %20, %23
%25 = load i32, i32* %6
%26 = add nsw i32 %25, 1
%27 = load i32, i32* %7
%28 = sub nsw i32 %26, %27
%29 = shl i32 %24, %28
%30 = or i32 %19, %29
ret i32 %30
}

LLVM IR (-O2):
define i32 @setbits(i32 %0, i32 %1, i32 %2, i32 %3) {
%5 = shl nsw i32 -1, %2
%6 = xor i32 %5, -1
%7 = add nsw i32 %1, 1
%8 = sub i32 %7, %2
%9 = shl i32 %6, %8
%10 = xor i32 %9, -1
%11 = and i32 %10, %0
%12 = and i32 %6, %3
%13 = shl i32 %12, %8
%14 = or i32 %11, %13
ret i32 %14
}
/* Variables and functions */
int /*<<< orphan*/ fputs(char *, int /*<<< orphan*/);
int /*<<< orphan*/ stderr;
void indent(int amt) {
  while (amt--) {
    fputs("  ", stderr);
  }
}


x86 assembly (clang, -O0):
<indent>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%eax
mov    %eax,%ecx
add    $0xffffffff,%ecx
mov    %ecx,-0x4(%rbp)
cmp    $0x0,%eax
je     1149 <indent+0x39>
mov    0x2eaa(%rip),%rax
mov    (%rax),%esi
lea    0xec1(%rip),%rdi
call   1030 <fputs@plt>
jmp    111b <indent+0xb>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<indent>:
push   %r15
push   %r14
push   %rbx
test   %edi,%edi
je     1140 <indent+0x30>
mov    %edi,%ebx
mov    0x2ebe(%rip),%r15
lea    0xed7(%rip),%r14
nopl   0x0(%rax)
mov    (%r15),%esi
mov    %r14,%rdi
call   1030 <fputs@plt>
add    $0xffffffff,%ebx
jne    1130 <indent+0x20>
pop    %rbx
pop    %r14
pop    %r15
ret

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

LLVM IR (-O2):
@.str = [3 x i8] c" \00"
@stderr = global i32 0
define void @indent(i32 %0) {
%2 = icmp eq i32 %0, 0
br i1 %2, label %9, label %3
3: ; preds = %1, %3
%4 = phi i32 [ %5, %3 ], [ %0, %1 ]
%5 = add nsw i32 %4, -1
%6 = load i32, i32* @stderr
%7 = tail call i32 @fputs(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32 %6)
%8 = icmp eq i32 %5, 0
br i1 %8, label %9, label %3
9: ; preds = %3, %1
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ uint32_t;

/* Variables and functions */
__attribute__((always_)) uint32_t __RBIT(uint32_t value) {
  uint32_t result;
  return (result);
}


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

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

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

LLVM IR (-O2):
define i32 @__RBIT(i32 %0) {
ret i32 undef
}
/* Variables and functions */
int InitialisationAvecService(char *, char *);
int Initialisation(char *machine) {
  return InitialisationAvecService(machine, "13214");
}


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

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

LLVM IR (-O0):
@.str = [6 x i8] c"13214\00"
define i32 @Initialisation(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = call i32 @InitialisationAvecService(i8* %3, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
ret i32 %4
}

LLVM IR (-O2):
@.str = [6 x i8] c"13214\00"
define i32 @Initialisation(i8* %0) {
%2 = tail call i32 @InitialisationAvecService(i8* %0, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
ret i32 %2
}
int parse(const char *s) { return 0; }


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

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

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

LLVM IR (-O2):
define i32 @parse(i8* nocapture readnone %0) {
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ do_longjmp();
int /*<<< orphan*/ do_setjmp();
int /*<<< orphan*/ printf(char *);
int main() {
  printf("starting...\n");
  do_setjmp();
  do_longjmp();
  printf("finished...\n");
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
lea    0xec5(%rip),%rdi
call   1040 <printf@plt>
mov    $0x0,%al
call   1050 <do_setjmp@plt>
mov    $0x0,%al
call   1030 <do_longjmp@plt>
lea    0xeb8(%rip),%rdi
call   1040 <printf@plt>
xor    %eax,%eax
pop    %rbp
ret

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

LLVM IR (-O0):
@.str = [13 x i8] c"starting...\0A\00"
@.str.1 = [13 x i8] c"finished...\0A\00"
define i32 @main() {
%1 = call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
%2 = call i32 (...) @do_setjmp()
%3 = call i32 (...) @do_longjmp()
%4 = call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.1, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@str = [12 x i8] c"starting...\00"
@str.2 = [12 x i8] c"finished...\00"
define i32 @main() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @str, i64 0, i64 0))
%2 = tail call i32 (...) @do_setjmp()
%3 = tail call i32 (...) @do_longjmp()
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @str.2, i64 0, i64 0))
ret i32 0
}
void XtAppSetWarningHandler() {}


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

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

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

LLVM IR (-O2):
define void @XtAppSetWarningHandler() {
ret void
}
void gtk_color_button_set_alpha() {}


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

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

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

LLVM IR (-O2):
define void @gtk_color_button_set_alpha() {
ret void
}
/* Variables and functions */
void *memset(void *, int /*<<< orphan*/, size_t);
void *memclr(void *ptr, size_t len) { return memset(ptr, 0, len); }


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

x86 assembly (clang, -O2):
<memclr>:
mov    %rsi,%rdx
xor    %esi,%esi
jmp    1030 <memset@plt>

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

LLVM IR (-O2):
define i8* @memclr(i8* returned writeonly %0, i64 %1) {
tail call void @llvm.memset.p0i8.i64(i8* align 1 %0, i8 0, i64 %1, i1 false)
ret i8* %0
}
void PopCharPixel(const unsigned char pixel, unsigned char **pixels) {
  *(*pixels)++ = (unsigned char)(pixel);
}


x86 assembly (clang, -O0):
<PopCharPixel>:
push   %rbp
mov    %rsp,%rbp
mov    %dil,%al
mov    %al,-0x1(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x1(%rbp),%cl
mov    -0x10(%rbp),%rdx
mov    (%rdx),%rax
mov    %rax,%rsi
add    $0x1,%rsi
mov    %rsi,(%rdx)
mov    %cl,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<PopCharPixel>:
mov    (%rsi),%rax
lea    0x1(%rax),%rcx
mov    %rcx,(%rsi)
mov    %dil,(%rax)
ret

LLVM IR (-O0):
define void @PopCharPixel(i8 zeroext %0, i8** %1) {
%3 = alloca i8
%4 = alloca i8**
store i8 %0, i8* %3
store i8** %1, i8*** %4
%5 = load i8, i8* %3
%6 = load i8**, i8*** %4
%7 = load i8*, i8** %6
%8 = getelementptr inbounds i8, i8* %7, i32 1
store i8* %8, i8** %6
store i8 %5, i8* %7
ret void
}

LLVM IR (-O2):
define void @PopCharPixel(i8 zeroext %0, i8** nocapture %1) {
%3 = load i8*, i8** %1
%4 = getelementptr inbounds i8, i8* %3, i64 1
store i8* %4, i8** %1
store i8 %0, i8* %3
ret void
}
/* Variables and functions */
int /*<<< orphan*/ draw_color(int, int, char, char, char);
void draw_pixel(int x, int y, char r, char g, char b, int screen) {
  int offset = 720 * x + 720 - (y * 3) - 3;
  draw_color(offset, screen, r, g, b);
}


x86 assembly (clang, -O0):
<draw_pixel>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %r8b,%al
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %dl,-0x9(%rbp)
mov    %cl,-0xa(%rbp)
mov    %al,-0xb(%rbp)
mov    %r9d,-0x10(%rbp)
imul   $0x2d0,-0x4(%rbp),%eax
add    $0x2d0,%eax
imul   $0x3,-0x8(%rbp),%ecx
sub    %ecx,%eax
sub    $0x3,%eax
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%edi
mov    -0x10(%rbp),%esi
mov    -0x9(%rbp),%cl
mov    -0xa(%rbp),%al
movsbl %cl,%edx
movsbl %al,%ecx
movsbl -0xb(%rbp),%r8d
call   1030 <draw_color@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<draw_pixel>:
imul   $0x2d0,%edi,%edi
lea    (%rsi,%rsi,2),%eax
sub    %eax,%edi
add    $0x2cd,%edi
mov    %r9d,%esi
jmp    1030 <draw_color@plt>

LLVM IR (-O0):
define void @draw_pixel(i32 %0, i32 %1, i8 signext %2, i8 signext %3, i8 signext %4, i32 %5) {
%7 = alloca i32
%8 = alloca i32
%9 = alloca i8
%10 = alloca i8
%11 = alloca i8
%12 = alloca i32
%13 = alloca i32
store i32 %0, i32* %7
store i32 %1, i32* %8
store i8 %2, i8* %9
store i8 %3, i8* %10
store i8 %4, i8* %11
store i32 %5, i32* %12
%14 = load i32, i32* %7
%15 = mul nsw i32 720, %14
%16 = add nsw i32 %15, 720
%17 = load i32, i32* %8
%18 = mul nsw i32 %17, 3
%19 = sub nsw i32 %16, %18
%20 = sub nsw i32 %19, 3
store i32 %20, i32* %13
%21 = load i32, i32* %13
%22 = load i32, i32* %12
%23 = load i8, i8* %9
%24 = load i8, i8* %10
%25 = load i8, i8* %11
%26 = call i32 @draw_color(i32 %21, i32 %22, i8 signext %23, i8 signext %24, i8 signext %25)
ret void
}

LLVM IR (-O2):
define void @draw_pixel(i32 %0, i32 %1, i8 signext %2, i8 signext %3, i8 signext %4, i32 %5) {
%7 = mul nsw i32 %0, 720
%8 = mul i32 %1, -3
%9 = add i32 %7, 717
%10 = add i32 %9, %8
%11 = tail call i32 @draw_color(i32 %10, i32 %5, i8 signext %2, i8 signext %3, i8 signext %4)
ret void
}
int choose_pivot(int i, int j) { return ((i + j) / 2); }


x86 assembly (clang, -O0):
<choose_pivot>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x4(%rbp),%eax
add    -0x8(%rbp),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
pop    %rbp
ret

x86 assembly (clang, -O2):
<choose_pivot>:
lea    (%rdi,%rsi,1),%ecx
mov    %ecx,%eax
shr    $0x1f,%eax
add    %ecx,%eax
sar    %eax
ret

LLVM IR (-O0):
define i32 @choose_pivot(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 = add nsw i32 %5, %6
%8 = sdiv i32 %7, 2
ret i32 %8
}

LLVM IR (-O2):
define i32 @choose_pivot(i32 %0, i32 %1) {
%3 = add nsw i32 %1, %0
%4 = sdiv i32 %3, 2
ret i32 %4
}
void nm_isr_handler(void) {
  while (1) {
  }
}


x86 assembly (clang, -O0):
<nm_isr_handler>:
push   %rbp
mov    %rsp,%rbp
jmp    1109 <nm_isr_handler+0x9>
jmp    1109 <nm_isr_handler+0x9>

x86 assembly (clang, -O2):
<nm_isr_handler>:
jmp    1100 <nm_isr_handler>

LLVM IR (-O0):
define void @nm_isr_handler() {
br label %1
1: ; preds = %0, %1
br label %1
}

LLVM IR (-O2):
define void @nm_isr_handler() {
br label %1
1: ; preds = %0, %1
br label %1
}
/* Type definitions */
struct db_query {
  int dummy;
};
typedef int /*<<< orphan*/ sqlite3_stmt;

/* Variables and functions */
int sqlite3_column_count(int /*<<< orphan*/ *);
int db_column_count(struct db_query *query) {
  if (query == NULL)
    return -1;
  return sqlite3_column_count((sqlite3_stmt *)query);
}


x86 assembly (clang, -O0):
<db_column_count>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x10(%rbp)
cmpq   $0x0,-0x10(%rbp)
jne    1133 <db_column_count+0x23>
movl   $0xffffffff,-0x4(%rbp)
jmp    113f <db_column_count+0x2f>
mov    -0x10(%rbp),%rdi
call   1030 <sqlite3_column_count@plt>
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<db_column_count>:
test   %rdi,%rdi
je     111a <db_column_count+0xa>
jmp    1030 <sqlite3_column_count@plt>
mov    $0xffffffff,%eax
ret

LLVM IR (-O0):
%struct.db_query = type { i32 }
define i32 @db_column_count(%struct.db_query* %0) {
%2 = alloca i32
%3 = alloca %struct.db_query*
store %struct.db_query* %0, %struct.db_query** %3
%4 = load %struct.db_query*, %struct.db_query** %3
%5 = icmp eq %struct.db_query* %4, null
br i1 %5, label %6, label %7
6: ; preds = %1
store i32 -1, i32* %2
br label %11
7: ; preds = %1
%8 = load %struct.db_query*, %struct.db_query** %3
%9 = bitcast %struct.db_query* %8 to i32*
%10 = call i32 @sqlite3_column_count(i32* %9)
store i32 %10, i32* %2
br label %11
11: ; preds = %7, %6
%12 = load i32, i32* %2
ret i32 %12
}

LLVM IR (-O2):
%struct.db_query = type { i32 }
define i32 @db_column_count(%struct.db_query* %0) {
%2 = icmp eq %struct.db_query* %0, null
br i1 %2, label %6, label %3
3: ; preds = %1
%4 = getelementptr %struct.db_query, %struct.db_query* %0, i64 0, i32 0
%5 = tail call i32 @sqlite3_column_count(i32* %4)
br label %6
6: ; preds = %1, %3
%7 = phi i32 [ %5, %3 ], [ -1, %1 ]
ret i32 %7
}
/* Variables and functions */
int /*<<< orphan*/ wFree(char *);
int /*<<< orphan*/ wNotYet(char *);
char *wPopString();
void wBasMkDir() {
  char *name;
  name = wPopString();
  wNotYet("MkDir");
  wFree(name);
}


x86 assembly (clang, -O0):
<wBasMkDir>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x0,%al
call   1030 <wPopString@plt>
mov    %rax,-0x8(%rbp)
lea    0xeb6(%rip),%rdi
call   1040 <wNotYet@plt>
mov    -0x8(%rbp),%rdi
call   1050 <wFree@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<wBasMkDir>:
push   %rbx
xor    %eax,%eax
call   1030 <wPopString@plt>
mov    %rax,%rbx
lea    0xebe(%rip),%rdi
call   1040 <wNotYet@plt>
mov    %rbx,%rdi
pop    %rbx
jmp    1050 <wFree@plt>

LLVM IR (-O0):
@.str = [6 x i8] c"MkDir\00"
define void @wBasMkDir() {
%1 = alloca i8*
%2 = call i8* (...) @wPopString()
store i8* %2, i8** %1
%3 = call i32 @wNotYet(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
%4 = load i8*, i8** %1
%5 = call i32 @wFree(i8* %4)
ret void
}

LLVM IR (-O2):
@.str = [6 x i8] c"MkDir\00"
define void @wBasMkDir() {
%1 = tail call i8* (...) @wPopString()
%2 = tail call i32 @wNotYet(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
%3 = tail call i32 @wFree(i8* %1)
ret void
}
void glGenFramebuffers(void) { return; }


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

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

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

LLVM IR (-O2):
define void @glGenFramebuffers() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ mempcpy(char *, int /*<<< orphan*/, int /*<<< orphan*/);
void mempcpy13() {
  char a[4] = {0};
  mempcpy(a, 0, 0);
}


x86 assembly (clang, -O0):
<mempcpy13>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
lea    -0x4(%rbp),%rdi
xor    %esi,%esi
mov    $0x4,%edx
call   1030 <memset@plt>
lea    -0x4(%rbp),%rdi
xor    %edx,%edx
mov    %edx,%esi
call   1040 <mempcpy@plt>
add    $0x10,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
define void @mempcpy13() {
%1 = alloca [4 x i8]
%2 = bitcast [4 x i8]* %1 to i8*
%3 = getelementptr inbounds [4 x i8], [4 x i8]* %1, i64 0, i64 0
%4 = call i32 @mempcpy(i8* %3, i32 0, i32 0)
ret void
}

LLVM IR (-O2):
define void @mempcpy13() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
store i32 0, i32* %1
%3 = call i32 @mempcpy(i8* %2, i32 0, i32 0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ remove(char *);
void mbm_test_cleanup(void) { remove("result_mbm"); }


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

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

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

LLVM IR (-O2):
@.str = [11 x i8] c"result_mbm\00"
define void @mbm_test_cleanup() {
%1 = tail call i32 @remove(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0))
ret void
}
/* Variables and functions */
int _ada_use_c2phc4c(int, int *, int *, double *, int /*<<< orphan*/);
int padcon_get_quaddobl_hessian_step(double *step) {
  int fail;
  int precision = 2;
  int *b;
  fail = _ada_use_c2phc4c(888, &precision, b, step, 0);
  return fail;
}


x86 assembly (clang, -O0):
<padcon_get_quaddobl_hessian_step>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
movl   $0x2,-0x10(%rbp)
mov    -0x18(%rbp),%rdx
mov    -0x8(%rbp),%rcx
mov    $0x378,%edi
lea    -0x10(%rbp),%rsi
xor    %r8d,%r8d
call   1030 <_ada_use_c2phc4c@plt>
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

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

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

LLVM IR (-O2):
define i32 @padcon_get_quaddobl_hessian_step(double* %0) {
%2 = alloca i32
%3 = bitcast i32* %2 to i8*
store i32 2, i32* %2
%4 = call i32 @_ada_use_c2phc4c(i32 888, i32* %2, i32* undef, double* %0, i32 0)
ret i32 %4
}
/* Variables and functions */
bool san_has_capture(const char *SAN) {
  for (const char *ptr = SAN; *ptr != '\0' && *ptr != ' '; ptr++)
    if (*ptr == 'x')
      return true;
  return false;
}


x86 assembly (clang, -O0):
<san_has_capture>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
movsbl (%rax),%ecx
xor    %eax,%eax
cmp    $0x0,%ecx
mov    %al,-0x19(%rbp)
je     1135 <san_has_capture+0x35>
mov    -0x18(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x20,%eax
setne  %al
mov    %al,-0x19(%rbp)
mov    -0x19(%rbp),%al
test   $0x1,%al
jne    1145 <san_has_capture+0x45>
jmp    1177 <san_has_capture+0x77>
mov    -0x18(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x78,%eax
jne    1161 <san_has_capture+0x61>
movl   $0x1,-0x4(%rbp)
jmp    117e <san_has_capture+0x7e>
jmp    1166 <san_has_capture+0x66>
mov    -0x18(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x18(%rbp)
jmp    1110 <san_has_capture+0x10>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<san_has_capture>:
movzbl (%rdi),%eax
test   %al,%al
je     1115 <san_has_capture+0x15>
cmp    $0x20,%al
je     1115 <san_has_capture+0x15>
cmp    $0x78,%al
je     1118 <san_has_capture+0x18>
add    $0x1,%rdi
jmp    1100 <san_has_capture>
xor    %eax,%eax
ret
mov    $0x1,%eax
ret

LLVM IR (-O0):
define i32 @san_has_capture(i8* %0) {
%2 = alloca i32
%3 = alloca i8*
%4 = alloca i8*
store i8* %0, i8** %3
%5 = load i8*, i8** %3
store i8* %5, i8** %4
br label %6
6: ; preds = %25, %1
%7 = load i8*, i8** %4
%8 = load i8, i8* %7
%9 = sext i8 %8 to i32
%10 = icmp ne i32 %9, 0
br i1 %10, label %11, label %16
11: ; preds = %6
%12 = load i8*, i8** %4
%13 = load i8, i8* %12
%14 = sext i8 %13 to i32
%15 = icmp ne i32 %14, 32
br label %16
16: ; preds = %11, %6
%17 = phi i1 [ false, %6 ], [ %15, %11 ]
br i1 %17, label %18, label %28
18: ; preds = %16
%19 = load i8*, i8** %4
%20 = load i8, i8* %19
%21 = sext i8 %20 to i32
%22 = icmp eq i32 %21, 120
br i1 %22, label %23, label %24
23: ; preds = %18
store i32 1, i32* %2
br label %29
24: ; preds = %18
br label %25
25: ; preds = %24
%26 = load i8*, i8** %4
%27 = getelementptr inbounds i8, i8* %26, i32 1
store i8* %27, i8** %4
br label %6
28: ; preds = %16
store i32 0, i32* %2
br label %29
29: ; preds = %28, %23
%30 = load i32, i32* %2
ret i32 %30
}

LLVM IR (-O2):
define i32 @san_has_capture(i8* nocapture %0) {
br label %2
2: ; preds = %5, %1
%3 = phi i8* [ %0, %1 ], [ %6, %5 ]
%4 = load i8, i8* %3
switch i8 %4, label %5 [
i8 0, label %7
i8 32, label %7
i8 120, label %8
]
5: ; preds = %2
%6 = getelementptr inbounds i8, i8* %3, i64 1
br label %2
7: ; preds = %2, %2
br label %8
8: ; preds = %2, %7
%9 = phi i32 [ 0, %7 ], [ 1, %2 ]
ret i32 %9
}
/* Variables and functions */
scalar_t__ strchr(char *, char);
int is_reserved(char in) {
  if (strchr(";/?:@&=+$,{}", in))
    return 1;
  else
    return 0;
}


x86 assembly (clang, -O0):
<is_reserved>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %dil,%al
mov    %al,-0x5(%rbp)
lea    0xedb(%rip),%rdi
movsbl -0x5(%rbp),%esi
call   1030 <strchr@plt>
cmp    $0x0,%rax
je     1144 <is_reserved+0x34>
movl   $0x1,-0x4(%rbp)
jmp    114b <is_reserved+0x3b>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_reserved>:
push   %rax
mov    %edi,%esi
lea    0xee6(%rip),%rdi
call   1030 <strchr@plt>
xor    %ecx,%ecx
test   %rax,%rax
setne  %cl
mov    %ecx,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [13 x i8] c";/?:@&=+$,{}\00"
define i32 @is_reserved(i8 signext %0) {
%2 = alloca i32
%3 = alloca i8
store i8 %0, i8* %3
%4 = load i8, i8* %3
%5 = call i64 @strchr(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i8 signext %4)
%6 = icmp ne i64 %5, 0
br i1 %6, label %7, label %8
7: ; preds = %1
store i32 1, i32* %2
br label %9
8: ; preds = %1
store i32 0, i32* %2
br label %9
9: ; preds = %8, %7
%10 = load i32, i32* %2
ret i32 %10
}

LLVM IR (-O2):
@.str = [13 x i8] c";/?:@&=+$,{}\00"
define i32 @is_reserved(i8 signext %0) {
%2 = tail call i64 @strchr(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i8 signext %0)
%3 = icmp ne i64 %2, 0
%4 = zext i1 %3 to i32
ret i32 %4
}
/* Type definitions */
typedef int /*<<< orphan*/ __m128;

/* Variables and functions */
int /*<<< orphan*/ _mm_max_ps(int /*<<< orphan*/, int /*<<< orphan*/);
__m128 test_mm_max_ps(__m128 A, __m128 B) { return _mm_max_ps(A, B); }


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

x86 assembly (clang, -O2):
<test_mm_max_ps>:
jmp    1030 <_mm_max_ps@plt>

LLVM IR (-O0):
define i32 @test_mm_max_ps(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 = call i32 @_mm_max_ps(i32 %5, i32 %6)
ret i32 %7
}

LLVM IR (-O2):
define i32 @test_mm_max_ps(i32 %0, i32 %1) {
%3 = tail call i32 @_mm_max_ps(i32 %0, i32 %1)
ret i32 %3
}
/* Variables and functions */
int sck_sendf(int, char *, char const *);
int irc_join(int s, const char *data) {
  return sck_sendf(s, "JOIN %s\r\n", data);
}


x86 assembly (clang, -O0):
<irc_join>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x4(%rbp),%edi
mov    -0x10(%rbp),%rdx
lea    0xed3(%rip),%rsi
call   1030 <sck_sendf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<irc_join>:
mov    %rsi,%rdx
lea    0xee6(%rip),%rsi
jmp    1030 <sck_sendf@plt>

LLVM IR (-O0):
@.str = [10 x i8] c"JOIN %s\0D\0A\00"
define i32 @irc_join(i32 %0, i8* %1) {
%3 = alloca i32
%4 = alloca i8*
store i32 %0, i32* %3
store i8* %1, i8** %4
%5 = load i32, i32* %3
%6 = load i8*, i8** %4
%7 = call i32 @sck_sendf(i32 %5, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), i8* %6)
ret i32 %7
}

LLVM IR (-O2):
@.str = [10 x i8] c"JOIN %s\0D\0A\00"
define i32 @irc_join(i32 %0, i8* %1) {
%3 = tail call i32 @sck_sendf(i32 %0, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), i8* %1)
ret i32 %3
}
int main(void) {
  volatile const int ci = 10;
  int *p = (int *)&ci;
  *p = 20;
  printf("*p=%d\n", *p);
  printf("ci=%d\n", ci);
}


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

x86 assembly (clang, -O2):
<main>:
push   %rax
movl   $0xa,0x4(%rsp)
movl   $0x14,0x4(%rsp)
lea    0xed8(%rip),%rdi
mov    $0x14,%esi
xor    %eax,%eax
call   1030 <printf@plt>
mov    0x4(%rsp),%esi
lea    0xec8(%rip),%rdi
xor    %eax,%eax
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [7 x i8] c"*p=%d\0A\00"
@.str.1 = [7 x i8] c"ci=%d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32*
store volatile i32 10, i32* %1
store i32* %1, i32** %2
%3 = load i32*, i32** %2
store i32 20, i32* %3
%4 = load i32*, i32** %2
%5 = load i32, i32* %4
%6 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i32 %5)
%7 = load volatile i32, i32* %1
%8 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 %7)
ret i32 0
}

LLVM IR (-O2):
@.str = [7 x i8] c"*p=%d\0A\00"
@.str.1 = [7 x i8] c"ci=%d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
store volatile i32 10, i32* %1
store i32 20, i32* %1
%3 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i32 20)
%4 = load volatile i32, i32* %1
%5 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 %4)
ret i32 0
}