; LLVM IR from CLASS-SZ/class_sz :: class-sz/tools (r8lib)

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

@stderr = external global ptr, align 8
@.str = external hidden unnamed_addr constant [2 x i8], align 1
@.str.99 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.157 = external hidden unnamed_addr constant [30 x i8], align 1

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

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

; Function Attrs: nounwind
declare i32 @fprintf(ptr noundef, ptr noundef, ...) #1

; Function Attrs: noreturn nounwind
declare void @exit(i32 noundef) #2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #3

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fabs.f64(double) #3

; Function Attrs: nounwind uwtable
declare dso_local ptr @r8vec_copy_new(i32 noundef, ptr noundef) #4

; Function Attrs: nounwind uwtable
declare dso_local ptr @r8rmat_copy_new(i32 noundef, i32 noundef, ptr noundef) #4

; Function Attrs: nounwind uwtable
declare dso_local void @r8rmat_delete(i32 noundef, i32 noundef, ptr noundef) #4

; Function Attrs: nounwind uwtable
define dso_local ptr @r8rmat_fs_new(i32 noundef %0, ptr noundef %1, ptr noundef %2) #4 {
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca double, align 8
  %13 = alloca ptr, align 8
  store i32 %0, ptr %4, align 4, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !9
  store ptr %2, ptr %6, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #5
  %14 = load i32, ptr %4, align 4, !tbaa !5
  %15 = load i32, ptr %4, align 4, !tbaa !5
  %16 = load ptr, ptr %5, align 8, !tbaa !9
  %17 = call ptr @r8rmat_copy_new(i32 noundef %14, i32 noundef %15, ptr noundef %16)
  store ptr %17, ptr %7, align 8, !tbaa !9
  %18 = load i32, ptr %4, align 4, !tbaa !5
  %19 = load ptr, ptr %6, align 8, !tbaa !9
  %20 = call ptr @r8vec_copy_new(i32 noundef %18, ptr noundef %19)
  store ptr %20, ptr %13, align 8, !tbaa !9
  store i32 0, ptr %10, align 4, !tbaa !5
  br label %21

21:                                               ; preds = %303, %3
  %22 = load i32, ptr %10, align 4, !tbaa !5
  %23 = load i32, ptr %4, align 4, !tbaa !5
  %24 = icmp slt i32 %22, %23
  br i1 %24, label %25, label %306

25:                                               ; preds = %21
  %26 = load i32, ptr %10, align 4, !tbaa !5
  store i32 %26, ptr %11, align 4, !tbaa !5
  %27 = load i32, ptr %10, align 4, !tbaa !5
  %28 = add nsw i32 %27, 1
  store i32 %28, ptr %8, align 4, !tbaa !5
  br label %29

29:                                               ; preds = %58, %25
  %30 = load i32, ptr %8, align 4, !tbaa !5
  %31 = load i32, ptr %4, align 4, !tbaa !5
  %32 = icmp slt i32 %30, %31
  br i1 %32, label %33, label %61

33:                                               ; preds = %29
  %34 = load ptr, ptr %7, align 8, !tbaa !9
  %35 = load i32, ptr %11, align 4, !tbaa !5
  %36 = sext i32 %35 to i64
  %37 = getelementptr inbounds ptr, ptr %34, i64 %36
  %38 = load ptr, ptr %37, align 8, !tbaa !9
  %39 = load i32, ptr %10, align 4, !tbaa !5
  %40 = sext i32 %39 to i64
  %41 = getelementptr inbounds double, ptr %38, i64 %40
  %42 = load double, ptr %41, align 8, !tbaa !11
  %43 = call double @llvm.fabs.f64(double %42)
  %44 = load ptr, ptr %7, align 8, !tbaa !9
  %45 = load i32, ptr %8, align 4, !tbaa !5
  %46 = sext i32 %45 to i64
  %47 = getelementptr inbounds ptr, ptr %44, i64 %46
  %48 = load ptr, ptr %47, align 8, !tbaa !9
  %49 = load i32, ptr %10, align 4, !tbaa !5
  %50 = sext i32 %49 to i64
  %51 = getelementptr inbounds double, ptr %48, i64 %50
  %52 = load double, ptr %51, align 8, !tbaa !11
  %53 = call double @llvm.fabs.f64(double %52)
  %54 = fcmp olt double %43, %53
  br i1 %54, label %55, label %57

55:                                               ; preds = %33
  %56 = load i32, ptr %8, align 4, !tbaa !5
  store i32 %56, ptr %11, align 4, !tbaa !5
  br label %57

57:                                               ; preds = %55, %33
  br label %58

58:                                               ; preds = %57
  %59 = load i32, ptr %8, align 4, !tbaa !5
  %60 = add nsw i32 %59, 1
  store i32 %60, ptr %8, align 4, !tbaa !5
  br label %29, !llvm.loop !13

61:                                               ; preds = %29
  %62 = load ptr, ptr %7, align 8, !tbaa !9
  %63 = load i32, ptr %11, align 4, !tbaa !5
  %64 = sext i32 %63 to i64
  %65 = getelementptr inbounds ptr, ptr %62, i64 %64
  %66 = load ptr, ptr %65, align 8, !tbaa !9
  %67 = load i32, ptr %10, align 4, !tbaa !5
  %68 = sext i32 %67 to i64
  %69 = getelementptr inbounds double, ptr %66, i64 %68
  %70 = load double, ptr %69, align 8, !tbaa !11
  %71 = fcmp oeq double %70, 0.000000e+00
  br i1 %71, label %72, label %80

72:                                               ; preds = %61
  %73 = load ptr, ptr @stderr, align 8, !tbaa !9
  %74 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %73, ptr noundef @.str) #5
  %75 = load ptr, ptr @stderr, align 8, !tbaa !9
  %76 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %75, ptr noundef @.str.157) #5
  %77 = load ptr, ptr @stderr, align 8, !tbaa !9
  %78 = load i32, ptr %10, align 4, !tbaa !5
  %79 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %77, ptr noundef @.str.99, i32 noundef %78) #5
  call void @exit(i32 noundef 1) #6
  unreachable

80:                                               ; preds = %61
  %81 = load i32, ptr %10, align 4, !tbaa !5
  %82 = load i32, ptr %11, align 4, !tbaa !5
  %83 = icmp ne i32 %81, %82
  br i1 %83, label %84, label %148

84:                                               ; preds = %80
  store i32 0, ptr %9, align 4, !tbaa !5
  br label %85

85:                                               ; preds = %125, %84
  %86 = load i32, ptr %9, align 4, !tbaa !5
  %87 = load i32, ptr %4, align 4, !tbaa !5
  %88 = icmp slt i32 %86, %87
  br i1 %88, label %89, label %128

89:                                               ; preds = %85
  %90 = load ptr, ptr %7, align 8, !tbaa !9
  %91 = load i32, ptr %10, align 4, !tbaa !5
  %92 = sext i32 %91 to i64
  %93 = getelementptr inbounds ptr, ptr %90, i64 %92
  %94 = load ptr, ptr %93, align 8, !tbaa !9
  %95 = load i32, ptr %9, align 4, !tbaa !5
  %96 = sext i32 %95 to i64
  %97 = getelementptr inbounds double, ptr %94, i64 %96
  %98 = load double, ptr %97, align 8, !tbaa !11
  store double %98, ptr %12, align 8, !tbaa !11
  %99 = load ptr, ptr %7, align 8, !tbaa !9
  %100 = load i32, ptr %11, align 4, !tbaa !5
  %101 = sext i32 %100 to i64
  %102 = getelementptr inbounds ptr, ptr %99, i64 %101
  %103 = load ptr, ptr %102, align 8, !tbaa !9
  %104 = load i32, ptr %9, align 4, !tbaa !5
  %105 = sext i32 %104 to i64
  %106 = getelementptr inbounds double, ptr %103, i64 %105
  %107 = load double, ptr %106, align 8, !tbaa !11
  %108 = load ptr, ptr %7, align 8, !tbaa !9
  %109 = load i32, ptr %10, align 4, !tbaa !5
  %110 = sext i32 %109 to i64
  %111 = getelementptr inbounds ptr, ptr %108, i64 %110
  %112 = load ptr, ptr %111, align 8, !tbaa !9
  %113 = load i32, ptr %9, align 4, !tbaa !5
  %114 = sext i32 %113 to i64
  %115 = getelementptr inbounds double, ptr %112, i64 %114
  store double %107, ptr %115, align 8, !tbaa !11
  %116 = load double, ptr %12, align 8, !tbaa !11
  %117 = load ptr, ptr %7, align 8, !tbaa !9
  %118 = load i32, ptr %11, align 4, !tbaa !5
  %119 = sext i32 %118 to i64
  %120 = getelementptr inbounds ptr, ptr %117, i64 %119
  %121 = load ptr, ptr %120, align 8, !tbaa !9
  %122 = load i32, ptr %9, align 4, !tbaa !5
  %123 = sext i32 %122 to i64
  %124 = getelementptr inbounds double, ptr %121, i64 %123
  store double %116, ptr %124, align 8, !tbaa !11
  br label %125

125:                                              ; preds = %89
  %126 = load i32, ptr %9, align 4, !tbaa !5
  %127 = add nsw i32 %126, 1
  store i32 %127, ptr %9, align 4, !tbaa !5
  br label %85, !llvm.loop !15

128:                                              ; preds = %85
  %129 = load ptr, ptr %13, align 8, !tbaa !9
  %130 = load i32, ptr %10, align 4, !tbaa !5
  %131 = sext i32 %130 to i64
  %132 = getelementptr inbounds double, ptr %129, i64 %131
  %133 = load double, ptr %132, align 8, !tbaa !11
  store double %133, ptr %12, align 8, !tbaa !11
  %134 = load ptr, ptr %13, align 8, !tbaa !9
  %135 = load i32, ptr %11, align 4, !tbaa !5
  %136 = sext i32 %135 to i64
  %137 = getelementptr inbounds double, ptr %134, i64 %136
  %138 = load double, ptr %137, align 8, !tbaa !11
  %139 = load ptr, ptr %13, align 8, !tbaa !9
  %140 = load i32, ptr %10, align 4, !tbaa !5
  %141 = sext i32 %140 to i64
  %142 = getelementptr inbounds double, ptr %139, i64 %141
  store double %138, ptr %142, align 8, !tbaa !11
  %143 = load double, ptr %12, align 8, !tbaa !11
  %144 = load ptr, ptr %13, align 8, !tbaa !9
  %145 = load i32, ptr %11, align 4, !tbaa !5
  %146 = sext i32 %145 to i64
  %147 = getelementptr inbounds double, ptr %144, i64 %146
  store double %143, ptr %147, align 8, !tbaa !11
  br label %148

148:                                              ; preds = %128, %80
  %149 = load ptr, ptr %7, align 8, !tbaa !9
  %150 = load i32, ptr %10, align 4, !tbaa !5
  %151 = sext i32 %150 to i64
  %152 = getelementptr inbounds ptr, ptr %149, i64 %151
  %153 = load ptr, ptr %152, align 8, !tbaa !9
  %154 = load i32, ptr %10, align 4, !tbaa !5
  %155 = sext i32 %154 to i64
  %156 = getelementptr inbounds double, ptr %153, i64 %155
  %157 = load double, ptr %156, align 8, !tbaa !11
  store double %157, ptr %12, align 8, !tbaa !11
  %158 = load ptr, ptr %7, align 8, !tbaa !9
  %159 = load i32, ptr %10, align 4, !tbaa !5
  %160 = sext i32 %159 to i64
  %161 = getelementptr inbounds ptr, ptr %158, i64 %160
  %162 = load ptr, ptr %161, align 8, !tbaa !9
  %163 = load i32, ptr %10, align 4, !tbaa !5
  %164 = sext i32 %163 to i64
  %165 = getelementptr inbounds double, ptr %162, i64 %164
  store double 1.000000e+00, ptr %165, align 8, !tbaa !11
  %166 = load i32, ptr %10, align 4, !tbaa !5
  %167 = add nsw i32 %166, 1
  store i32 %167, ptr %9, align 4, !tbaa !5
  br label %168

168:                                              ; preds = %192, %148
  %169 = load i32, ptr %9, align 4, !tbaa !5
  %170 = load i32, ptr %4, align 4, !tbaa !5
  %171 = icmp slt i32 %169, %170
  br i1 %171, label %172, label %195

172:                                              ; preds = %168
  %173 = load ptr, ptr %7, align 8, !tbaa !9
  %174 = load i32, ptr %10, align 4, !tbaa !5
  %175 = sext i32 %174 to i64
  %176 = getelementptr inbounds ptr, ptr %173, i64 %175
  %177 = load ptr, ptr %176, align 8, !tbaa !9
  %178 = load i32, ptr %9, align 4, !tbaa !5
  %179 = sext i32 %178 to i64
  %180 = getelementptr inbounds double, ptr %177, i64 %179
  %181 = load double, ptr %180, align 8, !tbaa !11
  %182 = load double, ptr %12, align 8, !tbaa !11
  %183 = fdiv double %181, %182
  %184 = load ptr, ptr %7, align 8, !tbaa !9
  %185 = load i32, ptr %10, align 4, !tbaa !5
  %186 = sext i32 %185 to i64
  %187 = getelementptr inbounds ptr, ptr %184, i64 %186
  %188 = load ptr, ptr %187, align 8, !tbaa !9
  %189 = load i32, ptr %9, align 4, !tbaa !5
  %190 = sext i32 %189 to i64
  %191 = getelementptr inbounds double, ptr %188, i64 %190
  store double %183, ptr %191, align 8, !tbaa !11
  br label %192

192:                                              ; preds = %172
  %193 = load i32, ptr %9, align 4, !tbaa !5
  %194 = add nsw i32 %193, 1
  store i32 %194, ptr %9, align 4, !tbaa !5
  br label %168, !llvm.loop !16

195:                                              ; preds = %168
  %196 = load ptr, ptr %13, align 8, !tbaa !9
  %197 = load i32, ptr %10, align 4, !tbaa !5
  %198 = sext i32 %197 to i64
  %199 = getelementptr inbounds double, ptr %196, i64 %198
  %200 = load double, ptr %199, align 8, !tbaa !11
  %201 = load double, ptr %12, align 8, !tbaa !11
  %202 = fdiv double %200, %201
  %203 = load ptr, ptr %13, align 8, !tbaa !9
  %204 = load i32, ptr %10, align 4, !tbaa !5
  %205 = sext i32 %204 to i64
  %206 = getelementptr inbounds double, ptr %203, i64 %205
  store double %202, ptr %206, align 8, !tbaa !11
  %207 = load i32, ptr %10, align 4, !tbaa !5
  %208 = add nsw i32 %207, 1
  store i32 %208, ptr %8, align 4, !tbaa !5
  br label %209

209:                                              ; preds = %299, %195
  %210 = load i32, ptr %8, align 4, !tbaa !5
  %211 = load i32, ptr %4, align 4, !tbaa !5
  %212 = icmp slt i32 %210, %211
  br i1 %212, label %213, label %302

213:                                              ; preds = %209
  %214 = load ptr, ptr %7, align 8, !tbaa !9
  %215 = load i32, ptr %8, align 4, !tbaa !5
  %216 = sext i32 %215 to i64
  %217 = getelementptr inbounds ptr, ptr %214, i64 %216
  %218 = load ptr, ptr %217, align 8, !tbaa !9
  %219 = load i32, ptr %10, align 4, !tbaa !5
  %220 = sext i32 %219 to i64
  %221 = getelementptr inbounds double, ptr %218, i64 %220
  %222 = load double, ptr %221, align 8, !tbaa !11
  %223 = fcmp une double %222, 0.000000e+00
  br i1 %223, label %224, label %298

224:                                              ; preds = %213
  %225 = load ptr, ptr %7, align 8, !tbaa !9
  %226 = load i32, ptr %8, align 4, !tbaa !5
  %227 = sext i32 %226 to i64
  %228 = getelementptr inbounds ptr, ptr %225, i64 %227
  %229 = load ptr, ptr %228, align 8, !tbaa !9
  %230 = load i32, ptr %10, align 4, !tbaa !5
  %231 = sext i32 %230 to i64
  %232 = getelementptr inbounds double, ptr %229, i64 %231
  %233 = load double, ptr %232, align 8, !tbaa !11
  %234 = fneg double %233
  store double %234, ptr %12, align 8, !tbaa !11
  %235 = load ptr, ptr %7, align 8, !tbaa !9
  %236 = load i32, ptr %8, align 4, !tbaa !5
  %237 = sext i32 %236 to i64
  %238 = getelementptr inbounds ptr, ptr %235, i64 %237
  %239 = load ptr, ptr %238, align 8, !tbaa !9
  %240 = load i32, ptr %10, align 4, !tbaa !5
  %241 = sext i32 %240 to i64
  %242 = getelementptr inbounds double, ptr %239, i64 %241
  store double 0.000000e+00, ptr %242, align 8, !tbaa !11
  %243 = load i32, ptr %10, align 4, !tbaa !5
  %244 = add nsw i32 %243, 1
  store i32 %244, ptr %9, align 4, !tbaa !5
  br label %245

245:                                              ; preds = %278, %224
  %246 = load i32, ptr %9, align 4, !tbaa !5
  %247 = load i32, ptr %4, align 4, !tbaa !5
  %248 = icmp slt i32 %246, %247
  br i1 %248, label %249, label %281

249:                                              ; preds = %245
  %250 = load ptr, ptr %7, align 8, !tbaa !9
  %251 = load i32, ptr %8, align 4, !tbaa !5
  %252 = sext i32 %251 to i64
  %253 = getelementptr inbounds ptr, ptr %250, i64 %252
  %254 = load ptr, ptr %253, align 8, !tbaa !9
  %255 = load i32, ptr %9, align 4, !tbaa !5
  %256 = sext i32 %255 to i64
  %257 = getelementptr inbounds double, ptr %254, i64 %256
  %258 = load double, ptr %257, align 8, !tbaa !11
  %259 = load double, ptr %12, align 8, !tbaa !11
  %260 = load ptr, ptr %7, align 8, !tbaa !9
  %261 = load i32, ptr %10, align 4, !tbaa !5
  %262 = sext i32 %261 to i64
  %263 = getelementptr inbounds ptr, ptr %260, i64 %262
  %264 = load ptr, ptr %263, align 8, !tbaa !9
  %265 = load i32, ptr %9, align 4, !tbaa !5
  %266 = sext i32 %265 to i64
  %267 = getelementptr inbounds double, ptr %264, i64 %266
  %268 = load double, ptr %267, align 8, !tbaa !11
  %269 = call double @llvm.fmuladd.f64(double %259, double %268, double %258)
  %270 = load ptr, ptr %7, align 8, !tbaa !9
  %271 = load i32, ptr %8, align 4, !tbaa !5
  %272 = sext i32 %271 to i64
  %273 = getelementptr inbounds ptr, ptr %270, i64 %272
  %274 = load ptr, ptr %273, align 8, !tbaa !9
  %275 = load i32, ptr %9, align 4, !tbaa !5
  %276 = sext i32 %275 to i64
  %277 = getelementptr inbounds double, ptr %274, i64 %276
  store double %269, ptr %277, align 8, !tbaa !11
  br label %278

278:                                              ; preds = %249
  %279 = load i32, ptr %9, align 4, !tbaa !5
  %280 = add nsw i32 %279, 1
  store i32 %280, ptr %9, align 4, !tbaa !5
  br label %245, !llvm.loop !17

281:                                              ; preds = %245
  %282 = load ptr, ptr %13, align 8, !tbaa !9
  %283 = load i32, ptr %8, align 4, !tbaa !5
  %284 = sext i32 %283 to i64
  %285 = getelementptr inbounds double, ptr %282, i64 %284
  %286 = load double, ptr %285, align 8, !tbaa !11
  %287 = load double, ptr %12, align 8, !tbaa !11
  %288 = load ptr, ptr %13, align 8, !tbaa !9
  %289 = load i32, ptr %10, align 4, !tbaa !5
  %290 = sext i32 %289 to i64
  %291 = getelementptr inbounds double, ptr %288, i64 %290
  %292 = load double, ptr %291, align 8, !tbaa !11
  %293 = call double @llvm.fmuladd.f64(double %287, double %292, double %286)
  %294 = load ptr, ptr %13, align 8, !tbaa !9
  %295 = load i32, ptr %8, align 4, !tbaa !5
  %296 = sext i32 %295 to i64
  %297 = getelementptr inbounds double, ptr %294, i64 %296
  store double %293, ptr %297, align 8, !tbaa !11
  br label %298

298:                                              ; preds = %281, %213
  br label %299

299:                                              ; preds = %298
  %300 = load i32, ptr %8, align 4, !tbaa !5
  %301 = add nsw i32 %300, 1
  store i32 %301, ptr %8, align 4, !tbaa !5
  br label %209, !llvm.loop !18

302:                                              ; preds = %209
  br label %303

303:                                              ; preds = %302
  %304 = load i32, ptr %10, align 4, !tbaa !5
  %305 = add nsw i32 %304, 1
  store i32 %305, ptr %10, align 4, !tbaa !5
  br label %21, !llvm.loop !19

306:                                              ; preds = %21
  %307 = load i32, ptr %4, align 4, !tbaa !5
  %308 = sub nsw i32 %307, 1
  store i32 %308, ptr %9, align 4, !tbaa !5
  br label %309

309:                                              ; preds = %347, %306
  %310 = load i32, ptr %9, align 4, !tbaa !5
  %311 = icmp sle i32 1, %310
  br i1 %311, label %312, label %350

312:                                              ; preds = %309
  store i32 0, ptr %8, align 4, !tbaa !5
  br label %313

313:                                              ; preds = %343, %312
  %314 = load i32, ptr %8, align 4, !tbaa !5
  %315 = load i32, ptr %9, align 4, !tbaa !5
  %316 = icmp slt i32 %314, %315
  br i1 %316, label %317, label %346

317:                                              ; preds = %313
  %318 = load ptr, ptr %13, align 8, !tbaa !9
  %319 = load i32, ptr %8, align 4, !tbaa !5
  %320 = sext i32 %319 to i64
  %321 = getelementptr inbounds double, ptr %318, i64 %320
  %322 = load double, ptr %321, align 8, !tbaa !11
  %323 = load ptr, ptr %7, align 8, !tbaa !9
  %324 = load i32, ptr %8, align 4, !tbaa !5
  %325 = sext i32 %324 to i64
  %326 = getelementptr inbounds ptr, ptr %323, i64 %325
  %327 = load ptr, ptr %326, align 8, !tbaa !9
  %328 = load i32, ptr %9, align 4, !tbaa !5
  %329 = sext i32 %328 to i64
  %330 = getelementptr inbounds double, ptr %327, i64 %329
  %331 = load double, ptr %330, align 8, !tbaa !11
  %332 = load ptr, ptr %13, align 8, !tbaa !9
  %333 = load i32, ptr %9, align 4, !tbaa !5
  %334 = sext i32 %333 to i64
  %335 = getelementptr inbounds double, ptr %332, i64 %334
  %336 = load double, ptr %335, align 8, !tbaa !11
  %337 = fneg double %331
  %338 = call double @llvm.fmuladd.f64(double %337, double %336, double %322)
  %339 = load ptr, ptr %13, align 8, !tbaa !9
  %340 = load i32, ptr %8, align 4, !tbaa !5
  %341 = sext i32 %340 to i64
  %342 = getelementptr inbounds double, ptr %339, i64 %341
  store double %338, ptr %342, align 8, !tbaa !11
  br label %343

343:                                              ; preds = %317
  %344 = load i32, ptr %8, align 4, !tbaa !5
  %345 = add nsw i32 %344, 1
  store i32 %345, ptr %8, align 4, !tbaa !5
  br label %313, !llvm.loop !20

346:                                              ; preds = %313
  br label %347

347:                                              ; preds = %346
  %348 = load i32, ptr %9, align 4, !tbaa !5
  %349 = add nsw i32 %348, -1
  store i32 %349, ptr %9, align 4, !tbaa !5
  br label %309, !llvm.loop !21

350:                                              ; preds = %309
  %351 = load i32, ptr %4, align 4, !tbaa !5
  %352 = load i32, ptr %4, align 4, !tbaa !5
  %353 = load ptr, ptr %7, align 8, !tbaa !9
  call void @r8rmat_delete(i32 noundef %351, i32 noundef %352, ptr noundef %353)
  %354 = load ptr, ptr %13, align 8, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  ret ptr %354
}

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { 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 #3 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #4 = { 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 #5 = { nounwind }
attributes #6 = { 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 = !{!"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, !12, i64 0}
!12 = !{!"double", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = distinct !{!15, !14}
!16 = distinct !{!16, !14}
!17 = distinct !{!17, !14}
!18 = distinct !{!18, !14}
!19 = distinct !{!19, !14}
!20 = distinct !{!20, !14}
!21 = distinct !{!21, !14}


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

@stderr = external local_unnamed_addr global ptr, align 8
@.str = external hidden unnamed_addr constant [2 x i8], align 1
@.str.99 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.157 = external hidden unnamed_addr constant [30 x i8], align 1

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

; Function Attrs: noreturn nounwind
declare void @exit(i32 noundef) local_unnamed_addr #1

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #2

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fabs.f64(double) #2

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

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

; Function Attrs: nounwind uwtable
declare dso_local void @r8rmat_delete(i32 noundef, i32 noundef, ptr noundef) local_unnamed_addr #3

; Function Attrs: nounwind uwtable
define dso_local ptr @r8rmat_fs_new(i32 noundef %0, ptr noundef %1, ptr noundef %2) local_unnamed_addr #3 {
  %4 = tail call ptr @r8rmat_copy_new(i32 noundef %0, i32 noundef %0, ptr noundef %1)
  %5 = tail call ptr @r8vec_copy_new(i32 noundef %0, ptr noundef %2)
  %6 = icmp sgt i32 %0, 0
  br i1 %6, label %.lr.ph155, label %._crit_edge160

.lr.ph155:                                        ; preds = %3
  %7 = zext nneg i32 %0 to i64
  %wide.trip.count188 = zext nneg i32 %0 to i64
  %8 = shl nuw nsw i64 %wide.trip.count188, 3
  %9 = shl nuw nsw i64 %wide.trip.count188, 3
  %min.iters.check237 = icmp ult i32 %0, 4
  %n.vec240 = and i64 %wide.trip.count188, 2147483644
  %cmp.n249 = icmp eq i64 %n.vec240, %wide.trip.count188
  %xtraiter = and i64 %wide.trip.count188, 1
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  %10 = add nsw i64 %wide.trip.count188, -1
  %11 = add nsw i64 %wide.trip.count188, -1
  br label %16

.loopexit134:                                     ; preds = %129, %._crit_edge145.thread, %._crit_edge145
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond189.not = icmp eq i64 %indvars.iv.next186, %wide.trip.count188
  br i1 %exitcond189.not, label %.preheader133, label %16, !llvm.loop !5

.preheader133:                                    ; preds = %.loopexit134
  %.not205 = icmp eq i32 %0, 1
  br i1 %.not205, label %._crit_edge160, label %.preheader.preheader

.preheader.preheader:                             ; preds = %.preheader133
  %12 = add nsw i32 %0, -1
  %13 = zext i32 %12 to i64
  %14 = zext nneg i32 %0 to i64
  %15 = add nsw i64 %13, -1
  br label %.lr.ph157

16:                                               ; preds = %.lr.ph155, %.loopexit134
  %indvars.iv185 = phi i64 [ 0, %.lr.ph155 ], [ %indvars.iv.next186, %.loopexit134 ]
  %indvars.iv = phi i64 [ 1, %.lr.ph155 ], [ %indvars.iv.next, %.loopexit134 ]
  %17 = xor i64 %indvars.iv185, -1
  %18 = add nsw i64 %17, %wide.trip.count188
  %19 = xor i64 %indvars.iv185, -1
  %20 = add nsw i64 %19, %wide.trip.count188
  %21 = shl nuw nsw i64 %indvars.iv185, 3
  %22 = add nuw i64 %21, 8
  %indvars.iv.next186 = add nuw nsw i64 %indvars.iv185, 1
  %23 = icmp ult i64 %indvars.iv.next186, %7
  %24 = trunc nuw nsw i64 %indvars.iv185 to i32
  br i1 %23, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %16, %.lr.ph
  %indvars.iv162 = phi i64 [ %indvars.iv.next163, %.lr.ph ], [ %indvars.iv, %16 ]
  %.0125137 = phi i32 [ %.1126, %.lr.ph ], [ %24, %16 ]
  %25 = sext i32 %.0125137 to i64
  %26 = getelementptr inbounds ptr, ptr %4, i64 %25
  %27 = load ptr, ptr %26, align 8, !tbaa !7
  %28 = getelementptr inbounds double, ptr %27, i64 %indvars.iv185
  %29 = load double, ptr %28, align 8, !tbaa !11
  %30 = tail call double @llvm.fabs.f64(double %29)
  %31 = getelementptr inbounds ptr, ptr %4, i64 %indvars.iv162
  %32 = load ptr, ptr %31, align 8, !tbaa !7
  %33 = getelementptr inbounds double, ptr %32, i64 %indvars.iv185
  %34 = load double, ptr %33, align 8, !tbaa !11
  %35 = tail call double @llvm.fabs.f64(double %34)
  %36 = fcmp olt double %30, %35
  %37 = trunc nuw nsw i64 %indvars.iv162 to i32
  %.1126 = select i1 %36, i32 %37, i32 %.0125137
  %indvars.iv.next163 = add nuw nsw i64 %indvars.iv162, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next163, %wide.trip.count188
  br i1 %exitcond.not, label %._crit_edge, label %.lr.ph, !llvm.loop !13

._crit_edge:                                      ; preds = %.lr.ph, %16
  %.0125.lcssa = phi i32 [ %24, %16 ], [ %.1126, %.lr.ph ]
  %38 = sext i32 %.0125.lcssa to i64
  %39 = getelementptr inbounds ptr, ptr %4, i64 %38
  %40 = load ptr, ptr %39, align 8, !tbaa !7
  %41 = getelementptr inbounds double, ptr %40, i64 %indvars.iv185
  %42 = load double, ptr %41, align 8, !tbaa !11
  %43 = fcmp oeq double %42, 0.000000e+00
  br i1 %43, label %44, label %51

44:                                               ; preds = %._crit_edge
  %45 = load ptr, ptr @stderr, align 8, !tbaa !7
  %46 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %45, ptr noundef nonnull @.str) #5
  %47 = load ptr, ptr @stderr, align 8, !tbaa !7
  %48 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %47, ptr noundef nonnull @.str.157) #5
  %49 = load ptr, ptr @stderr, align 8, !tbaa !7
  %50 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %49, ptr noundef nonnull @.str.99, i32 noundef %24) #5
  tail call void @exit(i32 noundef 1) #6
  unreachable

51:                                               ; preds = %._crit_edge
  %52 = zext i32 %.0125.lcssa to i64
  %.not = icmp eq i64 %indvars.iv185, %52
  br i1 %.not, label %77, label %.lr.ph140

.lr.ph140:                                        ; preds = %51
  %53 = getelementptr inbounds ptr, ptr %4, i64 %indvars.iv185
  %54 = load ptr, ptr %53, align 8, !tbaa !7
  br i1 %min.iters.check237, label %scalar.ph236.preheader, label %vector.memcheck229

vector.memcheck229:                               ; preds = %.lr.ph140
  %scevgep230 = getelementptr i8, ptr %54, i64 %9
  %scevgep231 = getelementptr i8, ptr %40, i64 %9
  %bound0232 = icmp ult ptr %54, %scevgep231
  %bound1233 = icmp ult ptr %40, %scevgep230
  %found.conflict234 = and i1 %bound0232, %bound1233
  br i1 %found.conflict234, label %scalar.ph236.preheader, label %vector.body242

vector.body242:                                   ; preds = %vector.memcheck229, %vector.body242
  %index243 = phi i64 [ %index.next248, %vector.body242 ], [ 0, %vector.memcheck229 ]
  %55 = getelementptr inbounds double, ptr %54, i64 %index243
  %56 = getelementptr inbounds i8, ptr %55, i64 16
  %wide.load244 = load <2 x double>, ptr %55, align 8, !tbaa !11, !alias.scope !14, !noalias !17
  %wide.load245 = load <2 x double>, ptr %56, align 8, !tbaa !11, !alias.scope !14, !noalias !17
  %57 = getelementptr inbounds double, ptr %40, i64 %index243
  %58 = getelementptr inbounds i8, ptr %57, i64 16
  %wide.load246 = load <2 x double>, ptr %57, align 8, !tbaa !11, !alias.scope !17
  %wide.load247 = load <2 x double>, ptr %58, align 8, !tbaa !11, !alias.scope !17
  store <2 x double> %wide.load246, ptr %55, align 8, !tbaa !11, !alias.scope !14, !noalias !17
  store <2 x double> %wide.load247, ptr %56, align 8, !tbaa !11, !alias.scope !14, !noalias !17
  store <2 x double> %wide.load244, ptr %57, align 8, !tbaa !11, !alias.scope !17
  store <2 x double> %wide.load245, ptr %58, align 8, !tbaa !11, !alias.scope !17
  %index.next248 = add nuw i64 %index243, 4
  %59 = icmp eq i64 %index.next248, %n.vec240
  br i1 %59, label %middle.block235, label %vector.body242, !llvm.loop !19

middle.block235:                                  ; preds = %vector.body242
  br i1 %cmp.n249, label %._crit_edge141, label %scalar.ph236.preheader

scalar.ph236.preheader:                           ; preds = %middle.block235, %vector.memcheck229, %.lr.ph140
  %indvars.iv165.ph = phi i64 [ 0, %vector.memcheck229 ], [ 0, %.lr.ph140 ], [ %n.vec240, %middle.block235 ]
  br i1 %lcmp.mod.not, label %scalar.ph236.prol.loopexit, label %scalar.ph236.prol

scalar.ph236.prol:                                ; preds = %scalar.ph236.preheader
  %60 = getelementptr inbounds double, ptr %54, i64 %indvars.iv165.ph
  %61 = load double, ptr %60, align 8, !tbaa !11
  %62 = getelementptr inbounds double, ptr %40, i64 %indvars.iv165.ph
  %63 = load double, ptr %62, align 8, !tbaa !11
  store double %63, ptr %60, align 8, !tbaa !11
  store double %61, ptr %62, align 8, !tbaa !11
  %indvars.iv.next166.prol = or disjoint i64 %indvars.iv165.ph, 1
  br label %scalar.ph236.prol.loopexit

scalar.ph236.prol.loopexit:                       ; preds = %scalar.ph236.prol, %scalar.ph236.preheader
  %indvars.iv165.unr = phi i64 [ %indvars.iv165.ph, %scalar.ph236.preheader ], [ %indvars.iv.next166.prol, %scalar.ph236.prol ]
  %64 = icmp eq i64 %indvars.iv165.ph, %10
  br i1 %64, label %._crit_edge141, label %scalar.ph236

scalar.ph236:                                     ; preds = %scalar.ph236.prol.loopexit, %scalar.ph236
  %indvars.iv165 = phi i64 [ %indvars.iv.next166.1, %scalar.ph236 ], [ %indvars.iv165.unr, %scalar.ph236.prol.loopexit ]
  %65 = getelementptr inbounds double, ptr %54, i64 %indvars.iv165
  %66 = load double, ptr %65, align 8, !tbaa !11
  %67 = getelementptr inbounds double, ptr %40, i64 %indvars.iv165
  %68 = load double, ptr %67, align 8, !tbaa !11
  store double %68, ptr %65, align 8, !tbaa !11
  store double %66, ptr %67, align 8, !tbaa !11
  %indvars.iv.next166 = add nuw nsw i64 %indvars.iv165, 1
  %69 = getelementptr inbounds double, ptr %54, i64 %indvars.iv.next166
  %70 = load double, ptr %69, align 8, !tbaa !11
  %71 = getelementptr inbounds double, ptr %40, i64 %indvars.iv.next166
  %72 = load double, ptr %71, align 8, !tbaa !11
  store double %72, ptr %69, align 8, !tbaa !11
  store double %70, ptr %71, align 8, !tbaa !11
  %indvars.iv.next166.1 = add nuw nsw i64 %indvars.iv165, 2
  %exitcond169.not.1 = icmp eq i64 %indvars.iv.next166.1, %wide.trip.count188
  br i1 %exitcond169.not.1, label %._crit_edge141, label %scalar.ph236, !llvm.loop !22

._crit_edge141:                                   ; preds = %scalar.ph236.prol.loopexit, %scalar.ph236, %middle.block235
  %73 = getelementptr inbounds double, ptr %5, i64 %indvars.iv185
  %74 = load double, ptr %73, align 8, !tbaa !11
  %75 = getelementptr inbounds double, ptr %5, i64 %38
  %76 = load double, ptr %75, align 8, !tbaa !11
  store double %76, ptr %73, align 8, !tbaa !11
  store double %74, ptr %75, align 8, !tbaa !11
  br label %77

77:                                               ; preds = %._crit_edge141, %51
  %78 = getelementptr inbounds ptr, ptr %4, i64 %indvars.iv185
  %79 = load ptr, ptr %78, align 8, !tbaa !7
  %80 = getelementptr inbounds double, ptr %79, i64 %indvars.iv185
  %81 = load double, ptr %80, align 8, !tbaa !11
  store double 1.000000e+00, ptr %80, align 8, !tbaa !11
  br i1 %23, label %.lr.ph144.preheader, label %._crit_edge145.thread

.lr.ph144.preheader:                              ; preds = %77
  %min.iters.check215 = icmp ult i64 %18, 2
  br i1 %min.iters.check215, label %.lr.ph144.preheader250, label %vector.ph216

.lr.ph144.preheader250:                           ; preds = %middle.block213, %.lr.ph144.preheader
  %indvars.iv170.ph = phi i64 [ %indvars.iv, %.lr.ph144.preheader ], [ %ind.end219, %middle.block213 ]
  br label %.lr.ph144

vector.ph216:                                     ; preds = %.lr.ph144.preheader
  %n.vec218 = and i64 %18, -2
  %ind.end219 = add i64 %indvars.iv, %n.vec218
  %broadcast.splatinsert225 = insertelement <2 x double> poison, double %81, i64 0
  %broadcast.splat226 = shufflevector <2 x double> %broadcast.splatinsert225, <2 x double> poison, <2 x i32> zeroinitializer
  %82 = getelementptr double, ptr %79, i64 %indvars.iv
  br label %vector.body221

vector.body221:                                   ; preds = %vector.body221, %vector.ph216
  %index222 = phi i64 [ 0, %vector.ph216 ], [ %index.next227, %vector.body221 ]
  %83 = getelementptr double, ptr %82, i64 %index222
  %wide.load224 = load <2 x double>, ptr %83, align 8, !tbaa !11
  %84 = fdiv <2 x double> %wide.load224, %broadcast.splat226
  store <2 x double> %84, ptr %83, align 8, !tbaa !11
  %index.next227 = add nuw i64 %index222, 2
  %85 = icmp eq i64 %index.next227, %n.vec218
  br i1 %85, label %middle.block213, label %vector.body221, !llvm.loop !23

middle.block213:                                  ; preds = %vector.body221
  %cmp.n228 = icmp eq i64 %18, %n.vec218
  br i1 %cmp.n228, label %._crit_edge145, label %.lr.ph144.preheader250

._crit_edge145.thread:                            ; preds = %77
  %86 = getelementptr inbounds double, ptr %5, i64 %indvars.iv185
  %87 = load double, ptr %86, align 8, !tbaa !11
  %88 = fdiv double %87, %81
  store double %88, ptr %86, align 8, !tbaa !11
  br label %.loopexit134

.lr.ph144:                                        ; preds = %.lr.ph144.preheader250, %.lr.ph144
  %indvars.iv170 = phi i64 [ %indvars.iv.next171, %.lr.ph144 ], [ %indvars.iv170.ph, %.lr.ph144.preheader250 ]
  %89 = getelementptr inbounds double, ptr %79, i64 %indvars.iv170
  %90 = load double, ptr %89, align 8, !tbaa !11
  %91 = fdiv double %90, %81
  store double %91, ptr %89, align 8, !tbaa !11
  %indvars.iv.next171 = add nuw nsw i64 %indvars.iv170, 1
  %exitcond174.not = icmp eq i64 %indvars.iv.next171, %wide.trip.count188
  br i1 %exitcond174.not, label %._crit_edge145, label %.lr.ph144, !llvm.loop !24

._crit_edge145:                                   ; preds = %.lr.ph144, %middle.block213
  %92 = getelementptr inbounds double, ptr %5, i64 %indvars.iv185
  %93 = load double, ptr %92, align 8, !tbaa !11
  %94 = fdiv double %93, %81
  store double %94, ptr %92, align 8, !tbaa !11
  br i1 %23, label %.lr.ph152.preheader, label %.loopexit134

.lr.ph152.preheader:                              ; preds = %._crit_edge145
  %scevgep208 = getelementptr i8, ptr %79, i64 %22
  %scevgep209 = getelementptr i8, ptr %79, i64 %8
  %min.iters.check = icmp ult i64 %20, 4
  %n.vec = and i64 %20, -4
  %ind.end = add i64 %indvars.iv, %n.vec
  %cmp.n = icmp eq i64 %20, %n.vec
  br label %.lr.ph152

.lr.ph152:                                        ; preds = %.lr.ph152.preheader, %129
  %indvars.iv180 = phi i64 [ %indvars.iv.next181, %129 ], [ %indvars.iv, %.lr.ph152.preheader ]
  %95 = getelementptr inbounds ptr, ptr %4, i64 %indvars.iv180
  %96 = load ptr, ptr %95, align 8, !tbaa !7
  %97 = getelementptr inbounds double, ptr %96, i64 %indvars.iv185
  %98 = load double, ptr %97, align 8, !tbaa !11
  %99 = fcmp une double %98, 0.000000e+00
  br i1 %99, label %.lr.ph148, label %129

.lr.ph148:                                        ; preds = %.lr.ph152
  %100 = fneg double %98
  store double 0.000000e+00, ptr %97, align 8, !tbaa !11
  br i1 %min.iters.check, label %scalar.ph.preheader, label %vector.memcheck

vector.memcheck:                                  ; preds = %.lr.ph148
  %scevgep = getelementptr i8, ptr %96, i64 %22
  %scevgep207 = getelementptr i8, ptr %96, i64 %8
  %bound0 = icmp ult ptr %scevgep, %scevgep209
  %bound1 = icmp ult ptr %scevgep208, %scevgep207
  %found.conflict = and i1 %bound0, %bound1
  br i1 %found.conflict, label %scalar.ph.preheader, label %vector.ph

vector.ph:                                        ; preds = %vector.memcheck
  %broadcast.splatinsert = insertelement <2 x double> poison, double %100, i64 0
  %broadcast.splat = shufflevector <2 x double> %broadcast.splatinsert, <2 x double> poison, <2 x i32> zeroinitializer
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %offset.idx = add i64 %indvars.iv, %index
  %101 = getelementptr inbounds double, ptr %96, i64 %offset.idx
  %102 = getelementptr inbounds i8, ptr %101, i64 16
  %wide.load = load <2 x double>, ptr %101, align 8, !tbaa !11, !alias.scope !25, !noalias !28
  %wide.load210 = load <2 x double>, ptr %102, align 8, !tbaa !11, !alias.scope !25, !noalias !28
  %103 = getelementptr inbounds double, ptr %79, i64 %offset.idx
  %104 = getelementptr inbounds i8, ptr %103, i64 16
  %wide.load211 = load <2 x double>, ptr %103, align 8, !tbaa !11, !alias.scope !28
  %wide.load212 = load <2 x double>, ptr %104, align 8, !tbaa !11, !alias.scope !28
  %105 = tail call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %broadcast.splat, <2 x double> %wide.load211, <2 x double> %wide.load)
  %106 = tail call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %broadcast.splat, <2 x double> %wide.load212, <2 x double> %wide.load210)
  store <2 x double> %105, ptr %101, align 8, !tbaa !11, !alias.scope !25, !noalias !28
  store <2 x double> %106, ptr %102, align 8, !tbaa !11, !alias.scope !25, !noalias !28
  %index.next = add nuw i64 %index, 4
  %107 = icmp eq i64 %index.next, %n.vec
  br i1 %107, label %middle.block, label %vector.body, !llvm.loop !30

middle.block:                                     ; preds = %vector.body
  br i1 %cmp.n, label %._crit_edge149, label %scalar.ph.preheader

scalar.ph.preheader:                              ; preds = %middle.block, %vector.memcheck, %.lr.ph148
  %indvars.iv175.ph = phi i64 [ %indvars.iv, %vector.memcheck ], [ %indvars.iv, %.lr.ph148 ], [ %ind.end, %middle.block ]
  %108 = sub i64 %wide.trip.count188, %indvars.iv175.ph
  %xtraiter252 = and i64 %108, 1
  %lcmp.mod253.not = icmp eq i64 %xtraiter252, 0
  br i1 %lcmp.mod253.not, label %scalar.ph.prol.loopexit, label %scalar.ph.prol

scalar.ph.prol:                                   ; preds = %scalar.ph.preheader
  %109 = getelementptr inbounds double, ptr %96, i64 %indvars.iv175.ph
  %110 = load double, ptr %109, align 8, !tbaa !11
  %111 = getelementptr inbounds double, ptr %79, i64 %indvars.iv175.ph
  %112 = load double, ptr %111, align 8, !tbaa !11
  %113 = tail call double @llvm.fmuladd.f64(double %100, double %112, double %110)
  store double %113, ptr %109, align 8, !tbaa !11
  %indvars.iv.next176.prol = add nuw nsw i64 %indvars.iv175.ph, 1
  br label %scalar.ph.prol.loopexit

scalar.ph.prol.loopexit:                          ; preds = %scalar.ph.prol, %scalar.ph.preheader
  %indvars.iv175.unr = phi i64 [ %indvars.iv175.ph, %scalar.ph.preheader ], [ %indvars.iv.next176.prol, %scalar.ph.prol ]
  %114 = icmp eq i64 %indvars.iv175.ph, %11
  br i1 %114, label %._crit_edge149, label %scalar.ph

scalar.ph:                                        ; preds = %scalar.ph.prol.loopexit, %scalar.ph
  %indvars.iv175 = phi i64 [ %indvars.iv.next176.1, %scalar.ph ], [ %indvars.iv175.unr, %scalar.ph.prol.loopexit ]
  %115 = getelementptr inbounds double, ptr %96, i64 %indvars.iv175
  %116 = load double, ptr %115, align 8, !tbaa !11
  %117 = getelementptr inbounds double, ptr %79, i64 %indvars.iv175
  %118 = load double, ptr %117, align 8, !tbaa !11
  %119 = tail call double @llvm.fmuladd.f64(double %100, double %118, double %116)
  store double %119, ptr %115, align 8, !tbaa !11
  %indvars.iv.next176 = add nuw nsw i64 %indvars.iv175, 1
  %120 = getelementptr inbounds double, ptr %96, i64 %indvars.iv.next176
  %121 = load double, ptr %120, align 8, !tbaa !11
  %122 = getelementptr inbounds double, ptr %79, i64 %indvars.iv.next176
  %123 = load double, ptr %122, align 8, !tbaa !11
  %124 = tail call double @llvm.fmuladd.f64(double %100, double %123, double %121)
  store double %124, ptr %120, align 8, !tbaa !11
  %indvars.iv.next176.1 = add nuw nsw i64 %indvars.iv175, 2
  %exitcond179.not.1 = icmp eq i64 %indvars.iv.next176.1, %wide.trip.count188
  br i1 %exitcond179.not.1, label %._crit_edge149, label %scalar.ph, !llvm.loop !31

._crit_edge149:                                   ; preds = %scalar.ph.prol.loopexit, %scalar.ph, %middle.block
  %125 = getelementptr inbounds double, ptr %5, i64 %indvars.iv180
  %126 = load double, ptr %125, align 8, !tbaa !11
  %127 = load double, ptr %92, align 8, !tbaa !11
  %128 = tail call double @llvm.fmuladd.f64(double %100, double %127, double %126)
  store double %128, ptr %125, align 8, !tbaa !11
  br label %129

129:                                              ; preds = %.lr.ph152, %._crit_edge149
  %indvars.iv.next181 = add nuw nsw i64 %indvars.iv180, 1
  %exitcond184.not = icmp eq i64 %indvars.iv.next181, %wide.trip.count188
  br i1 %exitcond184.not, label %.loopexit134, label %.lr.ph152, !llvm.loop !32

.loopexit.unr-lcssa:                              ; preds = %142, %.lr.ph157
  %indvars.iv190.unr = phi i64 [ 0, %.lr.ph157 ], [ %indvars.iv.next191.1, %142 ]
  %lcmp.mod255.not = icmp eq i64 %xtraiter254, 0
  br i1 %lcmp.mod255.not, label %.loopexit, label %.loopexit.epilog-lcssa

.loopexit.epilog-lcssa:                           ; preds = %.loopexit.unr-lcssa
  %130 = getelementptr inbounds double, ptr %5, i64 %indvars.iv190.unr
  %131 = load double, ptr %130, align 8, !tbaa !11
  %132 = getelementptr inbounds ptr, ptr %4, i64 %indvars.iv190.unr
  %133 = load ptr, ptr %132, align 8, !tbaa !7
  %134 = getelementptr inbounds double, ptr %133, i64 %indvars.iv.next200
  %135 = load double, ptr %134, align 8, !tbaa !11
  %136 = load double, ptr %140, align 8, !tbaa !11
  %137 = fneg double %135
  %138 = tail call double @llvm.fmuladd.f64(double %137, double %136, double %131)
  store double %138, ptr %130, align 8, !tbaa !11
  br label %.loopexit

.loopexit:                                        ; preds = %.loopexit.unr-lcssa, %.loopexit.epilog-lcssa
  %139 = icmp sgt i64 %indvars.iv199, 2
  %indvars.iv.next198 = add nsw i64 %indvars.iv197, -1
  %indvar.next = add i64 %indvar, 1
  br i1 %139, label %.lr.ph157, label %._crit_edge160, !llvm.loop !33

.lr.ph157:                                        ; preds = %.loopexit, %.preheader.preheader
  %indvar = phi i64 [ %indvar.next, %.loopexit ], [ 0, %.preheader.preheader ]
  %indvars.iv199 = phi i64 [ %indvars.iv.next200, %.loopexit ], [ %14, %.preheader.preheader ]
  %indvars.iv197 = phi i64 [ %indvars.iv.next198, %.loopexit ], [ %13, %.preheader.preheader ]
  %indvars.iv.next200 = add nsw i64 %indvars.iv199, -1
  %140 = getelementptr inbounds double, ptr %5, i64 %indvars.iv.next200
  %xtraiter254 = and i64 %indvars.iv197, 1
  %141 = icmp eq i64 %indvar, %15
  br i1 %141, label %.loopexit.unr-lcssa, label %.lr.ph157.new

.lr.ph157.new:                                    ; preds = %.lr.ph157
  %unroll_iter = and i64 %indvars.iv197, -2
  br label %142

142:                                              ; preds = %142, %.lr.ph157.new
  %indvars.iv190 = phi i64 [ 0, %.lr.ph157.new ], [ %indvars.iv.next191.1, %142 ]
  %niter = phi i64 [ 0, %.lr.ph157.new ], [ %niter.next.1, %142 ]
  %143 = getelementptr inbounds double, ptr %5, i64 %indvars.iv190
  %144 = load double, ptr %143, align 8, !tbaa !11
  %145 = getelementptr inbounds ptr, ptr %4, i64 %indvars.iv190
  %146 = load ptr, ptr %145, align 8, !tbaa !7
  %147 = getelementptr inbounds double, ptr %146, i64 %indvars.iv.next200
  %148 = load double, ptr %147, align 8, !tbaa !11
  %149 = load double, ptr %140, align 8, !tbaa !11
  %150 = fneg double %148
  %151 = tail call double @llvm.fmuladd.f64(double %150, double %149, double %144)
  store double %151, ptr %143, align 8, !tbaa !11
  %indvars.iv.next191 = or disjoint i64 %indvars.iv190, 1
  %152 = getelementptr inbounds double, ptr %5, i64 %indvars.iv.next191
  %153 = load double, ptr %152, align 8, !tbaa !11
  %154 = getelementptr inbounds ptr, ptr %4, i64 %indvars.iv.next191
  %155 = load ptr, ptr %154, align 8, !tbaa !7
  %156 = getelementptr inbounds double, ptr %155, i64 %indvars.iv.next200
  %157 = load double, ptr %156, align 8, !tbaa !11
  %158 = load double, ptr %140, align 8, !tbaa !11
  %159 = fneg double %157
  %160 = tail call double @llvm.fmuladd.f64(double %159, double %158, double %153)
  store double %160, ptr %152, align 8, !tbaa !11
  %indvars.iv.next191.1 = add nuw nsw i64 %indvars.iv190, 2
  %niter.next.1 = add i64 %niter, 2
  %niter.ncmp.1 = icmp eq i64 %niter.next.1, %unroll_iter
  br i1 %niter.ncmp.1, label %.loopexit.unr-lcssa, label %142, !llvm.loop !34

._crit_edge160:                                   ; preds = %.loopexit, %3, %.preheader133
  tail call void @r8rmat_delete(i32 noundef %0, i32 noundef %0, ptr noundef %4)
  ret ptr %5
}

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare <2 x double> @llvm.fmuladd.v2f64(<2 x double>, <2 x double>, <2 x double>) #4

attributes #0 = { 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 #1 = { 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 #2 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #3 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #5 = { cold nounwind }
attributes #6 = { 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 = distinct !{!5, !6}
!6 = !{!"llvm.loop.mustprogress"}
!7 = !{!8, !8, i64 0}
!8 = !{!"any pointer", !9, i64 0}
!9 = !{!"omnipotent char", !10, i64 0}
!10 = !{!"Simple C/C++ TBAA"}
!11 = !{!12, !12, i64 0}
!12 = !{!"double", !9, i64 0}
!13 = distinct !{!13, !6}
!14 = !{!15}
!15 = distinct !{!15, !16}
!16 = distinct !{!16, !"LVerDomain"}
!17 = !{!18}
!18 = distinct !{!18, !16}
!19 = distinct !{!19, !6, !20, !21}
!20 = !{!"llvm.loop.isvectorized", i32 1}
!21 = !{!"llvm.loop.unroll.runtime.disable"}
!22 = distinct !{!22, !6, !20}
!23 = distinct !{!23, !6, !20, !21}
!24 = distinct !{!24, !6, !21, !20}
!25 = !{!26}
!26 = distinct !{!26, !27}
!27 = distinct !{!27, !"LVerDomain"}
!28 = !{!29}
!29 = distinct !{!29, !27}
!30 = distinct !{!30, !6, !20, !21}
!31 = distinct !{!31, !6, !20}
!32 = distinct !{!32, !6}
!33 = distinct !{!33, !6}
!34 = distinct !{!34, !6}


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