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

/* Variables and functions */
int /*<<< orphan*/ SEEK_SET;
unsigned char fgetc(int /*<<< orphan*/ *);
int /*<<< orphan*/ fread(unsigned char *, int, int, int /*<<< orphan*/ *);
int /*<<< orphan*/ fseek(int /*<<< orphan*/ *, int, int /*<<< orphan*/);
scalar_t__ is_cz88(char *);
int /*<<< orphan*/ readOrJumpRead(char *, int /*<<< orphan*/ *, int);
int search_index(int const, int /*<<< orphan*/ *);
size_t strlen(char *);
int qqwry_get_location_by_long(char *addr1, char *addr2, const uint32_t ip,
                               FILE *qqwry_file) {
  unsigned char data_index_bytes[3];
  uint32_t data_index;
  uint32_t addr2_offset;
  unsigned char c;
  if (!qqwry_file) {
    return 0;
  }
  fseek(qqwry_file, 0, SEEK_SET);
  data_index = search_index(ip, qqwry_file);
  fseek(qqwry_file, data_index + 4, SEEK_SET);
  c = fgetc(qqwry_file);
  if (c == 0x01) {
    fread(data_index_bytes, 3, 1, qqwry_file);
    data_index = ((((uint8_t *)(&data_index_bytes[0]))[2] << 16) |
                  (((uint8_t *)(&data_index_bytes[0]))[1] << 8) |
                  ((uint8_t *)(&data_index_bytes[0]))[0]);
    fseek(qqwry_file, data_index, SEEK_SET);
    c = fgetc(qqwry_file);
    data_index -= 4;
  }
  if (c == 0x02) {
    addr2_offset = data_index + 8;
    fread(data_index_bytes, 3, 1, qqwry_file);
    data_index = ((((uint8_t *)(&data_index_bytes[0]))[2] << 16) |
                  (((uint8_t *)(&data_index_bytes[0]))[1] << 8) |
                  ((uint8_t *)(&data_index_bytes[0]))[0]);
    fseek(qqwry_file, data_index, SEEK_SET);
    while ((c = fgetc(qqwry_file))) {
      addr1[strlen(addr1)] = c;
    }
    readOrJumpRead(addr2, qqwry_file, addr2_offset);
  } else {
    addr1[strlen(addr1)] = c;
    while ((c = fgetc(qqwry_file))) {
      addr1[strlen(addr1)] = c;
    }
    readOrJumpRead(addr2, qqwry_file, 0);
  }
  if (is_cz88(addr1)) {
    addr1[0] = '\0';
  }
  if (is_cz88(addr2)) {
    addr2[0] = '\0';
  }
  return 1;
}


x86 assembly (clang, -O0):
<qqwry_get_location_by_long>:
push   %rbp
mov    %rsp,%rbp
sub    $0x70,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    %edx,-0x1c(%rbp)
mov    %rcx,-0x28(%rbp)
cmpq   $0x0,-0x28(%rbp)
jne    119e <qqwry_get_location_by_long+0x2e>
movl   $0x0,-0x4(%rbp)
jmp    139a <qqwry_get_location_by_long+0x22a>
mov    -0x28(%rbp),%rdi
mov    0x2e37(%rip),%rax
mov    (%rax),%edx
xor    %esi,%esi
call   1080 <fseek@plt>
mov    -0x1c(%rbp),%edi
mov    -0x28(%rbp),%rsi
call   1030 <search_index@plt>
mov    %eax,-0x30(%rbp)
mov    -0x28(%rbp),%rdi
mov    -0x30(%rbp),%esi
add    $0x4,%esi
mov    0x2e0e(%rip),%rax
mov    (%rax),%edx
call   1080 <fseek@plt>
mov    -0x28(%rbp),%rdi
call   1070 <fgetc@plt>
mov    %al,-0x35(%rbp)
movzbl -0x35(%rbp),%eax
cmp    $0x1,%eax
jne    1247 <qqwry_get_location_by_long+0xd7>
lea    -0x2b(%rbp),%rdi
mov    -0x28(%rbp),%rcx
mov    $0x3,%esi
mov    $0x1,%edx
call   1040 <fread@plt>
mov    -0x23(%rbp),%eax
shl    $0x10,%eax
mov    -0x27(%rbp),%ecx
shl    $0x8,%ecx
or     %ecx,%eax
or     -0x2b(%rbp),%eax
mov    %eax,-0x30(%rbp)
mov    -0x28(%rbp),%rdi
mov    -0x30(%rbp),%esi
mov    0x2db5(%rip),%rax
mov    (%rax),%edx
call   1080 <fseek@plt>
mov    -0x28(%rbp),%rdi
call   1070 <fgetc@plt>
mov    %al,-0x35(%rbp)
mov    -0x30(%rbp),%eax
sub    $0x4,%eax
mov    %eax,-0x30(%rbp)
movzbl -0x35(%rbp),%eax
cmp    $0x2,%eax
jne    12ef <qqwry_get_location_by_long+0x17f>
mov    -0x30(%rbp),%eax
add    $0x8,%eax
mov    %eax,-0x34(%rbp)
lea    -0x2b(%rbp),%rdi
mov    -0x28(%rbp),%rcx
mov    $0x3,%esi
mov    $0x1,%edx
call   1040 <fread@plt>
mov    -0x23(%rbp),%eax
shl    $0x10,%eax
mov    -0x27(%rbp),%ecx
shl    $0x8,%ecx
or     %ecx,%eax
or     -0x2b(%rbp),%eax
mov    %eax,-0x30(%rbp)
mov    -0x28(%rbp),%rdi
mov    -0x30(%rbp),%esi
mov    0x2d4a(%rip),%rax
mov    (%rax),%edx
call   1080 <fseek@plt>
mov    -0x28(%rbp),%rdi
call   1070 <fgetc@plt>
mov    %al,-0x35(%rbp)
cmp    $0x0,%al
je     12da <qqwry_get_location_by_long+0x16a>
mov    -0x35(%rbp),%al
mov    %al,-0x41(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,-0x40(%rbp)
mov    -0x10(%rbp),%rdi
call   1060 <strlen@plt>
mov    -0x41(%rbp),%dl
mov    %rax,%rcx
mov    -0x40(%rbp),%rax
mov    %dl,(%rax,%rcx,1)
jmp    129d <qqwry_get_location_by_long+0x12d>
mov    -0x18(%rbp),%rdi
mov    -0x28(%rbp),%rsi
mov    -0x34(%rbp),%edx
call   1090 <readOrJumpRead@plt>
jmp    135f <qqwry_get_location_by_long+0x1ef>
mov    -0x35(%rbp),%al
mov    %al,-0x51(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,-0x50(%rbp)
mov    -0x10(%rbp),%rdi
call   1060 <strlen@plt>
mov    -0x51(%rbp),%dl
mov    %rax,%rcx
mov    -0x50(%rbp),%rax
mov    %dl,(%rax,%rcx,1)
mov    -0x28(%rbp),%rdi
call   1070 <fgetc@plt>
mov    %al,-0x35(%rbp)
cmp    $0x0,%al
je     1350 <qqwry_get_location_by_long+0x1e0>
mov    -0x35(%rbp),%al
mov    %al,-0x61(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,-0x60(%rbp)
mov    -0x10(%rbp),%rdi
call   1060 <strlen@plt>
mov    -0x61(%rbp),%dl
mov    %rax,%rcx
mov    -0x60(%rbp),%rax
mov    %dl,(%rax,%rcx,1)
jmp    1313 <qqwry_get_location_by_long+0x1a3>
mov    -0x18(%rbp),%rdi
mov    -0x28(%rbp),%rsi
xor    %edx,%edx
call   1090 <readOrJumpRead@plt>
mov    -0x10(%rbp),%rdi
call   1050 <is_cz88@plt>
cmp    $0x0,%rax
je     1379 <qqwry_get_location_by_long+0x209>
mov    -0x10(%rbp),%rax
movb   $0x0,(%rax)
mov    -0x18(%rbp),%rdi
call   1050 <is_cz88@plt>
cmp    $0x0,%rax
je     1393 <qqwry_get_location_by_long+0x223>
mov    -0x18(%rbp),%rax
movb   $0x0,(%rax)
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x70,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<qqwry_get_location_by_long>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
test   %rcx,%rcx
je     126c <qqwry_get_location_by_long+0xfc>
mov    %rcx,%r15
mov    %edx,%ebx
mov    %rsi,%r14
mov    %rdi,%rbp
mov    0x2e4a(%rip),%r13
mov    0x0(%r13),%edx
mov    %rcx,%rdi
xor    %esi,%esi
call   1080 <fseek@plt>
mov    %ebx,%edi
mov    %r15,%rsi
call   1030 <search_index@plt>
mov    %eax,%r12d
lea    0x4(%r12),%esi
mov    0x0(%r13),%edx
mov    %r15,%rdi
call   1080 <fseek@plt>
mov    %r15,%rdi
call   1070 <fgetc@plt>
cmp    $0x1,%al
jne    1273 <qqwry_get_location_by_long+0x103>
lea    0x4(%rsp),%rdi
mov    $0x3,%esi
mov    $0x1,%edx
mov    %r15,%rcx
call   1040 <fread@plt>
mov    0x8(%rsp),%r12d
mov    0xc(%rsp),%eax
shl    $0x10,%eax
shl    $0x8,%r12d
or     %eax,%r12d
or     0x4(%rsp),%r12d
mov    0x0(%r13),%edx
mov    %r15,%rdi
mov    %r12d,%esi
call   1080 <fseek@plt>
mov    %r15,%rdi
call   1070 <fgetc@plt>
mov    %eax,%ebx
add    $0xfffffffc,%r12d
cmp    $0x2,%bl
je     127a <qqwry_get_location_by_long+0x10a>
mov    %rbp,%rdi
call   1060 <strlen@plt>
mov    %bl,0x0(%rbp,%rax,1)
mov    %r15,%rdi
call   1070 <fgetc@plt>
xor    %r12d,%r12d
test   %al,%al
je     12ea <qqwry_get_location_by_long+0x17a>
mov    %eax,%ebx
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
mov    %rbp,%rdi
call   1060 <strlen@plt>
mov    %bl,0x0(%rbp,%rax,1)
mov    %r15,%rdi
call   1070 <fgetc@plt>
mov    %eax,%ebx
test   %al,%al
jne    1250 <qqwry_get_location_by_long+0xe0>
jmp    12ea <qqwry_get_location_by_long+0x17a>
xor    %eax,%eax
jmp    1322 <qqwry_get_location_by_long+0x1b2>
mov    %eax,%ebx
cmp    $0x2,%bl
jne    1223 <qqwry_get_location_by_long+0xb3>
add    $0x8,%r12d
lea    0x4(%rsp),%rdi
mov    $0x3,%esi
mov    $0x1,%edx
mov    %r15,%rcx
call   1040 <fread@plt>
mov    0x8(%rsp),%esi
mov    0xc(%rsp),%eax
shl    $0x10,%eax
shl    $0x8,%esi
or     %eax,%esi
or     0x4(%rsp),%esi
mov    0x0(%r13),%edx
mov    %r15,%rdi
call   1080 <fseek@plt>
mov    %r15,%rdi
call   1070 <fgetc@plt>
test   %al,%al
je     12ea <qqwry_get_location_by_long+0x17a>
mov    %eax,%ebx
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
mov    %rbp,%rdi
call   1060 <strlen@plt>
mov    %bl,0x0(%rbp,%rax,1)
mov    %r15,%rdi
call   1070 <fgetc@plt>
mov    %eax,%ebx
test   %al,%al
jne    12d0 <qqwry_get_location_by_long+0x160>
mov    %r14,%rdi
mov    %r15,%rsi
mov    %r12d,%edx
call   1090 <readOrJumpRead@plt>
mov    %rbp,%rdi
call   1050 <is_cz88@plt>
test   %rax,%rax
je     1309 <qqwry_get_location_by_long+0x199>
movb   $0x0,0x0(%rbp)
mov    %r14,%rdi
call   1050 <is_cz88@plt>
mov    %rax,%rcx
mov    $0x1,%eax
test   %rcx,%rcx
je     1322 <qqwry_get_location_by_long+0x1b2>
movb   $0x0,(%r14)
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@SEEK_SET = global i32 0
define i32 @qqwry_get_location_by_long(i8* %0, i8* %1, i32 %2, i32* %3) {
%5 = alloca i32
%6 = alloca i8*
%7 = alloca i8*
%8 = alloca i32
%9 = alloca i32*
%10 = alloca [3 x i8]
%11 = alloca i32
%12 = alloca i32
%13 = alloca i8
store i8* %0, i8** %6
store i8* %1, i8** %7
store i32 %2, i32* %8
store i32* %3, i32** %9
%14 = load i32*, i32** %9
%15 = icmp ne i32* %14, null
br i1 %15, label %17, label %16
16: ; preds = %4
store i32 0, i32* %5
br label %142
17: ; preds = %4
%18 = load i32*, i32** %9
%19 = load i32, i32* @SEEK_SET
%20 = call i32 @fseek(i32* %18, i32 0, i32 %19)
%21 = load i32, i32* %8
%22 = load i32*, i32** %9
%23 = call i32 @search_index(i32 %21, i32* %22)
store i32 %23, i32* %11
%24 = load i32*, i32** %9
%25 = load i32, i32* %11
%26 = add nsw i32 %25, 4
%27 = load i32, i32* @SEEK_SET
%28 = call i32 @fseek(i32* %24, i32 %26, i32 %27)
%29 = load i32*, i32** %9
%30 = call zeroext i8 @fgetc(i32* %29)
store i8 %30, i8* %13
%31 = load i8, i8* %13
%32 = zext i8 %31 to i32
%33 = icmp eq i32 %32, 1
br i1 %33, label %34, label %62
34: ; preds = %17
%35 = getelementptr inbounds [3 x i8], [3 x i8]* %10, i64 0, i64 0
%36 = load i32*, i32** %9
%37 = call i32 @fread(i8* %35, i32 3, i32 1, i32* %36)
%38 = getelementptr inbounds [3 x i8], [3 x i8]* %10, i64 0, i64 0
%39 = bitcast i8* %38 to i32*
%40 = getelementptr inbounds i32, i32* %39, i64 2
%41 = load i32, i32* %40
%42 = shl i32 %41, 16
%43 = getelementptr inbounds [3 x i8], [3 x i8]* %10, i64 0, i64 0
%44 = bitcast i8* %43 to i32*
%45 = getelementptr inbounds i32, i32* %44, i64 1
%46 = load i32, i32* %45
%47 = shl i32 %46, 8
%48 = or i32 %42, %47
%49 = getelementptr inbounds [3 x i8], [3 x i8]* %10, i64 0, i64 0
%50 = bitcast i8* %49 to i32*
%51 = getelementptr inbounds i32, i32* %50, i64 0
%52 = load i32, i32* %51
%53 = or i32 %48, %52
store i32 %53, i32* %11
%54 = load i32*, i32** %9
%55 = load i32, i32* %11
%56 = load i32, i32* @SEEK_SET
%57 = call i32 @fseek(i32* %54, i32 %55, i32 %56)
%58 = load i32*, i32** %9
%59 = call zeroext i8 @fgetc(i32* %58)
store i8 %59, i8* %13
%60 = load i32, i32* %11
%61 = sub nsw i32 %60, 4
store i32 %61, i32* %11
br label %62
62: ; preds = %34, %17
%63 = load i8, i8* %13
%64 = zext i8 %63 to i32
%65 = icmp eq i32 %64, 2
br i1 %65, label %66, label %107
66: ; preds = %62
%67 = load i32, i32* %11
%68 = add nsw i32 %67, 8
store i32 %68, i32* %12
%69 = getelementptr inbounds [3 x i8], [3 x i8]* %10, i64 0, i64 0
%70 = load i32*, i32** %9
%71 = call i32 @fread(i8* %69, i32 3, i32 1, i32* %70)
%72 = getelementptr inbounds [3 x i8], [3 x i8]* %10, i64 0, i64 0
%73 = bitcast i8* %72 to i32*
%74 = getelementptr inbounds i32, i32* %73, i64 2
%75 = load i32, i32* %74
%76 = shl i32 %75, 16
%77 = getelementptr inbounds [3 x i8], [3 x i8]* %10, i64 0, i64 0
%78 = bitcast i8* %77 to i32*
%79 = getelementptr inbounds i32, i32* %78, i64 1
%80 = load i32, i32* %79
%81 = shl i32 %80, 8
%82 = or i32 %76, %81
%83 = getelementptr inbounds [3 x i8], [3 x i8]* %10, i64 0, i64 0
%84 = bitcast i8* %83 to i32*
%85 = getelementptr inbounds i32, i32* %84, i64 0
%86 = load i32, i32* %85
%87 = or i32 %82, %86
store i32 %87, i32* %11
%88 = load i32*, i32** %9
%89 = load i32, i32* %11
%90 = load i32, i32* @SEEK_SET
%91 = call i32 @fseek(i32* %88, i32 %89, i32 %90)
br label %92
92: ; preds = %96, %66
%93 = load i32*, i32** %9
%94 = call zeroext i8 @fgetc(i32* %93)
store i8 %94, i8* %13
%95 = icmp ne i8 %94, 0
br i1 %95, label %96, label %102
96: ; preds = %92
%97 = load i8, i8* %13
%98 = load i8*, i8** %6
%99 = load i8*, i8** %6
%100 = call i64 @strlen(i8* %99)
%101 = getelementptr inbounds i8, i8* %98, i64 %100
store i8 %97, i8* %101
br label %92
102: ; preds = %92
%103 = load i8*, i8** %7
%104 = load i32*, i32** %9
%105 = load i32, i32* %12
%106 = call i32 @readOrJumpRead(i8* %103, i32* %104, i32 %105)
br label %127
107: ; preds = %62
%108 = load i8, i8* %13
%109 = load i8*, i8** %6
%110 = load i8*, i8** %6
%111 = call i64 @strlen(i8* %110)
%112 = getelementptr inbounds i8, i8* %109, i64 %111
store i8 %108, i8* %112
br label %113
113: ; preds = %117, %107
%114 = load i32*, i32** %9
%115 = call zeroext i8 @fgetc(i32* %114)
store i8 %115, i8* %13
%116 = icmp ne i8 %115, 0
br i1 %116, label %117, label %123
117: ; preds = %113
%118 = load i8, i8* %13
%119 = load i8*, i8** %6
%120 = load i8*, i8** %6
%121 = call i64 @strlen(i8* %120)
%122 = getelementptr inbounds i8, i8* %119, i64 %121
store i8 %118, i8* %122
br label %113
123: ; preds = %113
%124 = load i8*, i8** %7
%125 = load i32*, i32** %9
%126 = call i32 @readOrJumpRead(i8* %124, i32* %125, i32 0)
br label %127
127: ; preds = %123, %102
%128 = load i8*, i8** %6
%129 = call i64 @is_cz88(i8* %128)
%130 = icmp ne i64 %129, 0
br i1 %130, label %131, label %134
131: ; preds = %127
%132 = load i8*, i8** %6
%133 = getelementptr inbounds i8, i8* %132, i64 0
store i8 0, i8* %133
br label %134
134: ; preds = %131, %127
%135 = load i8*, i8** %7
%136 = call i64 @is_cz88(i8* %135)
%137 = icmp ne i64 %136, 0
br i1 %137, label %138, label %141
138: ; preds = %134
%139 = load i8*, i8** %7
%140 = getelementptr inbounds i8, i8* %139, i64 0
store i8 0, i8* %140
br label %141
141: ; preds = %138, %134
store i32 1, i32* %5
br label %142
142: ; preds = %141, %16
%143 = load i32, i32* %5
ret i32 %143
}

LLVM IR (-O2):
@SEEK_SET = global i32 0
define i32 @qqwry_get_location_by_long(i8* %0, i8* %1, i32 %2, i32* %3) {
%5 = alloca [3 x i8]
%6 = getelementptr inbounds [3 x i8], [3 x i8]* %5, i64 0, i64 0
%7 = icmp eq i32* %3, null
br i1 %7, label %85, label %8
8: ; preds = %4
%9 = load i32, i32* @SEEK_SET
%10 = tail call i32 @fseek(i32* %3, i32 0, i32 %9)
%11 = tail call i32 @search_index(i32 %2, i32* %3)
%12 = add nsw i32 %11, 4
%13 = load i32, i32* @SEEK_SET
%14 = tail call i32 @fseek(i32* %3, i32 %12, i32 %13)
%15 = tail call zeroext i8 @fgetc(i32* %3)
%16 = icmp eq i8 %15, 1
br i1 %16, label %17, label %35
17: ; preds = %8
%18 = call i32 @fread(i8* %6, i32 3, i32 1, i32* %3)
%19 = bitcast [3 x i8]* %5 to i32*
%20 = getelementptr inbounds [3 x i8], [3 x i8]* %5, i64 2, i64 2
%21 = bitcast i8* %20 to i32*
%22 = load i32, i32* %21
%23 = shl i32 %22, 16
%24 = getelementptr inbounds [3 x i8], [3 x i8]* %5, i64 1, i64 1
%25 = bitcast i8* %24 to i32*
%26 = load i32, i32* %25
%27 = shl i32 %26, 8
%28 = or i32 %27, %23
%29 = load i32, i32* %19
%30 = or i32 %28, %29
%31 = load i32, i32* @SEEK_SET
%32 = tail call i32 @fseek(i32* %3, i32 %30, i32 %31)
%33 = tail call zeroext i8 @fgetc(i32* %3)
%34 = add nsw i32 %30, -4
br label %35
35: ; preds = %17, %8
%36 = phi i32 [ %34, %17 ], [ %11, %8 ]
%37 = phi i8 [ %33, %17 ], [ %15, %8 ]
%38 = icmp eq i8 %37, 2
br i1 %38, label %39, label %64
39: ; preds = %35
%40 = add nsw i32 %36, 8
%41 = call i32 @fread(i8* %6, i32 3, i32 1, i32* %3)
%42 = bitcast [3 x i8]* %5 to i32*
%43 = getelementptr inbounds [3 x i8], [3 x i8]* %5, i64 2, i64 2
%44 = bitcast i8* %43 to i32*
%45 = load i32, i32* %44
%46 = shl i32 %45, 16
%47 = getelementptr inbounds [3 x i8], [3 x i8]* %5, i64 1, i64 1
%48 = bitcast i8* %47 to i32*
%49 = load i32, i32* %48
%50 = shl i32 %49, 8
%51 = or i32 %50, %46
%52 = load i32, i32* %42
%53 = or i32 %51, %52
%54 = load i32, i32* @SEEK_SET
%55 = tail call i32 @fseek(i32* %3, i32 %53, i32 %54)
%56 = tail call zeroext i8 @fgetc(i32* %3)
%57 = icmp eq i8 %56, 0
br i1 %57, label %75, label %58
58: ; preds = %39, %58
%59 = phi i8 [ %62, %58 ], [ %56, %39 ]
%60 = tail call i64 @strlen(i8* dereferenceable(1) %0)
%61 = getelementptr inbounds i8, i8* %0, i64 %60
store i8 %59, i8* %61
%62 = tail call zeroext i8 @fgetc(i32* %3)
%63 = icmp eq i8 %62, 0
br i1 %63, label %75, label %58
64: ; preds = %35
%65 = tail call i64 @strlen(i8* dereferenceable(1) %0)
%66 = getelementptr inbounds i8, i8* %0, i64 %65
store i8 %37, i8* %66
%67 = tail call zeroext i8 @fgetc(i32* %3)
%68 = icmp eq i8 %67, 0
br i1 %68, label %75, label %69
69: ; preds = %64, %69
%70 = phi i8 [ %73, %69 ], [ %67, %64 ]
%71 = tail call i64 @strlen(i8* dereferenceable(1) %0)
%72 = getelementptr inbounds i8, i8* %0, i64 %71
store i8 %70, i8* %72
%73 = tail call zeroext i8 @fgetc(i32* %3)
%74 = icmp eq i8 %73, 0
br i1 %74, label %75, label %69
75: ; preds = %69, %58, %64, %39
%76 = phi i32 [ %40, %39 ], [ 0, %64 ], [ %40, %58 ], [ 0, %69 ]
%77 = tail call i32 @readOrJumpRead(i8* %1, i32* %3, i32 %76)
%78 = tail call i64 @is_cz88(i8* %0)
%79 = icmp eq i64 %78, 0
br i1 %79, label %81, label %80
80: ; preds = %75
store i8 0, i8* %0
br label %81
81: ; preds = %80, %75
%82 = tail call i64 @is_cz88(i8* %1)
%83 = icmp eq i64 %82, 0
br i1 %83, label %85, label %84
84: ; preds = %81
store i8 0, i8* %1
br label %85
85: ; preds = %81, %84, %4
%86 = phi i32 [ 0, %4 ], [ 1, %84 ], [ 1, %81 ]
ret i32 %86
}