#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 /*<<< orphan*/ SEEK_SET;
scalar_t__ feof(int /*<<< orphan*/ *);
int fread(char *, int, int, int /*<<< orphan*/ *);
int /*<<< orphan*/ fseek(int /*<<< orphan*/ *, long, int /*<<< orphan*/);
long ftell(int /*<<< orphan*/ *);
int /*<<< orphan*/ sleep(int);
int sscanf(char *, char *, ...);
int E_ReadTypeAndTimeStamp(FILE *input, double *stamp) {
  int type, items;
  long pos;
  char type_str[256] = "";
  int p = 0;
  if (input == NULL)
    return -2;
  if (feof(input))
    return -1;
  pos = ftell(input);
  while (!feof(input) && (fread(&type_str[p], 1, 1, input) == 1) &&
         type_str[p] >= '0' && type_str[p] <= '9') {
    p += 1;
  }
  if (p == 0) {
    fseek(input, pos, SEEK_SET);
    sleep(1);
    return -1;
  }
  type_str[p + 1] = '\n';
  items = sscanf(type_str, "%i", &type);
  if (items != 1) {
    fseek(input, pos, SEEK_SET);
    return -1;
  }
  p = 0;
  while (((!feof(input)) && (fread(&type_str[p], 1, 1, input) == 1) &&
          (type_str[p] >= '0') && (type_str[p] <= '9')) ||
         (type_str[p] == '.')) {
    p += 1;
  }
  if (p == 0) {
    fseek(input, pos, SEEK_SET);
    return -1;
  }
  type_str[p + 1] = '\n';
  items = sscanf(type_str, "%lf", stamp);
  if (items != 1) {
    fseek(input, pos, SEEK_SET);
    return -1;
  }
  fseek(input, pos, SEEK_SET);
  return type;
}


x86 assembly (clang, -O0):
<E_ReadTypeAndTimeStamp>:
push   %rbp
mov    %rsp,%rbp
sub    $0x140,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
lea    -0x130(%rbp),%rdi
xor    %esi,%esi
mov    $0x100,%edx
call   1040 <memset@plt>
movl   $0x0,-0x134(%rbp)
cmpq   $0x0,-0x10(%rbp)
jne    11b7 <E_ReadTypeAndTimeStamp+0x47>
movl   $0xfffffffe,-0x4(%rbp)
jmp    1492 <E_ReadTypeAndTimeStamp+0x322>
mov    -0x10(%rbp),%rdi
call   1060 <feof@plt>
cmp    $0x0,%rax
je     11d6 <E_ReadTypeAndTimeStamp+0x66>
movl   $0xffffffff,-0x4(%rbp)
jmp    1492 <E_ReadTypeAndTimeStamp+0x322>
mov    -0x10(%rbp),%rdi
call   1050 <ftell@plt>
mov    %rax,-0x28(%rbp)
mov    -0x10(%rbp),%rdi
call   1060 <feof@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    $0x0,%rcx
mov    %al,-0x135(%rbp)
jne    1270 <E_ReadTypeAndTimeStamp+0x100>
movslq -0x134(%rbp),%rax
lea    -0x130(%rbp),%rdi
add    %rax,%rdi
mov    -0x10(%rbp),%rcx
mov    $0x1,%edx
mov    %edx,%esi
call   1030 <fread@plt>
mov    %eax,%ecx
xor    %eax,%eax
cmp    $0x1,%ecx
mov    %al,-0x135(%rbp)
jne    1270 <E_ReadTypeAndTimeStamp+0x100>
movslq -0x134(%rbp),%rax
movsbl -0x130(%rbp,%rax,1),%ecx
ff
xor    %eax,%eax
cmp    $0x30,%ecx
mov    %al,-0x135(%rbp)
jl     1270 <E_ReadTypeAndTimeStamp+0x100>
movslq -0x134(%rbp),%rax
movsbl -0x130(%rbp,%rax,1),%eax
ff
cmp    $0x39,%eax
setle  %al
mov    %al,-0x135(%rbp)
mov    -0x135(%rbp),%al
test   $0x1,%al
jne    1283 <E_ReadTypeAndTimeStamp+0x113>
jmp    1297 <E_ReadTypeAndTimeStamp+0x127>
mov    -0x134(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x134(%rbp)
jmp    11e3 <E_ReadTypeAndTimeStamp+0x73>
cmpl   $0x0,-0x134(%rbp)
jne    12d0 <E_ReadTypeAndTimeStamp+0x160>
mov    -0x10(%rbp),%rdi
mov    -0x28(%rbp),%rsi
mov    0x2d2d(%rip),%rax
mov    (%rax),%edx
call   1080 <fseek@plt>
mov    $0x1,%edi
call   1090 <sleep@plt>
movl   $0xffffffff,-0x4(%rbp)
jmp    1492 <E_ReadTypeAndTimeStamp+0x322>
mov    -0x134(%rbp),%eax
add    $0x1,%eax
cltq
movb   $0xa,-0x130(%rbp,%rax,1)
0a
lea    -0x130(%rbp),%rdi
lea    0xd0f(%rip),%rsi
lea    -0x1c(%rbp),%rdx
mov    $0x0,%al
call   1070 <sscanf@plt>
mov    %eax,-0x20(%rbp)
cmpl   $0x1,-0x20(%rbp)
je     132b <E_ReadTypeAndTimeStamp+0x1bb>
mov    -0x10(%rbp),%rdi
mov    -0x28(%rbp),%rsi
mov    0x2cc8(%rip),%rax
mov    (%rax),%edx
call   1080 <fseek@plt>
movl   $0xffffffff,-0x4(%rbp)
jmp    1492 <E_ReadTypeAndTimeStamp+0x322>
movl   $0x0,-0x134(%rbp)
mov    -0x10(%rbp),%rdi
call   1060 <feof@plt>
cmp    $0x0,%rax
jne    13aa <E_ReadTypeAndTimeStamp+0x23a>
movslq -0x134(%rbp),%rax
lea    -0x130(%rbp),%rdi
add    %rax,%rdi
mov    -0x10(%rbp),%rcx
mov    $0x1,%edx
mov    %edx,%esi
call   1030 <fread@plt>
cmp    $0x1,%eax
jne    13aa <E_ReadTypeAndTimeStamp+0x23a>
movslq -0x134(%rbp),%rax
movsbl -0x130(%rbp,%rax,1),%eax
ff
cmp    $0x30,%eax
jl     13aa <E_ReadTypeAndTimeStamp+0x23a>
movslq -0x134(%rbp),%rax
movsbl -0x130(%rbp,%rax,1),%ecx
ff
mov    $0x1,%al
cmp    $0x39,%ecx
mov    %al,-0x136(%rbp)
jle    13c5 <E_ReadTypeAndTimeStamp+0x255>
movslq -0x134(%rbp),%rax
movsbl -0x130(%rbp,%rax,1),%eax
ff
cmp    $0x2e,%eax
sete   %al
mov    %al,-0x136(%rbp)
mov    -0x136(%rbp),%al
test   $0x1,%al
jne    13d8 <E_ReadTypeAndTimeStamp+0x268>
jmp    13ec <E_ReadTypeAndTimeStamp+0x27c>
mov    -0x134(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x134(%rbp)
jmp    1335 <E_ReadTypeAndTimeStamp+0x1c5>
cmpl   $0x0,-0x134(%rbp)
jne    141b <E_ReadTypeAndTimeStamp+0x2ab>
mov    -0x10(%rbp),%rdi
mov    -0x28(%rbp),%rsi
mov    0x2bd8(%rip),%rax
mov    (%rax),%edx
call   1080 <fseek@plt>
movl   $0xffffffff,-0x4(%rbp)
jmp    1492 <E_ReadTypeAndTimeStamp+0x322>
mov    -0x134(%rbp),%eax
add    $0x1,%eax
cltq
movb   $0xa,-0x130(%rbp,%rax,1)
0a
lea    -0x130(%rbp),%rdi
mov    -0x18(%rbp),%rdx
lea    0xbc3(%rip),%rsi
mov    $0x0,%al
call   1070 <sscanf@plt>
mov    %eax,-0x20(%rbp)
cmpl   $0x1,-0x20(%rbp)
je     1476 <E_ReadTypeAndTimeStamp+0x306>
mov    -0x10(%rbp),%rdi
mov    -0x28(%rbp),%rsi
mov    0x2b7d(%rip),%rax
mov    (%rax),%edx
call   1080 <fseek@plt>
movl   $0xffffffff,-0x4(%rbp)
jmp    1492 <E_ReadTypeAndTimeStamp+0x322>
mov    -0x10(%rbp),%rdi
mov    -0x28(%rbp),%rsi
mov    0x2b5b(%rip),%rax
mov    (%rax),%edx
call   1080 <fseek@plt>
mov    -0x1c(%rbp),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x140,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<E_ReadTypeAndTimeStamp>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x118,%rsp
xorps  %xmm0,%xmm0
movaps %xmm0,0x100(%rsp)
movaps %xmm0,0xf0(%rsp)
movaps %xmm0,0xe0(%rsp)
movaps %xmm0,0xd0(%rsp)
movaps %xmm0,0xc0(%rsp)
movaps %xmm0,0xb0(%rsp)
movaps %xmm0,0xa0(%rsp)
movaps %xmm0,0x90(%rsp)
movaps %xmm0,0x80(%rsp)
movaps %xmm0,0x70(%rsp)
movaps %xmm0,0x60(%rsp)
movaps %xmm0,0x50(%rsp)
movaps %xmm0,0x40(%rsp)
movaps %xmm0,0x30(%rsp)
movaps %xmm0,0x20(%rsp)
movaps %xmm0,0x10(%rsp)
test   %rdi,%rdi
je     1232 <E_ReadTypeAndTimeStamp+0xd2>
mov    %rsi,%r14
mov    %rdi,%r15
call   1050 <feof@plt>
mov    $0xffffffff,%r12d
test   %rax,%rax
jne    1238 <E_ReadTypeAndTimeStamp+0xd8>
mov    %r15,%rdi
call   1040 <ftell@plt>
mov    %rax,%r13
mov    %r15,%rdi
call   1050 <feof@plt>
test   %rax,%rax
je     124d <E_ReadTypeAndTimeStamp+0xed>
mov    0x2dc7(%rip),%rax
mov    (%rax),%edx
mov    %r15,%rdi
mov    %r13,%rsi
call   1070 <fseek@plt>
mov    $0x1,%edi
call   1080 <sleep@plt>
jmp    1238 <E_ReadTypeAndTimeStamp+0xd8>
mov    $0xfffffffe,%r12d
mov    %r12d,%eax
add    $0x118,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret
xor    %ebx,%ebx
nop
lea    (%rsp,%rbx,1),%rbp
add    $0x10,%rbp
mov    %rbp,%rdi
mov    $0x1,%esi
mov    $0x1,%edx
mov    %r15,%rcx
call   1030 <fread@plt>
cmp    $0x1,%eax
jne    128d <E_ReadTypeAndTimeStamp+0x12d>
movzbl 0x0(%rbp),%eax
add    $0xd0,%al
cmp    $0x9,%al
ja     128d <E_ReadTypeAndTimeStamp+0x12d>
add    $0x1,%rbx
mov    %r15,%rdi
call   1050 <feof@plt>
test   %rax,%rax
je     1250 <E_ReadTypeAndTimeStamp+0xf0>
test   %ebx,%ebx
je     1212 <E_ReadTypeAndTimeStamp+0xb2>
add    $0x1,%ebx
movb   $0xa,0x10(%rsp,%rbx,1)
lea    0xd60(%rip),%rsi
lea    0x10(%rsp),%rbp
lea    0xc(%rsp),%rdx
mov    %rbp,%rdi
xor    %eax,%eax
call   1060 <sscanf@plt>
cmp    $0x1,%eax
jne    1311 <E_ReadTypeAndTimeStamp+0x1b1>
mov    %r13,%rbx
mov    $0xffffffffffffffff,%r13
jmp    12de <E_ReadTypeAndTimeStamp+0x17e>
cs nopw 0x0(%rax,%rax,1)
nop
cmpb   $0x2e,0x0(%rbp)
jne    132a <E_ReadTypeAndTimeStamp+0x1ca>
add    $0xffffffffffffffff,%r13
add    $0x1,%rbp
mov    %r15,%rdi
call   1050 <feof@plt>
test   %rax,%rax
jne    12d0 <E_ReadTypeAndTimeStamp+0x170>
mov    %rbp,%rdi
mov    $0x1,%esi
mov    $0x1,%edx
mov    %r15,%rcx
call   1030 <fread@plt>
cmp    $0x1,%eax
jne    12d0 <E_ReadTypeAndTimeStamp+0x170>
movzbl 0x0(%rbp),%eax
add    $0xd0,%al
cmp    $0xa,%al
jae    12d0 <E_ReadTypeAndTimeStamp+0x170>
jmp    12d6 <E_ReadTypeAndTimeStamp+0x176>
mov    0x2cc8(%rip),%rax
mov    (%rax),%edx
mov    %r15,%rdi
mov    %r13,%rsi
call   1070 <fseek@plt>
jmp    1238 <E_ReadTypeAndTimeStamp+0xd8>
cmp    $0xffffffff,%r13d
je     137e <E_ReadTypeAndTimeStamp+0x21e>
neg    %r13d
movb   $0xa,0x10(%rsp,%r13,1)
lea    0xcc3(%rip),%rsi
lea    0x10(%rsp),%rdi
mov    %r14,%rdx
xor    %eax,%eax
call   1060 <sscanf@plt>
mov    %eax,%ebp
mov    0x2c88(%rip),%rax
mov    (%rax),%edx
mov    %r15,%rdi
mov    %rbx,%rsi
call   1070 <fseek@plt>
mov    $0xffffffff,%r12d
cmp    $0x1,%ebp
jne    1238 <E_ReadTypeAndTimeStamp+0xd8>
mov    0xc(%rsp),%r12d
jmp    1238 <E_ReadTypeAndTimeStamp+0xd8>
mov    0x2c5b(%rip),%rax
mov    (%rax),%edx
mov    %r15,%rdi
mov    %rbx,%rsi
call   1070 <fseek@plt>
jmp    1238 <E_ReadTypeAndTimeStamp+0xd8>

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

LLVM IR (-O2):
@SEEK_SET = global i32 0
@.str = [3 x i8] c"%i\00"
@.str.1 = [4 x i8] c"%lf\00"
define i32 @E_ReadTypeAndTimeStamp(i32* %0, double* %1) {
%3 = alloca i32
%4 = alloca [256 x i8]
%5 = bitcast i32* %3 to i8*
%6 = getelementptr inbounds [256 x i8], [256 x i8]* %4, i64 0, i64 0
%7 = icmp eq i32* %0, null
br i1 %7, label %79, label %8
8: ; preds = %2
%9 = tail call i64 @feof(i32* %0)
%10 = icmp eq i64 %9, 0
br i1 %10, label %11, label %79
11: ; preds = %8
%12 = tail call i64 @ftell(i32* %0)
%13 = tail call i64 @feof(i32* %0)
%14 = icmp eq i64 %13, 0
br i1 %14, label %15, label %32
15: ; preds = %11, %24
%16 = phi i64 [ %25, %24 ], [ 0, %11 ]
%17 = getelementptr inbounds [256 x i8], [256 x i8]* %4, i64 0, i64 %16
%18 = call i32 @fread(i8* %17, i32 1, i32 1, i32* %0)
%19 = icmp eq i32 %18, 1
br i1 %19, label %20, label %28
20: ; preds = %15
%21 = load i8, i8* %17
%22 = add i8 %21, -48
%23 = icmp ult i8 %22, 10
br i1 %23, label %24, label %28
24: ; preds = %20
%25 = add nuw i64 %16, 1
%26 = tail call i64 @feof(i32* %0)
%27 = icmp eq i64 %26, 0
br i1 %27, label %15, label %28
28: ; preds = %20, %15, %24
%29 = phi i64 [ %16, %20 ], [ %16, %15 ], [ %25, %24 ]
%30 = trunc i64 %29 to i32
%31 = icmp eq i32 %30, 0
br i1 %31, label %32, label %36
32: ; preds = %11, %28
%33 = load i32, i32* @SEEK_SET
%34 = tail call i32 @fseek(i32* %0, i64 %12, i32 %33)
%35 = tail call i32 @sleep(i32 1)
br label %79
36: ; preds = %28
%37 = add i64 %29, 1
%38 = and i64 %37, 4294967295
%39 = getelementptr inbounds [256 x i8], [256 x i8]* %4, i64 0, i64 %38
store i8 10, i8* %39
%40 = call i32 (i8*, i8*, ...) @sscanf(i8* %6, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %3)
%41 = icmp eq i32 %40, 1
br i1 %41, label %45, label %42
42: ; preds = %36
%43 = load i32, i32* @SEEK_SET
%44 = call i32 @fseek(i32* %0, i64 %12, i32 %43)
br label %79
45: ; preds = %36, %61
%46 = phi i64 [ %62, %61 ], [ 0, %36 ]
%47 = call i64 @feof(i32* %0)
%48 = icmp eq i64 %47, 0
br i1 %48, label %49, label %57
49: ; preds = %45
%50 = getelementptr inbounds [256 x i8], [256 x i8]* %4, i64 0, i64 %46
%51 = call i32 @fread(i8* %50, i32 1, i32 1, i32* %0)
%52 = icmp eq i32 %51, 1
br i1 %52, label %53, label %57
53: ; preds = %49
%54 = load i8, i8* %50
%55 = add i8 %54, -48
%56 = icmp ult i8 %55, 10
br i1 %56, label %61, label %57
57: ; preds = %53, %49, %45
%58 = getelementptr inbounds [256 x i8], [256 x i8]* %4, i64 0, i64 %46
%59 = load i8, i8* %58
%60 = icmp eq i8 %59, 46
br i1 %60, label %61, label %63
61: ; preds = %53, %57
%62 = add nuw i64 %46, 1
br label %45
63: ; preds = %57
%64 = trunc i64 %46 to i32
%65 = icmp eq i32 %64, 0
br i1 %65, label %66, label %69
66: ; preds = %63
%67 = load i32, i32* @SEEK_SET
%68 = call i32 @fseek(i32* %0, i64 %12, i32 %67)
br label %79
69: ; preds = %63
%70 = add i64 %46, 1
%71 = and i64 %70, 4294967295
%72 = getelementptr inbounds [256 x i8], [256 x i8]* %4, i64 0, i64 %71
store i8 10, i8* %72
%73 = call i32 (i8*, i8*, ...) @sscanf(i8* %6, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), double* %1)
%74 = icmp eq i32 %73, 1
%75 = load i32, i32* @SEEK_SET
%76 = call i32 @fseek(i32* %0, i64 %12, i32 %75)
%77 = load i32, i32* %3
%78 = select i1 %74, i32 %77, i32 -1
br label %79
79: ; preds = %69, %8, %2, %66, %42, %32
%80 = phi i32 [ -1, %32 ], [ -1, %42 ], [ -1, %66 ], [ -2, %2 ], [ -1, %8 ], [ %78, %69 ]
ret i32 %80
}