; LLVM IR from aspuru-guzik-group/qtorch :: nlopt-2.4.2/stogo/linalg.ll (Z4gemvcdRK7RMatrixRK7RVectordS4_)

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

%class.RMatrix = type <{ ptr, i32, [4 x i8] }>
%class.RVector = type { i32, ptr }

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

; Function Attrs: mustprogress nounwind uwtable
define dso_local void @_Z4gemvcdRK7RMatrixRK7RVectordS4_(i8 noundef signext %0, double noundef %1, ptr noundef nonnull align 8 dereferenceable(12) %2, ptr noundef nonnull align 8 dereferenceable(16) %3, double noundef %4, ptr noundef nonnull align 8 dereferenceable(16) %5) #2 {
  %7 = alloca i8, align 1
  %8 = alloca double, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca double, align 8
  %12 = alloca ptr, align 8
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca double, align 8
  store i8 %0, ptr %7, align 1, !tbaa !5
  store double %1, ptr %8, align 8, !tbaa !8
  store ptr %2, ptr %9, align 8, !tbaa !10
  store ptr %3, ptr %10, align 8, !tbaa !10
  store double %4, ptr %11, align 8, !tbaa !8
  store ptr %5, ptr %12, align 8, !tbaa !10
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #3
  %17 = load ptr, ptr %9, align 8, !tbaa !10
  %18 = getelementptr inbounds %class.RMatrix, ptr %17, i32 0, i32 1
  %19 = load i32, ptr %18, align 8, !tbaa !12
  store i32 %19, ptr %15, align 4, !tbaa !15
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #3
  %20 = load i8, ptr %7, align 1, !tbaa !5
  %21 = sext i8 %20 to i32
  %22 = icmp eq i32 %21, 78
  br i1 %22, label %23, label %80

23:                                               ; preds = %6
  store i32 0, ptr %13, align 4, !tbaa !15
  br label %24

24:                                               ; preds = %76, %23
  %25 = load i32, ptr %13, align 4, !tbaa !15
  %26 = load i32, ptr %15, align 4, !tbaa !15
  %27 = icmp slt i32 %25, %26
  br i1 %27, label %28, label %79

28:                                               ; preds = %24
  store double 0.000000e+00, ptr %16, align 8, !tbaa !8
  store i32 0, ptr %14, align 4, !tbaa !15
  br label %29

29:                                               ; preds = %56, %28
  %30 = load i32, ptr %14, align 4, !tbaa !15
  %31 = load i32, ptr %15, align 4, !tbaa !15
  %32 = icmp slt i32 %30, %31
  br i1 %32, label %33, label %59

33:                                               ; preds = %29
  %34 = load ptr, ptr %9, align 8, !tbaa !10
  %35 = getelementptr inbounds %class.RMatrix, ptr %34, i32 0, i32 0
  %36 = load ptr, ptr %35, align 8, !tbaa !16
  %37 = load i32, ptr %14, align 4, !tbaa !15
  %38 = load i32, ptr %13, align 4, !tbaa !15
  %39 = load i32, ptr %15, align 4, !tbaa !15
  %40 = mul nsw i32 %38, %39
  %41 = add nsw i32 %37, %40
  %42 = sext i32 %41 to i64
  %43 = getelementptr inbounds double, ptr %36, i64 %42
  %44 = load double, ptr %43, align 8, !tbaa !8
  %45 = load ptr, ptr %10, align 8, !tbaa !10
  %46 = getelementptr inbounds %class.RVector, ptr %45, i32 0, i32 1
  %47 = load ptr, ptr %46, align 8, !tbaa !17
  %48 = load i32, ptr %14, align 4, !tbaa !15
  %49 = sext i32 %48 to i64
  %50 = getelementptr inbounds double, ptr %47, i64 %49
  %51 = load double, ptr %50, align 8, !tbaa !8
  %52 = fmul double %44, %51
  %53 = load double, ptr %8, align 8, !tbaa !8
  %54 = load double, ptr %16, align 8, !tbaa !8
  %55 = call double @llvm.fmuladd.f64(double %52, double %53, double %54)
  store double %55, ptr %16, align 8, !tbaa !8
  br label %56

56:                                               ; preds = %33
  %57 = load i32, ptr %14, align 4, !tbaa !15
  %58 = add nsw i32 %57, 1
  store i32 %58, ptr %14, align 4, !tbaa !15
  br label %29, !llvm.loop !19

59:                                               ; preds = %29
  %60 = load ptr, ptr %12, align 8, !tbaa !10
  %61 = getelementptr inbounds %class.RVector, ptr %60, i32 0, i32 1
  %62 = load ptr, ptr %61, align 8, !tbaa !17
  %63 = load i32, ptr %13, align 4, !tbaa !15
  %64 = sext i32 %63 to i64
  %65 = getelementptr inbounds double, ptr %62, i64 %64
  %66 = load double, ptr %65, align 8, !tbaa !8
  %67 = load double, ptr %11, align 8, !tbaa !8
  %68 = load double, ptr %16, align 8, !tbaa !8
  %69 = call double @llvm.fmuladd.f64(double %66, double %67, double %68)
  %70 = load ptr, ptr %12, align 8, !tbaa !10
  %71 = getelementptr inbounds %class.RVector, ptr %70, i32 0, i32 1
  %72 = load ptr, ptr %71, align 8, !tbaa !17
  %73 = load i32, ptr %13, align 4, !tbaa !15
  %74 = sext i32 %73 to i64
  %75 = getelementptr inbounds double, ptr %72, i64 %74
  store double %69, ptr %75, align 8, !tbaa !8
  br label %76

76:                                               ; preds = %59
  %77 = load i32, ptr %13, align 4, !tbaa !15
  %78 = add nsw i32 %77, 1
  store i32 %78, ptr %13, align 4, !tbaa !15
  br label %24, !llvm.loop !21

79:                                               ; preds = %24
  br label %137

80:                                               ; preds = %6
  store i32 0, ptr %13, align 4, !tbaa !15
  br label %81

81:                                               ; preds = %133, %80
  %82 = load i32, ptr %13, align 4, !tbaa !15
  %83 = load i32, ptr %15, align 4, !tbaa !15
  %84 = icmp slt i32 %82, %83
  br i1 %84, label %85, label %136

85:                                               ; preds = %81
  store double 0.000000e+00, ptr %16, align 8, !tbaa !8
  store i32 0, ptr %14, align 4, !tbaa !15
  br label %86

86:                                               ; preds = %113, %85
  %87 = load i32, ptr %14, align 4, !tbaa !15
  %88 = load i32, ptr %15, align 4, !tbaa !15
  %89 = icmp slt i32 %87, %88
  br i1 %89, label %90, label %116

90:                                               ; preds = %86
  %91 = load ptr, ptr %9, align 8, !tbaa !10
  %92 = getelementptr inbounds %class.RMatrix, ptr %91, i32 0, i32 0
  %93 = load ptr, ptr %92, align 8, !tbaa !16
  %94 = load i32, ptr %13, align 4, !tbaa !15
  %95 = load i32, ptr %14, align 4, !tbaa !15
  %96 = load i32, ptr %15, align 4, !tbaa !15
  %97 = mul nsw i32 %95, %96
  %98 = add nsw i32 %94, %97
  %99 = sext i32 %98 to i64
  %100 = getelementptr inbounds double, ptr %93, i64 %99
  %101 = load double, ptr %100, align 8, !tbaa !8
  %102 = load ptr, ptr %10, align 8, !tbaa !10
  %103 = getelementptr inbounds %class.RVector, ptr %102, i32 0, i32 1
  %104 = load ptr, ptr %103, align 8, !tbaa !17
  %105 = load i32, ptr %14, align 4, !tbaa !15
  %106 = sext i32 %105 to i64
  %107 = getelementptr inbounds double, ptr %104, i64 %106
  %108 = load double, ptr %107, align 8, !tbaa !8
  %109 = fmul double %101, %108
  %110 = load double, ptr %8, align 8, !tbaa !8
  %111 = load double, ptr %16, align 8, !tbaa !8
  %112 = call double @llvm.fmuladd.f64(double %109, double %110, double %111)
  store double %112, ptr %16, align 8, !tbaa !8
  br label %113

113:                                              ; preds = %90
  %114 = load i32, ptr %14, align 4, !tbaa !15
  %115 = add nsw i32 %114, 1
  store i32 %115, ptr %14, align 4, !tbaa !15
  br label %86, !llvm.loop !22

116:                                              ; preds = %86
  %117 = load ptr, ptr %12, align 8, !tbaa !10
  %118 = getelementptr inbounds %class.RVector, ptr %117, i32 0, i32 1
  %119 = load ptr, ptr %118, align 8, !tbaa !17
  %120 = load i32, ptr %13, align 4, !tbaa !15
  %121 = sext i32 %120 to i64
  %122 = getelementptr inbounds double, ptr %119, i64 %121
  %123 = load double, ptr %122, align 8, !tbaa !8
  %124 = load double, ptr %11, align 8, !tbaa !8
  %125 = load double, ptr %16, align 8, !tbaa !8
  %126 = call double @llvm.fmuladd.f64(double %123, double %124, double %125)
  %127 = load ptr, ptr %12, align 8, !tbaa !10
  %128 = getelementptr inbounds %class.RVector, ptr %127, i32 0, i32 1
  %129 = load ptr, ptr %128, align 8, !tbaa !17
  %130 = load i32, ptr %13, align 4, !tbaa !15
  %131 = sext i32 %130 to i64
  %132 = getelementptr inbounds double, ptr %129, i64 %131
  store double %126, ptr %132, align 8, !tbaa !8
  br label %133

133:                                              ; preds = %116
  %134 = load i32, ptr %13, align 4, !tbaa !15
  %135 = add nsw i32 %134, 1
  store i32 %135, ptr %13, align 4, !tbaa !15
  br label %81, !llvm.loop !23

136:                                              ; preds = %81
  br label %137

137:                                              ; preds = %136, %79
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #3
  ret void
}

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #2 = { mustprogress 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 #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 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !9, i64 0}
!9 = !{!"double", !6, i64 0}
!10 = !{!11, !11, i64 0}
!11 = !{!"any pointer", !6, i64 0}
!12 = !{!13, !14, i64 8}
!13 = !{!"_ZTS7RMatrix", !11, i64 0, !14, i64 8}
!14 = !{!"int", !6, i64 0}
!15 = !{!14, !14, i64 0}
!16 = !{!13, !11, i64 0}
!17 = !{!18, !11, i64 8}
!18 = !{!"_ZTS7RVector", !14, i64 0, !11, i64 8}
!19 = distinct !{!19, !20}
!20 = !{!"llvm.loop.mustprogress"}
!21 = distinct !{!21, !20}
!22 = distinct !{!22, !20}
!23 = distinct !{!23, !20}


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

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

; Function Attrs: mustprogress nofree norecurse nosync nounwind memory(readwrite, inaccessiblemem: none) uwtable
define dso_local void @_Z4gemvcdRK7RMatrixRK7RVectordS4_(i8 noundef signext %0, double noundef %1, ptr nocapture noundef nonnull readonly align 8 dereferenceable(12) %2, ptr nocapture noundef nonnull readonly align 8 dereferenceable(16) %3, double noundef %4, ptr nocapture noundef nonnull readonly align 8 dereferenceable(16) %5) local_unnamed_addr #1 {
  %7 = getelementptr inbounds i8, ptr %2, i64 8
  %8 = load i32, ptr %7, align 8, !tbaa !5
  %9 = icmp eq i8 %0, 78
  %10 = icmp sgt i32 %8, 0
  br i1 %9, label %.preheader46, label %.preheader48

.preheader48:                                     ; preds = %6
  br i1 %10, label %.preheader47.lr.ph, label %.loopexit

.preheader47.lr.ph:                               ; preds = %.preheader48
  %11 = load ptr, ptr %2, align 8
  %12 = getelementptr inbounds i8, ptr %3, i64 8
  %13 = load ptr, ptr %12, align 8
  %14 = getelementptr inbounds i8, ptr %5, i64 8
  %15 = load ptr, ptr %14, align 8, !tbaa !11
  %16 = zext nneg i32 %8 to i64
  %xtraiter = and i64 %16, 1
  %17 = icmp eq i32 %8, 1
  %unroll_iter = and i64 %16, 2147483646
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br label %.preheader47.us

.preheader47.us:                                  ; preds = %._crit_edge.us, %.preheader47.lr.ph
  %indvars.iv61 = phi i64 [ %indvars.iv.next62, %._crit_edge.us ], [ 0, %.preheader47.lr.ph ]
  %invariant.gep = getelementptr inbounds double, ptr %11, i64 %indvars.iv61
  br i1 %17, label %._crit_edge.us.unr-lcssa, label %.preheader47.us.new

.preheader47.us.new:                              ; preds = %.preheader47.us, %.preheader47.us.new
  %indvars.iv = phi i64 [ %indvars.iv.next.1, %.preheader47.us.new ], [ 0, %.preheader47.us ]
  %.151.us = phi double [ %29, %.preheader47.us.new ], [ 0.000000e+00, %.preheader47.us ]
  %niter = phi i64 [ %niter.next.1, %.preheader47.us.new ], [ 0, %.preheader47.us ]
  %18 = mul nuw nsw i64 %indvars.iv, %16
  %gep = getelementptr inbounds double, ptr %invariant.gep, i64 %18
  %19 = load double, ptr %gep, align 8, !tbaa !13
  %20 = getelementptr inbounds double, ptr %13, i64 %indvars.iv
  %21 = load double, ptr %20, align 8, !tbaa !13
  %22 = fmul double %19, %21
  %23 = tail call double @llvm.fmuladd.f64(double %22, double %1, double %.151.us)
  %indvars.iv.next = or disjoint i64 %indvars.iv, 1
  %24 = mul nuw nsw i64 %indvars.iv.next, %16
  %gep.1 = getelementptr inbounds double, ptr %invariant.gep, i64 %24
  %25 = load double, ptr %gep.1, align 8, !tbaa !13
  %26 = getelementptr inbounds double, ptr %13, i64 %indvars.iv.next
  %27 = load double, ptr %26, align 8, !tbaa !13
  %28 = fmul double %25, %27
  %29 = tail call double @llvm.fmuladd.f64(double %28, double %1, double %23)
  %indvars.iv.next.1 = add nuw nsw i64 %indvars.iv, 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 %._crit_edge.us.unr-lcssa, label %.preheader47.us.new, !llvm.loop !15

._crit_edge.us.unr-lcssa:                         ; preds = %.preheader47.us.new, %.preheader47.us
  %.lcssa83.ph = phi double [ poison, %.preheader47.us ], [ %29, %.preheader47.us.new ]
  %indvars.iv.unr = phi i64 [ 0, %.preheader47.us ], [ %indvars.iv.next.1, %.preheader47.us.new ]
  %.151.us.unr = phi double [ 0.000000e+00, %.preheader47.us ], [ %29, %.preheader47.us.new ]
  br i1 %lcmp.mod.not, label %._crit_edge.us, label %._crit_edge.us.epilog-lcssa

._crit_edge.us.epilog-lcssa:                      ; preds = %._crit_edge.us.unr-lcssa
  %30 = mul nuw nsw i64 %indvars.iv.unr, %16
  %gep.epil = getelementptr inbounds double, ptr %invariant.gep, i64 %30
  %31 = load double, ptr %gep.epil, align 8, !tbaa !13
  %32 = getelementptr inbounds double, ptr %13, i64 %indvars.iv.unr
  %33 = load double, ptr %32, align 8, !tbaa !13
  %34 = fmul double %31, %33
  %35 = tail call double @llvm.fmuladd.f64(double %34, double %1, double %.151.us.unr)
  br label %._crit_edge.us

._crit_edge.us:                                   ; preds = %._crit_edge.us.unr-lcssa, %._crit_edge.us.epilog-lcssa
  %.lcssa83 = phi double [ %.lcssa83.ph, %._crit_edge.us.unr-lcssa ], [ %35, %._crit_edge.us.epilog-lcssa ]
  %36 = getelementptr inbounds double, ptr %15, i64 %indvars.iv61
  %37 = load double, ptr %36, align 8, !tbaa !13
  %38 = tail call double @llvm.fmuladd.f64(double %37, double %4, double %.lcssa83)
  store double %38, ptr %36, align 8, !tbaa !13
  %indvars.iv.next62 = add nuw nsw i64 %indvars.iv61, 1
  %exitcond65.not = icmp eq i64 %indvars.iv.next62, %16
  br i1 %exitcond65.not, label %.loopexit, label %.preheader47.us, !llvm.loop !17

.preheader46:                                     ; preds = %6
  br i1 %10, label %.preheader.lr.ph, label %.loopexit

.preheader.lr.ph:                                 ; preds = %.preheader46
  %39 = load ptr, ptr %2, align 8
  %40 = getelementptr inbounds i8, ptr %3, i64 8
  %41 = load ptr, ptr %40, align 8
  %42 = getelementptr inbounds i8, ptr %5, i64 8
  %43 = load ptr, ptr %42, align 8, !tbaa !11
  %44 = zext nneg i32 %8 to i64
  %xtraiter86 = and i64 %44, 3
  %45 = icmp ult i32 %8, 4
  %unroll_iter89 = and i64 %44, 2147483644
  %lcmp.mod87.not = icmp eq i64 %xtraiter86, 0
  br label %.preheader.us

.preheader.us:                                    ; preds = %._crit_edge.us56, %.preheader.lr.ph
  %indvars.iv71 = phi i64 [ %indvars.iv.next72, %._crit_edge.us56 ], [ 0, %.preheader.lr.ph ]
  %46 = mul nuw nsw i64 %indvars.iv71, %44
  %invariant.gep78 = getelementptr inbounds double, ptr %39, i64 %46
  br i1 %45, label %._crit_edge.us56.unr-lcssa, label %.preheader.us.new

.preheader.us.new:                                ; preds = %.preheader.us, %.preheader.us.new
  %indvars.iv66 = phi i64 [ %indvars.iv.next67.3, %.preheader.us.new ], [ 0, %.preheader.us ]
  %.054.us = phi double [ %66, %.preheader.us.new ], [ 0.000000e+00, %.preheader.us ]
  %niter90 = phi i64 [ %niter90.next.3, %.preheader.us.new ], [ 0, %.preheader.us ]
  %gep79 = getelementptr inbounds double, ptr %invariant.gep78, i64 %indvars.iv66
  %47 = load double, ptr %gep79, align 8, !tbaa !13
  %48 = getelementptr inbounds double, ptr %41, i64 %indvars.iv66
  %49 = load double, ptr %48, align 8, !tbaa !13
  %50 = fmul double %47, %49
  %51 = tail call double @llvm.fmuladd.f64(double %50, double %1, double %.054.us)
  %indvars.iv.next67 = or disjoint i64 %indvars.iv66, 1
  %gep79.1 = getelementptr inbounds double, ptr %invariant.gep78, i64 %indvars.iv.next67
  %52 = load double, ptr %gep79.1, align 8, !tbaa !13
  %53 = getelementptr inbounds double, ptr %41, i64 %indvars.iv.next67
  %54 = load double, ptr %53, align 8, !tbaa !13
  %55 = fmul double %52, %54
  %56 = tail call double @llvm.fmuladd.f64(double %55, double %1, double %51)
  %indvars.iv.next67.1 = or disjoint i64 %indvars.iv66, 2
  %gep79.2 = getelementptr inbounds double, ptr %invariant.gep78, i64 %indvars.iv.next67.1
  %57 = load double, ptr %gep79.2, align 8, !tbaa !13
  %58 = getelementptr inbounds double, ptr %41, i64 %indvars.iv.next67.1
  %59 = load double, ptr %58, align 8, !tbaa !13
  %60 = fmul double %57, %59
  %61 = tail call double @llvm.fmuladd.f64(double %60, double %1, double %56)
  %indvars.iv.next67.2 = or disjoint i64 %indvars.iv66, 3
  %gep79.3 = getelementptr inbounds double, ptr %invariant.gep78, i64 %indvars.iv.next67.2
  %62 = load double, ptr %gep79.3, align 8, !tbaa !13
  %63 = getelementptr inbounds double, ptr %41, i64 %indvars.iv.next67.2
  %64 = load double, ptr %63, align 8, !tbaa !13
  %65 = fmul double %62, %64
  %66 = tail call double @llvm.fmuladd.f64(double %65, double %1, double %61)
  %indvars.iv.next67.3 = add nuw nsw i64 %indvars.iv66, 4
  %niter90.next.3 = add i64 %niter90, 4
  %niter90.ncmp.3 = icmp eq i64 %niter90.next.3, %unroll_iter89
  br i1 %niter90.ncmp.3, label %._crit_edge.us56.unr-lcssa, label %.preheader.us.new, !llvm.loop !18

._crit_edge.us56.unr-lcssa:                       ; preds = %.preheader.us.new, %.preheader.us
  %.lcssa.ph = phi double [ poison, %.preheader.us ], [ %66, %.preheader.us.new ]
  %indvars.iv66.unr = phi i64 [ 0, %.preheader.us ], [ %indvars.iv.next67.3, %.preheader.us.new ]
  %.054.us.unr = phi double [ 0.000000e+00, %.preheader.us ], [ %66, %.preheader.us.new ]
  br i1 %lcmp.mod87.not, label %._crit_edge.us56, label %.epil.preheader85

.epil.preheader85:                                ; preds = %._crit_edge.us56.unr-lcssa, %.epil.preheader85
  %indvars.iv66.epil = phi i64 [ %indvars.iv.next67.epil, %.epil.preheader85 ], [ %indvars.iv66.unr, %._crit_edge.us56.unr-lcssa ]
  %.054.us.epil = phi double [ %71, %.epil.preheader85 ], [ %.054.us.unr, %._crit_edge.us56.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.epil.preheader85 ], [ 0, %._crit_edge.us56.unr-lcssa ]
  %gep79.epil = getelementptr inbounds double, ptr %invariant.gep78, i64 %indvars.iv66.epil
  %67 = load double, ptr %gep79.epil, align 8, !tbaa !13
  %68 = getelementptr inbounds double, ptr %41, i64 %indvars.iv66.epil
  %69 = load double, ptr %68, align 8, !tbaa !13
  %70 = fmul double %67, %69
  %71 = tail call double @llvm.fmuladd.f64(double %70, double %1, double %.054.us.epil)
  %indvars.iv.next67.epil = add nuw nsw i64 %indvars.iv66.epil, 1
  %epil.iter.next = add i64 %epil.iter, 1
  %epil.iter.cmp.not = icmp eq i64 %epil.iter.next, %xtraiter86
  br i1 %epil.iter.cmp.not, label %._crit_edge.us56, label %.epil.preheader85, !llvm.loop !19

._crit_edge.us56:                                 ; preds = %.epil.preheader85, %._crit_edge.us56.unr-lcssa
  %.lcssa = phi double [ %.lcssa.ph, %._crit_edge.us56.unr-lcssa ], [ %71, %.epil.preheader85 ]
  %72 = getelementptr inbounds double, ptr %43, i64 %indvars.iv71
  %73 = load double, ptr %72, align 8, !tbaa !13
  %74 = tail call double @llvm.fmuladd.f64(double %73, double %4, double %.lcssa)
  store double %74, ptr %72, align 8, !tbaa !13
  %indvars.iv.next72 = add nuw nsw i64 %indvars.iv71, 1
  %exitcond75.not = icmp eq i64 %indvars.iv.next72, %44
  br i1 %exitcond75.not, label %.loopexit, label %.preheader.us, !llvm.loop !21

.loopexit:                                        ; preds = %._crit_edge.us, %._crit_edge.us56, %.preheader48, %.preheader46
  ret void
}

attributes #0 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #1 = { mustprogress nofree norecurse nosync nounwind memory(readwrite, inaccessiblemem: none) 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" }

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

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


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