; LLVM IR from niuyishuai/PDCABB :: LAPACK_BLAS/BLAS/SRC (daxpy)

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

; Function Attrs: nounwind uwtable
define dso_local i32 @f2c_daxpy(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef %3, ptr noundef %4, ptr noundef %5) #0 {
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca i64, align 8
  %15 = alloca i64, align 8
  %16 = alloca i64, align 8
  %17 = alloca i64, align 8
  %18 = alloca i64, align 8
  %19 = alloca i64, align 8
  %20 = alloca i32, align 4
  store ptr %0, ptr %8, align 8, !tbaa !5
  store ptr %1, ptr %9, align 8, !tbaa !5
  store ptr %2, ptr %10, align 8, !tbaa !5
  store ptr %3, ptr %11, align 8, !tbaa !5
  store ptr %4, ptr %12, align 8, !tbaa !5
  store ptr %5, ptr %13, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #3
  %21 = load ptr, ptr %12, align 8, !tbaa !5
  %22 = getelementptr inbounds double, ptr %21, i32 -1
  store ptr %22, ptr %12, align 8, !tbaa !5
  %23 = load ptr, ptr %10, align 8, !tbaa !5
  %24 = getelementptr inbounds double, ptr %23, i32 -1
  store ptr %24, ptr %10, align 8, !tbaa !5
  %25 = load ptr, ptr %8, align 8, !tbaa !5
  %26 = load i64, ptr %25, align 8, !tbaa !9
  %27 = icmp sle i64 %26, 0
  br i1 %27, label %28, label %29

28:                                               ; preds = %6
  store i32 0, ptr %7, align 4
  store i32 1, ptr %20, align 4
  br label %199

29:                                               ; preds = %6
  %30 = load ptr, ptr %9, align 8, !tbaa !5
  %31 = load double, ptr %30, align 8, !tbaa !11
  %32 = fcmp oeq double %31, 0.000000e+00
  br i1 %32, label %33, label %34

33:                                               ; preds = %29
  store i32 0, ptr %7, align 4
  store i32 1, ptr %20, align 4
  br label %199

34:                                               ; preds = %29
  %35 = load ptr, ptr %11, align 8, !tbaa !5
  %36 = load i64, ptr %35, align 8, !tbaa !9
  %37 = icmp eq i64 %36, 1
  br i1 %37, label %38, label %43

38:                                               ; preds = %34
  %39 = load ptr, ptr %13, align 8, !tbaa !5
  %40 = load i64, ptr %39, align 8, !tbaa !9
  %41 = icmp eq i64 %40, 1
  br i1 %41, label %42, label %43

42:                                               ; preds = %38
  br label %100

43:                                               ; preds = %38, %34
  store i64 1, ptr %17, align 8, !tbaa !9
  store i64 1, ptr %18, align 8, !tbaa !9
  %44 = load ptr, ptr %11, align 8, !tbaa !5
  %45 = load i64, ptr %44, align 8, !tbaa !9
  %46 = icmp slt i64 %45, 0
  br i1 %46, label %47, label %56

47:                                               ; preds = %43
  %48 = load ptr, ptr %8, align 8, !tbaa !5
  %49 = load i64, ptr %48, align 8, !tbaa !9
  %50 = sub nsw i64 0, %49
  %51 = add nsw i64 %50, 1
  %52 = load ptr, ptr %11, align 8, !tbaa !5
  %53 = load i64, ptr %52, align 8, !tbaa !9
  %54 = mul nsw i64 %51, %53
  %55 = add nsw i64 %54, 1
  store i64 %55, ptr %17, align 8, !tbaa !9
  br label %56

56:                                               ; preds = %47, %43
  %57 = load ptr, ptr %13, align 8, !tbaa !5
  %58 = load i64, ptr %57, align 8, !tbaa !9
  %59 = icmp slt i64 %58, 0
  br i1 %59, label %60, label %69

60:                                               ; preds = %56
  %61 = load ptr, ptr %8, align 8, !tbaa !5
  %62 = load i64, ptr %61, align 8, !tbaa !9
  %63 = sub nsw i64 0, %62
  %64 = add nsw i64 %63, 1
  %65 = load ptr, ptr %13, align 8, !tbaa !5
  %66 = load i64, ptr %65, align 8, !tbaa !9
  %67 = mul nsw i64 %64, %66
  %68 = add nsw i64 %67, 1
  store i64 %68, ptr %18, align 8, !tbaa !9
  br label %69

69:                                               ; preds = %60, %56
  %70 = load ptr, ptr %8, align 8, !tbaa !5
  %71 = load i64, ptr %70, align 8, !tbaa !9
  store i64 %71, ptr %14, align 8, !tbaa !9
  store i64 1, ptr %15, align 8, !tbaa !9
  br label %72

72:                                               ; preds = %96, %69
  %73 = load i64, ptr %15, align 8, !tbaa !9
  %74 = load i64, ptr %14, align 8, !tbaa !9
  %75 = icmp sle i64 %73, %74
  br i1 %75, label %76, label %99

76:                                               ; preds = %72
  %77 = load ptr, ptr %9, align 8, !tbaa !5
  %78 = load double, ptr %77, align 8, !tbaa !11
  %79 = load ptr, ptr %10, align 8, !tbaa !5
  %80 = load i64, ptr %17, align 8, !tbaa !9
  %81 = getelementptr inbounds double, ptr %79, i64 %80
  %82 = load double, ptr %81, align 8, !tbaa !11
  %83 = load ptr, ptr %12, align 8, !tbaa !5
  %84 = load i64, ptr %18, align 8, !tbaa !9
  %85 = getelementptr inbounds double, ptr %83, i64 %84
  %86 = load double, ptr %85, align 8, !tbaa !11
  %87 = call double @llvm.fmuladd.f64(double %78, double %82, double %86)
  store double %87, ptr %85, align 8, !tbaa !11
  %88 = load ptr, ptr %11, align 8, !tbaa !5
  %89 = load i64, ptr %88, align 8, !tbaa !9
  %90 = load i64, ptr %17, align 8, !tbaa !9
  %91 = add nsw i64 %90, %89
  store i64 %91, ptr %17, align 8, !tbaa !9
  %92 = load ptr, ptr %13, align 8, !tbaa !5
  %93 = load i64, ptr %92, align 8, !tbaa !9
  %94 = load i64, ptr %18, align 8, !tbaa !9
  %95 = add nsw i64 %94, %93
  store i64 %95, ptr %18, align 8, !tbaa !9
  br label %96

96:                                               ; preds = %76
  %97 = load i64, ptr %15, align 8, !tbaa !9
  %98 = add nsw i64 %97, 1
  store i64 %98, ptr %15, align 8, !tbaa !9
  br label %72, !llvm.loop !13

99:                                               ; preds = %72
  store i32 0, ptr %7, align 4
  store i32 1, ptr %20, align 4
  br label %199

100:                                              ; preds = %42
  %101 = load ptr, ptr %8, align 8, !tbaa !5
  %102 = load i64, ptr %101, align 8, !tbaa !9
  %103 = srem i64 %102, 4
  store i64 %103, ptr %16, align 8, !tbaa !9
  %104 = load i64, ptr %16, align 8, !tbaa !9
  %105 = icmp eq i64 %104, 0
  br i1 %105, label %106, label %107

106:                                              ; preds = %100
  br label %134

107:                                              ; preds = %100
  %108 = load i64, ptr %16, align 8, !tbaa !9
  store i64 %108, ptr %14, align 8, !tbaa !9
  store i64 1, ptr %15, align 8, !tbaa !9
  br label %109

109:                                              ; preds = %125, %107
  %110 = load i64, ptr %15, align 8, !tbaa !9
  %111 = load i64, ptr %14, align 8, !tbaa !9
  %112 = icmp sle i64 %110, %111
  br i1 %112, label %113, label %128

113:                                              ; preds = %109
  %114 = load ptr, ptr %9, align 8, !tbaa !5
  %115 = load double, ptr %114, align 8, !tbaa !11
  %116 = load ptr, ptr %10, align 8, !tbaa !5
  %117 = load i64, ptr %15, align 8, !tbaa !9
  %118 = getelementptr inbounds double, ptr %116, i64 %117
  %119 = load double, ptr %118, align 8, !tbaa !11
  %120 = load ptr, ptr %12, align 8, !tbaa !5
  %121 = load i64, ptr %15, align 8, !tbaa !9
  %122 = getelementptr inbounds double, ptr %120, i64 %121
  %123 = load double, ptr %122, align 8, !tbaa !11
  %124 = call double @llvm.fmuladd.f64(double %115, double %119, double %123)
  store double %124, ptr %122, align 8, !tbaa !11
  br label %125

125:                                              ; preds = %113
  %126 = load i64, ptr %15, align 8, !tbaa !9
  %127 = add nsw i64 %126, 1
  store i64 %127, ptr %15, align 8, !tbaa !9
  br label %109, !llvm.loop !15

128:                                              ; preds = %109
  %129 = load ptr, ptr %8, align 8, !tbaa !5
  %130 = load i64, ptr %129, align 8, !tbaa !9
  %131 = icmp slt i64 %130, 4
  br i1 %131, label %132, label %133

132:                                              ; preds = %128
  store i32 0, ptr %7, align 4
  store i32 1, ptr %20, align 4
  br label %199

133:                                              ; preds = %128
  br label %134

134:                                              ; preds = %133, %106
  %135 = load i64, ptr %16, align 8, !tbaa !9
  %136 = add nsw i64 %135, 1
  store i64 %136, ptr %19, align 8, !tbaa !9
  %137 = load ptr, ptr %8, align 8, !tbaa !5
  %138 = load i64, ptr %137, align 8, !tbaa !9
  store i64 %138, ptr %14, align 8, !tbaa !9
  %139 = load i64, ptr %19, align 8, !tbaa !9
  store i64 %139, ptr %15, align 8, !tbaa !9
  br label %140

140:                                              ; preds = %195, %134
  %141 = load i64, ptr %15, align 8, !tbaa !9
  %142 = load i64, ptr %14, align 8, !tbaa !9
  %143 = icmp sle i64 %141, %142
  br i1 %143, label %144, label %198

144:                                              ; preds = %140
  %145 = load ptr, ptr %9, align 8, !tbaa !5
  %146 = load double, ptr %145, align 8, !tbaa !11
  %147 = load ptr, ptr %10, align 8, !tbaa !5
  %148 = load i64, ptr %15, align 8, !tbaa !9
  %149 = getelementptr inbounds double, ptr %147, i64 %148
  %150 = load double, ptr %149, align 8, !tbaa !11
  %151 = load ptr, ptr %12, align 8, !tbaa !5
  %152 = load i64, ptr %15, align 8, !tbaa !9
  %153 = getelementptr inbounds double, ptr %151, i64 %152
  %154 = load double, ptr %153, align 8, !tbaa !11
  %155 = call double @llvm.fmuladd.f64(double %146, double %150, double %154)
  store double %155, ptr %153, align 8, !tbaa !11
  %156 = load ptr, ptr %9, align 8, !tbaa !5
  %157 = load double, ptr %156, align 8, !tbaa !11
  %158 = load ptr, ptr %10, align 8, !tbaa !5
  %159 = load i64, ptr %15, align 8, !tbaa !9
  %160 = add nsw i64 %159, 1
  %161 = getelementptr inbounds double, ptr %158, i64 %160
  %162 = load double, ptr %161, align 8, !tbaa !11
  %163 = load ptr, ptr %12, align 8, !tbaa !5
  %164 = load i64, ptr %15, align 8, !tbaa !9
  %165 = add nsw i64 %164, 1
  %166 = getelementptr inbounds double, ptr %163, i64 %165
  %167 = load double, ptr %166, align 8, !tbaa !11
  %168 = call double @llvm.fmuladd.f64(double %157, double %162, double %167)
  store double %168, ptr %166, align 8, !tbaa !11
  %169 = load ptr, ptr %9, align 8, !tbaa !5
  %170 = load double, ptr %169, align 8, !tbaa !11
  %171 = load ptr, ptr %10, align 8, !tbaa !5
  %172 = load i64, ptr %15, align 8, !tbaa !9
  %173 = add nsw i64 %172, 2
  %174 = getelementptr inbounds double, ptr %171, i64 %173
  %175 = load double, ptr %174, align 8, !tbaa !11
  %176 = load ptr, ptr %12, align 8, !tbaa !5
  %177 = load i64, ptr %15, align 8, !tbaa !9
  %178 = add nsw i64 %177, 2
  %179 = getelementptr inbounds double, ptr %176, i64 %178
  %180 = load double, ptr %179, align 8, !tbaa !11
  %181 = call double @llvm.fmuladd.f64(double %170, double %175, double %180)
  store double %181, ptr %179, align 8, !tbaa !11
  %182 = load ptr, ptr %9, align 8, !tbaa !5
  %183 = load double, ptr %182, align 8, !tbaa !11
  %184 = load ptr, ptr %10, align 8, !tbaa !5
  %185 = load i64, ptr %15, align 8, !tbaa !9
  %186 = add nsw i64 %185, 3
  %187 = getelementptr inbounds double, ptr %184, i64 %186
  %188 = load double, ptr %187, align 8, !tbaa !11
  %189 = load ptr, ptr %12, align 8, !tbaa !5
  %190 = load i64, ptr %15, align 8, !tbaa !9
  %191 = add nsw i64 %190, 3
  %192 = getelementptr inbounds double, ptr %189, i64 %191
  %193 = load double, ptr %192, align 8, !tbaa !11
  %194 = call double @llvm.fmuladd.f64(double %183, double %188, double %193)
  store double %194, ptr %192, align 8, !tbaa !11
  br label %195

195:                                              ; preds = %144
  %196 = load i64, ptr %15, align 8, !tbaa !9
  %197 = add nsw i64 %196, 4
  store i64 %197, ptr %15, align 8, !tbaa !9
  br label %140, !llvm.loop !16

198:                                              ; preds = %140
  store i32 0, ptr %7, align 4
  store i32 1, ptr %20, align 4
  br label %199

199:                                              ; preds = %198, %132, %99, %33, %28
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #3
  %200 = load i32, ptr %7, align 4
  ret i32 %200
}

; 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 nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #2

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

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = !{!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}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

; Function Attrs: nofree norecurse nosync nounwind memory(argmem: readwrite) uwtable
define dso_local noundef i32 @f2c_daxpy(ptr nocapture noundef readonly %0, ptr nocapture noundef readonly %1, ptr nocapture noundef readonly %2, ptr nocapture noundef readonly %3, ptr nocapture noundef %4, ptr nocapture noundef readonly %5) local_unnamed_addr #0 {
  %7 = getelementptr inbounds i8, ptr %4, i64 -8
  %8 = getelementptr inbounds i8, ptr %2, i64 -8
  %9 = load i64, ptr %0, align 8, !tbaa !5
  %10 = icmp slt i64 %9, 1
  br i1 %10, label %.loopexit, label %11

11:                                               ; preds = %6
  %12 = load double, ptr %1, align 8, !tbaa !9
  %13 = fcmp oeq double %12, 0.000000e+00
  br i1 %13, label %.loopexit, label %14

14:                                               ; preds = %11
  %15 = load i64, ptr %3, align 8, !tbaa !5
  %16 = icmp eq i64 %15, 1
  br i1 %16, label %17, label %thread-pre-split

17:                                               ; preds = %14
  %18 = load i64, ptr %5, align 8, !tbaa !5
  %19 = icmp eq i64 %18, 1
  br i1 %19, label %78, label %..thread_crit_edge

..thread_crit_edge:                               ; preds = %17
  %.pre = sub nsw i64 1, %9
  br label %.lr.ph.preheader

thread-pre-split:                                 ; preds = %14
  %20 = icmp slt i64 %15, 0
  %21 = sub nsw i64 1, %9
  %22 = mul nsw i64 %15, %21
  %23 = add nuw nsw i64 %22, 1
  %.064.ph = select i1 %20, i64 %23, i64 1
  %.pr = load i64, ptr %5, align 8, !tbaa !5
  br label %.lr.ph.preheader

.lr.ph.preheader:                                 ; preds = %thread-pre-split, %..thread_crit_edge
  %.pre-phi = phi i64 [ %.pre, %..thread_crit_edge ], [ %21, %thread-pre-split ]
  %24 = phi i64 [ %18, %..thread_crit_edge ], [ %.pr, %thread-pre-split ]
  %.064 = phi i64 [ 1, %..thread_crit_edge ], [ %.064.ph, %thread-pre-split ]
  %25 = icmp slt i64 %24, 0
  %26 = mul nsw i64 %24, %.pre-phi
  %27 = add nuw nsw i64 %26, 1
  %.063 = select i1 %25, i64 %27, i64 1
  %min.iters.check = icmp ult i64 %9, 16
  br i1 %min.iters.check, label %.lr.ph.preheader139, label %vector.scevcheck

vector.scevcheck:                                 ; preds = %.lr.ph.preheader
  %ident.check = icmp ne i64 %24, 1
  %ident.check86 = icmp ne i64 %15, 1
  %28 = or i1 %ident.check, %ident.check86
  br i1 %28, label %.lr.ph.preheader139, label %vector.memcheck

vector.memcheck:                                  ; preds = %vector.scevcheck
  %29 = shl i64 %.063, 3
  %30 = getelementptr i8, ptr %4, i64 %29
  %scevgep = getelementptr i8, ptr %30, i64 -8
  %31 = shl i64 %9, 3
  %32 = getelementptr i8, ptr %4, i64 %29
  %33 = getelementptr i8, ptr %32, i64 %31
  %scevgep87 = getelementptr i8, ptr %33, i64 -8
  %scevgep88 = getelementptr i8, ptr %1, i64 8
  %34 = shl i64 %.064, 3
  %35 = getelementptr i8, ptr %2, i64 %34
  %36 = getelementptr i8, ptr %2, i64 %34
  %37 = getelementptr i8, ptr %36, i64 %31
  %bound0 = icmp ult ptr %scevgep, %scevgep88
  %bound1 = icmp ugt ptr %scevgep87, %1
  %found.conflict = and i1 %bound0, %bound1
  %bound091 = icmp ult ptr %30, %37
  %bound192 = icmp ult ptr %35, %33
  %found.conflict93 = and i1 %bound091, %bound192
  %conflict.rdx = or i1 %found.conflict, %found.conflict93
  br i1 %conflict.rdx, label %.lr.ph.preheader139, label %vector.ph

vector.ph:                                        ; preds = %vector.memcheck
  %n.vec = and i64 %9, 9223372036854775804
  %38 = mul nuw i64 %n.vec, %24
  %ind.end = add i64 %.063, %38
  %39 = mul nuw i64 %n.vec, %15
  %ind.end94 = add i64 %.064, %39
  %ind.end96 = or disjoint i64 %n.vec, 1
  %40 = load double, ptr %1, align 8, !tbaa !9, !alias.scope !11
  %broadcast.splatinsert102 = insertelement <2 x double> poison, double %40, i64 0
  %broadcast.splat103 = shufflevector <2 x double> %broadcast.splatinsert102, <2 x double> poison, <2 x i32> zeroinitializer
  %41 = getelementptr double, ptr %8, i64 %.064
  %42 = getelementptr double, ptr %7, i64 %.063
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %43 = getelementptr double, ptr %41, i64 %index
  %44 = getelementptr inbounds i8, ptr %43, i64 16
  %wide.load = load <2 x double>, ptr %43, align 8, !tbaa !9, !alias.scope !14
  %wide.load99 = load <2 x double>, ptr %44, align 8, !tbaa !9, !alias.scope !14
  %45 = getelementptr double, ptr %42, i64 %index
  %46 = getelementptr inbounds i8, ptr %45, i64 16
  %wide.load100 = load <2 x double>, ptr %45, align 8, !tbaa !9, !alias.scope !16, !noalias !18
  %wide.load101 = load <2 x double>, ptr %46, align 8, !tbaa !9, !alias.scope !16, !noalias !18
  %47 = tail call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %broadcast.splat103, <2 x double> %wide.load, <2 x double> %wide.load100)
  %48 = tail call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %broadcast.splat103, <2 x double> %wide.load99, <2 x double> %wide.load101)
  store <2 x double> %47, ptr %45, align 8, !tbaa !9, !alias.scope !16, !noalias !18
  store <2 x double> %48, ptr %46, align 8, !tbaa !9, !alias.scope !16, !noalias !18
  %index.next = add nuw i64 %index, 4
  %49 = icmp eq i64 %index.next, %n.vec
  br i1 %49, label %middle.block, label %vector.body, !llvm.loop !19

middle.block:                                     ; preds = %vector.body
  %cmp.n = icmp eq i64 %9, %n.vec
  br i1 %cmp.n, label %.loopexit, label %.lr.ph.preheader139

.lr.ph.preheader139:                              ; preds = %middle.block, %vector.memcheck, %vector.scevcheck, %.lr.ph.preheader
  %.177.ph = phi i64 [ %.063, %vector.memcheck ], [ %.063, %vector.scevcheck ], [ %.063, %.lr.ph.preheader ], [ %ind.end, %middle.block ]
  %.16576.ph = phi i64 [ %.064, %vector.memcheck ], [ %.064, %vector.scevcheck ], [ %.064, %.lr.ph.preheader ], [ %ind.end94, %middle.block ]
  %.06675.ph = phi i64 [ 1, %vector.memcheck ], [ 1, %vector.scevcheck ], [ 1, %.lr.ph.preheader ], [ %ind.end96, %middle.block ]
  %xtraiter = and i64 %9, 1
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %.lr.ph.prol.loopexit, label %.lr.ph.prol

.lr.ph.prol:                                      ; preds = %.lr.ph.preheader139
  %50 = load double, ptr %1, align 8, !tbaa !9
  %51 = getelementptr inbounds double, ptr %8, i64 %.16576.ph
  %52 = load double, ptr %51, align 8, !tbaa !9
  %53 = getelementptr inbounds double, ptr %7, i64 %.177.ph
  %54 = load double, ptr %53, align 8, !tbaa !9
  %55 = tail call double @llvm.fmuladd.f64(double %50, double %52, double %54)
  store double %55, ptr %53, align 8, !tbaa !9
  %56 = add nsw i64 %.16576.ph, %15
  %57 = add nsw i64 %.177.ph, %24
  %58 = add nuw i64 %.06675.ph, 1
  br label %.lr.ph.prol.loopexit

.lr.ph.prol.loopexit:                             ; preds = %.lr.ph.prol, %.lr.ph.preheader139
  %.177.unr = phi i64 [ %.177.ph, %.lr.ph.preheader139 ], [ %57, %.lr.ph.prol ]
  %.16576.unr = phi i64 [ %.16576.ph, %.lr.ph.preheader139 ], [ %56, %.lr.ph.prol ]
  %.06675.unr = phi i64 [ %.06675.ph, %.lr.ph.preheader139 ], [ %58, %.lr.ph.prol ]
  %59 = icmp eq i64 %9, %.06675.ph
  br i1 %59, label %.loopexit, label %.lr.ph

.lr.ph:                                           ; preds = %.lr.ph.prol.loopexit, %.lr.ph
  %.177 = phi i64 [ %76, %.lr.ph ], [ %.177.unr, %.lr.ph.prol.loopexit ]
  %.16576 = phi i64 [ %75, %.lr.ph ], [ %.16576.unr, %.lr.ph.prol.loopexit ]
  %.06675 = phi i64 [ %77, %.lr.ph ], [ %.06675.unr, %.lr.ph.prol.loopexit ]
  %60 = load double, ptr %1, align 8, !tbaa !9
  %61 = getelementptr inbounds double, ptr %8, i64 %.16576
  %62 = load double, ptr %61, align 8, !tbaa !9
  %63 = getelementptr inbounds double, ptr %7, i64 %.177
  %64 = load double, ptr %63, align 8, !tbaa !9
  %65 = tail call double @llvm.fmuladd.f64(double %60, double %62, double %64)
  store double %65, ptr %63, align 8, !tbaa !9
  %66 = add nsw i64 %.16576, %15
  %67 = add nsw i64 %.177, %24
  %68 = add nuw i64 %.06675, 1
  %69 = load double, ptr %1, align 8, !tbaa !9
  %70 = getelementptr inbounds double, ptr %8, i64 %66
  %71 = load double, ptr %70, align 8, !tbaa !9
  %72 = getelementptr inbounds double, ptr %7, i64 %67
  %73 = load double, ptr %72, align 8, !tbaa !9
  %74 = tail call double @llvm.fmuladd.f64(double %69, double %71, double %73)
  store double %74, ptr %72, align 8, !tbaa !9
  %75 = add nsw i64 %66, %15
  %76 = add nsw i64 %67, %24
  %77 = add nuw i64 %.06675, 2
  %exitcond.not.1 = icmp eq i64 %68, %9
  br i1 %exitcond.not.1, label %.loopexit, label %.lr.ph, !llvm.loop !23

78:                                               ; preds = %17
  %79 = and i64 %9, 3
  %80 = icmp eq i64 %79, 0
  br i1 %80, label %.lr.ph81.preheader, label %.preheader.preheader

.preheader.preheader:                             ; preds = %78
  %81 = add nuw nsw i64 %79, 1
  %82 = load double, ptr %1, align 8, !tbaa !9
  %83 = load double, ptr %2, align 8, !tbaa !9
  %84 = load double, ptr %4, align 8, !tbaa !9
  %85 = tail call double @llvm.fmuladd.f64(double %82, double %83, double %84)
  store double %85, ptr %4, align 8, !tbaa !9
  %exitcond83.not = icmp eq i64 %79, 1
  br i1 %exitcond83.not, label %98, label %.preheader.1, !llvm.loop !24

.preheader.1:                                     ; preds = %.preheader.preheader
  %86 = load double, ptr %1, align 8, !tbaa !9
  %87 = getelementptr inbounds i8, ptr %2, i64 8
  %88 = load double, ptr %87, align 8, !tbaa !9
  %89 = getelementptr inbounds i8, ptr %4, i64 8
  %90 = load double, ptr %89, align 8, !tbaa !9
  %91 = tail call double @llvm.fmuladd.f64(double %86, double %88, double %90)
  store double %91, ptr %89, align 8, !tbaa !9
  %exitcond83.not.1 = icmp eq i64 %79, 2
  br i1 %exitcond83.not.1, label %98, label %.preheader.2, !llvm.loop !24

.preheader.2:                                     ; preds = %.preheader.1
  %92 = load double, ptr %1, align 8, !tbaa !9
  %93 = getelementptr inbounds i8, ptr %2, i64 16
  %94 = load double, ptr %93, align 8, !tbaa !9
  %95 = getelementptr inbounds i8, ptr %4, i64 16
  %96 = load double, ptr %95, align 8, !tbaa !9
  %97 = tail call double @llvm.fmuladd.f64(double %92, double %94, double %96)
  store double %97, ptr %95, align 8, !tbaa !9
  br label %98

98:                                               ; preds = %.preheader.2, %.preheader.1, %.preheader.preheader
  %99 = icmp slt i64 %9, 4
  br i1 %99, label %.loopexit, label %.lr.ph81.preheader

.lr.ph81.preheader:                               ; preds = %78, %98
  %.280.ph = phi i64 [ %81, %98 ], [ 1, %78 ]
  %100 = or disjoint i64 %79, 4
  %smax117 = tail call i64 @llvm.smax.i64(i64 %9, i64 %100)
  %101 = xor i64 %79, -1
  %102 = add nsw i64 %smax117, %101
  %103 = lshr i64 %102, 2
  %104 = add nuw nsw i64 %103, 1
  %min.iters.check120 = icmp ult i64 %102, 20
  br i1 %min.iters.check120, label %.lr.ph81.preheader137, label %vector.memcheck104

vector.memcheck104:                               ; preds = %.lr.ph81.preheader
  %105 = shl nuw nsw i64 %79, 3
  %scevgep105 = getelementptr i8, ptr %4, i64 %105
  %106 = or disjoint i64 %79, 4
  %smax = tail call i64 @llvm.smax.i64(i64 %9, i64 %106)
  %107 = xor i64 %79, -1
  %108 = add nsw i64 %smax, %107
  %109 = shl i64 %108, 3
  %110 = and i64 %109, -32
  %111 = or disjoint i64 %110, %105
  %112 = add i64 %111, 32
  %scevgep106 = getelementptr i8, ptr %4, i64 %112
  %scevgep107 = getelementptr i8, ptr %1, i64 8
  %scevgep108 = getelementptr i8, ptr %2, i64 %105
  %scevgep109 = getelementptr i8, ptr %2, i64 %112
  %bound0110 = icmp ult ptr %scevgep105, %scevgep107
  %bound1111 = icmp ugt ptr %scevgep106, %1
  %found.conflict112 = and i1 %bound0110, %bound1111
  %bound0113 = icmp ult ptr %scevgep105, %scevgep109
  %bound1114 = icmp ult ptr %scevgep108, %scevgep106
  %found.conflict115 = and i1 %bound0113, %bound1114
  %conflict.rdx116 = or i1 %found.conflict112, %found.conflict115
  br i1 %conflict.rdx116, label %.lr.ph81.preheader137, label %vector.ph121

vector.ph121:                                     ; preds = %vector.memcheck104
  %n.vec123 = and i64 %104, 9223372036854775806
  %113 = shl i64 %n.vec123, 2
  %ind.end124 = add i64 %.280.ph, %113
  br label %vector.body126

vector.body126:                                   ; preds = %vector.body126, %vector.ph121
  %index127 = phi i64 [ 0, %vector.ph121 ], [ %index.next135, %vector.body126 ]
  %114 = shl i64 %index127, 2
  %offset.idx128 = add i64 %.280.ph, %114
  %115 = add i64 %offset.idx128, 4
  %116 = load double, ptr %1, align 8, !tbaa !9, !alias.scope !25
  %broadcast.splatinsert = insertelement <2 x double> poison, double %116, i64 0
  %broadcast.splat = shufflevector <2 x double> %broadcast.splatinsert, <2 x double> poison, <2 x i32> zeroinitializer
  %117 = getelementptr inbounds double, ptr %8, i64 %offset.idx128
  %118 = getelementptr inbounds double, ptr %8, i64 %115
  %119 = load double, ptr %117, align 8, !tbaa !9, !alias.scope !28
  %120 = load double, ptr %118, align 8, !tbaa !9, !alias.scope !28
  %121 = insertelement <2 x double> poison, double %119, i64 0
  %122 = insertelement <2 x double> %121, double %120, i64 1
  %123 = getelementptr inbounds double, ptr %7, i64 %offset.idx128
  %124 = getelementptr inbounds double, ptr %7, i64 %115
  %125 = load double, ptr %123, align 8, !tbaa !9, !alias.scope !30, !noalias !32
  %126 = load double, ptr %124, align 8, !tbaa !9, !alias.scope !30, !noalias !32
  %127 = insertelement <2 x double> poison, double %125, i64 0
  %128 = insertelement <2 x double> %127, double %126, i64 1
  %129 = tail call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %broadcast.splat, <2 x double> %122, <2 x double> %128)
  %130 = load double, ptr %1, align 8, !tbaa !9, !alias.scope !25
  %broadcast.splatinsert129 = insertelement <2 x double> poison, double %130, i64 0
  %broadcast.splat130 = shufflevector <2 x double> %broadcast.splatinsert129, <2 x double> poison, <2 x i32> zeroinitializer
  %131 = getelementptr double, ptr %2, i64 %offset.idx128
  %132 = getelementptr double, ptr %2, i64 %115
  %133 = load double, ptr %131, align 8, !tbaa !9, !alias.scope !28
  %134 = load double, ptr %132, align 8, !tbaa !9, !alias.scope !28
  %135 = insertelement <2 x double> poison, double %133, i64 0
  %136 = insertelement <2 x double> %135, double %134, i64 1
  %137 = getelementptr double, ptr %4, i64 %offset.idx128
  %138 = getelementptr double, ptr %4, i64 %115
  %139 = load double, ptr %137, align 8, !tbaa !9, !alias.scope !30, !noalias !32
  %140 = load double, ptr %138, align 8, !tbaa !9, !alias.scope !30, !noalias !32
  %141 = insertelement <2 x double> poison, double %139, i64 0
  %142 = insertelement <2 x double> %141, double %140, i64 1
  %143 = tail call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %broadcast.splat130, <2 x double> %136, <2 x double> %142)
  %144 = load double, ptr %1, align 8, !tbaa !9, !alias.scope !25
  %broadcast.splatinsert131 = insertelement <2 x double> poison, double %144, i64 0
  %broadcast.splat132 = shufflevector <2 x double> %broadcast.splatinsert131, <2 x double> poison, <2 x i32> zeroinitializer
  %145 = add nuw nsw i64 %offset.idx128, 2
  %146 = add i64 %offset.idx128, 6
  %147 = getelementptr inbounds double, ptr %8, i64 %145
  %148 = getelementptr inbounds double, ptr %8, i64 %146
  %149 = load double, ptr %147, align 8, !tbaa !9, !alias.scope !28
  %150 = load double, ptr %148, align 8, !tbaa !9, !alias.scope !28
  %151 = insertelement <2 x double> poison, double %149, i64 0
  %152 = insertelement <2 x double> %151, double %150, i64 1
  %153 = getelementptr inbounds double, ptr %7, i64 %145
  %154 = getelementptr inbounds double, ptr %7, i64 %146
  %155 = load double, ptr %153, align 8, !tbaa !9, !alias.scope !30, !noalias !32
  %156 = load double, ptr %154, align 8, !tbaa !9, !alias.scope !30, !noalias !32
  %157 = insertelement <2 x double> poison, double %155, i64 0
  %158 = insertelement <2 x double> %157, double %156, i64 1
  %159 = tail call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %broadcast.splat132, <2 x double> %152, <2 x double> %158)
  %160 = load double, ptr %1, align 8, !tbaa !9, !alias.scope !25
  %broadcast.splatinsert133 = insertelement <2 x double> poison, double %160, i64 0
  %broadcast.splat134 = shufflevector <2 x double> %broadcast.splatinsert133, <2 x double> poison, <2 x i32> zeroinitializer
  %161 = add nuw nsw i64 %offset.idx128, 3
  %162 = add i64 %offset.idx128, 7
  %163 = getelementptr inbounds double, ptr %8, i64 %161
  %164 = getelementptr inbounds double, ptr %8, i64 %162
  %165 = load double, ptr %163, align 8, !tbaa !9, !alias.scope !28
  %166 = load double, ptr %164, align 8, !tbaa !9, !alias.scope !28
  %167 = insertelement <2 x double> poison, double %165, i64 0
  %168 = insertelement <2 x double> %167, double %166, i64 1
  %169 = getelementptr inbounds double, ptr %7, i64 %161
  %170 = getelementptr inbounds double, ptr %7, i64 %162
  %171 = load double, ptr %169, align 8, !tbaa !9, !alias.scope !30, !noalias !32
  %172 = load double, ptr %170, align 8, !tbaa !9, !alias.scope !30, !noalias !32
  %173 = insertelement <2 x double> poison, double %171, i64 0
  %174 = insertelement <2 x double> %173, double %172, i64 1
  %175 = tail call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %broadcast.splat134, <2 x double> %168, <2 x double> %174)
  %176 = getelementptr inbounds i8, ptr %169, i64 -24
  %177 = shufflevector <2 x double> %129, <2 x double> %143, <4 x i32> <i32 0, i32 1, i32 2, i32 3>
  %178 = shufflevector <2 x double> %159, <2 x double> %175, <4 x i32> <i32 0, i32 1, i32 2, i32 3>
  %interleaved.vec = shufflevector <4 x double> %177, <4 x double> %178, <8 x i32> <i32 0, i32 2, i32 4, i32 6, i32 1, i32 3, i32 5, i32 7>
  store <8 x double> %interleaved.vec, ptr %176, align 8, !tbaa !9
  %index.next135 = add nuw i64 %index127, 2
  %179 = icmp eq i64 %index.next135, %n.vec123
  br i1 %179, label %middle.block118, label %vector.body126, !llvm.loop !33

middle.block118:                                  ; preds = %vector.body126
  %cmp.n136 = icmp eq i64 %104, %n.vec123
  br i1 %cmp.n136, label %.loopexit, label %.lr.ph81.preheader137

.lr.ph81.preheader137:                            ; preds = %middle.block118, %vector.memcheck104, %.lr.ph81.preheader
  %.280.ph138 = phi i64 [ %.280.ph, %vector.memcheck104 ], [ %.280.ph, %.lr.ph81.preheader ], [ %ind.end124, %middle.block118 ]
  br label %.lr.ph81

.lr.ph81:                                         ; preds = %.lr.ph81.preheader137, %.lr.ph81
  %.280 = phi i64 [ %206, %.lr.ph81 ], [ %.280.ph138, %.lr.ph81.preheader137 ]
  %180 = load double, ptr %1, align 8, !tbaa !9
  %181 = getelementptr inbounds double, ptr %8, i64 %.280
  %182 = load double, ptr %181, align 8, !tbaa !9
  %183 = getelementptr inbounds double, ptr %7, i64 %.280
  %184 = load double, ptr %183, align 8, !tbaa !9
  %185 = tail call double @llvm.fmuladd.f64(double %180, double %182, double %184)
  store double %185, ptr %183, align 8, !tbaa !9
  %186 = load double, ptr %1, align 8, !tbaa !9
  %187 = getelementptr double, ptr %2, i64 %.280
  %188 = load double, ptr %187, align 8, !tbaa !9
  %189 = getelementptr double, ptr %4, i64 %.280
  %190 = load double, ptr %189, align 8, !tbaa !9
  %191 = tail call double @llvm.fmuladd.f64(double %186, double %188, double %190)
  store double %191, ptr %189, align 8, !tbaa !9
  %192 = load double, ptr %1, align 8, !tbaa !9
  %193 = add nuw nsw i64 %.280, 2
  %194 = getelementptr inbounds double, ptr %8, i64 %193
  %195 = load double, ptr %194, align 8, !tbaa !9
  %196 = getelementptr inbounds double, ptr %7, i64 %193
  %197 = load double, ptr %196, align 8, !tbaa !9
  %198 = tail call double @llvm.fmuladd.f64(double %192, double %195, double %197)
  store double %198, ptr %196, align 8, !tbaa !9
  %199 = load double, ptr %1, align 8, !tbaa !9
  %200 = add nuw nsw i64 %.280, 3
  %201 = getelementptr inbounds double, ptr %8, i64 %200
  %202 = load double, ptr %201, align 8, !tbaa !9
  %203 = getelementptr inbounds double, ptr %7, i64 %200
  %204 = load double, ptr %203, align 8, !tbaa !9
  %205 = tail call double @llvm.fmuladd.f64(double %199, double %202, double %204)
  store double %205, ptr %203, align 8, !tbaa !9
  %206 = add nuw nsw i64 %.280, 4
  %.not72 = icmp sgt i64 %206, %9
  br i1 %.not72, label %.loopexit, label %.lr.ph81, !llvm.loop !34

.loopexit:                                        ; preds = %.lr.ph.prol.loopexit, %.lr.ph, %.lr.ph81, %middle.block, %middle.block118, %98, %11, %6
  ret i32 0
}

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

; 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>) #2

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

attributes #0 = { nofree norecurse nosync nounwind memory(argmem: readwrite) 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 speculatable willreturn memory(none) }
attributes #2 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }

!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 = !{!"long", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"double", !7, i64 0}
!11 = !{!12}
!12 = distinct !{!12, !13}
!13 = distinct !{!13, !"LVerDomain"}
!14 = !{!15}
!15 = distinct !{!15, !13}
!16 = !{!17}
!17 = distinct !{!17, !13}
!18 = !{!12, !15}
!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}
!24 = distinct !{!24, !20}
!25 = !{!26}
!26 = distinct !{!26, !27}
!27 = distinct !{!27, !"LVerDomain"}
!28 = !{!29}
!29 = distinct !{!29, !27}
!30 = !{!31}
!31 = distinct !{!31, !27}
!32 = !{!26, !29}
!33 = distinct !{!33, !20, !21, !22}
!34 = distinct !{!34, !20, !21}


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