; LLVM IR from CerebusOSS/CereLink :: cbhwlib/CCFUtilsBinary.ll (ZN14CCFUtilsBinary11ReadVersionEPKc)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%class.CCFUtils = type <{ ptr, ptr, i8, [7 x i8], ptr, i8, [7 x i8], ptr, i32, i32, i32, [4 x i8], ptr, i8, i8, [6 x i8] }>

@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [5 x i8], align 1

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #0

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_ZN14CCFUtilsBinary11ReadVersionEPKc(ptr noundef nonnull align 8 dereferenceable(189696) %0, ptr noundef %1) unnamed_addr #1 align 2 {
  %3 = alloca i32, align 4
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca [7 x i8], align 1
  %10 = alloca [11 x i8], align 1
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  %11 = load ptr, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #5
  store ptr null, ptr %6, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #5
  store i32 0, ptr %7, align 4, !tbaa !9
  %12 = load ptr, ptr %5, align 8, !tbaa !5
  %13 = getelementptr inbounds %class.CCFUtils, ptr %11, i32 0, i32 12
  store ptr %12, ptr %13, align 8, !tbaa !11
  %14 = load ptr, ptr %5, align 8, !tbaa !5
  %15 = call noalias ptr @fopen(ptr noundef %14, ptr noundef @.str)
  store ptr %15, ptr %6, align 8, !tbaa !5
  %16 = load ptr, ptr %6, align 8, !tbaa !5
  %17 = icmp eq ptr %16, null
  br i1 %17, label %18, label %19

18:                                               ; preds = %2
  store i32 -5, ptr %3, align 4
  store i32 1, ptr %8, align 4
  br label %178

19:                                               ; preds = %2
  call void @llvm.lifetime.start.p0(i64 7, ptr %9) #5
  call void @llvm.memset.p0.i64(ptr align 1 %9, i8 0, i64 7, i1 false)
  call void @llvm.lifetime.start.p0(i64 11, ptr %10) #5
  call void @llvm.memset.p0.i64(ptr align 1 %10, i8 0, i64 11, i1 false)
  %20 = load ptr, ptr %6, align 8, !tbaa !5
  %21 = call i64 @fread(ptr noundef %9, i64 noundef 6, i64 noundef 1, ptr noundef %20)
  %22 = load ptr, ptr %6, align 8, !tbaa !5
  %23 = call i64 @fread(ptr noundef %10, i64 noundef 10, i64 noundef 1, ptr noundef %22)
  %24 = getelementptr inbounds [7 x i8], ptr %9, i64 0, i64 0
  %25 = call i32 @strcmp(ptr noundef @.str.1, ptr noundef %24) #6
  %26 = icmp eq i32 %25, 0
  br i1 %26, label %27, label %33

27:                                               ; preds = %19
  %28 = getelementptr inbounds [11 x i8], ptr %10, i64 0, i64 0
  %29 = call i32 @strncmp(ptr noundef @.str.2, ptr noundef %28, i64 noundef 3) #6
  %30 = icmp eq i32 %29, 0
  br i1 %30, label %31, label %33

31:                                               ; preds = %27
  %32 = getelementptr inbounds %class.CCFUtils, ptr %11, i32 0, i32 9
  store i32 1, ptr %32, align 4, !tbaa !15
  br label %167

33:                                               ; preds = %27, %19
  %34 = getelementptr inbounds [7 x i8], ptr %9, i64 0, i64 0
  %35 = call i32 @strcmp(ptr noundef @.str.3, ptr noundef %34) #6
  %36 = icmp eq i32 %35, 0
  br i1 %36, label %37, label %43

37:                                               ; preds = %33
  %38 = getelementptr inbounds [11 x i8], ptr %10, i64 0, i64 0
  %39 = call i32 @strcmp(ptr noundef @.str.4, ptr noundef %38) #6
  %40 = icmp eq i32 %39, 0
  br i1 %40, label %41, label %43

41:                                               ; preds = %37
  %42 = getelementptr inbounds %class.CCFUtils, ptr %11, i32 0, i32 9
  store i32 2, ptr %42, align 4, !tbaa !15
  br label %166

43:                                               ; preds = %37, %33
  %44 = getelementptr inbounds [7 x i8], ptr %9, i64 0, i64 0
  %45 = call i32 @strcmp(ptr noundef @.str.3, ptr noundef %44) #6
  %46 = icmp eq i32 %45, 0
  br i1 %46, label %47, label %53

47:                                               ; preds = %43
  %48 = getelementptr inbounds [11 x i8], ptr %10, i64 0, i64 0
  %49 = call i32 @strcmp(ptr noundef @.str.5, ptr noundef %48) #6
  %50 = icmp eq i32 %49, 0
  br i1 %50, label %51, label %53

51:                                               ; preds = %47
  %52 = getelementptr inbounds %class.CCFUtils, ptr %11, i32 0, i32 9
  store i32 3, ptr %52, align 4, !tbaa !15
  br label %165

53:                                               ; preds = %47, %43
  %54 = getelementptr inbounds [7 x i8], ptr %9, i64 0, i64 0
  %55 = call i32 @strcmp(ptr noundef @.str.3, ptr noundef %54) #6
  %56 = icmp eq i32 %55, 0
  br i1 %56, label %57, label %63

57:                                               ; preds = %53
  %58 = getelementptr inbounds [11 x i8], ptr %10, i64 0, i64 0
  %59 = call i32 @strcmp(ptr noundef @.str.6, ptr noundef %58) #6
  %60 = icmp eq i32 %59, 0
  br i1 %60, label %61, label %63

61:                                               ; preds = %57
  %62 = getelementptr inbounds %class.CCFUtils, ptr %11, i32 0, i32 9
  store i32 4, ptr %62, align 4, !tbaa !15
  br label %164

63:                                               ; preds = %57, %53
  %64 = getelementptr inbounds [7 x i8], ptr %9, i64 0, i64 0
  %65 = call i32 @strcmp(ptr noundef @.str.3, ptr noundef %64) #6
  %66 = icmp eq i32 %65, 0
  br i1 %66, label %67, label %73

67:                                               ; preds = %63
  %68 = getelementptr inbounds [11 x i8], ptr %10, i64 0, i64 0
  %69 = call i32 @strcmp(ptr noundef @.str.7, ptr noundef %68) #6
  %70 = icmp eq i32 %69, 0
  br i1 %70, label %71, label %73

71:                                               ; preds = %67
  %72 = getelementptr inbounds %class.CCFUtils, ptr %11, i32 0, i32 9
  store i32 5, ptr %72, align 4, !tbaa !15
  br label %163

73:                                               ; preds = %67, %63
  %74 = getelementptr inbounds [7 x i8], ptr %9, i64 0, i64 0
  %75 = call i32 @strcmp(ptr noundef @.str.3, ptr noundef %74) #6
  %76 = icmp eq i32 %75, 0
  br i1 %76, label %77, label %83

77:                                               ; preds = %73
  %78 = getelementptr inbounds [11 x i8], ptr %10, i64 0, i64 0
  %79 = call i32 @strcmp(ptr noundef @.str.8, ptr noundef %78) #6
  %80 = icmp eq i32 %79, 0
  br i1 %80, label %81, label %83

81:                                               ; preds = %77
  %82 = getelementptr inbounds %class.CCFUtils, ptr %11, i32 0, i32 9
  store i32 6, ptr %82, align 4, !tbaa !15
  br label %162

83:                                               ; preds = %77, %73
  %84 = getelementptr inbounds [7 x i8], ptr %9, i64 0, i64 0
  %85 = call i32 @strcmp(ptr noundef @.str.3, ptr noundef %84) #6
  %86 = icmp eq i32 %85, 0
  br i1 %86, label %87, label %93

87:                                               ; preds = %83
  %88 = getelementptr inbounds [11 x i8], ptr %10, i64 0, i64 0
  %89 = call i32 @strcmp(ptr noundef @.str.9, ptr noundef %88) #6
  %90 = icmp eq i32 %89, 0
  br i1 %90, label %91, label %93

91:                                               ; preds = %87
  %92 = getelementptr inbounds %class.CCFUtils, ptr %11, i32 0, i32 9
  store i32 7, ptr %92, align 4, !tbaa !15
  br label %161

93:                                               ; preds = %87, %83
  %94 = getelementptr inbounds [7 x i8], ptr %9, i64 0, i64 0
  %95 = call i32 @strcmp(ptr noundef @.str.10, ptr noundef %94) #6
  %96 = icmp eq i32 %95, 0
  br i1 %96, label %97, label %103

97:                                               ; preds = %93
  %98 = getelementptr inbounds [11 x i8], ptr %10, i64 0, i64 0
  %99 = call i32 @strcmp(ptr noundef @.str.11, ptr noundef %98) #6
  %100 = icmp eq i32 %99, 0
  br i1 %100, label %101, label %103

101:                                              ; preds = %97
  %102 = getelementptr inbounds %class.CCFUtils, ptr %11, i32 0, i32 9
  store i32 8, ptr %102, align 4, !tbaa !15
  br label %160

103:                                              ; preds = %97, %93
  %104 = getelementptr inbounds [7 x i8], ptr %9, i64 0, i64 0
  %105 = call i32 @strcmp(ptr noundef @.str.10, ptr noundef %104) #6
  %106 = icmp eq i32 %105, 0
  br i1 %106, label %107, label %113

107:                                              ; preds = %103
  %108 = getelementptr inbounds [11 x i8], ptr %10, i64 0, i64 0
  %109 = call i32 @strcmp(ptr noundef @.str.12, ptr noundef %108) #6
  %110 = icmp eq i32 %109, 0
  br i1 %110, label %111, label %113

111:                                              ; preds = %107
  %112 = getelementptr inbounds %class.CCFUtils, ptr %11, i32 0, i32 9
  store i32 9, ptr %112, align 4, !tbaa !15
  br label %159

113:                                              ; preds = %107, %103
  %114 = getelementptr inbounds [7 x i8], ptr %9, i64 0, i64 0
  %115 = call i32 @strcmp(ptr noundef @.str.10, ptr noundef %114) #6
  %116 = icmp eq i32 %115, 0
  br i1 %116, label %117, label %123

117:                                              ; preds = %113
  %118 = getelementptr inbounds [11 x i8], ptr %10, i64 0, i64 0
  %119 = call i32 @strcmp(ptr noundef @.str.13, ptr noundef %118) #6
  %120 = icmp eq i32 %119, 0
  br i1 %120, label %121, label %123

121:                                              ; preds = %117
  %122 = getelementptr inbounds %class.CCFUtils, ptr %11, i32 0, i32 9
  store i32 10, ptr %122, align 4, !tbaa !15
  br label %158

123:                                              ; preds = %117, %113
  %124 = getelementptr inbounds [7 x i8], ptr %9, i64 0, i64 0
  %125 = call i32 @strcmp(ptr noundef @.str.10, ptr noundef %124) #6
  %126 = icmp eq i32 %125, 0
  br i1 %126, label %127, label %133

127:                                              ; preds = %123
  %128 = getelementptr inbounds [11 x i8], ptr %10, i64 0, i64 0
  %129 = call i32 @strcmp(ptr noundef @.str.14, ptr noundef %128) #6
  %130 = icmp eq i32 %129, 0
  br i1 %130, label %131, label %133

131:                                              ; preds = %127
  %132 = getelementptr inbounds %class.CCFUtils, ptr %11, i32 0, i32 9
  store i32 11, ptr %132, align 4, !tbaa !15
  br label %157

133:                                              ; preds = %127, %123
  %134 = getelementptr inbounds [7 x i8], ptr %9, i64 0, i64 0
  %135 = call i32 @strcmp(ptr noundef @.str.10, ptr noundef %134) #6
  %136 = icmp eq i32 %135, 0
  br i1 %136, label %137, label %143

137:                                              ; preds = %133
  %138 = getelementptr inbounds [11 x i8], ptr %10, i64 0, i64 0
  %139 = call i32 @strcmp(ptr noundef @.str.15, ptr noundef %138) #6
  %140 = icmp eq i32 %139, 0
  br i1 %140, label %141, label %143

141:                                              ; preds = %137
  %142 = getelementptr inbounds %class.CCFUtils, ptr %11, i32 0, i32 9
  store i32 11, ptr %142, align 4, !tbaa !15
  br label %156

143:                                              ; preds = %137, %133
  %144 = getelementptr inbounds [7 x i8], ptr %9, i64 0, i64 0
  %145 = call i32 @strcmp(ptr noundef @.str.10, ptr noundef %144) #6
  %146 = icmp eq i32 %145, 0
  br i1 %146, label %147, label %153

147:                                              ; preds = %143
  %148 = getelementptr inbounds [11 x i8], ptr %10, i64 0, i64 0
  %149 = call i32 @strcmp(ptr noundef @.str.16, ptr noundef %148) #6
  %150 = icmp eq i32 %149, 0
  br i1 %150, label %151, label %153

151:                                              ; preds = %147
  %152 = getelementptr inbounds %class.CCFUtils, ptr %11, i32 0, i32 9
  store i32 12, ptr %152, align 4, !tbaa !15
  br label %155

153:                                              ; preds = %147, %143
  %154 = getelementptr inbounds %class.CCFUtils, ptr %11, i32 0, i32 9
  store i32 0, ptr %154, align 4, !tbaa !15
  br label %155

155:                                              ; preds = %153, %151
  br label %156

156:                                              ; preds = %155, %141
  br label %157

157:                                              ; preds = %156, %131
  br label %158

158:                                              ; preds = %157, %121
  br label %159

159:                                              ; preds = %158, %111
  br label %160

160:                                              ; preds = %159, %101
  br label %161

161:                                              ; preds = %160, %91
  br label %162

162:                                              ; preds = %161, %81
  br label %163

163:                                              ; preds = %162, %71
  br label %164

164:                                              ; preds = %163, %61
  br label %165

165:                                              ; preds = %164, %51
  br label %166

166:                                              ; preds = %165, %41
  br label %167

167:                                              ; preds = %166, %31
  %168 = load ptr, ptr %6, align 8, !tbaa !5
  %169 = call i32 @fclose(ptr noundef %168)
  %170 = getelementptr inbounds %class.CCFUtils, ptr %11, i32 0, i32 9
  %171 = load i32, ptr %170, align 4, !tbaa !15
  %172 = icmp eq i32 %171, 0
  br i1 %172, label %173, label %174

173:                                              ; preds = %167
  store i32 -3, ptr %7, align 4, !tbaa !9
  br label %176

174:                                              ; preds = %167
  %175 = getelementptr inbounds %class.CCFUtils, ptr %11, i32 0, i32 14
  store i8 1, ptr %175, align 1, !tbaa !16
  br label %176

176:                                              ; preds = %174, %173
  %177 = load i32, ptr %7, align 4, !tbaa !9
  store i32 %177, ptr %3, align 4
  store i32 1, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 11, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 7, ptr %9) #5
  br label %178

178:                                              ; preds = %176, %18
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #5
  %179 = load i32, ptr %3, align 4
  ret i32 %179
}

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #2

declare noalias ptr @fopen(ptr noundef, ptr noundef) #3

declare i64 @fread(ptr noundef, i64 noundef, i64 noundef, ptr noundef) #3

; Function Attrs: nounwind willreturn memory(read)
declare i32 @strcmp(ptr noundef, ptr noundef) #4

; Function Attrs: nounwind willreturn memory(read)
declare i32 @strncmp(ptr noundef, ptr noundef, i64 noundef) #4

declare i32 @fclose(ptr noundef) #3

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #2

attributes #0 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #1 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { nounwind willreturn memory(read) "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { nounwind }
attributes #6 = { nounwind willreturn memory(read) }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"_ZTSN3ccf10_ccfResultE", !7, i64 0}
!11 = !{!12, !6, i64 64}
!12 = !{!"_ZTS8CCFUtils", !6, i64 8, !13, i64 16, !6, i64 24, !13, i64 32, !6, i64 40, !14, i64 48, !14, i64 52, !14, i64 56, !6, i64 64, !13, i64 72, !13, i64 73}
!13 = !{!"bool", !7, i64 0}
!14 = !{!"int", !7, i64 0}
!15 = !{!12, !14, i64 52}
!16 = !{!12, !13, i64 73}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

@.str = external hidden unnamed_addr constant [3 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [5 x i8], align 1

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #0

; Function Attrs: mustprogress nofree nounwind uwtable
define dso_local noundef range(i32 -5, 1) i32 @_ZN14CCFUtilsBinary11ReadVersionEPKc(ptr nocapture noundef nonnull align 8 dereferenceable(189696) %0, ptr noundef %1) unnamed_addr #1 align 2 {
  %3 = alloca [7 x i8], align 1
  %4 = alloca [11 x i8], align 1
  %5 = getelementptr inbounds i8, ptr %0, i64 64
  store ptr %1, ptr %5, align 8, !tbaa !5
  %6 = tail call noalias ptr @fopen(ptr noundef %1, ptr noundef nonnull @.str)
  %7 = icmp eq ptr %6, null
  br i1 %7, label %68, label %8

8:                                                ; preds = %2
  call void @llvm.lifetime.start.p0(i64 7, ptr nonnull %3) #5
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 1 dereferenceable(7) %3, i8 0, i64 7, i1 false)
  call void @llvm.lifetime.start.p0(i64 11, ptr nonnull %4) #5
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 1 dereferenceable(11) %4, i8 0, i64 11, i1 false)
  %9 = call i64 @fread(ptr noundef nonnull %3, i64 noundef 6, i64 noundef 1, ptr noundef nonnull %6)
  %10 = call i64 @fread(ptr noundef nonnull %4, i64 noundef 10, i64 noundef 1, ptr noundef nonnull %6)
  %11 = call i32 @strcmp(ptr noundef nonnull dereferenceable(1) @.str.1, ptr noundef nonnull dereferenceable(1) %3) #6
  %12 = icmp eq i32 %11, 0
  br i1 %12, label %13, label %16

13:                                               ; preds = %8
  %14 = call i32 @strncmp(ptr noundef nonnull dereferenceable(1) @.str.2, ptr noundef nonnull dereferenceable(1) %4, i64 noundef 3) #6
  %15 = icmp eq i32 %14, 0
  br i1 %15, label %59, label %16

16:                                               ; preds = %13, %8
  %17 = call i32 @strcmp(ptr noundef nonnull dereferenceable(1) @.str.3, ptr noundef nonnull dereferenceable(1) %3) #6
  %18 = icmp eq i32 %17, 0
  br i1 %18, label %19, label %37

19:                                               ; preds = %16
  %20 = call i32 @strcmp(ptr noundef nonnull dereferenceable(1) @.str.4, ptr noundef nonnull dereferenceable(1) %4) #6
  %21 = icmp eq i32 %20, 0
  br i1 %21, label %59, label %22

22:                                               ; preds = %19
  %23 = call i32 @strcmp(ptr noundef nonnull dereferenceable(1) @.str.5, ptr noundef nonnull dereferenceable(1) %4) #6
  %24 = icmp eq i32 %23, 0
  br i1 %24, label %59, label %25

25:                                               ; preds = %22
  %26 = call i32 @strcmp(ptr noundef nonnull dereferenceable(1) @.str.6, ptr noundef nonnull dereferenceable(1) %4) #6
  %27 = icmp eq i32 %26, 0
  br i1 %27, label %59, label %28

28:                                               ; preds = %25
  %29 = call i32 @strcmp(ptr noundef nonnull dereferenceable(1) @.str.7, ptr noundef nonnull dereferenceable(1) %4) #6
  %30 = icmp eq i32 %29, 0
  br i1 %30, label %59, label %31

31:                                               ; preds = %28
  %32 = call i32 @strcmp(ptr noundef nonnull dereferenceable(1) @.str.8, ptr noundef nonnull dereferenceable(1) %4) #6
  %33 = icmp eq i32 %32, 0
  br i1 %33, label %59, label %34

34:                                               ; preds = %31
  %35 = call i32 @strcmp(ptr noundef nonnull dereferenceable(1) @.str.9, ptr noundef nonnull dereferenceable(1) %4) #6
  %36 = icmp eq i32 %35, 0
  br i1 %36, label %59, label %37

37:                                               ; preds = %16, %34
  %38 = call i32 @strcmp(ptr noundef nonnull dereferenceable(1) @.str.10, ptr noundef nonnull dereferenceable(1) %3) #6
  %39 = icmp eq i32 %38, 0
  br i1 %39, label %40, label %58

40:                                               ; preds = %37
  %41 = call i32 @strcmp(ptr noundef nonnull dereferenceable(1) @.str.11, ptr noundef nonnull dereferenceable(1) %4) #6
  %42 = icmp eq i32 %41, 0
  br i1 %42, label %59, label %43

43:                                               ; preds = %40
  %44 = call i32 @strcmp(ptr noundef nonnull dereferenceable(1) @.str.12, ptr noundef nonnull dereferenceable(1) %4) #6
  %45 = icmp eq i32 %44, 0
  br i1 %45, label %59, label %46

46:                                               ; preds = %43
  %47 = call i32 @strcmp(ptr noundef nonnull dereferenceable(1) @.str.13, ptr noundef nonnull dereferenceable(1) %4) #6
  %48 = icmp eq i32 %47, 0
  br i1 %48, label %59, label %49

49:                                               ; preds = %46
  %50 = call i32 @strcmp(ptr noundef nonnull dereferenceable(1) @.str.14, ptr noundef nonnull dereferenceable(1) %4) #6
  %51 = icmp eq i32 %50, 0
  br i1 %51, label %59, label %52

52:                                               ; preds = %49
  %53 = call i32 @strcmp(ptr noundef nonnull dereferenceable(1) @.str.15, ptr noundef nonnull dereferenceable(1) %4) #6
  %54 = icmp eq i32 %53, 0
  br i1 %54, label %59, label %55

55:                                               ; preds = %52
  %56 = call i32 @strcmp(ptr noundef nonnull dereferenceable(1) @.str.16, ptr noundef nonnull dereferenceable(1) %4) #6
  %57 = icmp eq i32 %56, 0
  br i1 %57, label %59, label %58

58:                                               ; preds = %37, %55
  br label %59

59:                                               ; preds = %55, %52, %49, %46, %43, %40, %34, %31, %28, %25, %22, %19, %13, %58
  %.sink = phi i32 [ 0, %58 ], [ 1, %13 ], [ 2, %19 ], [ 3, %22 ], [ 4, %25 ], [ 5, %28 ], [ 6, %31 ], [ 7, %34 ], [ 8, %40 ], [ 9, %43 ], [ 10, %46 ], [ 11, %49 ], [ 11, %52 ], [ 12, %55 ]
  %60 = getelementptr inbounds i8, ptr %0, i64 52
  store i32 %.sink, ptr %60, align 4, !tbaa !12
  %61 = tail call i32 @fclose(ptr noundef nonnull %6)
  %62 = getelementptr inbounds i8, ptr %0, i64 52
  %63 = load i32, ptr %62, align 4, !tbaa !12
  %64 = icmp eq i32 %63, 0
  br i1 %64, label %67, label %65

65:                                               ; preds = %59
  %66 = getelementptr inbounds i8, ptr %0, i64 73
  store i8 1, ptr %66, align 1, !tbaa !13
  br label %67

67:                                               ; preds = %59, %65
  %.0 = phi i32 [ 0, %65 ], [ -3, %59 ]
  call void @llvm.lifetime.end.p0(i64 11, ptr nonnull %4) #5
  call void @llvm.lifetime.end.p0(i64 7, ptr nonnull %3) #5
  br label %68

68:                                               ; preds = %2, %67
  %.08 = phi i32 [ %.0, %67 ], [ -5, %2 ]
  ret i32 %.08
}

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #2

; Function Attrs: nofree nounwind
declare noalias noundef ptr @fopen(ptr nocapture noundef readonly, ptr nocapture noundef readonly) local_unnamed_addr #3

; Function Attrs: nofree nounwind
declare noundef i64 @fread(ptr nocapture noundef, i64 noundef, i64 noundef, ptr nocapture noundef) local_unnamed_addr #3

; Function Attrs: mustprogress nofree nounwind willreturn memory(argmem: read)
declare i32 @strcmp(ptr nocapture noundef, ptr nocapture noundef) local_unnamed_addr #4

; Function Attrs: mustprogress nofree nounwind willreturn memory(argmem: read)
declare i32 @strncmp(ptr nocapture noundef, ptr nocapture noundef, i64 noundef) local_unnamed_addr #4

; Function Attrs: nofree nounwind
declare noundef i32 @fclose(ptr nocapture noundef) local_unnamed_addr #3

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #2

attributes #0 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #1 = { mustprogress nofree nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { nofree nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { mustprogress nofree nounwind willreturn memory(argmem: read) "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { nounwind }
attributes #6 = { nounwind willreturn memory(read) }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !7, i64 64}
!6 = !{!"_ZTS8CCFUtils", !7, i64 8, !10, i64 16, !7, i64 24, !10, i64 32, !7, i64 40, !11, i64 48, !11, i64 52, !11, i64 56, !7, i64 64, !10, i64 72, !10, i64 73}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"bool", !8, i64 0}
!11 = !{!"int", !8, i64 0}
!12 = !{!6, !11, i64 52}
!13 = !{!6, !10, i64 73}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass,TailCallElimPass