xunge/DecIR huggingface dataset:
unsigned xrop3_255_1_1(unsigned char s, unsigned char t) {
  unsigned D = 0x00ff;
  unsigned S = ((unsigned)s << 8) | s;
  unsigned T = ((unsigned)t << 8) | t;
  unsigned stk1;
  stk1 = 0xffff;
  return (stk1 & (~S) & (~T)) | (D & S) | (D & T);
}


x86 assembly (clang, -O0):
<xrop3_255_1_1>:
push   %rbp
mov    %rsp,%rbp
mov    %sil,%al
mov    %dil,%cl
mov    %cl,-0x1(%rbp)
mov    %al,-0x2(%rbp)
movl   $0xff,-0x8(%rbp)
movzbl -0x1(%rbp),%eax
shl    $0x8,%eax
movzbl -0x1(%rbp),%ecx
or     %ecx,%eax
mov    %eax,-0xc(%rbp)
movzbl -0x2(%rbp),%eax
shl    $0x8,%eax
movzbl -0x2(%rbp),%ecx
or     %ecx,%eax
mov    %eax,-0x10(%rbp)
movl   $0xffff,-0x14(%rbp)
mov    -0x14(%rbp),%eax
mov    -0xc(%rbp),%ecx
xor    $0xffffffff,%ecx
and    %ecx,%eax
mov    -0x10(%rbp),%ecx
xor    $0xffffffff,%ecx
and    %ecx,%eax
mov    -0x8(%rbp),%ecx
and    -0xc(%rbp),%ecx
or     %ecx,%eax
mov    -0x8(%rbp),%ecx
and    -0x10(%rbp),%ecx
or     %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<xrop3_255_1_1>:
mov    %edi,%ecx
shl    $0x8,%ecx
or     %edi,%ecx
mov    %esi,%eax
shl    $0x8,%eax
or     %esi,%eax
xor    $0xffff,%ecx
not    %eax
and    %ecx,%eax
or     %edi,%esi
or     %esi,%eax
ret

LLVM IR (-O0):
define i32 @xrop3_255_1_1(i8 zeroext %0, i8 zeroext %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
store i32 255, i32* %5
%9 = load i8, i8* %3
%10 = zext i8 %9 to i32
%11 = shl i32 %10, 8
%12 = load i8, i8* %3
%13 = zext i8 %12 to i32
%14 = or i32 %11, %13
store i32 %14, i32* %6
%15 = load i8, i8* %4
%16 = zext i8 %15 to i32
%17 = shl i32 %16, 8
%18 = load i8, i8* %4
%19 = zext i8 %18 to i32
%20 = or i32 %17, %19
store i32 %20, i32* %7
store i32 65535, i32* %8
%21 = load i32, i32* %8
%22 = load i32, i32* %6
%23 = xor i32 %22, -1
%24 = and i32 %21, %23
%25 = load i32, i32* %7
%26 = xor i32 %25, -1
%27 = and i32 %24, %26
%28 = load i32, i32* %5
%29 = load i32, i32* %6
%30 = and i32 %28, %29
%31 = or i32 %27, %30
%32 = load i32, i32* %5
%33 = load i32, i32* %7
%34 = and i32 %32, %33
%35 = or i32 %31, %34
ret i32 %35
}

LLVM IR (-O2):
define i32 @xrop3_255_1_1(i8 zeroext %0, i8 zeroext %1) {
%3 = zext i8 %0 to i32
%4 = mul nuw nsw i32 %3, 257
%5 = zext i8 %1 to i32
%6 = mul nuw nsw i32 %5, 257
%7 = xor i32 %4, 65535
%8 = xor i32 %6, -1
%9 = and i32 %7, %8
%10 = or i8 %1, %0
%11 = zext i8 %10 to i32
%12 = or i32 %9, %11
ret i32 %12
}
/* Variables and functions */
char getchar();
int /*<<< orphan*/ printf(char *, ...);
int main() {
  int a = 0;
  char c;
  int sum;
  printf("Enter an abitrarily long string, ending with carriage return > ");
  while (c != '\n') {
    c = getchar();
    a += (int)c;
    sum = a % 64 + 22;
    sum = (char)sum;
  }
  printf("Check sum is %c\n", sum);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
lea    0xec3(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movsbl -0x9(%rbp),%eax
cmp    $0xa,%eax
je     1184 <main+0x64>
mov    $0x0,%al
call   1040 <getchar@plt>
mov    %al,-0x9(%rbp)
movsbl -0x9(%rbp),%eax
add    -0x8(%rbp),%eax
mov    %eax,-0x8(%rbp)
mov    -0x8(%rbp),%eax
mov    $0x40,%ecx
cltd
idiv   %ecx
add    $0x16,%edx
mov    %edx,-0x10(%rbp)
mov    -0x10(%rbp),%eax
movsbl %al,%eax
mov    %eax,-0x10(%rbp)
jmp    1144 <main+0x24>
mov    -0x10(%rbp),%esi
lea    0xeb2(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
@.str = [64 x i8] c"Enter an abitrarily long string, ending with carriage return > \00"
@.str.1 = [17 x i8] c"Check sum is %c\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i8
%4 = alloca i32
store i32 0, i32* %1
store i32 0, i32* %2
%5 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([64 x i8], [64 x i8]* @.str, i64 0, i64 0))
br label %6
6: ; preds = %10, %0
%7 = load i8, i8* %3
%8 = sext i8 %7 to i32
%9 = icmp ne i32 %8, 10
br i1 %9, label %10, label %22
10: ; preds = %6
%11 = call signext i8 (...) @getchar()
store i8 %11, i8* %3
%12 = load i8, i8* %3
%13 = sext i8 %12 to i32
%14 = load i32, i32* %2
%15 = add nsw i32 %14, %13
store i32 %15, i32* %2
%16 = load i32, i32* %2
%17 = srem i32 %16, 64
%18 = add nsw i32 %17, 22
store i32 %18, i32* %4
%19 = load i32, i32* %4
%20 = trunc i32 %19 to i8
%21 = sext i8 %20 to i32
store i32 %21, i32* %4
br label %6
22: ; preds = %6
%23 = load i32, i32* %4
%24 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.1, i64 0, i64 0), i32 %23)
ret i32 0
}

LLVM IR (-O2):
@.str = [64 x i8] c"Enter an abitrarily long string, ending with carriage return > \00"
define i32 @main() {
%1 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([64 x i8], [64 x i8]* @.str, i64 0, i64 0))
unreachable
}
/* Type definitions */
typedef int /*<<< orphan*/ v;
typedef int /*<<< orphan*/ uint16_t;
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
int fwrite(int /*<<< orphan*/ *, int, int, int /*<<< orphan*/ *);
int /*<<< orphan*/ htole16(int);
int xdf_write_uint16(FILE *out, int val) {
  uint16_t v;
  if (val < 0 || val > 65535)
    return 1;
  v = htole16(val);
  if (fwrite(&v, sizeof(v), 1, out) != 1)
    return 1;
  return 0;
}


x86 assembly (clang, -O0):
<xdf_write_uint16>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %esi,-0x14(%rbp)
cmpl   $0x0,-0x14(%rbp)
jl     1146 <xdf_write_uint16+0x26>
cmpl   $0xffff,-0x14(%rbp)
jle    1152 <xdf_write_uint16+0x32>
movl   $0x1,-0x4(%rbp)
jmp    1190 <xdf_write_uint16+0x70>
mov    -0x14(%rbp),%edi
call   1030 <htole16@plt>
mov    %eax,-0x18(%rbp)
mov    -0x10(%rbp),%rcx
lea    -0x18(%rbp),%rdi
mov    $0x4,%esi
mov    $0x1,%edx
call   1040 <fwrite@plt>
cmp    $0x1,%eax
je     1189 <xdf_write_uint16+0x69>
movl   $0x1,-0x4(%rbp)
jmp    1190 <xdf_write_uint16+0x70>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<xdf_write_uint16>:
mov    $0x1,%eax
cmp    $0xffff,%esi
ja     1166 <xdf_write_uint16+0x46>
push   %rbx
sub    $0x10,%rsp
mov    %rdi,%rbx
mov    %esi,%edi
call   1030 <htole16@plt>
mov    %eax,0xc(%rsp)
lea    0xc(%rsp),%rdi
mov    $0x4,%esi
mov    $0x1,%edx
mov    %rbx,%rcx
call   1040 <fwrite@plt>
mov    %eax,%ecx
xor    %eax,%eax
cmp    $0x1,%ecx
setne  %al
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
define i32 @xdf_write_uint16(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* %5
%8 = icmp slt i32 %7, 0
br i1 %8, label %12, label %9
9: ; preds = %2
%10 = load i32, i32* %5
%11 = icmp sgt i32 %10, 65535
br i1 %11, label %12, label %13
12: ; preds = %9, %2
store i32 1, i32* %3
br label %21
13: ; preds = %9
%14 = load i32, i32* %5
%15 = call i32 @htole16(i32 %14)
store i32 %15, i32* %6
%16 = load i32*, i32** %4
%17 = call i32 @fwrite(i32* %6, i32 4, i32 1, i32* %16)
%18 = icmp ne i32 %17, 1
br i1 %18, label %19, label %20
19: ; preds = %13
store i32 1, i32* %3
br label %21
20: ; preds = %13
store i32 0, i32* %3
br label %21
21: ; preds = %20, %19, %12
%22 = load i32, i32* %3
ret i32 %22
}

LLVM IR (-O2):
define i32 @xdf_write_uint16(i32* nocapture %0, i32 %1) {
%3 = alloca i32
%4 = bitcast i32* %3 to i8*
%5 = icmp ugt i32 %1, 65535
br i1 %5, label %11, label %6
6: ; preds = %2
%7 = tail call i32 @htole16(i32 %1)
store i32 %7, i32* %3
%8 = call i32 @fwrite(i32* %3, i32 4, i32 1, i32* %0)
%9 = icmp ne i32 %8, 1
%10 = zext i1 %9 to i32
br label %11
11: ; preds = %6, %2
%12 = phi i32 [ 1, %2 ], [ %10, %6 ]
ret i32 %12
}
int test_imm_2Buint8_reg(unsigned char val) {
  return ((val) & (0x2B << 0)) ? -20 : -40;
}


x86 assembly (clang, -O0):
<test_imm_2Buint8_reg>:
push   %rbp
mov    %rsp,%rbp
mov    %dil,%al
mov    %al,-0x1(%rbp)
movzbl -0x1(%rbp),%edx
and    $0x2b,%edx
mov    $0xffffffd8,%eax
mov    $0xffffffec,%ecx
cmp    $0x0,%edx
cmovne %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_imm_2Buint8_reg>:
test   $0x2b,%dil
mov    $0xffffffd8,%ecx
mov    $0xffffffec,%eax
cmove  %ecx,%eax
ret

LLVM IR (-O0):
define i32 @test_imm_2Buint8_reg(i8 zeroext %0) {
%2 = alloca i8
store i8 %0, i8* %2
%3 = load i8, i8* %2
%4 = zext i8 %3 to i32
%5 = and i32 %4, 43
%6 = icmp ne i32 %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_2Buint8_reg(i8 zeroext %0) {
%2 = and i8 %0, 43
%3 = icmp eq i8 %2, 0
%4 = select i1 %3, i32 -40, i32 -20
ret i32 %4
}
/* Variables and functions */
int /*<<< orphan*/ port_byte_out(int, unsigned char);
void set_cursor(int offset) {
  offset /= 2;
  port_byte_out(0x3D4, 14);
  port_byte_out(0x3D5, (unsigned char)(offset >> 8));
  port_byte_out(0x3D4, 15);
  port_byte_out(0x3D5, (unsigned char)offset);
}


x86 assembly (clang, -O0):
<set_cursor>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,-0x4(%rbp)
mov    $0x3d4,%edi
mov    $0xe,%esi
call   1030 <port_byte_out@plt>
mov    -0x4(%rbp),%eax
sar    $0x8,%eax
mov    $0x3d5,%edi
movzbl %al,%esi
call   1030 <port_byte_out@plt>
mov    $0x3d4,%edi
mov    $0xf,%esi
call   1030 <port_byte_out@plt>
mov    -0x4(%rbp),%eax
mov    $0x3d5,%edi
movzbl %al,%esi
call   1030 <port_byte_out@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<set_cursor>:
push   %rbx
mov    %edi,%ebx
shr    $0x1f,%ebx
add    %edi,%ebx
sar    %ebx
mov    $0x3d4,%edi
mov    $0xe,%esi
call   1030 <port_byte_out@plt>
movzbl %bh,%esi
mov    $0x3d5,%edi
call   1030 <port_byte_out@plt>
mov    $0x3d4,%edi
mov    $0xf,%esi
call   1030 <port_byte_out@plt>
movzbl %bl,%esi
mov    $0x3d5,%edi
pop    %rbx
jmp    1030 <port_byte_out@plt>

LLVM IR (-O0):
define void @set_cursor(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = sdiv i32 %3, 2
store i32 %4, i32* %2
%5 = call i32 @port_byte_out(i32 980, i8 zeroext 14)
%6 = load i32, i32* %2
%7 = ashr i32 %6, 8
%8 = trunc i32 %7 to i8
%9 = call i32 @port_byte_out(i32 981, i8 zeroext %8)
%10 = call i32 @port_byte_out(i32 980, i8 zeroext 15)
%11 = load i32, i32* %2
%12 = trunc i32 %11 to i8
%13 = call i32 @port_byte_out(i32 981, i8 zeroext %12)
ret void
}

LLVM IR (-O2):
define void @set_cursor(i32 %0) {
%2 = sdiv i32 %0, 2
%3 = tail call i32 @port_byte_out(i32 980, i8 zeroext 14)
%4 = lshr i32 %2, 8
%5 = trunc i32 %4 to i8
%6 = tail call i32 @port_byte_out(i32 981, i8 zeroext %5)
%7 = tail call i32 @port_byte_out(i32 980, i8 zeroext 15)
%8 = trunc i32 %2 to i8
%9 = tail call i32 @port_byte_out(i32 981, i8 zeroext %8)
ret void
}
void rte_prefetch2(const volatile void *p) {}


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

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

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

LLVM IR (-O2):
define void @rte_prefetch2(i8* nocapture %0) {
ret void
}
/* Type definitions */
typedef int uint32_t;

/* Variables and functions */
int read32(void *);
int /*<<< orphan*/ write32(int, void *);
void clrbits32(uint32_t bits, void *addr) {
  write32(read32(addr) & ~bits, addr);
}


x86 assembly (clang, -O0):
<clrbits32>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
call   1040 <read32@plt>
mov    %eax,%edi
mov    -0x4(%rbp),%eax
xor    $0xffffffff,%eax
and    %eax,%edi
mov    -0x10(%rbp),%rsi
call   1030 <write32@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<clrbits32>:
push   %rbp
push   %rbx
push   %rax
mov    %rsi,%rbx
mov    %edi,%ebp
mov    %rsi,%rdi
call   1040 <read32@plt>
not    %ebp
and    %eax,%ebp
mov    %ebp,%edi
mov    %rbx,%rsi
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1030 <write32@plt>

LLVM IR (-O0):
define void @clrbits32(i32 %0, i8* %1) {
%3 = alloca i32
%4 = alloca i8*
store i32 %0, i32* %3
store i8* %1, i8** %4
%5 = load i8*, i8** %4
%6 = call i32 @read32(i8* %5)
%7 = load i32, i32* %3
%8 = xor i32 %7, -1
%9 = and i32 %6, %8
%10 = load i8*, i8** %4
%11 = call i32 @write32(i32 %9, i8* %10)
ret void
}

LLVM IR (-O2):
define void @clrbits32(i32 %0, i8* %1) {
%3 = tail call i32 @read32(i8* %1)
%4 = xor i32 %0, -1
%5 = and i32 %3, %4
%6 = tail call i32 @write32(i32 %5, i8* %1)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ static_1();
int /*<<< orphan*/ static_2();
void func(void) {
  printf("func!\n");
  static_1();
  static_2();
}


x86 assembly (clang, -O0):
<func>:
push   %rbp
mov    %rsp,%rbp
lea    0xec5(%rip),%rdi
call   1040 <printf@plt>
mov    $0x0,%al
call   1030 <static_1@plt>
mov    $0x0,%al
call   1050 <static_2@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<func>:
push   %rax
lea    0xec8(%rip),%rdi
call   1040 <puts@plt>
xor    %eax,%eax
call   1030 <static_1@plt>
xor    %eax,%eax
pop    %rcx
jmp    1050 <static_2@plt>

LLVM IR (-O0):
@.str = [7 x i8] c"func!\0A\00"
define void @func() {
%1 = call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0))
%2 = call i32 (...) @static_1()
%3 = call i32 (...) @static_2()
ret void
}

LLVM IR (-O2):
@str = [6 x i8] c"func!\00"
define void @func() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @str, i64 0, i64 0))
%2 = tail call i32 (...) @static_1()
%3 = tail call i32 (...) @static_2()
ret void
}
char *strcat(char *dst, const char *src) {
  char *ret = dst;
  while (*dst)
    dst++;
  while ((*dst++ = *src++))
    ;
  return ret;
}


x86 assembly (clang, -O0):
<strcat>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    -0x8(%rbp),%rax
cmpb   $0x0,(%rax)
je     1132 <strcat+0x32>
mov    -0x8(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x8(%rbp)
jmp    1114 <strcat+0x14>
jmp    1137 <strcat+0x37>
mov    -0x10(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x10(%rbp)
mov    (%rax),%al
mov    -0x8(%rbp),%rcx
mov    %rcx,%rdx
add    $0x1,%rdx
mov    %rdx,-0x8(%rbp)
mov    %al,(%rcx)
cmp    $0x0,%al
je     1166 <strcat+0x66>
jmp    1137 <strcat+0x37>
mov    -0x18(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<strcat>:
mov    %rdi,%rax
mov    %rdi,%rcx
cs nopw 0x0(%rax,%rax,1)
cmpb   $0x0,(%rcx)
lea    0x1(%rcx),%rcx
jne    1110 <strcat+0x10>
xor    %edx,%edx
nopl   0x0(%rax,%rax,1)
movzbl (%rsi,%rdx,1),%edi
mov    %dil,-0x1(%rcx,%rdx,1)
add    $0x1,%rdx
test   %dil,%dil
jne    1120 <strcat+0x20>
ret

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

LLVM IR (-O2):
define i8* @strcat(i8* returned %0, i8* nocapture %1) {
br label %3
3: ; preds = %3, %2
%4 = phi i8* [ %0, %2 ], [ %7, %3 ]
%5 = load i8, i8* %4
%6 = icmp eq i8 %5, 0
%7 = getelementptr inbounds i8, i8* %4, i64 1
br i1 %6, label %8, label %3
8: ; preds = %3, %8
%9 = phi i8* [ %11, %8 ], [ %1, %3 ]
%10 = phi i8* [ %13, %8 ], [ %4, %3 ]
%11 = getelementptr inbounds i8, i8* %9, i64 1
%12 = load i8, i8* %9
%13 = getelementptr inbounds i8, i8* %10, i64 1
store i8 %12, i8* %10
%14 = icmp eq i8 %12, 0
br i1 %14, label %15, label %8
15: ; preds = %8
ret i8* %0
}
/* Variables and functions */
int /*<<< orphan*/ test_vhdl_comment_entities();
int /*<<< orphan*/ test_vhdl_comments();
void all_vhdl_tests() {
  test_vhdl_comments();
  test_vhdl_comment_entities();
}


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

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

LLVM IR (-O0):
define void @all_vhdl_tests() {
%1 = call i32 (...) @test_vhdl_comments()
%2 = call i32 (...) @test_vhdl_comment_entities()
ret void
}

LLVM IR (-O2):
define void @all_vhdl_tests() {
%1 = tail call i32 (...) @test_vhdl_comments()
%2 = tail call i32 (...) @test_vhdl_comment_entities()
ret void
}
void security_sb_umount_close(struct vfsmount *mnt) {}


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

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

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

LLVM IR (-O2):
%struct.vfsmount = type opaque
define void @security_sb_umount_close(%struct.vfsmount* nocapture %0) {
ret void
}
/* Variables and functions */
scalar_t__ istty();
char *rdz_gr() { return istty() ? "[1;30m" : ""; }


x86 assembly (clang, -O0):
<rdz_gr>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1030 <istty@plt>
mov    %rax,%rdx
lea    0xee2(%rip),%rax
lea    0xed4(%rip),%rcx
cmp    $0x0,%rdx
cmovne %rcx,%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<rdz_gr>:
push   %rax
xor    %eax,%eax
call   1030 <istty@plt>
test   %rax,%rax
lea    0xee5(%rip),%rcx
lea    0xed7(%rip),%rax
cmove  %rcx,%rax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [8 x i8] c"\1B[1;30m\00"
@.str.1 = [1 x i8] zeroinitializer
define i8* @rdz_gr() {
%1 = call i64 (...) @istty()
%2 = icmp ne i64 %1, 0
%3 = zext i1 %2 to i64
%4 = select i1 %2, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.1, i64 0, i64 0)
ret i8* %4
}

LLVM IR (-O2):
@.str = [8 x i8] c"\1B[1;30m\00"
@.str.1 = [1 x i8] zeroinitializer
define i8* @rdz_gr() {
%1 = tail call i64 (...) @istty()
%2 = icmp eq i64 %1, 0
%3 = select i1 %2, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0)
ret i8* %3
}
/* Type definitions */
typedef char *uint64_t;

/* Variables and functions */
uint64_t ec_atomic_cas64(uint64_t *mem, uint64_t with, uint64_t cmp) {
  uint64_t prev;
  __asm__ volatile("lock; cmpxchgq %1, %2"
                   : "=a"(prev)
                   : "r"(with), "m"(*(mem)), "0"(cmp)
                   : "memory");
  return prev;
}


x86 assembly (clang, -O0):
<ec_atomic_cas64>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x10(%rbp),%rcx
mov    -0x8(%rbp),%rdx
mov    -0x18(%rbp),%rax
lock cmpxchg %rcx,(%rdx)
mov    %rax,-0x20(%rbp)
mov    -0x20(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<ec_atomic_cas64>:
mov    %rdx,%rax
lock cmpxchg %rsi,(%rdi)
ret

LLVM IR (-O0):
define i8* @ec_atomic_cas64(i8** %0, i8* %1, i8* %2) {
%4 = alloca i8**
%5 = alloca i8*
%6 = alloca i8*
%7 = alloca i8*
store i8** %0, i8*** %4
store i8* %1, i8** %5
store i8* %2, i8** %6
%8 = load i8*, i8** %5
%9 = load i8**, i8*** %4
%10 = load i8*, i8** %6
%11 = call i8* asm sideeffect "lock; cmpxchgq $1, $2", "={ax},r,*m,0,~{memory},~{dirflag},~{fpsr},~{flags}"(i8* %8, i8** elementtype(i8*) %9, i8* %10)
store i8* %11, i8** %7
%12 = load i8*, i8** %7
ret i8* %12
}

LLVM IR (-O2):
define i8* @ec_atomic_cas64(i8** %0, i8* %1, i8* %2) {
%4 = tail call i8* asm sideeffect "lock; cmpxchgq $1, $2", "={ax},r,*m,0,~{memory},~{dirflag},~{fpsr},~{flags}"(i8* %1, i8** elementtype(i8*) %0, i8* %2)
ret i8* %4
}
/* Variables and functions */
int /*<<< orphan*/ FIONBIO;
int ioctl(int, int /*<<< orphan*/, int *);
int make_socket_non_blocking(int sfd) {
  int nb;
  nb = 1;
  return ioctl(sfd, FIONBIO, &nb);
}


x86 assembly (clang, -O0):
<make_socket_non_blocking>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
movl   $0x1,-0x8(%rbp)
mov    -0x4(%rbp),%edi
mov    0x2eb4(%rip),%rax
mov    (%rax),%esi
lea    -0x8(%rbp),%rdx
call   1030 <ioctl@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<make_socket_non_blocking>:
push   %rax
movl   $0x1,0x4(%rsp)
mov    0x2ec0(%rip),%rax
mov    (%rax),%esi
lea    0x4(%rsp),%rdx
call   1030 <ioctl@plt>
pop    %rcx
ret

LLVM IR (-O0):
@FIONBIO = global i32 0
define i32 @make_socket_non_blocking(i32 %0) {
%2 = alloca i32
%3 = alloca i32
store i32 %0, i32* %2
store i32 1, i32* %3
%4 = load i32, i32* %2
%5 = load i32, i32* @FIONBIO
%6 = call i32 @ioctl(i32 %4, i32 %5, i32* %3)
ret i32 %6
}

LLVM IR (-O2):
@FIONBIO = global i32 0
define i32 @make_socket_non_blocking(i32 %0) {
%2 = alloca i32
%3 = bitcast i32* %2 to i8*
store i32 1, i32* %2
%4 = load i32, i32* @FIONBIO
%5 = call i32 @ioctl(i32 %0, i32 %4, i32* %2)
ret i32 %5
}
void __DELETE_org_apache_harmony_luni_util_PriviAction(void *me,
                                                       void *client_data) {}


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

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

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

LLVM IR (-O2):
define void @__DELETE_org_apache_harmony_luni_util_PriviAction(i8* nocapture %0, i8* nocapture %1) {
ret void
}
void MUSIC_SetSongTime(unsigned long milliseconds) {}


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

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

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

LLVM IR (-O2):
define void @MUSIC_SetSongTime(i64 %0) {
ret void
}
/* Type definitions */
struct termios {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ TCSANOW;
int close(int);
int /*<<< orphan*/ tcsetattr(int, int /*<<< orphan*/, struct termios *);
int close_serial(int fd, struct termios *old) {
  tcsetattr(fd, TCSANOW, old);
  return close(fd);
}


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

x86 assembly (clang, -O2):
<close_serial>:
push   %rbx
mov    %rsi,%rdx
mov    %edi,%ebx
mov    0x2ebb(%rip),%rax
mov    (%rax),%esi
call   1040 <tcsetattr@plt>
mov    %ebx,%edi
pop    %rbx
jmp    1030 <close@plt>

LLVM IR (-O0):
%struct.termios = type { i32 }
@TCSANOW = global i32 0
define i32 @close_serial(i32 %0, %struct.termios* %1) {
%3 = alloca i32
%4 = alloca %struct.termios*
store i32 %0, i32* %3
store %struct.termios* %1, %struct.termios** %4
%5 = load i32, i32* %3
%6 = load i32, i32* @TCSANOW
%7 = load %struct.termios*, %struct.termios** %4
%8 = call i32 @tcsetattr(i32 %5, i32 %6, %struct.termios* %7)
%9 = load i32, i32* %3
%10 = call i32 @close(i32 %9)
ret i32 %10
}

LLVM IR (-O2):
%struct.termios = type { i32 }
@TCSANOW = global i32 0
define i32 @close_serial(i32 %0, %struct.termios* %1) {
%3 = load i32, i32* @TCSANOW
%4 = tail call i32 @tcsetattr(i32 %0, i32 %3, %struct.termios* %1)
%5 = tail call i32 @close(i32 %0)
ret i32 %5
}
/* Variables and functions */
int /*<<< orphan*/ Input_ensure_EOS();
int /*<<< orphan*/ Output_byte(int);
void group_only_implied_addressing(int opcode) {
  Output_byte(opcode);
  Input_ensure_EOS();
}


x86 assembly (clang, -O0):
<group_only_implied_addressing>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%edi
call   1040 <Output_byte@plt>
mov    $0x0,%al
call   1030 <Input_ensure_EOS@plt>
add    $0x10,%rsp
pop    %rbp
ret

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

LLVM IR (-O0):
define void @group_only_implied_addressing(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = call i32 @Output_byte(i32 %3)
%5 = call i32 (...) @Input_ensure_EOS()
ret void
}

LLVM IR (-O2):
define void @group_only_implied_addressing(i32 %0) {
%2 = tail call i32 @Output_byte(i32 %0)
%3 = tail call i32 (...) @Input_ensure_EOS()
ret void
}
int notifier_from_errno(int err) {
  if (err)
    return 0x8000 | (0x0001 - err);
  return 0x0001;
}


x86 assembly (clang, -O0):
<notifier_from_errno>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x8(%rbp)
cmpl   $0x0,-0x8(%rbp)
je     1126 <notifier_from_errno+0x26>
mov    $0x1,%eax
sub    -0x8(%rbp),%eax
or     $0x8000,%eax
mov    %eax,-0x4(%rbp)
jmp    112d <notifier_from_errno+0x2d>
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<notifier_from_errno>:
mov    $0x1,%ecx
mov    $0x1,%eax
sub    %edi,%eax
or     $0x8000,%eax
test   %edi,%edi
cmove  %ecx,%eax
ret

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

LLVM IR (-O2):
define i32 @notifier_from_errno(i32 %0) {
%2 = icmp eq i32 %0, 0
%3 = sub nsw i32 1, %0
%4 = or i32 %3, 32768
%5 = select i1 %2, i32 1, i32 %4
ret i32 %5
}
/* Variables and functions */
int /*<<< orphan*/ ao();
int /*<<< orphan*/ mav(int, int);
int /*<<< orphan*/ msleep(int);
int /*<<< orphan*/ printf(char *);
int main() {
  printf("andrew!\n");
  mav(0, 1000);
  mav(2, 1000);
  msleep(5000);
  ao();
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeaa(%rip),%rdi
call   1040 <printf@plt>
xor    %edi,%edi
mov    $0x3e8,%esi
call   1050 <mav@plt>
mov    $0x2,%edi
mov    $0x3e8,%esi
call   1050 <mav@plt>
mov    $0x1388,%edi
call   1030 <msleep@plt>
mov    $0x0,%al
call   1060 <ao@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xeb8(%rip),%rdi
call   1030 <puts@plt>
xor    %edi,%edi
mov    $0x3e8,%esi
call   1050 <mav@plt>
mov    $0x2,%edi
mov    $0x3e8,%esi
call   1050 <mav@plt>
mov    $0x1388,%edi
call   1040 <msleep@plt>
xor    %eax,%eax
call   1060 <ao@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [9 x i8] c"andrew!\0A\00"
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = call i32 @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0))
%3 = call i32 @mav(i32 0, i32 1000)
%4 = call i32 @mav(i32 2, i32 1000)
%5 = call i32 @msleep(i32 5000)
%6 = call i32 (...) @ao()
ret i32 0
}

LLVM IR (-O2):
@str = [8 x i8] c"andrew!\00"
define i32 @main() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([8 x i8], [8 x i8]* @str, i64 0, i64 0))
%2 = tail call i32 @mav(i32 0, i32 1000)
%3 = tail call i32 @mav(i32 2, i32 1000)
%4 = tail call i32 @msleep(i32 5000)
%5 = tail call i32 (...) @ao()
ret i32 0
}
/* Variables and functions */
scalar_t__ memcmp(char *, char *, int);
bool strings_bounded_equals(char *a, char *b, unsigned int size) {
  if (size == 0)
    return true;
  return memcmp(a, b, sizeof(char) * size) == 0;
}


x86 assembly (clang, -O0):
<strings_bounded_equals>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    %edx,-0x1c(%rbp)
cmpl   $0x0,-0x1c(%rbp)
jne    1139 <strings_bounded_equals+0x29>
movl   $0x1,-0x4(%rbp)
jmp    115e <strings_bounded_equals+0x4e>
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
mov    -0x1c(%rbp),%eax
shl    $0x0,%rax
mov    %eax,%edx
call   1030 <memcmp@plt>
cmp    $0x0,%rax
sete   %al
and    $0x1,%al
movzbl %al,%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<strings_bounded_equals>:
test   %edx,%edx
je     112a <strings_bounded_equals+0x1a>
push   %rax
call   1030 <memcmp@plt>
mov    %rax,%rcx
xor    %eax,%eax
test   %rcx,%rcx
sete   %al
add    $0x8,%rsp
ret
mov    $0x1,%eax
ret

LLVM IR (-O0):
define i32 @strings_bounded_equals(i8* %0, i8* %1, i32 %2) {
%4 = alloca i32
%5 = alloca i8*
%6 = alloca i8*
%7 = alloca i32
store i8* %0, i8** %5
store i8* %1, i8** %6
store i32 %2, i32* %7
%8 = load i32, i32* %7
%9 = icmp eq i32 %8, 0
br i1 %9, label %10, label %11
10: ; preds = %3
store i32 1, i32* %4
br label %21
11: ; preds = %3
%12 = load i8*, i8** %5
%13 = load i8*, i8** %6
%14 = load i32, i32* %7
%15 = zext i32 %14 to i64
%16 = mul i64 1, %15
%17 = trunc i64 %16 to i32
%18 = call i64 @memcmp(i8* %12, i8* %13, i32 %17)
%19 = icmp eq i64 %18, 0
%20 = zext i1 %19 to i32
store i32 %20, i32* %4
br label %21
21: ; preds = %11, %10
%22 = load i32, i32* %4
ret i32 %22
}

LLVM IR (-O2):
define i32 @strings_bounded_equals(i8* %0, i8* %1, i32 %2) {
%4 = icmp eq i32 %2, 0
br i1 %4, label %9, label %5
5: ; preds = %3
%6 = tail call i64 @memcmp(i8* %0, i8* %1, i32 %2)
%7 = icmp eq i64 %6, 0
%8 = zext i1 %7 to i32
br label %9
9: ; preds = %3, %5
%10 = phi i32 [ %8, %5 ], [ 1, %3 ]
ret i32 %10
}
/* Variables and functions */
scalar_t__ get_int(int /*<<< orphan*/);
int /*<<< orphan*/ insert(int);
void read() {
  do {
    insert(23);
  } while (get_int(0));
}


x86 assembly (clang, -O0):
<read>:
push   %rbp
mov    %rsp,%rbp
jmp    1129 <read+0x9>
mov    $0x17,%edi
call   1030 <insert@plt>
xor    %edi,%edi
call   1040 <get_int@plt>
cmp    $0x0,%rax
jne    1129 <read+0x9>
pop    %rbp
ret

x86 assembly (clang, -O2):
<read>:
push   %rax
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
mov    $0x17,%edi
call   1030 <insert@plt>
xor    %edi,%edi
call   1040 <get_int@plt>
test   %rax,%rax
jne    1130 <read+0x10>
pop    %rax
ret

LLVM IR (-O0):
define void @read() {
br label %1
1: ; preds = %3, %0
%2 = call i32 @insert(i32 23)
br label %3
3: ; preds = %1
%4 = call i64 @get_int(i32 0)
%5 = icmp ne i64 %4, 0
br i1 %5, label %1, label %6
6: ; preds = %3
ret void
}

LLVM IR (-O2):
define void @read() {
br label %1
1: ; preds = %1, %0
%2 = tail call i32 @insert(i32 23)
%3 = tail call i64 @get_int(i32 0)
%4 = icmp eq i64 %3, 0
br i1 %4, label %5, label %1
5: ; preds = %1
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *, int);
void INTFC_tourDeJeu(int k) {
  printf("\n\n\033[1;4m[ Tour De Jeu Numero %d ]\033[0m \n\n", k);
}


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

x86 assembly (clang, -O2):
<INTFC_tourDeJeu>:
mov    %edi,%esi
lea    0xee7(%rip),%rdi
jmp    1030 <printf@plt>

LLVM IR (-O0):
@.str = [41 x i8] c"\0A\0A\1B[1;4m[ Tour De Jeu Numero %d ]\1B[0m \0A\0A\00"
define void @INTFC_tourDeJeu(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = call i32 @printf(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str, i64 0, i64 0), i32 %3)
ret void
}

LLVM IR (-O2):
@.str = [41 x i8] c"\0A\0A\1B[1;4m[ Tour De Jeu Numero %d ]\1B[0m \0A\0A\00"
define void @INTFC_tourDeJeu(i32 %0) {
%2 = tail call i32 @printf(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str, i64 0, i64 0), i32 %0)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int /*<<< orphan*/, char *, int, char *);
int /*<<< orphan*/ isprint(int);
void t_isprint_0x63() {
  Assert_real((isprint(99)),
              "/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_isprint.c",
              500, ("isprint should be 1 for c"));
}


x86 assembly (clang, -O0):
<t_isprint_0x63>:
push   %rbp
mov    %rsp,%rbp
mov    $0x63,%edi
call   1030 <isprint@plt>
mov    %eax,%edi
lea    0xec9(%rip),%rsi
mov    $0x1f4,%edx
lea    0xf65(%rip),%rcx
call   1040 <Assert_real@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<t_isprint_0x63>:
push   %rax
mov    $0x63,%edi
call   1030 <isprint@plt>
lea    0xece(%rip),%rsi
lea    0xf6f(%rip),%rcx
mov    %eax,%edi
mov    $0x1f4,%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_isprint.c\00"
@.str.1 = [26 x i8] c"isprint should be 1 for c\00"
define void @t_isprint_0x63() {
%1 = call i32 @isprint(i32 99)
%2 = call i32 @Assert_real(i32 %1, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 500, 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_isprint.c\00"
@.str.1 = [26 x i8] c"isprint should be 1 for c\00"
define void @t_isprint_0x63() {
%1 = tail call i32 @isprint(i32 99)
%2 = tail call i32 @Assert_real(i32 %1, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 500, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ dbg_break();
void gdb_arch_set_register(void) { dbg_break(); }


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

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

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

LLVM IR (-O2):
define void @gdb_arch_set_register() {
%1 = tail call i32 (...) @dbg_break()
ret void
}
void v9fs_cache_unregister(void) {}


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

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

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

LLVM IR (-O2):
define void @v9fs_cache_unregister() {
ret void
}
/* Variables and functions */
int calcgoerzel();
int /*<<< orphan*/ init();
int /*<<< orphan*/ printf(char *, int);
int /*<<< orphan*/ takesamples();
int main() {
  takesamples();
  init();
  printf("\nMAX at: %d Hz\n\n", calcgoerzel());
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0x0,%al
call   1060 <takesamples@plt>
mov    $0x0,%al
call   1050 <init@plt>
mov    $0x0,%al
call   1040 <calcgoerzel@plt>
mov    %eax,%esi
lea    0xe93(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
xor    %eax,%eax
call   1060 <takesamples@plt>
xor    %eax,%eax
call   1050 <init@plt>
xor    %eax,%eax
call   1040 <calcgoerzel@plt>
lea    0xea3(%rip),%rdi
mov    %eax,%esi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [17 x i8] c"\0AMAX at: %d Hz\0A\0A\00"
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = call i32 (...) @takesamples()
%3 = call i32 (...) @init()
%4 = call i32 (...) @calcgoerzel()
%5 = call i32 @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0), i32 %4)
ret i32 0
}

LLVM IR (-O2):
@.str = [17 x i8] c"\0AMAX at: %d Hz\0A\0A\00"
define i32 @main() {
%1 = tail call i32 (...) @takesamples()
%2 = tail call i32 (...) @init()
%3 = tail call i32 (...) @calcgoerzel()
%4 = tail call i32 @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0), i32 %3)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ call();
void cpu_call_nn() { call(); }


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

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

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

LLVM IR (-O2):
define void @cpu_call_nn() {
%1 = tail call i32 (...) @call()
ret void
}
/* Type definitions */
struct tdb_context {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ F_RDLCK;
int /*<<< orphan*/ F_SETLKW;
int _tdb_lockall(struct tdb_context *, int /*<<< orphan*/, int /*<<< orphan*/);
int ext2fs_tdb_lockall_read(struct tdb_context *tdb) {
  return _tdb_lockall(tdb, F_RDLCK, F_SETLKW);
}


x86 assembly (clang, -O0):
<ext2fs_tdb_lockall_read>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
mov    0x2ea9(%rip),%rax
mov    (%rax),%esi
mov    0x2eb8(%rip),%rax
mov    (%rax),%edx
call   1030 <_tdb_lockall@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ext2fs_tdb_lockall_read>:
mov    0x2eb9(%rip),%rax
mov    (%rax),%esi
mov    0x2ec8(%rip),%rax
mov    (%rax),%edx
jmp    1030 <_tdb_lockall@plt>

LLVM IR (-O0):
%struct.tdb_context = type { i32 }
@F_RDLCK = global i32 0
@F_SETLKW = global i32 0
define i32 @ext2fs_tdb_lockall_read(%struct.tdb_context* %0) {
%2 = alloca %struct.tdb_context*
store %struct.tdb_context* %0, %struct.tdb_context** %2
%3 = load %struct.tdb_context*, %struct.tdb_context** %2
%4 = load i32, i32* @F_RDLCK
%5 = load i32, i32* @F_SETLKW
%6 = call i32 @_tdb_lockall(%struct.tdb_context* %3, i32 %4, i32 %5)
ret i32 %6
}

LLVM IR (-O2):
%struct.tdb_context = type { i32 }
@F_RDLCK = global i32 0
@F_SETLKW = global i32 0
define i32 @ext2fs_tdb_lockall_read(%struct.tdb_context* %0) {
%2 = load i32, i32* @F_RDLCK
%3 = load i32, i32* @F_SETLKW
%4 = tail call i32 @_tdb_lockall(%struct.tdb_context* %0, i32 %2, i32 %3)
ret i32 %4
}
/* Variables and functions */
int /*<<< orphan*/ _hmt_register_covercase(char *, char *);
void _hmt_covercase_HMM_EqualsVec4_init(void) {
  _hmt_register_covercase("HMM_EqualsVec4", "1");
}


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

x86 assembly (clang, -O2):
<_hmt_covercase_HMM_EqualsVec4_init>:
lea    0xee9(%rip),%rdi
lea    0xef1(%rip),%rsi
jmp    1030 <_hmt_register_covercase@plt>

LLVM IR (-O0):
@.str = [15 x i8] c"HMM_EqualsVec4\00"
@.str.1 = [2 x i8] c"1\00"
define void @_hmt_covercase_HMM_EqualsVec4_init() {
%1 = call i32 @_hmt_register_covercase(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [15 x i8] c"HMM_EqualsVec4\00"
@.str.1 = [2 x i8] c"1\00"
define void @_hmt_covercase_HMM_EqualsVec4_init() {
%1 = tail call i32 @_hmt_register_covercase(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
ret void
}
char *colon(char *cp) {
  while (*cp) {
    if (*cp == ':')
      return (cp);
    if (*cp == '/')
      return (0);
    cp++;
  }
  return (0);
}


x86 assembly (clang, -O0):
<colon>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
cmpb   $0x0,(%rax)
je     1160 <colon+0x60>
mov    -0x10(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x3a,%eax
jne    1132 <colon+0x32>
mov    -0x10(%rbp),%rax
mov    %rax,-0x8(%rbp)
jmp    1168 <colon+0x68>
mov    -0x10(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x2f,%eax
jne    114f <colon+0x4f>
movq   $0x0,-0x8(%rbp)
jmp    1168 <colon+0x68>
mov    -0x10(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x10(%rbp)
jmp    1108 <colon+0x8>
movq   $0x0,-0x8(%rbp)
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<colon>:
mov    %rdi,%rax
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
movzbl (%rax),%ecx
test   %cl,%cl
je     1127 <colon+0x27>
cmp    $0x2f,%cl
je     1127 <colon+0x27>
cmp    $0x3a,%cl
je     1129 <colon+0x29>
add    $0x1,%rax
jmp    1110 <colon+0x10>
xor    %eax,%eax
ret

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

LLVM IR (-O2):
define i8* @colon(i8* %0) {
br label %2
2: ; preds = %5, %1
%3 = phi i8* [ %0, %1 ], [ %6, %5 ]
%4 = load i8, i8* %3
switch i8 %4, label %5 [
i8 0, label %8
i8 58, label %7
i8 47, label %8
]
5: ; preds = %2
%6 = getelementptr inbounds i8, i8* %3, i64 1
br label %2
7: ; preds = %2
br label %8
8: ; preds = %2, %2, %7
%9 = phi i8* [ %3, %7 ], [ null, %2 ], [ null, %2 ]
ret i8* %9
}
/* Variables and functions */
int /*<<< orphan*/ getenv_r(char *, char *, int);
int /*<<< orphan*/ printf(char *, char *);
int main(int argc, char const *argv[]) {
  char buf[1024];
  getenv_r("PATH", buf, 1024);
  printf("PATH = %s\n", buf);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x410,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
lea    -0x410(%rbp),%rsi
lea    0xeb9(%rip),%rdi
mov    $0x400,%edx
call   1040 <getenv_r@plt>
lea    -0x410(%rbp),%rsi
lea    0xea6(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x410,%rsp
pop    %rbp
ret

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

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

LLVM IR (-O2):
@.str = [5 x i8] c"PATH\00"
@.str.1 = [11 x i8] c"PATH = %s\0A\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = alloca [1024 x i8]
%4 = getelementptr inbounds [1024 x i8], [1024 x i8]* %3, i64 0, i64 0
%5 = call i32 @getenv_r(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i8* %4, i32 1024)
%6 = call i32 @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0), i8* %4)
ret i32 0
}
/* Variables and functions */
int /*<<< orphan*/ DB_PutChar(char);
int DB_PrintString(char *string) {
  int count;
  char *ptr;
  ptr = string;
  count = 0;
  while (*ptr) {
    DB_PutChar(*ptr);
    count++;
    ptr++;
  }
  return (count);
}


x86 assembly (clang, -O0):
<DB_PrintString>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x18(%rbp)
movl   $0x0,-0xc(%rbp)
mov    -0x18(%rbp),%rax
cmpb   $0x0,(%rax)
je     115e <DB_PrintString+0x4e>
mov    -0x18(%rbp),%rax
movsbl (%rax),%edi
call   1030 <DB_PutChar@plt>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
mov    -0x18(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x18(%rbp)
jmp    112b <DB_PrintString+0x1b>
mov    -0xc(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<DB_PrintString>:
push   %r14
push   %rbx
push   %rax
mov    (%rdi),%al
test   %al,%al
je     1138 <DB_PrintString+0x28>
mov    %rdi,%r14
xor    %ebx,%ebx
nop
movsbl %al,%edi
call   1030 <DB_PutChar@plt>
movzbl 0x1(%r14,%rbx,1),%eax
add    $0x1,%rbx
test   %al,%al
jne    1120 <DB_PrintString+0x10>
jmp    113a <DB_PrintString+0x2a>
xor    %ebx,%ebx
mov    %ebx,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
define i32 @DB_PrintString(i8* %0) {
%2 = alloca i8*
%3 = alloca i32
%4 = alloca i8*
store i8* %0, i8** %2
%5 = load i8*, i8** %2
store i8* %5, i8** %4
store i32 0, i32* %3
br label %6
6: ; preds = %10, %1
%7 = load i8*, i8** %4
%8 = load i8, i8* %7
%9 = icmp ne i8 %8, 0
br i1 %9, label %10, label %18
10: ; preds = %6
%11 = load i8*, i8** %4
%12 = load i8, i8* %11
%13 = call i32 @DB_PutChar(i8 signext %12)
%14 = load i32, i32* %3
%15 = add nsw i32 %14, 1
store i32 %15, i32* %3
%16 = load i8*, i8** %4
%17 = getelementptr inbounds i8, i8* %16, i32 1
store i8* %17, i8** %4
br label %6
18: ; preds = %6
%19 = load i32, i32* %3
ret i32 %19
}

LLVM IR (-O2):
define i32 @DB_PrintString(i8* nocapture %0) {
%2 = load i8, i8* %0
%3 = icmp eq i8 %2, 0
br i1 %3, label %13, label %4
4: ; preds = %1, %4
%5 = phi i8 [ %11, %4 ], [ %2, %1 ]
%6 = phi i8* [ %10, %4 ], [ %0, %1 ]
%7 = phi i32 [ %9, %4 ], [ 0, %1 ]
%8 = tail call i32 @DB_PutChar(i8 signext %5)
%9 = add nuw nsw i32 %7, 1
%10 = getelementptr inbounds i8, i8* %6, i64 1
%11 = load i8, i8* %10
%12 = icmp eq i8 %11, 0
br i1 %12, label %13, label %4
13: ; preds = %4, %1
%14 = phi i32 [ 0, %1 ], [ %9, %4 ]
ret i32 %14
}
void foo_2_1_2_2_1_1_1_1_1() {}


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

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

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

LLVM IR (-O2):
define void @foo_2_1_2_2_1_1_1_1_1() {
ret void
}
/* Variables and functions */
double omp_get_wtime();
double secnds() { return omp_get_wtime(); }


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

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

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

LLVM IR (-O2):
define double @secnds() {
%1 = tail call double (...) @omp_get_wtime()
ret double %1
}