; LLVM IR from sbu-fsl/kernel-ml :: examples (readahead_net_classification_training)

; 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.matrix = type { i32, i32, i32, %union.anon }
%union.anon = type { ptr }

@.str = external hidden unnamed_addr constant [91 x i8], align 1
@workload_names = external hidden constant [4 x [25 x i8]], align 16
@readahead_test_list = external hidden constant [12 x i32], align 16
@.str.1 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [100 x i8], align 1
@__PRETTY_FUNCTION__.preparing_ml_xy = external hidden unnamed_addr constant [27 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [3 x i8], align 1
@input_matrix = external hidden global ptr, align 8
@output_matrix = external hidden global ptr, align 8
@.str.5 = external hidden unnamed_addr constant [19 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local void @preparing_ml_xy() #0 {
  %1 = alloca ptr, align 8
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca float, align 4
  %7 = alloca [255 x i8], align 16
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca float, align 4
  %12 = alloca ptr, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %1) #6
  store ptr null, ptr %1, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #6
  store i32 0, ptr %2, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #6
  store i32 0, ptr %3, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #6
  store i32 0, ptr %4, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #6
  store i32 0, ptr %5, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #6
  store float 0.000000e+00, ptr %6, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 255, ptr %7) #6
  call void @llvm.memset.p0.i64(ptr align 16 %7, i8 0, i64 255, i1 false)
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #6
  store i32 0, ptr %3, align 4, !tbaa !9
  br label %13

13:                                               ; preds = %306, %0
  %14 = load i32, ptr %3, align 4, !tbaa !9
  %15 = icmp slt i32 %14, 4
  br i1 %15, label %16, label %309

16:                                               ; preds = %13
  store i32 0, ptr %2, align 4, !tbaa !9
  br label %17

17:                                               ; preds = %302, %16
  %18 = load i32, ptr %2, align 4, !tbaa !9
  %19 = sext i32 %18 to i64
  %20 = icmp ult i64 %19, 12
  br i1 %20, label %21, label %305

21:                                               ; preds = %17
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #6
  %22 = getelementptr inbounds [255 x i8], ptr %7, i64 0, i64 0
  %23 = load i32, ptr %3, align 4, !tbaa !9
  %24 = sext i32 %23 to i64
  %25 = getelementptr inbounds [4 x [25 x i8]], ptr @workload_names, i64 0, i64 %24
  %26 = getelementptr inbounds [25 x i8], ptr %25, i64 0, i64 0
  %27 = load i32, ptr %2, align 4, !tbaa !9
  %28 = sext i32 %27 to i64
  %29 = getelementptr inbounds [12 x i32], ptr @readahead_test_list, i64 0, i64 %28
  %30 = load i32, ptr %29, align 4, !tbaa !9
  %31 = call i32 (ptr, i64, ptr, ...) @snprintf(ptr noundef %22, i64 noundef 255, ptr noundef @.str, ptr noundef %26, i32 noundef %30) #6
  store i32 %31, ptr %9, align 4, !tbaa !9
  %32 = load i32, ptr %9, align 4, !tbaa !9
  %33 = icmp sgt i32 %32, 0
  br i1 %33, label %34, label %37

34:                                               ; preds = %21
  %35 = load i32, ptr %9, align 4, !tbaa !9
  %36 = icmp slt i32 %35, 255
  br i1 %36, label %38, label %37

37:                                               ; preds = %34, %21
  call void @__assert_fail(ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 46, ptr noundef @__PRETTY_FUNCTION__.preparing_ml_xy) #7
  unreachable

38:                                               ; preds = %34
  %39 = getelementptr inbounds [255 x i8], ptr %7, i64 0, i64 0
  %40 = call ptr @kml_file_open(ptr noundef %39, ptr noundef @.str.3, i32 noundef 0)
  store ptr %40, ptr %1, align 8, !tbaa !5
  %41 = load ptr, ptr %1, align 8, !tbaa !5
  %42 = call i32 (ptr, ptr, ...) @kml_fscanf(ptr noundef %41, ptr noundef @.str.4, ptr noundef %6)
  %43 = load float, ptr %6, align 4, !tbaa !11
  %44 = fptosi float %43 to i32
  store i32 %44, ptr %4, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #6
  store i32 0, ptr %10, align 4, !tbaa !9
  br label %45

45:                                               ; preds = %282, %38
  %46 = load i32, ptr %10, align 4, !tbaa !9
  %47 = load i32, ptr %4, align 4, !tbaa !9
  %48 = icmp slt i32 %46, %47
  br i1 %48, label %49, label %285

49:                                               ; preds = %45
  store i32 0, ptr %8, align 4, !tbaa !9
  br label %50

50:                                               ; preds = %143, %49
  %51 = load i32, ptr %8, align 4, !tbaa !9
  %52 = icmp slt i32 %51, 4
  br i1 %52, label %53, label %146

53:                                               ; preds = %50
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #6
  %54 = load ptr, ptr %1, align 8, !tbaa !5
  %55 = call i32 (ptr, ptr, ...) @kml_fscanf(ptr noundef %54, ptr noundef @.str.4, ptr noundef %11)
  %56 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %57 = getelementptr inbounds %struct.matrix, ptr %56, i32 0, i32 2
  %58 = load i32, ptr %57, align 8, !tbaa !13
  switch i32 %58, label %93 [
    i32 1, label %59
    i32 2, label %75
    i32 0, label %92
  ]

59:                                               ; preds = %53
  %60 = load float, ptr %11, align 4, !tbaa !11
  %61 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %62 = getelementptr inbounds %struct.matrix, ptr %61, i32 0, i32 3
  %63 = load ptr, ptr %62, align 8, !tbaa !15
  %64 = load i32, ptr %5, align 4, !tbaa !9
  %65 = load i32, ptr %10, align 4, !tbaa !9
  %66 = add nsw i32 %64, %65
  %67 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %68 = getelementptr inbounds %struct.matrix, ptr %67, i32 0, i32 1
  %69 = load i32, ptr %68, align 4, !tbaa !16
  %70 = mul nsw i32 %66, %69
  %71 = load i32, ptr %8, align 4, !tbaa !9
  %72 = add nsw i32 %70, %71
  %73 = sext i32 %72 to i64
  %74 = getelementptr inbounds float, ptr %63, i64 %73
  store float %60, ptr %74, align 4, !tbaa !11
  br label %93

75:                                               ; preds = %53
  %76 = load float, ptr %11, align 4, !tbaa !11
  %77 = fpext float %76 to double
  %78 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %79 = getelementptr inbounds %struct.matrix, ptr %78, i32 0, i32 3
  %80 = load ptr, ptr %79, align 8, !tbaa !15
  %81 = load i32, ptr %5, align 4, !tbaa !9
  %82 = load i32, ptr %10, align 4, !tbaa !9
  %83 = add nsw i32 %81, %82
  %84 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %85 = getelementptr inbounds %struct.matrix, ptr %84, i32 0, i32 1
  %86 = load i32, ptr %85, align 4, !tbaa !16
  %87 = mul nsw i32 %83, %86
  %88 = load i32, ptr %8, align 4, !tbaa !9
  %89 = add nsw i32 %87, %88
  %90 = sext i32 %89 to i64
  %91 = getelementptr inbounds double, ptr %80, i64 %90
  store double %77, ptr %91, align 8, !tbaa !17
  br label %93

92:                                               ; preds = %53
  call void @__assert_fail(ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 74, ptr noundef @__PRETTY_FUNCTION__.preparing_ml_xy) #7
  unreachable

93:                                               ; preds = %75, %59, %53
  %94 = load i32, ptr %3, align 4, !tbaa !9
  %95 = icmp eq i32 %94, 2
  br i1 %95, label %99, label %96

96:                                               ; preds = %93
  %97 = load i32, ptr %3, align 4, !tbaa !9
  %98 = icmp eq i32 %97, 3
  br i1 %98, label %99, label %142

99:                                               ; preds = %96, %93
  %100 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %101 = getelementptr inbounds %struct.matrix, ptr %100, i32 0, i32 2
  %102 = load i32, ptr %101, align 8, !tbaa !13
  switch i32 %102, label %141 [
    i32 1, label %103
    i32 2, label %121
    i32 0, label %140
  ]

103:                                              ; preds = %99
  %104 = load float, ptr %11, align 4, !tbaa !11
  %105 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %106 = getelementptr inbounds %struct.matrix, ptr %105, i32 0, i32 3
  %107 = load ptr, ptr %106, align 8, !tbaa !15
  %108 = load i32, ptr %5, align 4, !tbaa !9
  %109 = load i32, ptr %4, align 4, !tbaa !9
  %110 = add nsw i32 %108, %109
  %111 = load i32, ptr %10, align 4, !tbaa !9
  %112 = add nsw i32 %110, %111
  %113 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %114 = getelementptr inbounds %struct.matrix, ptr %113, i32 0, i32 1
  %115 = load i32, ptr %114, align 4, !tbaa !16
  %116 = mul nsw i32 %112, %115
  %117 = load i32, ptr %8, align 4, !tbaa !9
  %118 = add nsw i32 %116, %117
  %119 = sext i32 %118 to i64
  %120 = getelementptr inbounds float, ptr %107, i64 %119
  store float %104, ptr %120, align 4, !tbaa !11
  br label %141

121:                                              ; preds = %99
  %122 = load float, ptr %11, align 4, !tbaa !11
  %123 = fpext float %122 to double
  %124 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %125 = getelementptr inbounds %struct.matrix, ptr %124, i32 0, i32 3
  %126 = load ptr, ptr %125, align 8, !tbaa !15
  %127 = load i32, ptr %5, align 4, !tbaa !9
  %128 = load i32, ptr %4, align 4, !tbaa !9
  %129 = add nsw i32 %127, %128
  %130 = load i32, ptr %10, align 4, !tbaa !9
  %131 = add nsw i32 %129, %130
  %132 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %133 = getelementptr inbounds %struct.matrix, ptr %132, i32 0, i32 1
  %134 = load i32, ptr %133, align 4, !tbaa !16
  %135 = mul nsw i32 %131, %134
  %136 = load i32, ptr %8, align 4, !tbaa !9
  %137 = add nsw i32 %135, %136
  %138 = sext i32 %137 to i64
  %139 = getelementptr inbounds double, ptr %126, i64 %138
  store double %123, ptr %139, align 8, !tbaa !17
  br label %141

140:                                              ; preds = %99
  call void @__assert_fail(ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 90, ptr noundef @__PRETTY_FUNCTION__.preparing_ml_xy) #7
  unreachable

141:                                              ; preds = %121, %103, %99
  br label %142

142:                                              ; preds = %141, %96
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #6
  br label %143

143:                                              ; preds = %142
  %144 = load i32, ptr %8, align 4, !tbaa !9
  %145 = add nsw i32 %144, 1
  store i32 %145, ptr %8, align 4, !tbaa !9
  br label %50, !llvm.loop !19

146:                                              ; preds = %50
  %147 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %148 = getelementptr inbounds %struct.matrix, ptr %147, i32 0, i32 2
  %149 = load i32, ptr %148, align 8, !tbaa !13
  switch i32 %149, label %193 [
    i32 1, label %150
    i32 2, label %171
    i32 0, label %192
  ]

150:                                              ; preds = %146
  %151 = load i32, ptr %2, align 4, !tbaa !9
  %152 = sext i32 %151 to i64
  %153 = getelementptr inbounds [12 x i32], ptr @readahead_test_list, i64 0, i64 %152
  %154 = load i32, ptr %153, align 4, !tbaa !9
  %155 = sitofp i32 %154 to float
  %156 = fdiv float %155, 1.024000e+03
  %157 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %158 = getelementptr inbounds %struct.matrix, ptr %157, i32 0, i32 3
  %159 = load ptr, ptr %158, align 8, !tbaa !15
  %160 = load i32, ptr %5, align 4, !tbaa !9
  %161 = load i32, ptr %10, align 4, !tbaa !9
  %162 = add nsw i32 %160, %161
  %163 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %164 = getelementptr inbounds %struct.matrix, ptr %163, i32 0, i32 1
  %165 = load i32, ptr %164, align 4, !tbaa !16
  %166 = mul nsw i32 %162, %165
  %167 = load i32, ptr %8, align 4, !tbaa !9
  %168 = add nsw i32 %166, %167
  %169 = sext i32 %168 to i64
  %170 = getelementptr inbounds float, ptr %159, i64 %169
  store float %156, ptr %170, align 4, !tbaa !11
  br label %193

171:                                              ; preds = %146
  %172 = load i32, ptr %2, align 4, !tbaa !9
  %173 = sext i32 %172 to i64
  %174 = getelementptr inbounds [12 x i32], ptr @readahead_test_list, i64 0, i64 %173
  %175 = load i32, ptr %174, align 4, !tbaa !9
  %176 = sitofp i32 %175 to double
  %177 = fdiv double %176, 1.024000e+03
  %178 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %179 = getelementptr inbounds %struct.matrix, ptr %178, i32 0, i32 3
  %180 = load ptr, ptr %179, align 8, !tbaa !15
  %181 = load i32, ptr %5, align 4, !tbaa !9
  %182 = load i32, ptr %10, align 4, !tbaa !9
  %183 = add nsw i32 %181, %182
  %184 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %185 = getelementptr inbounds %struct.matrix, ptr %184, i32 0, i32 1
  %186 = load i32, ptr %185, align 4, !tbaa !16
  %187 = mul nsw i32 %183, %186
  %188 = load i32, ptr %8, align 4, !tbaa !9
  %189 = add nsw i32 %187, %188
  %190 = sext i32 %189 to i64
  %191 = getelementptr inbounds double, ptr %180, i64 %190
  store double %177, ptr %191, align 8, !tbaa !17
  br label %193

192:                                              ; preds = %146
  call void @__assert_fail(ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 107, ptr noundef @__PRETTY_FUNCTION__.preparing_ml_xy) #7
  unreachable

193:                                              ; preds = %171, %150, %146
  %194 = load i32, ptr %3, align 4, !tbaa !9
  %195 = load ptr, ptr @output_matrix, align 8, !tbaa !5
  %196 = getelementptr inbounds %struct.matrix, ptr %195, i32 0, i32 3
  %197 = load ptr, ptr %196, align 8, !tbaa !15
  %198 = load i32, ptr %5, align 4, !tbaa !9
  %199 = load i32, ptr %10, align 4, !tbaa !9
  %200 = add nsw i32 %198, %199
  %201 = load ptr, ptr @output_matrix, align 8, !tbaa !5
  %202 = getelementptr inbounds %struct.matrix, ptr %201, i32 0, i32 1
  %203 = load i32, ptr %202, align 4, !tbaa !16
  %204 = mul nsw i32 %200, %203
  %205 = add nsw i32 %204, 0
  %206 = sext i32 %205 to i64
  %207 = getelementptr inbounds i32, ptr %197, i64 %206
  store i32 %194, ptr %207, align 4, !tbaa !9
  %208 = load i32, ptr %3, align 4, !tbaa !9
  %209 = icmp eq i32 %208, 2
  br i1 %209, label %213, label %210

210:                                              ; preds = %193
  %211 = load i32, ptr %3, align 4, !tbaa !9
  %212 = icmp eq i32 %211, 3
  br i1 %212, label %213, label %281

213:                                              ; preds = %210, %193
  %214 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %215 = getelementptr inbounds %struct.matrix, ptr %214, i32 0, i32 2
  %216 = load i32, ptr %215, align 8, !tbaa !13
  switch i32 %216, label %264 [
    i32 1, label %217
    i32 2, label %240
    i32 0, label %263
  ]

217:                                              ; preds = %213
  %218 = load i32, ptr %2, align 4, !tbaa !9
  %219 = sext i32 %218 to i64
  %220 = getelementptr inbounds [12 x i32], ptr @readahead_test_list, i64 0, i64 %219
  %221 = load i32, ptr %220, align 4, !tbaa !9
  %222 = sitofp i32 %221 to float
  %223 = fdiv float %222, 1.024000e+03
  %224 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %225 = getelementptr inbounds %struct.matrix, ptr %224, i32 0, i32 3
  %226 = load ptr, ptr %225, align 8, !tbaa !15
  %227 = load i32, ptr %5, align 4, !tbaa !9
  %228 = load i32, ptr %4, align 4, !tbaa !9
  %229 = add nsw i32 %227, %228
  %230 = load i32, ptr %10, align 4, !tbaa !9
  %231 = add nsw i32 %229, %230
  %232 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %233 = getelementptr inbounds %struct.matrix, ptr %232, i32 0, i32 1
  %234 = load i32, ptr %233, align 4, !tbaa !16
  %235 = mul nsw i32 %231, %234
  %236 = load i32, ptr %8, align 4, !tbaa !9
  %237 = add nsw i32 %235, %236
  %238 = sext i32 %237 to i64
  %239 = getelementptr inbounds float, ptr %226, i64 %238
  store float %223, ptr %239, align 4, !tbaa !11
  br label %264

240:                                              ; preds = %213
  %241 = load i32, ptr %2, align 4, !tbaa !9
  %242 = sext i32 %241 to i64
  %243 = getelementptr inbounds [12 x i32], ptr @readahead_test_list, i64 0, i64 %242
  %244 = load i32, ptr %243, align 4, !tbaa !9
  %245 = sitofp i32 %244 to double
  %246 = fdiv double %245, 1.024000e+03
  %247 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %248 = getelementptr inbounds %struct.matrix, ptr %247, i32 0, i32 3
  %249 = load ptr, ptr %248, align 8, !tbaa !15
  %250 = load i32, ptr %5, align 4, !tbaa !9
  %251 = load i32, ptr %4, align 4, !tbaa !9
  %252 = add nsw i32 %250, %251
  %253 = load i32, ptr %10, align 4, !tbaa !9
  %254 = add nsw i32 %252, %253
  %255 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %256 = getelementptr inbounds %struct.matrix, ptr %255, i32 0, i32 1
  %257 = load i32, ptr %256, align 4, !tbaa !16
  %258 = mul nsw i32 %254, %257
  %259 = load i32, ptr %8, align 4, !tbaa !9
  %260 = add nsw i32 %258, %259
  %261 = sext i32 %260 to i64
  %262 = getelementptr inbounds double, ptr %249, i64 %261
  store double %246, ptr %262, align 8, !tbaa !17
  br label %264

263:                                              ; preds = %213
  call void @__assert_fail(ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 128, ptr noundef @__PRETTY_FUNCTION__.preparing_ml_xy) #7
  unreachable

264:                                              ; preds = %240, %217, %213
  %265 = load i32, ptr %3, align 4, !tbaa !9
  %266 = load ptr, ptr @output_matrix, align 8, !tbaa !5
  %267 = getelementptr inbounds %struct.matrix, ptr %266, i32 0, i32 3
  %268 = load ptr, ptr %267, align 8, !tbaa !15
  %269 = load i32, ptr %5, align 4, !tbaa !9
  %270 = load i32, ptr %4, align 4, !tbaa !9
  %271 = add nsw i32 %269, %270
  %272 = load i32, ptr %10, align 4, !tbaa !9
  %273 = add nsw i32 %271, %272
  %274 = load ptr, ptr @output_matrix, align 8, !tbaa !5
  %275 = getelementptr inbounds %struct.matrix, ptr %274, i32 0, i32 1
  %276 = load i32, ptr %275, align 4, !tbaa !16
  %277 = mul nsw i32 %273, %276
  %278 = add nsw i32 %277, 0
  %279 = sext i32 %278 to i64
  %280 = getelementptr inbounds i32, ptr %268, i64 %279
  store i32 %265, ptr %280, align 4, !tbaa !9
  br label %281

281:                                              ; preds = %264, %210
  br label %282

282:                                              ; preds = %281
  %283 = load i32, ptr %10, align 4, !tbaa !9
  %284 = add nsw i32 %283, 1
  store i32 %284, ptr %10, align 4, !tbaa !9
  br label %45, !llvm.loop !21

285:                                              ; preds = %45
  %286 = load ptr, ptr %1, align 8, !tbaa !5
  %287 = call i32 @kml_file_close(ptr noundef %286)
  %288 = load i32, ptr %3, align 4, !tbaa !9
  %289 = icmp eq i32 %288, 2
  br i1 %289, label %293, label %290

290:                                              ; preds = %285
  %291 = load i32, ptr %3, align 4, !tbaa !9
  %292 = icmp eq i32 %291, 3
  br i1 %292, label %293, label %296

293:                                              ; preds = %290, %285
  %294 = load i32, ptr %4, align 4, !tbaa !9
  %295 = mul nsw i32 %294, 2
  br label %298

296:                                              ; preds = %290
  %297 = load i32, ptr %4, align 4, !tbaa !9
  br label %298

298:                                              ; preds = %296, %293
  %299 = phi i32 [ %295, %293 ], [ %297, %296 ]
  %300 = load i32, ptr %5, align 4, !tbaa !9
  %301 = add nsw i32 %300, %299
  store i32 %301, ptr %5, align 4, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #6
  br label %302

302:                                              ; preds = %298
  %303 = load i32, ptr %2, align 4, !tbaa !9
  %304 = add nsw i32 %303, 1
  store i32 %304, ptr %2, align 4, !tbaa !9
  br label %17, !llvm.loop !22

305:                                              ; preds = %17
  br label %306

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

309:                                              ; preds = %13
  %310 = load i32, ptr %5, align 4, !tbaa !9
  %311 = call i32 (ptr, ...) @printf(ptr noundef @.str.5, i32 noundef %310)
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #6
  %312 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  store ptr %312, ptr %12, align 8, !tbaa !5
  %313 = load ptr, ptr @input_matrix, align 8, !tbaa !5
  %314 = call ptr @matrix_zscore(ptr noundef %313, i32 noundef 1)
  store ptr %314, ptr @input_matrix, align 8, !tbaa !5
  %315 = load ptr, ptr %12, align 8, !tbaa !5
  call void @free_matrix(ptr noundef %315)
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 255, ptr %7) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %1) #6
  ret void
}

; 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 nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #2

; Function Attrs: nounwind
declare i32 @snprintf(ptr noundef, i64 noundef, ptr noundef, ...) #3

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) #4

declare ptr @kml_file_open(ptr noundef, ptr noundef, i32 noundef) #5

declare i32 @kml_fscanf(ptr noundef, ptr noundef, ...) #5

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

declare i32 @kml_file_close(ptr noundef) #5

declare i32 @printf(ptr noundef, ...) #5

declare ptr @matrix_zscore(ptr noundef, i32 noundef) #5

declare void @free_matrix(ptr noundef) #5

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 = { nocallback nofree nounwind willreturn memory(argmem: write) }
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 = { noreturn 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 #5 = { "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 #6 = { nounwind }
attributes #7 = { noreturn nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"float", !7, i64 0}
!13 = !{!14, !10, i64 8}
!14 = !{!"matrix", !10, i64 0, !10, i64 4, !10, i64 8, !7, i64 16}
!15 = !{!7, !7, i64 0}
!16 = !{!14, !10, i64 4}
!17 = !{!18, !18, i64 0}
!18 = !{!"double", !7, i64 0}
!19 = distinct !{!19, !20}
!20 = !{!"llvm.loop.mustprogress"}
!21 = distinct !{!21, !20}
!22 = distinct !{!22, !20}
!23 = distinct !{!23, !20}


; 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 [91 x i8], align 1
@workload_names = external hidden constant [4 x [25 x i8]], align 16
@readahead_test_list = external hidden local_unnamed_addr constant [12 x i32], align 16
@.str.1 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [100 x i8], align 1
@__PRETTY_FUNCTION__.preparing_ml_xy = external hidden unnamed_addr constant [27 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [3 x i8], align 1
@input_matrix = external hidden local_unnamed_addr global ptr, align 8
@output_matrix = external hidden local_unnamed_addr global ptr, align 8
@.str.5 = external hidden unnamed_addr constant [19 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local void @preparing_ml_xy() local_unnamed_addr #0 {
  %1 = alloca float, align 4
  %2 = alloca [255 x i8], align 16
  %3 = alloca float, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %1) #6
  store float 0.000000e+00, ptr %1, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 255, ptr nonnull %2) #6
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(255) %2, i8 0, i64 255, i1 false)
  br label %.preheader79

.preheader79:                                     ; preds = %0, %330
  %indvars.iv103 = phi i64 [ 0, %0 ], [ %indvars.iv.next104, %330 ]
  %.07496 = phi i32 [ 0, %0 ], [ %329, %330 ]
  %4 = getelementptr inbounds [4 x [25 x i8]], ptr @workload_names, i64 0, i64 %indvars.iv103
  %or.cond3.not = icmp ult i64 %indvars.iv103, 2
  %or.cond7.not = icmp ugt i64 %indvars.iv103, 1
  %5 = zext i1 %or.cond7.not to i32
  %6 = trunc nuw nsw i64 %indvars.iv103 to i32
  br label %7

7:                                                ; preds = %.preheader79, %._crit_edge
  %indvars.iv = phi i64 [ 0, %.preheader79 ], [ %indvars.iv.next, %._crit_edge ]
  %.193 = phi i32 [ %.07496, %.preheader79 ], [ %329, %._crit_edge ]
  %8 = getelementptr inbounds [12 x i32], ptr @readahead_test_list, i64 0, i64 %indvars.iv
  %9 = load i32, ptr %8, align 4, !tbaa !9
  %10 = call i32 (ptr, i64, ptr, ...) @snprintf(ptr noundef nonnull dereferenceable(1) %2, i64 noundef 255, ptr noundef nonnull @.str, ptr noundef nonnull %4, i32 noundef %9) #6
  %11 = add i32 %10, -1
  %or.cond = icmp ult i32 %11, 254
  br i1 %or.cond, label %13, label %12

12:                                               ; preds = %7
  call void @__assert_fail(ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.2, i32 noundef 46, ptr noundef nonnull @__PRETTY_FUNCTION__.preparing_ml_xy) #7
  unreachable

13:                                               ; preds = %7
  %14 = call ptr @kml_file_open(ptr noundef nonnull %2, ptr noundef nonnull @.str.3, i32 noundef 0) #6
  %15 = call i32 (ptr, ptr, ...) @kml_fscanf(ptr noundef %14, ptr noundef nonnull @.str.4, ptr noundef nonnull %1) #6
  %16 = load float, ptr %1, align 4, !tbaa !5
  %17 = fptosi float %16 to i32
  %18 = icmp sgt i32 %17, 0
  br i1 %18, label %.preheader.lr.ph, label %._crit_edge

.preheader.lr.ph:                                 ; preds = %13
  %19 = add nsw i32 %.193, %17
  %20 = sitofp i32 %9 to double
  %21 = fmul double %20, 0x3F50000000000000
  %22 = sitofp i32 %9 to float
  %23 = fmul float %22, 0x3F50000000000000
  br label %.preheader

.preheader:                                       ; preds = %.preheader.lr.ph, %325
  %.092 = phi i32 [ 0, %.preheader.lr.ph ], [ %326, %325 ]
  %24 = add nsw i32 %.092, %.193
  %25 = add nsw i32 %19, %.092
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #6
  %26 = call i32 (ptr, ptr, ...) @kml_fscanf(ptr noundef %14, ptr noundef nonnull @.str.4, ptr noundef nonnull %3) #6
  %27 = load ptr, ptr @input_matrix, align 8, !tbaa !11
  %28 = getelementptr inbounds i8, ptr %27, i64 8
  %29 = load i32, ptr %28, align 8, !tbaa !13
  br i1 %or.cond3.not, label %.preheader.split.us.preheader, label %.preheader.split.preheader

.preheader.split.preheader:                       ; preds = %.preheader
  switch i32 %29, label %.preheader.split.1 [
    i32 1, label %124
    i32 2, label %138
    i32 0, label %.split.us
  ]

.preheader.split.us.preheader:                    ; preds = %.preheader
  switch i32 %29, label %.preheader.split.us.1 [
    i32 1, label %40
    i32 2, label %30
    i32 0, label %.split.us
  ]

30:                                               ; preds = %.preheader.split.us.preheader
  %31 = load float, ptr %3, align 4, !tbaa !5
  %32 = fpext float %31 to double
  %33 = getelementptr inbounds i8, ptr %27, i64 16
  %34 = load ptr, ptr %33, align 8, !tbaa !15
  %35 = getelementptr inbounds i8, ptr %27, i64 4
  %36 = load i32, ptr %35, align 4, !tbaa !16
  %37 = mul nsw i32 %36, %24
  %38 = sext i32 %37 to i64
  %39 = getelementptr inbounds double, ptr %34, i64 %38
  store double %32, ptr %39, align 8, !tbaa !17
  br label %.preheader.split.us.1

40:                                               ; preds = %.preheader.split.us.preheader
  %41 = load float, ptr %3, align 4, !tbaa !5
  %42 = getelementptr inbounds i8, ptr %27, i64 16
  %43 = load ptr, ptr %42, align 8, !tbaa !15
  %44 = getelementptr inbounds i8, ptr %27, i64 4
  %45 = load i32, ptr %44, align 4, !tbaa !16
  %46 = mul nsw i32 %45, %24
  %47 = sext i32 %46 to i64
  %48 = getelementptr inbounds float, ptr %43, i64 %47
  store float %41, ptr %48, align 4, !tbaa !5
  br label %.preheader.split.us.1

.preheader.split.us.1:                            ; preds = %40, %30, %.preheader.split.us.preheader
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #6
  %49 = call i32 (ptr, ptr, ...) @kml_fscanf(ptr noundef %14, ptr noundef nonnull @.str.4, ptr noundef nonnull %3) #6
  %50 = load ptr, ptr @input_matrix, align 8, !tbaa !11
  %51 = getelementptr inbounds i8, ptr %50, i64 8
  %52 = load i32, ptr %51, align 8, !tbaa !13
  switch i32 %52, label %.preheader.split.us.2 [
    i32 1, label %64
    i32 2, label %53
    i32 0, label %.split.us
  ]

53:                                               ; preds = %.preheader.split.us.1
  %54 = load float, ptr %3, align 4, !tbaa !5
  %55 = fpext float %54 to double
  %56 = getelementptr inbounds i8, ptr %50, i64 16
  %57 = load ptr, ptr %56, align 8, !tbaa !15
  %58 = getelementptr inbounds i8, ptr %50, i64 4
  %59 = load i32, ptr %58, align 4, !tbaa !16
  %60 = mul nsw i32 %59, %24
  %61 = sext i32 %60 to i64
  %62 = getelementptr double, ptr %57, i64 %61
  %63 = getelementptr i8, ptr %62, i64 8
  store double %55, ptr %63, align 8, !tbaa !17
  br label %.preheader.split.us.2

64:                                               ; preds = %.preheader.split.us.1
  %65 = load float, ptr %3, align 4, !tbaa !5
  %66 = getelementptr inbounds i8, ptr %50, i64 16
  %67 = load ptr, ptr %66, align 8, !tbaa !15
  %68 = getelementptr inbounds i8, ptr %50, i64 4
  %69 = load i32, ptr %68, align 4, !tbaa !16
  %70 = mul nsw i32 %69, %24
  %71 = sext i32 %70 to i64
  %72 = getelementptr float, ptr %67, i64 %71
  %73 = getelementptr i8, ptr %72, i64 4
  store float %65, ptr %73, align 4, !tbaa !5
  br label %.preheader.split.us.2

.preheader.split.us.2:                            ; preds = %64, %53, %.preheader.split.us.1
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #6
  %74 = call i32 (ptr, ptr, ...) @kml_fscanf(ptr noundef %14, ptr noundef nonnull @.str.4, ptr noundef nonnull %3) #6
  %75 = load ptr, ptr @input_matrix, align 8, !tbaa !11
  %76 = getelementptr inbounds i8, ptr %75, i64 8
  %77 = load i32, ptr %76, align 8, !tbaa !13
  switch i32 %77, label %.preheader.split.us.3 [
    i32 1, label %89
    i32 2, label %78
    i32 0, label %.split.us
  ]

78:                                               ; preds = %.preheader.split.us.2
  %79 = load float, ptr %3, align 4, !tbaa !5
  %80 = fpext float %79 to double
  %81 = getelementptr inbounds i8, ptr %75, i64 16
  %82 = load ptr, ptr %81, align 8, !tbaa !15
  %83 = getelementptr inbounds i8, ptr %75, i64 4
  %84 = load i32, ptr %83, align 4, !tbaa !16
  %85 = mul nsw i32 %84, %24
  %86 = sext i32 %85 to i64
  %87 = getelementptr double, ptr %82, i64 %86
  %88 = getelementptr i8, ptr %87, i64 16
  store double %80, ptr %88, align 8, !tbaa !17
  br label %.preheader.split.us.3

89:                                               ; preds = %.preheader.split.us.2
  %90 = load float, ptr %3, align 4, !tbaa !5
  %91 = getelementptr inbounds i8, ptr %75, i64 16
  %92 = load ptr, ptr %91, align 8, !tbaa !15
  %93 = getelementptr inbounds i8, ptr %75, i64 4
  %94 = load i32, ptr %93, align 4, !tbaa !16
  %95 = mul nsw i32 %94, %24
  %96 = sext i32 %95 to i64
  %97 = getelementptr float, ptr %92, i64 %96
  %98 = getelementptr i8, ptr %97, i64 8
  store float %90, ptr %98, align 4, !tbaa !5
  br label %.preheader.split.us.3

.preheader.split.us.3:                            ; preds = %89, %78, %.preheader.split.us.2
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #6
  %99 = call i32 (ptr, ptr, ...) @kml_fscanf(ptr noundef %14, ptr noundef nonnull @.str.4, ptr noundef nonnull %3) #6
  %100 = load ptr, ptr @input_matrix, align 8, !tbaa !11
  %101 = getelementptr inbounds i8, ptr %100, i64 8
  %102 = load i32, ptr %101, align 8, !tbaa !13
  switch i32 %102, label %.split91.us.loopexit [
    i32 1, label %114
    i32 2, label %103
    i32 0, label %.split.us
  ]

103:                                              ; preds = %.preheader.split.us.3
  %104 = load float, ptr %3, align 4, !tbaa !5
  %105 = fpext float %104 to double
  %106 = getelementptr inbounds i8, ptr %100, i64 16
  %107 = load ptr, ptr %106, align 8, !tbaa !15
  %108 = getelementptr inbounds i8, ptr %100, i64 4
  %109 = load i32, ptr %108, align 4, !tbaa !16
  %110 = mul nsw i32 %109, %24
  %111 = sext i32 %110 to i64
  %112 = getelementptr double, ptr %107, i64 %111
  %113 = getelementptr i8, ptr %112, i64 24
  store double %105, ptr %113, align 8, !tbaa !17
  br label %.split91.us.loopexit

114:                                              ; preds = %.preheader.split.us.3
  %115 = load float, ptr %3, align 4, !tbaa !5
  %116 = getelementptr inbounds i8, ptr %100, i64 16
  %117 = load ptr, ptr %116, align 8, !tbaa !15
  %118 = getelementptr inbounds i8, ptr %100, i64 4
  %119 = load i32, ptr %118, align 4, !tbaa !16
  %120 = mul nsw i32 %119, %24
  %121 = sext i32 %120 to i64
  %122 = getelementptr float, ptr %117, i64 %121
  %123 = getelementptr i8, ptr %122, i64 12
  store float %115, ptr %123, align 4, !tbaa !5
  br label %.split91.us.loopexit

.split91.us.loopexit:                             ; preds = %114, %103, %.preheader.split.us.3
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #6
  br label %.split91.us

.split.us:                                        ; preds = %.preheader.split.preheader, %.preheader.split.1, %.preheader.split.2, %.preheader.split.3, %.preheader.split.us.preheader, %.preheader.split.us.1, %.preheader.split.us.2, %.preheader.split.us.3
  call void @__assert_fail(ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.2, i32 noundef 74, ptr noundef nonnull @__PRETTY_FUNCTION__.preparing_ml_xy) #7
  unreachable

124:                                              ; preds = %.preheader.split.preheader
  %125 = load float, ptr %3, align 4, !tbaa !5
  %126 = getelementptr inbounds i8, ptr %27, i64 16
  %127 = load ptr, ptr %126, align 8, !tbaa !15
  %128 = getelementptr inbounds i8, ptr %27, i64 4
  %129 = load i32, ptr %128, align 4, !tbaa !16
  %130 = mul nsw i32 %129, %24
  %131 = sext i32 %130 to i64
  %132 = getelementptr inbounds float, ptr %127, i64 %131
  store float %125, ptr %132, align 4, !tbaa !5
  %133 = getelementptr inbounds i8, ptr %27, i64 16
  %134 = load ptr, ptr %133, align 8, !tbaa !15
  %135 = mul nsw i32 %129, %25
  %136 = sext i32 %135 to i64
  %137 = getelementptr inbounds float, ptr %134, i64 %136
  store float %125, ptr %137, align 4, !tbaa !5
  br label %.preheader.split.1

138:                                              ; preds = %.preheader.split.preheader
  %139 = load float, ptr %3, align 4, !tbaa !5
  %140 = fpext float %139 to double
  %141 = getelementptr inbounds i8, ptr %27, i64 16
  %142 = load ptr, ptr %141, align 8, !tbaa !15
  %143 = getelementptr inbounds i8, ptr %27, i64 4
  %144 = load i32, ptr %143, align 4, !tbaa !16
  %145 = mul nsw i32 %144, %24
  %146 = sext i32 %145 to i64
  %147 = getelementptr inbounds double, ptr %142, i64 %146
  store double %140, ptr %147, align 8, !tbaa !17
  %148 = fpext float %139 to double
  %149 = getelementptr inbounds i8, ptr %27, i64 16
  %150 = load ptr, ptr %149, align 8, !tbaa !15
  %151 = mul nsw i32 %144, %25
  %152 = sext i32 %151 to i64
  %153 = getelementptr inbounds double, ptr %150, i64 %152
  store double %148, ptr %153, align 8, !tbaa !17
  br label %.preheader.split.1

.preheader.split.1:                               ; preds = %.preheader.split.preheader, %124, %138
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #6
  %154 = call i32 (ptr, ptr, ...) @kml_fscanf(ptr noundef %14, ptr noundef nonnull @.str.4, ptr noundef nonnull %3) #6
  %155 = load ptr, ptr @input_matrix, align 8, !tbaa !11
  %156 = getelementptr inbounds i8, ptr %155, i64 8
  %157 = load i32, ptr %156, align 8, !tbaa !13
  switch i32 %157, label %.preheader.split.2 [
    i32 1, label %176
    i32 2, label %158
    i32 0, label %.split.us
  ]

158:                                              ; preds = %.preheader.split.1
  %159 = load float, ptr %3, align 4, !tbaa !5
  %160 = fpext float %159 to double
  %161 = getelementptr inbounds i8, ptr %155, i64 16
  %162 = load ptr, ptr %161, align 8, !tbaa !15
  %163 = getelementptr inbounds i8, ptr %155, i64 4
  %164 = load i32, ptr %163, align 4, !tbaa !16
  %165 = mul nsw i32 %164, %24
  %166 = sext i32 %165 to i64
  %167 = getelementptr double, ptr %162, i64 %166
  %168 = getelementptr i8, ptr %167, i64 8
  store double %160, ptr %168, align 8, !tbaa !17
  %169 = fpext float %159 to double
  %170 = getelementptr inbounds i8, ptr %155, i64 16
  %171 = load ptr, ptr %170, align 8, !tbaa !15
  %172 = mul nsw i32 %164, %25
  %173 = sext i32 %172 to i64
  %174 = getelementptr double, ptr %171, i64 %173
  %175 = getelementptr i8, ptr %174, i64 8
  store double %169, ptr %175, align 8, !tbaa !17
  br label %.preheader.split.2

176:                                              ; preds = %.preheader.split.1
  %177 = load float, ptr %3, align 4, !tbaa !5
  %178 = getelementptr inbounds i8, ptr %155, i64 16
  %179 = load ptr, ptr %178, align 8, !tbaa !15
  %180 = getelementptr inbounds i8, ptr %155, i64 4
  %181 = load i32, ptr %180, align 4, !tbaa !16
  %182 = mul nsw i32 %181, %24
  %183 = sext i32 %182 to i64
  %184 = getelementptr float, ptr %179, i64 %183
  %185 = getelementptr i8, ptr %184, i64 4
  store float %177, ptr %185, align 4, !tbaa !5
  %186 = getelementptr inbounds i8, ptr %155, i64 16
  %187 = load ptr, ptr %186, align 8, !tbaa !15
  %188 = mul nsw i32 %181, %25
  %189 = sext i32 %188 to i64
  %190 = getelementptr float, ptr %187, i64 %189
  %191 = getelementptr i8, ptr %190, i64 4
  store float %177, ptr %191, align 4, !tbaa !5
  br label %.preheader.split.2

.preheader.split.2:                               ; preds = %176, %158, %.preheader.split.1
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #6
  %192 = call i32 (ptr, ptr, ...) @kml_fscanf(ptr noundef %14, ptr noundef nonnull @.str.4, ptr noundef nonnull %3) #6
  %193 = load ptr, ptr @input_matrix, align 8, !tbaa !11
  %194 = getelementptr inbounds i8, ptr %193, i64 8
  %195 = load i32, ptr %194, align 8, !tbaa !13
  switch i32 %195, label %.preheader.split.3 [
    i32 1, label %214
    i32 2, label %196
    i32 0, label %.split.us
  ]

196:                                              ; preds = %.preheader.split.2
  %197 = load float, ptr %3, align 4, !tbaa !5
  %198 = fpext float %197 to double
  %199 = getelementptr inbounds i8, ptr %193, i64 16
  %200 = load ptr, ptr %199, align 8, !tbaa !15
  %201 = getelementptr inbounds i8, ptr %193, i64 4
  %202 = load i32, ptr %201, align 4, !tbaa !16
  %203 = mul nsw i32 %202, %24
  %204 = sext i32 %203 to i64
  %205 = getelementptr double, ptr %200, i64 %204
  %206 = getelementptr i8, ptr %205, i64 16
  store double %198, ptr %206, align 8, !tbaa !17
  %207 = fpext float %197 to double
  %208 = getelementptr inbounds i8, ptr %193, i64 16
  %209 = load ptr, ptr %208, align 8, !tbaa !15
  %210 = mul nsw i32 %202, %25
  %211 = sext i32 %210 to i64
  %212 = getelementptr double, ptr %209, i64 %211
  %213 = getelementptr i8, ptr %212, i64 16
  store double %207, ptr %213, align 8, !tbaa !17
  br label %.preheader.split.3

214:                                              ; preds = %.preheader.split.2
  %215 = load float, ptr %3, align 4, !tbaa !5
  %216 = getelementptr inbounds i8, ptr %193, i64 16
  %217 = load ptr, ptr %216, align 8, !tbaa !15
  %218 = getelementptr inbounds i8, ptr %193, i64 4
  %219 = load i32, ptr %218, align 4, !tbaa !16
  %220 = mul nsw i32 %219, %24
  %221 = sext i32 %220 to i64
  %222 = getelementptr float, ptr %217, i64 %221
  %223 = getelementptr i8, ptr %222, i64 8
  store float %215, ptr %223, align 4, !tbaa !5
  %224 = getelementptr inbounds i8, ptr %193, i64 16
  %225 = load ptr, ptr %224, align 8, !tbaa !15
  %226 = mul nsw i32 %219, %25
  %227 = sext i32 %226 to i64
  %228 = getelementptr float, ptr %225, i64 %227
  %229 = getelementptr i8, ptr %228, i64 8
  store float %215, ptr %229, align 4, !tbaa !5
  br label %.preheader.split.3

.preheader.split.3:                               ; preds = %214, %196, %.preheader.split.2
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #6
  %230 = call i32 (ptr, ptr, ...) @kml_fscanf(ptr noundef %14, ptr noundef nonnull @.str.4, ptr noundef nonnull %3) #6
  %231 = load ptr, ptr @input_matrix, align 8, !tbaa !11
  %232 = getelementptr inbounds i8, ptr %231, i64 8
  %233 = load i32, ptr %232, align 8, !tbaa !13
  switch i32 %233, label %.split91.us.loopexit98 [
    i32 1, label %252
    i32 2, label %234
    i32 0, label %.split.us
  ]

234:                                              ; preds = %.preheader.split.3
  %235 = load float, ptr %3, align 4, !tbaa !5
  %236 = fpext float %235 to double
  %237 = getelementptr inbounds i8, ptr %231, i64 16
  %238 = load ptr, ptr %237, align 8, !tbaa !15
  %239 = getelementptr inbounds i8, ptr %231, i64 4
  %240 = load i32, ptr %239, align 4, !tbaa !16
  %241 = mul nsw i32 %240, %24
  %242 = sext i32 %241 to i64
  %243 = getelementptr double, ptr %238, i64 %242
  %244 = getelementptr i8, ptr %243, i64 24
  store double %236, ptr %244, align 8, !tbaa !17
  %245 = fpext float %235 to double
  %246 = getelementptr inbounds i8, ptr %231, i64 16
  %247 = load ptr, ptr %246, align 8, !tbaa !15
  %248 = mul nsw i32 %240, %25
  %249 = sext i32 %248 to i64
  %250 = getelementptr double, ptr %247, i64 %249
  %251 = getelementptr i8, ptr %250, i64 24
  store double %245, ptr %251, align 8, !tbaa !17
  br label %.split91.us.loopexit98

252:                                              ; preds = %.preheader.split.3
  %253 = load float, ptr %3, align 4, !tbaa !5
  %254 = getelementptr inbounds i8, ptr %231, i64 16
  %255 = load ptr, ptr %254, align 8, !tbaa !15
  %256 = getelementptr inbounds i8, ptr %231, i64 4
  %257 = load i32, ptr %256, align 4, !tbaa !16
  %258 = mul nsw i32 %257, %24
  %259 = sext i32 %258 to i64
  %260 = getelementptr float, ptr %255, i64 %259
  %261 = getelementptr i8, ptr %260, i64 12
  store float %253, ptr %261, align 4, !tbaa !5
  %262 = getelementptr inbounds i8, ptr %231, i64 16
  %263 = load ptr, ptr %262, align 8, !tbaa !15
  %264 = mul nsw i32 %257, %25
  %265 = sext i32 %264 to i64
  %266 = getelementptr float, ptr %263, i64 %265
  %267 = getelementptr i8, ptr %266, i64 12
  store float %253, ptr %267, align 4, !tbaa !5
  br label %.split91.us.loopexit98

.split91.us.loopexit98:                           ; preds = %252, %234, %.preheader.split.3
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #6
  br label %.split91.us

.split91.us:                                      ; preds = %.split91.us.loopexit98, %.split91.us.loopexit
  %268 = phi i32 [ %233, %.split91.us.loopexit98 ], [ %102, %.split91.us.loopexit ]
  %269 = phi ptr [ %231, %.split91.us.loopexit98 ], [ %100, %.split91.us.loopexit ]
  %270 = getelementptr inbounds i8, ptr %269, i64 8
  switch i32 %268, label %289 [
    i32 1, label %271
    i32 2, label %280
  ]

271:                                              ; preds = %.split91.us
  %272 = getelementptr inbounds i8, ptr %269, i64 16
  %273 = load ptr, ptr %272, align 8, !tbaa !15
  %274 = getelementptr inbounds i8, ptr %269, i64 4
  %275 = load i32, ptr %274, align 4, !tbaa !16
  %276 = mul nsw i32 %275, %24
  %277 = sext i32 %276 to i64
  %278 = getelementptr float, ptr %273, i64 %277
  %279 = getelementptr i8, ptr %278, i64 16
  store float %23, ptr %279, align 4, !tbaa !5
  br label %289

280:                                              ; preds = %.split91.us
  %281 = getelementptr inbounds i8, ptr %269, i64 16
  %282 = load ptr, ptr %281, align 8, !tbaa !15
  %283 = getelementptr inbounds i8, ptr %269, i64 4
  %284 = load i32, ptr %283, align 4, !tbaa !16
  %285 = mul nsw i32 %284, %24
  %286 = sext i32 %285 to i64
  %287 = getelementptr double, ptr %282, i64 %286
  %288 = getelementptr i8, ptr %287, i64 32
  store double %21, ptr %288, align 8, !tbaa !17
  br label %289

289:                                              ; preds = %280, %271, %.split91.us
  %290 = load ptr, ptr @output_matrix, align 8, !tbaa !11
  %291 = getelementptr inbounds i8, ptr %290, i64 16
  %292 = load ptr, ptr %291, align 8, !tbaa !15
  %293 = getelementptr inbounds i8, ptr %290, i64 4
  %294 = load i32, ptr %293, align 4, !tbaa !16
  %295 = mul nsw i32 %294, %24
  %296 = sext i32 %295 to i64
  %297 = getelementptr inbounds i32, ptr %292, i64 %296
  store i32 %6, ptr %297, align 4, !tbaa !9
  br i1 %or.cond3.not, label %325, label %298

298:                                              ; preds = %289
  %299 = load i32, ptr %270, align 8, !tbaa !13
  switch i32 %299, label %319 [
    i32 1, label %300
    i32 2, label %309
    i32 0, label %318
  ]

300:                                              ; preds = %298
  %301 = getelementptr inbounds i8, ptr %269, i64 16
  %302 = load ptr, ptr %301, align 8, !tbaa !15
  %303 = getelementptr inbounds i8, ptr %269, i64 4
  %304 = load i32, ptr %303, align 4, !tbaa !16
  %305 = mul nsw i32 %304, %25
  %306 = sext i32 %305 to i64
  %307 = getelementptr float, ptr %302, i64 %306
  %308 = getelementptr i8, ptr %307, i64 16
  store float %23, ptr %308, align 4, !tbaa !5
  br label %319

309:                                              ; preds = %298
  %310 = getelementptr inbounds i8, ptr %269, i64 16
  %311 = load ptr, ptr %310, align 8, !tbaa !15
  %312 = getelementptr inbounds i8, ptr %269, i64 4
  %313 = load i32, ptr %312, align 4, !tbaa !16
  %314 = mul nsw i32 %313, %25
  %315 = sext i32 %314 to i64
  %316 = getelementptr double, ptr %311, i64 %315
  %317 = getelementptr i8, ptr %316, i64 32
  store double %21, ptr %317, align 8, !tbaa !17
  br label %319

318:                                              ; preds = %298
  call void @__assert_fail(ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.2, i32 noundef 128, ptr noundef nonnull @__PRETTY_FUNCTION__.preparing_ml_xy) #7
  unreachable

319:                                              ; preds = %309, %300, %298
  %320 = load ptr, ptr %291, align 8, !tbaa !15
  %321 = load i32, ptr %293, align 4, !tbaa !16
  %322 = mul nsw i32 %321, %25
  %323 = sext i32 %322 to i64
  %324 = getelementptr inbounds i32, ptr %320, i64 %323
  store i32 %6, ptr %324, align 4, !tbaa !9
  br label %325

325:                                              ; preds = %319, %289
  %326 = add nuw nsw i32 %.092, 1
  %exitcond.not = icmp eq i32 %326, %17
  br i1 %exitcond.not, label %._crit_edge, label %.preheader, !llvm.loop !19

._crit_edge:                                      ; preds = %325, %13
  %327 = call i32 @kml_file_close(ptr noundef %14) #6
  %328 = shl nsw i32 %17, %5
  %329 = add nsw i32 %328, %.193
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond102.not = icmp eq i64 %indvars.iv.next, 12
  br i1 %exitcond102.not, label %330, label %7, !llvm.loop !21

330:                                              ; preds = %._crit_edge
  %indvars.iv.next104 = add nuw nsw i64 %indvars.iv103, 1
  %exitcond106.not = icmp eq i64 %indvars.iv.next104, 4
  br i1 %exitcond106.not, label %331, label %.preheader79, !llvm.loop !22

331:                                              ; preds = %330
  %332 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.5, i32 noundef %329)
  %333 = load ptr, ptr @input_matrix, align 8, !tbaa !11
  %334 = call ptr @matrix_zscore(ptr noundef %333, i32 noundef 1) #6
  store ptr %334, ptr @input_matrix, align 8, !tbaa !11
  call void @free_matrix(ptr noundef %333) #6
  call void @llvm.lifetime.end.p0(i64 255, ptr nonnull %2) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %1) #6
  ret void
}

; 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 nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #2

; Function Attrs: nofree nounwind
declare noundef i32 @snprintf(ptr noalias nocapture noundef writeonly, i64 noundef, ptr nocapture noundef readonly, ...) local_unnamed_addr #3

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #4

declare ptr @kml_file_open(ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #5

declare i32 @kml_fscanf(ptr noundef, ptr noundef, ...) local_unnamed_addr #5

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

declare i32 @kml_file_close(ptr noundef) local_unnamed_addr #5

; Function Attrs: nofree nounwind
declare noundef i32 @printf(ptr nocapture noundef readonly, ...) local_unnamed_addr #3

declare ptr @matrix_zscore(ptr noundef, i32 noundef) local_unnamed_addr #5

declare void @free_matrix(ptr noundef) local_unnamed_addr #5

attributes #0 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #3 = { nofree 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 = { noreturn 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 #5 = { "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 #6 = { nounwind }
attributes #7 = { noreturn 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 = !{!"float", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"any pointer", !7, i64 0}
!13 = !{!14, !10, i64 8}
!14 = !{!"matrix", !10, i64 0, !10, i64 4, !10, i64 8, !7, i64 16}
!15 = !{!7, !7, i64 0}
!16 = !{!14, !10, i64 4}
!17 = !{!18, !18, i64 0}
!18 = !{!"double", !7, i64 0}
!19 = distinct !{!19, !20}
!20 = !{!"llvm.loop.mustprogress"}
!21 = distinct !{!21, !20}
!22 = distinct !{!22, !20}


; Effective O3 passes: BDCEPass,CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopRotatePass,LoopSimplifyCFGPass,LoopSimplifyPass,LoopUnrollPass,ReassociatePass,SROAPass,SimplifyCFGPass