; LLVM IR from attractivechaos/klib :: ksw (ksw_qinit)

; 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._kswq_t = type { i32, i32, i8, i8, i8, i8, ptr, ptr, ptr, ptr, ptr }

; Function Attrs: nounwind uwtable
define dso_local ptr @ksw_qinit(i32 noundef %0, i32 noundef %1, ptr noundef %2, i32 noundef %3, ptr noundef %4) #0 {
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %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
  %16 = alloca ptr, align 8
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca i32, align 4
  %20 = alloca ptr, align 8
  %21 = alloca ptr, align 8
  %22 = alloca i32, align 4
  %23 = alloca i32, align 4
  %24 = alloca i32, align 4
  %25 = alloca ptr, align 8
  store i32 %0, ptr %6, align 4, !tbaa !5
  store i32 %1, ptr %7, align 4, !tbaa !5
  store ptr %2, ptr %8, align 8, !tbaa !9
  store i32 %3, ptr %9, align 4, !tbaa !5
  store ptr %4, ptr %10, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #3
  %26 = load i32, ptr %6, align 4, !tbaa !5
  %27 = icmp sgt i32 %26, 1
  %28 = zext i1 %27 to i64
  %29 = select i1 %27, i32 2, i32 1
  store i32 %29, ptr %6, align 4, !tbaa !5
  %30 = load i32, ptr %6, align 4, !tbaa !5
  %31 = sub nsw i32 3, %30
  %32 = mul nsw i32 8, %31
  store i32 %32, ptr %15, align 4, !tbaa !5
  %33 = load i32, ptr %7, align 4, !tbaa !5
  %34 = load i32, ptr %15, align 4, !tbaa !5
  %35 = add nsw i32 %33, %34
  %36 = sub nsw i32 %35, 1
  %37 = load i32, ptr %15, align 4, !tbaa !5
  %38 = sdiv i32 %36, %37
  store i32 %38, ptr %12, align 4, !tbaa !5
  %39 = load i32, ptr %12, align 4, !tbaa !5
  %40 = mul nsw i32 16, %39
  %41 = load i32, ptr %9, align 4, !tbaa !5
  %42 = add nsw i32 %41, 4
  %43 = mul nsw i32 %40, %42
  %44 = sext i32 %43 to i64
  %45 = add i64 312, %44
  %46 = call noalias ptr @malloc(i64 noundef %45) #4
  store ptr %46, ptr %11, align 8, !tbaa !9
  %47 = load ptr, ptr %11, align 8, !tbaa !9
  %48 = ptrtoint ptr %47 to i64
  %49 = add i64 %48, 56
  %50 = add i64 %49, 15
  %51 = lshr i64 %50, 4
  %52 = shl i64 %51, 4
  %53 = inttoptr i64 %52 to ptr
  %54 = load ptr, ptr %11, align 8, !tbaa !9
  %55 = getelementptr inbounds %struct._kswq_t, ptr %54, i32 0, i32 6
  store ptr %53, ptr %55, align 8, !tbaa !11
  %56 = load ptr, ptr %11, align 8, !tbaa !9
  %57 = getelementptr inbounds %struct._kswq_t, ptr %56, i32 0, i32 6
  %58 = load ptr, ptr %57, align 8, !tbaa !11
  %59 = load i32, ptr %12, align 4, !tbaa !5
  %60 = load i32, ptr %9, align 4, !tbaa !5
  %61 = mul nsw i32 %59, %60
  %62 = sext i32 %61 to i64
  %63 = getelementptr inbounds <2 x i64>, ptr %58, i64 %62
  %64 = load ptr, ptr %11, align 8, !tbaa !9
  %65 = getelementptr inbounds %struct._kswq_t, ptr %64, i32 0, i32 7
  store ptr %63, ptr %65, align 8, !tbaa !13
  %66 = load ptr, ptr %11, align 8, !tbaa !9
  %67 = getelementptr inbounds %struct._kswq_t, ptr %66, i32 0, i32 7
  %68 = load ptr, ptr %67, align 8, !tbaa !13
  %69 = load i32, ptr %12, align 4, !tbaa !5
  %70 = sext i32 %69 to i64
  %71 = getelementptr inbounds <2 x i64>, ptr %68, i64 %70
  %72 = load ptr, ptr %11, align 8, !tbaa !9
  %73 = getelementptr inbounds %struct._kswq_t, ptr %72, i32 0, i32 8
  store ptr %71, ptr %73, align 8, !tbaa !14
  %74 = load ptr, ptr %11, align 8, !tbaa !9
  %75 = getelementptr inbounds %struct._kswq_t, ptr %74, i32 0, i32 8
  %76 = load ptr, ptr %75, align 8, !tbaa !14
  %77 = load i32, ptr %12, align 4, !tbaa !5
  %78 = sext i32 %77 to i64
  %79 = getelementptr inbounds <2 x i64>, ptr %76, i64 %78
  %80 = load ptr, ptr %11, align 8, !tbaa !9
  %81 = getelementptr inbounds %struct._kswq_t, ptr %80, i32 0, i32 9
  store ptr %79, ptr %81, align 8, !tbaa !15
  %82 = load ptr, ptr %11, align 8, !tbaa !9
  %83 = getelementptr inbounds %struct._kswq_t, ptr %82, i32 0, i32 9
  %84 = load ptr, ptr %83, align 8, !tbaa !15
  %85 = load i32, ptr %12, align 4, !tbaa !5
  %86 = sext i32 %85 to i64
  %87 = getelementptr inbounds <2 x i64>, ptr %84, i64 %86
  %88 = load ptr, ptr %11, align 8, !tbaa !9
  %89 = getelementptr inbounds %struct._kswq_t, ptr %88, i32 0, i32 10
  store ptr %87, ptr %89, align 8, !tbaa !16
  %90 = load i32, ptr %12, align 4, !tbaa !5
  %91 = load ptr, ptr %11, align 8, !tbaa !9
  %92 = getelementptr inbounds %struct._kswq_t, ptr %91, i32 0, i32 1
  store i32 %90, ptr %92, align 4, !tbaa !17
  %93 = load i32, ptr %7, align 4, !tbaa !5
  %94 = load ptr, ptr %11, align 8, !tbaa !9
  %95 = getelementptr inbounds %struct._kswq_t, ptr %94, i32 0, i32 0
  store i32 %93, ptr %95, align 8, !tbaa !18
  %96 = load i32, ptr %6, align 4, !tbaa !5
  %97 = trunc i32 %96 to i8
  %98 = load ptr, ptr %11, align 8, !tbaa !9
  %99 = getelementptr inbounds %struct._kswq_t, ptr %98, i32 0, i32 5
  store i8 %97, ptr %99, align 1, !tbaa !19
  %100 = load i32, ptr %9, align 4, !tbaa !5
  %101 = load i32, ptr %9, align 4, !tbaa !5
  %102 = mul nsw i32 %100, %101
  store i32 %102, ptr %14, align 4, !tbaa !5
  store i32 0, ptr %13, align 4, !tbaa !5
  %103 = load ptr, ptr %11, align 8, !tbaa !9
  %104 = getelementptr inbounds %struct._kswq_t, ptr %103, i32 0, i32 2
  store i8 127, ptr %104, align 8, !tbaa !20
  %105 = load ptr, ptr %11, align 8, !tbaa !9
  %106 = getelementptr inbounds %struct._kswq_t, ptr %105, i32 0, i32 3
  store i8 0, ptr %106, align 1, !tbaa !21
  br label %107

107:                                              ; preds = %152, %5
  %108 = load i32, ptr %13, align 4, !tbaa !5
  %109 = load i32, ptr %14, align 4, !tbaa !5
  %110 = icmp slt i32 %108, %109
  br i1 %110, label %111, label %155

111:                                              ; preds = %107
  %112 = load ptr, ptr %10, align 8, !tbaa !9
  %113 = load i32, ptr %13, align 4, !tbaa !5
  %114 = sext i32 %113 to i64
  %115 = getelementptr inbounds i8, ptr %112, i64 %114
  %116 = load i8, ptr %115, align 1, !tbaa !22
  %117 = sext i8 %116 to i32
  %118 = load ptr, ptr %11, align 8, !tbaa !9
  %119 = getelementptr inbounds %struct._kswq_t, ptr %118, i32 0, i32 2
  %120 = load i8, ptr %119, align 8, !tbaa !20
  %121 = sext i8 %120 to i32
  %122 = icmp slt i32 %117, %121
  br i1 %122, label %123, label %131

123:                                              ; preds = %111
  %124 = load ptr, ptr %10, align 8, !tbaa !9
  %125 = load i32, ptr %13, align 4, !tbaa !5
  %126 = sext i32 %125 to i64
  %127 = getelementptr inbounds i8, ptr %124, i64 %126
  %128 = load i8, ptr %127, align 1, !tbaa !22
  %129 = load ptr, ptr %11, align 8, !tbaa !9
  %130 = getelementptr inbounds %struct._kswq_t, ptr %129, i32 0, i32 2
  store i8 %128, ptr %130, align 8, !tbaa !20
  br label %131

131:                                              ; preds = %123, %111
  %132 = load ptr, ptr %10, align 8, !tbaa !9
  %133 = load i32, ptr %13, align 4, !tbaa !5
  %134 = sext i32 %133 to i64
  %135 = getelementptr inbounds i8, ptr %132, i64 %134
  %136 = load i8, ptr %135, align 1, !tbaa !22
  %137 = sext i8 %136 to i32
  %138 = load ptr, ptr %11, align 8, !tbaa !9
  %139 = getelementptr inbounds %struct._kswq_t, ptr %138, i32 0, i32 3
  %140 = load i8, ptr %139, align 1, !tbaa !21
  %141 = sext i8 %140 to i32
  %142 = icmp sgt i32 %137, %141
  br i1 %142, label %143, label %151

143:                                              ; preds = %131
  %144 = load ptr, ptr %10, align 8, !tbaa !9
  %145 = load i32, ptr %13, align 4, !tbaa !5
  %146 = sext i32 %145 to i64
  %147 = getelementptr inbounds i8, ptr %144, i64 %146
  %148 = load i8, ptr %147, align 1, !tbaa !22
  %149 = load ptr, ptr %11, align 8, !tbaa !9
  %150 = getelementptr inbounds %struct._kswq_t, ptr %149, i32 0, i32 3
  store i8 %148, ptr %150, align 1, !tbaa !21
  br label %151

151:                                              ; preds = %143, %131
  br label %152

152:                                              ; preds = %151
  %153 = load i32, ptr %13, align 4, !tbaa !5
  %154 = add nsw i32 %153, 1
  store i32 %154, ptr %13, align 4, !tbaa !5
  br label %107, !llvm.loop !23

155:                                              ; preds = %107
  %156 = load ptr, ptr %11, align 8, !tbaa !9
  %157 = getelementptr inbounds %struct._kswq_t, ptr %156, i32 0, i32 3
  %158 = load i8, ptr %157, align 1, !tbaa !21
  %159 = load ptr, ptr %11, align 8, !tbaa !9
  %160 = getelementptr inbounds %struct._kswq_t, ptr %159, i32 0, i32 4
  store i8 %158, ptr %160, align 2, !tbaa !25
  %161 = load ptr, ptr %11, align 8, !tbaa !9
  %162 = getelementptr inbounds %struct._kswq_t, ptr %161, i32 0, i32 2
  %163 = load i8, ptr %162, align 8, !tbaa !20
  %164 = zext i8 %163 to i32
  %165 = sub nsw i32 256, %164
  %166 = trunc i32 %165 to i8
  %167 = load ptr, ptr %11, align 8, !tbaa !9
  %168 = getelementptr inbounds %struct._kswq_t, ptr %167, i32 0, i32 2
  store i8 %166, ptr %168, align 8, !tbaa !20
  %169 = load ptr, ptr %11, align 8, !tbaa !9
  %170 = getelementptr inbounds %struct._kswq_t, ptr %169, i32 0, i32 2
  %171 = load i8, ptr %170, align 8, !tbaa !20
  %172 = zext i8 %171 to i32
  %173 = load ptr, ptr %11, align 8, !tbaa !9
  %174 = getelementptr inbounds %struct._kswq_t, ptr %173, i32 0, i32 3
  %175 = load i8, ptr %174, align 1, !tbaa !21
  %176 = zext i8 %175 to i32
  %177 = add nsw i32 %176, %172
  %178 = trunc i32 %177 to i8
  store i8 %178, ptr %174, align 1, !tbaa !21
  %179 = load i32, ptr %6, align 4, !tbaa !5
  %180 = icmp eq i32 %179, 1
  br i1 %180, label %181, label %248

181:                                              ; preds = %155
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #3
  %182 = load ptr, ptr %11, align 8, !tbaa !9
  %183 = getelementptr inbounds %struct._kswq_t, ptr %182, i32 0, i32 6
  %184 = load ptr, ptr %183, align 8, !tbaa !11
  store ptr %184, ptr %16, align 8, !tbaa !9
  store i32 0, ptr %13, align 4, !tbaa !5
  br label %185

185:                                              ; preds = %244, %181
  %186 = load i32, ptr %13, align 4, !tbaa !5
  %187 = load i32, ptr %9, align 4, !tbaa !5
  %188 = icmp slt i32 %186, %187
  br i1 %188, label %189, label %247

189:                                              ; preds = %185
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #3
  %190 = load i32, ptr %12, align 4, !tbaa !5
  %191 = load i32, ptr %15, align 4, !tbaa !5
  %192 = mul nsw i32 %190, %191
  store i32 %192, ptr %19, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #3
  %193 = load ptr, ptr %10, align 8, !tbaa !9
  %194 = load i32, ptr %13, align 4, !tbaa !5
  %195 = load i32, ptr %9, align 4, !tbaa !5
  %196 = mul nsw i32 %194, %195
  %197 = sext i32 %196 to i64
  %198 = getelementptr inbounds i8, ptr %193, i64 %197
  store ptr %198, ptr %20, align 8, !tbaa !9
  store i32 0, ptr %17, align 4, !tbaa !5
  br label %199

199:                                              ; preds = %240, %189
  %200 = load i32, ptr %17, align 4, !tbaa !5
  %201 = load i32, ptr %12, align 4, !tbaa !5
  %202 = icmp slt i32 %200, %201
  br i1 %202, label %203, label %243

203:                                              ; preds = %199
  %204 = load i32, ptr %17, align 4, !tbaa !5
  store i32 %204, ptr %18, align 4, !tbaa !5
  br label %205

205:                                              ; preds = %235, %203
  %206 = load i32, ptr %18, align 4, !tbaa !5
  %207 = load i32, ptr %19, align 4, !tbaa !5
  %208 = icmp slt i32 %206, %207
  br i1 %208, label %209, label %239

209:                                              ; preds = %205
  %210 = load i32, ptr %18, align 4, !tbaa !5
  %211 = load i32, ptr %7, align 4, !tbaa !5
  %212 = icmp sge i32 %210, %211
  br i1 %212, label %213, label %214

213:                                              ; preds = %209
  br label %225

214:                                              ; preds = %209
  %215 = load ptr, ptr %20, align 8, !tbaa !9
  %216 = load ptr, ptr %8, align 8, !tbaa !9
  %217 = load i32, ptr %18, align 4, !tbaa !5
  %218 = sext i32 %217 to i64
  %219 = getelementptr inbounds i8, ptr %216, i64 %218
  %220 = load i8, ptr %219, align 1, !tbaa !22
  %221 = zext i8 %220 to i64
  %222 = getelementptr inbounds i8, ptr %215, i64 %221
  %223 = load i8, ptr %222, align 1, !tbaa !22
  %224 = sext i8 %223 to i32
  br label %225

225:                                              ; preds = %214, %213
  %226 = phi i32 [ 0, %213 ], [ %224, %214 ]
  %227 = load ptr, ptr %11, align 8, !tbaa !9
  %228 = getelementptr inbounds %struct._kswq_t, ptr %227, i32 0, i32 2
  %229 = load i8, ptr %228, align 8, !tbaa !20
  %230 = zext i8 %229 to i32
  %231 = add nsw i32 %226, %230
  %232 = trunc i32 %231 to i8
  %233 = load ptr, ptr %16, align 8, !tbaa !9
  %234 = getelementptr inbounds i8, ptr %233, i32 1
  store ptr %234, ptr %16, align 8, !tbaa !9
  store i8 %232, ptr %233, align 1, !tbaa !22
  br label %235

235:                                              ; preds = %225
  %236 = load i32, ptr %12, align 4, !tbaa !5
  %237 = load i32, ptr %18, align 4, !tbaa !5
  %238 = add nsw i32 %237, %236
  store i32 %238, ptr %18, align 4, !tbaa !5
  br label %205, !llvm.loop !26

239:                                              ; preds = %205
  br label %240

240:                                              ; preds = %239
  %241 = load i32, ptr %17, align 4, !tbaa !5
  %242 = add nsw i32 %241, 1
  store i32 %242, ptr %17, align 4, !tbaa !5
  br label %199, !llvm.loop !27

243:                                              ; preds = %199
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #3
  br label %244

244:                                              ; preds = %243
  %245 = load i32, ptr %13, align 4, !tbaa !5
  %246 = add nsw i32 %245, 1
  store i32 %246, ptr %13, align 4, !tbaa !5
  br label %185, !llvm.loop !28

247:                                              ; preds = %185
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #3
  br label %310

248:                                              ; preds = %155
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #3
  %249 = load ptr, ptr %11, align 8, !tbaa !9
  %250 = getelementptr inbounds %struct._kswq_t, ptr %249, i32 0, i32 6
  %251 = load ptr, ptr %250, align 8, !tbaa !11
  store ptr %251, ptr %21, align 8, !tbaa !9
  store i32 0, ptr %13, align 4, !tbaa !5
  br label %252

252:                                              ; preds = %306, %248
  %253 = load i32, ptr %13, align 4, !tbaa !5
  %254 = load i32, ptr %9, align 4, !tbaa !5
  %255 = icmp slt i32 %253, %254
  br i1 %255, label %256, label %309

256:                                              ; preds = %252
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #3
  %257 = load i32, ptr %12, align 4, !tbaa !5
  %258 = load i32, ptr %15, align 4, !tbaa !5
  %259 = mul nsw i32 %257, %258
  store i32 %259, ptr %24, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #3
  %260 = load ptr, ptr %10, align 8, !tbaa !9
  %261 = load i32, ptr %13, align 4, !tbaa !5
  %262 = load i32, ptr %9, align 4, !tbaa !5
  %263 = mul nsw i32 %261, %262
  %264 = sext i32 %263 to i64
  %265 = getelementptr inbounds i8, ptr %260, i64 %264
  store ptr %265, ptr %25, align 8, !tbaa !9
  store i32 0, ptr %22, align 4, !tbaa !5
  br label %266

266:                                              ; preds = %302, %256
  %267 = load i32, ptr %22, align 4, !tbaa !5
  %268 = load i32, ptr %12, align 4, !tbaa !5
  %269 = icmp slt i32 %267, %268
  br i1 %269, label %270, label %305

270:                                              ; preds = %266
  %271 = load i32, ptr %22, align 4, !tbaa !5
  store i32 %271, ptr %23, align 4, !tbaa !5
  br label %272

272:                                              ; preds = %297, %270
  %273 = load i32, ptr %23, align 4, !tbaa !5
  %274 = load i32, ptr %24, align 4, !tbaa !5
  %275 = icmp slt i32 %273, %274
  br i1 %275, label %276, label %301

276:                                              ; preds = %272
  %277 = load i32, ptr %23, align 4, !tbaa !5
  %278 = load i32, ptr %7, align 4, !tbaa !5
  %279 = icmp sge i32 %277, %278
  br i1 %279, label %280, label %281

280:                                              ; preds = %276
  br label %292

281:                                              ; preds = %276
  %282 = load ptr, ptr %25, align 8, !tbaa !9
  %283 = load ptr, ptr %8, align 8, !tbaa !9
  %284 = load i32, ptr %23, align 4, !tbaa !5
  %285 = sext i32 %284 to i64
  %286 = getelementptr inbounds i8, ptr %283, i64 %285
  %287 = load i8, ptr %286, align 1, !tbaa !22
  %288 = zext i8 %287 to i64
  %289 = getelementptr inbounds i8, ptr %282, i64 %288
  %290 = load i8, ptr %289, align 1, !tbaa !22
  %291 = sext i8 %290 to i32
  br label %292

292:                                              ; preds = %281, %280
  %293 = phi i32 [ 0, %280 ], [ %291, %281 ]
  %294 = trunc i32 %293 to i16
  %295 = load ptr, ptr %21, align 8, !tbaa !9
  %296 = getelementptr inbounds i16, ptr %295, i32 1
  store ptr %296, ptr %21, align 8, !tbaa !9
  store i16 %294, ptr %295, align 2, !tbaa !29
  br label %297

297:                                              ; preds = %292
  %298 = load i32, ptr %12, align 4, !tbaa !5
  %299 = load i32, ptr %23, align 4, !tbaa !5
  %300 = add nsw i32 %299, %298
  store i32 %300, ptr %23, align 4, !tbaa !5
  br label %272, !llvm.loop !31

301:                                              ; preds = %272
  br label %302

302:                                              ; preds = %301
  %303 = load i32, ptr %22, align 4, !tbaa !5
  %304 = add nsw i32 %303, 1
  store i32 %304, ptr %22, align 4, !tbaa !5
  br label %266, !llvm.loop !32

305:                                              ; preds = %266
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #3
  br label %306

306:                                              ; preds = %305
  %307 = load i32, ptr %13, align 4, !tbaa !5
  %308 = add nsw i32 %307, 1
  store i32 %308, ptr %13, align 4, !tbaa !5
  br label %252, !llvm.loop !33

309:                                              ; preds = %252
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #3
  br label %310

310:                                              ; preds = %309, %247
  %311 = load ptr, ptr %11, align 8, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #3
  ret ptr %311
}

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

; Function Attrs: nounwind allocsize(0)
declare noalias ptr @malloc(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 = { nounwind allocsize(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 }
attributes #4 = { nounwind allocsize(0) }

!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 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = !{!12, !10, i64 16}
!12 = !{!"_kswq_t", !6, i64 0, !6, i64 4, !7, i64 8, !7, i64 9, !7, i64 10, !7, i64 11, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48}
!13 = !{!12, !10, i64 24}
!14 = !{!12, !10, i64 32}
!15 = !{!12, !10, i64 40}
!16 = !{!12, !10, i64 48}
!17 = !{!12, !6, i64 4}
!18 = !{!12, !6, i64 0}
!19 = !{!12, !7, i64 11}
!20 = !{!12, !7, i64 8}
!21 = !{!12, !7, i64 9}
!22 = !{!7, !7, i64 0}
!23 = distinct !{!23, !24}
!24 = !{!"llvm.loop.mustprogress"}
!25 = !{!12, !7, i64 10}
!26 = distinct !{!26, !24}
!27 = distinct !{!27, !24}
!28 = distinct !{!28, !24}
!29 = !{!30, !30, i64 0}
!30 = !{!"short", !7, i64 0}
!31 = distinct !{!31, !24}
!32 = distinct !{!32, !24}
!33 = distinct !{!33, !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"

; Function Attrs: nofree nounwind uwtable
define dso_local noundef ptr @ksw_qinit(i32 noundef %0, i32 noundef %1, ptr nocapture noundef readonly %2, i32 noundef %3, ptr nocapture noundef readonly %4) local_unnamed_addr #0 {
  %6 = icmp slt i32 %0, 2
  %7 = select i1 %6, i32 1, i32 2
  %8 = shl nuw nsw i32 %7, 3
  %9 = xor i32 %8, 24
  %10 = add i32 %1, -1
  %11 = add i32 %10, %9
  %12 = sdiv i32 %11, %9
  %13 = shl i32 %3, 4
  %14 = add i32 %13, 64
  %15 = mul i32 %14, %12
  %16 = sext i32 %15 to i64
  %17 = add nsw i64 %16, 312
  %18 = tail call noalias ptr @malloc(i64 noundef %17) #3
  %19 = ptrtoint ptr %18 to i64
  %20 = add i64 %19, 71
  %21 = and i64 %20, -16
  %22 = inttoptr i64 %21 to ptr
  %23 = getelementptr inbounds i8, ptr %18, i64 16
  store ptr %22, ptr %23, align 8, !tbaa !5
  %24 = mul nsw i32 %12, %3
  %25 = sext i32 %24 to i64
  %26 = getelementptr inbounds <2 x i64>, ptr %22, i64 %25
  %27 = getelementptr inbounds i8, ptr %18, i64 24
  store ptr %26, ptr %27, align 8, !tbaa !11
  %28 = sext i32 %12 to i64
  %29 = getelementptr inbounds <2 x i64>, ptr %26, i64 %28
  %30 = getelementptr inbounds i8, ptr %18, i64 32
  store ptr %29, ptr %30, align 8, !tbaa !12
  %31 = getelementptr inbounds <2 x i64>, ptr %29, i64 %28
  %32 = getelementptr inbounds i8, ptr %18, i64 40
  store ptr %31, ptr %32, align 8, !tbaa !13
  %33 = getelementptr inbounds <2 x i64>, ptr %31, i64 %28
  %34 = getelementptr inbounds i8, ptr %18, i64 48
  store ptr %33, ptr %34, align 8, !tbaa !14
  %35 = getelementptr inbounds i8, ptr %18, i64 4
  store i32 %12, ptr %35, align 4, !tbaa !15
  store i32 %1, ptr %18, align 8, !tbaa !16
  %36 = trunc nuw nsw i32 %7 to i8
  %37 = getelementptr inbounds i8, ptr %18, i64 11
  store i8 %36, ptr %37, align 1, !tbaa !17
  %38 = getelementptr inbounds i8, ptr %18, i64 8
  %39 = getelementptr inbounds i8, ptr %18, i64 9
  %.not = icmp eq i32 %3, 0
  br i1 %.not, label %._crit_edge.thread, label %iter.check

iter.check:                                       ; preds = %5
  %40 = mul i32 %3, %3
  %umax = tail call i32 @llvm.umax.i32(i32 %40, i32 1)
  %wide.trip.count = zext i32 %umax to i64
  %min.iters.check = icmp ult i32 %40, 8
  br i1 %min.iters.check, label %vec.epilog.scalar.ph.preheader, label %vector.main.loop.iter.check

vector.main.loop.iter.check:                      ; preds = %iter.check
  %min.iters.check182 = icmp ult i32 %40, 32
  br i1 %min.iters.check182, label %vec.epilog.ph, label %vector.ph

vector.ph:                                        ; preds = %vector.main.loop.iter.check
  %n.vec = and i64 %wide.trip.count, 4294967264
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %vec.phi = phi <16 x i8> [ zeroinitializer, %vector.ph ], [ %45, %vector.body ]
  %vec.phi183 = phi <16 x i8> [ zeroinitializer, %vector.ph ], [ %46, %vector.body ]
  %vec.phi184 = phi <16 x i8> [ <i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127>, %vector.ph ], [ %43, %vector.body ]
  %vec.phi185 = phi <16 x i8> [ <i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127, i8 127>, %vector.ph ], [ %44, %vector.body ]
  %41 = getelementptr inbounds i8, ptr %4, i64 %index
  %42 = getelementptr inbounds i8, ptr %41, i64 16
  %wide.load = load <16 x i8>, ptr %41, align 1, !tbaa !18
  %wide.load186 = load <16 x i8>, ptr %42, align 1, !tbaa !18
  %43 = tail call <16 x i8> @llvm.smin.v16i8(<16 x i8> %wide.load, <16 x i8> %vec.phi184)
  %44 = tail call <16 x i8> @llvm.smin.v16i8(<16 x i8> %wide.load186, <16 x i8> %vec.phi185)
  %45 = tail call <16 x i8> @llvm.smax.v16i8(<16 x i8> %wide.load, <16 x i8> %vec.phi)
  %46 = tail call <16 x i8> @llvm.smax.v16i8(<16 x i8> %wide.load186, <16 x i8> %vec.phi183)
  %index.next = add nuw i64 %index, 32
  %47 = icmp eq i64 %index.next, %n.vec
  br i1 %47, label %middle.block, label %vector.body, !llvm.loop !19

middle.block:                                     ; preds = %vector.body
  %rdx.minmax = tail call <16 x i8> @llvm.smax.v16i8(<16 x i8> %45, <16 x i8> %46)
  %48 = tail call i8 @llvm.vector.reduce.smax.v16i8(<16 x i8> %rdx.minmax)
  %rdx.minmax187 = tail call <16 x i8> @llvm.smin.v16i8(<16 x i8> %43, <16 x i8> %44)
  %49 = tail call i8 @llvm.vector.reduce.smin.v16i8(<16 x i8> %rdx.minmax187)
  %cmp.n = icmp eq i64 %n.vec, %wide.trip.count
  br i1 %cmp.n, label %._crit_edge, label %vec.epilog.iter.check

vec.epilog.iter.check:                            ; preds = %middle.block
  %n.vec.remaining = and i64 %wide.trip.count, 24
  %min.epilog.iters.check = icmp eq i64 %n.vec.remaining, 0
  br i1 %min.epilog.iters.check, label %vec.epilog.scalar.ph.preheader, label %vec.epilog.ph

vec.epilog.ph:                                    ; preds = %vector.main.loop.iter.check, %vec.epilog.iter.check
  %bc.merge.rdx = phi i8 [ %48, %vec.epilog.iter.check ], [ 0, %vector.main.loop.iter.check ]
  %bc.merge.rdx188 = phi i8 [ %49, %vec.epilog.iter.check ], [ 127, %vector.main.loop.iter.check ]
  %vec.epilog.resume.val = phi i64 [ %n.vec, %vec.epilog.iter.check ], [ 0, %vector.main.loop.iter.check ]
  %n.vec190 = and i64 %wide.trip.count, 4294967288
  %minmax.ident.splatinsert = insertelement <8 x i8> poison, i8 %bc.merge.rdx, i64 0
  %minmax.ident.splat = shufflevector <8 x i8> %minmax.ident.splatinsert, <8 x i8> poison, <8 x i32> zeroinitializer
  %minmax.ident.splatinsert194 = insertelement <8 x i8> poison, i8 %bc.merge.rdx188, i64 0
  %minmax.ident.splat195 = shufflevector <8 x i8> %minmax.ident.splatinsert194, <8 x i8> poison, <8 x i32> zeroinitializer
  br label %vec.epilog.vector.body

vec.epilog.vector.body:                           ; preds = %vec.epilog.vector.body, %vec.epilog.ph
  %index191 = phi i64 [ %vec.epilog.resume.val, %vec.epilog.ph ], [ %index.next197, %vec.epilog.vector.body ]
  %vec.phi192 = phi <8 x i8> [ %minmax.ident.splat, %vec.epilog.ph ], [ %52, %vec.epilog.vector.body ]
  %vec.phi193 = phi <8 x i8> [ %minmax.ident.splat195, %vec.epilog.ph ], [ %51, %vec.epilog.vector.body ]
  %50 = getelementptr inbounds i8, ptr %4, i64 %index191
  %wide.load196 = load <8 x i8>, ptr %50, align 1, !tbaa !18
  %51 = tail call <8 x i8> @llvm.smin.v8i8(<8 x i8> %wide.load196, <8 x i8> %vec.phi193)
  %52 = tail call <8 x i8> @llvm.smax.v8i8(<8 x i8> %wide.load196, <8 x i8> %vec.phi192)
  %index.next197 = add nuw i64 %index191, 8
  %53 = icmp eq i64 %index.next197, %n.vec190
  br i1 %53, label %vec.epilog.middle.block, label %vec.epilog.vector.body, !llvm.loop !23

vec.epilog.middle.block:                          ; preds = %vec.epilog.vector.body
  %54 = tail call i8 @llvm.vector.reduce.smax.v8i8(<8 x i8> %52)
  %55 = tail call i8 @llvm.vector.reduce.smin.v8i8(<8 x i8> %51)
  %cmp.n198 = icmp eq i64 %n.vec190, %wide.trip.count
  br i1 %cmp.n198, label %._crit_edge, label %vec.epilog.scalar.ph.preheader

vec.epilog.scalar.ph.preheader:                   ; preds = %vec.epilog.middle.block, %iter.check, %vec.epilog.iter.check
  %indvars.iv.ph = phi i64 [ 0, %iter.check ], [ %n.vec, %vec.epilog.iter.check ], [ %n.vec190, %vec.epilog.middle.block ]
  %.ph = phi i8 [ 0, %iter.check ], [ %48, %vec.epilog.iter.check ], [ %54, %vec.epilog.middle.block ]
  %.ph203 = phi i8 [ 127, %iter.check ], [ %49, %vec.epilog.iter.check ], [ %55, %vec.epilog.middle.block ]
  br label %vec.epilog.scalar.ph

vec.epilog.scalar.ph:                             ; preds = %vec.epilog.scalar.ph.preheader, %vec.epilog.scalar.ph
  %indvars.iv = phi i64 [ %indvars.iv.next, %vec.epilog.scalar.ph ], [ %indvars.iv.ph, %vec.epilog.scalar.ph.preheader ]
  %56 = phi i8 [ %60, %vec.epilog.scalar.ph ], [ %.ph, %vec.epilog.scalar.ph.preheader ]
  %57 = phi i8 [ %spec.select, %vec.epilog.scalar.ph ], [ %.ph203, %vec.epilog.scalar.ph.preheader ]
  %58 = getelementptr inbounds i8, ptr %4, i64 %indvars.iv
  %59 = load i8, ptr %58, align 1, !tbaa !18
  %spec.select = tail call i8 @llvm.smin.i8(i8 %59, i8 %57)
  %60 = tail call i8 @llvm.smax.i8(i8 %59, i8 %56)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count
  br i1 %exitcond.not, label %._crit_edge, label %vec.epilog.scalar.ph, !llvm.loop !24

._crit_edge:                                      ; preds = %vec.epilog.scalar.ph, %vec.epilog.middle.block, %middle.block
  %spec.select.lcssa = phi i8 [ %49, %middle.block ], [ %55, %vec.epilog.middle.block ], [ %spec.select, %vec.epilog.scalar.ph ]
  %.lcssa181 = phi i8 [ %48, %middle.block ], [ %54, %vec.epilog.middle.block ], [ %60, %vec.epilog.scalar.ph ]
  %61 = getelementptr inbounds i8, ptr %18, i64 10
  store i8 %.lcssa181, ptr %61, align 2, !tbaa !25
  %62 = sub i8 0, %spec.select.lcssa
  store i8 %62, ptr %38, align 8, !tbaa !26
  %63 = sub i8 %.lcssa181, %spec.select.lcssa
  store i8 %63, ptr %39, align 1, !tbaa !27
  %64 = icmp sgt i32 %3, 0
  br i1 %6, label %.preheader116, label %.preheader118

._crit_edge.thread:                               ; preds = %5
  %65 = getelementptr inbounds i8, ptr %18, i64 10
  store i8 0, ptr %65, align 2, !tbaa !25
  store i8 -127, ptr %38, align 8, !tbaa !26
  store i8 -127, ptr %39, align 1, !tbaa !27
  br label %.loopexit

.preheader118:                                    ; preds = %._crit_edge
  br i1 %64, label %.lr.ph132, label %.loopexit

.lr.ph132:                                        ; preds = %.preheader118
  %66 = mul nsw i32 %12, %9
  %67 = icmp sgt i32 %12, 0
  br i1 %67, label %.preheader117.lr.ph.us.preheader, label %.loopexit

.preheader117.lr.ph.us.preheader:                 ; preds = %.lr.ph132
  %68 = zext nneg i32 %12 to i64
  %69 = zext nneg i32 %3 to i64
  br label %.preheader117.lr.ph.us

.preheader117.lr.ph.us:                           ; preds = %.preheader117.lr.ph.us.preheader, %._crit_edge128.us
  %indvars.iv157 = phi i64 [ 0, %.preheader117.lr.ph.us.preheader ], [ %indvars.iv.next158, %._crit_edge128.us ]
  %.0103130.us = phi ptr [ %22, %.preheader117.lr.ph.us.preheader ], [ %.2105.lcssa.us, %._crit_edge128.us ]
  %70 = mul nuw nsw i64 %indvars.iv157, %69
  %71 = getelementptr inbounds i8, ptr %4, i64 %70
  br label %.preheader117.us

._crit_edge125.us:                                ; preds = %80, %.preheader117.us
  %.2105.lcssa.us = phi ptr [ %.1104126.us, %.preheader117.us ], [ %82, %80 ]
  %indvars.iv.next150 = add nuw nsw i64 %indvars.iv149, 1
  %exitcond156.not = icmp eq i64 %indvars.iv.next150, %68
  br i1 %exitcond156.not, label %._crit_edge128.us, label %.preheader117.us, !llvm.loop !28

.lr.ph124.us:                                     ; preds = %.preheader117.us, %80
  %indvars.iv151 = phi i64 [ %indvars.iv.next152, %80 ], [ %indvars.iv149, %.preheader117.us ]
  %.2105122.us = phi ptr [ %82, %80 ], [ %.1104126.us, %.preheader117.us ]
  %72 = trunc nuw i64 %indvars.iv151 to i32
  %.not.us = icmp slt i32 %72, %1
  br i1 %.not.us, label %73, label %80

73:                                               ; preds = %.lr.ph124.us
  %74 = getelementptr inbounds i8, ptr %2, i64 %indvars.iv151
  %75 = load i8, ptr %74, align 1, !tbaa !18
  %76 = zext i8 %75 to i64
  %77 = getelementptr inbounds i8, ptr %71, i64 %76
  %78 = load i8, ptr %77, align 1, !tbaa !18
  %79 = sext i8 %78 to i16
  br label %80

80:                                               ; preds = %73, %.lr.ph124.us
  %81 = phi i16 [ %79, %73 ], [ 0, %.lr.ph124.us ]
  %82 = getelementptr inbounds i8, ptr %.2105122.us, i64 2
  store i16 %81, ptr %.2105122.us, align 2, !tbaa !29
  %indvars.iv.next152 = add nuw nsw i64 %indvars.iv151, %68
  %83 = trunc nuw i64 %indvars.iv.next152 to i32
  %84 = icmp sgt i32 %66, %83
  br i1 %84, label %.lr.ph124.us, label %._crit_edge125.us, !llvm.loop !31

.preheader117.us:                                 ; preds = %.preheader117.lr.ph.us, %._crit_edge125.us
  %indvars.iv149 = phi i64 [ 0, %.preheader117.lr.ph.us ], [ %indvars.iv.next150, %._crit_edge125.us ]
  %.1104126.us = phi ptr [ %.0103130.us, %.preheader117.lr.ph.us ], [ %.2105.lcssa.us, %._crit_edge125.us ]
  %indvars154 = trunc i64 %indvars.iv149 to i32
  %85 = icmp sgt i32 %66, %indvars154
  br i1 %85, label %.lr.ph124.us, label %._crit_edge125.us

._crit_edge128.us:                                ; preds = %._crit_edge125.us
  %indvars.iv.next158 = add nuw nsw i64 %indvars.iv157, 1
  %exitcond161.not = icmp eq i64 %indvars.iv.next158, %69
  br i1 %exitcond161.not, label %.loopexit, label %.preheader117.lr.ph.us, !llvm.loop !32

.preheader116:                                    ; preds = %._crit_edge
  br i1 %64, label %.lr.ph143, label %.loopexit

.lr.ph143:                                        ; preds = %.preheader116
  %86 = mul nsw i32 %12, %9
  %87 = icmp sgt i32 %12, 0
  br i1 %87, label %.preheader.lr.ph.us.preheader, label %.loopexit

.preheader.lr.ph.us.preheader:                    ; preds = %.lr.ph143
  %88 = zext nneg i32 %12 to i64
  %89 = zext nneg i32 %3 to i64
  br label %.preheader.lr.ph.us

.preheader.lr.ph.us:                              ; preds = %.preheader.lr.ph.us.preheader, %._crit_edge139.us
  %indvars.iv170 = phi i64 [ 0, %.preheader.lr.ph.us.preheader ], [ %indvars.iv.next171, %._crit_edge139.us ]
  %.0106141.us = phi ptr [ %22, %.preheader.lr.ph.us.preheader ], [ %.2108.lcssa.us, %._crit_edge139.us ]
  %90 = mul nuw nsw i64 %indvars.iv170, %89
  %91 = getelementptr inbounds i8, ptr %4, i64 %90
  br label %.preheader.us

._crit_edge136.us:                                ; preds = %99, %.preheader.us
  %.2108.lcssa.us = phi ptr [ %.1107138.us, %.preheader.us ], [ %103, %99 ]
  %indvars.iv.next163 = add nuw nsw i64 %indvars.iv162, 1
  %exitcond169.not = icmp eq i64 %indvars.iv.next163, %88
  br i1 %exitcond169.not, label %._crit_edge139.us, label %.preheader.us, !llvm.loop !33

.lr.ph135.us:                                     ; preds = %.preheader.us, %99
  %indvars.iv164 = phi i64 [ %indvars.iv.next165, %99 ], [ %indvars.iv162, %.preheader.us ]
  %.2108134.us = phi ptr [ %103, %99 ], [ %.1107138.us, %.preheader.us ]
  %92 = trunc nuw i64 %indvars.iv164 to i32
  %.not115.us = icmp slt i32 %92, %1
  br i1 %.not115.us, label %93, label %99

93:                                               ; preds = %.lr.ph135.us
  %94 = getelementptr inbounds i8, ptr %2, i64 %indvars.iv164
  %95 = load i8, ptr %94, align 1, !tbaa !18
  %96 = zext i8 %95 to i64
  %97 = getelementptr inbounds i8, ptr %91, i64 %96
  %98 = load i8, ptr %97, align 1, !tbaa !18
  br label %99

99:                                               ; preds = %93, %.lr.ph135.us
  %100 = phi i8 [ %98, %93 ], [ 0, %.lr.ph135.us ]
  %101 = load i8, ptr %38, align 8, !tbaa !26
  %102 = add i8 %101, %100
  %103 = getelementptr inbounds i8, ptr %.2108134.us, i64 1
  store i8 %102, ptr %.2108134.us, align 1, !tbaa !18
  %indvars.iv.next165 = add nuw nsw i64 %indvars.iv164, %88
  %104 = trunc nuw i64 %indvars.iv.next165 to i32
  %105 = icmp sgt i32 %86, %104
  br i1 %105, label %.lr.ph135.us, label %._crit_edge136.us, !llvm.loop !34

.preheader.us:                                    ; preds = %.preheader.lr.ph.us, %._crit_edge136.us
  %indvars.iv162 = phi i64 [ 0, %.preheader.lr.ph.us ], [ %indvars.iv.next163, %._crit_edge136.us ]
  %.1107138.us = phi ptr [ %.0106141.us, %.preheader.lr.ph.us ], [ %.2108.lcssa.us, %._crit_edge136.us ]
  %indvars167 = trunc i64 %indvars.iv162 to i32
  %106 = icmp sgt i32 %86, %indvars167
  br i1 %106, label %.lr.ph135.us, label %._crit_edge136.us

._crit_edge139.us:                                ; preds = %._crit_edge136.us
  %indvars.iv.next171 = add nuw nsw i64 %indvars.iv170, 1
  %exitcond174.not = icmp eq i64 %indvars.iv.next171, %89
  br i1 %exitcond174.not, label %.loopexit, label %.preheader.lr.ph.us, !llvm.loop !35

.loopexit:                                        ; preds = %._crit_edge128.us, %._crit_edge139.us, %._crit_edge.thread, %.lr.ph143, %.lr.ph132, %.preheader118, %.preheader116
  ret ptr %18
}

; Function Attrs: mustprogress nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite)
declare noalias noundef ptr @malloc(i64 noundef) local_unnamed_addr #1

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.umax.i32(i32, i32) #2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i8 @llvm.smin.i8(i8, i8) #2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i8 @llvm.smax.i8(i8, i8) #2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare <16 x i8> @llvm.smin.v16i8(<16 x i8>, <16 x i8>) #2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare <16 x i8> @llvm.smax.v16i8(<16 x i8>, <16 x i8>) #2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i8 @llvm.vector.reduce.smax.v16i8(<16 x i8>) #2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i8 @llvm.vector.reduce.smin.v16i8(<16 x i8>) #2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare <8 x i8> @llvm.smin.v8i8(<8 x i8>, <8 x i8>) #2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare <8 x i8> @llvm.smax.v8i8(<8 x i8>, <8 x i8>) #2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i8 @llvm.vector.reduce.smax.v8i8(<8 x i8>) #2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i8 @llvm.vector.reduce.smin.v8i8(<8 x i8>) #2

attributes #0 = { nofree nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { mustprogress nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite) "alloc-family"="malloc" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #3 = { nounwind allocsize(0) }

!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 16}
!6 = !{!"_kswq_t", !7, i64 0, !7, i64 4, !8, i64 8, !8, i64 9, !8, i64 10, !8, i64 11, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"any pointer", !8, i64 0}
!11 = !{!6, !10, i64 24}
!12 = !{!6, !10, i64 32}
!13 = !{!6, !10, i64 40}
!14 = !{!6, !10, i64 48}
!15 = !{!6, !7, i64 4}
!16 = !{!6, !7, i64 0}
!17 = !{!6, !8, i64 11}
!18 = !{!8, !8, i64 0}
!19 = distinct !{!19, !20, !21, !22}
!20 = !{!"llvm.loop.mustprogress"}
!21 = !{!"llvm.loop.isvectorized", i32 1}
!22 = !{!"llvm.loop.unroll.runtime.disable"}
!23 = distinct !{!23, !20, !21, !22}
!24 = distinct !{!24, !20, !22, !21}
!25 = !{!6, !8, i64 10}
!26 = !{!6, !8, i64 8}
!27 = !{!6, !8, i64 9}
!28 = distinct !{!28, !20}
!29 = !{!30, !30, i64 0}
!30 = !{!"short", !8, i64 0}
!31 = distinct !{!31, !20}
!32 = distinct !{!32, !20}
!33 = distinct !{!33, !20}
!34 = distinct !{!34, !20}
!35 = distinct !{!35, !20}


; Effective O3 passes: ADCEPass,DSEPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopInstSimplifyPass,LoopLoadEliminationPass,LoopRotatePass,LoopSimplifyCFGPass,LoopSimplifyPass,LoopUnrollPass,LoopVectorizePass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass