xunge/DecIR huggingface dataset:
/* Variables and functions */
long double __infer_nondet_long_double();
long double expm1l(long double x) { return __infer_nondet_long_double(); }


x86 assembly (clang, -O0):
<expm1l>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
fldt   0x10(%rbp)
fstpt  -0x10(%rbp)
xor    %eax,%eax
call   1030 <__infer_nondet_long_double@plt>
fld    %st(0)
fstp   %st(0)
add    $0x10,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
define x86_fp80 @expm1l(x86_fp80 %0) {
%2 = alloca x86_fp80
store x86_fp80 %0, x86_fp80* %2
%3 = call x86_fp80 (...) @__infer_nondet_long_double()
ret x86_fp80 %3
}

LLVM IR (-O2):
define x86_fp80 @expm1l(x86_fp80 %0) {
%2 = tail call x86_fp80 (...) @__infer_nondet_long_double()
ret x86_fp80 %2
}
int udfexample_ver() { return 2; }


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

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

LLVM IR (-O0):
define i32 @udfexample_ver() {
ret i32 2
}

LLVM IR (-O2):
define i32 @udfexample_ver() {
ret i32 2
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int);
int main() {
  int age = 24;
  int height = 12 * 6 - 1;
  printf("I am %d years old.\n", age);
  printf("I am %d inches tall.\n", height);
  return 0;
}


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

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xee8(%rip),%rdi
mov    $0x18,%esi
call   1030 <printf@plt>
lea    0xeeb(%rip),%rdi
mov    $0x47,%esi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [20 x i8] c"I am %d years old.\0A\00"
@.str.1 = [22 x i8] c"I am %d inches tall.\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
store i32 0, i32* %1
store i32 24, i32* %2
store i32 71, i32* %3
%4 = load i32, i32* %2
%5 = call i32 @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str, i64 0, i64 0), i32 %4)
%6 = load i32, i32* %3
%7 = call i32 @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.1, i64 0, i64 0), i32 %6)
ret i32 0
}

LLVM IR (-O2):
@.str = [20 x i8] c"I am %d years old.\0A\00"
@.str.1 = [22 x i8] c"I am %d inches tall.\0A\00"
define i32 @main() {
%1 = tail call i32 @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str, i64 0, i64 0), i32 24)
%2 = tail call i32 @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.1, i64 0, i64 0), i32 71)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ bar();
int /*<<< orphan*/ go();
void foo(int x) {
  if (x == 0)
    bar();
  else
    go();
}


x86 assembly (clang, -O0):
<foo>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
cmpl   $0x0,-0x4(%rbp)
jne    1141 <foo+0x21>
mov    $0x0,%al
call   1030 <bar@plt>
jmp    1148 <foo+0x28>
mov    $0x0,%al
call   1040 <go@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<foo>:
xor    %eax,%eax
test   %edi,%edi
je     112b <foo+0xb>
jmp    1040 <go@plt>
jmp    1030 <bar@plt>

LLVM IR (-O0):
define void @foo(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = icmp eq i32 %3, 0
br i1 %4, label %5, label %7
5: ; preds = %1
%6 = call i32 (...) @bar()
br label %9
7: ; preds = %1
%8 = call i32 (...) @go()
br label %9
9: ; preds = %7, %5
ret void
}

LLVM IR (-O2):
define void @foo(i32 %0) {
%2 = icmp eq i32 %0, 0
br i1 %2, label %3, label %5
3: ; preds = %1
%4 = tail call i32 (...) @bar()
br label %7
5: ; preds = %1
%6 = tail call i32 (...) @go()
br label %7
7: ; preds = %5, %3
ret void
}
void memregion_free(int id) {}


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

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

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

LLVM IR (-O2):
define void @memregion_free(i32 %0) {
ret void
}
int os_devopen(const char *name, int flag) { return -1; }


x86 assembly (clang, -O0):
<os_devopen>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    $0xffffffff,%eax
pop    %rbp
ret

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

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

LLVM IR (-O2):
define i32 @os_devopen(i8* nocapture readnone %0, i32 %1) {
ret i32 -1
}
int od_qm_offset(int bs, int xydec) {
  return xydec * (((((1 << 2 * (5)) - 1) << 2 * (2)) / 3)) +
         ((((1 << 2 * bs) - 1) << 2 * (2)) / 3);
}


x86 assembly (clang, -O0):
<od_qm_offset>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
imul   $0x1550,-0x8(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0x4(%rbp),%ecx
shl    $0x1,%ecx
mov    $0x1,%eax
shl    %cl,%eax
sub    $0x1,%eax
shl    $0x4,%eax
mov    $0x3,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0xc(%rbp),%eax
add    %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<od_qm_offset>:
imul   $0x1550,%esi,%edx
lea    (%rdi,%rdi,1),%ecx
mov    $0xffffffff,%eax
shl    %cl,%eax
not    %eax
shl    $0x4,%eax
cltq
imul   $0x55555556,%rax,%rax
mov    %rax,%rcx
shr    $0x3f,%rcx
shr    $0x20,%rax
add    %ecx,%eax
add    %edx,%eax
ret

LLVM IR (-O0):
define i32 @od_qm_offset(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
store i32 %0, i32* %3
store i32 %1, i32* %4
%5 = load i32, i32* %4
%6 = mul nsw i32 %5, 5456
%7 = load i32, i32* %3
%8 = mul nsw i32 2, %7
%9 = shl i32 1, %8
%10 = sub nsw i32 %9, 1
%11 = shl i32 %10, 4
%12 = sdiv i32 %11, 3
%13 = add nsw i32 %6, %12
ret i32 %13
}

LLVM IR (-O2):
define i32 @od_qm_offset(i32 %0, i32 %1) {
%3 = mul nsw i32 %1, 5456
%4 = shl nsw i32 %0, 1
%5 = shl nsw i32 -1, %4
%6 = xor i32 %5, -1
%7 = shl i32 %6, 4
%8 = sdiv i32 %7, 3
%9 = add nsw i32 %8, %3
ret i32 %9
}
/* Variables and functions */
int /*<<< orphan*/ dump(char const *, char const *, int, char *, int, char *);
void decdump(const char *message, const char *data, int len) {
  dump(message, data, len, "%03d ", 10, "    ");
}


x86 assembly (clang, -O0):
<decdump>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
mov    -0x14(%rbp),%edx
lea    0xecb(%rip),%rcx
mov    $0xa,%r8d
lea    0xec4(%rip),%r9
call   1030 <dump@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<decdump>:
lea    0xee9(%rip),%rcx
lea    0xee8(%rip),%r9
mov    $0xa,%r8d
jmp    1030 <dump@plt>

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

LLVM IR (-O2):
@.str = [6 x i8] c"%03d \00"
@.str.1 = [5 x i8] c" \00"
define void @decdump(i8* %0, i8* %1, i32 %2) {
%4 = tail call i32 @dump(i8* %0, i8* %1, i32 %2, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 10, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Type definitions */
struct wpa_ctrl {
  int dummy;
};

/* Variables and functions */
int wpa_ctrl_command(struct wpa_ctrl *, char *);
int wpa_cli_cmd_logon(struct wpa_ctrl *ctrl, int argc, const char *argv[]) {
  return wpa_ctrl_command(ctrl, "LOGON");
}


x86 assembly (clang, -O0):
<wpa_cli_cmd_logon>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x8(%rbp),%rdi
lea    0xed2(%rip),%rsi
call   1030 <wpa_ctrl_command@plt>
add    $0x20,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
%struct.wpa_ctrl = type { i32 }
@.str = [6 x i8] c"LOGON\00"
define i32 @wpa_cli_cmd_logon(%struct.wpa_ctrl* %0, i32 %1, i8** %2) {
%4 = alloca %struct.wpa_ctrl*
%5 = alloca i32
%6 = alloca i8**
store %struct.wpa_ctrl* %0, %struct.wpa_ctrl** %4
store i32 %1, i32* %5
store i8** %2, i8*** %6
%7 = load %struct.wpa_ctrl*, %struct.wpa_ctrl** %4
%8 = call i32 @wpa_ctrl_command(%struct.wpa_ctrl* %7, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
ret i32 %8
}

LLVM IR (-O2):
%struct.wpa_ctrl = type { i32 }
@.str = [6 x i8] c"LOGON\00"
define i32 @wpa_cli_cmd_logon(%struct.wpa_ctrl* %0, i32 %1, i8** nocapture readnone %2) {
%4 = tail call i32 @wpa_ctrl_command(%struct.wpa_ctrl* %0, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
ret i32 %4
}
unsigned long http_parser_version(void) {
  return 2 * 0x10000 | 8 * 0x00100 | 0 * 0x00001;
}


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

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

LLVM IR (-O0):
define i64 @http_parser_version() {
ret i64 133120
}

LLVM IR (-O2):
define i64 @http_parser_version() {
ret i64 133120
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, char *);
int /*<<< orphan*/ puts(char *);
void print_help(char *argv0) {
  printf("Usage: %s [OPTION]... DEVICE\n", argv0);
  puts("io_board -- read from rs485 serial port");
  puts("  -h            display this help and exit");
  puts("  -t TIME       delay TIME (ms) after request. (default: 50 ms)");
}


x86 assembly (clang, -O0):
<print_help>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rsi
lea    0xec9(%rip),%rdi
call   1040 <printf@plt>
lea    0xedb(%rip),%rdi
call   1030 <puts@plt>
lea    0xef7(%rip),%rdi
call   1030 <puts@plt>
lea    0xf16(%rip),%rdi
call   1030 <puts@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<print_help>:
push   %rax
mov    %rdi,%rsi
lea    0xed5(%rip),%rdi
call   1040 <printf@plt>
lea    0xee7(%rip),%rdi
call   1030 <puts@plt>
lea    0xf03(%rip),%rdi
call   1030 <puts@plt>
lea    0xf22(%rip),%rdi
pop    %rax
jmp    1030 <puts@plt>

LLVM IR (-O0):
@.str = [30 x i8] c"Usage: %s [OPTION]... DEVICE\0A\00"
@.str.1 = [40 x i8] c"io_board -- read from rs485 serial port\00"
@.str.2 = [43 x i8] c" -h display this help and exit\00"
@.str.3 = [64 x i8] c" -t TIME delay TIME (ms) after request. (default: 50 ms)\00"
define void @print_help(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = call i32 @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str, i64 0, i64 0), i8* %3)
%5 = call i32 @puts(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str.1, i64 0, i64 0))
%6 = call i32 @puts(i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.2, i64 0, i64 0))
%7 = call i32 @puts(i8* getelementptr inbounds ([64 x i8], [64 x i8]* @.str.3, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [30 x i8] c"Usage: %s [OPTION]... DEVICE\0A\00"
@.str.1 = [40 x i8] c"io_board -- read from rs485 serial port\00"
@.str.2 = [43 x i8] c" -h display this help and exit\00"
@.str.3 = [64 x i8] c" -t TIME delay TIME (ms) after request. (default: 50 ms)\00"
define void @print_help(i8* %0) {
%2 = tail call i32 @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str, i64 0, i64 0), i8* %0)
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([40 x i8], [40 x i8]* @.str.1, i64 0, i64 0))
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([43 x i8], [43 x i8]* @.str.2, i64 0, i64 0))
%5 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([64 x i8], [64 x i8]* @.str.3, i64 0, i64 0))
ret void
}
/* Type definitions */
struct buffer {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ buffer_insert(struct buffer *, char *, int);
void buffer_insert_int(struct buffer *buf, unsigned int value) {
  buffer_insert(buf, (char *)&value, 4);
}


x86 assembly (clang, -O0):
<buffer_insert_int>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0x8(%rbp),%rdi
lea    -0xc(%rbp),%rsi
mov    $0x4,%edx
call   1030 <buffer_insert@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<buffer_insert_int>:
push   %rax
mov    %esi,0x4(%rsp)
lea    0x4(%rsp),%rsi
mov    $0x4,%edx
call   1030 <buffer_insert@plt>
pop    %rax
ret

LLVM IR (-O0):
%struct.buffer = type { i32 }
define void @buffer_insert_int(%struct.buffer* %0, i32 %1) {
%3 = alloca %struct.buffer*
%4 = alloca i32
store %struct.buffer* %0, %struct.buffer** %3
store i32 %1, i32* %4
%5 = load %struct.buffer*, %struct.buffer** %3
%6 = bitcast i32* %4 to i8*
%7 = call i32 @buffer_insert(%struct.buffer* %5, i8* %6, i32 4)
ret void
}

LLVM IR (-O2):
%struct.buffer = type { i32 }
define void @buffer_insert_int(%struct.buffer* %0, i32 %1) {
%3 = alloca i32
store i32 %1, i32* %3
%4 = bitcast i32* %3 to i8*
%5 = call i32 @buffer_insert(%struct.buffer* %0, i8* %4, i32 4)
ret void
}
/* Type definitions */
typedef int uint8_t;

/* Variables and functions */
int /*<<< orphan*/ SPI_IOC_RD_MODE;
scalar_t__ ioctl(int, int /*<<< orphan*/, int *);
int SPI_getMode(int spidev_fd) {
  uint8_t mode;
  if (ioctl(spidev_fd, SPI_IOC_RD_MODE, &mode) < 0)
    return -1;
  return mode;
}


x86 assembly (clang, -O0):
<SPI_getMode>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x8(%rbp)
mov    -0x8(%rbp),%edi
mov    0x2ec3(%rip),%rax
mov    (%rax),%esi
lea    -0xc(%rbp),%rdx
call   1030 <ioctl@plt>
cmp    $0x0,%rax
jge    1146 <SPI_getMode+0x36>
movl   $0xffffffff,-0x4(%rbp)
jmp    114c <SPI_getMode+0x3c>
mov    -0xc(%rbp),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<SPI_getMode>:
push   %rax
mov    0x2ed0(%rip),%rax
mov    (%rax),%esi
lea    0x4(%rsp),%rdx
call   1030 <ioctl@plt>
mov    %rax,%rcx
mov    $0xffffffff,%eax
test   %rcx,%rcx
js     1135 <SPI_getMode+0x25>
mov    0x4(%rsp),%eax
pop    %rcx
ret

LLVM IR (-O0):
@SPI_IOC_RD_MODE = global i32 0
define i32 @SPI_getMode(i32 %0) {
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
store i32 %0, i32* %3
%5 = load i32, i32* %3
%6 = load i32, i32* @SPI_IOC_RD_MODE
%7 = call i64 @ioctl(i32 %5, i32 %6, i32* %4)
%8 = icmp slt i64 %7, 0
br i1 %8, label %9, label %10
9: ; preds = %1
store i32 -1, i32* %2
br label %12
10: ; preds = %1
%11 = load i32, i32* %4
store i32 %11, i32* %2
br label %12
12: ; preds = %10, %9
%13 = load i32, i32* %2
ret i32 %13
}

LLVM IR (-O2):
@SPI_IOC_RD_MODE = global i32 0
define i32 @SPI_getMode(i32 %0) {
%2 = alloca i32
%3 = bitcast i32* %2 to i8*
%4 = load i32, i32* @SPI_IOC_RD_MODE
%5 = call i64 @ioctl(i32 %0, i32 %4, i32* %2)
%6 = icmp slt i64 %5, 0
%7 = load i32, i32* %2
%8 = select i1 %6, i32 -1, i32 %7
ret i32 %8
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int *, int *);
int main() {
  int arr[2];
  int *p = arr;
  printf("%p %p\n", p, p + 1);
  return 0;
}


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

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0x4(%rsp),%rdx
lea    0xee3(%rip),%rdi
mov    %rsp,%rsi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rcx
ret

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

LLVM IR (-O2):
@.str = [7 x i8] c"%p %p\0A\00"
define i32 @main() {
%1 = alloca [2 x i32]
%2 = bitcast [2 x i32]* %1 to i8*
%3 = getelementptr inbounds [2 x i32], [2 x i32]* %1, i64 0, i64 0
%4 = getelementptr inbounds [2 x i32], [2 x i32]* %1, i64 0, i64 1
%5 = call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i32* %3, i32* %4)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ ixp_errbuf();
int /*<<< orphan*/ strncpy(char *, int /*<<< orphan*/, int);
void ixp_rerrstr(char *buf, int n) { strncpy(buf, ixp_errbuf(), n); }


x86 assembly (clang, -O0):
<ixp_rerrstr>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    $0x0,%al
call   1030 <ixp_errbuf@plt>
mov    -0x18(%rbp),%rdi
mov    %eax,%esi
mov    -0xc(%rbp),%edx
call   1040 <strncpy@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ixp_rerrstr>:
push   %rbp
push   %rbx
push   %rax
mov    %esi,%ebp
mov    %rdi,%rbx
xor    %eax,%eax
call   1030 <ixp_errbuf@plt>
mov    %rbx,%rdi
mov    %eax,%esi
mov    %ebp,%edx
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1040 <strncpy@plt>

LLVM IR (-O0):
define void @ixp_rerrstr(i8* %0, i32 %1) {
%3 = alloca i8*
%4 = alloca i32
store i8* %0, i8** %3
store i32 %1, i32* %4
%5 = load i8*, i8** %3
%6 = call i32 (...) @ixp_errbuf()
%7 = load i32, i32* %4
%8 = call i32 @strncpy(i8* %5, i32 %6, i32 %7)
ret void
}

LLVM IR (-O2):
define void @ixp_rerrstr(i8* %0, i32 %1) {
%3 = tail call i32 (...) @ixp_errbuf()
%4 = tail call i32 @strncpy(i8* %0, i32 %3, i32 %1)
ret void
}
/* Variables and functions */
double beta(int, int);
double simfreqBN(double FST, double p_anc) {
  return beta(((1 - FST) / FST) * p_anc, ((1 - FST) / FST) * (1 - p_anc));
}


x86 assembly (clang, -O0):
<simfreqBN>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
movsd  0xed6(%rip),%xmm0
subsd  -0x8(%rbp),%xmm0
divsd  -0x8(%rbp),%xmm0
mulsd  -0x10(%rbp),%xmm0
cvttsd2si %xmm0,%edi
movsd  0xebb(%rip),%xmm0
subsd  -0x8(%rbp),%xmm0
divsd  -0x8(%rbp),%xmm0
movsd  0xea9(%rip),%xmm1
subsd  -0x10(%rbp),%xmm1
mulsd  %xmm1,%xmm0
cvttsd2si %xmm0,%esi
call   1030 <beta@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<simfreqBN>:
movsd  0xee8(%rip),%xmm2
movapd %xmm2,%xmm3
subsd  %xmm0,%xmm3
divsd  %xmm0,%xmm3
subsd  %xmm1,%xmm2
mulsd  %xmm3,%xmm2
mulsd  %xmm1,%xmm3
cvttsd2si %xmm3,%edi
cvttsd2si %xmm2,%esi
jmp    1030 <beta@plt>

LLVM IR (-O0):
define double @simfreqBN(double %0, double %1) {
%3 = alloca double
%4 = alloca double
store double %0, double* %3
store double %1, double* %4
%5 = load double, double* %3
%6 = fsub double 1.000000e+00, %5
%7 = load double, double* %3
%8 = fdiv double %6, %7
%9 = load double, double* %4
%10 = fmul double %8, %9
%11 = fptosi double %10 to i32
%12 = load double, double* %3
%13 = fsub double 1.000000e+00, %12
%14 = load double, double* %3
%15 = fdiv double %13, %14
%16 = load double, double* %4
%17 = fsub double 1.000000e+00, %16
%18 = fmul double %15, %17
%19 = fptosi double %18 to i32
%20 = call double @beta(i32 %11, i32 %19)
ret double %20
}

LLVM IR (-O2):
define double @simfreqBN(double %0, double %1) {
%3 = fsub double 1.000000e+00, %0
%4 = fdiv double %3, %0
%5 = fmul double %4, %1
%6 = fptosi double %5 to i32
%7 = fsub double 1.000000e+00, %1
%8 = fmul double %4, %7
%9 = fptosi double %8 to i32
%10 = tail call double @beta(i32 %6, i32 %9)
ret double %10
}
void CFGMR3GetFirstValue(void) {}


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

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

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

LLVM IR (-O2):
define void @CFGMR3GetFirstValue() {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ pckg_unlock();
PI_vminit() {
  pckg_unlock();
  return (0);
}


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

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

LLVM IR (-O0):
define i32 @PI_vminit() {
%1 = call i32 (...) @pckg_unlock()
ret i32 0
}

LLVM IR (-O2):
define i32 @PI_vminit() {
%1 = tail call i32 (...) @pckg_unlock()
ret i32 0
}
double calc_duh(double const x) { return x * 2376; }


x86 assembly (clang, -O0):
<calc_duh>:
push   %rbp
mov    %rsp,%rbp
movsd  %xmm0,-0x8(%rbp)
movsd  0xeef(%rip),%xmm0
mulsd  -0x8(%rbp),%xmm0
pop    %rbp
ret

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

LLVM IR (-O0):
define double @calc_duh(double %0) {
%2 = alloca double
store double %0, double* %2
%3 = load double, double* %2
%4 = fmul double %3, 2.376000e+03
ret double %4
}

LLVM IR (-O2):
define double @calc_duh(double %0) {
%2 = fmul double %0, 2.376000e+03
ret double %2
}
void CompareTextsTestCase() {
  TestCheckEqualStrings("Text 1", "Other text", __FUNCTION__,
                        "/scratch/repos/new/home/jordi_armengol_estape/"
                        "c-scraper/outputs/2022-01-22/02-19-57/repos/ociotec/"
                        "mini-test/refs/heads/master/samples/main.c",
                        20);
}


x86 assembly (clang, -O0):
<CompareTextsTestCase>:
push   %rbp
mov    %rsp,%rbp
lea    0xee5(%rip),%rdi
lea    0xee5(%rip),%rsi
lea    0xee9(%rip),%rdx
lea    0xef7(%rip),%rcx
mov    $0x14,%r8d
mov    $0x0,%al
call   1030 <TestCheckEqualStrings@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<CompareTextsTestCase>:
lea    0xee9(%rip),%rdi
lea    0xee9(%rip),%rsi
lea    0xeed(%rip),%rdx
lea    0xefb(%rip),%rcx
mov    $0x14,%r8d
xor    %eax,%eax
jmp    1030 <TestCheckEqualStrings@plt>

LLVM IR (-O0):
@.str = [7 x i8] c"Text 1\00"
@.str.1 = [11 x i8] c"Other text\00"
@__FUNCTION__.CompareTextsTestCase = [21 x i8] c"CompareTextsTestCase\00"
@.str.2 = [141 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/ociotec/mini-test/refs/heads/master/samples/main.c\00"
define void @CompareTextsTestCase() {
%1 = call i32 (i8*, i8*, i8*, i8*, i32, ...) bitcast (i32 (...)* @TestCheckEqualStrings to i32 (i8*, i8*, i8*, i8*, i32, ...)*)(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([21 x i8], [21 x i8]* @__FUNCTION__.CompareTextsTestCase, i64 0, i64 0), i8* getelementptr inbounds ([141 x i8], [141 x i8]* @.str.2, i64 0, i64 0), i32 20)
ret void
}

LLVM IR (-O2):
@.str = [7 x i8] c"Text 1\00"
@.str.1 = [11 x i8] c"Other text\00"
@__FUNCTION__.CompareTextsTestCase = [21 x i8] c"CompareTextsTestCase\00"
@.str.2 = [141 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/ociotec/mini-test/refs/heads/master/samples/main.c\00"
define void @CompareTextsTestCase() {
%1 = tail call i32 (i8*, i8*, i8*, i8*, i32, ...) bitcast (i32 (...)* @TestCheckEqualStrings to i32 (i8*, i8*, i8*, i8*, i32, ...)*)(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([21 x i8], [21 x i8]* @__FUNCTION__.CompareTextsTestCase, i64 0, i64 0), i8* getelementptr inbounds ([141 x i8], [141 x i8]* @.str.2, i64 0, i64 0), i32 20)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ test7_f(int **);
void test7_g() {
  int x[5];
  test7_f(&x);
}


x86 assembly (clang, -O0):
<test7_g>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
lea    -0x20(%rbp),%rdi
call   1030 <test7_f@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<test7_g>:
sub    $0x18,%rsp
mov    %rsp,%rdi
call   1030 <test7_f@plt>
add    $0x18,%rsp
ret

LLVM IR (-O0):
define void @test7_g() {
%1 = alloca [5 x i32]
%2 = bitcast [5 x i32]* %1 to i32**
%3 = call i32 @test7_f(i32** %2)
ret void
}

LLVM IR (-O2):
define void @test7_g() {
%1 = alloca [5 x i32]
%2 = bitcast [5 x i32]* %1 to i8*
%3 = bitcast [5 x i32]* %1 to i32**
%4 = call i32 @test7_f(i32** %3)
ret void
}
/* Type definitions */
struct io_file {
  int dummy;
};

/* Variables and functions */
int io_out(struct io_file *, int, char *, int);
int io_out_i1(struct io_file *f, int pos, signed char o) {
  return io_out(f, pos, &o, sizeof o);
}


x86 assembly (clang, -O0):
<io_out_i1>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %dl,%al
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %al,-0xd(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
lea    -0xd(%rbp),%rdx
mov    $0x1,%ecx
call   1030 <io_out@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<io_out_i1>:
push   %rax
mov    %dl,0x7(%rsp)
lea    0x7(%rsp),%rdx
mov    $0x1,%ecx
call   1030 <io_out@plt>
pop    %rcx
ret

LLVM IR (-O0):
%struct.io_file = type { i32 }
define i32 @io_out_i1(%struct.io_file* %0, i32 %1, i8 signext %2) {
%4 = alloca %struct.io_file*
%5 = alloca i32
%6 = alloca i8
store %struct.io_file* %0, %struct.io_file** %4
store i32 %1, i32* %5
store i8 %2, i8* %6
%7 = load %struct.io_file*, %struct.io_file** %4
%8 = load i32, i32* %5
%9 = call i32 @io_out(%struct.io_file* %7, i32 %8, i8* %6, i32 1)
ret i32 %9
}

LLVM IR (-O2):
%struct.io_file = type { i32 }
define i32 @io_out_i1(%struct.io_file* %0, i32 %1, i8 signext %2) {
%4 = alloca i8
store i8 %2, i8* %4
%5 = call i32 @io_out(%struct.io_file* %0, i32 %1, i8* %4, i32 1)
ret i32 %5
}
int common_denominator(int a, int b) {
  if (a == 0)
    return b;
  if (b == 0)
    return a;
  while (b) {
    int t = b;
    b = a % b;
    a = t;
  }
  return a;
}


x86 assembly (clang, -O0):
<common_denominator>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
cmpl   $0x0,-0x8(%rbp)
jne    111f <common_denominator+0x1f>
mov    -0xc(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    1164 <common_denominator+0x64>
cmpl   $0x0,-0xc(%rbp)
jne    1134 <common_denominator+0x34>
mov    -0x8(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    1164 <common_denominator+0x64>
jmp    1139 <common_denominator+0x39>
cmpl   $0x0,-0xc(%rbp)
je     115e <common_denominator+0x5e>
mov    -0xc(%rbp),%eax
mov    %eax,-0x10(%rbp)
mov    -0x8(%rbp),%eax
cltd
idivl  -0xc(%rbp)
mov    %edx,-0xc(%rbp)
mov    -0x10(%rbp),%eax
mov    %eax,-0x8(%rbp)
jmp    1139 <common_denominator+0x39>
mov    -0x8(%rbp),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<common_denominator>:
mov    %esi,%edx
test   %edi,%edi
je     111e <common_denominator+0x1e>
mov    %edi,%eax
test   %edx,%edx
je     1120 <common_denominator+0x20>
nopl   0x0(%rax)
mov    %edx,%ecx
cltd
idiv   %ecx
mov    %ecx,%eax
test   %edx,%edx
jne    1110 <common_denominator+0x10>
mov    %ecx,%eax
ret
mov    %edx,%eax
ret

LLVM IR (-O0):
define i32 @common_denominator(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
store i32 %0, i32* %4
store i32 %1, i32* %5
%7 = load i32, i32* %4
%8 = icmp eq i32 %7, 0
br i1 %8, label %9, label %11
9: ; preds = %2
%10 = load i32, i32* %5
store i32 %10, i32* %3
br label %28
11: ; preds = %2
%12 = load i32, i32* %5
%13 = icmp eq i32 %12, 0
br i1 %13, label %14, label %16
14: ; preds = %11
%15 = load i32, i32* %4
store i32 %15, i32* %3
br label %28
16: ; preds = %11
br label %17
17: ; preds = %20, %16
%18 = load i32, i32* %5
%19 = icmp ne i32 %18, 0
br i1 %19, label %20, label %26
20: ; preds = %17
%21 = load i32, i32* %5
store i32 %21, i32* %6
%22 = load i32, i32* %4
%23 = load i32, i32* %5
%24 = srem i32 %22, %23
store i32 %24, i32* %5
%25 = load i32, i32* %6
store i32 %25, i32* %4
br label %17
26: ; preds = %17
%27 = load i32, i32* %4
store i32 %27, i32* %3
br label %28
28: ; preds = %26, %14, %9
%29 = load i32, i32* %3
ret i32 %29
}

LLVM IR (-O2):
define i32 @common_denominator(i32 %0, i32 %1) {
%3 = icmp eq i32 %0, 0
br i1 %3, label %11, label %4
4: ; preds = %2
%5 = icmp eq i32 %1, 0
br i1 %5, label %11, label %6
6: ; preds = %4, %6
%7 = phi i32 [ %9, %6 ], [ %1, %4 ]
%8 = phi i32 [ %7, %6 ], [ %0, %4 ]
%9 = srem i32 %8, %7
%10 = icmp eq i32 %9, 0
br i1 %10, label %11, label %6
11: ; preds = %6, %4, %2
%12 = phi i32 [ %1, %2 ], [ %0, %4 ], [ %7, %6 ]
ret i32 %12
}
/* Type definitions */
typedef int uint8_t;

/* Variables and functions */
bool bit_is_set(uint8_t byte, uint8_t i) { return byte & (1 << i); }


x86 assembly (clang, -O0):
<bit_is_set>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x4(%rbp),%eax
mov    -0x8(%rbp),%ecx
mov    $0x1,%edx
shl    %cl,%edx
mov    %edx,%ecx
and    %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<bit_is_set>:
mov    %esi,%ecx
mov    $0x1,%eax
shl    %cl,%eax
and    %edi,%eax
ret

LLVM IR (-O0):
define i32 @bit_is_set(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 = shl i32 1, %6
%8 = and i32 %5, %7
ret i32 %8
}

LLVM IR (-O2):
define i32 @bit_is_set(i32 %0, i32 %1) {
%3 = shl nuw i32 1, %1
%4 = and i32 %3, %0
ret i32 %4
}
/* Type definitions */
struct tm {
  int tm_sec;
};

/* Variables and functions */
unsigned Sys_Second(void *t) { return ((struct tm *)t)->tm_sec; }


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

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

LLVM IR (-O0):
%struct.tm = type { i32 }
define i32 @Sys_Second(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = bitcast i8* %3 to %struct.tm*
%5 = getelementptr inbounds %struct.tm, %struct.tm* %4, i32 0, i32 0
%6 = load i32, i32* %5
ret i32 %6
}

LLVM IR (-O2):
define i32 @Sys_Second(i8* nocapture %0) {
%2 = bitcast i8* %0 to i32*
%3 = load i32, i32* %2
ret i32 %3
}
unsigned shiftrt(unsigned long long a, unsigned b) {
  int c = a;
  return c >> b;
}


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

x86 assembly (clang, -O2):
<shiftrt>:
mov    %esi,%ecx
mov    %rdi,%rax
sar    %cl,%eax
ret

LLVM IR (-O0):
define i32 @shiftrt(i64 %0, i32 %1) {
%3 = alloca i64
%4 = alloca i32
%5 = alloca i32
store i64 %0, i64* %3
store i32 %1, i32* %4
%6 = load i64, i64* %3
%7 = trunc i64 %6 to i32
store i32 %7, i32* %5
%8 = load i32, i32* %5
%9 = load i32, i32* %4
%10 = ashr i32 %8, %9
ret i32 %10
}

LLVM IR (-O2):
define i32 @shiftrt(i64 %0, i32 %1) {
%3 = trunc i64 %0 to i32
%4 = ashr i32 %3, %1
ret i32 %4
}
void d_storesb(register unsigned char **ptr, register signed char data) {
  *(*ptr)++ = data;
}


x86 assembly (clang, -O0):
<d_storesb>:
push   %rbp
mov    %rsp,%rbp
mov    %sil,%al
mov    %rdi,-0x8(%rbp)
mov    %al,-0x9(%rbp)
mov    -0x9(%rbp),%cl
mov    -0x8(%rbp),%rdx
mov    (%rdx),%rax
mov    %rax,%rsi
add    $0x1,%rsi
mov    %rsi,(%rdx)
mov    %cl,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<d_storesb>:
mov    (%rdi),%rax
lea    0x1(%rax),%rcx
mov    %rcx,(%rdi)
mov    %sil,(%rax)
ret

LLVM IR (-O0):
define void @d_storesb(i8** %0, i8 signext %1) {
%3 = alloca i8**
%4 = alloca i8
store i8** %0, i8*** %3
store i8 %1, i8* %4
%5 = load i8, i8* %4
%6 = load i8**, i8*** %3
%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 @d_storesb(i8** nocapture %0, i8 signext %1) {
%3 = load i8*, i8** %0
%4 = getelementptr inbounds i8, i8* %3, i64 1
store i8* %4, i8** %0
store i8 %1, i8* %3
ret void
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ isalpha(int);
void t_isalpha_0x3d() {
  Assert_real((isalpha(61) == 0),
              "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/"
              "2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/"
              "dg/z88dk/test/suites/ctype/test_isalpha.c",
              310, ("isalpha should be 0 for ="));
}


x86 assembly (clang, -O0):
<t_isalpha_0x3d>:
push   %rbp
mov    %rsp,%rbp
mov    $0x3d,%edi
call   1030 <isalpha@plt>
cmp    $0x0,%rax
sete   %al
and    $0x1,%al
movzbl %al,%edi
lea    0xebf(%rip),%rsi
mov    $0x136,%edx
lea    0xf5b(%rip),%rcx
call   1040 <Assert_real@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<t_isalpha_0x3d>:
push   %rax
mov    $0x3d,%edi
call   1030 <isalpha@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
lea    0xec5(%rip),%rsi
lea    0xf66(%rip),%rcx
mov    $0x136,%edx
pop    %rax
jmp    1040 <Assert_real@plt>

LLVM IR (-O0):
@.str = [168 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_isalpha.c\00"
@.str.1 = [26 x i8] c"isalpha should be 0 for =\00"
define void @t_isalpha_0x3d() {
%1 = call i64 @isalpha(i32 61)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 310, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [168 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_isalpha.c\00"
@.str.1 = [26 x i8] c"isalpha should be 0 for =\00"
define void @t_isalpha_0x3d() {
%1 = tail call i64 @isalpha(i32 61)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = tail call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 310, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ GroundPathFollowerSettingsHandle();
int /*<<< orphan*/ UAVObjUpdated(int /*<<< orphan*/);
void GroundPathFollowerSettingsUpdated() {
  UAVObjUpdated(GroundPathFollowerSettingsHandle());
}


x86 assembly (clang, -O0):
<GroundPathFollowerSettingsUpdated>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1040 <GroundPathFollowerSettingsHandle@plt>
mov    %eax,%edi
call   1030 <UAVObjUpdated@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<GroundPathFollowerSettingsUpdated>:
push   %rax
xor    %eax,%eax
call   1040 <GroundPathFollowerSettingsHandle@plt>
mov    %eax,%edi
pop    %rax
jmp    1030 <UAVObjUpdated@plt>

LLVM IR (-O0):
define void @GroundPathFollowerSettingsUpdated() {
%1 = call i32 (...) @GroundPathFollowerSettingsHandle()
%2 = call i32 @UAVObjUpdated(i32 %1)
ret void
}

LLVM IR (-O2):
define void @GroundPathFollowerSettingsUpdated() {
%1 = tail call i32 (...) @GroundPathFollowerSettingsHandle()
%2 = tail call i32 @UAVObjUpdated(i32 %1)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ integrity_parse_slot(char const *, int *, int *, int *,
                                        int *);
int /*<<< orphan*/ sprintf(char *, char *, int);
char *integrity_slot_str(const char *slot_name, char *str) {
  int cabinet, bay, chassis, slot_num;
  integrity_parse_slot(slot_name, &cabinet, &bay, &chassis, &slot_num);
  sprintf(str, "%d", slot_num);
  return str;
}


x86 assembly (clang, -O0):
<integrity_slot_str>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
lea    -0x14(%rbp),%rsi
lea    -0x18(%rbp),%rdx
lea    -0x1c(%rbp),%rcx
lea    -0x20(%rbp),%r8
call   1030 <integrity_parse_slot@plt>
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%edx
lea    0xea9(%rip),%rsi
call   1040 <sprintf@plt>
mov    -0x10(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<integrity_slot_str>:
push   %rbx
sub    $0x10,%rsp
mov    %rsi,%rbx
lea    0xc(%rsp),%rsi
lea    0x8(%rsp),%rdx
lea    0x4(%rsp),%rcx
mov    %rsp,%r8
call   1030 <integrity_parse_slot@plt>
mov    (%rsp),%edx
lea    0xeb7(%rip),%rsi
mov    %rbx,%rdi
call   1040 <sprintf@plt>
mov    %rbx,%rax
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%d\00"
define i8* @integrity_slot_str(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
store i8* %0, i8** %3
store i8* %1, i8** %4
%9 = load i8*, i8** %3
%10 = call i32 @integrity_parse_slot(i8* %9, i32* %5, i32* %6, i32* %7, i32* %8)
%11 = load i8*, i8** %4
%12 = load i32, i32* %8
%13 = call i32 @sprintf(i8* %11, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32 %12)
%14 = load i8*, i8** %4
ret i8* %14
}

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
define i8* @integrity_slot_str(i8* %0, i8* returned writeonly %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
%7 = bitcast i32* %3 to i8*
%8 = bitcast i32* %4 to i8*
%9 = bitcast i32* %5 to i8*
%10 = bitcast i32* %6 to i8*
%11 = call i32 @integrity_parse_slot(i8* %0, i32* %3, i32* %4, i32* %5, i32* %6)
%12 = load i32, i32* %6
%13 = call i32 @sprintf(i8* dereferenceable(1) %1, i8* dereferenceable(1) getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32 %12)
ret i8* %1
}
unsigned int multiple(int secondoNumero, int primoNumero) {
  if (secondoNumero % primoNumero == 0) {
    return 1;
  }
  return 0;
}


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

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

LLVM IR (-O0):
define i32 @multiple(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* %5
%8 = srem i32 %6, %7
%9 = icmp eq i32 %8, 0
br i1 %9, label %10, label %11
10: ; preds = %2
store i32 1, i32* %3
br label %12
11: ; preds = %2
store i32 0, i32* %3
br label %12
12: ; preds = %11, %10
%13 = load i32, i32* %3
ret i32 %13
}

LLVM IR (-O2):
define i32 @multiple(i32 %0, i32 %1) {
%3 = srem i32 %0, %1
%4 = icmp eq i32 %3, 0
%5 = zext i1 %4 to i32
ret i32 %5
}
const char keyblock_key_filter(char c) {
  if (' ' <= c && c <= '~')
    return c;
  else
    return 0;
}


x86 assembly (clang, -O0):
<keyblock_key_filter>:
push   %rbp
mov    %rsp,%rbp
mov    %dil,%al
mov    %al,-0x2(%rbp)
movsbl -0x2(%rbp),%ecx
mov    $0x20,%eax
cmp    %ecx,%eax
jg     1133 <keyblock_key_filter+0x33>
movsbl -0x2(%rbp),%eax
cmp    $0x7e,%eax
jg     1133 <keyblock_key_filter+0x33>
mov    -0x2(%rbp),%al
mov    %al,-0x1(%rbp)
jmp    1137 <keyblock_key_filter+0x37>
movb   $0x0,-0x1(%rbp)
movsbl -0x1(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<keyblock_key_filter>:
lea    -0x20(%rdi),%ecx
xor    %eax,%eax
cmp    $0x5f,%cl
cmovb  %edi,%eax
ret

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

LLVM IR (-O2):
define signext i8 @keyblock_key_filter(i8 signext %0) {
%2 = add i8 %0, -32
%3 = icmp ult i8 %2, 95
%4 = select i1 %3, i8 %0, i8 0
ret i8 %4
}
/* Variables and functions */
int /*<<< orphan*/ runalltests_behaviour_open_address_file_hash();
int main(void) {
  runalltests_behaviour_open_address_file_hash();
  return 0;
}


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

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

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

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 (...) @runalltests_behaviour_open_address_file_hash()
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ synchronize_sched();
__attribute__((always_)) void tracepoint_synchronize_unregister(void) {
  synchronize_sched();
}


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

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

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

LLVM IR (-O2):
define void @tracepoint_synchronize_unregister() {
%1 = tail call i32 (...) @synchronize_sched()
ret void
}
int test_imm_70int8_mem(signed char *val) {
  return ((*val) & (-0x70 << 0)) ? -20 : -40;
}


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

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

LLVM IR (-O0):
define i32 @test_imm_70int8_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, -112
%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_70int8_mem(i8* nocapture %0) {
%2 = load i8, i8* %0
%3 = and i8 %2, -112
%4 = icmp eq i8 %3, 0
%5 = select i1 %4, i32 -40, i32 -20
ret i32 %5
}
__attribute((always_)) void *f(unsigned size) {
  static char malloc_buf[16];
  static void *ptr = malloc_buf;
  void *ret = ptr;
  ptr += size;
  return ret;
}


x86 assembly (clang, -O0):
<f>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    0x2f12(%rip),%rax
mov    %rax,-0x10(%rbp)
mov    -0x4(%rbp),%ecx
mov    0x2f04(%rip),%rax
mov    %ecx,%ecx
add    %rcx,%rax
mov    %rax,0x2ef8(%rip)
mov    -0x10(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<f>:
mov    0x2f19(%rip),%rax
mov    %edi,%ecx
add    %rax,%rcx
mov    %rcx,0x2f0d(%rip)
ret

LLVM IR (-O0):
@f.malloc_buf = internal global [16 x i8] zeroinitializer
@f.ptr = internal global i8* getelementptr inbounds ([16 x i8], [16 x i8]* @f.malloc_buf, i32 0, i32 0)
define i8* @f(i32 %0) {
%2 = alloca i32
%3 = alloca i8*
store i32 %0, i32* %2
%4 = load i8*, i8** @f.ptr
store i8* %4, i8** %3
%5 = load i32, i32* %2
%6 = load i8*, i8** @f.ptr
%7 = zext i32 %5 to i64
%8 = getelementptr i8, i8* %6, i64 %7
store i8* %8, i8** @f.ptr
%9 = load i8*, i8** %3
ret i8* %9
}

LLVM IR (-O2):
@f.malloc_buf = internal global [16 x i8] zeroinitializer
@f.ptr = internal unnamed_addr global i8* getelementptr inbounds ([16 x i8], [16 x i8]* @f.malloc_buf, i64 0, i64 0)
define i8* @f(i32 %0) {
%2 = load i8*, i8** @f.ptr
%3 = zext i32 %0 to i64
%4 = getelementptr i8, i8* %2, i64 %3
store i8* %4, i8** @f.ptr
ret i8* %2
}
/* Variables and functions */
float atanhf(float);
float qlogisticf(float p) { return 2.0f * atanhf(2.0f * p - 1.0f); }


x86 assembly (clang, -O0):
<qlogisticf>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
addss  %xmm0,%xmm0
movss  0xed6(%rip),%xmm1
addss  %xmm1,%xmm0
call   1030 <atanhf@plt>
movaps %xmm0,%xmm1
movss  0xebe(%rip),%xmm0
mulss  %xmm1,%xmm0
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<qlogisticf>:
push   %rax
addss  %xmm0,%xmm0
addss  0xee3(%rip),%xmm0
call   1030 <atanhf@plt>
addss  %xmm0,%xmm0
pop    %rax
ret

LLVM IR (-O0):
define float @qlogisticf(float %0) {
%2 = alloca float
store float %0, float* %2
%3 = load float, float* %2
%4 = call float @llvm.fmuladd.f32(float 2.000000e+00, float %3, float -1.000000e+00)
%5 = call float @atanhf(float %4)
%6 = fmul float 2.000000e+00, %5
ret float %6
}

LLVM IR (-O2):
define float @qlogisticf(float %0) {
%2 = tail call float @llvm.fmuladd.f32(float %0, float 2.000000e+00, float -1.000000e+00)
%3 = tail call float @atanhf(float %2)
%4 = fmul float %3, 2.000000e+00
ret float %4
}
int _dlinfo(void *ptr1, int x, void *ptr2) { return 0; }


x86 assembly (clang, -O0):
<_dlinfo>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %rdx,-0x18(%rbp)
xor    %eax,%eax
pop    %rbp
ret

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

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

LLVM IR (-O2):
define i32 @_dlinfo(i8* nocapture readnone %0, i32 %1, i8* nocapture readnone %2) {
ret i32 0
}
/* Variables and functions */
int EINVAL;
__attribute__((visibility("default"))) int
sd_bus_add_object(void *bus, void **slot, const char *path, void *callback,
                  void *userdata) {
  return -EINVAL;
}


x86 assembly (clang, -O0):
<sd_bus_add_object>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
xor    %eax,%eax
mov    0x2ebf(%rip),%rcx
sub    (%rcx),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<sd_bus_add_object>:
mov    0x2ed9(%rip),%rcx
xor    %eax,%eax
sub    (%rcx),%eax
ret

LLVM IR (-O0):
@EINVAL = global i32 0
define i32 @sd_bus_add_object(i8* %0, i8** %1, i8* %2, i8* %3, i8* %4) {
%6 = alloca i8*
%7 = alloca i8**
%8 = alloca i8*
%9 = alloca i8*
%10 = alloca i8*
store i8* %0, i8** %6
store i8** %1, i8*** %7
store i8* %2, i8** %8
store i8* %3, i8** %9
store i8* %4, i8** %10
%11 = load i32, i32* @EINVAL
%12 = sub nsw i32 0, %11
ret i32 %12
}

LLVM IR (-O2):
@EINVAL = global i32 0
define i32 @sd_bus_add_object(i8* nocapture readnone %0, i8** nocapture readnone %1, i8* nocapture readnone %2, i8* nocapture readnone %3, i8* nocapture readnone %4) {
%6 = load i32, i32* @EINVAL
%7 = sub nsw i32 0, %6
ret i32 %7
}
/* Variables and functions */
int /*<<< orphan*/ abort();
void f1(void) { abort(); }


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

x86 assembly (clang, -O2):
<f1>:
push   %rax
xor    %eax,%eax
call   1030 <abort@plt>

LLVM IR (-O0):
define void @f1() {
%1 = call i32 (...) @abort()
unreachable
}

LLVM IR (-O2):
define void @f1() {
%1 = tail call i32 (...) @abort()
unreachable
}