xunge/DecIR huggingface dataset:
/* Variables and functions */
int my_exit(int);
int main(int argc, char *argv[]) { return my_exit(42); }


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    $0x2a,%edi
call   1030 <my_exit@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
mov    $0x2a,%edi
jmp    1030 <my_exit@plt>

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

LLVM IR (-O2):
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @my_exit(i32 42)
ret i32 %3
}
/* Variables and functions */
int arng(int);
int runAway(int escapingAgility, int chasingAgility) {
  if ((escapingAgility + arng(escapingAgility / 3)) > chasingAgility) {
    return 1;
  } else {
    return 0;
  }
}


x86 assembly (clang, -O0):
<runAway>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0x8(%rbp),%eax
mov    %eax,-0x10(%rbp)
mov    -0x8(%rbp),%eax
mov    $0x3,%ecx
cltd
idiv   %ecx
mov    %eax,%edi
call   1030 <arng@plt>
mov    %eax,%ecx
mov    -0x10(%rbp),%eax
add    %ecx,%eax
cmp    -0xc(%rbp),%eax
jle    1152 <runAway+0x42>
movl   $0x1,-0x4(%rbp)
jmp    1159 <runAway+0x49>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<runAway>:
push   %rbp
push   %rbx
push   %rax
mov    %esi,%ebp
movslq %edi,%rbx
imul   $0x55555556,%rbx,%rdi
mov    %rdi,%rax
shr    $0x3f,%rax
shr    $0x20,%rdi
add    %eax,%edi
call   1030 <arng@plt>
add    %eax,%ebx
xor    %eax,%eax
cmp    %ebp,%ebx
setg   %al
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
define i32 @runAway(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store i32 %0, i32* %4
store i32 %1, i32* %5
%6 = load i32, i32* %4
%7 = load i32, i32* %4
%8 = sdiv i32 %7, 3
%9 = call i32 @arng(i32 %8)
%10 = add nsw i32 %6, %9
%11 = load i32, i32* %5
%12 = icmp sgt i32 %10, %11
br i1 %12, label %13, label %14
13: ; preds = %2
store i32 1, i32* %3
br label %15
14: ; preds = %2
store i32 0, i32* %3
br label %15
15: ; preds = %14, %13
%16 = load i32, i32* %3
ret i32 %16
}

LLVM IR (-O2):
define i32 @runAway(i32 %0, i32 %1) {
%3 = sdiv i32 %0, 3
%4 = tail call i32 @arng(i32 %3)
%5 = add nsw i32 %4, %0
%6 = icmp sgt i32 %5, %1
%7 = zext i1 %6 to i32
ret i32 %7
}
/* Variables and functions */
size_t roundup(size_t var, size_t size) {
  return (var + size - 1) & ~(size - 1);
}


x86 assembly (clang, -O0):
<roundup>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
add    -0x10(%rbp),%rax
sub    $0x1,%rax
mov    -0x10(%rbp),%rcx
sub    $0x1,%rcx
xor    $0xffffffffffffffff,%rcx
and    %rcx,%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<roundup>:
lea    (%rdi,%rsi,1),%rax
add    $0xffffffffffffffff,%rax
neg    %rsi
and    %rsi,%rax
ret

LLVM IR (-O0):
define i64 @roundup(i64 %0, i64 %1) {
%3 = alloca i64
%4 = alloca i64
store i64 %0, i64* %3
store i64 %1, i64* %4
%5 = load i64, i64* %3
%6 = load i64, i64* %4
%7 = add i64 %5, %6
%8 = sub i64 %7, 1
%9 = load i64, i64* %4
%10 = sub i64 %9, 1
%11 = xor i64 %10, -1
%12 = and i64 %8, %11
ret i64 %12
}

LLVM IR (-O2):
define i64 @roundup(i64 %0, i64 %1) {
%3 = add i64 %0, -1
%4 = add i64 %3, %1
%5 = sub i64 0, %1
%6 = and i64 %4, %5
ret i64 %6
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, long);
void PrintCVersion() { printf("C version: %ld\n", 201710L); }


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

x86 assembly (clang, -O2):
<PrintCVersion>:
lea    0xee9(%rip),%rdi
mov    $0x313ee,%esi
jmp    1030 <printf@plt>

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

LLVM IR (-O2):
@.str = [16 x i8] c"C version: %ld\0A\00"
define void @PrintCVersion() {
%1 = tail call i32 @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str, i64 0, i64 0), i64 201710)
ret void
}
void RTSgBufCopy(void) {}


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

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

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

LLVM IR (-O2):
define void @RTSgBufCopy() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ SHUT_RDWR;
int /*<<< orphan*/ close(int);
int /*<<< orphan*/ shutdown(int, int /*<<< orphan*/);
void close_connection(int socket_descriptor) {
  shutdown(socket_descriptor, SHUT_RDWR);
  close(socket_descriptor);
}


x86 assembly (clang, -O0):
<close_connection>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%edi
mov    0x2ebb(%rip),%rax
mov    (%rax),%esi
call   1030 <shutdown@plt>
mov    -0x4(%rbp),%edi
call   1040 <close@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<close_connection>:
push   %rbx
mov    %edi,%ebx
mov    0x2ec6(%rip),%rax
mov    (%rax),%esi
call   1030 <shutdown@plt>
mov    %ebx,%edi
pop    %rbx
jmp    1040 <close@plt>

LLVM IR (-O0):
@SHUT_RDWR = global i32 0
define void @close_connection(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = load i32, i32* @SHUT_RDWR
%5 = call i32 @shutdown(i32 %3, i32 %4)
%6 = load i32, i32* %2
%7 = call i32 @close(i32 %6)
ret void
}

LLVM IR (-O2):
@SHUT_RDWR = global i32 0
define void @close_connection(i32 %0) {
%2 = load i32, i32* @SHUT_RDWR
%3 = tail call i32 @shutdown(i32 %0, i32 %2)
%4 = tail call i32 @close(i32 %0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ write(int, char *, int);
__attribute__((no)) wrmagic(void) {
  write(1, "Yee1Ahwv", sizeof("Yee1Ahwv") - 1);
}


x86 assembly (clang, -O0):
<wrmagic>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x1,%edi
lea    0xedc(%rip),%rsi
mov    $0x8,%edx
call   1030 <write@plt>
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<wrmagic>:
lea    0xee9(%rip),%rsi
mov    $0x1,%edi
mov    $0x8,%edx
jmp    1030 <write@plt>

LLVM IR (-O0):
@.str = [9 x i8] c"Yee1Ahwv\00"
define i32 @wrmagic() {
%1 = alloca i32
%2 = call i32 @write(i32 1, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i32 8)
%3 = load i32, i32* %1
ret i32 %3
}

LLVM IR (-O2):
@.str = [9 x i8] c"Yee1Ahwv\00"
define i32 @wrmagic() {
%1 = tail call i32 @write(i32 1, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i32 8)
ret i32 undef
}
/* Type definitions */
struct bar {
  int dummy;
};

/* Variables and functions */
scalar_t__ error();
int /*<<< orphan*/ free_object(int, short *);
void free_bar(struct bar *b) {
  free_object(58, (short *)b);
  if (error())
    return;
}


x86 assembly (clang, -O0):
<free_bar>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rsi
mov    $0x3a,%edi
call   1030 <free_object@plt>
mov    $0x0,%al
call   1040 <error@plt>
cmp    $0x0,%rax
je     1150 <free_bar+0x30>
jmp    1150 <free_bar+0x30>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<free_bar>:
push   %rax
mov    %rdi,%rsi
mov    $0x3a,%edi
call   1030 <free_object@plt>
xor    %eax,%eax
pop    %rcx
jmp    1040 <error@plt>

LLVM IR (-O0):
%struct.bar = type { i32 }
define void @free_bar(%struct.bar* %0) {
%2 = alloca %struct.bar*
store %struct.bar* %0, %struct.bar** %2
%3 = load %struct.bar*, %struct.bar** %2
%4 = bitcast %struct.bar* %3 to i16*
%5 = call i32 @free_object(i32 58, i16* %4)
%6 = call i64 (...) @error()
%7 = icmp ne i64 %6, 0
br i1 %7, label %8, label %9
8: ; preds = %1
br label %9
9: ; preds = %8, %1
ret void
}

LLVM IR (-O2):
%struct.bar = type { i32 }
define void @free_bar(%struct.bar* %0) {
%2 = bitcast %struct.bar* %0 to i16*
%3 = tail call i32 @free_object(i32 58, i16* %2)
%4 = tail call i64 (...) @error()
ret void
}
/* Variables and functions */
int errno;
int errno_non_zero() {
  int last_error = errno;
  return last_error > 0 ? last_error : -1;
}


x86 assembly (clang, -O0):
<errno_non_zero>:
push   %rbp
mov    %rsp,%rbp
mov    0x2ed5(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x4(%rbp)
cmpl   $0x0,-0x4(%rbp)
jle    1125 <errno_non_zero+0x25>
mov    -0x4(%rbp),%eax
mov    %eax,-0x8(%rbp)
jmp    1132 <errno_non_zero+0x32>
mov    $0xffffffff,%eax
mov    %eax,-0x8(%rbp)
jmp    1132 <errno_non_zero+0x32>
mov    -0x8(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<errno_non_zero>:
mov    0x2ed9(%rip),%rax
mov    (%rax),%ecx
test   %ecx,%ecx
mov    $0xffffffff,%eax
cmovg  %ecx,%eax
ret

LLVM IR (-O0):
@errno = global i32 0
define i32 @errno_non_zero() {
%1 = alloca i32
%2 = load i32, i32* @errno
store i32 %2, i32* %1
%3 = load i32, i32* %1
%4 = icmp sgt i32 %3, 0
br i1 %4, label %5, label %7
5: ; preds = %0
%6 = load i32, i32* %1
br label %8
7: ; preds = %0
br label %8
8: ; preds = %7, %5
%9 = phi i32 [ %6, %5 ], [ -1, %7 ]
ret i32 %9
}

LLVM IR (-O2):
@errno = global i32 0
define i32 @errno_non_zero() {
%1 = load i32, i32* @errno
%2 = icmp sgt i32 %1, 0
%3 = select i1 %2, i32 %1, i32 -1
ret i32 %3
}
int Mini_LutNodeConst1() { return 1; }


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

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

LLVM IR (-O0):
define i32 @Mini_LutNodeConst1() {
ret i32 1
}

LLVM IR (-O2):
define i32 @Mini_LutNodeConst1() {
ret i32 1
}
void free_2d_matrix(double **M) {
  free(M[0]);
  free(M);
}


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

x86 assembly (clang, -O2):
<free_2d_matrix>:
push   %rbx
mov    %rdi,%rbx
mov    (%rdi),%rdi
call   1030 <free@plt>
mov    %rbx,%rdi
pop    %rbx
jmp    1030 <free@plt>

LLVM IR (-O0):
define void @free_2d_matrix(double** %0) {
%2 = alloca double**
store double** %0, double*** %2
%3 = load double**, double*** %2
%4 = getelementptr inbounds double*, double** %3, i64 0
%5 = load double*, double** %4
%6 = bitcast double* %5 to i8*
%7 = load double**, double*** %2
%8 = bitcast double** %7 to i8*
ret void
}

LLVM IR (-O2):
define void @free_2d_matrix(double** nocapture %0) {
%2 = bitcast double** %0 to i8**
%3 = load i8*, i8** %2
tail call void @free(i8* %3)
%4 = bitcast double** %0 to i8*
tail call void @free(i8* %4)
ret void
}
/* Type definitions */
typedef unsigned long volatile uint32_t;

/* Variables and functions */
uint32_t TimerADCEventGet(uint32_t ui32Base) {
  ;
  return ((*((volatile unsigned long *)(ui32Base + 0x00000070))));
}


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

x86 assembly (clang, -O2):
<TimerADCEventGet>:
mov    %rdi,-0x8(%rsp)
mov    -0x8(%rsp),%rax
mov    0x70(%rax),%rax
ret

LLVM IR (-O0):
define i64 @TimerADCEventGet(i64 %0) {
%2 = alloca i64
store volatile i64 %0, i64* %2
%3 = load volatile i64, i64* %2
%4 = add i64 %3, 112
%5 = inttoptr i64 %4 to i64*
%6 = load volatile i64, i64* %5
ret i64 %6
}

LLVM IR (-O2):
define i64 @TimerADCEventGet(i64 %0) {
%2 = alloca i64
store volatile i64 %0, i64* %2
%3 = load volatile i64, i64* %2
%4 = add i64 %3, 112
%5 = inttoptr i64 %4 to i64*
%6 = load volatile i64, i64* %5
ret i64 %6
}
/* Variables and functions */
int /*<<< orphan*/ setloc(int);
void pdata(void) { setloc(3); }


x86 assembly (clang, -O0):
<pdata>:
push   %rbp
mov    %rsp,%rbp
mov    $0x3,%edi
call   1030 <setloc@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<pdata>:
mov    $0x3,%edi
jmp    1030 <setloc@plt>

LLVM IR (-O0):
define void @pdata() {
%1 = call i32 @setloc(i32 3)
ret void
}

LLVM IR (-O2):
define void @pdata() {
%1 = tail call i32 @setloc(i32 3)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ MAIN__();
int main(int argc, char **argv) {
  MAIN__();
  return 0;
}


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

x86 assembly (clang, -O2):
<main>:
push   %rax
xor    %eax,%eax
call   1030 <MAIN__@plt>
xor    %eax,%eax
pop    %rcx
ret

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

LLVM IR (-O2):
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 (...) @MAIN__()
ret i32 0
}
int test_imm_A0int8_mem(signed char *val) {
  return ((*val) & (0xA0 << 0)) ? -20 : -40;
}


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

x86 assembly (clang, -O2):
<test_imm_A0int8_mem>:
testb  $0xa0,(%rdi)
mov    $0xffffffd8,%ecx
mov    $0xffffffec,%eax
cmove  %ecx,%eax
ret

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

LLVM IR (-O2):
define i32 @test_imm_A0int8_mem(i8* nocapture %0) {
%2 = load i8, i8* %0
%3 = and i8 %2, -96
%4 = icmp eq i8 %3, 0
%5 = select i1 %4, i32 -40, i32 -20
ret i32 %5
}
/* Type definitions */
struct timeval {
  unsigned long tv_sec;
  unsigned long tv_usec;
};

/* Variables and functions */
unsigned long time_elapsed(const struct timeval *last,
                           const struct timeval *current) {
  unsigned long secs, diff;
  secs = current->tv_sec - last->tv_sec;
  diff = 1000000 * secs + current->tv_usec - last->tv_usec;
  return (diff);
}


x86 assembly (clang, -O0):
<time_elapsed>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
mov    (%rax),%rax
mov    -0x8(%rbp),%rcx
sub    (%rcx),%rax
mov    %rax,-0x18(%rbp)
imul   $0xf4240,-0x18(%rbp),%rax
mov    -0x10(%rbp),%rcx
add    0x8(%rcx),%rax
mov    -0x8(%rbp),%rcx
sub    0x8(%rcx),%rax
mov    %rax,-0x20(%rbp)
mov    -0x20(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<time_elapsed>:
mov    (%rsi),%rax
sub    (%rdi),%rax
imul   $0xf4240,%rax,%rax
add    0x8(%rsi),%rax
sub    0x8(%rdi),%rax
ret

LLVM IR (-O0):
%struct.timeval = type { i64, i64 }
define i64 @time_elapsed(%struct.timeval* %0, %struct.timeval* %1) {
%3 = alloca %struct.timeval*
%4 = alloca %struct.timeval*
%5 = alloca i64
%6 = alloca i64
store %struct.timeval* %0, %struct.timeval** %3
store %struct.timeval* %1, %struct.timeval** %4
%7 = load %struct.timeval*, %struct.timeval** %4
%8 = getelementptr inbounds %struct.timeval, %struct.timeval* %7, i32 0, i32 0
%9 = load i64, i64* %8
%10 = load %struct.timeval*, %struct.timeval** %3
%11 = getelementptr inbounds %struct.timeval, %struct.timeval* %10, i32 0, i32 0
%12 = load i64, i64* %11
%13 = sub i64 %9, %12
store i64 %13, i64* %5
%14 = load i64, i64* %5
%15 = mul i64 1000000, %14
%16 = load %struct.timeval*, %struct.timeval** %4
%17 = getelementptr inbounds %struct.timeval, %struct.timeval* %16, i32 0, i32 1
%18 = load i64, i64* %17
%19 = add i64 %15, %18
%20 = load %struct.timeval*, %struct.timeval** %3
%21 = getelementptr inbounds %struct.timeval, %struct.timeval* %20, i32 0, i32 1
%22 = load i64, i64* %21
%23 = sub i64 %19, %22
store i64 %23, i64* %6
%24 = load i64, i64* %6
ret i64 %24
}

LLVM IR (-O2):
%struct.timeval = type { i64, i64 }
define i64 @time_elapsed(%struct.timeval* nocapture %0, %struct.timeval* nocapture %1) {
%3 = getelementptr inbounds %struct.timeval, %struct.timeval* %1, i64 0, i32 0
%4 = load i64, i64* %3
%5 = getelementptr inbounds %struct.timeval, %struct.timeval* %0, i64 0, i32 0
%6 = load i64, i64* %5
%7 = sub i64 %4, %6
%8 = mul i64 %7, 1000000
%9 = getelementptr inbounds %struct.timeval, %struct.timeval* %1, i64 0, i32 1
%10 = load i64, i64* %9
%11 = add i64 %8, %10
%12 = getelementptr inbounds %struct.timeval, %struct.timeval* %0, i64 0, i32 1
%13 = load i64, i64* %12
%14 = sub i64 %11, %13
ret i64 %14
}
/* Variables and functions */
int _ada_use_c2phc4c(int, int *, int *, double *, int /*<<< orphan*/);
int create_dobldobl_homotopy_with_given_gamma(double gamma_re,
                                              double gamma_im) {
  int *a, *b, fail;
  double c[2];
  c[0] = gamma_re;
  c[1] = gamma_im;
  fail = _ada_use_c2phc4c(173, a, b, c, 0);
  return fail;
}


x86 assembly (clang, -O0):
<create_dobldobl_homotopy_with_given_gamma>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
movsd  -0x8(%rbp),%xmm0
movsd  %xmm0,-0x40(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  %xmm0,-0x38(%rbp)
mov    -0x18(%rbp),%rsi
mov    -0x20(%rbp),%rdx
lea    -0x40(%rbp),%rcx
mov    $0xad,%edi
xor    %r8d,%r8d
call   1030 <_ada_use_c2phc4c@plt>
mov    %eax,-0x24(%rbp)
mov    -0x24(%rbp),%eax
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<create_dobldobl_homotopy_with_given_gamma>:
sub    $0x18,%rsp
movsd  %xmm0,(%rsp)
movsd  %xmm1,0x8(%rsp)
mov    %rsp,%rcx
mov    $0xad,%edi
xor    %r8d,%r8d
call   1030 <_ada_use_c2phc4c@plt>
add    $0x18,%rsp
ret

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

LLVM IR (-O2):
define i32 @create_dobldobl_homotopy_with_given_gamma(double %0, double %1) {
%3 = alloca [2 x double]
%4 = bitcast [2 x double]* %3 to i8*
%5 = getelementptr inbounds [2 x double], [2 x double]* %3, i64 0, i64 0
store double %0, double* %5
%6 = getelementptr inbounds [2 x double], [2 x double]* %3, i64 0, i64 1
store double %1, double* %6
%7 = call i32 @_ada_use_c2phc4c(i32 173, i32* undef, i32* undef, double* %5, i32 0)
ret i32 %7
}
int isLowercaseLetter(char c) {
  if ('a' <= c && c <= 'z') {
    return 1;
  } else {
    return 0;
  }
}


x86 assembly (clang, -O0):
<isLowercaseLetter>:
push   %rbp
mov    %rsp,%rbp
mov    %dil,%al
mov    %al,-0x5(%rbp)
movsbl -0x5(%rbp),%ecx
mov    $0x61,%eax
cmp    %ecx,%eax
jg     1134 <isLowercaseLetter+0x34>
movsbl -0x5(%rbp),%eax
cmp    $0x7a,%eax
jg     1134 <isLowercaseLetter+0x34>
movl   $0x1,-0x4(%rbp)
jmp    113b <isLowercaseLetter+0x3b>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<isLowercaseLetter>:
add    $0x9f,%dil
xor    %eax,%eax
cmp    $0x1a,%dil
setb   %al
ret

LLVM IR (-O0):
define i32 @isLowercaseLetter(i8 signext %0) {
%2 = alloca i32
%3 = alloca i8
store i8 %0, i8* %3
%4 = load i8, i8* %3
%5 = sext i8 %4 to i32
%6 = icmp sle i32 97, %5
br i1 %6, label %7, label %12
7: ; preds = %1
%8 = load i8, i8* %3
%9 = sext i8 %8 to i32
%10 = icmp sle i32 %9, 122
br i1 %10, label %11, label %12
11: ; preds = %7
store i32 1, i32* %2
br label %13
12: ; preds = %7, %1
store i32 0, i32* %2
br label %13
13: ; preds = %12, %11
%14 = load i32, i32* %2
ret i32 %14
}

LLVM IR (-O2):
define i32 @isLowercaseLetter(i8 signext %0) {
%2 = add i8 %0, -97
%3 = icmp ult i8 %2, 26
%4 = zext i1 %3 to i32
ret i32 %4
}
int use_int(int i) {
  int a = i + 3;
  return a;
}


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

x86 assembly (clang, -O2):
<use_int>:
lea    0x3(%rdi),%eax
ret

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

LLVM IR (-O2):
define i32 @use_int(i32 %0) {
%2 = add nsw i32 %0, 3
ret i32 %2
}
/* Variables and functions */
scalar_t__ const_time_select(unsigned char, unsigned char, unsigned char);
unsigned char const_time_select_u8(unsigned char mask, unsigned char true_val,
                                   unsigned char false_val) {
  return (unsigned char)const_time_select(mask, true_val, false_val);
}


x86 assembly (clang, -O0):
<const_time_select_u8>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %dl,%al
mov    %sil,%cl
mov    %dil,%dl
mov    %dl,-0x1(%rbp)
mov    %cl,-0x2(%rbp)
mov    %al,-0x3(%rbp)
mov    -0x1(%rbp),%cl
mov    -0x2(%rbp),%al
movzbl %cl,%edi
movzbl %al,%esi
movzbl -0x3(%rbp),%edx
call   1030 <const_time_select@plt>
movzbl %al,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<const_time_select_u8>:
push   %rax
call   1030 <const_time_select@plt>
pop    %rcx
ret

LLVM IR (-O0):
define zeroext i8 @const_time_select_u8(i8 zeroext %0, i8 zeroext %1, i8 zeroext %2) {
%4 = alloca i8
%5 = alloca i8
%6 = alloca i8
store i8 %0, i8* %4
store i8 %1, i8* %5
store i8 %2, i8* %6
%7 = load i8, i8* %4
%8 = load i8, i8* %5
%9 = load i8, i8* %6
%10 = call i64 @const_time_select(i8 zeroext %7, i8 zeroext %8, i8 zeroext %9)
%11 = trunc i64 %10 to i8
ret i8 %11
}

LLVM IR (-O2):
define zeroext i8 @const_time_select_u8(i8 zeroext %0, i8 zeroext %1, i8 zeroext %2) {
%4 = tail call i64 @const_time_select(i8 zeroext %0, i8 zeroext %1, i8 zeroext %2)
%5 = trunc i64 %4 to i8
ret i8 %5
}
/* Variables and functions */
int /*<<< orphan*/ adjustment();
int /*<<< orphan*/ jimp();
int /*<<< orphan*/ jomp();
int /*<<< orphan*/ overcoat();
int /*<<< orphan*/ soso();
int /*<<< orphan*/ tractor();
void wolverine() {
  adjustment();
  soso();
  overcoat();
  tractor();
  jimp();
  jomp();
}


x86 assembly (clang, -O0):
<wolverine>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1030 <adjustment@plt>
mov    $0x0,%al
call   1070 <soso@plt>
mov    $0x0,%al
call   1040 <overcoat@plt>
mov    $0x0,%al
call   1080 <tractor@plt>
mov    $0x0,%al
call   1060 <jimp@plt>
mov    $0x0,%al
call   1050 <jomp@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<wolverine>:
push   %rax
xor    %eax,%eax
call   1030 <adjustment@plt>
xor    %eax,%eax
call   1070 <soso@plt>
xor    %eax,%eax
call   1040 <overcoat@plt>
xor    %eax,%eax
call   1080 <tractor@plt>
xor    %eax,%eax
call   1060 <jimp@plt>
xor    %eax,%eax
pop    %rcx
jmp    1050 <jomp@plt>

LLVM IR (-O0):
define void @wolverine() {
%1 = call i32 (...) @adjustment()
%2 = call i32 (...) @soso()
%3 = call i32 (...) @overcoat()
%4 = call i32 (...) @tractor()
%5 = call i32 (...) @jimp()
%6 = call i32 (...) @jomp()
ret void
}

LLVM IR (-O2):
define void @wolverine() {
%1 = tail call i32 (...) @adjustment()
%2 = tail call i32 (...) @soso()
%3 = tail call i32 (...) @overcoat()
%4 = tail call i32 (...) @tractor()
%5 = tail call i32 (...) @jimp()
%6 = tail call i32 (...) @jomp()
ret void
}
/* Type definitions */
struct sockaddr_in {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ printf(char *, char *);
int /*<<< orphan*/ read(int, char *, int);
int /*<<< orphan*/ write(int, char *, int);
int net_callback(int sock, struct sockaddr_in *from, void *params) {
  char buffer[256];
  write(sock, "tcp server\n", 11);
  read(sock, buffer, 255);
  printf("%s\n", buffer);
  return 0;
}


x86 assembly (clang, -O0):
<net_callback>:
push   %rbp
mov    %rsp,%rbp
sub    $0x120,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x4(%rbp),%edi
lea    0xeb0(%rip),%rsi
mov    $0xb,%edx
call   1030 <write@plt>
mov    -0x4(%rbp),%edi
lea    -0x120(%rbp),%rsi
mov    $0xff,%edx
call   1050 <read@plt>
lea    -0x120(%rbp),%rsi
lea    0xe90(%rip),%rdi
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x120,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<net_callback>:
push   %r14
push   %rbx
sub    $0x108,%rsp
mov    %edi,%ebx
lea    0xebd(%rip),%rsi
mov    $0xb,%edx
call   1030 <write@plt>
mov    %rsp,%r14
mov    %ebx,%edi
mov    %r14,%rsi
mov    $0xff,%edx
call   1050 <read@plt>
lea    0xea6(%rip),%rdi
mov    %r14,%rsi
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x108,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
%struct.sockaddr_in = type { i32 }
@.str = [12 x i8] c"tcp server\0A\00"
@.str.1 = [4 x i8] c"%s\0A\00"
define i32 @net_callback(i32 %0, %struct.sockaddr_in* %1, i8* %2) {
%4 = alloca i32
%5 = alloca %struct.sockaddr_in*
%6 = alloca i8*
%7 = alloca [256 x i8]
store i32 %0, i32* %4
store %struct.sockaddr_in* %1, %struct.sockaddr_in** %5
store i8* %2, i8** %6
%8 = load i32, i32* %4
%9 = call i32 @write(i32 %8, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0), i32 11)
%10 = load i32, i32* %4
%11 = getelementptr inbounds [256 x i8], [256 x i8]* %7, i64 0, i64 0
%12 = call i32 @read(i32 %10, i8* %11, i32 255)
%13 = getelementptr inbounds [256 x i8], [256 x i8]* %7, i64 0, i64 0
%14 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* %13)
ret i32 0
}

LLVM IR (-O2):
%struct.sockaddr_in = type { i32 }
@.str = [12 x i8] c"tcp server\0A\00"
@.str.1 = [4 x i8] c"%s\0A\00"
define i32 @net_callback(i32 %0, %struct.sockaddr_in* nocapture readnone %1, i8* nocapture readnone %2) {
%4 = alloca [256 x i8]
%5 = getelementptr inbounds [256 x i8], [256 x i8]* %4, i64 0, i64 0
%6 = tail call i32 @write(i32 %0, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0), i32 11)
%7 = call i32 @read(i32 %0, i8* %5, i32 255)
%8 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* %5)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
void exitA12() { printf("A12\n"); }


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

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

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

LLVM IR (-O2):
@str = [4 x i8] c"A12\00"
define void @exitA12() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @str, i64 0, i64 0))
ret void
}
/* Type definitions */
struct bufferevent {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ bufferevent_free(struct bufferevent *);
int AMCBufferevent_Free(struct bufferevent *buffEv) {
  bufferevent_free(buffEv);
  return 0;
}


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

x86 assembly (clang, -O2):
<AMCBufferevent_Free>:
push   %rax
call   1030 <bufferevent_free@plt>
xor    %eax,%eax
pop    %rcx
ret

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

LLVM IR (-O2):
%struct.bufferevent = type { i32 }
define i32 @AMCBufferevent_Free(%struct.bufferevent* %0) {
%2 = tail call i32 @bufferevent_free(%struct.bufferevent* %0)
ret i32 0
}
int test_imm_60uint64_highword_reg(unsigned long long val) {
  return ((val >> 32) & (0x60 << 0)) ? -20 : -40;
}


x86 assembly (clang, -O0):
<test_imm_60uint64_highword_reg>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdx
shr    $0x20,%rdx
and    $0x60,%rdx
mov    $0xffffffd8,%eax
mov    $0xffffffec,%ecx
cmp    $0x0,%rdx
cmovne %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_imm_60uint64_highword_reg>:
movabs $0x6000000000,%rax
test   %rax,%rdi
mov    $0xffffffd8,%ecx
mov    $0xffffffec,%eax
cmove  %ecx,%eax
ret

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

LLVM IR (-O2):
define i32 @test_imm_60uint64_highword_reg(i64 %0) {
%2 = and i64 %0, 412316860416
%3 = icmp eq i64 %2, 0
%4 = select i1 %3, i32 -40, i32 -20
ret i32 %4
}
/* Variables and functions */
int /*<<< orphan*/ utempter_remove_added_record();
void removeFromUtmp(void) { utempter_remove_added_record(); }


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

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

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

LLVM IR (-O2):
define void @removeFromUtmp() {
%1 = tail call i32 (...) @utempter_remove_added_record()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ ASL16(int /*<<< orphan*/, int);
int /*<<< orphan*/ AbsoluteIndexedXX0(int);
void Op1EM0X0(void) { ASL16(AbsoluteIndexedXX0(3), 0xFFFFFF); }


x86 assembly (clang, -O0):
<Op1EM0X0>:
push   %rbp
mov    %rsp,%rbp
mov    $0x3,%edi
call   1030 <AbsoluteIndexedXX0@plt>
mov    %eax,%edi
mov    $0xffffff,%esi
call   1040 <ASL16@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<Op1EM0X0>:
push   %rax
mov    $0x3,%edi
call   1030 <AbsoluteIndexedXX0@plt>
mov    %eax,%edi
mov    $0xffffff,%esi
pop    %rax
jmp    1040 <ASL16@plt>

LLVM IR (-O0):
define void @Op1EM0X0() {
%1 = call i32 @AbsoluteIndexedXX0(i32 3)
%2 = call i32 @ASL16(i32 %1, i32 16777215)
ret void
}

LLVM IR (-O2):
define void @Op1EM0X0() {
%1 = tail call i32 @AbsoluteIndexedXX0(i32 3)
%2 = tail call i32 @ASL16(i32 %1, i32 16777215)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ outb(int, int /*<<< orphan*/);
void iowait() { outb(0x80, 0); }


x86 assembly (clang, -O0):
<iowait>:
push   %rbp
mov    %rsp,%rbp
mov    $0x80,%edi
xor    %esi,%esi
call   1030 <outb@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<iowait>:
mov    $0x80,%edi
xor    %esi,%esi
jmp    1030 <outb@plt>

LLVM IR (-O0):
define void @iowait() {
%1 = call i32 @outb(i32 128, i32 0)
ret void
}

LLVM IR (-O2):
define void @iowait() {
%1 = tail call i32 @outb(i32 128, i32 0)
ret void
}
int str_len3(char *s) {
  char *p = s;
  while (*p++ != '\0')
    ;
  return p - s;
}


x86 assembly (clang, -O0):
<str_len3>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x10(%rbp)
movsbl (%rax),%eax
cmp    $0x0,%eax
je     1130 <str_len3+0x30>
jmp    1110 <str_len3+0x10>
mov    -0x10(%rbp),%rax
mov    -0x8(%rbp),%rcx
sub    %rcx,%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<str_len3>:
xor    %eax,%eax
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
cmpb   $0x0,(%rdi,%rax,1)
lea    0x1(%rax),%rax
jne    1110 <str_len3+0x10>
ret

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

LLVM IR (-O2):
define i32 @str_len3(i8* %0) {
br label %2
2: ; preds = %2, %1
%3 = phi i8* [ %0, %1 ], [ %4, %2 ]
%4 = getelementptr inbounds i8, i8* %3, i64 1
%5 = load i8, i8* %3
%6 = icmp eq i8 %5, 0
br i1 %6, label %7, label %2
7: ; preds = %2
%8 = ptrtoint i8* %4 to i64
%9 = ptrtoint i8* %0 to i64
%10 = sub i64 %8, %9
%11 = trunc i64 %10 to i32
ret i32 %11
}
/* Variables and functions */
int /*<<< orphan*/ sscanf(char *, char const *, void *);
scalar_t__ strlen(char const *);
char *strstr(char const *, char const *);
void cr_parseinfo(const char *info, const char *field, const char *format,
                  void *storage) {
  char *str = strstr(info, field);
  if (str) {
    str += strlen(field) + 1;
    sscanf(str, format, storage);
  }
}


x86 assembly (clang, -O0):
<cr_parseinfo>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1050 <strstr@plt>
mov    %rax,-0x28(%rbp)
cmpq   $0x0,-0x28(%rbp)
je     118a <cr_parseinfo+0x5a>
mov    -0x10(%rbp),%rdi
call   1030 <strlen@plt>
add    $0x1,%rax
add    -0x28(%rbp),%rax
mov    %rax,-0x28(%rbp)
mov    -0x28(%rbp),%rdi
mov    -0x18(%rbp),%rsi
mov    -0x20(%rbp),%rdx
call   1040 <sscanf@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<cr_parseinfo>:
push   %r15
push   %r14
push   %r12
push   %rbx
push   %rax
mov    %rcx,%r14
mov    %rdx,%r15
mov    %rsi,%r12
call   1050 <strstr@plt>
test   %rax,%rax
je     1174 <cr_parseinfo+0x44>
mov    %rax,%rbx
mov    %r12,%rdi
call   1030 <strlen@plt>
lea    (%rax,%rbx,1),%rdi
add    $0x1,%rdi
mov    %r15,%rsi
mov    %r14,%rdx
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
jmp    1040 <sscanf@plt>
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret

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

LLVM IR (-O2):
define void @cr_parseinfo(i8* %0, i8* nocapture %1, i8* nocapture %2, i8* %3) {
%5 = tail call i8* @strstr(i8* dereferenceable(1) %0, i8* dereferenceable(1) %1)
%6 = icmp eq i8* %5, null
br i1 %6, label %12, label %7
7: ; preds = %4
%8 = tail call i64 @strlen(i8* dereferenceable(1) %1)
%9 = add nsw i64 %8, 1
%10 = getelementptr inbounds i8, i8* %5, i64 %9
%11 = tail call i32 @sscanf(i8* %10, i8* %2, i8* %3)
br label %12
12: ; preds = %7, %4
ret void
}
void marker(void) {}


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

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

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

LLVM IR (-O2):
define void @marker() {
ret void
}
long tell(f)
int f;
{ return (lseek(f, 0L, 1)); }


x86 assembly (clang, -O0):
<tell>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%edi
xor    %eax,%eax
mov    %eax,%esi
mov    $0x1,%edx
mov    $0x0,%al
call   1030 <lseek@plt>
cltq
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<tell>:
push   %rax
xor    %esi,%esi
mov    $0x1,%edx
xor    %eax,%eax
call   1030 <lseek@plt>
cltq
pop    %rcx
ret

LLVM IR (-O0):
define i64 @tell(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = call i32 (i32, i64, i32, ...) bitcast (i32 (...)* @lseek to i32 (i32, i64, i32, ...)*)(i32 %3, i64 0, i32 1)
%5 = sext i32 %4 to i64
ret i64 %5
}

LLVM IR (-O2):
define i64 @tell(i32 %0) {
%2 = tail call i32 (i32, i64, i32, ...) bitcast (i32 (...)* @lseek to i32 (i32, i64, i32, ...)*)(i32 %0, i64 0, i32 1)
%3 = sext i32 %2 to i64
ret i64 %3
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
void pci_config_write_long(unsigned char bus, unsigned char dev, int func,
                           unsigned cmd, long val) {
  printf("pci_config_write_long: generic function call\n");
}


x86 assembly (clang, -O0):
<pci_config_write_long>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %sil,%al
mov    %dil,%sil
mov    %sil,-0x1(%rbp)
mov    %al,-0x2(%rbp)
mov    %edx,-0x8(%rbp)
mov    %ecx,-0xc(%rbp)
mov    %r8,-0x18(%rbp)
lea    0xeca(%rip),%rdi
call   1030 <printf@plt>
add    $0x20,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
@.str = [46 x i8] c"pci_config_write_long: generic function call\0A\00"
define void @pci_config_write_long(i8 zeroext %0, i8 zeroext %1, i32 %2, i32 %3, i64 %4) {
%6 = alloca i8
%7 = alloca i8
%8 = alloca i32
%9 = alloca i32
%10 = alloca i64
store i8 %0, i8* %6
store i8 %1, i8* %7
store i32 %2, i32* %8
store i32 %3, i32* %9
store i64 %4, i64* %10
%11 = call i32 @printf(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@str = [45 x i8] c"pci_config_write_long: generic function call\00"
define void @pci_config_write_long(i8 zeroext %0, i8 zeroext %1, i32 %2, i32 %3, i64 %4) {
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([45 x i8], [45 x i8]* @str, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ indigoFree(int);
int indigoLoadQueryMolecule(int);
int indigoReadFile(char const *);
__attribute__((visibility("default"))) int
indigoLoadQueryMoleculeFromFile(const char *filename) {
  int source = indigoReadFile(filename);
  int result;
  if (source <= 0)
    return -1;
  result = indigoLoadQueryMolecule(source);
  indigoFree(source);
  return result;
}


x86 assembly (clang, -O0):
<indigoLoadQueryMoleculeFromFile>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
call   1030 <indigoReadFile@plt>
mov    %eax,-0x14(%rbp)
cmpl   $0x0,-0x14(%rbp)
jg     115e <indigoLoadQueryMoleculeFromFile+0x2e>
movl   $0xffffffff,-0x4(%rbp)
jmp    1177 <indigoLoadQueryMoleculeFromFile+0x47>
mov    -0x14(%rbp),%edi
call   1050 <indigoLoadQueryMolecule@plt>
mov    %eax,-0x18(%rbp)
mov    -0x14(%rbp),%edi
call   1040 <indigoFree@plt>
mov    -0x18(%rbp),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<indigoLoadQueryMoleculeFromFile>:
push   %rbp
push   %rbx
push   %rax
call   1030 <indigoReadFile@plt>
test   %eax,%eax
jle    1152 <indigoLoadQueryMoleculeFromFile+0x22>
mov    %eax,%ebx
mov    %eax,%edi
call   1050 <indigoLoadQueryMolecule@plt>
mov    %eax,%ebp
mov    %ebx,%edi
call   1040 <indigoFree@plt>
mov    %ebp,%eax
jmp    1157 <indigoLoadQueryMoleculeFromFile+0x27>
mov    $0xffffffff,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

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

LLVM IR (-O2):
define i32 @indigoLoadQueryMoleculeFromFile(i8* %0) {
%2 = tail call i32 @indigoReadFile(i8* %0)
%3 = icmp slt i32 %2, 1
br i1 %3, label %7, label %4
4: ; preds = %1
%5 = tail call i32 @indigoLoadQueryMolecule(i32 %2)
%6 = tail call i32 @indigoFree(i32 %2)
br label %7
7: ; preds = %1, %4
%8 = phi i32 [ %5, %4 ], [ -1, %1 ]
ret i32 %8
}
/* Variables and functions */
int /*<<< orphan*/ free(int *);
void freeList(int *ptr) { free(ptr); }


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

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

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

LLVM IR (-O2):
define void @freeList(i32* nocapture %0) {
%2 = tail call i32 @free(i32* %0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ HplAtm128GeneralIOPinP__8__IO__set();
void HplCC2420SpiP__SS__set(void) { HplAtm128GeneralIOPinP__8__IO__set(); }


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

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

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

LLVM IR (-O2):
define void @HplCC2420SpiP__SS__set() {
%1 = tail call i32 (...) @HplAtm128GeneralIOPinP__8__IO__set()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ create_letter_distribution_diagram(char *);
int /*<<< orphan*/ scanf(char *, char *);
int main() {
  char StringArray[1000];
  scanf("%[^\n]s", StringArray);
  create_letter_distribution_diagram(StringArray);
  return 0;
}


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

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

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

LLVM IR (-O2):
@.str = [7 x i8] c"%[^\0A]s\00"
define i32 @main() {
%1 = alloca [1000 x i8]
%2 = getelementptr inbounds [1000 x i8], [1000 x i8]* %1, i64 0, i64 0
%3 = call i32 @scanf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i8* %2)
%4 = call i32 @create_letter_distribution_diagram(i8* %2)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int, int);
int /*<<< orphan*/ scanf(char *, int *);
int main() {
  int n1, n2;
  scanf("%d", &n1);
  scanf("%d", &n2);
  printf("%d e %d\n", n1, n2);
  return 0;
}


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

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

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

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
@.str.1 = [9 x i8] c"%d e %d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = bitcast i32* %1 to i8*
%4 = bitcast i32* %2 to i8*
%5 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %1)
%6 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %2)
%7 = load i32, i32* %1
%8 = load i32, i32* %2
%9 = call i32 @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i32 %7, i32 %8)
ret i32 0
}
/* Type definitions */
struct tms {
  scalar_t__ tms_utime;
  scalar_t__ tms_stime;
};
typedef scalar_t__ clock_t;

/* Variables and functions */
scalar_t__ times(struct tms *);
clock_t clock(void) {
  struct tms t;
  if (times(&t) == (clock_t)-1)
    return (clock_t)-1;
  return t.tms_utime + t.tms_stime;
}


x86 assembly (clang, -O0):
<clock>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
lea    -0x18(%rbp),%rdi
call   1030 <times@plt>
cmp    $0xffffffffffffffff,%rax
jne    1138 <clock+0x28>
movq   $0xffffffffffffffff,-0x8(%rbp)
ff
jmp    1144 <clock+0x34>
mov    -0x18(%rbp),%rax
add    -0x10(%rbp),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<clock>:
sub    $0x18,%rsp
lea    0x8(%rsp),%rdi
call   1030 <times@plt>
mov    0x10(%rsp),%rcx
add    0x8(%rsp),%rcx
cmp    $0xffffffffffffffff,%rax
cmovne %rcx,%rax
add    $0x18,%rsp
ret

LLVM IR (-O0):
%struct.tms = type { i64, i64 }
define i64 @clock() {
%1 = alloca i64
%2 = alloca %struct.tms
%3 = call i64 @times(%struct.tms* %2)
%4 = icmp eq i64 %3, -1
br i1 %4, label %5, label %6
5: ; preds = %0
store i64 -1, i64* %1
br label %12
6: ; preds = %0
%7 = getelementptr inbounds %struct.tms, %struct.tms* %2, i32 0, i32 0
%8 = load i64, i64* %7
%9 = getelementptr inbounds %struct.tms, %struct.tms* %2, i32 0, i32 1
%10 = load i64, i64* %9
%11 = add nsw i64 %8, %10
store i64 %11, i64* %1
br label %12
12: ; preds = %6, %5
%13 = load i64, i64* %1
ret i64 %13
}

LLVM IR (-O2):
%struct.tms = type { i64, i64 }
define i64 @clock() {
%1 = alloca %struct.tms
%2 = bitcast %struct.tms* %1 to i8*
%3 = call i64 @times(%struct.tms* %1)
%4 = icmp eq i64 %3, -1
%5 = getelementptr inbounds %struct.tms, %struct.tms* %1, i64 0, i32 0
%6 = load i64, i64* %5
%7 = getelementptr inbounds %struct.tms, %struct.tms* %1, i64 0, i32 1
%8 = load i64, i64* %7
%9 = add nsw i64 %8, %6
%10 = select i1 %4, i64 -1, i64 %9
ret i64 %10
}
int main() {
  unsigned int arg = 0x12345678;
  unsigned int out = 0;
  __asm__("bswapl %%eax" : "=a"(out) : "a"(arg));
  return (out == 0x78563412);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
movl   $0x0,-0x4(%rbp)
movl   $0x12345678,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
mov    -0x8(%rbp),%eax
bswap  %eax
mov    %eax,-0xc(%rbp)
cmpl   $0x78563412,-0xc(%rbp)
sete   %al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
mov    $0x12345678,%eax
bswap  %eax
xor    %ecx,%ecx
cmp    $0x78563412,%eax
sete   %cl
mov    %ecx,%eax
ret

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
store i32 0, i32* %1
store i32 305419896, i32* %2
store i32 0, i32* %3
%4 = load i32, i32* %2
%5 = call i32 asm "bswapl %eax", "={ax},{ax},~{dirflag},~{fpsr},~{flags}"(i32 %4)
store i32 %5, i32* %3
%6 = load i32, i32* %3
%7 = icmp eq i32 %6, 2018915346
%8 = zext i1 %7 to i32
ret i32 %8
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 asm "bswapl %eax", "={ax},{ax},~{dirflag},~{fpsr},~{flags}"(i32 305419896)
%2 = icmp eq i32 %1, 2018915346
%3 = zext i1 %2 to i32
ret i32 %3
}