; LLVM IR from rdguez-mariano/fast_imas_IPOL :: libSimuTilts/filter.ll (Z24directional_gauss_filterfffPiS_)

; 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: mustprogress uwtable
define dso_local noundef ptr @_Z24directional_gauss_filterfffPiS_(float noundef %0, float noundef %1, float noundef %2, ptr noundef %3, ptr noundef %4) #0 {
  %6 = alloca float, align 4
  %7 = alloca float, align 4
  %8 = alloca float, align 4
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca i32, align 4
  %12 = alloca ptr, align 8
  %13 = alloca float, align 4
  %14 = alloca float, align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca float, align 4
  %20 = alloca float, align 4
  %21 = alloca float, align 4
  %22 = alloca float, align 4
  %23 = alloca float, align 4
  %24 = alloca float, align 4
  %25 = alloca i32, align 4
  %26 = alloca i32, align 4
  store float %0, ptr %6, align 4, !tbaa !5
  store float %1, ptr %7, align 4, !tbaa !5
  store float %2, ptr %8, align 4, !tbaa !5
  store ptr %3, ptr %9, align 8, !tbaa !9
  store ptr %4, ptr %10, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #5
  %27 = load float, ptr %6, align 4, !tbaa !5
  %28 = load float, ptr %7, align 4, !tbaa !5
  %29 = fcmp olt float %27, %28
  br i1 %29, label %30, label %32

30:                                               ; preds = %5
  %31 = load float, ptr %7, align 4, !tbaa !5
  br label %34

32:                                               ; preds = %5
  %33 = load float, ptr %6, align 4, !tbaa !5
  br label %34

34:                                               ; preds = %32, %30
  %35 = phi float [ %31, %30 ], [ %33, %32 ]
  %36 = fpext float %35 to double
  %37 = call double @llvm.fmuladd.f64(double 4.000000e+00, double %36, double 1.000000e+00)
  %38 = fptosi double %37 to i32
  store i32 %38, ptr %11, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #5
  %39 = load i32, ptr %11, align 4, !tbaa !11
  %40 = load i32, ptr %11, align 4, !tbaa !11
  %41 = mul nsw i32 %39, %40
  %42 = sext i32 %41 to i64
  %43 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %42, i64 4)
  %44 = extractvalue { i64, i1 } %43, 1
  %45 = extractvalue { i64, i1 } %43, 0
  %46 = select i1 %44, i64 -1, i64 %45
  %47 = call noalias noundef nonnull ptr @_Znam(i64 noundef %46) #6
  store ptr %47, ptr %12, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #5
  %48 = load float, ptr %6, align 4, !tbaa !5
  %49 = load float, ptr %6, align 4, !tbaa !5
  %50 = fmul float %48, %49
  store float %50, ptr %13, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #5
  %51 = load float, ptr %7, align 4, !tbaa !5
  %52 = load float, ptr %7, align 4, !tbaa !5
  %53 = fmul float %51, %52
  store float %53, ptr %14, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #5
  %54 = load i32, ptr %11, align 4, !tbaa !11
  %55 = sdiv i32 %54, 2
  store i32 %55, ptr %15, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #5
  %56 = load i32, ptr %15, align 4, !tbaa !11
  %57 = sub nsw i32 0, %56
  store i32 %57, ptr %16, align 4, !tbaa !11
  br label %58

58:                                               ; preds = %129, %34
  %59 = load i32, ptr %16, align 4, !tbaa !11
  %60 = load i32, ptr %15, align 4, !tbaa !11
  %61 = icmp sle i32 %59, %60
  br i1 %61, label %63, label %62

62:                                               ; preds = %58
  store i32 2, ptr %17, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #5
  br label %132

63:                                               ; preds = %58
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #5
  %64 = load i32, ptr %15, align 4, !tbaa !11
  %65 = sub nsw i32 0, %64
  store i32 %65, ptr %18, align 4, !tbaa !11
  br label %66

66:                                               ; preds = %125, %63
  %67 = load i32, ptr %18, align 4, !tbaa !11
  %68 = load i32, ptr %15, align 4, !tbaa !11
  %69 = icmp sle i32 %67, %68
  br i1 %69, label %71, label %70

70:                                               ; preds = %66
  store i32 5, ptr %17, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #5
  br label %128

71:                                               ; preds = %66
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #5
  %72 = load float, ptr %8, align 4, !tbaa !5
  %73 = fpext float %72 to double
  %74 = fmul double %73, 0x400921FB54442D18
  %75 = fdiv double %74, 1.800000e+02
  %76 = fptrunc double %75 to float
  store float %76, ptr %19, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #5
  %77 = load float, ptr %19, align 4, !tbaa !5
  %78 = call noundef float @_ZSt3sinf(float noundef %77)
  store float %78, ptr %20, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #5
  %79 = load float, ptr %19, align 4, !tbaa !5
  %80 = call noundef float @_ZSt3cosf(float noundef %79)
  store float %80, ptr %21, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #5
  %81 = load i32, ptr %18, align 4, !tbaa !11
  %82 = sitofp i32 %81 to float
  %83 = load float, ptr %21, align 4, !tbaa !5
  %84 = load i32, ptr %16, align 4, !tbaa !11
  %85 = sitofp i32 %84 to float
  %86 = load float, ptr %20, align 4, !tbaa !5
  %87 = fmul float %85, %86
  %88 = call float @llvm.fmuladd.f32(float %82, float %83, float %87)
  store float %88, ptr %22, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #5
  %89 = load i32, ptr %18, align 4, !tbaa !11
  %90 = sitofp i32 %89 to float
  %91 = fneg float %90
  %92 = load float, ptr %20, align 4, !tbaa !5
  %93 = load i32, ptr %16, align 4, !tbaa !11
  %94 = sitofp i32 %93 to float
  %95 = load float, ptr %21, align 4, !tbaa !5
  %96 = fmul float %94, %95
  %97 = call float @llvm.fmuladd.f32(float %91, float %92, float %96)
  store float %97, ptr %23, align 4, !tbaa !5
  %98 = load float, ptr %22, align 4, !tbaa !5
  %99 = load float, ptr %22, align 4, !tbaa !5
  %100 = fmul float %98, %99
  %101 = fneg float %100
  %102 = load float, ptr %13, align 4, !tbaa !5
  %103 = fmul float 2.000000e+00, %102
  %104 = fdiv float %101, %103
  %105 = load float, ptr %23, align 4, !tbaa !5
  %106 = load float, ptr %23, align 4, !tbaa !5
  %107 = fmul float %105, %106
  %108 = load float, ptr %14, align 4, !tbaa !5
  %109 = fmul float 2.000000e+00, %108
  %110 = fdiv float %107, %109
  %111 = fsub float %104, %110
  %112 = call noundef float @_ZSt3expf(float noundef %111)
  %113 = load ptr, ptr %12, align 8, !tbaa !9
  %114 = load i32, ptr %16, align 4, !tbaa !11
  %115 = load i32, ptr %15, align 4, !tbaa !11
  %116 = add nsw i32 %114, %115
  %117 = load i32, ptr %11, align 4, !tbaa !11
  %118 = mul nsw i32 %116, %117
  %119 = load i32, ptr %18, align 4, !tbaa !11
  %120 = add nsw i32 %118, %119
  %121 = load i32, ptr %15, align 4, !tbaa !11
  %122 = add nsw i32 %120, %121
  %123 = sext i32 %122 to i64
  %124 = getelementptr inbounds float, ptr %113, i64 %123
  store float %112, ptr %124, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #5
  br label %125

125:                                              ; preds = %71
  %126 = load i32, ptr %18, align 4, !tbaa !11
  %127 = add nsw i32 %126, 1
  store i32 %127, ptr %18, align 4, !tbaa !11
  br label %66, !llvm.loop !13

128:                                              ; preds = %70
  br label %129

129:                                              ; preds = %128
  %130 = load i32, ptr %16, align 4, !tbaa !11
  %131 = add nsw i32 %130, 1
  store i32 %131, ptr %16, align 4, !tbaa !11
  br label %58, !llvm.loop !15

132:                                              ; preds = %62
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #5
  store float 0.000000e+00, ptr %24, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #5
  store i32 0, ptr %25, align 4, !tbaa !11
  br label %133

133:                                              ; preds = %148, %132
  %134 = load i32, ptr %25, align 4, !tbaa !11
  %135 = load i32, ptr %11, align 4, !tbaa !11
  %136 = load i32, ptr %11, align 4, !tbaa !11
  %137 = mul nsw i32 %135, %136
  %138 = icmp slt i32 %134, %137
  br i1 %138, label %140, label %139

139:                                              ; preds = %133
  store i32 8, ptr %17, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #5
  br label %151

140:                                              ; preds = %133
  %141 = load ptr, ptr %12, align 8, !tbaa !9
  %142 = load i32, ptr %25, align 4, !tbaa !11
  %143 = sext i32 %142 to i64
  %144 = getelementptr inbounds float, ptr %141, i64 %143
  %145 = load float, ptr %144, align 4, !tbaa !5
  %146 = load float, ptr %24, align 4, !tbaa !5
  %147 = fadd float %146, %145
  store float %147, ptr %24, align 4, !tbaa !5
  br label %148

148:                                              ; preds = %140
  %149 = load i32, ptr %25, align 4, !tbaa !11
  %150 = add nsw i32 %149, 1
  store i32 %150, ptr %25, align 4, !tbaa !11
  br label %133, !llvm.loop !16

151:                                              ; preds = %139
  call void @llvm.lifetime.start.p0(i64 4, ptr %26) #5
  store i32 0, ptr %26, align 4, !tbaa !11
  br label %152

152:                                              ; preds = %167, %151
  %153 = load i32, ptr %26, align 4, !tbaa !11
  %154 = load i32, ptr %11, align 4, !tbaa !11
  %155 = load i32, ptr %11, align 4, !tbaa !11
  %156 = mul nsw i32 %154, %155
  %157 = icmp slt i32 %153, %156
  br i1 %157, label %159, label %158

158:                                              ; preds = %152
  store i32 11, ptr %17, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #5
  br label %170

159:                                              ; preds = %152
  %160 = load float, ptr %24, align 4, !tbaa !5
  %161 = load ptr, ptr %12, align 8, !tbaa !9
  %162 = load i32, ptr %26, align 4, !tbaa !11
  %163 = sext i32 %162 to i64
  %164 = getelementptr inbounds float, ptr %161, i64 %163
  %165 = load float, ptr %164, align 4, !tbaa !5
  %166 = fdiv float %165, %160
  store float %166, ptr %164, align 4, !tbaa !5
  br label %167

167:                                              ; preds = %159
  %168 = load i32, ptr %26, align 4, !tbaa !11
  %169 = add nsw i32 %168, 1
  store i32 %169, ptr %26, align 4, !tbaa !11
  br label %152, !llvm.loop !17

170:                                              ; preds = %158
  %171 = load i32, ptr %11, align 4, !tbaa !11
  %172 = load ptr, ptr %9, align 8, !tbaa !9
  store i32 %171, ptr %172, align 4, !tbaa !11
  %173 = load i32, ptr %11, align 4, !tbaa !11
  %174 = load ptr, ptr %10, align 8, !tbaa !9
  store i32 %173, ptr %174, align 4, !tbaa !11
  %175 = load ptr, ptr %12, align 8, !tbaa !9
  store i32 1, ptr %17, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #5
  ret ptr %175
}

; 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 speculatable willreturn memory(none)
declare { i64, i1 } @llvm.umul.with.overflow.i64(i64, i64) #2

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef float @_ZSt3sinf(float noundef) #4

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef float @_ZSt3cosf(float noundef) #4

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef float @_ZSt3expf(float noundef) #4

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

attributes #0 = { 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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #3 = { 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 #4 = { inlinehint 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 #5 = { nounwind }
attributes #6 = { builtin allocsize(0) }

!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 = !{!"float", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = distinct !{!15, !14}
!16 = distinct !{!16, !14}
!17 = distinct !{!17, !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: mustprogress uwtable
define dso_local noalias noundef nonnull ptr @_Z24directional_gauss_filterfffPiS_(float noundef %0, float noundef %1, float noundef %2, ptr nocapture noundef writeonly %3, ptr nocapture noundef writeonly %4) local_unnamed_addr #0 {
  %6 = fcmp olt float %0, %1
  %7 = select i1 %6, float %1, float %0
  %8 = fpext float %7 to double
  %9 = tail call double @llvm.fmuladd.f64(double %8, double 4.000000e+00, double 1.000000e+00)
  %10 = fptosi double %9 to i32
  %11 = mul nsw i32 %10, %10
  %12 = zext nneg i32 %11 to i64
  %13 = shl nuw nsw i64 %12, 2
  %14 = tail call noalias noundef nonnull ptr @_Znam(i64 noundef %13) #5
  %15 = sdiv i32 %10, 2
  %.not71 = icmp slt i32 %10, -1
  br i1 %.not71, label %.lr.ph.preheader, label %.preheader68.lr.ph

.preheader68.lr.ph:                               ; preds = %5
  %16 = sub nsw i32 0, %15
  %17 = insertelement <2 x float> poison, float %1, i64 0
  %18 = insertelement <2 x float> %17, float %0, i64 1
  %19 = fmul <2 x float> %18, %18
  %20 = fpext float %2 to double
  %21 = fmul double %20, 0x400921FB54442D18
  %22 = fdiv double %21, 1.800000e+02
  %23 = fptrunc double %22 to float
  %24 = fmul <2 x float> %19, <float 2.000000e+00, float 2.000000e+00>
  %25 = zext i32 %16 to i64
  %smax = tail call i32 @llvm.abs.i32(i32 %15, i1 true)
  %26 = add nuw nsw i32 %smax, 1
  br label %.preheader68

.preheader68:                                     ; preds = %.preheader68.lr.ph, %._crit_edge
  %.06272 = phi i32 [ %16, %.preheader68.lr.ph ], [ %34, %._crit_edge ]
  %27 = sitofp i32 %.06272 to float
  %28 = add nsw i32 %.06272, %15
  %29 = mul nsw i32 %28, %10
  %30 = add i32 %29, %15
  %31 = insertelement <2 x float> poison, float %27, i64 0
  %32 = shufflevector <2 x float> %31, <2 x float> poison, <2 x i32> zeroinitializer
  br label %35

.preheader67:                                     ; preds = %._crit_edge
  %.not = icmp eq i32 %10, 0
  br i1 %.not, label %._crit_edge77, label %.lr.ph.preheader

.lr.ph.preheader:                                 ; preds = %5, %.preheader67
  %umax = tail call i32 @llvm.umax.i32(i32 %11, i32 1)
  %wide.trip.count = zext nneg i32 %umax to i64
  %xtraiter = and i64 %wide.trip.count, 7
  %33 = icmp ult i32 %11, 8
  br i1 %33, label %.lr.ph76.preheader.unr-lcssa, label %.lr.ph.preheader.new

.lr.ph.preheader.new:                             ; preds = %.lr.ph.preheader
  %unroll_iter = and i64 %wide.trip.count, 2147483640
  br label %.lr.ph

._crit_edge:                                      ; preds = %35
  %34 = add i32 %.06272, 1
  %exitcond80.not = icmp eq i32 %.06272, %smax
  br i1 %exitcond80.not, label %.preheader67, label %.preheader68, !llvm.loop !5

35:                                               ; preds = %.preheader68, %35
  %indvars.iv = phi i64 [ %25, %.preheader68 ], [ %indvars.iv.next, %35 ]
  %36 = tail call noundef float @_ZSt3sinf(float noundef %23)
  %37 = tail call noundef float @_ZSt3cosf(float noundef %23)
  %38 = trunc i64 %indvars.iv to i32
  %39 = sitofp i32 %38 to float
  %40 = fneg float %39
  %41 = insertelement <2 x float> poison, float %37, i64 0
  %42 = insertelement <2 x float> %41, float %36, i64 1
  %43 = fmul <2 x float> %42, %32
  %44 = insertelement <2 x float> poison, float %40, i64 0
  %45 = insertelement <2 x float> %44, float %39, i64 1
  %46 = shufflevector <2 x float> %42, <2 x float> poison, <2 x i32> <i32 1, i32 0>
  %47 = tail call <2 x float> @llvm.fmuladd.v2f32(<2 x float> %45, <2 x float> %46, <2 x float> %43)
  %48 = fneg <2 x float> %47
  %49 = shufflevector <2 x float> %47, <2 x float> %48, <2 x i32> <i32 0, i32 3>
  %50 = fmul <2 x float> %47, %49
  %51 = fdiv <2 x float> %50, %24
  %shift = shufflevector <2 x float> %51, <2 x float> poison, <2 x i32> <i32 1, i32 poison>
  %52 = fsub <2 x float> %shift, %51
  %53 = extractelement <2 x float> %52, i64 0
  %54 = tail call noundef float @_ZSt3expf(float noundef %53)
  %55 = add i32 %30, %38
  %56 = sext i32 %55 to i64
  %57 = getelementptr inbounds float, ptr %14, i64 %56
  store float %54, ptr %57, align 4, !tbaa !7
  %indvars.iv.next = add i64 %indvars.iv, 1
  %lftr.wideiv = trunc i64 %indvars.iv.next to i32
  %exitcond.not = icmp eq i32 %26, %lftr.wideiv
  br i1 %exitcond.not, label %._crit_edge, label %35, !llvm.loop !11

.lr.ph76.preheader.unr-lcssa:                     ; preds = %.lr.ph, %.lr.ph.preheader
  %.lcssa.ph = phi float [ poison, %.lr.ph.preheader ], [ %87, %.lr.ph ]
  %indvars.iv81.unr = phi i64 [ 0, %.lr.ph.preheader ], [ %indvars.iv.next82.7, %.lr.ph ]
  %.06173.unr = phi float [ 0.000000e+00, %.lr.ph.preheader ], [ %87, %.lr.ph ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %.lr.ph76.preheader, label %.lr.ph.epil

.lr.ph.epil:                                      ; preds = %.lr.ph76.preheader.unr-lcssa, %.lr.ph.epil
  %indvars.iv81.epil = phi i64 [ %indvars.iv.next82.epil, %.lr.ph.epil ], [ %indvars.iv81.unr, %.lr.ph76.preheader.unr-lcssa ]
  %.06173.epil = phi float [ %60, %.lr.ph.epil ], [ %.06173.unr, %.lr.ph76.preheader.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.lr.ph.epil ], [ 0, %.lr.ph76.preheader.unr-lcssa ]
  %58 = getelementptr inbounds float, ptr %14, i64 %indvars.iv81.epil
  %59 = load float, ptr %58, align 4, !tbaa !7
  %60 = fadd float %.06173.epil, %59
  %indvars.iv.next82.epil = add nuw nsw i64 %indvars.iv81.epil, 1
  %epil.iter.next = add i64 %epil.iter, 1
  %epil.iter.cmp.not = icmp eq i64 %epil.iter.next, %xtraiter
  br i1 %epil.iter.cmp.not, label %.lr.ph76.preheader, label %.lr.ph.epil, !llvm.loop !12

.lr.ph76.preheader:                               ; preds = %.lr.ph.epil, %.lr.ph76.preheader.unr-lcssa
  %.lcssa = phi float [ %.lcssa.ph, %.lr.ph76.preheader.unr-lcssa ], [ %60, %.lr.ph.epil ]
  %umax88 = tail call i32 @llvm.umax.i32(i32 %11, i32 1)
  %wide.trip.count89 = zext nneg i32 %umax88 to i64
  %min.iters.check = icmp ult i32 %11, 4
  br i1 %min.iters.check, label %.lr.ph76.preheader96, label %vector.ph

.lr.ph76.preheader96:                             ; preds = %middle.block, %.lr.ph76.preheader
  %indvars.iv85.ph = phi i64 [ 0, %.lr.ph76.preheader ], [ %n.vec, %middle.block ]
  br label %.lr.ph76

vector.ph:                                        ; preds = %.lr.ph76.preheader
  %n.vec = and i64 %wide.trip.count, 2147483644
  %broadcast.splatinsert = insertelement <4 x float> poison, float %.lcssa, i64 0
  %broadcast.splat = shufflevector <4 x float> %broadcast.splatinsert, <4 x float> poison, <4 x i32> zeroinitializer
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %61 = getelementptr inbounds float, ptr %14, i64 %index
  %wide.load = load <4 x float>, ptr %61, align 4, !tbaa !7
  %62 = fdiv <4 x float> %wide.load, %broadcast.splat
  store <4 x float> %62, ptr %61, align 4, !tbaa !7
  %index.next = add nuw i64 %index, 4
  %63 = icmp eq i64 %index.next, %n.vec
  br i1 %63, label %middle.block, label %vector.body, !llvm.loop !14

middle.block:                                     ; preds = %vector.body
  %cmp.n = icmp eq i64 %n.vec, %wide.trip.count
  br i1 %cmp.n, label %._crit_edge77, label %.lr.ph76.preheader96

.lr.ph:                                           ; preds = %.lr.ph, %.lr.ph.preheader.new
  %indvars.iv81 = phi i64 [ 0, %.lr.ph.preheader.new ], [ %indvars.iv.next82.7, %.lr.ph ]
  %.06173 = phi float [ 0.000000e+00, %.lr.ph.preheader.new ], [ %87, %.lr.ph ]
  %niter = phi i64 [ 0, %.lr.ph.preheader.new ], [ %niter.next.7, %.lr.ph ]
  %64 = getelementptr inbounds float, ptr %14, i64 %indvars.iv81
  %65 = load float, ptr %64, align 4, !tbaa !7
  %66 = fadd float %.06173, %65
  %indvars.iv.next82 = or disjoint i64 %indvars.iv81, 1
  %67 = getelementptr inbounds float, ptr %14, i64 %indvars.iv.next82
  %68 = load float, ptr %67, align 4, !tbaa !7
  %69 = fadd float %66, %68
  %indvars.iv.next82.1 = or disjoint i64 %indvars.iv81, 2
  %70 = getelementptr inbounds float, ptr %14, i64 %indvars.iv.next82.1
  %71 = load float, ptr %70, align 4, !tbaa !7
  %72 = fadd float %69, %71
  %indvars.iv.next82.2 = or disjoint i64 %indvars.iv81, 3
  %73 = getelementptr inbounds float, ptr %14, i64 %indvars.iv.next82.2
  %74 = load float, ptr %73, align 4, !tbaa !7
  %75 = fadd float %72, %74
  %indvars.iv.next82.3 = or disjoint i64 %indvars.iv81, 4
  %76 = getelementptr inbounds float, ptr %14, i64 %indvars.iv.next82.3
  %77 = load float, ptr %76, align 4, !tbaa !7
  %78 = fadd float %75, %77
  %indvars.iv.next82.4 = or disjoint i64 %indvars.iv81, 5
  %79 = getelementptr inbounds float, ptr %14, i64 %indvars.iv.next82.4
  %80 = load float, ptr %79, align 4, !tbaa !7
  %81 = fadd float %78, %80
  %indvars.iv.next82.5 = or disjoint i64 %indvars.iv81, 6
  %82 = getelementptr inbounds float, ptr %14, i64 %indvars.iv.next82.5
  %83 = load float, ptr %82, align 4, !tbaa !7
  %84 = fadd float %81, %83
  %indvars.iv.next82.6 = or disjoint i64 %indvars.iv81, 7
  %85 = getelementptr inbounds float, ptr %14, i64 %indvars.iv.next82.6
  %86 = load float, ptr %85, align 4, !tbaa !7
  %87 = fadd float %84, %86
  %indvars.iv.next82.7 = add nuw nsw i64 %indvars.iv81, 8
  %niter.next.7 = add i64 %niter, 8
  %niter.ncmp.7 = icmp eq i64 %niter.next.7, %unroll_iter
  br i1 %niter.ncmp.7, label %.lr.ph76.preheader.unr-lcssa, label %.lr.ph, !llvm.loop !17

._crit_edge77:                                    ; preds = %.lr.ph76, %middle.block, %.preheader67
  store i32 %10, ptr %3, align 4, !tbaa !18
  store i32 %10, ptr %4, align 4, !tbaa !18
  ret ptr %14

.lr.ph76:                                         ; preds = %.lr.ph76.preheader96, %.lr.ph76
  %indvars.iv85 = phi i64 [ %indvars.iv.next86, %.lr.ph76 ], [ %indvars.iv85.ph, %.lr.ph76.preheader96 ]
  %88 = getelementptr inbounds float, ptr %14, i64 %indvars.iv85
  %89 = load float, ptr %88, align 4, !tbaa !7
  %90 = fdiv float %89, %.lcssa
  store float %90, ptr %88, align 4, !tbaa !7
  %indvars.iv.next86 = add nuw nsw i64 %indvars.iv85, 1
  %exitcond90.not = icmp eq i64 %indvars.iv.next86, %wide.trip.count89
  br i1 %exitcond90.not, label %._crit_edge77, label %.lr.ph76, !llvm.loop !20
}

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef float @_ZSt3sinf(float noundef) local_unnamed_addr #3

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef float @_ZSt3cosf(float noundef) local_unnamed_addr #3

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef float @_ZSt3expf(float noundef) local_unnamed_addr #3

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.umax.i32(i32, i32) #4

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.abs.i32(i32, i1 immarg) #4

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

attributes #0 = { 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 #1 = { mustprogress 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 = { inlinehint 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 #4 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #5 = { builtin allocsize(0) }

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

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


; Effective O3 passes: BDCEPass,CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalDCEPass,GlobalOptPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopLoadEliminationPass,LoopRotatePass,LoopSimplifyCFGPass,LoopSimplifyPass,LoopUnrollPass,LoopVectorizePass,PostOrderFunctionAttrsPass,ReassociatePass,SCCPPass,SLPVectorizerPass,SROAPass,SimplifyCFGPass,TailCallElimPass,VectorCombinePass