; LLVM IR from CLASS-SZ/class_sz :: class-sz/source (transfer)

; 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.transfers = type { double, double, double, [100 x double], [100 x double], i16, i16, [256 x i8], i32, ptr, ptr, ptr, i16, i16, [256 x i8], i32, ptr, ptr, ptr, ptr, i16, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, ptr, ptr, ptr, i32, ptr, double, i64, ptr, ptr, i32, ptr, i16, i16, [2048 x i8] }
%struct.background = type { double, double, double, double, double, double, double, i32, double, double, double, double, i16, double, double, double, double, double, double, double, double, double, i16, double, double, ptr, i32, i32, double, i32, ptr, ptr, double, ptr, double, ptr, double, ptr, double, ptr, ptr, ptr, double, double, double, double, i32, ptr, double, double, double, double, double, double, double, double, double, double, double, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, ptr, ptr, ptr, ptr, ptr, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i16, i16, i16, i16, i16, i16, i16, i16, i16, i16, i16, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i16, i16, i16, i16, i16, i16, [2048 x i8], i16, [2048 x i8] }

@.str = external hidden unnamed_addr constant [18 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.42 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.57 = external hidden unnamed_addr constant [81 x i8], align 1
@__func__.transfer_selection_sampling = external hidden unnamed_addr constant [28 x i8], align 1
@.str.79 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.80 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.81 = external hidden unnamed_addr constant [58 x i8], align 1
@.str.82 = external hidden unnamed_addr constant [13 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

declare void @class_protect_sprintf(ptr noundef, ptr noundef, ...) #1

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

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

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

; Function Attrs: nounwind uwtable
define dso_local i32 @transfer_selection_sampling(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef %3, i32 noundef %4, ptr noundef %5, i32 noundef %6) #3 {
  %8 = alloca i32, align 4
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca i32, align 4
  %14 = alloca ptr, align 8
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca double, align 8
  %18 = alloca double, align 8
  %19 = alloca double, align 8
  %20 = alloca [2048 x i8], align 16
  %21 = alloca i32, align 4
  %22 = alloca [2048 x i8], align 16
  %23 = alloca [2048 x i8], align 16
  %24 = alloca [2048 x i8], align 16
  %25 = alloca [2048 x i8], align 16
  store ptr %0, ptr %9, align 8, !tbaa !5
  store ptr %1, ptr %10, align 8, !tbaa !5
  store ptr %2, ptr %11, align 8, !tbaa !5
  store ptr %3, ptr %12, align 8, !tbaa !5
  store i32 %4, ptr %13, align 4, !tbaa !9
  store ptr %5, ptr %14, align 8, !tbaa !5
  store i32 %6, ptr %15, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #4
  %26 = load ptr, ptr %9, align 8, !tbaa !5
  %27 = load ptr, ptr %10, align 8, !tbaa !5
  %28 = load ptr, ptr %11, align 8, !tbaa !5
  %29 = load ptr, ptr %12, align 8, !tbaa !5
  %30 = load i32, ptr %13, align 4, !tbaa !9
  %31 = call i32 @transfer_selection_times(ptr noundef %26, ptr noundef %27, ptr noundef %28, ptr noundef %29, i32 noundef %30, ptr noundef %17, ptr noundef %18, ptr noundef %19)
  %32 = icmp eq i32 %31, 1
  br i1 %32, label %33, label %42

33:                                               ; preds = %7
  call void @llvm.lifetime.start.p0(i64 2048, ptr %20) #4
  %34 = getelementptr inbounds [2048 x i8], ptr %20, i64 0, i64 0
  %35 = load ptr, ptr %12, align 8, !tbaa !5
  %36 = getelementptr inbounds %struct.transfers, ptr %35, i32 0, i32 52
  %37 = getelementptr inbounds [2048 x i8], ptr %36, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %34, ptr noundef @.str, ptr noundef @.str.57, ptr noundef %37)
  %38 = load ptr, ptr %12, align 8, !tbaa !5
  %39 = getelementptr inbounds %struct.transfers, ptr %38, i32 0, i32 52
  %40 = getelementptr inbounds [2048 x i8], ptr %39, i64 0, i64 0
  %41 = getelementptr inbounds [2048 x i8], ptr %20, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %40, ptr noundef @.str.2, ptr noundef @__func__.transfer_selection_sampling, i32 noundef 2630, ptr noundef %41)
  call void @llvm.lifetime.end.p0(i64 2048, ptr %20) #4
  store i32 1, ptr %8, align 4
  store i32 1, ptr %21, align 4
  br label %119

42:                                               ; preds = %7
  %43 = load i32, ptr %15, align 4, !tbaa !9
  %44 = icmp sle i32 %43, 0
  br i1 %44, label %45, label %53

45:                                               ; preds = %42
  call void @llvm.lifetime.start.p0(i64 2048, ptr %22) #4
  %46 = getelementptr inbounds [2048 x i8], ptr %22, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %46, ptr noundef @.str.79)
  call void @llvm.lifetime.start.p0(i64 2048, ptr %23) #4
  %47 = getelementptr inbounds [2048 x i8], ptr %23, i64 0, i64 0
  %48 = getelementptr inbounds [2048 x i8], ptr %22, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %47, ptr noundef @.str.42, ptr noundef @.str.80, ptr noundef %48)
  %49 = load ptr, ptr %12, align 8, !tbaa !5
  %50 = getelementptr inbounds %struct.transfers, ptr %49, i32 0, i32 52
  %51 = getelementptr inbounds [2048 x i8], ptr %50, i64 0, i64 0
  %52 = getelementptr inbounds [2048 x i8], ptr %23, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %51, ptr noundef @.str.2, ptr noundef @__func__.transfer_selection_sampling, i32 noundef 2634, ptr noundef %52)
  call void @llvm.lifetime.end.p0(i64 2048, ptr %23) #4
  call void @llvm.lifetime.end.p0(i64 2048, ptr %22) #4
  store i32 1, ptr %8, align 4
  store i32 1, ptr %21, align 4
  br label %119

53:                                               ; preds = %42
  %54 = load double, ptr %17, align 8, !tbaa !11
  %55 = load double, ptr %19, align 8, !tbaa !11
  %56 = fcmp oeq double %54, %55
  br i1 %56, label %57, label %77

57:                                               ; preds = %53
  %58 = load i32, ptr %15, align 4, !tbaa !9
  %59 = icmp ne i32 %58, 1
  br i1 %59, label %60, label %69

60:                                               ; preds = %57
  call void @llvm.lifetime.start.p0(i64 2048, ptr %24) #4
  %61 = getelementptr inbounds [2048 x i8], ptr %24, i64 0, i64 0
  %62 = load i32, ptr %15, align 4, !tbaa !9
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %61, ptr noundef @.str.81, i32 noundef %62)
  call void @llvm.lifetime.start.p0(i64 2048, ptr %25) #4
  %63 = getelementptr inbounds [2048 x i8], ptr %25, i64 0, i64 0
  %64 = getelementptr inbounds [2048 x i8], ptr %24, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %63, ptr noundef @.str.42, ptr noundef @.str.82, ptr noundef %64)
  %65 = load ptr, ptr %12, align 8, !tbaa !5
  %66 = getelementptr inbounds %struct.transfers, ptr %65, i32 0, i32 52
  %67 = getelementptr inbounds [2048 x i8], ptr %66, i64 0, i64 0
  %68 = getelementptr inbounds [2048 x i8], ptr %25, i64 0, i64 0
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef %67, ptr noundef @.str.2, ptr noundef @__func__.transfer_selection_sampling, i32 noundef 2640, ptr noundef %68)
  call void @llvm.lifetime.end.p0(i64 2048, ptr %25) #4
  call void @llvm.lifetime.end.p0(i64 2048, ptr %24) #4
  store i32 1, ptr %8, align 4
  store i32 1, ptr %21, align 4
  br label %119

69:                                               ; preds = %57
  %70 = load ptr, ptr %10, align 8, !tbaa !5
  %71 = getelementptr inbounds %struct.background, ptr %70, i32 0, i32 44
  %72 = load double, ptr %71, align 8, !tbaa !13
  %73 = load double, ptr %18, align 8, !tbaa !11
  %74 = fsub double %72, %73
  %75 = load ptr, ptr %14, align 8, !tbaa !5
  %76 = getelementptr inbounds double, ptr %75, i64 0
  store double %74, ptr %76, align 8, !tbaa !11
  br label %118

77:                                               ; preds = %53
  store i32 0, ptr %16, align 4, !tbaa !9
  br label %78

78:                                               ; preds = %104, %77
  %79 = load i32, ptr %16, align 4, !tbaa !9
  %80 = load i32, ptr %15, align 4, !tbaa !9
  %81 = sub nsw i32 %80, 1
  %82 = icmp slt i32 %79, %81
  br i1 %82, label %83, label %107

83:                                               ; preds = %78
  %84 = load ptr, ptr %10, align 8, !tbaa !5
  %85 = getelementptr inbounds %struct.background, ptr %84, i32 0, i32 44
  %86 = load double, ptr %85, align 8, !tbaa !13
  %87 = load double, ptr %17, align 8, !tbaa !11
  %88 = fsub double %86, %87
  %89 = load i32, ptr %16, align 4, !tbaa !9
  %90 = sitofp i32 %89 to double
  %91 = load i32, ptr %15, align 4, !tbaa !9
  %92 = sitofp i32 %91 to double
  %93 = fsub double %92, 1.000000e+00
  %94 = fdiv double %90, %93
  %95 = load double, ptr %19, align 8, !tbaa !11
  %96 = load double, ptr %17, align 8, !tbaa !11
  %97 = fsub double %95, %96
  %98 = fneg double %94
  %99 = call double @llvm.fmuladd.f64(double %98, double %97, double %88)
  %100 = load ptr, ptr %14, align 8, !tbaa !5
  %101 = load i32, ptr %16, align 4, !tbaa !9
  %102 = sext i32 %101 to i64
  %103 = getelementptr inbounds double, ptr %100, i64 %102
  store double %99, ptr %103, align 8, !tbaa !11
  br label %104

104:                                              ; preds = %83
  %105 = load i32, ptr %16, align 4, !tbaa !9
  %106 = add nsw i32 %105, 1
  store i32 %106, ptr %16, align 4, !tbaa !9
  br label %78, !llvm.loop !16

107:                                              ; preds = %78
  %108 = load ptr, ptr %10, align 8, !tbaa !5
  %109 = getelementptr inbounds %struct.background, ptr %108, i32 0, i32 44
  %110 = load double, ptr %109, align 8, !tbaa !13
  %111 = load double, ptr %19, align 8, !tbaa !11
  %112 = fsub double %110, %111
  %113 = load ptr, ptr %14, align 8, !tbaa !5
  %114 = load i32, ptr %15, align 4, !tbaa !9
  %115 = sub nsw i32 %114, 1
  %116 = sext i32 %115 to i64
  %117 = getelementptr inbounds double, ptr %113, i64 %116
  store double %112, ptr %117, align 8, !tbaa !11
  br label %118

118:                                              ; preds = %107, %69
  store i32 0, ptr %8, align 4
  store i32 1, ptr %21, align 4
  br label %119

119:                                              ; preds = %118, %60, %45, %33
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #4
  %120 = load i32, ptr %8, align 4
  ret i32 %120
}

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { 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 = { 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 = !{!"double", !7, i64 0}
!13 = !{!14, !12, i64 344}
!14 = !{!"background", !12, i64 0, !12, i64 8, !12, i64 16, !12, i64 24, !12, i64 32, !12, i64 40, !12, i64 48, !10, i64 56, !12, i64 64, !12, i64 72, !12, i64 80, !12, i64 88, !15, i64 96, !12, i64 104, !12, i64 112, !12, i64 120, !12, i64 128, !12, i64 136, !12, i64 144, !12, i64 152, !12, i64 160, !12, i64 168, !15, i64 176, !12, i64 184, !12, i64 192, !6, i64 200, !10, i64 208, !10, i64 212, !12, i64 216, !10, i64 224, !6, i64 232, !6, i64 240, !12, i64 248, !6, i64 256, !12, i64 264, !6, i64 272, !12, i64 280, !6, i64 288, !12, i64 296, !6, i64 304, !6, i64 312, !6, i64 320, !12, i64 328, !12, i64 336, !12, i64 344, !12, i64 352, !10, i64 360, !6, i64 368, !12, i64 376, !12, i64 384, !12, i64 392, !12, i64 400, !12, i64 408, !12, i64 416, !12, i64 424, !12, i64 432, !12, i64 440, !12, i64 448, !12, i64 456, !10, i64 464, !10, i64 468, !10, i64 472, !10, i64 476, !10, i64 480, !10, i64 484, !10, i64 488, !10, i64 492, !10, i64 496, !10, i64 500, !10, i64 504, !10, i64 508, !10, i64 512, !10, i64 516, !10, i64 520, !10, i64 524, !10, i64 528, !10, i64 532, !10, i64 536, !10, i64 540, !10, i64 544, !10, i64 548, !10, i64 552, !10, i64 556, !10, i64 560, !10, i64 564, !10, i64 568, !10, i64 572, !10, i64 576, !10, i64 580, !10, i64 584, !10, i64 588, !10, i64 592, !10, i64 596, !10, i64 600, !10, i64 604, !10, i64 608, !10, i64 612, !10, i64 616, !10, i64 620, !10, i64 624, !10, i64 628, !6, i64 632, !6, i64 640, !6, i64 648, !6, i64 656, !6, i64 664, !10, i64 672, !10, i64 676, !10, i64 680, !10, i64 684, !10, i64 688, !10, i64 692, !10, i64 696, !10, i64 700, !10, i64 704, !10, i64 708, !10, i64 712, !10, i64 716, !10, i64 720, !15, i64 724, !15, i64 726, !15, i64 728, !15, i64 730, !15, i64 732, !15, i64 734, !15, i64 736, !15, i64 738, !15, i64 740, !15, i64 742, !15, i64 744, !6, i64 752, !6, i64 760, !6, i64 768, !6, i64 776, !6, i64 784, !6, i64 792, !6, i64 800, !6, i64 808, !6, i64 816, !6, i64 824, !6, i64 832, !15, i64 840, !15, i64 842, !15, i64 844, !15, i64 846, !15, i64 848, !15, i64 850, !7, i64 852, !15, i64 2900, !7, i64 2902}
!15 = !{!"short", !7, i64 0}
!16 = distinct !{!16, !17}
!17 = !{!"llvm.loop.mustprogress"}


; 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 [18 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.42 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.57 = external hidden unnamed_addr constant [81 x i8], align 1
@__func__.transfer_selection_sampling = external hidden unnamed_addr constant [28 x i8], align 1
@.str.79 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.80 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.81 = external hidden unnamed_addr constant [58 x i8], align 1
@.str.82 = external hidden unnamed_addr constant [13 x i8], align 1

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

declare void @class_protect_sprintf(ptr noundef, ptr noundef, ...) local_unnamed_addr #1

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

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

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

; Function Attrs: nounwind uwtable
define dso_local range(i32 0, 2) i32 @transfer_selection_sampling(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef %3, i32 noundef %4, ptr nocapture noundef writeonly %5, i32 noundef %6) local_unnamed_addr #3 {
  %8 = alloca double, align 8
  %9 = alloca double, align 8
  %10 = alloca double, align 8
  %11 = alloca [2048 x i8], align 16
  %12 = alloca [2048 x i8], align 16
  %13 = alloca [2048 x i8], align 16
  %14 = alloca [2048 x i8], align 16
  %15 = alloca [2048 x i8], align 16
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #5
  %16 = call i32 @transfer_selection_times(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef %3, i32 noundef %4, ptr noundef nonnull %8, ptr noundef nonnull %9, ptr noundef nonnull %10)
  %17 = icmp eq i32 %16, 1
  br i1 %17, label %18, label %20

18:                                               ; preds = %7
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %11) #5
  %19 = getelementptr inbounds i8, ptr %3, i64 2380
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %11, ptr noundef nonnull @.str, ptr noundef nonnull @.str.57, ptr noundef nonnull %19) #5
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %19, ptr noundef nonnull @.str.2, ptr noundef nonnull @__func__.transfer_selection_sampling, i32 noundef 2630, ptr noundef nonnull %11) #5
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %11) #5
  br label %81

20:                                               ; preds = %7
  %21 = icmp slt i32 %6, 1
  br i1 %21, label %22, label %24

22:                                               ; preds = %20
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %12) #5
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %12, ptr noundef nonnull @.str.79) #5
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %13) #5
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %13, ptr noundef nonnull @.str.42, ptr noundef nonnull @.str.80, ptr noundef nonnull %12) #5
  %23 = getelementptr inbounds i8, ptr %3, i64 2380
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %23, ptr noundef nonnull @.str.2, ptr noundef nonnull @__func__.transfer_selection_sampling, i32 noundef 2634, ptr noundef nonnull %13) #5
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %13) #5
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %12) #5
  br label %81

24:                                               ; preds = %20
  %25 = load double, ptr %8, align 8, !tbaa !5
  %26 = load double, ptr %10, align 8, !tbaa !5
  %27 = fcmp oeq double %25, %26
  %.not = icmp eq i32 %6, 1
  br i1 %27, label %53, label %.preheader

.preheader:                                       ; preds = %24
  br i1 %.not, label %._crit_edge, label %.lr.ph

.lr.ph:                                           ; preds = %.preheader
  %28 = add nsw i32 %6, -1
  %29 = getelementptr inbounds i8, ptr %1, i64 344
  %30 = uitofp nneg i32 %6 to double
  %31 = fadd double %30, -1.000000e+00
  %32 = fsub double %26, %25
  %wide.trip.count = zext i32 %28 to i64
  %min.iters.check = icmp ult i32 %6, 3
  br i1 %min.iters.check, label %scalar.ph.preheader, label %vector.memcheck

scalar.ph.preheader:                              ; preds = %middle.block, %vector.memcheck, %.lr.ph
  %indvars.iv.ph = phi i64 [ 0, %vector.memcheck ], [ 0, %.lr.ph ], [ %n.vec, %middle.block ]
  %xtraiter = and i64 %wide.trip.count, 1
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %scalar.ph.prol.loopexit, label %scalar.ph.prol

scalar.ph.prol:                                   ; preds = %scalar.ph.preheader
  %33 = load double, ptr %29, align 8, !tbaa !9
  %34 = fsub double %33, %25
  %35 = trunc nuw nsw i64 %indvars.iv.ph to i32
  %36 = uitofp nneg i32 %35 to double
  %37 = fneg double %36
  %38 = fdiv double %37, %31
  %39 = call double @llvm.fmuladd.f64(double %38, double %32, double %34)
  %40 = getelementptr inbounds double, ptr %5, i64 %indvars.iv.ph
  store double %39, ptr %40, align 8, !tbaa !5
  %indvars.iv.next.prol = or disjoint i64 %indvars.iv.ph, 1
  br label %scalar.ph.prol.loopexit

scalar.ph.prol.loopexit:                          ; preds = %scalar.ph.prol, %scalar.ph.preheader
  %indvars.iv.unr = phi i64 [ %indvars.iv.ph, %scalar.ph.preheader ], [ %indvars.iv.next.prol, %scalar.ph.prol ]
  %41 = add nsw i64 %wide.trip.count, -1
  %42 = icmp eq i64 %indvars.iv.ph, %41
  br i1 %42, label %._crit_edge, label %scalar.ph

vector.memcheck:                                  ; preds = %.lr.ph
  %43 = shl nuw nsw i64 %wide.trip.count, 3
  %scevgep = getelementptr i8, ptr %5, i64 %43
  %scevgep31 = getelementptr i8, ptr %1, i64 352
  %bound0 = icmp ugt ptr %scevgep31, %5
  %bound1 = icmp ult ptr %29, %scevgep
  %found.conflict = and i1 %bound0, %bound1
  br i1 %found.conflict, label %scalar.ph.preheader, label %vector.ph

vector.ph:                                        ; preds = %vector.memcheck
  %n.vec = and i64 %wide.trip.count, 2147483646
  %broadcast.splatinsert34 = insertelement <2 x double> poison, double %31, i64 0
  %broadcast.splat35 = shufflevector <2 x double> %broadcast.splatinsert34, <2 x double> poison, <2 x i32> zeroinitializer
  %broadcast.splatinsert36 = insertelement <2 x double> poison, double %32, i64 0
  %broadcast.splat37 = shufflevector <2 x double> %broadcast.splatinsert36, <2 x double> poison, <2 x i32> zeroinitializer
  %44 = load double, ptr %29, align 8, !tbaa !9, !alias.scope !14
  %.scalar = fsub double %44, %25
  %45 = insertelement <2 x double> poison, double %.scalar, i64 0
  %46 = shufflevector <2 x double> %45, <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 ]
  %vec.ind = phi <2 x i32> [ <i32 0, i32 1>, %vector.ph ], [ %vec.ind.next, %vector.body ]
  %47 = uitofp <2 x i32> %vec.ind to <2 x double>
  %48 = fneg <2 x double> %47
  %49 = fdiv <2 x double> %48, %broadcast.splat35
  %50 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %49, <2 x double> %broadcast.splat37, <2 x double> %46)
  %51 = getelementptr inbounds double, ptr %5, i64 %index
  store <2 x double> %50, ptr %51, align 8, !tbaa !5, !alias.scope !17, !noalias !14
  %index.next = add nuw i64 %index, 2
  %vec.ind.next = add <2 x i32> %vec.ind, <i32 2, i32 2>
  %52 = icmp eq i64 %index.next, %n.vec
  br i1 %52, label %middle.block, label %vector.body, !llvm.loop !19

middle.block:                                     ; preds = %vector.body
  %cmp.n = icmp eq i64 %n.vec, %wide.trip.count
  br i1 %cmp.n, label %._crit_edge, label %scalar.ph.preheader

53:                                               ; preds = %24
  br i1 %.not, label %56, label %54

54:                                               ; preds = %53
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %14) #5
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %14, ptr noundef nonnull @.str.81, i32 noundef %6) #5
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %15) #5
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %15, ptr noundef nonnull @.str.42, ptr noundef nonnull @.str.82, ptr noundef nonnull %14) #5
  %55 = getelementptr inbounds i8, ptr %3, i64 2380
  call void (ptr, ptr, ...) @class_protect_sprintf(ptr noundef nonnull %55, ptr noundef nonnull @.str.2, ptr noundef nonnull @__func__.transfer_selection_sampling, i32 noundef 2640, ptr noundef nonnull %15) #5
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %15) #5
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %14) #5
  br label %81

56:                                               ; preds = %53
  %57 = getelementptr inbounds i8, ptr %1, i64 344
  %58 = load double, ptr %57, align 8, !tbaa !9
  %59 = load double, ptr %9, align 8, !tbaa !5
  %60 = fsub double %58, %59
  store double %60, ptr %5, align 8, !tbaa !5
  br label %81

scalar.ph:                                        ; preds = %scalar.ph.prol.loopexit, %scalar.ph
  %indvars.iv = phi i64 [ %indvars.iv.next.1, %scalar.ph ], [ %indvars.iv.unr, %scalar.ph.prol.loopexit ]
  %61 = load double, ptr %29, align 8, !tbaa !9
  %62 = fsub double %61, %25
  %63 = trunc nuw nsw i64 %indvars.iv to i32
  %64 = uitofp nneg i32 %63 to double
  %65 = fneg double %64
  %66 = fdiv double %65, %31
  %67 = call double @llvm.fmuladd.f64(double %66, double %32, double %62)
  %68 = getelementptr inbounds double, ptr %5, i64 %indvars.iv
  store double %67, ptr %68, align 8, !tbaa !5
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %69 = load double, ptr %29, align 8, !tbaa !9
  %70 = fsub double %69, %25
  %71 = trunc nuw nsw i64 %indvars.iv.next to i32
  %72 = uitofp nneg i32 %71 to double
  %73 = fneg double %72
  %74 = fdiv double %73, %31
  %75 = call double @llvm.fmuladd.f64(double %74, double %32, double %70)
  %76 = getelementptr inbounds double, ptr %5, i64 %indvars.iv.next
  store double %75, ptr %76, align 8, !tbaa !5
  %indvars.iv.next.1 = add nuw nsw i64 %indvars.iv, 2
  %exitcond.not.1 = icmp eq i64 %indvars.iv.next.1, %wide.trip.count
  br i1 %exitcond.not.1, label %._crit_edge, label %scalar.ph, !llvm.loop !23

._crit_edge:                                      ; preds = %scalar.ph.prol.loopexit, %scalar.ph, %middle.block, %.preheader
  %.pre-phi = phi i64 [ 0, %.preheader ], [ %wide.trip.count, %middle.block ], [ %wide.trip.count, %scalar.ph ], [ %wide.trip.count, %scalar.ph.prol.loopexit ]
  %77 = getelementptr inbounds i8, ptr %1, i64 344
  %78 = load double, ptr %77, align 8, !tbaa !9
  %79 = fsub double %78, %26
  %80 = getelementptr inbounds double, ptr %5, i64 %.pre-phi
  store double %79, ptr %80, align 8, !tbaa !5
  br label %81

81:                                               ; preds = %56, %._crit_edge, %54, %22, %18
  %.025 = phi i32 [ 1, %18 ], [ 1, %22 ], [ 1, %54 ], [ 0, %._crit_edge ], [ 0, %56 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #5
  ret i32 %.025
}

; 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 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { 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 = { 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 = !{!"double", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !6, i64 344}
!10 = !{!"background", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !11, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !12, i64 96, !6, i64 104, !6, i64 112, !6, i64 120, !6, i64 128, !6, i64 136, !6, i64 144, !6, i64 152, !6, i64 160, !6, i64 168, !12, i64 176, !6, i64 184, !6, i64 192, !13, i64 200, !11, i64 208, !11, i64 212, !6, i64 216, !11, i64 224, !13, i64 232, !13, i64 240, !6, i64 248, !13, i64 256, !6, i64 264, !13, i64 272, !6, i64 280, !13, i64 288, !6, i64 296, !13, i64 304, !13, i64 312, !13, i64 320, !6, i64 328, !6, i64 336, !6, i64 344, !6, i64 352, !11, i64 360, !13, i64 368, !6, i64 376, !6, i64 384, !6, i64 392, !6, i64 400, !6, i64 408, !6, i64 416, !6, i64 424, !6, i64 432, !6, i64 440, !6, i64 448, !6, i64 456, !11, i64 464, !11, i64 468, !11, i64 472, !11, i64 476, !11, i64 480, !11, i64 484, !11, i64 488, !11, i64 492, !11, i64 496, !11, i64 500, !11, i64 504, !11, i64 508, !11, i64 512, !11, i64 516, !11, i64 520, !11, i64 524, !11, i64 528, !11, i64 532, !11, i64 536, !11, i64 540, !11, i64 544, !11, i64 548, !11, i64 552, !11, i64 556, !11, i64 560, !11, i64 564, !11, i64 568, !11, i64 572, !11, i64 576, !11, i64 580, !11, i64 584, !11, i64 588, !11, i64 592, !11, i64 596, !11, i64 600, !11, i64 604, !11, i64 608, !11, i64 612, !11, i64 616, !11, i64 620, !11, i64 624, !11, i64 628, !13, i64 632, !13, i64 640, !13, i64 648, !13, i64 656, !13, i64 664, !11, i64 672, !11, i64 676, !11, i64 680, !11, i64 684, !11, i64 688, !11, i64 692, !11, i64 696, !11, i64 700, !11, i64 704, !11, i64 708, !11, i64 712, !11, i64 716, !11, i64 720, !12, i64 724, !12, i64 726, !12, i64 728, !12, i64 730, !12, i64 732, !12, i64 734, !12, i64 736, !12, i64 738, !12, i64 740, !12, i64 742, !12, i64 744, !13, i64 752, !13, i64 760, !13, i64 768, !13, i64 776, !13, i64 784, !13, i64 792, !13, i64 800, !13, i64 808, !13, i64 816, !13, i64 824, !13, i64 832, !12, i64 840, !12, i64 842, !12, i64 844, !12, i64 846, !12, i64 848, !12, i64 850, !7, i64 852, !12, i64 2900, !7, i64 2902}
!11 = !{!"int", !7, i64 0}
!12 = !{!"short", !7, i64 0}
!13 = !{!"any pointer", !7, i64 0}
!14 = !{!15}
!15 = distinct !{!15, !16}
!16 = distinct !{!16, !"LVerDomain"}
!17 = !{!18}
!18 = distinct !{!18, !16}
!19 = distinct !{!19, !20, !21, !22}
!20 = !{!"llvm.loop.mustprogress"}
!21 = !{!"llvm.loop.isvectorized", i32 1}
!22 = !{!"llvm.loop.unroll.runtime.disable"}
!23 = distinct !{!23, !20, !21}


; Effective O3 passes: ADCEPass,CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LCSSAPass,LICMPass,LoopLoadEliminationPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,LoopVectorizePass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass,VectorCombinePass