; LLVM IR from itchio/go-brotli :: enc (metablock)

; 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.MetaBlockSplit = type { %struct.BlockSplit, %struct.BlockSplit, %struct.BlockSplit, ptr, i64, ptr, i64, ptr, i64, ptr, i64, ptr, i64 }
%struct.BlockSplit = type { i64, i64, ptr, ptr, i64, i64 }
%struct.BrotliEncoderParams = type { i32, i32, i32, i32, i64, i32, %struct.BrotliHasherParams }
%struct.BrotliHasherParams = type { i32, i32, i32, i32, i32 }

; Function Attrs: nounwind uwtable
define hidden void @BrotliBuildMetaBlock(ptr noundef %0, ptr noundef %1, i64 noundef %2, i64 noundef %3, ptr noundef %4, i8 noundef zeroext %5, i8 noundef zeroext %6, ptr noundef %7, i64 noundef %8, i32 noundef %9, ptr noundef %10) #0 {
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca i64, align 8
  %15 = alloca i64, align 8
  %16 = alloca ptr, align 8
  %17 = alloca i8, align 1
  %18 = alloca i8, align 1
  %19 = alloca ptr, align 8
  %20 = alloca i64, align 8
  %21 = alloca i32, align 4
  %22 = alloca ptr, align 8
  %23 = alloca ptr, align 8
  %24 = alloca ptr, align 8
  %25 = alloca ptr, align 8
  %26 = alloca i64, align 8
  %27 = alloca i64, align 8
  %28 = alloca i64, align 8
  %29 = alloca i64, align 8
  %30 = alloca i64, align 8
  store ptr %0, ptr %12, align 8, !tbaa !5
  store ptr %1, ptr %13, align 8, !tbaa !5
  store i64 %2, ptr %14, align 8, !tbaa !9
  store i64 %3, ptr %15, align 8, !tbaa !9
  store ptr %4, ptr %16, align 8, !tbaa !5
  store i8 %5, ptr %17, align 1, !tbaa !11
  store i8 %6, ptr %18, align 1, !tbaa !11
  store ptr %7, ptr %19, align 8, !tbaa !5
  store i64 %8, ptr %20, align 8, !tbaa !9
  store i32 %9, ptr %21, align 4, !tbaa !12
  store ptr %10, ptr %22, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #4
  store ptr null, ptr %25, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %27) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %29) #4
  store i64 1, ptr %29, align 8, !tbaa !9
  %31 = load ptr, ptr %12, align 8, !tbaa !5
  %32 = load ptr, ptr %19, align 8, !tbaa !5
  %33 = load i64, ptr %20, align 8, !tbaa !9
  %34 = load ptr, ptr %13, align 8, !tbaa !5
  %35 = load i64, ptr %14, align 8, !tbaa !9
  %36 = load i64, ptr %15, align 8, !tbaa !9
  %37 = load ptr, ptr %16, align 8, !tbaa !5
  %38 = load ptr, ptr %22, align 8, !tbaa !5
  %39 = getelementptr inbounds %struct.MetaBlockSplit, ptr %38, i32 0, i32 0
  %40 = load ptr, ptr %22, align 8, !tbaa !5
  %41 = getelementptr inbounds %struct.MetaBlockSplit, ptr %40, i32 0, i32 1
  %42 = load ptr, ptr %22, align 8, !tbaa !5
  %43 = getelementptr inbounds %struct.MetaBlockSplit, ptr %42, i32 0, i32 2
  call void @BrotliSplitBlock(ptr noundef %31, ptr noundef %32, i64 noundef %33, ptr noundef %34, i64 noundef %35, i64 noundef %36, ptr noundef %37, ptr noundef %39, ptr noundef %41, ptr noundef %43)
  %44 = load ptr, ptr %16, align 8, !tbaa !5
  %45 = getelementptr inbounds %struct.BrotliEncoderParams, ptr %44, i32 0, i32 5
  %46 = load i32, ptr %45, align 8, !tbaa !14
  %47 = icmp ne i32 %46, 0
  br i1 %47, label %81, label %48

48:                                               ; preds = %11
  store i64 64, ptr %29, align 8, !tbaa !9
  %49 = load ptr, ptr %22, align 8, !tbaa !5
  %50 = getelementptr inbounds %struct.MetaBlockSplit, ptr %49, i32 0, i32 0
  %51 = getelementptr inbounds %struct.BlockSplit, ptr %50, i32 0, i32 0
  %52 = load i64, ptr %51, align 8, !tbaa !17
  %53 = icmp ugt i64 %52, 0
  br i1 %53, label %54, label %62

54:                                               ; preds = %48
  %55 = load ptr, ptr %12, align 8, !tbaa !5
  %56 = load ptr, ptr %22, align 8, !tbaa !5
  %57 = getelementptr inbounds %struct.MetaBlockSplit, ptr %56, i32 0, i32 0
  %58 = getelementptr inbounds %struct.BlockSplit, ptr %57, i32 0, i32 0
  %59 = load i64, ptr %58, align 8, !tbaa !17
  %60 = mul i64 %59, 4
  %61 = call ptr @BrotliAllocate(ptr noundef %55, i64 noundef %60)
  br label %63

62:                                               ; preds = %48
  br label %63

63:                                               ; preds = %62, %54
  %64 = phi ptr [ %61, %54 ], [ null, %62 ]
  store ptr %64, ptr %25, align 8, !tbaa !5
  store i64 0, ptr %28, align 8, !tbaa !9
  br label %65

65:                                               ; preds = %77, %63
  %66 = load i64, ptr %28, align 8, !tbaa !9
  %67 = load ptr, ptr %22, align 8, !tbaa !5
  %68 = getelementptr inbounds %struct.MetaBlockSplit, ptr %67, i32 0, i32 0
  %69 = getelementptr inbounds %struct.BlockSplit, ptr %68, i32 0, i32 0
  %70 = load i64, ptr %69, align 8, !tbaa !17
  %71 = icmp ult i64 %66, %70
  br i1 %71, label %72, label %80

72:                                               ; preds = %65
  %73 = load i32, ptr %21, align 4, !tbaa !12
  %74 = load ptr, ptr %25, align 8, !tbaa !5
  %75 = load i64, ptr %28, align 8, !tbaa !9
  %76 = getelementptr inbounds i32, ptr %74, i64 %75
  store i32 %73, ptr %76, align 4, !tbaa !12
  br label %77

77:                                               ; preds = %72
  %78 = load i64, ptr %28, align 8, !tbaa !9
  %79 = add i64 %78, 1
  store i64 %79, ptr %28, align 8, !tbaa !9
  br label %65, !llvm.loop !20

80:                                               ; preds = %65
  br label %81

81:                                               ; preds = %80, %11
  %82 = load ptr, ptr %22, align 8, !tbaa !5
  %83 = getelementptr inbounds %struct.MetaBlockSplit, ptr %82, i32 0, i32 0
  %84 = getelementptr inbounds %struct.BlockSplit, ptr %83, i32 0, i32 0
  %85 = load i64, ptr %84, align 8, !tbaa !17
  %86 = load i64, ptr %29, align 8, !tbaa !9
  %87 = mul i64 %85, %86
  store i64 %87, ptr %26, align 8, !tbaa !9
  %88 = load i64, ptr %26, align 8, !tbaa !9
  %89 = icmp ugt i64 %88, 0
  br i1 %89, label %90, label %95

90:                                               ; preds = %81
  %91 = load ptr, ptr %12, align 8, !tbaa !5
  %92 = load i64, ptr %26, align 8, !tbaa !9
  %93 = mul i64 %92, 1040
  %94 = call ptr @BrotliAllocate(ptr noundef %91, i64 noundef %93)
  br label %96

95:                                               ; preds = %81
  br label %96

96:                                               ; preds = %95, %90
  %97 = phi ptr [ %94, %90 ], [ null, %95 ]
  store ptr %97, ptr %24, align 8, !tbaa !5
  %98 = load ptr, ptr %24, align 8, !tbaa !5
  %99 = load i64, ptr %26, align 8, !tbaa !9
  call void @ClearHistogramsLiteral(ptr noundef %98, i64 noundef %99)
  %100 = load ptr, ptr %22, align 8, !tbaa !5
  %101 = getelementptr inbounds %struct.MetaBlockSplit, ptr %100, i32 0, i32 2
  %102 = getelementptr inbounds %struct.BlockSplit, ptr %101, i32 0, i32 0
  %103 = load i64, ptr %102, align 8, !tbaa !22
  %104 = shl i64 %103, 2
  store i64 %104, ptr %27, align 8, !tbaa !9
  %105 = load i64, ptr %27, align 8, !tbaa !9
  %106 = icmp ugt i64 %105, 0
  br i1 %106, label %107, label %112

107:                                              ; preds = %96
  %108 = load ptr, ptr %12, align 8, !tbaa !5
  %109 = load i64, ptr %27, align 8, !tbaa !9
  %110 = mul i64 %109, 2096
  %111 = call ptr @BrotliAllocate(ptr noundef %108, i64 noundef %110)
  br label %113

112:                                              ; preds = %96
  br label %113

113:                                              ; preds = %112, %107
  %114 = phi ptr [ %111, %107 ], [ null, %112 ]
  store ptr %114, ptr %23, align 8, !tbaa !5
  %115 = load ptr, ptr %23, align 8, !tbaa !5
  %116 = load i64, ptr %27, align 8, !tbaa !9
  call void @ClearHistogramsDistance(ptr noundef %115, i64 noundef %116)
  %117 = load ptr, ptr %22, align 8, !tbaa !5
  %118 = getelementptr inbounds %struct.MetaBlockSplit, ptr %117, i32 0, i32 1
  %119 = getelementptr inbounds %struct.BlockSplit, ptr %118, i32 0, i32 0
  %120 = load i64, ptr %119, align 8, !tbaa !23
  %121 = load ptr, ptr %22, align 8, !tbaa !5
  %122 = getelementptr inbounds %struct.MetaBlockSplit, ptr %121, i32 0, i32 10
  store i64 %120, ptr %122, align 8, !tbaa !24
  %123 = load ptr, ptr %22, align 8, !tbaa !5
  %124 = getelementptr inbounds %struct.MetaBlockSplit, ptr %123, i32 0, i32 10
  %125 = load i64, ptr %124, align 8, !tbaa !24
  %126 = icmp ugt i64 %125, 0
  br i1 %126, label %127, label %134

127:                                              ; preds = %113
  %128 = load ptr, ptr %12, align 8, !tbaa !5
  %129 = load ptr, ptr %22, align 8, !tbaa !5
  %130 = getelementptr inbounds %struct.MetaBlockSplit, ptr %129, i32 0, i32 10
  %131 = load i64, ptr %130, align 8, !tbaa !24
  %132 = mul i64 %131, 2832
  %133 = call ptr @BrotliAllocate(ptr noundef %128, i64 noundef %132)
  br label %135

134:                                              ; preds = %113
  br label %135

135:                                              ; preds = %134, %127
  %136 = phi ptr [ %133, %127 ], [ null, %134 ]
  %137 = load ptr, ptr %22, align 8, !tbaa !5
  %138 = getelementptr inbounds %struct.MetaBlockSplit, ptr %137, i32 0, i32 9
  store ptr %136, ptr %138, align 8, !tbaa !25
  %139 = load ptr, ptr %22, align 8, !tbaa !5
  %140 = getelementptr inbounds %struct.MetaBlockSplit, ptr %139, i32 0, i32 9
  %141 = load ptr, ptr %140, align 8, !tbaa !25
  %142 = load ptr, ptr %22, align 8, !tbaa !5
  %143 = getelementptr inbounds %struct.MetaBlockSplit, ptr %142, i32 0, i32 10
  %144 = load i64, ptr %143, align 8, !tbaa !24
  call void @ClearHistogramsCommand(ptr noundef %141, i64 noundef %144)
  %145 = load ptr, ptr %19, align 8, !tbaa !5
  %146 = load i64, ptr %20, align 8, !tbaa !9
  %147 = load ptr, ptr %22, align 8, !tbaa !5
  %148 = getelementptr inbounds %struct.MetaBlockSplit, ptr %147, i32 0, i32 0
  %149 = load ptr, ptr %22, align 8, !tbaa !5
  %150 = getelementptr inbounds %struct.MetaBlockSplit, ptr %149, i32 0, i32 1
  %151 = load ptr, ptr %22, align 8, !tbaa !5
  %152 = getelementptr inbounds %struct.MetaBlockSplit, ptr %151, i32 0, i32 2
  %153 = load ptr, ptr %13, align 8, !tbaa !5
  %154 = load i64, ptr %14, align 8, !tbaa !9
  %155 = load i64, ptr %15, align 8, !tbaa !9
  %156 = load i8, ptr %17, align 1, !tbaa !11
  %157 = load i8, ptr %18, align 1, !tbaa !11
  %158 = load ptr, ptr %25, align 8, !tbaa !5
  %159 = load ptr, ptr %24, align 8, !tbaa !5
  %160 = load ptr, ptr %22, align 8, !tbaa !5
  %161 = getelementptr inbounds %struct.MetaBlockSplit, ptr %160, i32 0, i32 9
  %162 = load ptr, ptr %161, align 8, !tbaa !25
  %163 = load ptr, ptr %23, align 8, !tbaa !5
  call void @BrotliBuildHistogramsWithContext(ptr noundef %145, i64 noundef %146, ptr noundef %148, ptr noundef %150, ptr noundef %152, ptr noundef %153, i64 noundef %154, i64 noundef %155, i8 noundef zeroext %156, i8 noundef zeroext %157, ptr noundef %158, ptr noundef %159, ptr noundef %162, ptr noundef %163)
  %164 = load ptr, ptr %12, align 8, !tbaa !5
  %165 = load ptr, ptr %25, align 8, !tbaa !5
  call void @BrotliFree(ptr noundef %164, ptr noundef %165)
  store ptr null, ptr %25, align 8, !tbaa !5
  %166 = load ptr, ptr %22, align 8, !tbaa !5
  %167 = getelementptr inbounds %struct.MetaBlockSplit, ptr %166, i32 0, i32 0
  %168 = getelementptr inbounds %struct.BlockSplit, ptr %167, i32 0, i32 0
  %169 = load i64, ptr %168, align 8, !tbaa !17
  %170 = shl i64 %169, 6
  %171 = load ptr, ptr %22, align 8, !tbaa !5
  %172 = getelementptr inbounds %struct.MetaBlockSplit, ptr %171, i32 0, i32 4
  store i64 %170, ptr %172, align 8, !tbaa !26
  %173 = load ptr, ptr %22, align 8, !tbaa !5
  %174 = getelementptr inbounds %struct.MetaBlockSplit, ptr %173, i32 0, i32 4
  %175 = load i64, ptr %174, align 8, !tbaa !26
  %176 = icmp ugt i64 %175, 0
  br i1 %176, label %177, label %184

177:                                              ; preds = %135
  %178 = load ptr, ptr %12, align 8, !tbaa !5
  %179 = load ptr, ptr %22, align 8, !tbaa !5
  %180 = getelementptr inbounds %struct.MetaBlockSplit, ptr %179, i32 0, i32 4
  %181 = load i64, ptr %180, align 8, !tbaa !26
  %182 = mul i64 %181, 4
  %183 = call ptr @BrotliAllocate(ptr noundef %178, i64 noundef %182)
  br label %185

184:                                              ; preds = %135
  br label %185

185:                                              ; preds = %184, %177
  %186 = phi ptr [ %183, %177 ], [ null, %184 ]
  %187 = load ptr, ptr %22, align 8, !tbaa !5
  %188 = getelementptr inbounds %struct.MetaBlockSplit, ptr %187, i32 0, i32 3
  store ptr %186, ptr %188, align 8, !tbaa !27
  %189 = load ptr, ptr %22, align 8, !tbaa !5
  %190 = getelementptr inbounds %struct.MetaBlockSplit, ptr %189, i32 0, i32 4
  %191 = load i64, ptr %190, align 8, !tbaa !26
  %192 = load ptr, ptr %22, align 8, !tbaa !5
  %193 = getelementptr inbounds %struct.MetaBlockSplit, ptr %192, i32 0, i32 8
  store i64 %191, ptr %193, align 8, !tbaa !28
  %194 = load ptr, ptr %22, align 8, !tbaa !5
  %195 = getelementptr inbounds %struct.MetaBlockSplit, ptr %194, i32 0, i32 8
  %196 = load i64, ptr %195, align 8, !tbaa !28
  %197 = icmp ugt i64 %196, 0
  br i1 %197, label %198, label %205

198:                                              ; preds = %185
  %199 = load ptr, ptr %12, align 8, !tbaa !5
  %200 = load ptr, ptr %22, align 8, !tbaa !5
  %201 = getelementptr inbounds %struct.MetaBlockSplit, ptr %200, i32 0, i32 8
  %202 = load i64, ptr %201, align 8, !tbaa !28
  %203 = mul i64 %202, 1040
  %204 = call ptr @BrotliAllocate(ptr noundef %199, i64 noundef %203)
  br label %206

205:                                              ; preds = %185
  br label %206

206:                                              ; preds = %205, %198
  %207 = phi ptr [ %204, %198 ], [ null, %205 ]
  %208 = load ptr, ptr %22, align 8, !tbaa !5
  %209 = getelementptr inbounds %struct.MetaBlockSplit, ptr %208, i32 0, i32 7
  store ptr %207, ptr %209, align 8, !tbaa !29
  %210 = load ptr, ptr %12, align 8, !tbaa !5
  %211 = load ptr, ptr %24, align 8, !tbaa !5
  %212 = load i64, ptr %26, align 8, !tbaa !9
  %213 = load ptr, ptr %22, align 8, !tbaa !5
  %214 = getelementptr inbounds %struct.MetaBlockSplit, ptr %213, i32 0, i32 7
  %215 = load ptr, ptr %214, align 8, !tbaa !29
  %216 = load ptr, ptr %22, align 8, !tbaa !5
  %217 = getelementptr inbounds %struct.MetaBlockSplit, ptr %216, i32 0, i32 8
  %218 = load ptr, ptr %22, align 8, !tbaa !5
  %219 = getelementptr inbounds %struct.MetaBlockSplit, ptr %218, i32 0, i32 3
  %220 = load ptr, ptr %219, align 8, !tbaa !27
  call void @BrotliClusterHistogramsLiteral(ptr noundef %210, ptr noundef %211, i64 noundef %212, i64 noundef 256, ptr noundef %215, ptr noundef %217, ptr noundef %220)
  %221 = load ptr, ptr %12, align 8, !tbaa !5
  %222 = load ptr, ptr %24, align 8, !tbaa !5
  call void @BrotliFree(ptr noundef %221, ptr noundef %222)
  store ptr null, ptr %24, align 8, !tbaa !5
  %223 = load ptr, ptr %16, align 8, !tbaa !5
  %224 = getelementptr inbounds %struct.BrotliEncoderParams, ptr %223, i32 0, i32 5
  %225 = load i32, ptr %224, align 8, !tbaa !14
  %226 = icmp ne i32 %225, 0
  br i1 %226, label %227, label %261

227:                                              ; preds = %206
  %228 = load ptr, ptr %22, align 8, !tbaa !5
  %229 = getelementptr inbounds %struct.MetaBlockSplit, ptr %228, i32 0, i32 0
  %230 = getelementptr inbounds %struct.BlockSplit, ptr %229, i32 0, i32 0
  %231 = load i64, ptr %230, align 8, !tbaa !17
  store i64 %231, ptr %28, align 8, !tbaa !9
  br label %232

232:                                              ; preds = %259, %227
  %233 = load i64, ptr %28, align 8, !tbaa !9
  %234 = icmp ne i64 %233, 0
  br i1 %234, label %235, label %260

235:                                              ; preds = %232
  call void @llvm.lifetime.start.p0(i64 8, ptr %30) #4
  store i64 0, ptr %30, align 8, !tbaa !9
  %236 = load i64, ptr %28, align 8, !tbaa !9
  %237 = add i64 %236, -1
  store i64 %237, ptr %28, align 8, !tbaa !9
  br label %238

238:                                              ; preds = %256, %235
  %239 = load i64, ptr %30, align 8, !tbaa !9
  %240 = icmp ult i64 %239, 64
  br i1 %240, label %241, label %259

241:                                              ; preds = %238
  %242 = load ptr, ptr %22, align 8, !tbaa !5
  %243 = getelementptr inbounds %struct.MetaBlockSplit, ptr %242, i32 0, i32 3
  %244 = load ptr, ptr %243, align 8, !tbaa !27
  %245 = load i64, ptr %28, align 8, !tbaa !9
  %246 = getelementptr inbounds i32, ptr %244, i64 %245
  %247 = load i32, ptr %246, align 4, !tbaa !12
  %248 = load ptr, ptr %22, align 8, !tbaa !5
  %249 = getelementptr inbounds %struct.MetaBlockSplit, ptr %248, i32 0, i32 3
  %250 = load ptr, ptr %249, align 8, !tbaa !27
  %251 = load i64, ptr %28, align 8, !tbaa !9
  %252 = shl i64 %251, 6
  %253 = load i64, ptr %30, align 8, !tbaa !9
  %254 = add i64 %252, %253
  %255 = getelementptr inbounds i32, ptr %250, i64 %254
  store i32 %247, ptr %255, align 4, !tbaa !12
  br label %256

256:                                              ; preds = %241
  %257 = load i64, ptr %30, align 8, !tbaa !9
  %258 = add i64 %257, 1
  store i64 %258, ptr %30, align 8, !tbaa !9
  br label %238, !llvm.loop !30

259:                                              ; preds = %238
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #4
  br label %232, !llvm.loop !31

260:                                              ; preds = %232
  br label %261

261:                                              ; preds = %260, %206
  %262 = load ptr, ptr %22, align 8, !tbaa !5
  %263 = getelementptr inbounds %struct.MetaBlockSplit, ptr %262, i32 0, i32 2
  %264 = getelementptr inbounds %struct.BlockSplit, ptr %263, i32 0, i32 0
  %265 = load i64, ptr %264, align 8, !tbaa !22
  %266 = shl i64 %265, 2
  %267 = load ptr, ptr %22, align 8, !tbaa !5
  %268 = getelementptr inbounds %struct.MetaBlockSplit, ptr %267, i32 0, i32 6
  store i64 %266, ptr %268, align 8, !tbaa !32
  %269 = load ptr, ptr %22, align 8, !tbaa !5
  %270 = getelementptr inbounds %struct.MetaBlockSplit, ptr %269, i32 0, i32 6
  %271 = load i64, ptr %270, align 8, !tbaa !32
  %272 = icmp ugt i64 %271, 0
  br i1 %272, label %273, label %280

273:                                              ; preds = %261
  %274 = load ptr, ptr %12, align 8, !tbaa !5
  %275 = load ptr, ptr %22, align 8, !tbaa !5
  %276 = getelementptr inbounds %struct.MetaBlockSplit, ptr %275, i32 0, i32 6
  %277 = load i64, ptr %276, align 8, !tbaa !32
  %278 = mul i64 %277, 4
  %279 = call ptr @BrotliAllocate(ptr noundef %274, i64 noundef %278)
  br label %281

280:                                              ; preds = %261
  br label %281

281:                                              ; preds = %280, %273
  %282 = phi ptr [ %279, %273 ], [ null, %280 ]
  %283 = load ptr, ptr %22, align 8, !tbaa !5
  %284 = getelementptr inbounds %struct.MetaBlockSplit, ptr %283, i32 0, i32 5
  store ptr %282, ptr %284, align 8, !tbaa !33
  %285 = load ptr, ptr %22, align 8, !tbaa !5
  %286 = getelementptr inbounds %struct.MetaBlockSplit, ptr %285, i32 0, i32 6
  %287 = load i64, ptr %286, align 8, !tbaa !32
  %288 = load ptr, ptr %22, align 8, !tbaa !5
  %289 = getelementptr inbounds %struct.MetaBlockSplit, ptr %288, i32 0, i32 12
  store i64 %287, ptr %289, align 8, !tbaa !34
  %290 = load ptr, ptr %22, align 8, !tbaa !5
  %291 = getelementptr inbounds %struct.MetaBlockSplit, ptr %290, i32 0, i32 12
  %292 = load i64, ptr %291, align 8, !tbaa !34
  %293 = icmp ugt i64 %292, 0
  br i1 %293, label %294, label %301

294:                                              ; preds = %281
  %295 = load ptr, ptr %12, align 8, !tbaa !5
  %296 = load ptr, ptr %22, align 8, !tbaa !5
  %297 = getelementptr inbounds %struct.MetaBlockSplit, ptr %296, i32 0, i32 12
  %298 = load i64, ptr %297, align 8, !tbaa !34
  %299 = mul i64 %298, 2096
  %300 = call ptr @BrotliAllocate(ptr noundef %295, i64 noundef %299)
  br label %302

301:                                              ; preds = %281
  br label %302

302:                                              ; preds = %301, %294
  %303 = phi ptr [ %300, %294 ], [ null, %301 ]
  %304 = load ptr, ptr %22, align 8, !tbaa !5
  %305 = getelementptr inbounds %struct.MetaBlockSplit, ptr %304, i32 0, i32 11
  store ptr %303, ptr %305, align 8, !tbaa !35
  %306 = load ptr, ptr %12, align 8, !tbaa !5
  %307 = load ptr, ptr %23, align 8, !tbaa !5
  %308 = load ptr, ptr %22, align 8, !tbaa !5
  %309 = getelementptr inbounds %struct.MetaBlockSplit, ptr %308, i32 0, i32 6
  %310 = load i64, ptr %309, align 8, !tbaa !32
  %311 = load ptr, ptr %22, align 8, !tbaa !5
  %312 = getelementptr inbounds %struct.MetaBlockSplit, ptr %311, i32 0, i32 11
  %313 = load ptr, ptr %312, align 8, !tbaa !35
  %314 = load ptr, ptr %22, align 8, !tbaa !5
  %315 = getelementptr inbounds %struct.MetaBlockSplit, ptr %314, i32 0, i32 12
  %316 = load ptr, ptr %22, align 8, !tbaa !5
  %317 = getelementptr inbounds %struct.MetaBlockSplit, ptr %316, i32 0, i32 5
  %318 = load ptr, ptr %317, align 8, !tbaa !33
  call void @BrotliClusterHistogramsDistance(ptr noundef %306, ptr noundef %307, i64 noundef %310, i64 noundef 256, ptr noundef %313, ptr noundef %315, ptr noundef %318)
  %319 = load ptr, ptr %12, align 8, !tbaa !5
  %320 = load ptr, ptr %23, align 8, !tbaa !5
  call void @BrotliFree(ptr noundef %319, ptr noundef %320)
  store ptr null, ptr %23, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #4
  ret void
}

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

declare hidden void @BrotliSplitBlock(ptr noundef, ptr noundef, i64 noundef, ptr noundef, i64 noundef, i64 noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

declare hidden ptr @BrotliAllocate(ptr noundef, i64 noundef) #2

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @ClearHistogramsLiteral(ptr noundef, i64 noundef) #3

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @ClearHistogramsDistance(ptr noundef, i64 noundef) #3

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @ClearHistogramsCommand(ptr noundef, i64 noundef) #3

declare hidden void @BrotliBuildHistogramsWithContext(ptr noundef, i64 noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, i64 noundef, i64 noundef, i8 noundef zeroext, i8 noundef zeroext, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

declare hidden void @BrotliFree(ptr noundef, ptr noundef) #2

declare hidden void @BrotliClusterHistogramsLiteral(ptr noundef, ptr noundef, i64 noundef, i64 noundef, ptr noundef, ptr noundef, ptr noundef) #2

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

declare hidden void @BrotliClusterHistogramsDistance(ptr noundef, ptr noundef, i64 noundef, i64 noundef, ptr noundef, ptr noundef, ptr noundef) #2

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 = { alwaysinline 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 #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 = !{!"long", !7, i64 0}
!11 = !{!7, !7, i64 0}
!12 = !{!13, !13, i64 0}
!13 = !{!"int", !7, i64 0}
!14 = !{!15, !13, i64 24}
!15 = !{!"BrotliEncoderParams", !13, i64 0, !13, i64 4, !13, i64 8, !13, i64 12, !10, i64 16, !13, i64 24, !16, i64 28}
!16 = !{!"BrotliHasherParams", !13, i64 0, !13, i64 4, !13, i64 8, !13, i64 12, !13, i64 16}
!17 = !{!18, !10, i64 0}
!18 = !{!"MetaBlockSplit", !19, i64 0, !19, i64 48, !19, i64 96, !6, i64 144, !10, i64 152, !6, i64 160, !10, i64 168, !6, i64 176, !10, i64 184, !6, i64 192, !10, i64 200, !6, i64 208, !10, i64 216}
!19 = !{!"BlockSplit", !10, i64 0, !10, i64 8, !6, i64 16, !6, i64 24, !10, i64 32, !10, i64 40}
!20 = distinct !{!20, !21}
!21 = !{!"llvm.loop.mustprogress"}
!22 = !{!18, !10, i64 96}
!23 = !{!18, !10, i64 48}
!24 = !{!18, !10, i64 200}
!25 = !{!18, !6, i64 192}
!26 = !{!18, !10, i64 152}
!27 = !{!18, !6, i64 144}
!28 = !{!18, !10, i64 184}
!29 = !{!18, !6, i64 176}
!30 = distinct !{!30, !21}
!31 = distinct !{!31, !21}
!32 = !{!18, !10, i64 168}
!33 = !{!18, !6, i64 160}
!34 = !{!18, !10, i64 216}
!35 = !{!18, !6, i64 208}


; 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: nounwind uwtable
define hidden void @BrotliBuildMetaBlock(ptr noundef %0, ptr noundef %1, i64 noundef %2, i64 noundef %3, ptr noundef %4, i8 noundef zeroext %5, i8 noundef zeroext %6, ptr noundef %7, i64 noundef %8, i32 noundef %9, ptr noundef %10) local_unnamed_addr #0 {
  %12 = getelementptr inbounds i8, ptr %10, i64 48
  %13 = getelementptr inbounds i8, ptr %10, i64 96
  tail call void @BrotliSplitBlock(ptr noundef %0, ptr noundef %7, i64 noundef %8, ptr noundef %1, i64 noundef %2, i64 noundef %3, ptr noundef %4, ptr noundef %10, ptr noundef nonnull %12, ptr noundef nonnull %13) #3
  %14 = getelementptr inbounds i8, ptr %4, i64 24
  %15 = load i32, ptr %14, align 8, !tbaa !5
  %.not = icmp eq i32 %15, 0
  %.pre141 = load i64, ptr %10, align 8, !tbaa !12
  br i1 %.not, label %16, label %.loopexit133

16:                                               ; preds = %11
  %.not118 = icmp eq i64 %.pre141, 0
  br i1 %.not118, label %.loopexit133, label %17

17:                                               ; preds = %16
  %18 = shl i64 %.pre141, 2
  %19 = tail call ptr @BrotliAllocate(ptr noundef %0, i64 noundef %18) #3
  %.pre = load i64, ptr %10, align 8, !tbaa !12
  %.not139 = icmp eq i64 %.pre, 0
  br i1 %.not139, label %.loopexit133, label %.lr.ph.preheader

.lr.ph.preheader:                                 ; preds = %17
  %min.iters.check = icmp ult i64 %.pre, 8
  br i1 %min.iters.check, label %.lr.ph.preheader158, label %vector.ph

vector.ph:                                        ; preds = %.lr.ph.preheader
  %n.vec = and i64 %.pre, -8
  %broadcast.splatinsert = insertelement <4 x i32> poison, i32 %9, i64 0
  %broadcast.splat = shufflevector <4 x i32> %broadcast.splatinsert, <4 x i32> poison, <4 x i32> zeroinitializer
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %20 = getelementptr inbounds i32, ptr %19, i64 %index
  %21 = getelementptr inbounds i8, ptr %20, i64 16
  store <4 x i32> %broadcast.splat, ptr %20, align 4, !tbaa !16
  store <4 x i32> %broadcast.splat, ptr %21, align 4, !tbaa !16
  %index.next = add nuw i64 %index, 8
  %22 = icmp eq i64 %index.next, %n.vec
  br i1 %22, label %middle.block, label %vector.body, !llvm.loop !17

middle.block:                                     ; preds = %vector.body
  %cmp.n = icmp eq i64 %.pre, %n.vec
  br i1 %cmp.n, label %.loopexit133, label %.lr.ph.preheader158

.lr.ph.preheader158:                              ; preds = %middle.block, %.lr.ph.preheader
  %.0108134.ph = phi i64 [ 0, %.lr.ph.preheader ], [ %n.vec, %middle.block ]
  br label %.lr.ph

.lr.ph:                                           ; preds = %.lr.ph.preheader158, %.lr.ph
  %.0108134 = phi i64 [ %24, %.lr.ph ], [ %.0108134.ph, %.lr.ph.preheader158 ]
  %23 = getelementptr inbounds i32, ptr %19, i64 %.0108134
  store i32 %9, ptr %23, align 4, !tbaa !16
  %24 = add nuw i64 %.0108134, 1
  %exitcond.not = icmp eq i64 %24, %.pre
  br i1 %exitcond.not, label %.loopexit133, label %.lr.ph, !llvm.loop !21

.loopexit133:                                     ; preds = %.lr.ph, %middle.block, %16, %17, %11
  %25 = phi i64 [ %.pre141, %11 ], [ 0, %17 ], [ 0, %16 ], [ %.pre, %middle.block ], [ %.pre, %.lr.ph ]
  %.0109 = phi ptr [ null, %11 ], [ %19, %17 ], [ null, %16 ], [ %19, %middle.block ], [ %19, %.lr.ph ]
  %.0107 = phi i64 [ 1, %11 ], [ 64, %17 ], [ 64, %16 ], [ 64, %middle.block ], [ 64, %.lr.ph ]
  %26 = mul i64 %25, %.0107
  %.not119 = icmp eq i64 %26, 0
  br i1 %.not119, label %30, label %27

27:                                               ; preds = %.loopexit133
  %28 = mul i64 %26, 1040
  %29 = tail call ptr @BrotliAllocate(ptr noundef %0, i64 noundef %28) #3
  br label %30

30:                                               ; preds = %.loopexit133, %27
  %31 = phi ptr [ %29, %27 ], [ null, %.loopexit133 ]
  tail call void @ClearHistogramsLiteral(ptr noundef %31, i64 noundef %26)
  %32 = load i64, ptr %13, align 8, !tbaa !22
  %33 = shl i64 %32, 2
  %.not120 = icmp eq i64 %33, 0
  br i1 %.not120, label %37, label %34

34:                                               ; preds = %30
  %35 = mul i64 %32, 8384
  %36 = tail call ptr @BrotliAllocate(ptr noundef %0, i64 noundef %35) #3
  br label %37

37:                                               ; preds = %30, %34
  %38 = phi ptr [ %36, %34 ], [ null, %30 ]
  tail call void @ClearHistogramsDistance(ptr noundef %38, i64 noundef %33)
  %39 = load i64, ptr %12, align 8, !tbaa !23
  %40 = getelementptr inbounds i8, ptr %10, i64 200
  store i64 %39, ptr %40, align 8, !tbaa !24
  %.not121 = icmp eq i64 %39, 0
  br i1 %.not121, label %44, label %41

41:                                               ; preds = %37
  %42 = mul i64 %39, 2832
  %43 = tail call ptr @BrotliAllocate(ptr noundef %0, i64 noundef %42) #3
  %.pre142 = load i64, ptr %40, align 8, !tbaa !24
  br label %44

44:                                               ; preds = %37, %41
  %45 = phi i64 [ %.pre142, %41 ], [ 0, %37 ]
  %46 = phi ptr [ %43, %41 ], [ null, %37 ]
  %47 = getelementptr inbounds i8, ptr %10, i64 192
  store ptr %46, ptr %47, align 8, !tbaa !25
  tail call void @ClearHistogramsCommand(ptr noundef %46, i64 noundef %45)
  %48 = load ptr, ptr %47, align 8, !tbaa !25
  tail call void @BrotliBuildHistogramsWithContext(ptr noundef %7, i64 noundef %8, ptr noundef nonnull %10, ptr noundef nonnull %12, ptr noundef nonnull %13, ptr noundef %1, i64 noundef %2, i64 noundef %3, i8 noundef zeroext %5, i8 noundef zeroext %6, ptr noundef %.0109, ptr noundef %31, ptr noundef %48, ptr noundef %38) #3
  tail call void @BrotliFree(ptr noundef %0, ptr noundef %.0109) #3
  %49 = load i64, ptr %10, align 8, !tbaa !12
  %50 = shl i64 %49, 6
  %51 = getelementptr inbounds i8, ptr %10, i64 152
  store i64 %50, ptr %51, align 8, !tbaa !26
  %.not122 = icmp eq i64 %50, 0
  br i1 %.not122, label %.thread, label %54

.thread:                                          ; preds = %44
  %52 = getelementptr inbounds i8, ptr %10, i64 144
  store ptr null, ptr %52, align 8, !tbaa !27
  %53 = getelementptr inbounds i8, ptr %10, i64 184
  store i64 0, ptr %53, align 8, !tbaa !28
  br label %62

54:                                               ; preds = %44
  %55 = shl i64 %49, 8
  %56 = tail call ptr @BrotliAllocate(ptr noundef %0, i64 noundef %55) #3
  %.pr = load i64, ptr %51, align 8, !tbaa !26
  %57 = getelementptr inbounds i8, ptr %10, i64 144
  store ptr %56, ptr %57, align 8, !tbaa !27
  %58 = getelementptr inbounds i8, ptr %10, i64 184
  store i64 %.pr, ptr %58, align 8, !tbaa !28
  %.not123 = icmp eq i64 %.pr, 0
  br i1 %.not123, label %62, label %59

59:                                               ; preds = %54
  %60 = mul i64 %.pr, 1040
  %61 = tail call ptr @BrotliAllocate(ptr noundef %0, i64 noundef %60) #3
  %.pre143 = load ptr, ptr %57, align 8, !tbaa !27
  br label %62

62:                                               ; preds = %.thread, %54, %59
  %63 = phi ptr [ %.pre143, %59 ], [ %56, %54 ], [ null, %.thread ]
  %64 = phi ptr [ %58, %59 ], [ %58, %54 ], [ %53, %.thread ]
  %65 = phi ptr [ %57, %59 ], [ %57, %54 ], [ %52, %.thread ]
  %66 = phi ptr [ %61, %59 ], [ null, %54 ], [ null, %.thread ]
  %67 = getelementptr inbounds i8, ptr %10, i64 176
  store ptr %66, ptr %67, align 8, !tbaa !29
  tail call void @BrotliClusterHistogramsLiteral(ptr noundef %0, ptr noundef %31, i64 noundef %26, i64 noundef 256, ptr noundef %66, ptr noundef nonnull %64, ptr noundef %63) #3
  tail call void @BrotliFree(ptr noundef %0, ptr noundef %31) #3
  %68 = load i32, ptr %14, align 8, !tbaa !5
  %.not124 = icmp eq i32 %68, 0
  br i1 %.not124, label %.loopexit132, label %69

69:                                               ; preds = %62
  %70 = load i64, ptr %10, align 8, !tbaa !12
  %.not125136 = icmp eq i64 %70, 0
  br i1 %.not125136, label %.loopexit132, label %.lr.ph138

.lr.ph138:                                        ; preds = %69
  %71 = load ptr, ptr %65, align 8, !tbaa !27
  br label %vector.ph151

vector.ph151:                                     ; preds = %.lr.ph138, %vector.ph151
  %.1137 = phi i64 [ %70, %.lr.ph138 ], [ %72, %vector.ph151 ]
  %72 = add i64 %.1137, -1
  %73 = getelementptr inbounds i32, ptr %71, i64 %72
  %.pre144 = load i32, ptr %73, align 4, !tbaa !16
  %broadcast.splatinsert155 = insertelement <4 x i32> poison, i32 %.pre144, i64 0
  %broadcast.splat156 = shufflevector <4 x i32> %broadcast.splatinsert155, <4 x i32> poison, <4 x i32> zeroinitializer
  %.idx = shl i64 %72, 8
  %invariant.gep = getelementptr i8, ptr %71, i64 %.idx
  %74 = getelementptr i8, ptr %invariant.gep, i64 16
  store <4 x i32> %broadcast.splat156, ptr %invariant.gep, align 4, !tbaa !16
  store <4 x i32> %broadcast.splat156, ptr %74, align 4, !tbaa !16
  %75 = getelementptr i8, ptr %invariant.gep, i64 32
  %76 = getelementptr i8, ptr %invariant.gep, i64 48
  store <4 x i32> %broadcast.splat156, ptr %75, align 4, !tbaa !16
  store <4 x i32> %broadcast.splat156, ptr %76, align 4, !tbaa !16
  %77 = getelementptr i8, ptr %invariant.gep, i64 64
  %78 = getelementptr i8, ptr %invariant.gep, i64 80
  store <4 x i32> %broadcast.splat156, ptr %77, align 4, !tbaa !16
  store <4 x i32> %broadcast.splat156, ptr %78, align 4, !tbaa !16
  %79 = getelementptr i8, ptr %invariant.gep, i64 96
  %80 = getelementptr i8, ptr %invariant.gep, i64 112
  store <4 x i32> %broadcast.splat156, ptr %79, align 4, !tbaa !16
  store <4 x i32> %broadcast.splat156, ptr %80, align 4, !tbaa !16
  %81 = getelementptr i8, ptr %invariant.gep, i64 128
  %82 = getelementptr i8, ptr %invariant.gep, i64 144
  store <4 x i32> %broadcast.splat156, ptr %81, align 4, !tbaa !16
  store <4 x i32> %broadcast.splat156, ptr %82, align 4, !tbaa !16
  %83 = getelementptr i8, ptr %invariant.gep, i64 160
  %84 = getelementptr i8, ptr %invariant.gep, i64 176
  store <4 x i32> %broadcast.splat156, ptr %83, align 4, !tbaa !16
  store <4 x i32> %broadcast.splat156, ptr %84, align 4, !tbaa !16
  %85 = getelementptr i8, ptr %invariant.gep, i64 192
  %86 = getelementptr i8, ptr %invariant.gep, i64 208
  store <4 x i32> %broadcast.splat156, ptr %85, align 4, !tbaa !16
  store <4 x i32> %broadcast.splat156, ptr %86, align 4, !tbaa !16
  %87 = getelementptr i8, ptr %invariant.gep, i64 224
  %88 = getelementptr i8, ptr %invariant.gep, i64 240
  store <4 x i32> %broadcast.splat156, ptr %87, align 4, !tbaa !16
  store <4 x i32> %broadcast.splat156, ptr %88, align 4, !tbaa !16
  %.not125 = icmp eq i64 %72, 0
  br i1 %.not125, label %.loopexit132, label %vector.ph151, !llvm.loop !30

.loopexit132:                                     ; preds = %vector.ph151, %69, %62
  %89 = load i64, ptr %13, align 8, !tbaa !22
  %90 = shl i64 %89, 2
  %91 = getelementptr inbounds i8, ptr %10, i64 168
  store i64 %90, ptr %91, align 8, !tbaa !31
  %.not126 = icmp eq i64 %90, 0
  br i1 %.not126, label %.thread130, label %94

.thread130:                                       ; preds = %.loopexit132
  %92 = getelementptr inbounds i8, ptr %10, i64 160
  store ptr null, ptr %92, align 8, !tbaa !32
  %93 = getelementptr inbounds i8, ptr %10, i64 216
  store i64 0, ptr %93, align 8, !tbaa !33
  br label %102

94:                                               ; preds = %.loopexit132
  %95 = shl i64 %89, 4
  %96 = tail call ptr @BrotliAllocate(ptr noundef %0, i64 noundef %95) #3
  %.pr129 = load i64, ptr %91, align 8, !tbaa !31
  %97 = getelementptr inbounds i8, ptr %10, i64 160
  store ptr %96, ptr %97, align 8, !tbaa !32
  %98 = getelementptr inbounds i8, ptr %10, i64 216
  store i64 %.pr129, ptr %98, align 8, !tbaa !33
  %.not127 = icmp eq i64 %.pr129, 0
  br i1 %.not127, label %102, label %99

99:                                               ; preds = %94
  %100 = mul i64 %.pr129, 2096
  %101 = tail call ptr @BrotliAllocate(ptr noundef %0, i64 noundef %100) #3
  %.pre145 = load i64, ptr %91, align 8, !tbaa !31
  %.pre146 = load ptr, ptr %97, align 8, !tbaa !32
  br label %102

102:                                              ; preds = %.thread130, %94, %99
  %103 = phi ptr [ %.pre146, %99 ], [ %96, %94 ], [ null, %.thread130 ]
  %104 = phi i64 [ %.pre145, %99 ], [ 0, %94 ], [ 0, %.thread130 ]
  %105 = phi ptr [ %98, %99 ], [ %98, %94 ], [ %93, %.thread130 ]
  %106 = phi ptr [ %101, %99 ], [ null, %94 ], [ null, %.thread130 ]
  %107 = getelementptr inbounds i8, ptr %10, i64 208
  store ptr %106, ptr %107, align 8, !tbaa !34
  tail call void @BrotliClusterHistogramsDistance(ptr noundef %0, ptr noundef %38, i64 noundef %104, i64 noundef 256, ptr noundef %106, ptr noundef nonnull %105, ptr noundef %103) #3
  tail call void @BrotliFree(ptr noundef %0, ptr noundef %38) #3
  ret void
}

declare hidden void @BrotliSplitBlock(ptr noundef, ptr noundef, i64 noundef, ptr noundef, i64 noundef, i64 noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare hidden ptr @BrotliAllocate(ptr noundef, i64 noundef) local_unnamed_addr #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @ClearHistogramsLiteral(ptr noundef, i64 noundef) local_unnamed_addr #2

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @ClearHistogramsDistance(ptr noundef, i64 noundef) local_unnamed_addr #2

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @ClearHistogramsCommand(ptr noundef, i64 noundef) local_unnamed_addr #2

declare hidden void @BrotliBuildHistogramsWithContext(ptr noundef, i64 noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, i64 noundef, i64 noundef, i8 noundef zeroext, i8 noundef zeroext, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare hidden void @BrotliFree(ptr noundef, ptr noundef) local_unnamed_addr #1

declare hidden void @BrotliClusterHistogramsLiteral(ptr noundef, ptr noundef, i64 noundef, i64 noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare hidden void @BrotliClusterHistogramsDistance(ptr noundef, ptr noundef, i64 noundef, i64 noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #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 = { "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 = { alwaysinline 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 #3 = { 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 24}
!6 = !{!"BrotliEncoderParams", !7, i64 0, !7, i64 4, !7, i64 8, !7, i64 12, !10, i64 16, !7, i64 24, !11, i64 28}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"long", !8, i64 0}
!11 = !{!"BrotliHasherParams", !7, i64 0, !7, i64 4, !7, i64 8, !7, i64 12, !7, i64 16}
!12 = !{!13, !10, i64 0}
!13 = !{!"MetaBlockSplit", !14, i64 0, !14, i64 48, !14, i64 96, !15, i64 144, !10, i64 152, !15, i64 160, !10, i64 168, !15, i64 176, !10, i64 184, !15, i64 192, !10, i64 200, !15, i64 208, !10, i64 216}
!14 = !{!"BlockSplit", !10, i64 0, !10, i64 8, !15, i64 16, !15, i64 24, !10, i64 32, !10, i64 40}
!15 = !{!"any pointer", !8, i64 0}
!16 = !{!7, !7, i64 0}
!17 = distinct !{!17, !18, !19, !20}
!18 = !{!"llvm.loop.mustprogress"}
!19 = !{!"llvm.loop.isvectorized", i32 1}
!20 = !{!"llvm.loop.unroll.runtime.disable"}
!21 = distinct !{!21, !18, !20, !19}
!22 = !{!13, !10, i64 96}
!23 = !{!13, !10, i64 48}
!24 = !{!13, !10, i64 200}
!25 = !{!13, !15, i64 192}
!26 = !{!13, !10, i64 152}
!27 = !{!13, !15, i64 144}
!28 = !{!13, !10, i64 184}
!29 = !{!13, !15, i64 176}
!30 = distinct !{!30, !18}
!31 = !{!13, !10, i64 168}
!32 = !{!13, !15, i64 160}
!33 = !{!13, !10, i64 216}
!34 = !{!13, !15, i64 208}


; Effective O3 passes: BDCEPass,CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LICMPass,LoopLoadEliminationPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,LoopVectorizePass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass