#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 */
char EOF;
int /*<<< orphan*/ fclose(int /*<<< orphan*/ *);
scalar_t__ feof(int /*<<< orphan*/ *);
char fgetc(int /*<<< orphan*/ *);
int /*<<< orphan*/ *fopen(char *, char *);
int /*<<< orphan*/ printf(char *, ...);
int strlen(char *);
scalar_t__ strncmp(char *, char *, int);
void checkPlayerStatus(char *logFile, char *playerName) {
  char str[10240];
  FILE *fp = fopen(logFile, "rb");
  if (!fp) {
    printf("Warning, could not open %s\n", logFile);
  }
  int i = 0;
  int isIn = 0;
  char *head1 = "[SERVER] UNREGISTERING CLIENT RegisteredClient: ";
  char *head2 = "Revived PlayerState PlS[";
  int head1Len = strlen(head1);
  int head2Len = strlen(head2);
  int playerNameLen = strlen(playerName);
  while (feof(fp) == 0) {
    char c, *p;
    int count = 0;
    for (p = str; p < &str[10000]; count++) {
      c = fgetc(fp);
      if (c == EOF) {
        fclose(fp);
        printf("%d\n", isIn);
        return;
      }
      if (c == '\n')
        break;
      else
        *(p++) = c;
    }
    *(p++) = 0;
    if (count > head1Len && strncmp(str, head1, head1Len) == 0) {
      if (strncmp(str + head1Len, playerName, playerNameLen) == 0 &&
          str[head1Len + playerNameLen] == ' ') {
        isIn = 0;
      }
    }
    if (count > head2Len && strncmp(str, head2, head2Len) == 0) {
      if (strncmp(str + head2Len, playerName, playerNameLen) == 0 &&
          str[head2Len + playerNameLen] == ';') {
        isIn = 1;
      }
    }
  }
  printf("%d\n", isIn);
  fclose(fp);
}


x86 assembly (clang, -O0):
<checkPlayerStatus>:
push   %rbp
mov    %rsp,%rbp
sub    $0x2850,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
lea    0xe72(%rip),%rsi
call   1090 <fopen@plt>
mov    %rax,-0x2818(%rbp)
cmpq   $0x0,-0x2818(%rbp)
jne    11ba <checkPlayerStatus+0x4a>
mov    -0x8(%rbp),%rsi
lea    0xe50(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
movl   $0x0,-0x281c(%rbp)
movl   $0x0,-0x2820(%rbp)
lea    0xe4a(%rip),%rax
mov    %rax,-0x2828(%rbp)
lea    0xe6d(%rip),%rax
mov    %rax,-0x2830(%rbp)
mov    -0x2828(%rbp),%rdi
call   1050 <strlen@plt>
mov    %eax,-0x2834(%rbp)
mov    -0x2830(%rbp),%rdi
call   1050 <strlen@plt>
mov    %eax,-0x2838(%rbp)
mov    -0x10(%rbp),%rdi
call   1050 <strlen@plt>
mov    %eax,-0x283c(%rbp)
mov    -0x2818(%rbp),%rdi
call   1080 <feof@plt>
cmp    $0x0,%rax
jne    143b <checkPlayerStatus+0x2cb>
movl   $0x0,-0x284c(%rbp)
lea    -0x2810(%rbp),%rax
mov    %rax,-0x2848(%rbp)
mov    -0x2848(%rbp),%rax
lea    -0x2810(%rbp),%rcx
add    $0x2710,%rcx
cmp    %rcx,%rax
jae    1304 <checkPlayerStatus+0x194>
mov    -0x2818(%rbp),%rdi
call   1070 <fgetc@plt>
mov    %al,-0x283d(%rbp)
movsbl -0x283d(%rbp),%eax
mov    0x2d5f(%rip),%rcx
movsbl (%rcx),%ecx
cmp    %ecx,%eax
jne    12b9 <checkPlayerStatus+0x149>
mov    -0x2818(%rbp),%rdi
call   1040 <fclose@plt>
mov    -0x2820(%rbp),%esi
lea    0xdbc(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
jmp    145b <checkPlayerStatus+0x2eb>
movsbl -0x283d(%rbp),%eax
cmp    $0xa,%eax
jne    12ce <checkPlayerStatus+0x15e>
jmp    1304 <checkPlayerStatus+0x194>
mov    -0x283d(%rbp),%cl
mov    -0x2848(%rbp),%rax
mov    %rax,%rdx
add    $0x1,%rdx
mov    %rdx,-0x2848(%rbp)
mov    %cl,(%rax)
jmp    12f0 <checkPlayerStatus+0x180>
mov    -0x284c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x284c(%rbp)
jmp    124b <checkPlayerStatus+0xdb>
mov    -0x2848(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x2848(%rbp)
movb   $0x0,(%rax)
mov    -0x284c(%rbp),%eax
cmp    -0x2834(%rbp),%eax
jle    13a9 <checkPlayerStatus+0x239>
lea    -0x2810(%rbp),%rdi
mov    -0x2828(%rbp),%rsi
mov    -0x2834(%rbp),%edx
call   1030 <strncmp@plt>
cmp    $0x0,%rax
jne    13a9 <checkPlayerStatus+0x239>
lea    -0x2810(%rbp),%rdi
movslq -0x2834(%rbp),%rax
add    %rax,%rdi
mov    -0x10(%rbp),%rsi
mov    -0x283c(%rbp),%edx
call   1030 <strncmp@plt>
cmp    $0x0,%rax
jne    13a4 <checkPlayerStatus+0x234>
mov    -0x2834(%rbp),%eax
add    -0x283c(%rbp),%eax
cltq
movsbl -0x2810(%rbp,%rax,1),%eax
ff
cmp    $0x20,%eax
jne    13a4 <checkPlayerStatus+0x234>
movl   $0x0,-0x2820(%rbp)
jmp    13a9 <checkPlayerStatus+0x239>
mov    -0x284c(%rbp),%eax
cmp    -0x2838(%rbp),%eax
jle    1436 <checkPlayerStatus+0x2c6>
lea    -0x2810(%rbp),%rdi
mov    -0x2830(%rbp),%rsi
mov    -0x2838(%rbp),%edx
call   1030 <strncmp@plt>
cmp    $0x0,%rax
jne    1436 <checkPlayerStatus+0x2c6>
lea    -0x2810(%rbp),%rdi
movslq -0x2838(%rbp),%rax
add    %rax,%rdi
mov    -0x10(%rbp),%rsi
mov    -0x283c(%rbp),%edx
call   1030 <strncmp@plt>
cmp    $0x0,%rax
jne    1431 <checkPlayerStatus+0x2c1>
mov    -0x2838(%rbp),%eax
add    -0x283c(%rbp),%eax
cltq
movsbl -0x2810(%rbp,%rax,1),%eax
ff
cmp    $0x3b,%eax
jne    1431 <checkPlayerStatus+0x2c1>
movl   $0x1,-0x2820(%rbp)
jmp    1436 <checkPlayerStatus+0x2c6>
jmp    121d <checkPlayerStatus+0xad>
mov    -0x2820(%rbp),%esi
lea    0xc21(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x2818(%rbp),%rdi
call   1040 <fclose@plt>
add    $0x2850,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<checkPlayerStatus>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x2848,%rsp
mov    %rsi,%r14
mov    %rdi,%rbp
lea    0xe72(%rip),%rsi
call   1090 <fopen@plt>
mov    %rax,%rbx
test   %rax,%rax
jne    11ac <checkPlayerStatus+0x3c>
lea    0xe61(%rip),%rdi
mov    %rbp,%rsi
xor    %eax,%eax
call   1060 <printf@plt>
lea    0xe6c(%rip),%rdi
call   1050 <strlen@plt>
mov    %eax,%r13d
lea    0xe8e(%rip),%rdi
call   1050 <strlen@plt>
mov    %eax,%r15d
mov    %r14,0x18(%rsp)
mov    %r14,%rdi
call   1050 <strlen@plt>
mov    %eax,0x10(%rsp)
mov    %rbx,%rdi
call   1080 <feof@plt>
xor    %ebp,%ebp
test   %rax,%rax
je     1207 <checkPlayerStatus+0x97>
lea    0xe78(%rip),%rdi
mov    %ebp,%esi
xor    %eax,%eax
call   1060 <printf@plt>
mov    %rbx,%rdi
call   1040 <fclose@plt>
jmp    1380 <checkPlayerStatus+0x210>
lea    0x2750(%rsp),%r14
movslq %r13d,%rax
lea    (%rsp,%rax,1),%rcx
add    $0x40,%rcx
mov    %rcx,0x38(%rsp)
mov    0x10(%rsp),%ecx
add    %ecx,%eax
cltq
mov    %rax,0x28(%rsp)
movslq %r15d,%rax
lea    (%rsp,%rax,1),%rdx
add    $0x40,%rdx
mov    %rdx,0x30(%rsp)
add    %ecx,%eax
cltq
mov    %rax,0x20(%rsp)
mov    0x2d9c(%rip),%r12
xor    %ebp,%ebp
mov    %r15d,0x14(%rsp)
mov    %ebp,0xc(%rsp)
mov    %r13d,%ebp
xor    %r15d,%r15d
nopl   (%rax)
mov    %rbx,%rdi
call   1070 <fgetc@plt>
cmp    (%r12),%al
je     1366 <checkPlayerStatus+0x1f6>
cmp    $0xa,%al
je     128c <checkPlayerStatus+0x11c>
mov    %al,0x40(%rsp,%r15,1)
lea    (%rsp,%r15,1),%rax
add    $0x41,%rax
add    $0x1,%r15
cmp    %r14,%rax
jb     1260 <checkPlayerStatus+0xf0>
lea    (%rsp,%r15,1),%rax
add    $0x40,%rax
movb   $0x0,(%rax)
cmp    %ebp,%r15d
jle    12f0 <checkPlayerStatus+0x180>
mov    %ebp,%edx
lea    0x40(%rsp),%rdi
lea    0xd75(%rip),%rsi
call   1030 <strncmp@plt>
test   %rax,%rax
jne    12f0 <checkPlayerStatus+0x180>
mov    0x38(%rsp),%rdi
mov    0x18(%rsp),%rsi
mov    0x10(%rsp),%edx
call   1030 <strncmp@plt>
test   %rax,%rax
jne    12f0 <checkPlayerStatus+0x180>
mov    0x28(%rsp),%rax
cmpb   $0x20,0x40(%rsp,%rax,1)
mov    0xc(%rsp),%eax
mov    $0x0,%ecx
cmove  %ecx,%eax
mov    %eax,0xc(%rsp)
cs nopw 0x0(%rax,%rax,1)
mov    0x14(%rsp),%r13d
cmp    %r13d,%r15d
jle    1316 <checkPlayerStatus+0x1a6>
mov    %r13d,%r15d
lea    0x40(%rsp),%rdi
lea    0xd47(%rip),%rsi
mov    %r13d,%edx
call   1030 <strncmp@plt>
test   %rax,%rax
je     1333 <checkPlayerStatus+0x1c3>
mov    %ebp,%r13d
mov    0xc(%rsp),%ebp
mov    %rbx,%rdi
call   1080 <feof@plt>
test   %rax,%rax
je     1253 <checkPlayerStatus+0xe3>
jmp    11ea <checkPlayerStatus+0x7a>
mov    0x30(%rsp),%rdi
mov    0x18(%rsp),%rsi
mov    0x10(%rsp),%edx
call   1030 <strncmp@plt>
test   %rax,%rax
mov    %ebp,%r13d
mov    0xc(%rsp),%ebp
jne    131d <checkPlayerStatus+0x1ad>
mov    0x20(%rsp),%rax
cmpb   $0x3b,0x40(%rsp,%rax,1)
mov    $0x1,%eax
cmove  %eax,%ebp
jmp    131d <checkPlayerStatus+0x1ad>
mov    %rbx,%rdi
call   1040 <fclose@plt>
lea    0xcf4(%rip),%rdi
mov    0xc(%rsp),%esi
xor    %eax,%eax
call   1060 <printf@plt>
add    $0x2848,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [3 x i8] c"rb\00"
@.str.1 = [28 x i8] c"Warning, could not open %s\0A\00"
@.str.2 = [49 x i8] c"[SERVER] UNREGISTERING CLIENT RegisteredClient: \00"
@.str.3 = [25 x i8] c"Revived PlayerState PlS[\00"
@EOF = global i8 0
@.str.4 = [4 x i8] c"%d\0A\00"
define void @checkPlayerStatus(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
%5 = alloca [10240 x i8]
%6 = alloca i32*
%7 = alloca i32
%8 = alloca i32
%9 = alloca i8*
%10 = alloca i8*
%11 = alloca i32
%12 = alloca i32
%13 = alloca i32
%14 = alloca i8
%15 = alloca i8*
%16 = alloca i32
store i8* %0, i8** %3
store i8* %1, i8** %4
%17 = load i8*, i8** %3
%18 = call i32* @fopen(i8* %17, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0))
store i32* %18, i32** %6
%19 = load i32*, i32** %6
%20 = icmp ne i32* %19, null
br i1 %20, label %24, label %21
21: ; preds = %2
%22 = load i8*, i8** %3
%23 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.1, i64 0, i64 0), i8* %22)
br label %24
24: ; preds = %21, %2
store i32 0, i32* %7
store i32 0, i32* %8
store i8* getelementptr inbounds ([49 x i8], [49 x i8]* @.str.2, i64 0, i64 0), i8** %9
store i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.3, i64 0, i64 0), i8** %10
%25 = load i8*, i8** %9
%26 = call i32 @strlen(i8* %25)
store i32 %26, i32* %11
%27 = load i8*, i8** %10
%28 = call i32 @strlen(i8* %27)
store i32 %28, i32* %12
%29 = load i8*, i8** %4
%30 = call i32 @strlen(i8* %29)
store i32 %30, i32* %13
br label %31
31: ; preds = %129, %24
%32 = load i32*, i32** %6
%33 = call i64 @feof(i32* %32)
%34 = icmp eq i64 %33, 0
br i1 %34, label %35, label %130
35: ; preds = %31
store i32 0, i32* %16
%36 = getelementptr inbounds [10240 x i8], [10240 x i8]* %5, i64 0, i64 0
store i8* %36, i8** %15
br label %37
37: ; preds = %64, %35
%38 = load i8*, i8** %15
%39 = getelementptr inbounds [10240 x i8], [10240 x i8]* %5, i64 0, i64 10000
%40 = icmp ult i8* %38, %39
br i1 %40, label %41, label %67
41: ; preds = %37
%42 = load i32*, i32** %6
%43 = call signext i8 @fgetc(i32* %42)
store i8 %43, i8* %14
%44 = load i8, i8* %14
%45 = sext i8 %44 to i32
%46 = load i8, i8* @EOF
%47 = sext i8 %46 to i32
%48 = icmp eq i32 %45, %47
br i1 %48, label %49, label %54
49: ; preds = %41
%50 = load i32*, i32** %6
%51 = call i32 @fclose(i32* %50)
%52 = load i32, i32* %8
%53 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 %52)
br label %135
54: ; preds = %41
%55 = load i8, i8* %14
%56 = sext i8 %55 to i32
%57 = icmp eq i32 %56, 10
br i1 %57, label %58, label %59
58: ; preds = %54
br label %67
59: ; preds = %54
%60 = load i8, i8* %14
%61 = load i8*, i8** %15
%62 = getelementptr inbounds i8, i8* %61, i32 1
store i8* %62, i8** %15
store i8 %60, i8* %61
br label %63
63: ; preds = %59
br label %64
64: ; preds = %63
%65 = load i32, i32* %16
%66 = add nsw i32 %65, 1
store i32 %66, i32* %16
br label %37
67: ; preds = %58, %37
%68 = load i8*, i8** %15
%69 = getelementptr inbounds i8, i8* %68, i32 1
store i8* %69, i8** %15
store i8 0, i8* %68
%70 = load i32, i32* %16
%71 = load i32, i32* %11
%72 = icmp sgt i32 %70, %71
br i1 %72, label %73, label %99
73: ; preds = %67
%74 = getelementptr inbounds [10240 x i8], [10240 x i8]* %5, i64 0, i64 0
%75 = load i8*, i8** %9
%76 = load i32, i32* %11
%77 = call i64 @strncmp(i8* %74, i8* %75, i32 %76)
%78 = icmp eq i64 %77, 0
br i1 %78, label %79, label %99
79: ; preds = %73
%80 = getelementptr inbounds [10240 x i8], [10240 x i8]* %5, i64 0, i64 0
%81 = load i32, i32* %11
%82 = sext i32 %81 to i64
%83 = getelementptr inbounds i8, i8* %80, i64 %82
%84 = load i8*, i8** %4
%85 = load i32, i32* %13
%86 = call i64 @strncmp(i8* %83, i8* %84, i32 %85)
%87 = icmp eq i64 %86, 0
br i1 %87, label %88, label %98
88: ; preds = %79
%89 = load i32, i32* %11
%90 = load i32, i32* %13
%91 = add nsw i32 %89, %90
%92 = sext i32 %91 to i64
%93 = getelementptr inbounds [10240 x i8], [10240 x i8]* %5, i64 0, i64 %92
%94 = load i8, i8* %93
%95 = sext i8 %94 to i32
%96 = icmp eq i32 %95, 32
br i1 %96, label %97, label %98
97: ; preds = %88
store i32 0, i32* %8
br label %98
98: ; preds = %97, %88, %79
br label %99
99: ; preds = %98, %73, %67
%100 = load i32, i32* %16
%101 = load i32, i32* %12
%102 = icmp sgt i32 %100, %101
br i1 %102, label %103, label %129
103: ; preds = %99
%104 = getelementptr inbounds [10240 x i8], [10240 x i8]* %5, i64 0, i64 0
%105 = load i8*, i8** %10
%106 = load i32, i32* %12
%107 = call i64 @strncmp(i8* %104, i8* %105, i32 %106)
%108 = icmp eq i64 %107, 0
br i1 %108, label %109, label %129
109: ; preds = %103
%110 = getelementptr inbounds [10240 x i8], [10240 x i8]* %5, i64 0, i64 0
%111 = load i32, i32* %12
%112 = sext i32 %111 to i64
%113 = getelementptr inbounds i8, i8* %110, i64 %112
%114 = load i8*, i8** %4
%115 = load i32, i32* %13
%116 = call i64 @strncmp(i8* %113, i8* %114, i32 %115)
%117 = icmp eq i64 %116, 0
br i1 %117, label %118, label %128
118: ; preds = %109
%119 = load i32, i32* %12
%120 = load i32, i32* %13
%121 = add nsw i32 %119, %120
%122 = sext i32 %121 to i64
%123 = getelementptr inbounds [10240 x i8], [10240 x i8]* %5, i64 0, i64 %122
%124 = load i8, i8* %123
%125 = sext i8 %124 to i32
%126 = icmp eq i32 %125, 59
br i1 %126, label %127, label %128
127: ; preds = %118
store i32 1, i32* %8
br label %128
128: ; preds = %127, %118, %109
br label %129
129: ; preds = %128, %103, %99
br label %31
130: ; preds = %31
%131 = load i32, i32* %8
%132 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 %131)
%133 = load i32*, i32** %6
%134 = call i32 @fclose(i32* %133)
br label %135
135: ; preds = %130, %49
ret void
}

LLVM IR (-O2):
@.str = [3 x i8] c"rb\00"
@.str.1 = [28 x i8] c"Warning, could not open %s\0A\00"
@.str.2 = [49 x i8] c"[SERVER] UNREGISTERING CLIENT RegisteredClient: \00"
@.str.3 = [25 x i8] c"Revived PlayerState PlS[\00"
@EOF = global i8 0
@.str.4 = [4 x i8] c"%d\0A\00"
define void @checkPlayerStatus(i8* %0, i8* %1) {
%3 = alloca [10240 x i8]
%4 = getelementptr inbounds [10240 x i8], [10240 x i8]* %3, i64 0, i64 0
%5 = tail call i32* @fopen(i8* %0, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0))
%6 = icmp eq i32* %5, null
br i1 %6, label %7, label %9
7: ; preds = %2
%8 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([28 x i8], [28 x i8]* @.str.1, i64 0, i64 0), i8* %0)
br label %9
9: ; preds = %7, %2
%10 = tail call i32 @strlen(i8* getelementptr inbounds ([49 x i8], [49 x i8]* @.str.2, i64 0, i64 0))
%11 = tail call i32 @strlen(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.3, i64 0, i64 0))
%12 = tail call i32 @strlen(i8* %1)
%13 = call i64 @feof(i32* %5)
%14 = icmp eq i64 %13, 0
br i1 %14, label %15, label %75
15: ; preds = %9
%16 = getelementptr inbounds [10240 x i8], [10240 x i8]* %3, i64 0, i64 10000
%17 = sext i32 %10 to i64
%18 = getelementptr inbounds [10240 x i8], [10240 x i8]* %3, i64 0, i64 %17
%19 = add nsw i32 %12, %10
%20 = sext i32 %19 to i64
%21 = getelementptr inbounds [10240 x i8], [10240 x i8]* %3, i64 0, i64 %20
%22 = sext i32 %11 to i64
%23 = getelementptr inbounds [10240 x i8], [10240 x i8]* %3, i64 0, i64 %22
%24 = add nsw i32 %12, %11
%25 = sext i32 %24 to i64
%26 = getelementptr inbounds [10240 x i8], [10240 x i8]* %3, i64 0, i64 %25
br label %27
27: ; preds = %15, %71
%28 = phi i32 [ 0, %15 ], [ %72, %71 ]
br label %29
29: ; preds = %27, %40
%30 = phi i32 [ 0, %27 ], [ %42, %40 ]
%31 = phi i8* [ %4, %27 ], [ %41, %40 ]
%32 = call signext i8 @fgetc(i32* %5)
%33 = load i8, i8* @EOF
%34 = icmp eq i8 %32, %33
br i1 %34, label %35, label %38
35: ; preds = %29
%36 = call i32 @fclose(i32* %5)
%37 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 %28)
br label %79
38: ; preds = %29
%39 = icmp eq i8 %32, 10
br i1 %39, label %44, label %40
40: ; preds = %38
%41 = getelementptr inbounds i8, i8* %31, i64 1
store i8 %32, i8* %31
%42 = add nuw nsw i32 %30, 1
%43 = icmp ult i8* %41, %16
br i1 %43, label %29, label %44
44: ; preds = %38, %40
%45 = phi i8* [ %31, %38 ], [ %41, %40 ]
%46 = phi i32 [ %30, %38 ], [ %42, %40 ]
store i8 0, i8* %45
%47 = icmp sgt i32 %46, %10
br i1 %47, label %48, label %58
48: ; preds = %44
%49 = call i64 @strncmp(i8* %4, i8* getelementptr inbounds ([49 x i8], [49 x i8]* @.str.2, i64 0, i64 0), i32 %10)
%50 = icmp eq i64 %49, 0
br i1 %50, label %51, label %58
51: ; preds = %48
%52 = call i64 @strncmp(i8* %18, i8* %1, i32 %12)
%53 = icmp eq i64 %52, 0
br i1 %53, label %54, label %58
54: ; preds = %51
%55 = load i8, i8* %21
%56 = icmp eq i8 %55, 32
%57 = select i1 %56, i32 0, i32 %28
br label %58
58: ; preds = %54, %51, %48, %44
%59 = phi i32 [ %28, %51 ], [ %28, %48 ], [ %28, %44 ], [ %57, %54 ]
%60 = icmp sgt i32 %46, %11
br i1 %60, label %61, label %71
61: ; preds = %58
%62 = call i64 @strncmp(i8* %4, i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.3, i64 0, i64 0), i32 %11)
%63 = icmp eq i64 %62, 0
br i1 %63, label %64, label %71
64: ; preds = %61
%65 = call i64 @strncmp(i8* %23, i8* %1, i32 %12)
%66 = icmp eq i64 %65, 0
br i1 %66, label %67, label %71
67: ; preds = %64
%68 = load i8, i8* %26
%69 = icmp eq i8 %68, 59
%70 = select i1 %69, i32 1, i32 %59
br label %71
71: ; preds = %67, %58, %61, %64
%72 = phi i32 [ %59, %64 ], [ %59, %61 ], [ %59, %58 ], [ %70, %67 ]
%73 = call i64 @feof(i32* %5)
%74 = icmp eq i64 %73, 0
br i1 %74, label %27, label %75
75: ; preds = %71, %9
%76 = phi i32 [ 0, %9 ], [ %72, %71 ]
%77 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 %76)
%78 = call i32 @fclose(i32* %5)
br label %79
79: ; preds = %35, %75
ret void
}