; LLVM IR from SSBMTonberry/pocketlzma :: ref_spec/lzma1900/CPP/7zip/Compress (XzEncoder)

; 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.tagPROPVARIANT = type { i16, i16, i16, i16, %union.anon }
%union.anon = type { %struct._LARGE_INTEGER }
%struct._LARGE_INTEGER = type { i64 }
%"class.NCompress::NXz::CEncoder" = type { %struct.ICompressCoder, %struct.ICompressSetCoderProperties, %struct.ICompressSetCoderPropertiesOpt, %class.CMyUnknownImp, ptr, %struct.CXzProps }
%struct.ICompressCoder = type { %struct.IUnknown }
%struct.IUnknown = type { ptr }
%struct.ICompressSetCoderProperties = type { %struct.IUnknown }
%struct.ICompressSetCoderPropertiesOpt = type { %struct.IUnknown }
%class.CMyUnknownImp = type { i32 }
%struct.CXzProps = type { %struct.CLzma2EncProps, %struct.CXzFilterProps, i32, i64, i32, i32, i32, i32, i64 }
%struct.CLzma2EncProps = type { %struct._CLzmaEncProps, i64, i32, i32, i32 }
%struct._CLzmaEncProps = type { i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i64 }
%struct.CXzFilterProps = type { i32, i32, i32, i32 }
%struct._ULARGE_INTEGER = type { i64 }

@.str = external hidden unnamed_addr constant [6 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN9NCompress3NXz8CEncoder12SetCheckSizeEj(ptr noundef nonnull align 8 dereferenceable(176), i32 noundef) #0 align 2

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

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

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_ZN9NCompress3NXz8CEncoder12SetCoderPropEjRK14tagPROPVARIANT(ptr noundef nonnull align 8 dereferenceable(176) %0, i32 noundef %1, ptr noundef nonnull align 8 dereferenceable(16) %2) #2 align 2 {
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  store ptr %0, ptr %5, align 8, !tbaa !5
  store i32 %1, ptr %6, align 4, !tbaa !9
  store ptr %2, ptr %7, align 8, !tbaa !5
  %16 = load ptr, ptr %5, align 8
  %17 = load i32, ptr %6, align 4, !tbaa !9
  %18 = icmp eq i32 %17, 13
  br i1 %18, label %19, label %32

19:                                               ; preds = %3
  %20 = load ptr, ptr %7, align 8, !tbaa !5
  %21 = getelementptr inbounds %struct.tagPROPVARIANT, ptr %20, i32 0, i32 0
  %22 = load i16, ptr %21, align 8, !tbaa !11
  %23 = zext i16 %22 to i32
  %24 = icmp ne i32 %23, 19
  br i1 %24, label %25, label %26

25:                                               ; preds = %19
  store i32 -2147024809, ptr %4, align 4
  br label %216

26:                                               ; preds = %19
  %27 = load ptr, ptr %7, align 8, !tbaa !5
  %28 = getelementptr inbounds %struct.tagPROPVARIANT, ptr %27, i32 0, i32 4
  %29 = load i32, ptr %28, align 8, !tbaa !14
  %30 = getelementptr inbounds %"class.NCompress::NXz::CEncoder", ptr %16, i32 0, i32 5
  %31 = getelementptr inbounds %struct.CXzProps, ptr %30, i32 0, i32 6
  store i32 %29, ptr %31, align 8, !tbaa !15
  store i32 0, ptr %4, align 4
  br label %216

32:                                               ; preds = %3
  %33 = load i32, ptr %6, align 4, !tbaa !9
  %34 = icmp eq i32 %33, 19
  br i1 %34, label %35, label %47

35:                                               ; preds = %32
  %36 = load ptr, ptr %7, align 8, !tbaa !5
  %37 = getelementptr inbounds %struct.tagPROPVARIANT, ptr %36, i32 0, i32 0
  %38 = load i16, ptr %37, align 8, !tbaa !11
  %39 = zext i16 %38 to i32
  %40 = icmp ne i32 %39, 19
  br i1 %40, label %41, label %42

41:                                               ; preds = %35
  store i32 -2147024809, ptr %4, align 4
  br label %216

42:                                               ; preds = %35
  %43 = load ptr, ptr %7, align 8, !tbaa !5
  %44 = getelementptr inbounds %struct.tagPROPVARIANT, ptr %43, i32 0, i32 4
  %45 = load i32, ptr %44, align 8, !tbaa !14
  %46 = call noundef i32 @_ZN9NCompress3NXz8CEncoder12SetCheckSizeEj(ptr noundef nonnull align 8 dereferenceable(176) %16, i32 noundef %45)
  store i32 %46, ptr %4, align 4
  br label %216

47:                                               ; preds = %32
  %48 = load i32, ptr %6, align 4, !tbaa !9
  %49 = icmp eq i32 %48, 18
  br i1 %49, label %50, label %79

50:                                               ; preds = %47
  %51 = load ptr, ptr %7, align 8, !tbaa !5
  %52 = getelementptr inbounds %struct.tagPROPVARIANT, ptr %51, i32 0, i32 0
  %53 = load i16, ptr %52, align 8, !tbaa !11
  %54 = zext i16 %53 to i32
  %55 = icmp eq i32 %54, 19
  br i1 %55, label %56, label %63

56:                                               ; preds = %50
  %57 = load ptr, ptr %7, align 8, !tbaa !5
  %58 = getelementptr inbounds %struct.tagPROPVARIANT, ptr %57, i32 0, i32 4
  %59 = load i32, ptr %58, align 8, !tbaa !14
  %60 = zext i32 %59 to i64
  %61 = getelementptr inbounds %"class.NCompress::NXz::CEncoder", ptr %16, i32 0, i32 5
  %62 = getelementptr inbounds %struct.CXzProps, ptr %61, i32 0, i32 3
  store i64 %60, ptr %62, align 8, !tbaa !27
  br label %78

63:                                               ; preds = %50
  %64 = load ptr, ptr %7, align 8, !tbaa !5
  %65 = getelementptr inbounds %struct.tagPROPVARIANT, ptr %64, i32 0, i32 0
  %66 = load i16, ptr %65, align 8, !tbaa !11
  %67 = zext i16 %66 to i32
  %68 = icmp eq i32 %67, 21
  br i1 %68, label %69, label %76

69:                                               ; preds = %63
  %70 = load ptr, ptr %7, align 8, !tbaa !5
  %71 = getelementptr inbounds %struct.tagPROPVARIANT, ptr %70, i32 0, i32 4
  %72 = getelementptr inbounds %struct._ULARGE_INTEGER, ptr %71, i32 0, i32 0
  %73 = load i64, ptr %72, align 8, !tbaa !14
  %74 = getelementptr inbounds %"class.NCompress::NXz::CEncoder", ptr %16, i32 0, i32 5
  %75 = getelementptr inbounds %struct.CXzProps, ptr %74, i32 0, i32 3
  store i64 %73, ptr %75, align 8, !tbaa !27
  br label %77

76:                                               ; preds = %63
  store i32 -2147024809, ptr %4, align 4
  br label %216

77:                                               ; preds = %69
  br label %78

78:                                               ; preds = %77, %56
  store i32 0, ptr %4, align 4
  br label %216

79:                                               ; preds = %47
  %80 = load i32, ptr %6, align 4, !tbaa !9
  %81 = icmp eq i32 %80, 16
  br i1 %81, label %82, label %97

82:                                               ; preds = %79
  %83 = load ptr, ptr %7, align 8, !tbaa !5
  %84 = getelementptr inbounds %struct.tagPROPVARIANT, ptr %83, i32 0, i32 0
  %85 = load i16, ptr %84, align 8, !tbaa !11
  %86 = zext i16 %85 to i32
  %87 = icmp eq i32 %86, 21
  br i1 %87, label %88, label %95

88:                                               ; preds = %82
  %89 = load ptr, ptr %7, align 8, !tbaa !5
  %90 = getelementptr inbounds %struct.tagPROPVARIANT, ptr %89, i32 0, i32 4
  %91 = getelementptr inbounds %struct._ULARGE_INTEGER, ptr %90, i32 0, i32 0
  %92 = load i64, ptr %91, align 8, !tbaa !14
  %93 = getelementptr inbounds %"class.NCompress::NXz::CEncoder", ptr %16, i32 0, i32 5
  %94 = getelementptr inbounds %struct.CXzProps, ptr %93, i32 0, i32 8
  store i64 %92, ptr %94, align 8, !tbaa !28
  br label %96

95:                                               ; preds = %82
  store i32 -2147024809, ptr %4, align 4
  br label %216

96:                                               ; preds = %88
  store i32 0, ptr %4, align 4
  br label %216

97:                                               ; preds = %79
  %98 = load i32, ptr %6, align 4, !tbaa !9
  %99 = icmp eq i32 %98, 20
  br i1 %99, label %100, label %210

100:                                              ; preds = %97
  %101 = load ptr, ptr %7, align 8, !tbaa !5
  %102 = getelementptr inbounds %struct.tagPROPVARIANT, ptr %101, i32 0, i32 0
  %103 = load i16, ptr %102, align 8, !tbaa !11
  %104 = zext i16 %103 to i32
  %105 = icmp eq i32 %104, 19
  br i1 %105, label %106, label %123

106:                                              ; preds = %100
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #5
  %107 = load ptr, ptr %7, align 8, !tbaa !5
  %108 = getelementptr inbounds %struct.tagPROPVARIANT, ptr %107, i32 0, i32 4
  %109 = load i32, ptr %108, align 8, !tbaa !14
  store i32 %109, ptr %8, align 4, !tbaa !9
  %110 = load i32, ptr %8, align 4, !tbaa !9
  %111 = icmp eq i32 %110, 3
  br i1 %111, label %112, label %113

112:                                              ; preds = %106
  store i32 -2147024809, ptr %4, align 4
  store i32 1, ptr %9, align 4
  br label %120

113:                                              ; preds = %106
  %114 = load ptr, ptr %7, align 8, !tbaa !5
  %115 = getelementptr inbounds %struct.tagPROPVARIANT, ptr %114, i32 0, i32 4
  %116 = load i32, ptr %115, align 8, !tbaa !14
  %117 = getelementptr inbounds %"class.NCompress::NXz::CEncoder", ptr %16, i32 0, i32 5
  %118 = getelementptr inbounds %struct.CXzProps, ptr %117, i32 0, i32 1
  %119 = getelementptr inbounds %struct.CXzFilterProps, ptr %118, i32 0, i32 0
  store i32 %116, ptr %119, align 8, !tbaa !29
  store i32 0, ptr %9, align 4
  br label %120

120:                                              ; preds = %113, %112
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #5
  %121 = load i32, ptr %9, align 4
  switch i32 %121, label %218 [
    i32 0, label %122
    i32 1, label %216
  ]

122:                                              ; preds = %120
  br label %209

123:                                              ; preds = %100
  %124 = load ptr, ptr %7, align 8, !tbaa !5
  %125 = getelementptr inbounds %struct.tagPROPVARIANT, ptr %124, i32 0, i32 0
  %126 = load i16, ptr %125, align 8, !tbaa !11
  %127 = zext i16 %126 to i32
  %128 = icmp ne i32 %127, 8
  br i1 %128, label %129, label %130

129:                                              ; preds = %123
  store i32 -2147024809, ptr %4, align 4
  br label %216

130:                                              ; preds = %123
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #5
  %131 = load ptr, ptr %7, align 8, !tbaa !5
  %132 = getelementptr inbounds %struct.tagPROPVARIANT, ptr %131, i32 0, i32 4
  %133 = load ptr, ptr %132, align 8, !tbaa !14
  store ptr %133, ptr %10, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #5
  %134 = load ptr, ptr %10, align 8, !tbaa !5
  %135 = call noundef i32 @_Z21ConvertStringToUInt32PKwPS0_(ptr noundef %134, ptr noundef %11) #5
  store i32 %135, ptr %12, align 4, !tbaa !9
  %136 = load ptr, ptr %11, align 8, !tbaa !5
  %137 = load ptr, ptr %10, align 8, !tbaa !5
  %138 = icmp ne ptr %136, %137
  br i1 %138, label %139, label %141

139:                                              ; preds = %130
  %140 = load ptr, ptr %11, align 8, !tbaa !5
  store ptr %140, ptr %10, align 8, !tbaa !5
  br label %161

141:                                              ; preds = %130
  %142 = load ptr, ptr %10, align 8, !tbaa !5
  %143 = call noundef zeroext i1 @_Z39IsString1PrefixedByString2_NoCase_AsciiPKwPKc(ptr noundef %142, ptr noundef @.str) #5
  br i1 %143, label %144, label %147

144:                                              ; preds = %141
  %145 = load ptr, ptr %10, align 8, !tbaa !5
  %146 = getelementptr inbounds i32, ptr %145, i64 5
  store ptr %146, ptr %10, align 8, !tbaa !5
  store i32 3, ptr %12, align 4, !tbaa !9
  br label %160

147:                                              ; preds = %141
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #5
  %148 = load ptr, ptr %7, align 8, !tbaa !5
  %149 = getelementptr inbounds %struct.tagPROPVARIANT, ptr %148, i32 0, i32 4
  %150 = load ptr, ptr %149, align 8, !tbaa !14
  %151 = call noundef i32 @_ZN9NCompress3NXzL16FilterIdFromNameEPKw(ptr noundef %150)
  store i32 %151, ptr %13, align 4, !tbaa !9
  %152 = load i32, ptr %13, align 4, !tbaa !9
  %153 = icmp slt i32 %152, 0
  br i1 %153, label %154, label %155

154:                                              ; preds = %147
  store i32 -2147024809, ptr %4, align 4
  store i32 1, ptr %9, align 4
  br label %157

155:                                              ; preds = %147
  %156 = load i32, ptr %13, align 4, !tbaa !9
  store i32 %156, ptr %12, align 4, !tbaa !9
  store i32 0, ptr %9, align 4
  br label %157

157:                                              ; preds = %155, %154
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #5
  %158 = load i32, ptr %9, align 4
  switch i32 %158, label %206 [
    i32 0, label %159
  ]

159:                                              ; preds = %157
  br label %160

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

161:                                              ; preds = %160, %139
  %162 = load i32, ptr %12, align 4, !tbaa !9
  %163 = icmp eq i32 %162, 3
  br i1 %163, label %164, label %201

164:                                              ; preds = %161
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #5
  %165 = load ptr, ptr %10, align 8, !tbaa !5
  %166 = load i32, ptr %165, align 4, !tbaa !30
  store i32 %166, ptr %14, align 4, !tbaa !30
  %167 = load i32, ptr %14, align 4, !tbaa !30
  %168 = icmp ne i32 %167, 45
  br i1 %168, label %169, label %173

169:                                              ; preds = %164
  %170 = load i32, ptr %14, align 4, !tbaa !30
  %171 = icmp ne i32 %170, 58
  br i1 %171, label %172, label %173

172:                                              ; preds = %169
  store i32 -2147024809, ptr %4, align 4
  store i32 1, ptr %9, align 4
  br label %198

173:                                              ; preds = %169, %164
  %174 = load ptr, ptr %10, align 8, !tbaa !5
  %175 = getelementptr inbounds i32, ptr %174, i32 1
  store ptr %175, ptr %10, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #5
  %176 = load ptr, ptr %10, align 8, !tbaa !5
  %177 = call noundef i32 @_Z21ConvertStringToUInt32PKwPS0_(ptr noundef %176, ptr noundef %11) #5
  store i32 %177, ptr %15, align 4, !tbaa !9
  %178 = load ptr, ptr %11, align 8, !tbaa !5
  %179 = load ptr, ptr %10, align 8, !tbaa !5
  %180 = icmp eq ptr %178, %179
  br i1 %180, label %191, label %181

181:                                              ; preds = %173
  %182 = load ptr, ptr %11, align 8, !tbaa !5
  %183 = load i32, ptr %182, align 4, !tbaa !30
  %184 = icmp ne i32 %183, 0
  br i1 %184, label %191, label %185

185:                                              ; preds = %181
  %186 = load i32, ptr %15, align 4, !tbaa !9
  %187 = icmp eq i32 %186, 0
  br i1 %187, label %191, label %188

188:                                              ; preds = %185
  %189 = load i32, ptr %15, align 4, !tbaa !9
  %190 = icmp ugt i32 %189, 256
  br i1 %190, label %191, label %192

191:                                              ; preds = %188, %185, %181, %173
  store i32 -2147024809, ptr %4, align 4
  store i32 1, ptr %9, align 4
  br label %197

192:                                              ; preds = %188
  %193 = load i32, ptr %15, align 4, !tbaa !9
  %194 = getelementptr inbounds %"class.NCompress::NXz::CEncoder", ptr %16, i32 0, i32 5
  %195 = getelementptr inbounds %struct.CXzProps, ptr %194, i32 0, i32 1
  %196 = getelementptr inbounds %struct.CXzFilterProps, ptr %195, i32 0, i32 1
  store i32 %193, ptr %196, align 4, !tbaa !32
  store i32 0, ptr %9, align 4
  br label %197

197:                                              ; preds = %192, %191
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #5
  br label %198

198:                                              ; preds = %197, %172
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  %199 = load i32, ptr %9, align 4
  switch i32 %199, label %206 [
    i32 0, label %200
  ]

200:                                              ; preds = %198
  br label %201

201:                                              ; preds = %200, %161
  %202 = load i32, ptr %12, align 4, !tbaa !9
  %203 = getelementptr inbounds %"class.NCompress::NXz::CEncoder", ptr %16, i32 0, i32 5
  %204 = getelementptr inbounds %struct.CXzProps, ptr %203, i32 0, i32 1
  %205 = getelementptr inbounds %struct.CXzFilterProps, ptr %204, i32 0, i32 0
  store i32 %202, ptr %205, align 8, !tbaa !29
  store i32 0, ptr %9, align 4
  br label %206

206:                                              ; preds = %201, %198, %157
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  %207 = load i32, ptr %9, align 4
  switch i32 %207, label %218 [
    i32 0, label %208
    i32 1, label %216
  ]

208:                                              ; preds = %206
  br label %209

209:                                              ; preds = %208, %122
  store i32 0, ptr %4, align 4
  br label %216

210:                                              ; preds = %97
  %211 = load i32, ptr %6, align 4, !tbaa !9
  %212 = load ptr, ptr %7, align 8, !tbaa !5
  %213 = getelementptr inbounds %"class.NCompress::NXz::CEncoder", ptr %16, i32 0, i32 5
  %214 = getelementptr inbounds %struct.CXzProps, ptr %213, i32 0, i32 0
  %215 = call noundef i32 @_ZN9NCompress6NLzma212SetLzma2PropEjRK14tagPROPVARIANTR14CLzma2EncProps(i32 noundef %211, ptr noundef nonnull align 8 dereferenceable(16) %212, ptr noundef nonnull align 8 dereferenceable(80) %214)
  store i32 %215, ptr %4, align 4
  br label %216

216:                                              ; preds = %210, %209, %206, %129, %120, %96, %95, %78, %76, %42, %41, %26, %25
  %217 = load i32, ptr %4, align 4
  ret i32 %217

218:                                              ; preds = %206, %120
  unreachable
}

; Function Attrs: nounwind
declare noundef i32 @_Z21ConvertStringToUInt32PKwPS0_(ptr noundef, ptr noundef) #3

; Function Attrs: nounwind
declare noundef zeroext i1 @_Z39IsString1PrefixedByString2_NoCase_AsciiPKwPKc(ptr noundef, ptr noundef) #3

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef i32 @_ZN9NCompress3NXzL16FilterIdFromNameEPKw(ptr noundef) #0

declare noundef i32 @_ZN9NCompress6NLzma212SetLzma2PropEjRK14tagPROPVARIANTR14CLzma2EncProps(i32 noundef, ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(80)) #4

attributes #0 = { mustprogress 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 = { 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 #3 = { 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 = { "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 }

!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 = !{!"int", !7, i64 0}
!11 = !{!12, !13, i64 0}
!12 = !{!"_ZTS14tagPROPVARIANT", !13, i64 0, !13, i64 2, !13, i64 4, !13, i64 6, !7, i64 8}
!13 = !{!"short", !7, i64 0}
!14 = !{!7, !7, i64 0}
!15 = !{!16, !10, i64 160}
!16 = !{!"_ZTSN9NCompress3NXz8CEncoderE", !17, i64 0, !19, i64 8, !20, i64 16, !21, i64 24, !6, i64 32, !22, i64 40}
!17 = !{!"_ZTS14ICompressCoder", !18, i64 0}
!18 = !{!"_ZTS8IUnknown"}
!19 = !{!"_ZTS27ICompressSetCoderProperties", !18, i64 0}
!20 = !{!"_ZTS30ICompressSetCoderPropertiesOpt", !18, i64 0}
!21 = !{!"_ZTS13CMyUnknownImp", !10, i64 0}
!22 = !{!"_ZTS8CXzProps", !23, i64 0, !26, i64 80, !10, i64 96, !25, i64 104, !10, i64 112, !10, i64 116, !10, i64 120, !10, i64 124, !25, i64 128}
!23 = !{!"_ZTS14CLzma2EncProps", !24, i64 0, !25, i64 56, !10, i64 64, !10, i64 68, !10, i64 72}
!24 = !{!"_ZTS14_CLzmaEncProps", !10, i64 0, !10, i64 4, !10, i64 8, !10, i64 12, !10, i64 16, !10, i64 20, !10, i64 24, !10, i64 28, !10, i64 32, !10, i64 36, !10, i64 40, !10, i64 44, !25, i64 48}
!25 = !{!"long long", !7, i64 0}
!26 = !{!"_ZTS14CXzFilterProps", !10, i64 0, !10, i64 4, !10, i64 8, !10, i64 12}
!27 = !{!16, !25, i64 144}
!28 = !{!16, !25, i64 168}
!29 = !{!16, !10, i64 120}
!30 = !{!31, !31, i64 0}
!31 = !{!"wchar_t", !7, i64 0}
!32 = !{!16, !10, i64 124}


; 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 [6 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN9NCompress3NXz8CEncoder12SetCheckSizeEj(ptr noundef nonnull align 8 dereferenceable(176), i32 noundef) local_unnamed_addr #0 align 2

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

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

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_ZN9NCompress3NXz8CEncoder12SetCoderPropEjRK14tagPROPVARIANT(ptr noundef nonnull align 8 dereferenceable(176) %0, i32 noundef %1, ptr noundef nonnull align 8 dereferenceable(16) %2) local_unnamed_addr #2 align 2 {
  %4 = alloca ptr, align 8
  switch i32 %1, label %71 [
    i32 13, label %5
    i32 19, label %11
    i32 18, label %17
    i32 16, label %28
    i32 20, label %35
  ]

5:                                                ; preds = %3
  %6 = load i16, ptr %2, align 8, !tbaa !5
  %.not70 = icmp eq i16 %6, 19
  br i1 %.not70, label %7, label %74

7:                                                ; preds = %5
  %8 = getelementptr inbounds i8, ptr %2, i64 8
  %9 = load i32, ptr %8, align 8, !tbaa !10
  %10 = getelementptr inbounds i8, ptr %0, i64 160
  store i32 %9, ptr %10, align 8, !tbaa !11
  br label %74

11:                                               ; preds = %3
  %12 = load i16, ptr %2, align 8, !tbaa !5
  %.not69 = icmp eq i16 %12, 19
  br i1 %.not69, label %13, label %74

13:                                               ; preds = %11
  %14 = getelementptr inbounds i8, ptr %2, i64 8
  %15 = load i32, ptr %14, align 8, !tbaa !10
  %16 = tail call noundef i32 @_ZN9NCompress3NXz8CEncoder12SetCheckSizeEj(ptr noundef nonnull align 8 dereferenceable(176) %0, i32 noundef %15)
  br label %74

17:                                               ; preds = %3
  %18 = load i16, ptr %2, align 8, !tbaa !5
  switch i16 %18, label %74 [
    i16 19, label %19
    i16 21, label %24
  ]

19:                                               ; preds = %17
  %20 = getelementptr inbounds i8, ptr %2, i64 8
  %21 = load i32, ptr %20, align 8, !tbaa !10
  %22 = zext i32 %21 to i64
  %23 = getelementptr inbounds i8, ptr %0, i64 144
  store i64 %22, ptr %23, align 8, !tbaa !25
  br label %74

24:                                               ; preds = %17
  %25 = getelementptr inbounds i8, ptr %2, i64 8
  %26 = load i64, ptr %25, align 8, !tbaa !10
  %27 = getelementptr inbounds i8, ptr %0, i64 144
  store i64 %26, ptr %27, align 8, !tbaa !25
  br label %74

28:                                               ; preds = %3
  %29 = load i16, ptr %2, align 8, !tbaa !5
  %30 = icmp eq i16 %29, 21
  br i1 %30, label %31, label %74

31:                                               ; preds = %28
  %32 = getelementptr inbounds i8, ptr %2, i64 8
  %33 = load i64, ptr %32, align 8, !tbaa !10
  %34 = getelementptr inbounds i8, ptr %0, i64 168
  store i64 %33, ptr %34, align 8, !tbaa !26
  br label %74

35:                                               ; preds = %3
  %36 = load i16, ptr %2, align 8, !tbaa !5
  switch i16 %36, label %74 [
    i16 19, label %37
    i16 8, label %42
  ]

37:                                               ; preds = %35
  %38 = getelementptr inbounds i8, ptr %2, i64 8
  %39 = load i32, ptr %38, align 8, !tbaa !10
  %40 = icmp eq i32 %39, 3
  br i1 %40, label %74, label %.thread

.thread:                                          ; preds = %37
  %41 = getelementptr inbounds i8, ptr %0, i64 120
  store i32 %39, ptr %41, align 8, !tbaa !27
  br label %74

42:                                               ; preds = %35
  %43 = getelementptr inbounds i8, ptr %2, i64 8
  %44 = load ptr, ptr %43, align 8, !tbaa !10
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #5
  %45 = call noundef i32 @_Z21ConvertStringToUInt32PKwPS0_(ptr noundef %44, ptr noundef nonnull %4) #5
  %46 = load ptr, ptr %4, align 8, !tbaa !28
  %.not68 = icmp eq ptr %46, %44
  br i1 %.not68, label %47, label %54

47:                                               ; preds = %42
  %48 = call noundef zeroext i1 @_Z39IsString1PrefixedByString2_NoCase_AsciiPKwPKc(ptr noundef %44, ptr noundef nonnull @.str) #5
  br i1 %48, label %.thread73, label %50

.thread73:                                        ; preds = %47
  %49 = getelementptr inbounds i8, ptr %44, i64 20
  br label %56

50:                                               ; preds = %47
  %51 = load ptr, ptr %43, align 8, !tbaa !10
  %52 = call noundef i32 @_ZN9NCompress3NXzL16FilterIdFromNameEPKw(ptr noundef %51)
  %53 = icmp sgt i32 %52, -1
  br i1 %53, label %54, label %.critedge.thread

54:                                               ; preds = %42, %50
  %.159 = phi i32 [ %52, %50 ], [ %45, %42 ]
  %.057 = phi ptr [ %44, %50 ], [ %46, %42 ]
  %55 = icmp eq i32 %.159, 3
  br i1 %55, label %56, label %.critedge

56:                                               ; preds = %.thread73, %54
  %.05778 = phi ptr [ %49, %.thread73 ], [ %.057, %54 ]
  %57 = load i32, ptr %.05778, align 4, !tbaa !29
  switch i32 %57, label %.critedge.thread [
    i32 58, label %58
    i32 45, label %58
  ]

58:                                               ; preds = %56, %56
  %59 = getelementptr inbounds i8, ptr %.05778, i64 4
  %60 = call noundef i32 @_Z21ConvertStringToUInt32PKwPS0_(ptr noundef nonnull %59, ptr noundef nonnull %4) #5
  %61 = load ptr, ptr %4, align 8, !tbaa !28
  %62 = icmp eq ptr %61, %59
  br i1 %62, label %.critedge.thread, label %63

63:                                               ; preds = %58
  %64 = load i32, ptr %61, align 4, !tbaa !29
  %65 = icmp ne i32 %64, 0
  %66 = add i32 %60, -257
  %67 = icmp ult i32 %66, -256
  %or.cond6 = or i1 %67, %65
  br i1 %or.cond6, label %.critedge.thread, label %68

68:                                               ; preds = %63
  %69 = getelementptr inbounds i8, ptr %0, i64 124
  store i32 %60, ptr %69, align 4, !tbaa !31
  br label %.critedge

.critedge.thread:                                 ; preds = %50, %58, %63, %56
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #5
  br label %74

.critedge:                                        ; preds = %54, %68
  %.15976 = phi i32 [ 3, %68 ], [ %.159, %54 ]
  %70 = getelementptr inbounds i8, ptr %0, i64 120
  store i32 %.15976, ptr %70, align 8, !tbaa !27
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #5
  br label %74

71:                                               ; preds = %3
  %72 = getelementptr inbounds i8, ptr %0, i64 40
  %73 = tail call noundef i32 @_ZN9NCompress6NLzma212SetLzma2PropEjRK14tagPROPVARIANTR14CLzma2EncProps(i32 noundef %1, ptr noundef nonnull align 8 dereferenceable(16) %2, ptr noundef nonnull align 8 dereferenceable(80) %72)
  br label %74

74:                                               ; preds = %.thread, %.critedge, %.critedge.thread, %37, %35, %28, %19, %24, %17, %11, %5, %71, %31, %13, %7
  %.7 = phi i32 [ 0, %7 ], [ %16, %13 ], [ 0, %31 ], [ %73, %71 ], [ -2147024809, %5 ], [ -2147024809, %11 ], [ -2147024809, %17 ], [ 0, %24 ], [ 0, %19 ], [ -2147024809, %28 ], [ -2147024809, %35 ], [ -2147024809, %37 ], [ -2147024809, %.critedge.thread ], [ 0, %.critedge ], [ 0, %.thread ]
  ret i32 %.7
}

; Function Attrs: nounwind
declare noundef i32 @_Z21ConvertStringToUInt32PKwPS0_(ptr noundef, ptr noundef) local_unnamed_addr #3

; Function Attrs: nounwind
declare noundef zeroext i1 @_Z39IsString1PrefixedByString2_NoCase_AsciiPKwPKc(ptr noundef, ptr noundef) local_unnamed_addr #3

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef i32 @_ZN9NCompress3NXzL16FilterIdFromNameEPKw(ptr noundef) local_unnamed_addr #0

declare noundef i32 @_ZN9NCompress6NLzma212SetLzma2PropEjRK14tagPROPVARIANTR14CLzma2EncProps(i32 noundef, ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(80)) local_unnamed_addr #4

attributes #0 = { mustprogress 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 = { 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 #3 = { 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 = { "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 }

!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 0}
!6 = !{!"_ZTS14tagPROPVARIANT", !7, i64 0, !7, i64 2, !7, i64 4, !7, i64 6, !8, i64 8}
!7 = !{!"short", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!8, !8, i64 0}
!11 = !{!12, !18, i64 160}
!12 = !{!"_ZTSN9NCompress3NXz8CEncoderE", !13, i64 0, !15, i64 8, !16, i64 16, !17, i64 24, !19, i64 32, !20, i64 40}
!13 = !{!"_ZTS14ICompressCoder", !14, i64 0}
!14 = !{!"_ZTS8IUnknown"}
!15 = !{!"_ZTS27ICompressSetCoderProperties", !14, i64 0}
!16 = !{!"_ZTS30ICompressSetCoderPropertiesOpt", !14, i64 0}
!17 = !{!"_ZTS13CMyUnknownImp", !18, i64 0}
!18 = !{!"int", !8, i64 0}
!19 = !{!"any pointer", !8, i64 0}
!20 = !{!"_ZTS8CXzProps", !21, i64 0, !24, i64 80, !18, i64 96, !23, i64 104, !18, i64 112, !18, i64 116, !18, i64 120, !18, i64 124, !23, i64 128}
!21 = !{!"_ZTS14CLzma2EncProps", !22, i64 0, !23, i64 56, !18, i64 64, !18, i64 68, !18, i64 72}
!22 = !{!"_ZTS14_CLzmaEncProps", !18, i64 0, !18, i64 4, !18, i64 8, !18, i64 12, !18, i64 16, !18, i64 20, !18, i64 24, !18, i64 28, !18, i64 32, !18, i64 36, !18, i64 40, !18, i64 44, !23, i64 48}
!23 = !{!"long long", !8, i64 0}
!24 = !{!"_ZTS14CXzFilterProps", !18, i64 0, !18, i64 4, !18, i64 8, !18, i64 12}
!25 = !{!12, !23, i64 144}
!26 = !{!12, !23, i64 168}
!27 = !{!12, !18, i64 120}
!28 = !{!19, !19, i64 0}
!29 = !{!30, !30, i64 0}
!30 = !{!"wchar_t", !8, i64 0}
!31 = !{!12, !18, i64 124}


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