xunge/DecIR huggingface dataset:
/* Variables and functions */
int /*<<< orphan*/ THAtomicCompareAndSwap(int volatile *, int, int);
int THAtomicGet(int volatile *a) {
  int value;
  do {
    value = *a;
  } while (!THAtomicCompareAndSwap(a, value, value));
  return value;
}


x86 assembly (clang, -O0):
<THAtomicGet>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%eax
mov    %eax,-0xc(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
mov    -0xc(%rbp),%edx
call   1030 <THAtomicCompareAndSwap@plt>
cmp    $0x0,%eax
setne  %al
xor    $0xff,%al
test   $0x1,%al
jne    111c <THAtomicGet+0xc>
mov    -0xc(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<THAtomicGet>:
push   %rbp
push   %rbx
push   %rax
mov    %rdi,%rbx
cs nopw 0x0(%rax,%rax,1)
mov    (%rbx),%ebp
mov    %rbx,%rdi
mov    %ebp,%esi
mov    %ebp,%edx
call   1030 <THAtomicCompareAndSwap@plt>
test   %eax,%eax
je     1120 <THAtomicGet+0x10>
mov    %ebp,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
define i32 @THAtomicGet(i32* %0) {
%2 = alloca i32*
%3 = alloca i32
store i32* %0, i32** %2
br label %4
4: ; preds = %7, %1
%5 = load i32*, i32** %2
%6 = load volatile i32, i32* %5
store i32 %6, i32* %3
br label %7
7: ; preds = %4
%8 = load i32*, i32** %2
%9 = load i32, i32* %3
%10 = load i32, i32* %3
%11 = call i32 @THAtomicCompareAndSwap(i32* %8, i32 %9, i32 %10)
%12 = icmp ne i32 %11, 0
%13 = xor i1 %12, true
br i1 %13, label %4, label %14
14: ; preds = %7
%15 = load i32, i32* %3
ret i32 %15
}

LLVM IR (-O2):
define i32 @THAtomicGet(i32* %0) {
br label %2
2: ; preds = %2, %1
%3 = load volatile i32, i32* %0
%4 = tail call i32 @THAtomicCompareAndSwap(i32* %0, i32 %3, i32 %3)
%5 = icmp eq i32 %4, 0
br i1 %5, label %2, label %6
6: ; preds = %2
ret i32 %3
}
/* Forward declarations */
typedef struct TYPE_4__ TYPE_2__;
typedef struct TYPE_3__ TYPE_1__;

/* Type definitions */
struct TYPE_3__ {
  int height;
};
struct TYPE_4__ {
  TYPE_1__ xconfigure;
};
typedef TYPE_2__ XEvent;

/* Variables and functions */
void set_XEvent_xconfigure_height(void *_p, int _v) {
  ((XEvent *)_p)->xconfigure.height = (int)_v;
}


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

x86 assembly (clang, -O2):
<set_XEvent_xconfigure_height>:
mov    %esi,(%rdi)
ret

LLVM IR (-O0):
%struct.TYPE_4__ = type { %struct.TYPE_3__ }
%struct.TYPE_3__ = type { i32 }
define void @set_XEvent_xconfigure_height(i8* %0, i32 %1) {
%3 = alloca i8*
%4 = alloca i32
store i8* %0, i8** %3
store i32 %1, i32* %4
%5 = load i32, i32* %4
%6 = load i8*, i8** %3
%7 = bitcast i8* %6 to %struct.TYPE_4__*
%8 = getelementptr inbounds %struct.TYPE_4__, %struct.TYPE_4__* %7, i32 0, i32 0
%9 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %8, i32 0, i32 0
store i32 %5, i32* %9
ret void
}

LLVM IR (-O2):
define void @set_XEvent_xconfigure_height(i8* nocapture writeonly %0, i32 %1) {
%3 = bitcast i8* %0 to i32*
store i32 %1, i32* %3
ret void
}
int test_imm_F2uint16_reg(unsigned short val) {
  return ((val) & (0xF2 << 0)) ? -20 : -40;
}


x86 assembly (clang, -O0):
<test_imm_F2uint16_reg>:
push   %rbp
mov    %rsp,%rbp
mov    %di,%ax
mov    %ax,-0x2(%rbp)
movzwl -0x2(%rbp),%edx
and    $0xf2,%edx
mov    $0xffffffd8,%eax
mov    $0xffffffec,%ecx
cmp    $0x0,%edx
cmovne %ecx,%eax
pop    %rbp
ret

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

LLVM IR (-O0):
define i32 @test_imm_F2uint16_reg(i16 zeroext %0) {
%2 = alloca i16
store i16 %0, i16* %2
%3 = load i16, i16* %2
%4 = zext i16 %3 to i32
%5 = and i32 %4, 242
%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_F2uint16_reg(i16 zeroext %0) {
%2 = and i16 %0, 242
%3 = icmp eq i16 %2, 0
%4 = select i1 %3, i32 -40, i32 -20
ret i32 %4
}
/* Type definitions */
struct aXInfo {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ printf(char *, char *);
int alock_check_xrender(const struct aXInfo *xinfo) {
  printf("%s", "alock: error, i wasnt compiled to support xrender.\n");
  return 0;
}


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

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

LLVM IR (-O0):
%struct.aXInfo = type { i32 }
@.str = [3 x i8] c"%s\00"
@.str.1 = [52 x i8] c"alock: error, i wasnt compiled to support xrender.\0A\00"
define i32 @alock_check_xrender(%struct.aXInfo* %0) {
%2 = alloca %struct.aXInfo*
store %struct.aXInfo* %0, %struct.aXInfo** %2
%3 = call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([52 x i8], [52 x i8]* @.str.1, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
%struct.aXInfo = type { i32 }
@.str = [3 x i8] c"%s\00"
@.str.1 = [52 x i8] c"alock: error, i wasnt compiled to support xrender.\0A\00"
define i32 @alock_check_xrender(%struct.aXInfo* nocapture readnone %0) {
%2 = tail call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([52 x i8], [52 x i8]* @.str.1, i64 0, i64 0))
ret i32 0
}
int is_ascii_string(const char *str) {
  while (*str) {
    if (*str & 0x80)
      return 0;
    str++;
  }
  return 1;
}


x86 assembly (clang, -O0):
<is_ascii_string>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
cmpb   $0x0,(%rax)
je     1147 <is_ascii_string+0x47>
mov    -0x10(%rbp),%rax
movsbl (%rax),%eax
and    $0x80,%eax
cmp    $0x0,%eax
je     1136 <is_ascii_string+0x36>
movl   $0x0,-0x4(%rbp)
jmp    114e <is_ascii_string+0x4e>
mov    -0x10(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x10(%rbp)
jmp    1108 <is_ascii_string+0x8>
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_ascii_string>:
mov    (%rdi),%cl
mov    $0x1,%eax
test   %cl,%cl
je     111f <is_ascii_string+0x1f>
add    $0x1,%rdi
nop
test   %cl,%cl
js     1120 <is_ascii_string+0x20>
movzbl (%rdi),%ecx
add    $0x1,%rdi
test   %cl,%cl
jne    1110 <is_ascii_string+0x10>
ret
xor    %eax,%eax
ret

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

LLVM IR (-O2):
define i32 @is_ascii_string(i8* nocapture %0) {
%2 = load i8, i8* %0
%3 = icmp eq i8 %2, 0
br i1 %3, label %12, label %7
4: ; preds = %7
%5 = load i8, i8* %11
%6 = icmp eq i8 %5, 0
br i1 %6, label %12, label %7
7: ; preds = %1, %4
%8 = phi i8 [ %5, %4 ], [ %2, %1 ]
%9 = phi i8* [ %11, %4 ], [ %0, %1 ]
%10 = icmp sgt i8 %8, -1
%11 = getelementptr inbounds i8, i8* %9, i64 1
br i1 %10, label %4, label %12
12: ; preds = %7, %4, %1
%13 = phi i32 [ 1, %1 ], [ 1, %4 ], [ 0, %7 ]
ret i32 %13
}
int fun1153() { return 1153; }


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

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

LLVM IR (-O0):
define i32 @fun1153() {
ret i32 1153
}

LLVM IR (-O2):
define i32 @fun1153() {
ret i32 1153
}
void L_CRYPT_BB_InitKey(unsigned char *data) {
  unsigned x;
  for (x = 0; x < 48; x += 3) {
    data[x] ^= 0x19;
    data[x + 1] ^= 0x16;
    data[x + 2] ^= 0x18;
  }
}


x86 assembly (clang, -O0):
<L_CRYPT_BB_InitKey>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
cmpl   $0x30,-0xc(%rbp)
jae    1164 <L_CRYPT_BB_InitKey+0x64>
mov    -0x8(%rbp),%rax
mov    -0xc(%rbp),%ecx
movzbl (%rax,%rcx,1),%edx
xor    $0x19,%edx
mov    %dl,(%rax,%rcx,1)
mov    -0x8(%rbp),%rax
mov    -0xc(%rbp),%ecx
add    $0x1,%ecx
mov    %ecx,%ecx
movzbl (%rax,%rcx,1),%edx
xor    $0x16,%edx
mov    %dl,(%rax,%rcx,1)
mov    -0x8(%rbp),%rax
mov    -0xc(%rbp),%ecx
add    $0x2,%ecx
mov    %ecx,%ecx
movzbl (%rax,%rcx,1),%edx
xor    $0x18,%edx
mov    %dl,(%rax,%rcx,1)
mov    -0xc(%rbp),%eax
add    $0x3,%eax
mov    %eax,-0xc(%rbp)
jmp    110f <L_CRYPT_BB_InitKey+0xf>
pop    %rbp
ret

x86 assembly (clang, -O2):
<L_CRYPT_BB_InitKey>:
mov    $0xfffffffffffffffd,%rax
nopw   0x0(%rax,%rax,1)
xorb   $0x19,0x3(%rdi,%rax,1)
xorb   $0x16,0x4(%rdi,%rax,1)
xorb   $0x18,0x5(%rdi,%rax,1)
add    $0x3,%rax
cmp    $0x2d,%rax
jb     1110 <L_CRYPT_BB_InitKey+0x10>
ret

LLVM IR (-O0):
define void @L_CRYPT_BB_InitKey(i8* %0) {
%2 = alloca i8*
%3 = alloca i32
store i8* %0, i8** %2
store i32 0, i32* %3
br label %4
4: ; preds = %34, %1
%5 = load i32, i32* %3
%6 = icmp ult i32 %5, 48
br i1 %6, label %7, label %37
7: ; preds = %4
%8 = load i8*, i8** %2
%9 = load i32, i32* %3
%10 = zext i32 %9 to i64
%11 = getelementptr inbounds i8, i8* %8, i64 %10
%12 = load i8, i8* %11
%13 = zext i8 %12 to i32
%14 = xor i32 %13, 25
%15 = trunc i32 %14 to i8
store i8 %15, i8* %11
%16 = load i8*, i8** %2
%17 = load i32, i32* %3
%18 = add i32 %17, 1
%19 = zext i32 %18 to i64
%20 = getelementptr inbounds i8, i8* %16, i64 %19
%21 = load i8, i8* %20
%22 = zext i8 %21 to i32
%23 = xor i32 %22, 22
%24 = trunc i32 %23 to i8
store i8 %24, i8* %20
%25 = load i8*, i8** %2
%26 = load i32, i32* %3
%27 = add i32 %26, 2
%28 = zext i32 %27 to i64
%29 = getelementptr inbounds i8, i8* %25, i64 %28
%30 = load i8, i8* %29
%31 = zext i8 %30 to i32
%32 = xor i32 %31, 24
%33 = trunc i32 %32 to i8
store i8 %33, i8* %29
br label %34
34: ; preds = %7
%35 = load i32, i32* %3
%36 = add i32 %35, 3
store i32 %36, i32* %3
br label %4
37: ; preds = %4
ret void
}

LLVM IR (-O2):
define void @L_CRYPT_BB_InitKey(i8* nocapture %0) {
br label %2
2: ; preds = %1, %2
%3 = phi i64 [ 0, %1 ], [ %15, %2 ]
%4 = getelementptr inbounds i8, i8* %0, i64 %3
%5 = load i8, i8* %4
%6 = xor i8 %5, 25
store i8 %6, i8* %4
%7 = add nuw nsw i64 %3, 1
%8 = getelementptr inbounds i8, i8* %0, i64 %7
%9 = load i8, i8* %8
%10 = xor i8 %9, 22
store i8 %10, i8* %8
%11 = add nuw nsw i64 %3, 2
%12 = getelementptr inbounds i8, i8* %0, i64 %11
%13 = load i8, i8* %12
%14 = xor i8 %13, 24
store i8 %14, i8* %12
%15 = add nuw nsw i64 %3, 3
%16 = icmp ult i64 %3, 45
br i1 %16, label %2, label %17
17: ; preds = %2
ret void
}
/* Variables and functions */
int /*<<< orphan*/ free(int *);
int *malloc(int);
void f(int *ip) {
  int i = *ip;
  free(ip);
  ip = malloc(sizeof(int));
  *ip = i + 1;
}


x86 assembly (clang, -O0):
<f>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%eax
mov    %eax,-0xc(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <free@plt>
mov    $0x4,%edi
call   1040 <malloc@plt>
mov    %rax,-0x8(%rbp)
mov    -0xc(%rbp),%ecx
add    $0x1,%ecx
mov    -0x8(%rbp),%rax
mov    %ecx,(%rax)
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<f>:
push   %rax
call   1030 <free@plt>
mov    $0x4,%edi
pop    %rax
jmp    1040 <malloc@plt>

LLVM IR (-O0):
define void @f(i32* %0) {
%2 = alloca i32*
%3 = alloca i32
store i32* %0, i32** %2
%4 = load i32*, i32** %2
%5 = load i32, i32* %4
store i32 %5, i32* %3
%6 = load i32*, i32** %2
%7 = call i32 @free(i32* %6)
%8 = call i32* @malloc(i32 4)
store i32* %8, i32** %2
%9 = load i32, i32* %3
%10 = add nsw i32 %9, 1
%11 = load i32*, i32** %2
store i32 %10, i32* %11
ret void
}

LLVM IR (-O2):
define void @f(i32* nocapture %0) {
%2 = tail call i32 @free(i32* %0)
%3 = tail call i32* @malloc(i32 4)
ret void
}
int test_imm_F4uint8_mem(unsigned char *val) {
  return ((*val) & (-0xF4 << 0)) ? -20 : -40;
}


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

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

LLVM IR (-O0):
define i32 @test_imm_F4uint8_mem(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = load i8, i8* %3
%5 = zext i8 %4 to i32
%6 = and i32 %5, -244
%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_F4uint8_mem(i8* nocapture %0) {
%2 = load i8, i8* %0
%3 = and i8 %2, 12
%4 = icmp eq i8 %3, 0
%5 = select i1 %4, i32 -40, i32 -20
ret i32 %5
}
long ss() { return 0xffffffffL; }


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

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

LLVM IR (-O0):
define i64 @ss() {
ret i64 4294967295
}

LLVM IR (-O2):
define i64 @ss() {
ret i64 4294967295
}
void losequote(str) char *str;
{
  char tmp[128];
  if (*str == '"') {
    strcpy(tmp, str + 1);
    strcpy(str, tmp);
  }
}


x86 assembly (clang, -O0):
<losequote>:
push   %rbp
mov    %rsp,%rbp
sub    $0x90,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x22,%eax
jne    1153 <losequote+0x43>
lea    -0x90(%rbp),%rdi
mov    -0x8(%rbp),%rsi
add    $0x1,%rsi
call   1030 <strcpy@plt>
mov    -0x8(%rbp),%rdi
lea    -0x90(%rbp),%rsi
call   1030 <strcpy@plt>
add    $0x90,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<losequote>:
push   %r14
push   %rbx
sub    $0x88,%rsp
cmpb   $0x22,(%rdi)
jne    113c <losequote+0x2c>
mov    %rdi,%rbx
lea    0x1(%rdi),%rsi
mov    %rsp,%r14
mov    %r14,%rdi
call   1030 <strcpy@plt>
mov    %rbx,%rdi
mov    %r14,%rsi
call   1030 <strcpy@plt>
add    $0x88,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
define void @losequote(i8* %0) {
%2 = alloca i8*
%3 = alloca [128 x i8]
store i8* %0, i8** %2
%4 = load i8*, i8** %2
%5 = load i8, i8* %4
%6 = sext i8 %5 to i32
%7 = icmp eq i32 %6, 34
br i1 %7, label %8, label %16
8: ; preds = %1
%9 = getelementptr inbounds [128 x i8], [128 x i8]* %3, i64 0, i64 0
%10 = load i8*, i8** %2
%11 = getelementptr inbounds i8, i8* %10, i64 1
%12 = call i8* @strcpy(i8* %9, i8* %11)
%13 = load i8*, i8** %2
%14 = getelementptr inbounds [128 x i8], [128 x i8]* %3, i64 0, i64 0
%15 = call i8* @strcpy(i8* %13, i8* %14)
br label %16
16: ; preds = %8, %1
ret void
}

LLVM IR (-O2):
define void @losequote(i8* %0) {
%2 = alloca [128 x i8]
%3 = getelementptr inbounds [128 x i8], [128 x i8]* %2, i64 0, i64 0
%4 = load i8, i8* %0
%5 = icmp eq i8 %4, 34
br i1 %5, label %6, label %10
6: ; preds = %1
%7 = getelementptr inbounds i8, i8* %0, i64 1
%8 = call i8* @strcpy(i8* %3, i8* %7)
%9 = call i8* @strcpy(i8* %0, i8* %3)
br label %10
10: ; preds = %6, %1
ret void
}
/* Type definitions */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
int /*<<< orphan*/ fprintf(int /*<<< orphan*/ *, char *, int, int);
void drawEdgeFrom(int v0, int v1, FILE *f) {
  fprintf(f, "    \\path (v%d) edge (v%d);\n", v0, v1);
}


x86 assembly (clang, -O0):
<drawEdgeFrom>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %rdx,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
mov    -0x4(%rbp),%edx
mov    -0x8(%rbp),%ecx
lea    0xecd(%rip),%rsi
call   1030 <fprintf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<drawEdgeFrom>:
mov    %esi,%ecx
mov    %edi,%eax
lea    0xee5(%rip),%rsi
mov    %rdx,%rdi
mov    %eax,%edx
jmp    1030 <fprintf@plt>

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

LLVM IR (-O2):
@.str = [29 x i8] c" \\path (v%d) edge (v%d);\0A\00"
define void @drawEdgeFrom(i32 %0, i32 %1, i32* nocapture %2) {
%4 = tail call i32 @fprintf(i32* %2, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str, i64 0, i64 0), i32 %0, i32 %1)
ret void
}
/* Variables and functions */
long double __qatan2d(long double, long double);
long double __q_atn2d(long double *arg1, long double *arg2) {
  return (__qatan2d(*arg1, *arg2));
}


x86 assembly (clang, -O0):
<__q_atn2d>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
fldt   (%rax)
mov    -0x10(%rbp),%rax
fldt   (%rax)
mov    %rsp,%rax
fstpt  0x10(%rax)
fstpt  (%rax)
call   1030 <__qatan2d@plt>
fld    %st(0)
fstp   %st(0)
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<__q_atn2d>:
sub    $0x28,%rsp
fldt   (%rdi)
fldt   (%rsi)
fstpt  0x10(%rsp)
fstpt  (%rsp)
call   1030 <__qatan2d@plt>
add    $0x28,%rsp
ret

LLVM IR (-O0):
define x86_fp80 @__q_atn2d(x86_fp80* %0, x86_fp80* %1) {
%3 = alloca x86_fp80*
%4 = alloca x86_fp80*
store x86_fp80* %0, x86_fp80** %3
store x86_fp80* %1, x86_fp80** %4
%5 = load x86_fp80*, x86_fp80** %3
%6 = load x86_fp80, x86_fp80* %5
%7 = load x86_fp80*, x86_fp80** %4
%8 = load x86_fp80, x86_fp80* %7
%9 = call x86_fp80 @__qatan2d(x86_fp80 %6, x86_fp80 %8)
ret x86_fp80 %9
}

LLVM IR (-O2):
define x86_fp80 @__q_atn2d(x86_fp80* nocapture %0, x86_fp80* nocapture %1) {
%3 = load x86_fp80, x86_fp80* %0
%4 = load x86_fp80, x86_fp80* %1
%5 = tail call x86_fp80 @__qatan2d(x86_fp80 %3, x86_fp80 %4)
ret x86_fp80 %5
}
/* Type definitions */
typedef int /*<<< orphan*/ uint32_t;

/* Variables and functions */
float pun_int_to_float(int x) {
  union {
    uint32_t i;
    float f;
  } mx = {(uint32_t)x};
  return mx.f;
}


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

x86 assembly (clang, -O2):
<pun_int_to_float>:
movd   %edi,%xmm0
ret

LLVM IR (-O0):
%union.anon = type { i32 }
define float @pun_int_to_float(i32 %0) {
%2 = alloca i32
%3 = alloca %union.anon
store i32 %0, i32* %2
%4 = bitcast %union.anon* %3 to i32*
%5 = load i32, i32* %2
store i32 %5, i32* %4
%6 = bitcast %union.anon* %3 to float*
%7 = load float, float* %6
ret float %7
}

LLVM IR (-O2):
define float @pun_int_to_float(i32 %0) {
%2 = bitcast i32 %0 to float
ret float %2
}
/* Variables and functions */
int /*<<< orphan*/ puts(char *);
void foo(void) { puts("Hello I am a shared library"); }


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

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

LLVM IR (-O0):
@.str = [28 x i8] c"Hello I am a shared library\00"
define void @foo() {
%1 = call i32 @puts(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [28 x i8] c"Hello I am a shared library\00"
define void @foo() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([28 x i8], [28 x i8]* @.str, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ term_add_bytes(char *, int);
void ecma48_clear_screen(void) {
  term_add_bytes("\033[0m"
                 "\033[H"
                 "\033[2J",
                 (sizeof(""
                         "\033[0m"
                         "\033[H"
                         "\033[2J"
                         "") -
                  1));
}


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

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

LLVM IR (-O0):
@.str = [12 x i8] c"\1B[0m\1B[H\1B[2J\00"
define void @ecma48_clear_screen() {
%1 = call i32 @term_add_bytes(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0), i32 11)
ret void
}

LLVM IR (-O2):
@.str = [12 x i8] c"\1B[0m\1B[H\1B[2J\00"
define void @ecma48_clear_screen() {
%1 = tail call i32 @term_add_bytes(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0), i32 11)
ret void
}
/* Variables and functions */
scalar_t__ EOF;
scalar_t__ getchar();
int /*<<< orphan*/ printf(char *, double);
int main() {
  double nc;
  for (nc = 0; getchar() != EOF; ++nc)
    ;
  printf("%.0f\n", nc);
  return 1;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x10(%rbp)
mov    $0x0,%al
call   1040 <getchar@plt>
mov    0x2ea3(%rip),%rcx
cmp    (%rcx),%rax
je     116a <main+0x4a>
jmp    1153 <main+0x33>
movsd  0xea5(%rip),%xmm0
addsd  -0x10(%rbp),%xmm0
movsd  %xmm0,-0x10(%rbp)
jmp    1137 <main+0x17>
movsd  -0x10(%rbp),%xmm0
lea    0xe92(%rip),%rdi
call   1030 <printf@plt>
mov    $0x1,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x10,%rsp
xor    %eax,%eax
call   1040 <getchar@plt>
mov    0x2eb5(%rip),%rbx
xorpd  %xmm0,%xmm0
cmp    (%rbx),%rax
je     1160 <main+0x40>
xorpd  %xmm0,%xmm0
addsd  0xeb8(%rip),%xmm0
movsd  %xmm0,0x8(%rsp)
xor    %eax,%eax
call   1040 <getchar@plt>
movsd  0x8(%rsp),%xmm0
cmp    (%rbx),%rax
jne    1140 <main+0x20>
lea    0xea1(%rip),%rdi
call   1030 <printf@plt>
mov    $0x1,%eax
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@EOF = global i64 0
@.str = [6 x i8] c"%.0f\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca double
store i32 0, i32* %1
store double 0.000000e+00, double* %2
br label %3
3: ; preds = %8, %0
%4 = call i64 (...) @getchar()
%5 = load i64, i64* @EOF
%6 = icmp ne i64 %4, %5
br i1 %6, label %7, label %11
7: ; preds = %3
br label %8
8: ; preds = %7
%9 = load double, double* %2
%10 = fadd double %9, 1.000000e+00
store double %10, double* %2
br label %3
11: ; preds = %3
%12 = load double, double* %2
%13 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), double %12)
ret i32 1
}

LLVM IR (-O2):
@EOF = global i64 0
@.str = [6 x i8] c"%.0f\0A\00"
define i32 @main() {
%1 = tail call i64 (...) @getchar()
%2 = load i64, i64* @EOF
%3 = icmp eq i64 %1, %2
br i1 %3, label %10, label %4
4: ; preds = %0, %4
%5 = phi double [ %6, %4 ], [ 0.000000e+00, %0 ]
%6 = fadd double %5, 1.000000e+00
%7 = tail call i64 (...) @getchar()
%8 = load i64, i64* @EOF
%9 = icmp eq i64 %7, %8
br i1 %9, label %10, label %4
10: ; preds = %4, %0
%11 = phi double [ 0.000000e+00, %0 ], [ %6, %4 ]
%12 = tail call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), double %11)
ret i32 1
}
int isString(char *buf) {
  if (*buf != '"') {
    return 0;
  }
  buf++;
  while (*buf != '\0') {
    buf++;
  }
  buf--;
  if (*buf != '"') {
    return 0;
  }
  return 1;
}


x86 assembly (clang, -O0):
<isString>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x22,%eax
je     1124 <isString+0x24>
movl   $0x0,-0x4(%rbp)
jmp    1180 <isString+0x80>
mov    -0x10(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x0,%eax
je     1151 <isString+0x51>
mov    -0x10(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x10(%rbp)
jmp    1130 <isString+0x30>
mov    -0x10(%rbp),%rax
add    $0xffffffffffffffff,%rax
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x22,%eax
je     1179 <isString+0x79>
movl   $0x0,-0x4(%rbp)
jmp    1180 <isString+0x80>
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<isString>:
xor    %eax,%eax
cmpb   $0x22,(%rdi)
jne    1122 <isString+0x22>
add    $0x1,%rdi
nopl   0x0(%rax,%rax,1)
cmpb   $0x0,(%rdi)
lea    0x1(%rdi),%rdi
jne    1110 <isString+0x10>
xor    %eax,%eax
cmpb   $0x22,-0x2(%rdi)
sete   %al
ret

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

LLVM IR (-O2):
define i32 @isString(i8* nocapture %0) {
%2 = load i8, i8* %0
%3 = icmp eq i8 %2, 34
br i1 %3, label %4, label %13
4: ; preds = %1, %4
%5 = phi i8* [ %6, %4 ], [ %0, %1 ]
%6 = getelementptr inbounds i8, i8* %5, i64 1
%7 = load i8, i8* %6
%8 = icmp eq i8 %7, 0
br i1 %8, label %9, label %4
9: ; preds = %4
%10 = load i8, i8* %5
%11 = icmp eq i8 %10, 34
%12 = zext i1 %11 to i32
br label %13
13: ; preds = %9, %1
%14 = phi i32 [ 0, %1 ], [ %12, %9 ]
ret i32 %14
}
/* Variables and functions */
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ printf(char *, int, int);
void exitfunc0(int status, void *arg) {
  printf("Executing exitfunc0 (status=%d, arg=%d)\n", status, (int)arg);
  exit((int)arg);
}


x86 assembly (clang, -O0):
<exitfunc0>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x4(%rbp),%esi
mov    -0x10(%rbp),%rax
mov    %eax,%edx
lea    0xec1(%rip),%rdi
call   1030 <printf@plt>
mov    -0x10(%rbp),%rax
mov    %eax,%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<exitfunc0>:
push   %rbx
mov    %rsi,%rbx
mov    %edi,%esi
lea    0xed3(%rip),%rdi
mov    %ebx,%edx
call   1030 <printf@plt>
mov    %ebx,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@.str = [41 x i8] c"Executing exitfunc0 (status=%d, arg=%d)\0A\00"
define void @exitfunc0(i32 %0, i8* %1) {
%3 = alloca i32
%4 = alloca i8*
store i32 %0, i32* %3
store i8* %1, i8** %4
%5 = load i32, i32* %3
%6 = load i8*, i8** %4
%7 = ptrtoint i8* %6 to i32
%8 = call i32 @printf(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str, i64 0, i64 0), i32 %5, i32 %7)
%9 = load i8*, i8** %4
%10 = ptrtoint i8* %9 to i32
%11 = call i32 @exit(i32 %10)
unreachable
}

LLVM IR (-O2):
@.str = [41 x i8] c"Executing exitfunc0 (status=%d, arg=%d)\0A\00"
define void @exitfunc0(i32 %0, i8* %1) {
%3 = ptrtoint i8* %1 to i64
%4 = trunc i64 %3 to i32
%5 = tail call i32 @printf(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str, i64 0, i64 0), i32 %0, i32 %4)
%6 = tail call i32 @exit(i32 %4)
unreachable
}
/* Type definitions */
struct vec3i {
  int dummy;
};
typedef int /*<<< orphan*/ int32_t;

/* Variables and functions */
int /*<<< orphan*/ vec3i_abs(int /*<<< orphan*/ *, int /*<<< orphan*/ *);
__attribute__((always_)) struct vec3i *psvec3i_abs(struct vec3i *result,
                                                   struct vec3i *a) {
  vec3i_abs((int32_t *)result, (int32_t *)a);
  return result;
}


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

x86 assembly (clang, -O2):
<psvec3i_abs>:
push   %rbx
mov    %rdi,%rbx
call   1030 <vec3i_abs@plt>
mov    %rbx,%rax
pop    %rbx
ret

LLVM IR (-O0):
%struct.vec3i = type { i32 }
define %struct.vec3i* @psvec3i_abs(%struct.vec3i* %0, %struct.vec3i* %1) {
%3 = alloca %struct.vec3i*
%4 = alloca %struct.vec3i*
store %struct.vec3i* %0, %struct.vec3i** %3
store %struct.vec3i* %1, %struct.vec3i** %4
%5 = load %struct.vec3i*, %struct.vec3i** %3
%6 = bitcast %struct.vec3i* %5 to i32*
%7 = load %struct.vec3i*, %struct.vec3i** %4
%8 = bitcast %struct.vec3i* %7 to i32*
%9 = call i32 @vec3i_abs(i32* %6, i32* %8)
%10 = load %struct.vec3i*, %struct.vec3i** %3
ret %struct.vec3i* %10
}

LLVM IR (-O2):
%struct.vec3i = type { i32 }
define %struct.vec3i* @psvec3i_abs(%struct.vec3i* returned %0, %struct.vec3i* %1) {
%3 = getelementptr %struct.vec3i, %struct.vec3i* %0, i64 0, i32 0
%4 = getelementptr %struct.vec3i, %struct.vec3i* %1, i64 0, i32 0
%5 = tail call i32 @vec3i_abs(i32* %3, i32* %4)
ret %struct.vec3i* %0
}
/* Variables and functions */
int /*<<< orphan*/ OK;
int check_arg_count(int, int /*<<< orphan*/);
int /*<<< orphan*/ noqiflush();
int /*<<< orphan*/ report_count(int);
int /*<<< orphan*/ report_return(int /*<<< orphan*/);
void cmd_noqiflush(int nargs, char **args) {
  if (check_arg_count(nargs, 0) == 1)
    return;
  noqiflush();
  report_count(1);
  report_return(OK);
}


x86 assembly (clang, -O0):
<cmd_noqiflush>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x4(%rbp),%edi
xor    %esi,%esi
call   1050 <check_arg_count@plt>
cmp    $0x1,%eax
jne    1167 <cmd_noqiflush+0x27>
jmp    1186 <cmd_noqiflush+0x46>
mov    $0x0,%al
call   1040 <noqiflush@plt>
mov    $0x1,%edi
call   1060 <report_count@plt>
mov    0x2e61(%rip),%rax
mov    (%rax),%edi
call   1030 <report_return@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<cmd_noqiflush>:
push   %rax
xor    %esi,%esi
call   1050 <check_arg_count@plt>
cmp    $0x1,%eax
jne    114f <cmd_noqiflush+0xf>
pop    %rax
ret
xor    %eax,%eax
call   1040 <noqiflush@plt>
mov    $0x1,%edi
call   1060 <report_count@plt>
mov    0x2e79(%rip),%rax
mov    (%rax),%edi
pop    %rax
jmp    1030 <report_return@plt>

LLVM IR (-O0):
@OK = global i32 0
define void @cmd_noqiflush(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i8**
store i32 %0, i32* %3
store i8** %1, i8*** %4
%5 = load i32, i32* %3
%6 = call i32 @check_arg_count(i32 %5, i32 0)
%7 = icmp eq i32 %6, 1
br i1 %7, label %8, label %9
8: ; preds = %2
br label %14
9: ; preds = %2
%10 = call i32 (...) @noqiflush()
%11 = call i32 @report_count(i32 1)
%12 = load i32, i32* @OK
%13 = call i32 @report_return(i32 %12)
br label %14
14: ; preds = %9, %8
ret void
}

LLVM IR (-O2):
@OK = global i32 0
define void @cmd_noqiflush(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @check_arg_count(i32 %0, i32 0)
%4 = icmp eq i32 %3, 1
br i1 %4, label %10, label %5
5: ; preds = %2
%6 = tail call i32 (...) @noqiflush()
%7 = tail call i32 @report_count(i32 1)
%8 = load i32, i32* @OK
%9 = tail call i32 @report_return(i32 %8)
br label %10
10: ; preds = %2, %5
ret void
}
cbuf17(f, n) int f, n;
{ cbuf(f, n, 17); }


x86 assembly (clang, -O0):
<cbuf17>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0x8(%rbp),%edi
mov    -0xc(%rbp),%esi
mov    $0x11,%edx
mov    $0x0,%al
call   1030 <cbuf@plt>
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<cbuf17>:
mov    $0x11,%edx
xor    %eax,%eax
jmp    1030 <cbuf@plt>

LLVM IR (-O0):
define i32 @cbuf17(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 = call i32 (i32, i32, i32, ...) bitcast (i32 (...)* @cbuf to i32 (i32, i32, i32, ...)*)(i32 %6, i32 %7, i32 17)
%9 = load i32, i32* %3
ret i32 %9
}

LLVM IR (-O2):
define i32 @cbuf17(i32 %0, i32 %1) {
%3 = tail call i32 (i32, i32, i32, ...) bitcast (i32 (...)* @cbuf to i32 (i32, i32, i32, ...)*)(i32 %0, i32 %1, i32 17)
ret i32 undef
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ isdigit(int);
void t_isdigit_0x92() {
  Assert_real((isdigit(146) == 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_isdigit.c",
              735, ("isdigit should be 0 for 0x92"));
}


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

x86 assembly (clang, -O2):
<t_isdigit_0x92>:
push   %rax
mov    $0x92,%edi
call   1030 <isdigit@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
lea    0xec5(%rip),%rsi
lea    0xf66(%rip),%rcx
mov    $0x2df,%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_isdigit.c\00"
@.str.1 = [29 x i8] c"isdigit should be 0 for 0x92\00"
define void @t_isdigit_0x92() {
%1 = call i64 @isdigit(i32 146)
%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 735, i8* getelementptr inbounds ([29 x i8], [29 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_isdigit.c\00"
@.str.1 = [29 x i8] c"isdigit should be 0 for 0x92\00"
define void @t_isdigit_0x92() {
%1 = tail call i64 @isdigit(i32 146)
%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 735, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0))
ret void
}
void MV_StopRecord(void) {}


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

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

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

LLVM IR (-O2):
define void @MV_StopRecord() {
ret void
}
void CFGMR3GetRootU(void) {}


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

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

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

LLVM IR (-O2):
define void @CFGMR3GetRootU() {
ret void
}
int get_processor_number_total(void) { return -1; }


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

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

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

LLVM IR (-O2):
define i32 @get_processor_number_total() {
ret i32 -1
}
int divisionByValue(int dividend, int divisor) { return (dividend / divisor); }


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

x86 assembly (clang, -O2):
<divisionByValue>:
mov    %edi,%eax
cltd
idiv   %esi
ret

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

LLVM IR (-O2):
define i32 @divisionByValue(i32 %0, i32 %1) {
%3 = sdiv i32 %0, %1
ret i32 %3
}
/* Variables and functions */
int /*<<< orphan*/ nrf_ceh();
void nrf_listen() { nrf_ceh(); }


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

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

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

LLVM IR (-O2):
define void @nrf_listen() {
%1 = tail call i32 (...) @nrf_ceh()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ printf(char *);
void print_usage(char *appname) {
  printf("Usage: app testcode");
  exit(1);
}


x86 assembly (clang, -O0):
<print_usage>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
lea    0xecd(%rip),%rdi
call   1030 <printf@plt>
mov    $0x1,%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<print_usage>:
push   %rax
lea    0xed8(%rip),%rdi
call   1030 <printf@plt>
mov    $0x1,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@.str = [20 x i8] c"Usage: app testcode\00"
define void @print_usage(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = call i32 @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str, i64 0, i64 0))
%4 = call i32 @exit(i32 1)
unreachable
}

LLVM IR (-O2):
@.str = [20 x i8] c"Usage: app testcode\00"
define void @print_usage(i8* nocapture readnone %0) {
%2 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str, i64 0, i64 0))
%3 = tail call i32 @exit(i32 1)
unreachable
}
/* Type definitions */
typedef int /*<<< orphan*/ uint32_t;
struct helium_channel {
  int dummy;
};

/* Variables and functions */
int _helium_channel_poll_data(struct helium_channel *, int, void *, size_t,
                              size_t *, int /*<<< orphan*/);
int helium_channel_poll_data(struct helium_channel *channel, void *data,
                             size_t len, size_t *used, uint32_t retries) {
  return _helium_channel_poll_data(channel, 0x05, data, len, used, retries);
}


x86 assembly (clang, -O0):
<helium_channel_poll_data>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8d,-0x24(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rdx
mov    -0x18(%rbp),%rcx
mov    -0x20(%rbp),%r8
mov    -0x24(%rbp),%r9d
mov    $0x5,%esi
call   1030 <_helium_channel_poll_data@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<helium_channel_poll_data>:
mov    %r8d,%r9d
mov    %rcx,%r8
mov    %rdx,%rcx
mov    %rsi,%rdx
mov    $0x5,%esi
jmp    1030 <_helium_channel_poll_data@plt>

LLVM IR (-O0):
%struct.helium_channel = type { i32 }
define i32 @helium_channel_poll_data(%struct.helium_channel* %0, i8* %1, i64 %2, i64* %3, i32 %4) {
%6 = alloca %struct.helium_channel*
%7 = alloca i8*
%8 = alloca i64
%9 = alloca i64*
%10 = alloca i32
store %struct.helium_channel* %0, %struct.helium_channel** %6
store i8* %1, i8** %7
store i64 %2, i64* %8
store i64* %3, i64** %9
store i32 %4, i32* %10
%11 = load %struct.helium_channel*, %struct.helium_channel** %6
%12 = load i8*, i8** %7
%13 = load i64, i64* %8
%14 = load i64*, i64** %9
%15 = load i32, i32* %10
%16 = call i32 @_helium_channel_poll_data(%struct.helium_channel* %11, i32 5, i8* %12, i64 %13, i64* %14, i32 %15)
ret i32 %16
}

LLVM IR (-O2):
%struct.helium_channel = type { i32 }
define i32 @helium_channel_poll_data(%struct.helium_channel* %0, i8* %1, i64 %2, i64* %3, i32 %4) {
%6 = tail call i32 @_helium_channel_poll_data(%struct.helium_channel* %0, i32 5, i8* %1, i64 %2, i64* %3, i32 %4)
ret i32 %6
}
void d2i_GENERAL_NAMES(void) {}


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

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

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

LLVM IR (-O2):
define void @d2i_GENERAL_NAMES() {
ret void
}
void GC_world_stopped(void) {}


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

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

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

LLVM IR (-O2):
define void @GC_world_stopped() {
ret void
}
int bin(int d7, int d6, int d5, int d4, int d3, int d2, int d1, int d0) {
  return d7 << 7 | d6 << 6 | d5 << 5 | d4 << 4 | d3 << 3 | d2 << 2 | d1 << 1 |
         d0;
}


x86 assembly (clang, -O0):
<bin>:
push   %rbp
mov    %rsp,%rbp
mov    0x18(%rbp),%eax
mov    0x10(%rbp),%eax
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %ecx,-0x10(%rbp)
mov    %r8d,-0x14(%rbp)
mov    %r9d,-0x18(%rbp)
mov    -0x4(%rbp),%eax
shl    $0x7,%eax
mov    -0x8(%rbp),%ecx
shl    $0x6,%ecx
or     %ecx,%eax
mov    -0xc(%rbp),%ecx
shl    $0x5,%ecx
or     %ecx,%eax
mov    -0x10(%rbp),%ecx
shl    $0x4,%ecx
or     %ecx,%eax
mov    -0x14(%rbp),%ecx
shl    $0x3,%ecx
or     %ecx,%eax
mov    -0x18(%rbp),%ecx
shl    $0x2,%ecx
or     %ecx,%eax
mov    0x10(%rbp),%ecx
shl    $0x1,%ecx
or     %ecx,%eax
or     0x18(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<bin>:
mov    0x8(%rsp),%eax
shl    $0x7,%edi
shl    $0x6,%esi
or     %edi,%esi
shl    $0x5,%edx
shl    $0x4,%ecx
or     %edx,%ecx
or     %esi,%ecx
lea    0x0(,%r8,8),%edx
lea    0x0(,%r9,4),%esi
or     %edx,%esi
or     %ecx,%esi
add    %eax,%eax
or     %esi,%eax
or     0x10(%rsp),%eax
ret

LLVM IR (-O0):
define i32 @bin(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6, i32 %7) {
%9 = alloca i32
%10 = alloca i32
%11 = alloca i32
%12 = alloca i32
%13 = alloca i32
%14 = alloca i32
%15 = alloca i32
%16 = alloca i32
store i32 %0, i32* %9
store i32 %1, i32* %10
store i32 %2, i32* %11
store i32 %3, i32* %12
store i32 %4, i32* %13
store i32 %5, i32* %14
store i32 %6, i32* %15
store i32 %7, i32* %16
%17 = load i32, i32* %9
%18 = shl i32 %17, 7
%19 = load i32, i32* %10
%20 = shl i32 %19, 6
%21 = or i32 %18, %20
%22 = load i32, i32* %11
%23 = shl i32 %22, 5
%24 = or i32 %21, %23
%25 = load i32, i32* %12
%26 = shl i32 %25, 4
%27 = or i32 %24, %26
%28 = load i32, i32* %13
%29 = shl i32 %28, 3
%30 = or i32 %27, %29
%31 = load i32, i32* %14
%32 = shl i32 %31, 2
%33 = or i32 %30, %32
%34 = load i32, i32* %15
%35 = shl i32 %34, 1
%36 = or i32 %33, %35
%37 = load i32, i32* %16
%38 = or i32 %36, %37
ret i32 %38
}

LLVM IR (-O2):
define i32 @bin(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6, i32 %7) {
%9 = shl i32 %0, 7
%10 = shl i32 %1, 6
%11 = or i32 %10, %9
%12 = shl i32 %2, 5
%13 = or i32 %11, %12
%14 = shl i32 %3, 4
%15 = or i32 %13, %14
%16 = shl i32 %4, 3
%17 = or i32 %15, %16
%18 = shl i32 %5, 2
%19 = or i32 %17, %18
%20 = shl i32 %6, 1
%21 = or i32 %19, %20
%22 = or i32 %21, %7
ret i32 %22
}
/* Variables and functions */
int /*<<< orphan*/ data_read();
int /*<<< orphan*/ init();
scalar_t__ open_accesory_com_dev();
int /*<<< orphan*/ printf(char *);
int main(int argc, char **argv) {
  init();
  if (open_accesory_com_dev()) {
    return -1;
  }
  printf("open\n");
  data_read();
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    $0x0,%al
call   1050 <init@plt>
mov    $0x0,%al
call   1030 <open_accesory_com_dev@plt>
cmp    $0x0,%rax
je     117a <main+0x3a>
movl   $0xffffffff,-0x4(%rbp)
jmp    1194 <main+0x54>
lea    0xe7f(%rip),%rdi
call   1040 <printf@plt>
mov    $0x0,%al
call   1060 <data_read@plt>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
xor    %eax,%eax
call   1050 <init@plt>
xor    %eax,%eax
call   1030 <open_accesory_com_dev@plt>
mov    %rax,%rcx
mov    $0xffffffff,%eax
test   %rcx,%rcx
je     115e <main+0x1e>
pop    %rcx
ret
lea    0xe9b(%rip),%rdi
call   1040 <puts@plt>
xor    %eax,%eax
call   1060 <data_read@plt>
xor    %eax,%eax
pop    %rcx
ret

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

LLVM IR (-O2):
@str = [5 x i8] c"open\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 (...) @init()
%4 = tail call i64 (...) @open_accesory_com_dev()
%5 = icmp eq i64 %4, 0
br i1 %5, label %6, label %9
6: ; preds = %2
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @str, i64 0, i64 0))
%8 = tail call i32 (...) @data_read()
br label %9
9: ; preds = %2, %6
%10 = phi i32 [ 0, %6 ], [ -1, %2 ]
ret i32 %10
}
void gtk_selection_data_get_text() {}


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

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

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

LLVM IR (-O2):
define void @gtk_selection_data_get_text() {
ret void
}
void typecheck_shutdown(void) { return; }


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

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

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

LLVM IR (-O2):
define void @typecheck_shutdown() {
ret void
}
unsigned long long g(unsigned long long a) { return a & 0x100000000ull; }


x86 assembly (clang, -O0):
<g>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
movabs $0x100000000,%rax
and    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<g>:
movabs $0x100000000,%rax
and    %rdi,%rax
ret

LLVM IR (-O0):
define i64 @g(i64 %0) {
%2 = alloca i64
store i64 %0, i64* %2
%3 = load i64, i64* %2
%4 = and i64 %3, 4294967296
ret i64 %4
}

LLVM IR (-O2):
define i64 @g(i64 %0) {
%2 = and i64 %0, 4294967296
ret i64 %2
}
void report_RDMA_Read_Cmpl(void) {}


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

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

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

LLVM IR (-O2):
define void @report_RDMA_Read_Cmpl() {
ret void
}
/* Variables and functions */
int find_lev_passwd(char *, unsigned int *, unsigned int *);
int /*<<< orphan*/ set_acckey(unsigned int);
int check_lev_passwd(char *passwd) {
  unsigned int keylev, codlev;
  int nlev;
  nlev = find_lev_passwd(passwd, &keylev, &codlev);
  if (nlev > 0)
    set_acckey(keylev);
  return (nlev);
}


x86 assembly (clang, -O0):
<check_lev_passwd>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
lea    -0xc(%rbp),%rsi
lea    -0x10(%rbp),%rdx
call   1040 <find_lev_passwd@plt>
mov    %eax,-0x14(%rbp)
cmpl   $0x0,-0x14(%rbp)
jle    1152 <check_lev_passwd+0x32>
mov    -0xc(%rbp),%edi
call   1030 <set_acckey@plt>
mov    -0x14(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<check_lev_passwd>:
push   %rbx
sub    $0x10,%rsp
lea    0x8(%rsp),%rsi
lea    0xc(%rsp),%rdx
call   1040 <find_lev_passwd@plt>
mov    %eax,%ebx
test   %eax,%eax
jle    1143 <check_lev_passwd+0x23>
mov    0x8(%rsp),%edi
call   1030 <set_acckey@plt>
mov    %ebx,%eax
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
define i32 @check_lev_passwd(i8* %0) {
%2 = alloca i8*
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store i8* %0, i8** %2
%6 = load i8*, i8** %2
%7 = call i32 @find_lev_passwd(i8* %6, i32* %3, i32* %4)
store i32 %7, i32* %5
%8 = load i32, i32* %5
%9 = icmp sgt i32 %8, 0
br i1 %9, label %10, label %13
10: ; preds = %1
%11 = load i32, i32* %3
%12 = call i32 @set_acckey(i32 %11)
br label %13
13: ; preds = %10, %1
%14 = load i32, i32* %5
ret i32 %14
}

LLVM IR (-O2):
define i32 @check_lev_passwd(i8* %0) {
%2 = alloca i32
%3 = alloca i32
%4 = bitcast i32* %2 to i8*
%5 = bitcast i32* %3 to i8*
%6 = call i32 @find_lev_passwd(i8* %0, i32* %2, i32* %3)
%7 = icmp sgt i32 %6, 0
br i1 %7, label %8, label %11
8: ; preds = %1
%9 = load i32, i32* %2
%10 = call i32 @set_acckey(i32 %9)
br label %11
11: ; preds = %8, %1
ret i32 %6
}