#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 */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
int BUFSIZ;
int cmp_cache(char *, char *, int);
int /*<<< orphan*/ errno;
int /*<<< orphan*/ fclose(int /*<<< orphan*/ *);
int /*<<< orphan*/ feof(int /*<<< orphan*/ *);
int fgetl(int /*<<< orphan*/ *, int, char *);
int /*<<< orphan*/ *fopen(char *, char *);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, char *, ...);
int /*<<< orphan*/ memset(char *, int /*<<< orphan*/, int);
int /*<<< orphan*/ puts(char *);
int /*<<< orphan*/ stderr;
char *strerror(int /*<<< orphan*/);
int main(int argc, char *argv[]) {
  FILE *fd1;
  FILE *fd2;
  if (argc != 3) {
    fprintf(stderr, "usage: %s <hashfile> <foundfile>\n", argv[0]);
    return (-1);
  }
  char *infile = argv[1];
  char *removefile = argv[2];
  if ((fd1 = fopen(infile, "rb")) == NULL) {
    fprintf(stderr, "%s: %s\n", infile, strerror(errno));
    return (-1);
  }
  if ((fd2 = fopen(removefile, "rb")) == NULL) {
    fprintf(stderr, "%s: %s\n", removefile, strerror(errno));
    return (-1);
  }
  int len;
  char line_buf1[BUFSIZ];
  char line_buf2[BUFSIZ];
  len = 0;
  if ((len = fgetl(fd1, BUFSIZ, line_buf1)) == -1)
    memset(line_buf1, 0, BUFSIZ);
  if (fgetl(fd2, BUFSIZ, line_buf2) == -1)
    memset(line_buf2, 0, BUFSIZ);
  int comp = 1;
  while (!feof(fd1) && !feof(fd2)) {
    comp = cmp_cache(line_buf1, line_buf2, len);
    if (comp == 0) {
      if ((len = fgetl(fd1, BUFSIZ, line_buf1)) == -1)
        memset(line_buf1, 0, BUFSIZ);
      if (fgetl(fd2, BUFSIZ, line_buf2) == -1)
        memset(line_buf2, 0, BUFSIZ);
    } else if (comp > 0) {
      puts(line_buf1);
      if (fgetl(fd2, BUFSIZ, line_buf2) == -1)
        memset(line_buf2, 0, BUFSIZ);
    } else if (comp < 0) {
      puts(line_buf1);
      if ((len = fgetl(fd1, BUFSIZ, line_buf1)) == -1)
        memset(line_buf1, 0, BUFSIZ);
    }
  }
  if (!feof(fd1) && comp == 0)
    puts(line_buf1);
  if (comp > 0)
    puts(line_buf1);
  while (!feof(fd1)) {
    if (fgetl(fd1, BUFSIZ, line_buf1) == -1) {
      memset(line_buf1, 0, BUFSIZ);
      continue;
    }
    puts(line_buf1);
  }
  fclose(fd1);
  fclose(fd2);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x90,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpl   $0x3,-0x8(%rbp)
je     11dd <main+0x4d>
mov    0x2e26(%rip),%rax
mov    (%rax),%edi
mov    -0x10(%rbp),%rax
mov    (%rax),%rdx
lea    0xe36(%rip),%rsi
mov    $0x0,%al
call   1060 <fprintf@plt>
movl   $0xffffffff,-0x4(%rbp)
jmp    15de <main+0x44e>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rax
mov    %rax,-0x28(%rbp)
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rax
mov    %rax,-0x30(%rbp)
mov    -0x28(%rbp),%rdi
lea    0xe22(%rip),%rsi
call   10a0 <fopen@plt>
mov    %rax,-0x18(%rbp)
cmp    $0x0,%rax
jne    1259 <main+0xc9>
mov    0x2dc6(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x64(%rbp)
mov    -0x28(%rbp),%rax
mov    %rax,-0x60(%rbp)
mov    0x2da2(%rip),%rax
mov    (%rax),%edi
call   10b0 <strerror@plt>
mov    -0x64(%rbp),%edi
mov    -0x60(%rbp),%rdx
mov    %rax,%rcx
lea    0xddf(%rip),%rsi
mov    $0x0,%al
call   1060 <fprintf@plt>
movl   $0xffffffff,-0x4(%rbp)
jmp    15de <main+0x44e>
mov    -0x30(%rbp),%rdi
lea    0xdbe(%rip),%rsi
call   10a0 <fopen@plt>
mov    %rax,-0x20(%rbp)
cmp    $0x0,%rax
jne    12bd <main+0x12d>
mov    0x2d62(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x74(%rbp)
mov    -0x30(%rbp),%rax
mov    %rax,-0x70(%rbp)
mov    0x2d3e(%rip),%rax
mov    (%rax),%edi
call   10b0 <strerror@plt>
mov    -0x74(%rbp),%edi
mov    -0x70(%rbp),%rdx
mov    %rax,%rcx
lea    0xd7b(%rip),%rsi
mov    $0x0,%al
call   1060 <fprintf@plt>
movl   $0xffffffff,-0x4(%rbp)
jmp    15de <main+0x44e>
mov    0x2d14(%rip),%rax
mov    (%rax),%ecx
mov    %rsp,%rdx
mov    %rdx,-0x40(%rbp)
mov    %rcx,%rsi
add    $0xf,%rsi
and    $0xfffffffffffffff0,%rsi
mov    %rsp,%rdx
sub    %rsi,%rdx
mov    %rdx,-0x88(%rbp)
mov    %rdx,%rsp
mov    %rcx,-0x48(%rbp)
mov    (%rax),%eax
mov    %rax,%rsi
add    $0xf,%rsi
and    $0xfffffffffffffff0,%rsi
mov    %rsp,%rcx
sub    %rsi,%rcx
mov    %rcx,-0x80(%rbp)
mov    %rcx,%rsp
mov    %rax,-0x50(%rbp)
movl   $0x0,-0x34(%rbp)
mov    -0x18(%rbp),%rdi
mov    0x2cbc(%rip),%rax
mov    (%rax),%esi
call   1080 <fgetl@plt>
mov    %eax,-0x34(%rbp)
cmp    $0xffffffff,%eax
jne    1346 <main+0x1b6>
mov    -0x88(%rbp),%rdi
mov    0x2c9b(%rip),%rax
mov    (%rax),%edx
xor    %esi,%esi
call   1050 <memset@plt>
mov    -0x80(%rbp),%rdx
mov    -0x20(%rbp),%rdi
mov    0x2c83(%rip),%rax
mov    (%rax),%esi
call   1080 <fgetl@plt>
cmp    $0xffffffff,%eax
jne    1379 <main+0x1e9>
mov    -0x80(%rbp),%rdi
mov    0x2c68(%rip),%rax
mov    (%rax),%edx
xor    %esi,%esi
call   1050 <memset@plt>
movl   $0x1,-0x54(%rbp)
mov    -0x18(%rbp),%rdi
call   1070 <feof@plt>
mov    %eax,%ecx
xor    %eax,%eax
cmp    $0x0,%ecx
mov    %al,-0x89(%rbp)
jne    13b3 <main+0x223>
mov    -0x20(%rbp),%rdi
call   1070 <feof@plt>
cmp    $0x0,%eax
setne  %al
xor    $0xff,%al
mov    %al,-0x89(%rbp)
mov    -0x89(%rbp),%al
test   $0x1,%al
jne    13c6 <main+0x236>
jmp    150e <main+0x37e>
mov    -0x80(%rbp),%rsi
mov    -0x88(%rbp),%rdi
mov    -0x34(%rbp),%edx
call   1090 <cmp_cache@plt>
mov    %eax,-0x54(%rbp)
cmpl   $0x0,-0x54(%rbp)
jne    145a <main+0x2ca>
mov    -0x88(%rbp),%rdx
mov    -0x18(%rbp),%rdi
mov    0x2be0(%rip),%rax
mov    (%rax),%esi
call   1080 <fgetl@plt>
mov    %eax,-0x34(%rbp)
cmp    $0xffffffff,%eax
jne    1422 <main+0x292>
mov    -0x88(%rbp),%rdi
mov    0x2bbf(%rip),%rax
mov    (%rax),%edx
xor    %esi,%esi
call   1050 <memset@plt>
mov    -0x80(%rbp),%rdx
mov    -0x20(%rbp),%rdi
mov    0x2ba7(%rip),%rax
mov    (%rax),%esi
call   1080 <fgetl@plt>
cmp    $0xffffffff,%eax
jne    1455 <main+0x2c5>
mov    -0x80(%rbp),%rdi
mov    0x2b8c(%rip),%rax
mov    (%rax),%edx
xor    %esi,%esi
call   1050 <memset@plt>
jmp    1509 <main+0x379>
cmpl   $0x0,-0x54(%rbp)
jle    14a8 <main+0x318>
mov    -0x88(%rbp),%rdi
call   1030 <puts@plt>
mov    -0x80(%rbp),%rdx
mov    -0x20(%rbp),%rdi
mov    0x2b59(%rip),%rax
mov    (%rax),%esi
call   1080 <fgetl@plt>
cmp    $0xffffffff,%eax
jne    14a3 <main+0x313>
mov    -0x80(%rbp),%rdi
mov    0x2b3e(%rip),%rax
mov    (%rax),%edx
xor    %esi,%esi
call   1050 <memset@plt>
jmp    1504 <main+0x374>
cmpl   $0x0,-0x54(%rbp)
jge    14ff <main+0x36f>
mov    -0x88(%rbp),%rdi
call   1030 <puts@plt>
mov    -0x88(%rbp),%rdx
mov    -0x18(%rbp),%rdi
mov    0x2b08(%rip),%rax
mov    (%rax),%esi
call   1080 <fgetl@plt>
mov    %eax,-0x34(%rbp)
cmp    $0xffffffff,%eax
jne    14fa <main+0x36a>
mov    -0x88(%rbp),%rdi
mov    0x2ae7(%rip),%rax
mov    (%rax),%edx
xor    %esi,%esi
call   1050 <memset@plt>
jmp    14ff <main+0x36f>
jmp    1504 <main+0x374>
jmp    1509 <main+0x379>
jmp    1380 <main+0x1f0>
mov    -0x18(%rbp),%rdi
call   1070 <feof@plt>
cmp    $0x0,%eax
jne    1536 <main+0x3a6>
cmpl   $0x0,-0x54(%rbp)
jne    1536 <main+0x3a6>
mov    -0x88(%rbp),%rdi
call   1030 <puts@plt>
cmpl   $0x0,-0x54(%rbp)
jle    154c <main+0x3bc>
mov    -0x88(%rbp),%rdi
call   1030 <puts@plt>
jmp    1551 <main+0x3c1>
mov    -0x18(%rbp),%rdi
call   1070 <feof@plt>
cmp    $0x0,%eax
setne  %al
xor    $0xff,%al
test   $0x1,%al
jne    156f <main+0x3df>
jmp    15be <main+0x42e>
mov    -0x88(%rbp),%rdx
mov    -0x18(%rbp),%rdi
mov    0x2a57(%rip),%rax
mov    (%rax),%esi
call   1080 <fgetl@plt>
cmp    $0xffffffff,%eax
jne    15ad <main+0x41d>
mov    -0x88(%rbp),%rdi
mov    0x2a39(%rip),%rax
mov    (%rax),%edx
xor    %esi,%esi
call   1050 <memset@plt>
jmp    1551 <main+0x3c1>
mov    -0x88(%rbp),%rdi
call   1030 <puts@plt>
jmp    1551 <main+0x3c1>
mov    -0x18(%rbp),%rdi
call   1040 <fclose@plt>
mov    -0x20(%rbp),%rdi
call   1040 <fclose@plt>
movl   $0x0,-0x4(%rbp)
mov    -0x40(%rbp),%rax
mov    %rax,%rsp
mov    -0x4(%rbp),%eax
mov    %rbp,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
mov    %rsp,%rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x18,%rsp
cmp    $0x3,%edi
jne    1278 <main+0xe8>
mov    0x8(%rsi),%rbx
mov    0x10(%rsi),%r14
lea    0xe69(%rip),%rsi
mov    %rbx,%rdi
call   10a0 <fopen@plt>
test   %rax,%rax
je     129c <main+0x10c>
mov    %rax,%r15
lea    0xe4e(%rip),%rsi
mov    %r14,%rdi
call   10a0 <fopen@plt>
mov    %rax,-0x38(%rbp)
test   %rax,%rax
je     12c3 <main+0x133>
mov    %rsp,-0x40(%rbp)
mov    0x2de4(%rip),%r13
mov    0x0(%r13),%eax
mov    %rsp,%rbx
add    $0xf,%rax
and    $0xfffffffffffffff0,%rax
sub    %rax,%rbx
mov    %rbx,%rsp
mov    0x0(%r13),%esi
mov    %rsp,%r12
mov    %rsi,%rax
add    $0xf,%rax
and    $0xfffffffffffffff0,%rax
sub    %rax,%r12
mov    %r12,%rsp
mov    %r15,%rdi
mov    %rbx,%rdx
call   1080 <fgetl@plt>
mov    %eax,-0x2c(%rbp)
cmp    $0xffffffff,%eax
jne    1242 <main+0xb2>
mov    0x0(%r13),%edx
mov    %rbx,%rdi
xor    %esi,%esi
call   1050 <memset@plt>
mov    0x0(%r13),%esi
mov    -0x38(%rbp),%rdi
mov    %r12,%rdx
call   1080 <fgetl@plt>
cmp    $0xffffffff,%eax
jne    1265 <main+0xd5>
mov    0x0(%r13),%edx
mov    %r12,%rdi
xor    %esi,%esi
call   1050 <memset@plt>
mov    %r15,%rdi
call   1070 <feof@plt>
mov    $0x1,%r14d
jmp    1317 <main+0x187>
mov    0x2d61(%rip),%rax
mov    (%rax),%edi
mov    (%rsi),%rdx
lea    0xd75(%rip),%rsi
xor    %eax,%eax
call   1060 <fprintf@plt>
mov    $0xffffffff,%eax
jmp    1412 <main+0x282>
mov    0x2d3d(%rip),%rax
mov    (%rax),%r14d
mov    0x2d23(%rip),%rax
mov    (%rax),%edi
call   10b0 <strerror@plt>
lea    0xd6a(%rip),%rsi
mov    %r14d,%edi
mov    %rbx,%rdx
jmp    12e6 <main+0x156>
mov    0x2d16(%rip),%rax
mov    (%rax),%ebx
mov    0x2cfd(%rip),%rax
mov    (%rax),%edi
call   10b0 <strerror@plt>
lea    0xd44(%rip),%rsi
mov    %ebx,%edi
mov    %r14,%rdx
mov    %rax,%rcx
xor    %eax,%eax
call   1060 <fprintf@plt>
mov    $0xffffffff,%eax
jmp    1412 <main+0x282>
movl   $0xffffffff,-0x2c(%rbp)
mov    %rbx,%rdi
mov    0x0(%r13),%edx
xor    %esi,%esi
call   1050 <memset@plt>
mov    %r15,%rdi
call   1070 <feof@plt>
test   %eax,%eax
jne    13b1 <main+0x221>
mov    -0x38(%rbp),%rdi
call   1070 <feof@plt>
test   %eax,%eax
jne    13b1 <main+0x221>
mov    %rbx,%rdi
mov    %r12,%rsi
mov    -0x2c(%rbp),%edx
call   1090 <cmp_cache@plt>
mov    %eax,%r14d
test   %eax,%eax
je     136b <main+0x1db>
mov    %rbx,%rdi
call   1030 <puts@plt>
mov    0x0(%r13),%esi
test   %r14d,%r14d
jg     1394 <main+0x204>
mov    %r15,%rdi
mov    %rbx,%rdx
call   1080 <fgetl@plt>
mov    %eax,-0x2c(%rbp)
cmp    $0xffffffff,%eax
jne    130f <main+0x17f>
jmp    12fa <main+0x16a>
mov    0x0(%r13),%esi
mov    %r15,%rdi
mov    %rbx,%rdx
call   1080 <fgetl@plt>
mov    %eax,-0x2c(%rbp)
cmp    $0xffffffff,%eax
jne    1390 <main+0x200>
mov    0x0(%r13),%edx
mov    %rbx,%rdi
xor    %esi,%esi
call   1050 <memset@plt>
mov    0x0(%r13),%esi
mov    -0x38(%rbp),%rdi
mov    %r12,%rdx
call   1080 <fgetl@plt>
mov    %r12,%rdi
cmp    $0xffffffff,%eax
jne    130f <main+0x17f>
jmp    1304 <main+0x174>
mov    %r15,%rdi
call   1070 <feof@plt>
or     %r14d,%eax
je     13c3 <main+0x233>
test   %r14d,%r14d
jle    13cb <main+0x23b>
mov    %rbx,%rdi
call   1030 <puts@plt>
mov    %r15,%rdi
call   1070 <feof@plt>
test   %eax,%eax
jne    13fb <main+0x26b>
mov    0x0(%r13),%esi
mov    %r15,%rdi
mov    %rbx,%rdx
call   1080 <fgetl@plt>
cmp    $0xffffffff,%eax
jne    13c3 <main+0x233>
mov    0x0(%r13),%edx
mov    %rbx,%rdi
xor    %esi,%esi
call   1050 <memset@plt>
jmp    13cb <main+0x23b>
mov    %r15,%rdi
call   1040 <fclose@plt>
mov    -0x38(%rbp),%rdi
call   1040 <fclose@plt>
xor    %eax,%eax
mov    -0x40(%rbp),%rsp
lea    -0x28(%rbp),%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@stderr = global i32 0
@.str = [34 x i8] c"usage: %s <hashfile> <foundfile>\0A\00"
@.str.1 = [3 x i8] c"rb\00"
@.str.2 = [8 x i8] c"%s: %s\0A\00"
@errno = global i32 0
@BUFSIZ = global i32 0
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32*
%7 = alloca i32*
%8 = alloca i8*
%9 = alloca i8*
%10 = alloca i32
%11 = alloca i8*
%12 = alloca i64
%13 = alloca i64
%14 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%15 = load i32, i32* %4
%16 = icmp ne i32 %15, 3
br i1 %16, label %17, label %23
17: ; preds = %2
%18 = load i32, i32* @stderr
%19 = load i8**, i8*** %5
%20 = getelementptr inbounds i8*, i8** %19, i64 0
%21 = load i8*, i8** %20
%22 = call i32 (i32, i8*, i8*, ...) @fprintf(i32 %18, i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str, i64 0, i64 0), i8* %21)
store i32 -1, i32* %3
br label %171
23: ; preds = %2
%24 = load i8**, i8*** %5
%25 = getelementptr inbounds i8*, i8** %24, i64 1
%26 = load i8*, i8** %25
store i8* %26, i8** %8
%27 = load i8**, i8*** %5
%28 = getelementptr inbounds i8*, i8** %27, i64 2
%29 = load i8*, i8** %28
store i8* %29, i8** %9
%30 = load i8*, i8** %8
%31 = call i32* @fopen(i8* %30, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
store i32* %31, i32** %6
%32 = icmp eq i32* %31, null
br i1 %32, label %33, label %39
33: ; preds = %23
%34 = load i32, i32* @stderr
%35 = load i8*, i8** %8
%36 = load i32, i32* @errno
%37 = call i8* @strerror(i32 %36)
%38 = call i32 (i32, i8*, i8*, ...) @fprintf(i32 %34, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.2, i64 0, i64 0), i8* %35, i8* %37)
store i32 -1, i32* %3
br label %171
39: ; preds = %23
%40 = load i8*, i8** %9
%41 = call i32* @fopen(i8* %40, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
store i32* %41, i32** %7
%42 = icmp eq i32* %41, null
br i1 %42, label %43, label %49
43: ; preds = %39
%44 = load i32, i32* @stderr
%45 = load i8*, i8** %9
%46 = load i32, i32* @errno
%47 = call i8* @strerror(i32 %46)
%48 = call i32 (i32, i8*, i8*, ...) @fprintf(i32 %44, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.2, i64 0, i64 0), i8* %45, i8* %47)
store i32 -1, i32* %3
br label %171
49: ; preds = %39
%50 = load i32, i32* @BUFSIZ
%51 = zext i32 %50 to i64
%52 = call i8* @llvm.stacksave()
store i8* %52, i8** %11
%53 = alloca i8, i64 %51
store i64 %51, i64* %12
%54 = load i32, i32* @BUFSIZ
%55 = zext i32 %54 to i64
%56 = alloca i8, i64 %55
store i64 %55, i64* %13
store i32 0, i32* %10
%57 = load i32*, i32** %6
%58 = load i32, i32* @BUFSIZ
%59 = call i32 @fgetl(i32* %57, i32 %58, i8* %53)
store i32 %59, i32* %10
%60 = icmp eq i32 %59, -1
br i1 %60, label %61, label %64
61: ; preds = %49
%62 = load i32, i32* @BUFSIZ
%63 = call i32 @memset(i8* %53, i32 0, i32 %62)
br label %64
64: ; preds = %61, %49
%65 = load i32*, i32** %7
%66 = load i32, i32* @BUFSIZ
%67 = call i32 @fgetl(i32* %65, i32 %66, i8* %56)
%68 = icmp eq i32 %67, -1
br i1 %68, label %69, label %72
69: ; preds = %64
%70 = load i32, i32* @BUFSIZ
%71 = call i32 @memset(i8* %56, i32 0, i32 %70)
br label %72
72: ; preds = %69, %64
store i32 1, i32* %14
br label %73
73: ; preds = %134, %72
%74 = load i32*, i32** %6
%75 = call i32 @feof(i32* %74)
%76 = icmp ne i32 %75, 0
br i1 %76, label %82, label %77
77: ; preds = %73
%78 = load i32*, i32** %7
%79 = call i32 @feof(i32* %78)
%80 = icmp ne i32 %79, 0
%81 = xor i1 %80, true
br label %82
82: ; preds = %77, %73
%83 = phi i1 [ false, %73 ], [ %81, %77 ]
br i1 %83, label %84, label %135
84: ; preds = %82
%85 = load i32, i32* %10
%86 = call i32 @cmp_cache(i8* %53, i8* %56, i32 %85)
store i32 %86, i32* %14
%87 = load i32, i32* %14
%88 = icmp eq i32 %87, 0
br i1 %88, label %89, label %106
89: ; preds = %84
%90 = load i32*, i32** %6
%91 = load i32, i32* @BUFSIZ
%92 = call i32 @fgetl(i32* %90, i32 %91, i8* %53)
store i32 %92, i32* %10
%93 = icmp eq i32 %92, -1
br i1 %93, label %94, label %97
94: ; preds = %89
%95 = load i32, i32* @BUFSIZ
%96 = call i32 @memset(i8* %53, i32 0, i32 %95)
br label %97
97: ; preds = %94, %89
%98 = load i32*, i32** %7
%99 = load i32, i32* @BUFSIZ
%100 = call i32 @fgetl(i32* %98, i32 %99, i8* %56)
%101 = icmp eq i32 %100, -1
br i1 %101, label %102, label %105
102: ; preds = %97
%103 = load i32, i32* @BUFSIZ
%104 = call i32 @memset(i8* %56, i32 0, i32 %103)
br label %105
105: ; preds = %102, %97
br label %134
106: ; preds = %84
%107 = load i32, i32* %14
%108 = icmp sgt i32 %107, 0
br i1 %108, label %109, label %119
109: ; preds = %106
%110 = call i32 @puts(i8* %53)
%111 = load i32*, i32** %7
%112 = load i32, i32* @BUFSIZ
%113 = call i32 @fgetl(i32* %111, i32 %112, i8* %56)
%114 = icmp eq i32 %113, -1
br i1 %114, label %115, label %118
115: ; preds = %109
%116 = load i32, i32* @BUFSIZ
%117 = call i32 @memset(i8* %56, i32 0, i32 %116)
br label %118
118: ; preds = %115, %109
br label %133
119: ; preds = %106
%120 = load i32, i32* %14
%121 = icmp slt i32 %120, 0
br i1 %121, label %122, label %132
122: ; preds = %119
%123 = call i32 @puts(i8* %53)
%124 = load i32*, i32** %6
%125 = load i32, i32* @BUFSIZ
%126 = call i32 @fgetl(i32* %124, i32 %125, i8* %53)
store i32 %126, i32* %10
%127 = icmp eq i32 %126, -1
br i1 %127, label %128, label %131
128: ; preds = %122
%129 = load i32, i32* @BUFSIZ
%130 = call i32 @memset(i8* %53, i32 0, i32 %129)
br label %131
131: ; preds = %128, %122
br label %132
132: ; preds = %131, %119
br label %133
133: ; preds = %132, %118
br label %134
134: ; preds = %133, %105
br label %73
135: ; preds = %82
%136 = load i32*, i32** %6
%137 = call i32 @feof(i32* %136)
%138 = icmp ne i32 %137, 0
br i1 %138, label %144, label %139
139: ; preds = %135
%140 = load i32, i32* %14
%141 = icmp eq i32 %140, 0
br i1 %141, label %142, label %144
142: ; preds = %139
%143 = call i32 @puts(i8* %53)
br label %144
144: ; preds = %142, %139, %135
%145 = load i32, i32* %14
%146 = icmp sgt i32 %145, 0
br i1 %146, label %147, label %149
147: ; preds = %144
%148 = call i32 @puts(i8* %53)
br label %149
149: ; preds = %147, %144
br label %150
150: ; preds = %163, %160, %149
%151 = load i32*, i32** %6
%152 = call i32 @feof(i32* %151)
%153 = icmp ne i32 %152, 0
%154 = xor i1 %153, true
br i1 %154, label %155, label %165
155: ; preds = %150
%156 = load i32*, i32** %6
%157 = load i32, i32* @BUFSIZ
%158 = call i32 @fgetl(i32* %156, i32 %157, i8* %53)
%159 = icmp eq i32 %158, -1
br i1 %159, label %160, label %163
160: ; preds = %155
%161 = load i32, i32* @BUFSIZ
%162 = call i32 @memset(i8* %53, i32 0, i32 %161)
br label %150
163: ; preds = %155
%164 = call i32 @puts(i8* %53)
br label %150
165: ; preds = %150
%166 = load i32*, i32** %6
%167 = call i32 @fclose(i32* %166)
%168 = load i32*, i32** %7
%169 = call i32 @fclose(i32* %168)
store i32 0, i32* %3
%170 = load i8*, i8** %11
br label %171
171: ; preds = %165, %43, %33, %17
%172 = load i32, i32* %3
ret i32 %172
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [34 x i8] c"usage: %s <hashfile> <foundfile>\0A\00"
@.str.1 = [3 x i8] c"rb\00"
@.str.2 = [8 x i8] c"%s: %s\0A\00"
@errno = global i32 0
@BUFSIZ = global i32 0
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = icmp eq i32 %0, 3
br i1 %3, label %8, label %4
4: ; preds = %2
%5 = load i32, i32* @stderr
%6 = load i8*, i8** %1
%7 = tail call i32 (i32, i8*, i8*, ...) @fprintf(i32 %5, i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str, i64 0, i64 0), i8* %6)
br label %119
8: ; preds = %2
%9 = getelementptr inbounds i8*, i8** %1, i64 1
%10 = load i8*, i8** %9
%11 = getelementptr inbounds i8*, i8** %1, i64 2
%12 = load i8*, i8** %11
%13 = tail call i32* @fopen(i8* %10, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
%14 = icmp eq i32* %13, null
br i1 %14, label %15, label %20
15: ; preds = %8
%16 = load i32, i32* @stderr
%17 = load i32, i32* @errno
%18 = tail call i8* @strerror(i32 %17)
%19 = tail call i32 (i32, i8*, i8*, ...) @fprintf(i32 %16, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.2, i64 0, i64 0), i8* %10, i8* %18)
br label %119
20: ; preds = %8
%21 = tail call i32* @fopen(i8* %12, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
%22 = icmp eq i32* %21, null
br i1 %22, label %23, label %28
23: ; preds = %20
%24 = load i32, i32* @stderr
%25 = load i32, i32* @errno
%26 = tail call i8* @strerror(i32 %25)
%27 = tail call i32 (i32, i8*, i8*, ...) @fprintf(i32 %24, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.2, i64 0, i64 0), i8* %12, i8* %26)
br label %119
28: ; preds = %20
%29 = load i32, i32* @BUFSIZ
%30 = zext i32 %29 to i64
%31 = tail call i8* @llvm.stacksave()
%32 = alloca i8, i64 %30
%33 = load i32, i32* @BUFSIZ
%34 = zext i32 %33 to i64
%35 = alloca i8, i64 %34
%36 = call i32 @fgetl(i32* %13, i32 %33, i8* %32)
%37 = icmp eq i32 %36, -1
br i1 %37, label %38, label %41
38: ; preds = %28
%39 = load i32, i32* @BUFSIZ
%40 = call i32 @memset(i8* %32, i32 0, i32 %39)
br label %41
41: ; preds = %38, %28
%42 = load i32, i32* @BUFSIZ
%43 = call i32 @fgetl(i32* %21, i32 %42, i8* %35)
%44 = icmp eq i32 %43, -1
br i1 %44, label %45, label %48
45: ; preds = %41
%46 = load i32, i32* @BUFSIZ
%47 = call i32 @memset(i8* %35, i32 0, i32 %46)
br label %48
48: ; preds = %45, %41
%49 = call i32 @feof(i32* %13)
%50 = icmp eq i32 %49, 0
br i1 %50, label %51, label %91
51: ; preds = %48
%52 = call i32 @feof(i32* %21)
%53 = icmp eq i32 %52, 0
br i1 %53, label %57, label %91
54: ; preds = %87
%55 = call i32 @feof(i32* %21)
%56 = icmp eq i32 %55, 0
br i1 %56, label %57, label %91
57: ; preds = %51, %54
%58 = phi i32 [ %88, %54 ], [ %36, %51 ]
%59 = call i32 @cmp_cache(i8* %32, i8* %35, i32 %58)
%60 = icmp eq i32 %59, 0
br i1 %60, label %61, label %72
61: ; preds = %57
%62 = load i32, i32* @BUFSIZ
%63 = call i32 @fgetl(i32* %13, i32 %62, i8* %32)
%64 = icmp eq i32 %63, -1
br i1 %64, label %65, label %68
65: ; preds = %61
%66 = load i32, i32* @BUFSIZ
%67 = call i32 @memset(i8* %32, i32 0, i32 %66)
br label %68
68: ; preds = %65, %61
%69 = load i32, i32* @BUFSIZ
%70 = call i32 @fgetl(i32* %21, i32 %69, i8* %35)
%71 = icmp eq i32 %70, -1
br i1 %71, label %82, label %87
72: ; preds = %57
%73 = icmp sgt i32 %59, 0
%74 = call i32 @puts(i8* %32)
%75 = load i32, i32* @BUFSIZ
br i1 %73, label %76, label %79
76: ; preds = %72
%77 = call i32 @fgetl(i32* %21, i32 %75, i8* %35)
%78 = icmp eq i32 %77, -1
br i1 %78, label %82, label %87
79: ; preds = %72
%80 = call i32 @fgetl(i32* %13, i32 %75, i8* %32)
%81 = icmp eq i32 %80, -1
br i1 %81, label %82, label %87
82: ; preds = %79, %76, %68
%83 = phi i8* [ %35, %68 ], [ %35, %76 ], [ %32, %79 ]
%84 = phi i32 [ %63, %68 ], [ %58, %76 ], [ -1, %79 ]
%85 = load i32, i32* @BUFSIZ
%86 = call i32 @memset(i8* %83, i32 0, i32 %85)
br label %87
87: ; preds = %82, %76, %79, %68
%88 = phi i32 [ %63, %68 ], [ %58, %76 ], [ %80, %79 ], [ %84, %82 ]
%89 = call i32 @feof(i32* %13)
%90 = icmp eq i32 %89, 0
br i1 %90, label %54, label %91
91: ; preds = %87, %54, %51, %48
%92 = phi i32 [ 1, %48 ], [ 1, %51 ], [ %59, %54 ], [ %59, %87 ]
%93 = call i32 @feof(i32* %13)
%94 = icmp eq i32 %93, 0
%95 = icmp eq i32 %92, 0
%96 = select i1 %94, i1 %95, i1 false
%97 = icmp sgt i32 %92, 0
%98 = select i1 %96, i1 true, i1 %97
br i1 %98, label %99, label %101
99: ; preds = %91
%100 = call i32 @puts(i8* %32)
br label %101
101: ; preds = %91, %99
%102 = call i32 @feof(i32* %13)
%103 = icmp eq i32 %102, 0
br i1 %103, label %104, label %116
104: ; preds = %101, %111
%105 = load i32, i32* @BUFSIZ
%106 = call i32 @fgetl(i32* %13, i32 %105, i8* %32)
%107 = icmp eq i32 %106, -1
br i1 %107, label %108, label %114
108: ; preds = %104
%109 = load i32, i32* @BUFSIZ
%110 = call i32 @memset(i8* %32, i32 0, i32 %109)
br label %111
111: ; preds = %108, %114
%112 = call i32 @feof(i32* %13)
%113 = icmp eq i32 %112, 0
br i1 %113, label %104, label %116
114: ; preds = %104
%115 = call i32 @puts(i8* %32)
br label %111
116: ; preds = %111, %101
%117 = call i32 @fclose(i32* %13)
%118 = call i32 @fclose(i32* %21)
br label %119
119: ; preds = %15, %23, %116, %4
%120 = phi i32 [ -1, %4 ], [ -1, %15 ], [ -1, %23 ], [ 0, %116 ]
ret i32 %120
}