; LLVM IR from eugenebokhan/awesome-ml :: Awesome ML/Utils/Zip/minizip (unzip)

; 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"

%struct.unz64_s = type { %struct.zlib_filefunc64_32_def_s, ptr, ptr, %struct.unz_global_info64_s, i64, i64, i64, i64, i64, i64, i64, i64, %struct.unz_file_info64_s, %struct.unz_file_info64_internal_s, ptr, i32, [3 x i64], ptr }
%struct.zlib_filefunc64_32_def_s = type { %struct.zlib_filefunc64_def_s, ptr, ptr, ptr, ptr }
%struct.zlib_filefunc64_def_s = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }
%struct.unz_global_info64_s = type { i64, i64, i64 }
%struct.unz_file_info64_s = type { i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, %struct.tm_unz_s, i64, i64 }
%struct.tm_unz_s = type { i32, i32, i32, i32, i32, i32 }
%struct.unz_file_info64_internal_s = type { i64, i64 }
%struct.file_in_zip64_read_info_s = type { ptr, %struct.z_stream_s, i64, i64, i64, i32, i64, i64, i64, i64, i64, i64, %struct.zlib_filefunc64_32_def_s, ptr, i64, i64, i32 }
%struct.z_stream_s = type { ptr, i32, i64, ptr, i32, i64, ptr, ptr, ptr, ptr, ptr, i32, i64, i64 }

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

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

; Function Attrs: nounwind uwtable
define dso_local i32 @unzseek64(ptr noundef %0, i64 noundef %1, i32 noundef %2) #1 {
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  %6 = alloca i64, align 8
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %9 = alloca i64, align 8
  %10 = alloca i64, align 8
  %11 = alloca i32, align 4
  %12 = alloca i64, align 8
  %13 = alloca i32, align 4
  store ptr %0, ptr %5, align 8, !tbaa !5
  store i64 %1, ptr %6, align 8, !tbaa !9
  store i32 %2, ptr %7, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #2
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #2
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #2
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #2
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #2
  %14 = load ptr, ptr %5, align 8, !tbaa !5
  %15 = icmp eq ptr %14, null
  br i1 %15, label %16, label %17

16:                                               ; preds = %3
  store i32 -102, ptr %4, align 4
  store i32 1, ptr %13, align 4
  br label %197

17:                                               ; preds = %3
  %18 = load ptr, ptr %5, align 8, !tbaa !5
  store ptr %18, ptr %8, align 8, !tbaa !5
  %19 = load ptr, ptr %8, align 8, !tbaa !5
  %20 = getelementptr inbounds %struct.unz64_s, ptr %19, i32 0, i32 14
  %21 = load ptr, ptr %20, align 8, !tbaa !13
  %22 = icmp eq ptr %21, null
  br i1 %22, label %23, label %24

23:                                               ; preds = %17
  store i32 -1, ptr %4, align 4
  store i32 1, ptr %13, align 4
  br label %197

24:                                               ; preds = %17
  %25 = load ptr, ptr %8, align 8, !tbaa !5
  %26 = getelementptr inbounds %struct.unz64_s, ptr %25, i32 0, i32 14
  %27 = load ptr, ptr %26, align 8, !tbaa !13
  %28 = getelementptr inbounds %struct.file_in_zip64_read_info_s, ptr %27, i32 0, i32 14
  %29 = load i64, ptr %28, align 8, !tbaa !22
  %30 = icmp ne i64 %29, 0
  br i1 %30, label %31, label %32

31:                                               ; preds = %24
  store i32 -1, ptr %4, align 4
  store i32 1, ptr %13, align 4
  br label %197

32:                                               ; preds = %24
  %33 = load i32, ptr %7, align 4, !tbaa !11
  %34 = icmp eq i32 %33, 0
  br i1 %34, label %35, label %37

35:                                               ; preds = %32
  %36 = load i64, ptr %6, align 8, !tbaa !9
  store i64 %36, ptr %12, align 8, !tbaa !9
  br label %61

37:                                               ; preds = %32
  %38 = load i32, ptr %7, align 4, !tbaa !11
  %39 = icmp eq i32 %38, 1
  br i1 %39, label %40, label %48

40:                                               ; preds = %37
  %41 = load ptr, ptr %8, align 8, !tbaa !5
  %42 = getelementptr inbounds %struct.unz64_s, ptr %41, i32 0, i32 14
  %43 = load ptr, ptr %42, align 8, !tbaa !13
  %44 = getelementptr inbounds %struct.file_in_zip64_read_info_s, ptr %43, i32 0, i32 7
  %45 = load i64, ptr %44, align 8, !tbaa !25
  %46 = load i64, ptr %6, align 8, !tbaa !9
  %47 = add i64 %45, %46
  store i64 %47, ptr %12, align 8, !tbaa !9
  br label %60

48:                                               ; preds = %37
  %49 = load i32, ptr %7, align 4, !tbaa !11
  %50 = icmp eq i32 %49, 2
  br i1 %50, label %51, label %58

51:                                               ; preds = %48
  %52 = load ptr, ptr %8, align 8, !tbaa !5
  %53 = getelementptr inbounds %struct.unz64_s, ptr %52, i32 0, i32 12
  %54 = getelementptr inbounds %struct.unz_file_info64_s, ptr %53, i32 0, i32 6
  %55 = load i64, ptr %54, align 8, !tbaa !26
  %56 = load i64, ptr %6, align 8, !tbaa !9
  %57 = add i64 %55, %56
  store i64 %57, ptr %12, align 8, !tbaa !9
  br label %59

58:                                               ; preds = %48
  store i32 -102, ptr %4, align 4
  store i32 1, ptr %13, align 4
  br label %197

59:                                               ; preds = %51
  br label %60

60:                                               ; preds = %59, %40
  br label %61

61:                                               ; preds = %60, %35
  %62 = load i64, ptr %12, align 8, !tbaa !9
  %63 = load ptr, ptr %8, align 8, !tbaa !5
  %64 = getelementptr inbounds %struct.unz64_s, ptr %63, i32 0, i32 12
  %65 = getelementptr inbounds %struct.unz_file_info64_s, ptr %64, i32 0, i32 6
  %66 = load i64, ptr %65, align 8, !tbaa !26
  %67 = icmp ugt i64 %62, %66
  br i1 %67, label %68, label %69

68:                                               ; preds = %61
  store i32 -102, ptr %4, align 4
  store i32 1, ptr %13, align 4
  br label %197

69:                                               ; preds = %61
  %70 = load ptr, ptr %8, align 8, !tbaa !5
  %71 = getelementptr inbounds %struct.unz64_s, ptr %70, i32 0, i32 14
  %72 = load ptr, ptr %71, align 8, !tbaa !13
  %73 = getelementptr inbounds %struct.file_in_zip64_read_info_s, ptr %72, i32 0, i32 2
  %74 = load i64, ptr %73, align 8, !tbaa !27
  store i64 %74, ptr %10, align 8, !tbaa !9
  %75 = load i64, ptr %10, align 8, !tbaa !9
  store i64 %75, ptr %9, align 8, !tbaa !9
  %76 = load i64, ptr %9, align 8, !tbaa !9
  %77 = icmp ugt i64 %76, 65536
  br i1 %77, label %78, label %81

78:                                               ; preds = %69
  %79 = load i64, ptr %9, align 8, !tbaa !9
  %80 = sub i64 %79, 65536
  store i64 %80, ptr %9, align 8, !tbaa !9
  br label %82

81:                                               ; preds = %69
  store i64 0, ptr %9, align 8, !tbaa !9
  br label %82

82:                                               ; preds = %81, %78
  %83 = load ptr, ptr %8, align 8, !tbaa !5
  %84 = getelementptr inbounds %struct.unz64_s, ptr %83, i32 0, i32 14
  %85 = load ptr, ptr %84, align 8, !tbaa !13
  %86 = getelementptr inbounds %struct.file_in_zip64_read_info_s, ptr %85, i32 0, i32 1
  %87 = getelementptr inbounds %struct.z_stream_s, ptr %86, i32 0, i32 1
  %88 = load i32, ptr %87, align 8, !tbaa !28
  %89 = icmp ne i32 %88, 0
  br i1 %89, label %90, label %111

90:                                               ; preds = %82
  %91 = load ptr, ptr %8, align 8, !tbaa !5
  %92 = getelementptr inbounds %struct.unz64_s, ptr %91, i32 0, i32 14
  %93 = load ptr, ptr %92, align 8, !tbaa !13
  %94 = getelementptr inbounds %struct.file_in_zip64_read_info_s, ptr %93, i32 0, i32 10
  %95 = load i64, ptr %94, align 8, !tbaa !29
  %96 = icmp ne i64 %95, 0
  br i1 %96, label %103, label %97

97:                                               ; preds = %90
  %98 = load ptr, ptr %8, align 8, !tbaa !5
  %99 = getelementptr inbounds %struct.unz64_s, ptr %98, i32 0, i32 12
  %100 = getelementptr inbounds %struct.unz_file_info64_s, ptr %99, i32 0, i32 6
  %101 = load i64, ptr %100, align 8, !tbaa !26
  %102 = icmp ult i64 %101, 65536
  br i1 %102, label %103, label %111

103:                                              ; preds = %97, %90
  %104 = load i64, ptr %12, align 8, !tbaa !9
  %105 = load i64, ptr %9, align 8, !tbaa !9
  %106 = icmp uge i64 %104, %105
  br i1 %106, label %107, label %111

107:                                              ; preds = %103
  %108 = load i64, ptr %12, align 8, !tbaa !9
  %109 = load i64, ptr %10, align 8, !tbaa !9
  %110 = icmp ult i64 %108, %109
  br label %111

111:                                              ; preds = %107, %103, %97, %82
  %112 = phi i1 [ false, %103 ], [ false, %97 ], [ false, %82 ], [ %110, %107 ]
  %113 = zext i1 %112 to i32
  store i32 %113, ptr %11, align 4, !tbaa !11
  %114 = load i32, ptr %11, align 4, !tbaa !11
  %115 = icmp ne i32 %114, 0
  br i1 %115, label %116, label %140

116:                                              ; preds = %111
  %117 = load i64, ptr %12, align 8, !tbaa !9
  %118 = load ptr, ptr %8, align 8, !tbaa !5
  %119 = getelementptr inbounds %struct.unz64_s, ptr %118, i32 0, i32 14
  %120 = load ptr, ptr %119, align 8, !tbaa !13
  %121 = getelementptr inbounds %struct.file_in_zip64_read_info_s, ptr %120, i32 0, i32 7
  %122 = load i64, ptr %121, align 8, !tbaa !25
  %123 = sub i64 %117, %122
  %124 = load ptr, ptr %8, align 8, !tbaa !5
  %125 = getelementptr inbounds %struct.unz64_s, ptr %124, i32 0, i32 14
  %126 = load ptr, ptr %125, align 8, !tbaa !13
  %127 = getelementptr inbounds %struct.file_in_zip64_read_info_s, ptr %126, i32 0, i32 1
  %128 = getelementptr inbounds %struct.z_stream_s, ptr %127, i32 0, i32 0
  %129 = load ptr, ptr %128, align 8, !tbaa !30
  %130 = getelementptr inbounds i8, ptr %129, i64 %123
  store ptr %130, ptr %128, align 8, !tbaa !30
  %131 = load i64, ptr %10, align 8, !tbaa !9
  %132 = load i64, ptr %12, align 8, !tbaa !9
  %133 = sub i64 %131, %132
  %134 = trunc i64 %133 to i32
  %135 = load ptr, ptr %8, align 8, !tbaa !5
  %136 = getelementptr inbounds %struct.unz64_s, ptr %135, i32 0, i32 14
  %137 = load ptr, ptr %136, align 8, !tbaa !13
  %138 = getelementptr inbounds %struct.file_in_zip64_read_info_s, ptr %137, i32 0, i32 1
  %139 = getelementptr inbounds %struct.z_stream_s, ptr %138, i32 0, i32 1
  store i32 %134, ptr %139, align 8, !tbaa !28
  br label %172

140:                                              ; preds = %111
  %141 = load ptr, ptr %8, align 8, !tbaa !5
  %142 = getelementptr inbounds %struct.unz64_s, ptr %141, i32 0, i32 14
  %143 = load ptr, ptr %142, align 8, !tbaa !13
  %144 = getelementptr inbounds %struct.file_in_zip64_read_info_s, ptr %143, i32 0, i32 1
  %145 = getelementptr inbounds %struct.z_stream_s, ptr %144, i32 0, i32 1
  store i32 0, ptr %145, align 8, !tbaa !28
  %146 = load ptr, ptr %8, align 8, !tbaa !5
  %147 = getelementptr inbounds %struct.unz64_s, ptr %146, i32 0, i32 14
  %148 = load ptr, ptr %147, align 8, !tbaa !13
  %149 = getelementptr inbounds %struct.file_in_zip64_read_info_s, ptr %148, i32 0, i32 1
  %150 = getelementptr inbounds %struct.z_stream_s, ptr %149, i32 0, i32 0
  store ptr null, ptr %150, align 8, !tbaa !30
  %151 = load ptr, ptr %8, align 8, !tbaa !5
  %152 = getelementptr inbounds %struct.unz64_s, ptr %151, i32 0, i32 14
  %153 = load ptr, ptr %152, align 8, !tbaa !13
  %154 = getelementptr inbounds %struct.file_in_zip64_read_info_s, ptr %153, i32 0, i32 4
  %155 = load i64, ptr %154, align 8, !tbaa !31
  %156 = load i64, ptr %12, align 8, !tbaa !9
  %157 = add i64 %155, %156
  %158 = load ptr, ptr %8, align 8, !tbaa !5
  %159 = getelementptr inbounds %struct.unz64_s, ptr %158, i32 0, i32 14
  %160 = load ptr, ptr %159, align 8, !tbaa !13
  %161 = getelementptr inbounds %struct.file_in_zip64_read_info_s, ptr %160, i32 0, i32 2
  store i64 %157, ptr %161, align 8, !tbaa !27
  %162 = load ptr, ptr %8, align 8, !tbaa !5
  %163 = getelementptr inbounds %struct.unz64_s, ptr %162, i32 0, i32 12
  %164 = getelementptr inbounds %struct.unz_file_info64_s, ptr %163, i32 0, i32 6
  %165 = load i64, ptr %164, align 8, !tbaa !26
  %166 = load i64, ptr %12, align 8, !tbaa !9
  %167 = sub i64 %165, %166
  %168 = load ptr, ptr %8, align 8, !tbaa !5
  %169 = getelementptr inbounds %struct.unz64_s, ptr %168, i32 0, i32 14
  %170 = load ptr, ptr %169, align 8, !tbaa !13
  %171 = getelementptr inbounds %struct.file_in_zip64_read_info_s, ptr %170, i32 0, i32 10
  store i64 %167, ptr %171, align 8, !tbaa !29
  br label %172

172:                                              ; preds = %140, %116
  %173 = load i64, ptr %12, align 8, !tbaa !9
  %174 = load ptr, ptr %8, align 8, !tbaa !5
  %175 = getelementptr inbounds %struct.unz64_s, ptr %174, i32 0, i32 14
  %176 = load ptr, ptr %175, align 8, !tbaa !13
  %177 = getelementptr inbounds %struct.file_in_zip64_read_info_s, ptr %176, i32 0, i32 7
  %178 = load i64, ptr %177, align 8, !tbaa !25
  %179 = sub i64 %173, %178
  %180 = load ptr, ptr %8, align 8, !tbaa !5
  %181 = getelementptr inbounds %struct.unz64_s, ptr %180, i32 0, i32 14
  %182 = load ptr, ptr %181, align 8, !tbaa !13
  %183 = getelementptr inbounds %struct.file_in_zip64_read_info_s, ptr %182, i32 0, i32 11
  %184 = load i64, ptr %183, align 8, !tbaa !32
  %185 = sub i64 %184, %179
  store i64 %185, ptr %183, align 8, !tbaa !32
  %186 = load i64, ptr %12, align 8, !tbaa !9
  %187 = load ptr, ptr %8, align 8, !tbaa !5
  %188 = getelementptr inbounds %struct.unz64_s, ptr %187, i32 0, i32 14
  %189 = load ptr, ptr %188, align 8, !tbaa !13
  %190 = getelementptr inbounds %struct.file_in_zip64_read_info_s, ptr %189, i32 0, i32 1
  %191 = getelementptr inbounds %struct.z_stream_s, ptr %190, i32 0, i32 5
  store i64 %186, ptr %191, align 8, !tbaa !33
  %192 = load i64, ptr %12, align 8, !tbaa !9
  %193 = load ptr, ptr %8, align 8, !tbaa !5
  %194 = getelementptr inbounds %struct.unz64_s, ptr %193, i32 0, i32 14
  %195 = load ptr, ptr %194, align 8, !tbaa !13
  %196 = getelementptr inbounds %struct.file_in_zip64_read_info_s, ptr %195, i32 0, i32 7
  store i64 %192, ptr %196, align 8, !tbaa !25
  store i32 0, ptr %4, align 4
  store i32 1, ptr %13, align 4
  br label %197

197:                                              ; preds = %172, %68, %58, %31, %23, %16
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #2
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #2
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #2
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #2
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #2
  %198 = load i32, ptr %4, align 4
  ret i32 %198
}

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 = { nounwind }

!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/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"long long", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = !{!14, !6, i64 376}
!14 = !{!"", !15, i64 0, !6, i64 104, !6, i64 112, !17, i64 120, !10, i64 144, !10, i64 152, !10, i64 160, !10, i64 168, !10, i64 176, !18, i64 184, !10, i64 192, !10, i64 200, !19, i64 208, !21, i64 360, !6, i64 376, !12, i64 384, !7, i64 392, !6, i64 416}
!15 = !{!"zlib_filefunc64_32_def_s", !16, i64 0, !6, i64 72, !6, i64 80, !6, i64 88, !6, i64 96}
!16 = !{!"zlib_filefunc64_def_s", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64}
!17 = !{!"unz_global_info64_s", !10, i64 0, !18, i64 8, !18, i64 16}
!18 = !{!"long", !7, i64 0}
!19 = !{!"unz_file_info64_s", !18, i64 0, !18, i64 8, !18, i64 16, !18, i64 24, !18, i64 32, !18, i64 40, !10, i64 48, !10, i64 56, !18, i64 64, !18, i64 72, !18, i64 80, !18, i64 88, !18, i64 96, !18, i64 104, !20, i64 112, !10, i64 136, !18, i64 144}
!20 = !{!"tm_unz_s", !12, i64 0, !12, i64 4, !12, i64 8, !12, i64 12, !12, i64 16, !12, i64 20}
!21 = !{!"unz_file_info64_internal_s", !10, i64 0, !10, i64 8}
!22 = !{!23, !18, i64 312}
!23 = !{!"", !6, i64 0, !24, i64 8, !10, i64 120, !18, i64 128, !10, i64 136, !12, i64 144, !10, i64 152, !10, i64 160, !18, i64 168, !18, i64 176, !10, i64 184, !10, i64 192, !15, i64 200, !6, i64 304, !18, i64 312, !10, i64 320, !12, i64 328}
!24 = !{!"z_stream_s", !6, i64 0, !12, i64 8, !18, i64 16, !6, i64 24, !12, i64 32, !18, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !12, i64 88, !18, i64 96, !18, i64 104}
!25 = !{!23, !10, i64 160}
!26 = !{!14, !10, i64 256}
!27 = !{!23, !10, i64 120}
!28 = !{!23, !12, i64 16}
!29 = !{!23, !10, i64 184}
!30 = !{!23, !6, i64 8}
!31 = !{!23, !10, i64 136}
!32 = !{!23, !10, i64 192}
!33 = !{!23, !18, i64 48}


; 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"

; Function Attrs: mustprogress nofree norecurse nosync nounwind willreturn memory(readwrite, inaccessiblemem: none) uwtable
define dso_local range(i32 -102, 1) i32 @unzseek64(ptr noundef readonly %0, i64 noundef %1, i32 noundef %2) local_unnamed_addr #0 {
  %4 = icmp eq ptr %0, null
  br i1 %4, label %58, label %5

5:                                                ; preds = %3
  %6 = getelementptr inbounds i8, ptr %0, i64 376
  %7 = load ptr, ptr %6, align 8, !tbaa !5
  %8 = icmp eq ptr %7, null
  br i1 %8, label %58, label %9

9:                                                ; preds = %5
  %10 = getelementptr inbounds i8, ptr %7, i64 312
  %11 = load i64, ptr %10, align 8, !tbaa !19
  %.not = icmp eq i64 %11, 0
  br i1 %.not, label %12, label %58

12:                                               ; preds = %9
  switch i32 %2, label %58 [
    i32 0, label %19
    i32 1, label %13
    i32 2, label %15
  ]

13:                                               ; preds = %12
  %14 = getelementptr inbounds i8, ptr %7, i64 160
  br label %.sink.split

15:                                               ; preds = %12
  %16 = getelementptr inbounds i8, ptr %0, i64 256
  br label %.sink.split

.sink.split:                                      ; preds = %15, %13
  %.sink60 = phi ptr [ %14, %13 ], [ %16, %15 ]
  %17 = load i64, ptr %.sink60, align 8, !tbaa !22
  %18 = add i64 %17, %1
  br label %19

19:                                               ; preds = %.sink.split, %12
  %.0 = phi i64 [ %1, %12 ], [ %18, %.sink.split ]
  %20 = getelementptr inbounds i8, ptr %0, i64 256
  %21 = load i64, ptr %20, align 8, !tbaa !23
  %22 = icmp ugt i64 %.0, %21
  br i1 %22, label %58, label %23

23:                                               ; preds = %19
  %24 = getelementptr inbounds i8, ptr %7, i64 120
  %25 = load i64, ptr %24, align 8, !tbaa !24
  %.048 = tail call i64 @llvm.usub.sat.i64(i64 %25, i64 65536)
  %26 = getelementptr inbounds i8, ptr %7, i64 16
  %27 = load i32, ptr %26, align 8, !tbaa !25
  %.not53 = icmp eq i32 %27, 0
  br i1 %.not53, label %.critedge, label %28

28:                                               ; preds = %23
  %29 = getelementptr inbounds i8, ptr %7, i64 184
  %30 = load i64, ptr %29, align 8, !tbaa !26
  %.not54 = icmp eq i64 %30, 0
  br i1 %.not54, label %31, label %35

31:                                               ; preds = %28
  %32 = icmp ult i64 %21, 65536
  %.not55 = icmp uge i64 %.0, %.048
  %33 = icmp ult i64 %.0, %25
  %34 = and i1 %33, %.not55
  %or.cond56 = select i1 %32, i1 %34, i1 false
  br i1 %or.cond56, label %36, label %.critedge

35:                                               ; preds = %28
  %.not55.old = icmp uge i64 %.0, %.048
  %.old = icmp ult i64 %.0, %25
  %or.cond57 = and i1 %.old, %.not55.old
  br i1 %or.cond57, label %36, label %.critedge

36:                                               ; preds = %35, %31
  %37 = getelementptr inbounds i8, ptr %7, i64 160
  %38 = load i64, ptr %37, align 8, !tbaa !27
  %39 = sub i64 %.0, %38
  %40 = getelementptr inbounds i8, ptr %7, i64 8
  %41 = load ptr, ptr %40, align 8, !tbaa !28
  %42 = getelementptr inbounds i8, ptr %41, i64 %39
  store ptr %42, ptr %40, align 8, !tbaa !28
  %43 = sub i64 %25, %.0
  %44 = trunc i64 %43 to i32
  store i32 %44, ptr %26, align 8, !tbaa !25
  br label %51

.critedge:                                        ; preds = %35, %31, %23
  store i32 0, ptr %26, align 8, !tbaa !25
  %45 = getelementptr inbounds i8, ptr %7, i64 8
  store ptr null, ptr %45, align 8, !tbaa !28
  %46 = getelementptr inbounds i8, ptr %7, i64 136
  %47 = load i64, ptr %46, align 8, !tbaa !29
  %48 = add i64 %47, %.0
  store i64 %48, ptr %24, align 8, !tbaa !24
  %49 = sub i64 %21, %.0
  %50 = getelementptr inbounds i8, ptr %7, i64 184
  store i64 %49, ptr %50, align 8, !tbaa !26
  %.phi.trans.insert = getelementptr inbounds i8, ptr %7, i64 160
  %.pre = load i64, ptr %.phi.trans.insert, align 8, !tbaa !27
  br label %51

51:                                               ; preds = %.critedge, %36
  %52 = phi i64 [ %.pre, %.critedge ], [ %38, %36 ]
  %53 = getelementptr inbounds i8, ptr %7, i64 160
  %.neg = sub i64 %52, %.0
  %54 = getelementptr inbounds i8, ptr %7, i64 192
  %55 = load i64, ptr %54, align 8, !tbaa !30
  %56 = add i64 %.neg, %55
  store i64 %56, ptr %54, align 8, !tbaa !30
  %57 = getelementptr inbounds i8, ptr %7, i64 48
  store i64 %.0, ptr %57, align 8, !tbaa !31
  store i64 %.0, ptr %53, align 8, !tbaa !27
  br label %58

58:                                               ; preds = %19, %12, %9, %5, %3, %51
  %.047 = phi i32 [ 0, %51 ], [ -102, %3 ], [ -1, %5 ], [ -1, %9 ], [ -102, %12 ], [ -102, %19 ]
  ret i32 %.047
}

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i64 @llvm.usub.sat.i64(i64, i64) #1

attributes #0 = { mustprogress nofree norecurse nosync nounwind willreturn memory(readwrite, inaccessiblemem: none) 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 #1 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }

!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, !9, i64 376}
!6 = !{!"", !7, i64 0, !9, i64 104, !9, i64 112, !12, i64 120, !13, i64 144, !13, i64 152, !13, i64 160, !13, i64 168, !13, i64 176, !14, i64 184, !13, i64 192, !13, i64 200, !15, i64 208, !18, i64 360, !9, i64 376, !17, i64 384, !10, i64 392, !9, i64 416}
!7 = !{!"zlib_filefunc64_32_def_s", !8, i64 0, !9, i64 72, !9, i64 80, !9, i64 88, !9, i64 96}
!8 = !{!"zlib_filefunc64_def_s", !9, i64 0, !9, i64 8, !9, i64 16, !9, i64 24, !9, i64 32, !9, i64 40, !9, i64 48, !9, i64 56, !9, i64 64}
!9 = !{!"any pointer", !10, i64 0}
!10 = !{!"omnipotent char", !11, i64 0}
!11 = !{!"Simple C/C++ TBAA"}
!12 = !{!"unz_global_info64_s", !13, i64 0, !14, i64 8, !14, i64 16}
!13 = !{!"long long", !10, i64 0}
!14 = !{!"long", !10, i64 0}
!15 = !{!"unz_file_info64_s", !14, i64 0, !14, i64 8, !14, i64 16, !14, i64 24, !14, i64 32, !14, i64 40, !13, i64 48, !13, i64 56, !14, i64 64, !14, i64 72, !14, i64 80, !14, i64 88, !14, i64 96, !14, i64 104, !16, i64 112, !13, i64 136, !14, i64 144}
!16 = !{!"tm_unz_s", !17, i64 0, !17, i64 4, !17, i64 8, !17, i64 12, !17, i64 16, !17, i64 20}
!17 = !{!"int", !10, i64 0}
!18 = !{!"unz_file_info64_internal_s", !13, i64 0, !13, i64 8}
!19 = !{!20, !14, i64 312}
!20 = !{!"", !9, i64 0, !21, i64 8, !13, i64 120, !14, i64 128, !13, i64 136, !17, i64 144, !13, i64 152, !13, i64 160, !14, i64 168, !14, i64 176, !13, i64 184, !13, i64 192, !7, i64 200, !9, i64 304, !14, i64 312, !13, i64 320, !17, i64 328}
!21 = !{!"z_stream_s", !9, i64 0, !17, i64 8, !14, i64 16, !9, i64 24, !17, i64 32, !14, i64 40, !9, i64 48, !9, i64 56, !9, i64 64, !9, i64 72, !9, i64 80, !17, i64 88, !14, i64 96, !14, i64 104}
!22 = !{!13, !13, i64 0}
!23 = !{!6, !13, i64 256}
!24 = !{!20, !13, i64 120}
!25 = !{!20, !17, i64 16}
!26 = !{!20, !13, i64 184}
!27 = !{!20, !13, i64 160}
!28 = !{!20, !9, i64 8}
!29 = !{!20, !13, i64 136}
!30 = !{!20, !13, i64 192}
!31 = !{!20, !14, i64 48}


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