; LLVM IR from SSBMTonberry/pocketlzma :: ref_spec/lzma1900/C (7zDec)

; 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.CSzFolder = type { i32, i32, i32, i32, [4 x i32], [3 x %struct.CSzBond], [4 x %struct.CSzCoderInfo] }
%struct.CSzBond = type { i32, i32 }
%struct.CSzCoderInfo = type { i64, i32, i8, i8 }
%struct.CSzData = type { ptr, i64 }
%struct.CSzAr = type { i32, i32, ptr, %struct.CSzBitUi32s, ptr, ptr, ptr, ptr, ptr, ptr }
%struct.CSzBitUi32s = type { ptr, ptr }
%struct.ISzAlloc = type { ptr, ptr }

; Function Attrs: nounwind uwtable
define dso_local i32 @SzAr_DecodeFolder(ptr noundef %0, i32 noundef %1, ptr noundef %2, i64 noundef %3, ptr noundef %4, i64 noundef %5, ptr noundef %6) #0 {
  %8 = alloca i32, align 4
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca ptr, align 8
  %12 = alloca i64, align 8
  %13 = alloca ptr, align 8
  %14 = alloca i64, align 8
  %15 = alloca ptr, align 8
  %16 = alloca i32, align 4
  %17 = alloca %struct.CSzFolder, align 8
  %18 = alloca %struct.CSzData, align 8
  %19 = alloca ptr, align 8
  %20 = alloca i32, align 4
  %21 = alloca i32, align 4
  %22 = alloca [3 x ptr], align 16
  store ptr %0, ptr %9, align 8, !tbaa !5
  store i32 %1, ptr %10, align 4, !tbaa !9
  store ptr %2, ptr %11, align 8, !tbaa !5
  store i64 %3, ptr %12, align 8, !tbaa !11
  store ptr %4, ptr %13, align 8, !tbaa !5
  store i64 %5, ptr %14, align 8, !tbaa !13
  store ptr %6, ptr %15, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #4
  call void @llvm.lifetime.start.p0(i64 120, ptr %17) #4
  call void @llvm.lifetime.start.p0(i64 16, ptr %18) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #4
  %23 = load ptr, ptr %9, align 8, !tbaa !5
  %24 = getelementptr inbounds %struct.CSzAr, ptr %23, i32 0, i32 9
  %25 = load ptr, ptr %24, align 8, !tbaa !15
  %26 = load ptr, ptr %9, align 8, !tbaa !5
  %27 = getelementptr inbounds %struct.CSzAr, ptr %26, i32 0, i32 4
  %28 = load ptr, ptr %27, align 8, !tbaa !18
  %29 = load i32, ptr %10, align 4, !tbaa !9
  %30 = zext i32 %29 to i64
  %31 = getelementptr inbounds i64, ptr %28, i64 %30
  %32 = load i64, ptr %31, align 8, !tbaa !13
  %33 = getelementptr inbounds i8, ptr %25, i64 %32
  store ptr %33, ptr %19, align 8, !tbaa !5
  %34 = load ptr, ptr %19, align 8, !tbaa !5
  %35 = getelementptr inbounds %struct.CSzData, ptr %18, i32 0, i32 0
  store ptr %34, ptr %35, align 8, !tbaa !19
  %36 = load ptr, ptr %9, align 8, !tbaa !5
  %37 = getelementptr inbounds %struct.CSzAr, ptr %36, i32 0, i32 4
  %38 = load ptr, ptr %37, align 8, !tbaa !18
  %39 = load i32, ptr %10, align 4, !tbaa !9
  %40 = zext i32 %39 to i64
  %41 = add i64 %40, 1
  %42 = getelementptr inbounds i64, ptr %38, i64 %41
  %43 = load i64, ptr %42, align 8, !tbaa !13
  %44 = load ptr, ptr %9, align 8, !tbaa !5
  %45 = getelementptr inbounds %struct.CSzAr, ptr %44, i32 0, i32 4
  %46 = load ptr, ptr %45, align 8, !tbaa !18
  %47 = load i32, ptr %10, align 4, !tbaa !9
  %48 = zext i32 %47 to i64
  %49 = getelementptr inbounds i64, ptr %46, i64 %48
  %50 = load i64, ptr %49, align 8, !tbaa !13
  %51 = sub i64 %43, %50
  %52 = getelementptr inbounds %struct.CSzData, ptr %18, i32 0, i32 1
  store i64 %51, ptr %52, align 8, !tbaa !21
  %53 = call i32 @SzGetNextFolderItem(ptr noundef %17, ptr noundef %18)
  store i32 %53, ptr %16, align 4, !tbaa !9
  %54 = load i32, ptr %16, align 4, !tbaa !9
  %55 = icmp ne i32 %54, 0
  br i1 %55, label %56, label %58

56:                                               ; preds = %7
  %57 = load i32, ptr %16, align 4, !tbaa !9
  store i32 %57, ptr %8, align 4
  store i32 1, ptr %20, align 4
  br label %172

58:                                               ; preds = %7
  %59 = getelementptr inbounds %struct.CSzData, ptr %18, i32 0, i32 1
  %60 = load i64, ptr %59, align 8, !tbaa !21
  %61 = icmp ne i64 %60, 0
  br i1 %61, label %80, label %62

62:                                               ; preds = %58
  %63 = getelementptr inbounds %struct.CSzFolder, ptr %17, i32 0, i32 3
  %64 = load i32, ptr %63, align 4, !tbaa !22
  %65 = load ptr, ptr %9, align 8, !tbaa !5
  %66 = getelementptr inbounds %struct.CSzAr, ptr %65, i32 0, i32 7
  %67 = load ptr, ptr %66, align 8, !tbaa !24
  %68 = load i32, ptr %10, align 4, !tbaa !9
  %69 = zext i32 %68 to i64
  %70 = getelementptr inbounds i8, ptr %67, i64 %69
  %71 = load i8, ptr %70, align 1, !tbaa !25
  %72 = zext i8 %71 to i32
  %73 = icmp ne i32 %64, %72
  br i1 %73, label %80, label %74

74:                                               ; preds = %62
  %75 = load i64, ptr %14, align 8, !tbaa !13
  %76 = load ptr, ptr %9, align 8, !tbaa !5
  %77 = load i32, ptr %10, align 4, !tbaa !9
  %78 = call i64 @SzAr_GetFolderUnpackSize(ptr noundef %76, i32 noundef %77)
  %79 = icmp ne i64 %75, %78
  br i1 %79, label %80, label %81

80:                                               ; preds = %74, %62, %58
  store i32 11, ptr %8, align 4
  store i32 1, ptr %20, align 4
  br label %172

81:                                               ; preds = %74
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #4
  call void @llvm.lifetime.start.p0(i64 24, ptr %22) #4
  call void @llvm.memset.p0.i64(ptr align 16 %22, i8 0, i64 24, i1 false)
  %82 = load ptr, ptr %19, align 8, !tbaa !5
  %83 = load ptr, ptr %9, align 8, !tbaa !5
  %84 = getelementptr inbounds %struct.CSzAr, ptr %83, i32 0, i32 8
  %85 = load ptr, ptr %84, align 8, !tbaa !26
  %86 = load ptr, ptr %9, align 8, !tbaa !5
  %87 = getelementptr inbounds %struct.CSzAr, ptr %86, i32 0, i32 6
  %88 = load ptr, ptr %87, align 8, !tbaa !27
  %89 = load i32, ptr %10, align 4, !tbaa !9
  %90 = zext i32 %89 to i64
  %91 = getelementptr inbounds i32, ptr %88, i64 %90
  %92 = load i32, ptr %91, align 4, !tbaa !9
  %93 = zext i32 %92 to i64
  %94 = getelementptr inbounds i64, ptr %85, i64 %93
  %95 = load ptr, ptr %9, align 8, !tbaa !5
  %96 = getelementptr inbounds %struct.CSzAr, ptr %95, i32 0, i32 2
  %97 = load ptr, ptr %96, align 8, !tbaa !28
  %98 = load ptr, ptr %9, align 8, !tbaa !5
  %99 = getelementptr inbounds %struct.CSzAr, ptr %98, i32 0, i32 5
  %100 = load ptr, ptr %99, align 8, !tbaa !29
  %101 = load i32, ptr %10, align 4, !tbaa !9
  %102 = zext i32 %101 to i64
  %103 = getelementptr inbounds i32, ptr %100, i64 %102
  %104 = load i32, ptr %103, align 4, !tbaa !9
  %105 = zext i32 %104 to i64
  %106 = getelementptr inbounds i64, ptr %97, i64 %105
  %107 = load ptr, ptr %11, align 8, !tbaa !5
  %108 = load i64, ptr %12, align 8, !tbaa !11
  %109 = load ptr, ptr %13, align 8, !tbaa !5
  %110 = load i64, ptr %14, align 8, !tbaa !13
  %111 = load ptr, ptr %15, align 8, !tbaa !5
  %112 = getelementptr inbounds [3 x ptr], ptr %22, i64 0, i64 0
  %113 = call i32 @SzFolder_Decode2(ptr noundef %17, ptr noundef %82, ptr noundef %94, ptr noundef %106, ptr noundef %107, i64 noundef %108, ptr noundef %109, i64 noundef %110, ptr noundef %111, ptr noundef %112)
  store i32 %113, ptr %16, align 4, !tbaa !9
  store i32 0, ptr %21, align 4, !tbaa !9
  br label %114

114:                                              ; preds = %126, %81
  %115 = load i32, ptr %21, align 4, !tbaa !9
  %116 = icmp ult i32 %115, 3
  br i1 %116, label %117, label %129

117:                                              ; preds = %114
  %118 = load ptr, ptr %15, align 8, !tbaa !5
  %119 = getelementptr inbounds %struct.ISzAlloc, ptr %118, i32 0, i32 1
  %120 = load ptr, ptr %119, align 8, !tbaa !30
  %121 = load ptr, ptr %15, align 8, !tbaa !5
  %122 = load i32, ptr %21, align 4, !tbaa !9
  %123 = zext i32 %122 to i64
  %124 = getelementptr inbounds [3 x ptr], ptr %22, i64 0, i64 %123
  %125 = load ptr, ptr %124, align 8, !tbaa !5
  call void %120(ptr noundef %121, ptr noundef %125)
  br label %126

126:                                              ; preds = %117
  %127 = load i32, ptr %21, align 4, !tbaa !9
  %128 = add i32 %127, 1
  store i32 %128, ptr %21, align 4, !tbaa !9
  br label %114, !llvm.loop !32

129:                                              ; preds = %114
  %130 = load i32, ptr %16, align 4, !tbaa !9
  %131 = icmp eq i32 %130, 0
  br i1 %131, label %132, label %170

132:                                              ; preds = %129
  %133 = load ptr, ptr %9, align 8, !tbaa !5
  %134 = getelementptr inbounds %struct.CSzAr, ptr %133, i32 0, i32 3
  %135 = getelementptr inbounds %struct.CSzBitUi32s, ptr %134, i32 0, i32 0
  %136 = load ptr, ptr %135, align 8, !tbaa !34
  %137 = icmp ne ptr %136, null
  br i1 %137, label %138, label %169

138:                                              ; preds = %132
  %139 = load ptr, ptr %9, align 8, !tbaa !5
  %140 = getelementptr inbounds %struct.CSzAr, ptr %139, i32 0, i32 3
  %141 = getelementptr inbounds %struct.CSzBitUi32s, ptr %140, i32 0, i32 0
  %142 = load ptr, ptr %141, align 8, !tbaa !34
  %143 = load i32, ptr %10, align 4, !tbaa !9
  %144 = lshr i32 %143, 3
  %145 = zext i32 %144 to i64
  %146 = getelementptr inbounds i8, ptr %142, i64 %145
  %147 = load i8, ptr %146, align 1, !tbaa !25
  %148 = zext i8 %147 to i32
  %149 = load i32, ptr %10, align 4, !tbaa !9
  %150 = and i32 %149, 7
  %151 = ashr i32 128, %150
  %152 = and i32 %148, %151
  %153 = icmp ne i32 %152, 0
  br i1 %153, label %154, label %169

154:                                              ; preds = %138
  %155 = load ptr, ptr %13, align 8, !tbaa !5
  %156 = load i64, ptr %14, align 8, !tbaa !13
  %157 = call i32 @CrcCalc(ptr noundef %155, i64 noundef %156)
  %158 = load ptr, ptr %9, align 8, !tbaa !5
  %159 = getelementptr inbounds %struct.CSzAr, ptr %158, i32 0, i32 3
  %160 = getelementptr inbounds %struct.CSzBitUi32s, ptr %159, i32 0, i32 1
  %161 = load ptr, ptr %160, align 8, !tbaa !35
  %162 = load i32, ptr %10, align 4, !tbaa !9
  %163 = zext i32 %162 to i64
  %164 = getelementptr inbounds i32, ptr %161, i64 %163
  %165 = load i32, ptr %164, align 4, !tbaa !9
  %166 = icmp ne i32 %157, %165
  br i1 %166, label %167, label %168

167:                                              ; preds = %154
  store i32 3, ptr %16, align 4, !tbaa !9
  br label %168

168:                                              ; preds = %167, %154
  br label %169

169:                                              ; preds = %168, %138, %132
  br label %170

170:                                              ; preds = %169, %129
  %171 = load i32, ptr %16, align 4, !tbaa !9
  store i32 %171, ptr %8, align 4
  store i32 1, ptr %20, align 4
  call void @llvm.lifetime.end.p0(i64 24, ptr %22) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #4
  br label %172

172:                                              ; preds = %170, %80, %56
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #4
  call void @llvm.lifetime.end.p0(i64 16, ptr %18) #4
  call void @llvm.lifetime.end.p0(i64 120, ptr %17) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #4
  %173 = load i32, ptr %8, align 4
  ret i32 %173
}

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

declare i32 @SzGetNextFolderItem(ptr noundef, ptr noundef) #2

declare i64 @SzAr_GetFolderUnpackSize(ptr noundef, i32 noundef) #2

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

; Function Attrs: nounwind uwtable
declare hidden i32 @SzFolder_Decode2(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, i64 noundef, ptr noundef, i64 noundef, ptr noundef, ptr noundef) #0

declare i32 @CrcCalc(ptr noundef, i64 noundef) #2

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

attributes #0 = { 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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { "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 #3 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #4 = { 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 = !{!"int", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"long long", !7, i64 0}
!13 = !{!14, !14, i64 0}
!14 = !{!"long", !7, i64 0}
!15 = !{!16, !6, i64 72}
!16 = !{!"", !10, i64 0, !10, i64 4, !6, i64 8, !17, i64 16, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72}
!17 = !{!"", !6, i64 0, !6, i64 8}
!18 = !{!16, !6, i64 32}
!19 = !{!20, !6, i64 0}
!20 = !{!"", !6, i64 0, !14, i64 8}
!21 = !{!20, !14, i64 8}
!22 = !{!23, !10, i64 12}
!23 = !{!"", !10, i64 0, !10, i64 4, !10, i64 8, !10, i64 12, !7, i64 16, !7, i64 32, !7, i64 56}
!24 = !{!16, !6, i64 56}
!25 = !{!7, !7, i64 0}
!26 = !{!16, !6, i64 64}
!27 = !{!16, !6, i64 48}
!28 = !{!16, !6, i64 8}
!29 = !{!16, !6, i64 40}
!30 = !{!31, !6, i64 8}
!31 = !{!"ISzAlloc", !6, i64 0, !6, i64 8}
!32 = distinct !{!32, !33}
!33 = !{!"llvm.loop.mustprogress"}
!34 = !{!16, !6, i64 16}
!35 = !{!16, !6, i64 24}


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

%struct.CSzFolder = type { i32, i32, i32, i32, [4 x i32], [3 x %struct.CSzBond], [4 x %struct.CSzCoderInfo] }
%struct.CSzBond = type { i32, i32 }
%struct.CSzCoderInfo = type { i64, i32, i8, i8 }
%struct.CSzData = type { ptr, i64 }

; Function Attrs: nounwind uwtable
define dso_local i32 @SzAr_DecodeFolder(ptr noundef %0, i32 noundef %1, ptr noundef %2, i64 noundef %3, ptr noundef %4, i64 noundef %5, ptr noundef %6) local_unnamed_addr #0 {
  %8 = alloca %struct.CSzFolder, align 8
  %9 = alloca %struct.CSzData, align 8
  %10 = alloca [3 x ptr], align 16
  call void @llvm.lifetime.start.p0(i64 120, ptr nonnull %8) #4
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %9) #4
  %11 = getelementptr inbounds i8, ptr %0, i64 72
  %12 = load ptr, ptr %11, align 8, !tbaa !5
  %13 = getelementptr inbounds i8, ptr %0, i64 32
  %14 = load ptr, ptr %13, align 8, !tbaa !12
  %15 = zext i32 %1 to i64
  %16 = getelementptr inbounds i64, ptr %14, i64 %15
  %17 = load i64, ptr %16, align 8, !tbaa !13
  %18 = getelementptr inbounds i8, ptr %12, i64 %17
  store ptr %18, ptr %9, align 8, !tbaa !15
  %19 = getelementptr inbounds i8, ptr %16, i64 8
  %20 = load i64, ptr %19, align 8, !tbaa !13
  %21 = sub i64 %20, %17
  %22 = getelementptr inbounds i8, ptr %9, i64 8
  store i64 %21, ptr %22, align 8, !tbaa !17
  %23 = call i32 @SzGetNextFolderItem(ptr noundef nonnull %8, ptr noundef nonnull %9) #4
  %.not = icmp eq i32 %23, 0
  br i1 %.not, label %24, label %83

24:                                               ; preds = %7
  %25 = load i64, ptr %22, align 8, !tbaa !17
  %.not48 = icmp eq i64 %25, 0
  br i1 %.not48, label %26, label %83

26:                                               ; preds = %24
  %27 = getelementptr inbounds i8, ptr %8, i64 12
  %28 = load i32, ptr %27, align 4, !tbaa !18
  %29 = getelementptr inbounds i8, ptr %0, i64 56
  %30 = load ptr, ptr %29, align 8, !tbaa !20
  %31 = getelementptr inbounds i8, ptr %30, i64 %15
  %32 = load i8, ptr %31, align 1, !tbaa !21
  %33 = zext i8 %32 to i32
  %.not49 = icmp eq i32 %28, %33
  br i1 %.not49, label %34, label %83

34:                                               ; preds = %26
  %35 = call i64 @SzAr_GetFolderUnpackSize(ptr noundef nonnull %0, i32 noundef %1) #4
  %.not50 = icmp eq i64 %35, %5
  br i1 %.not50, label %36, label %83

36:                                               ; preds = %34
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %10) #4
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(24) %10, i8 0, i64 24, i1 false)
  %37 = getelementptr inbounds i8, ptr %0, i64 64
  %38 = load ptr, ptr %37, align 8, !tbaa !22
  %39 = getelementptr inbounds i8, ptr %0, i64 48
  %40 = load ptr, ptr %39, align 8, !tbaa !23
  %41 = getelementptr inbounds i32, ptr %40, i64 %15
  %42 = load i32, ptr %41, align 4, !tbaa !24
  %43 = zext i32 %42 to i64
  %44 = getelementptr inbounds i64, ptr %38, i64 %43
  %45 = getelementptr inbounds i8, ptr %0, i64 8
  %46 = load ptr, ptr %45, align 8, !tbaa !25
  %47 = getelementptr inbounds i8, ptr %0, i64 40
  %48 = load ptr, ptr %47, align 8, !tbaa !26
  %49 = getelementptr inbounds i32, ptr %48, i64 %15
  %50 = load i32, ptr %49, align 4, !tbaa !24
  %51 = zext i32 %50 to i64
  %52 = getelementptr inbounds i64, ptr %46, i64 %51
  %53 = call i32 @SzFolder_Decode2(ptr noundef nonnull %8, ptr noundef %18, ptr noundef %44, ptr noundef %52, ptr noundef %2, i64 noundef %3, ptr noundef %4, i64 noundef %5, ptr noundef %6, ptr noundef nonnull %10)
  %54 = getelementptr inbounds i8, ptr %6, i64 8
  %55 = load ptr, ptr %54, align 8, !tbaa !27
  %56 = load ptr, ptr %10, align 16, !tbaa !29
  call void %55(ptr noundef %6, ptr noundef %56) #4
  %57 = load ptr, ptr %54, align 8, !tbaa !27
  %58 = getelementptr inbounds i8, ptr %10, i64 8
  %59 = load ptr, ptr %58, align 8, !tbaa !29
  call void %57(ptr noundef %6, ptr noundef %59) #4
  %60 = load ptr, ptr %54, align 8, !tbaa !27
  %61 = getelementptr inbounds i8, ptr %10, i64 16
  %62 = load ptr, ptr %61, align 16, !tbaa !29
  call void %60(ptr noundef %6, ptr noundef %62) #4
  %63 = icmp eq i32 %53, 0
  br i1 %63, label %64, label %82

64:                                               ; preds = %36
  %65 = getelementptr inbounds i8, ptr %0, i64 16
  %66 = load ptr, ptr %65, align 8, !tbaa !30
  %.not51 = icmp eq ptr %66, null
  br i1 %.not51, label %82, label %67

67:                                               ; preds = %64
  %68 = lshr i32 %1, 3
  %69 = zext nneg i32 %68 to i64
  %70 = getelementptr inbounds i8, ptr %66, i64 %69
  %71 = load i8, ptr %70, align 1, !tbaa !21
  %72 = zext i8 %71 to i32
  %73 = and i32 %1, 7
  %74 = lshr exact i32 128, %73
  %75 = and i32 %74, %72
  %.not52 = icmp eq i32 %75, 0
  br i1 %.not52, label %82, label %76

76:                                               ; preds = %67
  %77 = call i32 @CrcCalc(ptr noundef %4, i64 noundef %5) #4
  %78 = getelementptr inbounds i8, ptr %0, i64 24
  %79 = load ptr, ptr %78, align 8, !tbaa !31
  %80 = getelementptr inbounds i32, ptr %79, i64 %15
  %81 = load i32, ptr %80, align 4, !tbaa !24
  %.not53 = icmp eq i32 %77, %81
  %spec.select = select i1 %.not53, i32 0, i32 3
  br label %82

82:                                               ; preds = %76, %64, %67, %36
  %.043 = phi i32 [ 0, %67 ], [ 0, %64 ], [ %53, %36 ], [ %spec.select, %76 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %10) #4
  br label %83

83:                                               ; preds = %24, %26, %34, %7, %82
  %.042 = phi i32 [ %.043, %82 ], [ %23, %7 ], [ 11, %34 ], [ 11, %26 ], [ 11, %24 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %9) #4
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %8) #4
  ret i32 %.042
}

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

declare i32 @SzGetNextFolderItem(ptr noundef, ptr noundef) local_unnamed_addr #2

declare i64 @SzAr_GetFolderUnpackSize(ptr noundef, i32 noundef) local_unnamed_addr #2

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

; Function Attrs: nounwind uwtable
declare hidden i32 @SzFolder_Decode2(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, i64 noundef, ptr noundef, i64 noundef, ptr noundef, ptr noundef) local_unnamed_addr #0

declare i32 @CrcCalc(ptr noundef, i64 noundef) local_unnamed_addr #2

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

attributes #0 = { 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 #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { "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 #3 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #4 = { 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, !10, i64 72}
!6 = !{!"", !7, i64 0, !7, i64 4, !10, i64 8, !11, i64 16, !10, i64 32, !10, i64 40, !10, i64 48, !10, i64 56, !10, i64 64, !10, i64 72}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"any pointer", !8, i64 0}
!11 = !{!"", !10, i64 0, !10, i64 8}
!12 = !{!6, !10, i64 32}
!13 = !{!14, !14, i64 0}
!14 = !{!"long", !8, i64 0}
!15 = !{!16, !10, i64 0}
!16 = !{!"", !10, i64 0, !14, i64 8}
!17 = !{!16, !14, i64 8}
!18 = !{!19, !7, i64 12}
!19 = !{!"", !7, i64 0, !7, i64 4, !7, i64 8, !7, i64 12, !8, i64 16, !8, i64 32, !8, i64 56}
!20 = !{!6, !10, i64 56}
!21 = !{!8, !8, i64 0}
!22 = !{!6, !10, i64 64}
!23 = !{!6, !10, i64 48}
!24 = !{!7, !7, i64 0}
!25 = !{!6, !10, i64 8}
!26 = !{!6, !10, i64 40}
!27 = !{!28, !10, i64 8}
!28 = !{!"ISzAlloc", !10, i64 0, !10, i64 8}
!29 = !{!10, !10, i64 0}
!30 = !{!6, !10, i64 16}
!31 = !{!6, !10, i64 24}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,LICMPass,LoopRotatePass,ReassociatePass,SROAPass,SimplifyCFGPass