#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */
struct stat {
  int st_mode;
  scalar_t__ st_dev;
  scalar_t__ st_ino;
};

/* Variables and functions */
int S_IFLNK;
int /*<<< orphan*/ free(struct stat *);
int /*<<< orphan*/ lstat(char *, struct stat *);
scalar_t__ malloc(int);
int /*<<< orphan*/ stat(char *, struct stat *);
scalar_t__ strcmp(char *, char *);
int is_same_file(char *file1, char *file2) {
  struct stat *buf1;
  struct stat *buf2;
  buf1 = (struct stat *)malloc(sizeof(struct stat));
  buf2 = (struct stat *)malloc(sizeof(struct stat));
  stat(file1, buf1);
  stat(file2, buf2);
  if (strcmp(file1, file2) == 0) {
    free(buf1);
    free(buf2);
    return -1;
  } else {
    lstat(file1, buf1);
    lstat(file2, buf2);
    if (!(buf1->st_mode & S_IFLNK) && !(buf2->st_mode & S_IFLNK)) {
      if ((buf1->st_dev == buf2->st_dev) && (buf1->st_ino == buf2->st_ino)) {
        free(buf1);
        free(buf2);
        return -1;
      } else {
        free(buf1);
        free(buf2);
        return 0;
      }
    } else if ((buf1->st_mode & S_IFLNK) && (buf2->st_mode & S_IFLNK)) {
      stat(file1, buf1);
      stat(file2, buf2);
      if ((buf1->st_dev == buf2->st_dev) && (buf1->st_ino == buf2->st_ino)) {
        free(buf1);
        free(buf2);
        return -1;
      } else {
        free(buf1);
        free(buf2);
        return 0;
      }
    } else if ((buf1->st_mode & S_IFLNK) && !(buf2->st_mode & S_IFLNK)) {
      stat(file1, buf1);
      stat(file2, buf2);
      if ((buf1->st_dev == buf2->st_dev) && (buf1->st_ino == buf2->st_ino)) {
        free(buf1);
        free(buf2);
        return -1;
      } else {
        free(buf1);
        free(buf2);
        return 0;
      }
    } else {
      stat(file1, buf1);
      stat(file2, buf2);
      if ((buf1->st_dev == buf2->st_dev) && (buf1->st_ino == buf2->st_ino)) {
        free(buf1);
        free(buf2);
        return -1;
      } else {
        free(buf1);
        free(buf2);
        return 0;
      }
    }
  }
}


x86 assembly (clang, -O0):
<is_same_file>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    $0x18,%edi
call   1070 <malloc@plt>
mov    %rax,-0x20(%rbp)
mov    $0x18,%edi
call   1070 <malloc@plt>
mov    %rax,-0x28(%rbp)
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1060 <stat@plt>
mov    -0x18(%rbp),%rdi
mov    -0x28(%rbp),%rsi
call   1060 <stat@plt>
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
call   1050 <strcmp@plt>
cmp    $0x0,%rax
jne    11cb <is_same_file+0x7b>
mov    -0x20(%rbp),%rdi
call   1030 <free@plt>
mov    -0x28(%rbp),%rdi
call   1030 <free@plt>
movl   $0xffffffff,-0x4(%rbp)
jmp    145e <is_same_file+0x30e>
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1040 <lstat@plt>
mov    -0x18(%rbp),%rdi
mov    -0x28(%rbp),%rsi
call   1040 <lstat@plt>
mov    -0x20(%rbp),%rax
mov    (%rax),%eax
mov    0x2df6(%rip),%rcx
and    (%rcx),%eax
cmp    $0x0,%eax
jne    127d <is_same_file+0x12d>
mov    -0x28(%rbp),%rax
mov    (%rax),%eax
mov    0x2dde(%rip),%rcx
and    (%rcx),%eax
cmp    $0x0,%eax
jne    127d <is_same_file+0x12d>
mov    -0x20(%rbp),%rax
mov    0x8(%rax),%rax
mov    -0x28(%rbp),%rcx
cmp    0x8(%rcx),%rax
jne    125f <is_same_file+0x10f>
mov    -0x20(%rbp),%rax
mov    0x10(%rax),%rax
mov    -0x28(%rbp),%rcx
cmp    0x10(%rcx),%rax
jne    125f <is_same_file+0x10f>
mov    -0x20(%rbp),%rdi
call   1030 <free@plt>
mov    -0x28(%rbp),%rdi
call   1030 <free@plt>
movl   $0xffffffff,-0x4(%rbp)
jmp    145e <is_same_file+0x30e>
mov    -0x20(%rbp),%rdi
call   1030 <free@plt>
mov    -0x28(%rbp),%rdi
call   1030 <free@plt>
movl   $0x0,-0x4(%rbp)
jmp    145e <is_same_file+0x30e>
mov    -0x20(%rbp),%rax
mov    (%rax),%eax
mov    0x2d5e(%rip),%rcx
and    (%rcx),%eax
cmp    $0x0,%eax
je     132f <is_same_file+0x1df>
mov    -0x28(%rbp),%rax
mov    (%rax),%eax
mov    0x2d46(%rip),%rcx
and    (%rcx),%eax
cmp    $0x0,%eax
je     132f <is_same_file+0x1df>
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1060 <stat@plt>
mov    -0x18(%rbp),%rdi
mov    -0x28(%rbp),%rsi
call   1060 <stat@plt>
mov    -0x20(%rbp),%rax
mov    0x8(%rax),%rax
mov    -0x28(%rbp),%rcx
cmp    0x8(%rcx),%rax
jne    1311 <is_same_file+0x1c1>
mov    -0x20(%rbp),%rax
mov    0x10(%rax),%rax
mov    -0x28(%rbp),%rcx
cmp    0x10(%rcx),%rax
jne    1311 <is_same_file+0x1c1>
mov    -0x20(%rbp),%rdi
call   1030 <free@plt>
mov    -0x28(%rbp),%rdi
call   1030 <free@plt>
movl   $0xffffffff,-0x4(%rbp)
jmp    145e <is_same_file+0x30e>
mov    -0x20(%rbp),%rdi
call   1030 <free@plt>
mov    -0x28(%rbp),%rdi
call   1030 <free@plt>
movl   $0x0,-0x4(%rbp)
jmp    145e <is_same_file+0x30e>
mov    -0x20(%rbp),%rax
mov    (%rax),%eax
mov    0x2cac(%rip),%rcx
and    (%rcx),%eax
cmp    $0x0,%eax
je     13e1 <is_same_file+0x291>
mov    -0x28(%rbp),%rax
mov    (%rax),%eax
mov    0x2c94(%rip),%rcx
and    (%rcx),%eax
cmp    $0x0,%eax
jne    13e1 <is_same_file+0x291>
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1060 <stat@plt>
mov    -0x18(%rbp),%rdi
mov    -0x28(%rbp),%rsi
call   1060 <stat@plt>
mov    -0x20(%rbp),%rax
mov    0x8(%rax),%rax
mov    -0x28(%rbp),%rcx
cmp    0x8(%rcx),%rax
jne    13c3 <is_same_file+0x273>
mov    -0x20(%rbp),%rax
mov    0x10(%rax),%rax
mov    -0x28(%rbp),%rcx
cmp    0x10(%rcx),%rax
jne    13c3 <is_same_file+0x273>
mov    -0x20(%rbp),%rdi
call   1030 <free@plt>
mov    -0x28(%rbp),%rdi
call   1030 <free@plt>
movl   $0xffffffff,-0x4(%rbp)
jmp    145e <is_same_file+0x30e>
mov    -0x20(%rbp),%rdi
call   1030 <free@plt>
mov    -0x28(%rbp),%rdi
call   1030 <free@plt>
movl   $0x0,-0x4(%rbp)
jmp    145e <is_same_file+0x30e>
mov    -0x10(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1060 <stat@plt>
mov    -0x18(%rbp),%rdi
mov    -0x28(%rbp),%rsi
call   1060 <stat@plt>
mov    -0x20(%rbp),%rax
mov    0x8(%rax),%rax
mov    -0x28(%rbp),%rcx
cmp    0x8(%rcx),%rax
jne    1445 <is_same_file+0x2f5>
mov    -0x20(%rbp),%rax
mov    0x10(%rax),%rax
mov    -0x28(%rbp),%rcx
cmp    0x10(%rcx),%rax
jne    1445 <is_same_file+0x2f5>
mov    -0x20(%rbp),%rdi
call   1030 <free@plt>
mov    -0x28(%rbp),%rdi
call   1030 <free@plt>
movl   $0xffffffff,-0x4(%rbp)
jmp    145e <is_same_file+0x30e>
mov    -0x20(%rbp),%rdi
call   1030 <free@plt>
mov    -0x28(%rbp),%rdi
call   1030 <free@plt>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_same_file>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
mov    %rsi,%r12
mov    %rdi,%rbx
mov    $0x18,%edi
call   1070 <malloc@plt>
mov    %rax,%r15
mov    $0x18,%edi
call   1070 <malloc@plt>
mov    %rax,%r14
mov    %rbx,%rdi
mov    %r15,%rsi
call   1060 <stat@plt>
mov    %r12,%rdi
mov    %r14,%rsi
call   1060 <stat@plt>
mov    %rbx,%rdi
mov    %r12,%rsi
call   1050 <strcmp@plt>
test   %rax,%rax
je     121f <is_same_file+0xcf>
mov    %rbx,%rdi
mov    %r15,%rsi
call   1040 <lstat@plt>
mov    %r12,%rdi
mov    %r14,%rsi
call   1040 <lstat@plt>
mov    0x2e2a(%rip),%rax
mov    (%rax),%ebp
mov    (%r14),%r13d
test   %ebp,(%r15)
je     11f0 <is_same_file+0xa0>
mov    %rbx,%rdi
mov    %r15,%rsi
call   1060 <stat@plt>
mov    %r12,%rdi
mov    %r14,%rsi
call   1060 <stat@plt>
mov    0x8(%r15),%rax
mov    0x8(%r14),%rcx
test   %ebp,%r13d
cmp    %rcx,%rax
je     1215 <is_same_file+0xc5>
jmp    1236 <is_same_file+0xe6>
test   %ebp,%r13d
je     120b <is_same_file+0xbb>
mov    %rbx,%rdi
mov    %r15,%rsi
call   1060 <stat@plt>
mov    %r12,%rdi
mov    %r14,%rsi
call   1060 <stat@plt>
mov    0x8(%r15),%rax
cmp    0x8(%r14),%rax
jne    1236 <is_same_file+0xe6>
mov    0x10(%r15),%rax
cmp    0x10(%r14),%rax
jne    1236 <is_same_file+0xe6>
mov    %r15,%rdi
call   1030 <free@plt>
mov    %r14,%rdi
call   1030 <free@plt>
mov    $0xffffffff,%eax
jmp    1248 <is_same_file+0xf8>
mov    %r15,%rdi
call   1030 <free@plt>
mov    %r14,%rdi
call   1030 <free@plt>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
%struct.stat = type { i32, i64, i64 }
@S_IFLNK = global i32 0
define i32 @is_same_file(i8* %0, i8* %1) {
%3 = alloca i32
%4 = alloca i8*
%5 = alloca i8*
%6 = alloca %struct.stat*
%7 = alloca %struct.stat*
store i8* %0, i8** %4
store i8* %1, i8** %5
%8 = call i64 @malloc(i32 24)
%9 = inttoptr i64 %8 to %struct.stat*
store %struct.stat* %9, %struct.stat** %6
%10 = call i64 @malloc(i32 24)
%11 = inttoptr i64 %10 to %struct.stat*
store %struct.stat* %11, %struct.stat** %7
%12 = load i8*, i8** %4
%13 = load %struct.stat*, %struct.stat** %6
%14 = call i32 @stat(i8* %12, %struct.stat* %13)
%15 = load i8*, i8** %5
%16 = load %struct.stat*, %struct.stat** %7
%17 = call i32 @stat(i8* %15, %struct.stat* %16)
%18 = load i8*, i8** %4
%19 = load i8*, i8** %5
%20 = call i64 @strcmp(i8* %18, i8* %19)
%21 = icmp eq i64 %20, 0
br i1 %21, label %22, label %27
22: ; preds = %2
%23 = load %struct.stat*, %struct.stat** %6
%24 = call i32 @free(%struct.stat* %23)
%25 = load %struct.stat*, %struct.stat** %7
%26 = call i32 @free(%struct.stat* %25)
store i32 -1, i32* %3
br label %197
27: ; preds = %2
%28 = load i8*, i8** %4
%29 = load %struct.stat*, %struct.stat** %6
%30 = call i32 @lstat(i8* %28, %struct.stat* %29)
%31 = load i8*, i8** %5
%32 = load %struct.stat*, %struct.stat** %7
%33 = call i32 @lstat(i8* %31, %struct.stat* %32)
%34 = load %struct.stat*, %struct.stat** %6
%35 = getelementptr inbounds %struct.stat, %struct.stat* %34, i32 0, i32 0
%36 = load i32, i32* %35
%37 = load i32, i32* @S_IFLNK
%38 = and i32 %36, %37
%39 = icmp ne i32 %38, 0
br i1 %39, label %73, label %40
40: ; preds = %27
%41 = load %struct.stat*, %struct.stat** %7
%42 = getelementptr inbounds %struct.stat, %struct.stat* %41, i32 0, i32 0
%43 = load i32, i32* %42
%44 = load i32, i32* @S_IFLNK
%45 = and i32 %43, %44
%46 = icmp ne i32 %45, 0
br i1 %46, label %73, label %47
47: ; preds = %40
%48 = load %struct.stat*, %struct.stat** %6
%49 = getelementptr inbounds %struct.stat, %struct.stat* %48, i32 0, i32 1
%50 = load i64, i64* %49
%51 = load %struct.stat*, %struct.stat** %7
%52 = getelementptr inbounds %struct.stat, %struct.stat* %51, i32 0, i32 1
%53 = load i64, i64* %52
%54 = icmp eq i64 %50, %53
br i1 %54, label %55, label %68
55: ; preds = %47
%56 = load %struct.stat*, %struct.stat** %6
%57 = getelementptr inbounds %struct.stat, %struct.stat* %56, i32 0, i32 2
%58 = load i64, i64* %57
%59 = load %struct.stat*, %struct.stat** %7
%60 = getelementptr inbounds %struct.stat, %struct.stat* %59, i32 0, i32 2
%61 = load i64, i64* %60
%62 = icmp eq i64 %58, %61
br i1 %62, label %63, label %68
63: ; preds = %55
%64 = load %struct.stat*, %struct.stat** %6
%65 = call i32 @free(%struct.stat* %64)
%66 = load %struct.stat*, %struct.stat** %7
%67 = call i32 @free(%struct.stat* %66)
store i32 -1, i32* %3
br label %197
68: ; preds = %55, %47
%69 = load %struct.stat*, %struct.stat** %6
%70 = call i32 @free(%struct.stat* %69)
%71 = load %struct.stat*, %struct.stat** %7
%72 = call i32 @free(%struct.stat* %71)
store i32 0, i32* %3
br label %197
73: ; preds = %40, %27
%74 = load %struct.stat*, %struct.stat** %6
%75 = getelementptr inbounds %struct.stat, %struct.stat* %74, i32 0, i32 0
%76 = load i32, i32* %75
%77 = load i32, i32* @S_IFLNK
%78 = and i32 %76, %77
%79 = icmp ne i32 %78, 0
br i1 %79, label %80, label %119
80: ; preds = %73
%81 = load %struct.stat*, %struct.stat** %7
%82 = getelementptr inbounds %struct.stat, %struct.stat* %81, i32 0, i32 0
%83 = load i32, i32* %82
%84 = load i32, i32* @S_IFLNK
%85 = and i32 %83, %84
%86 = icmp ne i32 %85, 0
br i1 %86, label %87, label %119
87: ; preds = %80
%88 = load i8*, i8** %4
%89 = load %struct.stat*, %struct.stat** %6
%90 = call i32 @stat(i8* %88, %struct.stat* %89)
%91 = load i8*, i8** %5
%92 = load %struct.stat*, %struct.stat** %7
%93 = call i32 @stat(i8* %91, %struct.stat* %92)
%94 = load %struct.stat*, %struct.stat** %6
%95 = getelementptr inbounds %struct.stat, %struct.stat* %94, i32 0, i32 1
%96 = load i64, i64* %95
%97 = load %struct.stat*, %struct.stat** %7
%98 = getelementptr inbounds %struct.stat, %struct.stat* %97, i32 0, i32 1
%99 = load i64, i64* %98
%100 = icmp eq i64 %96, %99
br i1 %100, label %101, label %114
101: ; preds = %87
%102 = load %struct.stat*, %struct.stat** %6
%103 = getelementptr inbounds %struct.stat, %struct.stat* %102, i32 0, i32 2
%104 = load i64, i64* %103
%105 = load %struct.stat*, %struct.stat** %7
%106 = getelementptr inbounds %struct.stat, %struct.stat* %105, i32 0, i32 2
%107 = load i64, i64* %106
%108 = icmp eq i64 %104, %107
br i1 %108, label %109, label %114
109: ; preds = %101
%110 = load %struct.stat*, %struct.stat** %6
%111 = call i32 @free(%struct.stat* %110)
%112 = load %struct.stat*, %struct.stat** %7
%113 = call i32 @free(%struct.stat* %112)
store i32 -1, i32* %3
br label %197
114: ; preds = %101, %87
%115 = load %struct.stat*, %struct.stat** %6
%116 = call i32 @free(%struct.stat* %115)
%117 = load %struct.stat*, %struct.stat** %7
%118 = call i32 @free(%struct.stat* %117)
store i32 0, i32* %3
br label %197
119: ; preds = %80, %73
%120 = load %struct.stat*, %struct.stat** %6
%121 = getelementptr inbounds %struct.stat, %struct.stat* %120, i32 0, i32 0
%122 = load i32, i32* %121
%123 = load i32, i32* @S_IFLNK
%124 = and i32 %122, %123
%125 = icmp ne i32 %124, 0
br i1 %125, label %126, label %165
126: ; preds = %119
%127 = load %struct.stat*, %struct.stat** %7
%128 = getelementptr inbounds %struct.stat, %struct.stat* %127, i32 0, i32 0
%129 = load i32, i32* %128
%130 = load i32, i32* @S_IFLNK
%131 = and i32 %129, %130
%132 = icmp ne i32 %131, 0
br i1 %132, label %165, label %133
133: ; preds = %126
%134 = load i8*, i8** %4
%135 = load %struct.stat*, %struct.stat** %6
%136 = call i32 @stat(i8* %134, %struct.stat* %135)
%137 = load i8*, i8** %5
%138 = load %struct.stat*, %struct.stat** %7
%139 = call i32 @stat(i8* %137, %struct.stat* %138)
%140 = load %struct.stat*, %struct.stat** %6
%141 = getelementptr inbounds %struct.stat, %struct.stat* %140, i32 0, i32 1
%142 = load i64, i64* %141
%143 = load %struct.stat*, %struct.stat** %7
%144 = getelementptr inbounds %struct.stat, %struct.stat* %143, i32 0, i32 1
%145 = load i64, i64* %144
%146 = icmp eq i64 %142, %145
br i1 %146, label %147, label %160
147: ; preds = %133
%148 = load %struct.stat*, %struct.stat** %6
%149 = getelementptr inbounds %struct.stat, %struct.stat* %148, i32 0, i32 2
%150 = load i64, i64* %149
%151 = load %struct.stat*, %struct.stat** %7
%152 = getelementptr inbounds %struct.stat, %struct.stat* %151, i32 0, i32 2
%153 = load i64, i64* %152
%154 = icmp eq i64 %150, %153
br i1 %154, label %155, label %160
155: ; preds = %147
%156 = load %struct.stat*, %struct.stat** %6
%157 = call i32 @free(%struct.stat* %156)
%158 = load %struct.stat*, %struct.stat** %7
%159 = call i32 @free(%struct.stat* %158)
store i32 -1, i32* %3
br label %197
160: ; preds = %147, %133
%161 = load %struct.stat*, %struct.stat** %6
%162 = call i32 @free(%struct.stat* %161)
%163 = load %struct.stat*, %struct.stat** %7
%164 = call i32 @free(%struct.stat* %163)
store i32 0, i32* %3
br label %197
165: ; preds = %126, %119
%166 = load i8*, i8** %4
%167 = load %struct.stat*, %struct.stat** %6
%168 = call i32 @stat(i8* %166, %struct.stat* %167)
%169 = load i8*, i8** %5
%170 = load %struct.stat*, %struct.stat** %7
%171 = call i32 @stat(i8* %169, %struct.stat* %170)
%172 = load %struct.stat*, %struct.stat** %6
%173 = getelementptr inbounds %struct.stat, %struct.stat* %172, i32 0, i32 1
%174 = load i64, i64* %173
%175 = load %struct.stat*, %struct.stat** %7
%176 = getelementptr inbounds %struct.stat, %struct.stat* %175, i32 0, i32 1
%177 = load i64, i64* %176
%178 = icmp eq i64 %174, %177
br i1 %178, label %179, label %192
179: ; preds = %165
%180 = load %struct.stat*, %struct.stat** %6
%181 = getelementptr inbounds %struct.stat, %struct.stat* %180, i32 0, i32 2
%182 = load i64, i64* %181
%183 = load %struct.stat*, %struct.stat** %7
%184 = getelementptr inbounds %struct.stat, %struct.stat* %183, i32 0, i32 2
%185 = load i64, i64* %184
%186 = icmp eq i64 %182, %185
br i1 %186, label %187, label %192
187: ; preds = %179
%188 = load %struct.stat*, %struct.stat** %6
%189 = call i32 @free(%struct.stat* %188)
%190 = load %struct.stat*, %struct.stat** %7
%191 = call i32 @free(%struct.stat* %190)
store i32 -1, i32* %3
br label %197
192: ; preds = %179, %165
%193 = load %struct.stat*, %struct.stat** %6
%194 = call i32 @free(%struct.stat* %193)
%195 = load %struct.stat*, %struct.stat** %7
%196 = call i32 @free(%struct.stat* %195)
store i32 0, i32* %3
br label %197
197: ; preds = %192, %187, %160, %155, %114, %109, %68, %63, %22
%198 = load i32, i32* %3
ret i32 %198
}

LLVM IR (-O2):
%struct.stat = type { i32, i64, i64 }
@S_IFLNK = global i32 0
define i32 @is_same_file(i8* %0, i8* %1) {
%3 = tail call i64 @malloc(i32 24)
%4 = inttoptr i64 %3 to %struct.stat*
%5 = tail call i64 @malloc(i32 24)
%6 = inttoptr i64 %5 to %struct.stat*
%7 = tail call i32 @stat(i8* %0, %struct.stat* %4)
%8 = tail call i32 @stat(i8* %1, %struct.stat* %6)
%9 = tail call i64 @strcmp(i8* %0, i8* %1)
%10 = icmp eq i64 %9, 0
br i1 %10, label %11, label %14
11: ; preds = %2
%12 = tail call i32 @free(%struct.stat* %4)
%13 = tail call i32 @free(%struct.stat* %6)
br label %99
14: ; preds = %2
%15 = tail call i32 @lstat(i8* %0, %struct.stat* %4)
%16 = tail call i32 @lstat(i8* %1, %struct.stat* %6)
%17 = getelementptr inbounds %struct.stat, %struct.stat* %4, i64 0, i32 0
%18 = load i32, i32* %17
%19 = load i32, i32* @S_IFLNK
%20 = and i32 %19, %18
%21 = icmp eq i32 %20, 0
%22 = getelementptr inbounds %struct.stat, %struct.stat* %6, i64 0, i32 0
%23 = load i32, i32* %22
%24 = and i32 %23, %19
%25 = icmp eq i32 %24, 0
br i1 %21, label %26, label %45
26: ; preds = %14
br i1 %25, label %27, label %79
27: ; preds = %26
%28 = getelementptr inbounds %struct.stat, %struct.stat* %4, i64 0, i32 1
%29 = load i64, i64* %28
%30 = getelementptr inbounds %struct.stat, %struct.stat* %6, i64 0, i32 1
%31 = load i64, i64* %30
%32 = icmp eq i64 %29, %31
br i1 %32, label %33, label %42
33: ; preds = %27
%34 = getelementptr inbounds %struct.stat, %struct.stat* %4, i64 0, i32 2
%35 = load i64, i64* %34
%36 = getelementptr inbounds %struct.stat, %struct.stat* %6, i64 0, i32 2
%37 = load i64, i64* %36
%38 = icmp eq i64 %35, %37
br i1 %38, label %39, label %42
39: ; preds = %33
%40 = tail call i32 @free(%struct.stat* %4)
%41 = tail call i32 @free(%struct.stat* %6)
br label %99
42: ; preds = %33, %27
%43 = tail call i32 @free(%struct.stat* %4)
%44 = tail call i32 @free(%struct.stat* %6)
br label %99
45: ; preds = %14
%46 = tail call i32 @stat(i8* %0, %struct.stat* %4)
%47 = tail call i32 @stat(i8* %1, %struct.stat* %6)
%48 = getelementptr inbounds %struct.stat, %struct.stat* %4, i64 0, i32 1
%49 = load i64, i64* %48
%50 = getelementptr inbounds %struct.stat, %struct.stat* %6, i64 0, i32 1
%51 = load i64, i64* %50
%52 = icmp eq i64 %49, %51
br i1 %25, label %66, label %53
53: ; preds = %45
br i1 %52, label %54, label %63
54: ; preds = %53
%55 = getelementptr inbounds %struct.stat, %struct.stat* %4, i64 0, i32 2
%56 = load i64, i64* %55
%57 = getelementptr inbounds %struct.stat, %struct.stat* %6, i64 0, i32 2
%58 = load i64, i64* %57
%59 = icmp eq i64 %56, %58
br i1 %59, label %60, label %63
60: ; preds = %54
%61 = tail call i32 @free(%struct.stat* %4)
%62 = tail call i32 @free(%struct.stat* %6)
br label %99
63: ; preds = %54, %53
%64 = tail call i32 @free(%struct.stat* %4)
%65 = tail call i32 @free(%struct.stat* %6)
br label %99
66: ; preds = %45
br i1 %52, label %67, label %76
67: ; preds = %66
%68 = getelementptr inbounds %struct.stat, %struct.stat* %4, i64 0, i32 2
%69 = load i64, i64* %68
%70 = getelementptr inbounds %struct.stat, %struct.stat* %6, i64 0, i32 2
%71 = load i64, i64* %70
%72 = icmp eq i64 %69, %71
br i1 %72, label %73, label %76
73: ; preds = %67
%74 = tail call i32 @free(%struct.stat* %4)
%75 = tail call i32 @free(%struct.stat* %6)
br label %99
76: ; preds = %67, %66
%77 = tail call i32 @free(%struct.stat* %4)
%78 = tail call i32 @free(%struct.stat* %6)
br label %99
79: ; preds = %26
%80 = tail call i32 @stat(i8* %0, %struct.stat* %4)
%81 = tail call i32 @stat(i8* %1, %struct.stat* %6)
%82 = getelementptr inbounds %struct.stat, %struct.stat* %4, i64 0, i32 1
%83 = load i64, i64* %82
%84 = getelementptr inbounds %struct.stat, %struct.stat* %6, i64 0, i32 1
%85 = load i64, i64* %84
%86 = icmp eq i64 %83, %85
br i1 %86, label %87, label %96
87: ; preds = %79
%88 = getelementptr inbounds %struct.stat, %struct.stat* %4, i64 0, i32 2
%89 = load i64, i64* %88
%90 = getelementptr inbounds %struct.stat, %struct.stat* %6, i64 0, i32 2
%91 = load i64, i64* %90
%92 = icmp eq i64 %89, %91
br i1 %92, label %93, label %96
93: ; preds = %87
%94 = tail call i32 @free(%struct.stat* %4)
%95 = tail call i32 @free(%struct.stat* %6)
br label %99
96: ; preds = %87, %79
%97 = tail call i32 @free(%struct.stat* %4)
%98 = tail call i32 @free(%struct.stat* %6)
br label %99
99: ; preds = %96, %93, %76, %73, %63, %60, %42, %39, %11
%100 = phi i32 [ -1, %11 ], [ -1, %60 ], [ 0, %63 ], [ -1, %93 ], [ 0, %96 ], [ -1, %73 ], [ 0, %76 ], [ -1, %39 ], [ 0, %42 ]
ret i32 %100
}