; LLVM IR from ox-vgg/vise :: src/search_engine/relja_retrival/external/KMCode_relja/stats (stats)

; 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.GaussMixture = type { ptr, ptr, ptr, ptr, ptr, i32, i32, i32, i32, i32, i32, i32, i32, float, float, float, i32 }
%class.Matrix = type { ptr, ptr, i32, i32 }

; 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 { i64, i1 } @llvm.umul.with.overflow.i64(i64, i64) #1

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znam(i64 noundef) #2

; Function Attrs: mustprogress uwtable
define dso_local noundef float @_ZN12GaussMixture9distMahalEPfi(ptr noundef nonnull align 8 dereferenceable(88) %0, ptr noundef %1, i32 noundef %2) #3 align 2 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca float, align 4
  %14 = alloca i32, align 4
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  store i32 %2, ptr %6, align 4, !tbaa !9
  %15 = load ptr, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #5
  %16 = getelementptr inbounds %class.GaussMixture, ptr %15, i32 0, i32 9
  %17 = load i32, ptr %16, align 8, !tbaa !11
  %18 = add nsw i32 %17, 1
  %19 = sext i32 %18 to i64
  %20 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %19, i64 4)
  %21 = extractvalue { i64, i1 } %20, 1
  %22 = extractvalue { i64, i1 } %20, 0
  %23 = select i1 %21, i64 -1, i64 %22
  %24 = call noalias noundef nonnull ptr @_Znam(i64 noundef %23) #6
  store ptr %24, ptr %7, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #5
  %25 = getelementptr inbounds %class.GaussMixture, ptr %15, i32 0, i32 9
  %26 = load i32, ptr %25, align 8, !tbaa !11
  %27 = add nsw i32 %26, 1
  %28 = sext i32 %27 to i64
  %29 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %28, i64 4)
  %30 = extractvalue { i64, i1 } %29, 1
  %31 = extractvalue { i64, i1 } %29, 0
  %32 = select i1 %30, i64 -1, i64 %31
  %33 = call noalias noundef nonnull ptr @_Znam(i64 noundef %32) #6
  store ptr %33, ptr %8, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #5
  store i32 0, ptr %9, align 4, !tbaa !9
  br label %34

34:                                               ; preds = %62, %3
  %35 = load i32, ptr %9, align 4, !tbaa !9
  %36 = getelementptr inbounds %class.GaussMixture, ptr %15, i32 0, i32 9
  %37 = load i32, ptr %36, align 8, !tbaa !11
  %38 = icmp slt i32 %35, %37
  br i1 %38, label %40, label %39

39:                                               ; preds = %34
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #5
  br label %65

40:                                               ; preds = %34
  %41 = load ptr, ptr %5, align 8, !tbaa !5
  %42 = load i32, ptr %9, align 4, !tbaa !9
  %43 = sext i32 %42 to i64
  %44 = getelementptr inbounds float, ptr %41, i64 %43
  %45 = load float, ptr %44, align 4, !tbaa !14
  %46 = getelementptr inbounds %class.GaussMixture, ptr %15, i32 0, i32 3
  %47 = load ptr, ptr %46, align 8, !tbaa !15
  %48 = load i32, ptr %6, align 4, !tbaa !9
  %49 = sext i32 %48 to i64
  %50 = getelementptr inbounds ptr, ptr %47, i64 %49
  %51 = load ptr, ptr %50, align 8, !tbaa !5
  %52 = load i32, ptr %9, align 4, !tbaa !9
  %53 = sext i32 %52 to i64
  %54 = getelementptr inbounds float, ptr %51, i64 %53
  %55 = load float, ptr %54, align 4, !tbaa !14
  %56 = fsub float %45, %55
  %57 = load ptr, ptr %7, align 8, !tbaa !5
  %58 = load i32, ptr %9, align 4, !tbaa !9
  %59 = add nsw i32 %58, 1
  %60 = sext i32 %59 to i64
  %61 = getelementptr inbounds float, ptr %57, i64 %60
  store float %56, ptr %61, align 4, !tbaa !14
  br label %62

62:                                               ; preds = %40
  %63 = load i32, ptr %9, align 4, !tbaa !9
  %64 = add nsw i32 %63, 1
  store i32 %64, ptr %9, align 4, !tbaa !9
  br label %34, !llvm.loop !16

65:                                               ; preds = %39
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #5
  store i32 1, ptr %10, align 4, !tbaa !9
  br label %66

66:                                               ; preds = %118, %65
  %67 = load i32, ptr %10, align 4, !tbaa !9
  %68 = getelementptr inbounds %class.GaussMixture, ptr %15, i32 0, i32 9
  %69 = load i32, ptr %68, align 8, !tbaa !11
  %70 = icmp sle i32 %67, %69
  br i1 %70, label %72, label %71

71:                                               ; preds = %66
  store i32 5, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  br label %121

72:                                               ; preds = %66
  %73 = load ptr, ptr %8, align 8, !tbaa !5
  %74 = load i32, ptr %10, align 4, !tbaa !9
  %75 = sext i32 %74 to i64
  %76 = getelementptr inbounds float, ptr %73, i64 %75
  store float 0.000000e+00, ptr %76, align 4, !tbaa !14
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #5
  store i32 1, ptr %12, align 4, !tbaa !9
  br label %77

77:                                               ; preds = %114, %72
  %78 = load i32, ptr %12, align 4, !tbaa !9
  %79 = getelementptr inbounds %class.GaussMixture, ptr %15, i32 0, i32 9
  %80 = load i32, ptr %79, align 8, !tbaa !11
  %81 = icmp sle i32 %78, %80
  br i1 %81, label %83, label %82

82:                                               ; preds = %77
  store i32 8, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  br label %117

83:                                               ; preds = %77
  %84 = getelementptr inbounds %class.GaussMixture, ptr %15, i32 0, i32 1
  %85 = load ptr, ptr %84, align 8, !tbaa !18
  %86 = load i32, ptr %6, align 4, !tbaa !9
  %87 = sext i32 %86 to i64
  %88 = getelementptr inbounds ptr, ptr %85, i64 %87
  %89 = load ptr, ptr %88, align 8, !tbaa !5
  %90 = getelementptr inbounds %class.Matrix, ptr %89, i32 0, i32 1
  %91 = load ptr, ptr %90, align 8, !tbaa !19
  %92 = load i32, ptr %10, align 4, !tbaa !9
  %93 = sext i32 %92 to i64
  %94 = getelementptr inbounds ptr, ptr %91, i64 %93
  %95 = load ptr, ptr %94, align 8, !tbaa !5
  %96 = load i32, ptr %12, align 4, !tbaa !9
  %97 = sext i32 %96 to i64
  %98 = getelementptr inbounds double, ptr %95, i64 %97
  %99 = load double, ptr %98, align 8, !tbaa !21
  %100 = load ptr, ptr %7, align 8, !tbaa !5
  %101 = load i32, ptr %12, align 4, !tbaa !9
  %102 = sext i32 %101 to i64
  %103 = getelementptr inbounds float, ptr %100, i64 %102
  %104 = load float, ptr %103, align 4, !tbaa !14
  %105 = fpext float %104 to double
  %106 = load ptr, ptr %8, align 8, !tbaa !5
  %107 = load i32, ptr %10, align 4, !tbaa !9
  %108 = sext i32 %107 to i64
  %109 = getelementptr inbounds float, ptr %106, i64 %108
  %110 = load float, ptr %109, align 4, !tbaa !14
  %111 = fpext float %110 to double
  %112 = call double @llvm.fmuladd.f64(double %99, double %105, double %111)
  %113 = fptrunc double %112 to float
  store float %113, ptr %109, align 4, !tbaa !14
  br label %114

114:                                              ; preds = %83
  %115 = load i32, ptr %12, align 4, !tbaa !9
  %116 = add nsw i32 %115, 1
  store i32 %116, ptr %12, align 4, !tbaa !9
  br label %77, !llvm.loop !23

117:                                              ; preds = %82
  br label %118

118:                                              ; preds = %117
  %119 = load i32, ptr %10, align 4, !tbaa !9
  %120 = add nsw i32 %119, 1
  store i32 %120, ptr %10, align 4, !tbaa !9
  br label %66, !llvm.loop !24

121:                                              ; preds = %71
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #5
  store float 0.000000e+00, ptr %13, align 4, !tbaa !14
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #5
  store i32 1, ptr %14, align 4, !tbaa !9
  br label %122

122:                                              ; preds = %141, %121
  %123 = load i32, ptr %14, align 4, !tbaa !9
  %124 = getelementptr inbounds %class.GaussMixture, ptr %15, i32 0, i32 9
  %125 = load i32, ptr %124, align 8, !tbaa !11
  %126 = icmp sle i32 %123, %125
  br i1 %126, label %128, label %127

127:                                              ; preds = %122
  store i32 11, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  br label %144

128:                                              ; preds = %122
  %129 = load ptr, ptr %7, align 8, !tbaa !5
  %130 = load i32, ptr %14, align 4, !tbaa !9
  %131 = sext i32 %130 to i64
  %132 = getelementptr inbounds float, ptr %129, i64 %131
  %133 = load float, ptr %132, align 4, !tbaa !14
  %134 = load ptr, ptr %8, align 8, !tbaa !5
  %135 = load i32, ptr %14, align 4, !tbaa !9
  %136 = sext i32 %135 to i64
  %137 = getelementptr inbounds float, ptr %134, i64 %136
  %138 = load float, ptr %137, align 4, !tbaa !14
  %139 = load float, ptr %13, align 4, !tbaa !14
  %140 = call float @llvm.fmuladd.f32(float %133, float %138, float %139)
  store float %140, ptr %13, align 4, !tbaa !14
  br label %141

141:                                              ; preds = %128
  %142 = load i32, ptr %14, align 4, !tbaa !9
  %143 = add nsw i32 %142, 1
  store i32 %143, ptr %14, align 4, !tbaa !9
  br label %122, !llvm.loop !25

144:                                              ; preds = %127
  %145 = load ptr, ptr %7, align 8, !tbaa !5
  %146 = icmp eq ptr %145, null
  br i1 %146, label %148, label %147

147:                                              ; preds = %144
  call void @_ZdaPv(ptr noundef %145) #7
  br label %148

148:                                              ; preds = %147, %144
  %149 = load ptr, ptr %8, align 8, !tbaa !5
  %150 = icmp eq ptr %149, null
  br i1 %150, label %152, label %151

151:                                              ; preds = %148
  call void @_ZdaPv(ptr noundef %149) #7
  br label %152

152:                                              ; preds = %151, %148
  %153 = load float, ptr %13, align 4, !tbaa !14
  store i32 1, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  ret float %153
}

; Function Attrs: 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 float @llvm.fmuladd.f32(float, float, float) #1

; Function Attrs: nobuiltin nounwind
declare void @_ZdaPv(ptr noundef) #4

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #2 = { nobuiltin allocsize(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 = { mustprogress 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 = { nobuiltin nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { nounwind }
attributes #6 = { builtin allocsize(0) }
attributes #7 = { builtin 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++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!12, !10, i64 56}
!12 = !{!"_ZTS12GaussMixture", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !10, i64 40, !10, i64 44, !10, i64 48, !10, i64 52, !10, i64 56, !10, i64 60, !10, i64 64, !10, i64 68, !13, i64 72, !13, i64 76, !13, i64 80, !10, i64 84}
!13 = !{!"float", !7, i64 0}
!14 = !{!13, !13, i64 0}
!15 = !{!12, !6, i64 24}
!16 = distinct !{!16, !17}
!17 = !{!"llvm.loop.mustprogress"}
!18 = !{!12, !6, i64 8}
!19 = !{!20, !6, i64 8}
!20 = !{!"_ZTS6Matrix", !6, i64 8, !10, i64 16, !10, i64 20}
!21 = !{!22, !22, i64 0}
!22 = !{!"double", !7, i64 0}
!23 = distinct !{!23, !17}
!24 = distinct !{!24, !17}
!25 = distinct !{!25, !17}


; 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: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znam(i64 noundef) local_unnamed_addr #0

; Function Attrs: mustprogress uwtable
define dso_local noundef float @_ZN12GaussMixture9distMahalEPfi(ptr nocapture noundef nonnull readonly align 8 dereferenceable(88) %0, ptr nocapture noundef readonly %1, i32 noundef %2) local_unnamed_addr #1 align 2 {
  %4 = ptrtoint ptr %1 to i64
  %5 = getelementptr inbounds i8, ptr %0, i64 56
  %6 = load i32, ptr %5, align 8, !tbaa !5
  %7 = add i32 %6, 1
  %8 = sext i32 %7 to i64
  %9 = icmp slt i32 %6, -1
  %10 = shl nsw i64 %8, 2
  %11 = select i1 %9, i64 -1, i64 %10
  %12 = tail call noalias noundef nonnull ptr @_Znam(i64 noundef %11) #4
  %13 = ptrtoint ptr %12 to i64
  %14 = tail call noalias noundef nonnull ptr @_Znam(i64 noundef %11) #4
  %15 = icmp sgt i32 %6, 0
  br i1 %15, label %.lr.ph, label %._crit_edge49

.lr.ph:                                           ; preds = %3
  %16 = getelementptr inbounds i8, ptr %0, i64 24
  %17 = load ptr, ptr %16, align 8, !tbaa !12
  %18 = sext i32 %2 to i64
  %19 = getelementptr inbounds ptr, ptr %17, i64 %18
  %20 = load ptr, ptr %19, align 8, !tbaa !13
  %wide.trip.count = zext nneg i32 %6 to i64
  %min.iters.check = icmp ult i32 %6, 12
  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, 3
  %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, %scalar.ph.prol
  %indvars.iv.prol = phi i64 [ %indvars.iv.next.prol, %scalar.ph.prol ], [ %indvars.iv.ph, %scalar.ph.preheader ]
  %prol.iter = phi i64 [ %prol.iter.next, %scalar.ph.prol ], [ 0, %scalar.ph.preheader ]
  %21 = getelementptr inbounds float, ptr %1, i64 %indvars.iv.prol
  %22 = load float, ptr %21, align 4, !tbaa !14
  %23 = getelementptr inbounds float, ptr %20, i64 %indvars.iv.prol
  %24 = load float, ptr %23, align 4, !tbaa !14
  %25 = fsub float %22, %24
  %indvars.iv.next.prol = add nuw nsw i64 %indvars.iv.prol, 1
  %26 = getelementptr inbounds float, ptr %12, i64 %indvars.iv.next.prol
  store float %25, ptr %26, align 4, !tbaa !14
  %prol.iter.next = add i64 %prol.iter, 1
  %prol.iter.cmp.not = icmp eq i64 %prol.iter.next, %xtraiter
  br i1 %prol.iter.cmp.not, label %scalar.ph.prol.loopexit, label %scalar.ph.prol, !llvm.loop !15

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 ]
  %27 = sub nsw i64 %indvars.iv.ph, %wide.trip.count
  %28 = icmp ugt i64 %27, -4
  br i1 %28, label %.lr.ph44, label %scalar.ph

vector.memcheck:                                  ; preds = %.lr.ph
  %29 = ptrtoint ptr %20 to i64
  %30 = add i64 %13, 4
  %31 = sub i64 %30, %4
  %diff.check = icmp ult i64 %31, 32
  %32 = sub i64 %30, %29
  %diff.check72 = icmp ult i64 %32, 32
  %conflict.rdx = or i1 %diff.check, %diff.check72
  br i1 %conflict.rdx, label %scalar.ph.preheader, label %vector.ph

vector.ph:                                        ; preds = %vector.memcheck
  %n.vec = and i64 %wide.trip.count, 2147483640
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %33 = getelementptr inbounds float, ptr %1, i64 %index
  %34 = getelementptr inbounds i8, ptr %33, i64 16
  %wide.load = load <4 x float>, ptr %33, align 4, !tbaa !14
  %wide.load73 = load <4 x float>, ptr %34, align 4, !tbaa !14
  %35 = getelementptr inbounds float, ptr %20, i64 %index
  %36 = getelementptr inbounds i8, ptr %35, i64 16
  %wide.load74 = load <4 x float>, ptr %35, align 4, !tbaa !14
  %wide.load75 = load <4 x float>, ptr %36, align 4, !tbaa !14
  %37 = fsub <4 x float> %wide.load, %wide.load74
  %38 = fsub <4 x float> %wide.load73, %wide.load75
  %39 = or disjoint i64 %index, 1
  %40 = getelementptr inbounds float, ptr %12, i64 %39
  %41 = getelementptr inbounds i8, ptr %40, i64 16
  store <4 x float> %37, ptr %40, align 4, !tbaa !14
  store <4 x float> %38, ptr %41, align 4, !tbaa !14
  %index.next = add nuw i64 %index, 8
  %42 = icmp eq i64 %index.next, %n.vec
  br i1 %42, label %middle.block, label %vector.body, !llvm.loop !17

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

.lr.ph44:                                         ; preds = %scalar.ph.prol.loopexit, %scalar.ph, %middle.block
  %43 = getelementptr inbounds i8, ptr %0, i64 8
  %44 = load ptr, ptr %43, align 8
  %45 = sext i32 %2 to i64
  %46 = getelementptr inbounds ptr, ptr %44, i64 %45
  %47 = load ptr, ptr %46, align 8, !tbaa !13
  %48 = getelementptr inbounds i8, ptr %47, i64 8
  %49 = load ptr, ptr %48, align 8, !tbaa !21
  %wide.trip.count60 = zext i32 %7 to i64
  %50 = add nsw i64 %wide.trip.count60, -1
  %51 = add nsw i64 %wide.trip.count60, -2
  %xtraiter77 = and i64 %50, 1
  %52 = icmp eq i64 %51, 0
  %unroll_iter = and i64 %50, -2
  %lcmp.mod78.not = icmp eq i64 %xtraiter77, 0
  br label %.lr.ph41

scalar.ph:                                        ; preds = %scalar.ph.prol.loopexit, %scalar.ph
  %indvars.iv = phi i64 [ %indvars.iv.next.3, %scalar.ph ], [ %indvars.iv.unr, %scalar.ph.prol.loopexit ]
  %53 = getelementptr inbounds float, ptr %1, i64 %indvars.iv
  %54 = load float, ptr %53, align 4, !tbaa !14
  %55 = getelementptr inbounds float, ptr %20, i64 %indvars.iv
  %56 = load float, ptr %55, align 4, !tbaa !14
  %57 = fsub float %54, %56
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %58 = getelementptr inbounds float, ptr %12, i64 %indvars.iv.next
  store float %57, ptr %58, align 4, !tbaa !14
  %59 = getelementptr inbounds float, ptr %1, i64 %indvars.iv.next
  %60 = load float, ptr %59, align 4, !tbaa !14
  %61 = getelementptr inbounds float, ptr %20, i64 %indvars.iv.next
  %62 = load float, ptr %61, align 4, !tbaa !14
  %63 = fsub float %60, %62
  %indvars.iv.next.1 = add nuw nsw i64 %indvars.iv, 2
  %64 = getelementptr inbounds float, ptr %12, i64 %indvars.iv.next.1
  store float %63, ptr %64, align 4, !tbaa !14
  %65 = getelementptr inbounds float, ptr %1, i64 %indvars.iv.next.1
  %66 = load float, ptr %65, align 4, !tbaa !14
  %67 = getelementptr inbounds float, ptr %20, i64 %indvars.iv.next.1
  %68 = load float, ptr %67, align 4, !tbaa !14
  %69 = fsub float %66, %68
  %indvars.iv.next.2 = add nuw nsw i64 %indvars.iv, 3
  %70 = getelementptr inbounds float, ptr %12, i64 %indvars.iv.next.2
  store float %69, ptr %70, align 4, !tbaa !14
  %71 = getelementptr inbounds float, ptr %1, i64 %indvars.iv.next.2
  %72 = load float, ptr %71, align 4, !tbaa !14
  %73 = getelementptr inbounds float, ptr %20, i64 %indvars.iv.next.2
  %74 = load float, ptr %73, align 4, !tbaa !14
  %75 = fsub float %72, %74
  %indvars.iv.next.3 = add nuw nsw i64 %indvars.iv, 4
  %76 = getelementptr inbounds float, ptr %12, i64 %indvars.iv.next.3
  store float %75, ptr %76, align 4, !tbaa !14
  %exitcond.not.3 = icmp eq i64 %indvars.iv.next.3, %wide.trip.count
  br i1 %exitcond.not.3, label %.lr.ph44, label %scalar.ph, !llvm.loop !23

.lr.ph48.preheader:                               ; preds = %._crit_edge
  %xtraiter80 = and i64 %50, 3
  %77 = icmp ult i64 %51, 3
  br i1 %77, label %._crit_edge49.loopexit.unr-lcssa, label %.lr.ph48.preheader.new

.lr.ph48.preheader.new:                           ; preds = %.lr.ph48.preheader
  %unroll_iter83 = and i64 %50, -4
  br label %.lr.ph48

.lr.ph41:                                         ; preds = %.lr.ph44, %._crit_edge
  %indvars.iv57 = phi i64 [ 1, %.lr.ph44 ], [ %indvars.iv.next58, %._crit_edge ]
  %78 = getelementptr inbounds float, ptr %14, i64 %indvars.iv57
  %79 = getelementptr inbounds ptr, ptr %49, i64 %indvars.iv57
  %80 = load ptr, ptr %79, align 8, !tbaa !13
  br i1 %52, label %._crit_edge.unr-lcssa, label %.lr.ph41.new

._crit_edge.unr-lcssa:                            ; preds = %.lr.ph41.new, %.lr.ph41
  %.lcssa76.ph = phi float [ poison, %.lr.ph41 ], [ %105, %.lr.ph41.new ]
  %indvars.iv52.unr = phi i64 [ 1, %.lr.ph41 ], [ %indvars.iv.next53.1, %.lr.ph41.new ]
  %.unr = phi float [ 0.000000e+00, %.lr.ph41 ], [ %105, %.lr.ph41.new ]
  br i1 %lcmp.mod78.not, label %._crit_edge, label %._crit_edge.epilog-lcssa

._crit_edge.epilog-lcssa:                         ; preds = %._crit_edge.unr-lcssa
  %81 = getelementptr inbounds double, ptr %80, i64 %indvars.iv52.unr
  %82 = load double, ptr %81, align 8, !tbaa !24
  %83 = getelementptr inbounds float, ptr %12, i64 %indvars.iv52.unr
  %84 = load float, ptr %83, align 4, !tbaa !14
  %85 = fpext float %84 to double
  %86 = fpext float %.unr to double
  %87 = tail call double @llvm.fmuladd.f64(double %82, double %85, double %86)
  %88 = fptrunc double %87 to float
  br label %._crit_edge

._crit_edge:                                      ; preds = %._crit_edge.unr-lcssa, %._crit_edge.epilog-lcssa
  %.lcssa76 = phi float [ %.lcssa76.ph, %._crit_edge.unr-lcssa ], [ %88, %._crit_edge.epilog-lcssa ]
  store float %.lcssa76, ptr %78, align 4, !tbaa !14
  %indvars.iv.next58 = add nuw nsw i64 %indvars.iv57, 1
  %exitcond61.not = icmp eq i64 %indvars.iv.next58, %wide.trip.count60
  br i1 %exitcond61.not, label %.lr.ph48.preheader, label %.lr.ph41, !llvm.loop !26

.lr.ph41.new:                                     ; preds = %.lr.ph41, %.lr.ph41.new
  %indvars.iv52 = phi i64 [ %indvars.iv.next53.1, %.lr.ph41.new ], [ 1, %.lr.ph41 ]
  %89 = phi float [ %105, %.lr.ph41.new ], [ 0.000000e+00, %.lr.ph41 ]
  %niter = phi i64 [ %niter.next.1, %.lr.ph41.new ], [ 0, %.lr.ph41 ]
  %90 = getelementptr inbounds double, ptr %80, i64 %indvars.iv52
  %91 = load double, ptr %90, align 8, !tbaa !24
  %92 = getelementptr inbounds float, ptr %12, i64 %indvars.iv52
  %93 = load float, ptr %92, align 4, !tbaa !14
  %94 = fpext float %93 to double
  %95 = fpext float %89 to double
  %96 = tail call double @llvm.fmuladd.f64(double %91, double %94, double %95)
  %97 = fptrunc double %96 to float
  %indvars.iv.next53 = add nuw nsw i64 %indvars.iv52, 1
  %98 = getelementptr inbounds double, ptr %80, i64 %indvars.iv.next53
  %99 = load double, ptr %98, align 8, !tbaa !24
  %100 = getelementptr inbounds float, ptr %12, i64 %indvars.iv.next53
  %101 = load float, ptr %100, align 4, !tbaa !14
  %102 = fpext float %101 to double
  %103 = fpext float %97 to double
  %104 = tail call double @llvm.fmuladd.f64(double %99, double %102, double %103)
  %105 = fptrunc double %104 to float
  %indvars.iv.next53.1 = add nuw nsw i64 %indvars.iv52, 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.unr-lcssa, label %.lr.ph41.new, !llvm.loop !27

.lr.ph48:                                         ; preds = %.lr.ph48, %.lr.ph48.preheader.new
  %indvars.iv62 = phi i64 [ 1, %.lr.ph48.preheader.new ], [ %indvars.iv.next63.3, %.lr.ph48 ]
  %.03146 = phi float [ 0.000000e+00, %.lr.ph48.preheader.new ], [ %125, %.lr.ph48 ]
  %niter84 = phi i64 [ 0, %.lr.ph48.preheader.new ], [ %niter84.next.3, %.lr.ph48 ]
  %106 = getelementptr inbounds float, ptr %12, i64 %indvars.iv62
  %107 = load float, ptr %106, align 4, !tbaa !14
  %108 = getelementptr inbounds float, ptr %14, i64 %indvars.iv62
  %109 = load float, ptr %108, align 4, !tbaa !14
  %110 = tail call float @llvm.fmuladd.f32(float %107, float %109, float %.03146)
  %indvars.iv.next63 = add nuw nsw i64 %indvars.iv62, 1
  %111 = getelementptr inbounds float, ptr %12, i64 %indvars.iv.next63
  %112 = load float, ptr %111, align 4, !tbaa !14
  %113 = getelementptr inbounds float, ptr %14, i64 %indvars.iv.next63
  %114 = load float, ptr %113, align 4, !tbaa !14
  %115 = tail call float @llvm.fmuladd.f32(float %112, float %114, float %110)
  %indvars.iv.next63.1 = add nuw nsw i64 %indvars.iv62, 2
  %116 = getelementptr inbounds float, ptr %12, i64 %indvars.iv.next63.1
  %117 = load float, ptr %116, align 4, !tbaa !14
  %118 = getelementptr inbounds float, ptr %14, i64 %indvars.iv.next63.1
  %119 = load float, ptr %118, align 4, !tbaa !14
  %120 = tail call float @llvm.fmuladd.f32(float %117, float %119, float %115)
  %indvars.iv.next63.2 = add nuw nsw i64 %indvars.iv62, 3
  %121 = getelementptr inbounds float, ptr %12, i64 %indvars.iv.next63.2
  %122 = load float, ptr %121, align 4, !tbaa !14
  %123 = getelementptr inbounds float, ptr %14, i64 %indvars.iv.next63.2
  %124 = load float, ptr %123, align 4, !tbaa !14
  %125 = tail call float @llvm.fmuladd.f32(float %122, float %124, float %120)
  %indvars.iv.next63.3 = add nuw nsw i64 %indvars.iv62, 4
  %niter84.next.3 = add i64 %niter84, 4
  %niter84.ncmp.3 = icmp eq i64 %niter84.next.3, %unroll_iter83
  br i1 %niter84.ncmp.3, label %._crit_edge49.loopexit.unr-lcssa, label %.lr.ph48, !llvm.loop !28

._crit_edge49.loopexit.unr-lcssa:                 ; preds = %.lr.ph48, %.lr.ph48.preheader
  %.lcssa.ph = phi float [ poison, %.lr.ph48.preheader ], [ %125, %.lr.ph48 ]
  %indvars.iv62.unr = phi i64 [ 1, %.lr.ph48.preheader ], [ %indvars.iv.next63.3, %.lr.ph48 ]
  %.03146.unr = phi float [ 0.000000e+00, %.lr.ph48.preheader ], [ %125, %.lr.ph48 ]
  %lcmp.mod81.not = icmp eq i64 %xtraiter80, 0
  br i1 %lcmp.mod81.not, label %._crit_edge49, label %.lr.ph48.epil

.lr.ph48.epil:                                    ; preds = %._crit_edge49.loopexit.unr-lcssa, %.lr.ph48.epil
  %indvars.iv62.epil = phi i64 [ %indvars.iv.next63.epil, %.lr.ph48.epil ], [ %indvars.iv62.unr, %._crit_edge49.loopexit.unr-lcssa ]
  %.03146.epil = phi float [ %130, %.lr.ph48.epil ], [ %.03146.unr, %._crit_edge49.loopexit.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.lr.ph48.epil ], [ 0, %._crit_edge49.loopexit.unr-lcssa ]
  %126 = getelementptr inbounds float, ptr %12, i64 %indvars.iv62.epil
  %127 = load float, ptr %126, align 4, !tbaa !14
  %128 = getelementptr inbounds float, ptr %14, i64 %indvars.iv62.epil
  %129 = load float, ptr %128, align 4, !tbaa !14
  %130 = tail call float @llvm.fmuladd.f32(float %127, float %129, float %.03146.epil)
  %indvars.iv.next63.epil = add nuw nsw i64 %indvars.iv62.epil, 1
  %epil.iter.next = add i64 %epil.iter, 1
  %epil.iter.cmp.not = icmp eq i64 %epil.iter.next, %xtraiter80
  br i1 %epil.iter.cmp.not, label %._crit_edge49, label %.lr.ph48.epil, !llvm.loop !29

._crit_edge49:                                    ; preds = %._crit_edge49.loopexit.unr-lcssa, %.lr.ph48.epil, %3
  %.031.lcssa = phi float [ 0.000000e+00, %3 ], [ %.lcssa.ph, %._crit_edge49.loopexit.unr-lcssa ], [ %130, %.lr.ph48.epil ]
  tail call void @_ZdaPv(ptr noundef nonnull %12) #5
  tail call void @_ZdaPv(ptr noundef nonnull %14) #5
  ret float %.031.lcssa
}

; 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 float @llvm.fmuladd.f32(float, float, float) #2

; Function Attrs: nobuiltin nounwind
declare void @_ZdaPv(ptr noundef) local_unnamed_addr #3

attributes #0 = { nobuiltin allocsize(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 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 #2 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #3 = { nobuiltin nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { builtin allocsize(0) }
attributes #5 = { builtin 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, !10, i64 56}
!6 = !{!"_ZTS12GaussMixture", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !10, i64 40, !10, i64 44, !10, i64 48, !10, i64 52, !10, i64 56, !10, i64 60, !10, i64 64, !10, i64 68, !11, i64 72, !11, i64 76, !11, i64 80, !10, i64 84}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"int", !8, i64 0}
!11 = !{!"float", !8, i64 0}
!12 = !{!6, !7, i64 24}
!13 = !{!7, !7, i64 0}
!14 = !{!11, !11, i64 0}
!15 = distinct !{!15, !16}
!16 = !{!"llvm.loop.unroll.disable"}
!17 = distinct !{!17, !18, !19, !20}
!18 = !{!"llvm.loop.mustprogress"}
!19 = !{!"llvm.loop.isvectorized", i32 1}
!20 = !{!"llvm.loop.unroll.runtime.disable"}
!21 = !{!22, !7, i64 8}
!22 = !{!"_ZTS6Matrix", !7, i64 8, !10, i64 16, !10, i64 20}
!23 = distinct !{!23, !18, !19}
!24 = !{!25, !25, i64 0}
!25 = !{!"double", !8, i64 0}
!26 = distinct !{!26, !18}
!27 = distinct !{!27, !18}
!28 = distinct !{!28, !18}
!29 = distinct !{!29, !16}


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