; LLVM IR from atlantis13579/Riemann :: Src/Solver (NumericalODESolver)

; 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.NumericalODESolver::ImplicitEuler_NewtonIteration" = type <{ %"class.std::function", %"class.std::function", %"class.std::vector", float, i32, float, [4 x i8] }>
%"class.std::function" = type { %"class.std::_Function_base", ptr }
%"class.std::_Function_base" = type { %"union.std::_Any_data", ptr }
%"union.std::_Any_data" = type { %"union.std::_Nocopy_types" }
%"union.std::_Nocopy_types" = type { { i64, i64 } }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<float, std::allocator<float>>::_Vector_impl" }
%"struct.std::_Vector_base<float, std::allocator<float>>::_Vector_impl" = type { %"struct.std::_Vector_base<float, std::allocator<float>>::_Vector_impl_data" }
%"struct.std::_Vector_base<float, std::allocator<float>>::_Vector_impl_data" = type { ptr, ptr, ptr }

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNKSt6vectorIfSaIfEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24)) #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIfSaIfEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) #1 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIfSaIfEEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNKSt8functionIFvPKfifPfEEclES1_ifS2_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, i32 noundef, float noundef, ptr noundef) #1 align 2

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN18NumericalODESolver29ImplicitEuler_NewtonIteration9IntegrateEfiPf(ptr noundef nonnull align 8 dereferenceable(100) %0, float noundef %1, i32 noundef %2, ptr noundef %3) #1 align 2 {
  %5 = alloca ptr, align 8
  %6 = alloca float, align 4
  %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 i32, align 4
  %13 = alloca i8, align 1
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca float, align 4
  %17 = alloca float, align 4
  %18 = alloca float, align 4
  store ptr %0, ptr %5, align 8, !tbaa !5
  store float %1, ptr %6, align 4, !tbaa !9
  store i32 %2, ptr %7, align 4, !tbaa !11
  store ptr %3, ptr %8, align 8, !tbaa !5
  %19 = load ptr, ptr %5, align 8
  %20 = getelementptr inbounds %"class.NumericalODESolver::ImplicitEuler_NewtonIteration", ptr %19, i32 0, i32 2
  %21 = call noundef i64 @_ZNKSt6vectorIfSaIfEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %20) #5
  %22 = load i32, ptr %7, align 4, !tbaa !11
  %23 = mul nsw i32 3, %22
  %24 = sext i32 %23 to i64
  %25 = icmp ult i64 %21, %24
  br i1 %25, label %26, label %31

26:                                               ; preds = %4
  %27 = getelementptr inbounds %"class.NumericalODESolver::ImplicitEuler_NewtonIteration", ptr %19, i32 0, i32 2
  %28 = load i32, ptr %7, align 4, !tbaa !11
  %29 = mul nsw i32 3, %28
  %30 = sext i32 %29 to i64
  call void @_ZNSt6vectorIfSaIfEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %27, i64 noundef %30)
  br label %31

31:                                               ; preds = %26, %4
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #5
  %32 = getelementptr inbounds %"class.NumericalODESolver::ImplicitEuler_NewtonIteration", ptr %19, i32 0, i32 2
  %33 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIfSaIfEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %32, i64 noundef 0) #5
  store ptr %33, ptr %9, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #5
  %34 = load ptr, ptr %9, align 8, !tbaa !5
  %35 = load i32, ptr %7, align 4, !tbaa !11
  %36 = sext i32 %35 to i64
  %37 = getelementptr inbounds float, ptr %34, i64 %36
  store ptr %37, ptr %10, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  %38 = load ptr, ptr %9, align 8, !tbaa !5
  %39 = load i32, ptr %7, align 4, !tbaa !11
  %40 = mul nsw i32 2, %39
  %41 = sext i32 %40 to i64
  %42 = getelementptr inbounds float, ptr %38, i64 %41
  store ptr %42, ptr %11, align 8, !tbaa !5
  %43 = load ptr, ptr %11, align 8, !tbaa !5
  %44 = load ptr, ptr %8, align 8, !tbaa !5
  %45 = load i32, ptr %7, align 4, !tbaa !11
  %46 = sext i32 %45 to i64
  %47 = mul i64 4, %46
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %43, ptr align 4 %44, i64 %47, i1 false)
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #5
  store i32 0, ptr %12, align 4, !tbaa !11
  br label %48

48:                                               ; preds = %136, %31
  %49 = load i32, ptr %12, align 4, !tbaa !11
  %50 = add nsw i32 %49, 1
  store i32 %50, ptr %12, align 4, !tbaa !11
  %51 = getelementptr inbounds %"class.NumericalODESolver::ImplicitEuler_NewtonIteration", ptr %19, i32 0, i32 4
  %52 = load i32, ptr %51, align 4, !tbaa !13
  %53 = icmp slt i32 %49, %52
  br i1 %53, label %54, label %137

54:                                               ; preds = %48
  %55 = getelementptr inbounds %"class.NumericalODESolver::ImplicitEuler_NewtonIteration", ptr %19, i32 0, i32 0
  %56 = load ptr, ptr %8, align 8, !tbaa !5
  %57 = load i32, ptr %7, align 4, !tbaa !11
  %58 = getelementptr inbounds %"class.NumericalODESolver::ImplicitEuler_NewtonIteration", ptr %19, i32 0, i32 3
  %59 = load float, ptr %58, align 8, !tbaa !21
  %60 = load ptr, ptr %9, align 8, !tbaa !5
  call void @_ZNKSt8functionIFvPKfifPfEEclES1_ifS2_(ptr noundef nonnull align 8 dereferenceable(32) %55, ptr noundef %56, i32 noundef %57, float noundef %59, ptr noundef %60)
  %61 = getelementptr inbounds %"class.NumericalODESolver::ImplicitEuler_NewtonIteration", ptr %19, i32 0, i32 1
  %62 = load ptr, ptr %8, align 8, !tbaa !5
  %63 = load i32, ptr %7, align 4, !tbaa !11
  %64 = getelementptr inbounds %"class.NumericalODESolver::ImplicitEuler_NewtonIteration", ptr %19, i32 0, i32 3
  %65 = load float, ptr %64, align 8, !tbaa !21
  %66 = load ptr, ptr %10, align 8, !tbaa !5
  call void @_ZNKSt8functionIFvPKfifPfEEclES1_ifS2_(ptr noundef nonnull align 8 dereferenceable(32) %61, ptr noundef %62, i32 noundef %63, float noundef %65, ptr noundef %66)
  call void @llvm.lifetime.start.p0(i64 1, ptr %13) #5
  store i8 1, ptr %13, align 1, !tbaa !22
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #5
  store i32 0, ptr %14, align 4, !tbaa !11
  br label %67

67:                                               ; preds = %126, %54
  %68 = load i32, ptr %14, align 4, !tbaa !11
  %69 = load i32, ptr %7, align 4, !tbaa !11
  %70 = icmp slt i32 %68, %69
  br i1 %70, label %72, label %71

71:                                               ; preds = %67
  store i32 4, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  br label %129

72:                                               ; preds = %67
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #5
  %73 = load ptr, ptr %8, align 8, !tbaa !5
  %74 = load i32, ptr %14, align 4, !tbaa !11
  %75 = sext i32 %74 to i64
  %76 = getelementptr inbounds float, ptr %73, i64 %75
  %77 = load float, ptr %76, align 4, !tbaa !9
  %78 = load ptr, ptr %11, align 8, !tbaa !5
  %79 = load i32, ptr %14, align 4, !tbaa !11
  %80 = sext i32 %79 to i64
  %81 = getelementptr inbounds float, ptr %78, i64 %80
  %82 = load float, ptr %81, align 4, !tbaa !9
  %83 = fsub float %77, %82
  %84 = load float, ptr %6, align 4, !tbaa !9
  %85 = load ptr, ptr %9, align 8, !tbaa !5
  %86 = load i32, ptr %14, align 4, !tbaa !11
  %87 = sext i32 %86 to i64
  %88 = getelementptr inbounds float, ptr %85, i64 %87
  %89 = load float, ptr %88, align 4, !tbaa !9
  %90 = fneg float %84
  %91 = call float @llvm.fmuladd.f32(float %90, float %89, float %83)
  store float %91, ptr %16, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #5
  %92 = load float, ptr %6, align 4, !tbaa !9
  %93 = load ptr, ptr %10, align 8, !tbaa !5
  %94 = load i32, ptr %14, align 4, !tbaa !11
  %95 = sext i32 %94 to i64
  %96 = getelementptr inbounds float, ptr %93, i64 %95
  %97 = load float, ptr %96, align 4, !tbaa !9
  %98 = fneg float %92
  %99 = call float @llvm.fmuladd.f32(float %98, float %97, float 1.000000e+00)
  store float %99, ptr %17, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #5
  %100 = load float, ptr %16, align 4, !tbaa !9
  %101 = load float, ptr %17, align 4, !tbaa !9
  %102 = fdiv float %100, %101
  %103 = call float @llvm.fabs.f32(float %102)
  store float %103, ptr %18, align 4, !tbaa !9
  %104 = load float, ptr %18, align 4, !tbaa !9
  %105 = getelementptr inbounds %"class.NumericalODESolver::ImplicitEuler_NewtonIteration", ptr %19, i32 0, i32 5
  %106 = load float, ptr %105, align 8, !tbaa !24
  %107 = fcmp olt float %104, %106
  br i1 %107, label %108, label %109

108:                                              ; preds = %72
  store i32 6, ptr %15, align 4
  br label %123

109:                                              ; preds = %72
  %110 = load ptr, ptr %8, align 8, !tbaa !5
  %111 = load i32, ptr %14, align 4, !tbaa !11
  %112 = sext i32 %111 to i64
  %113 = getelementptr inbounds float, ptr %110, i64 %112
  %114 = load float, ptr %113, align 4, !tbaa !9
  %115 = load float, ptr %16, align 4, !tbaa !9
  %116 = load float, ptr %17, align 4, !tbaa !9
  %117 = fdiv float %115, %116
  %118 = fsub float %114, %117
  %119 = load ptr, ptr %8, align 8, !tbaa !5
  %120 = load i32, ptr %14, align 4, !tbaa !11
  %121 = sext i32 %120 to i64
  %122 = getelementptr inbounds float, ptr %119, i64 %121
  store float %118, ptr %122, align 4, !tbaa !9
  store i8 0, ptr %13, align 1, !tbaa !22
  store i32 0, ptr %15, align 4
  br label %123

123:                                              ; preds = %109, %108
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #5
  %124 = load i32, ptr %15, align 4
  switch i32 %124, label %142 [
    i32 0, label %125
    i32 6, label %126
  ]

125:                                              ; preds = %123
  br label %126

126:                                              ; preds = %125, %123
  %127 = load i32, ptr %14, align 4, !tbaa !11
  %128 = add nsw i32 %127, 1
  store i32 %128, ptr %14, align 4, !tbaa !11
  br label %67, !llvm.loop !25

129:                                              ; preds = %71
  %130 = load i8, ptr %13, align 1, !tbaa !22, !range !27, !noundef !28
  %131 = trunc i8 %130 to i1
  br i1 %131, label %132, label %133

132:                                              ; preds = %129
  store i32 3, ptr %15, align 4
  br label %134

133:                                              ; preds = %129
  store i32 0, ptr %15, align 4
  br label %134

134:                                              ; preds = %133, %132
  call void @llvm.lifetime.end.p0(i64 1, ptr %13) #5
  %135 = load i32, ptr %15, align 4
  switch i32 %135, label %142 [
    i32 0, label %136
    i32 3, label %137
  ]

136:                                              ; preds = %134
  br label %48, !llvm.loop !29

137:                                              ; preds = %134, %48
  %138 = load float, ptr %6, align 4, !tbaa !9
  %139 = getelementptr inbounds %"class.NumericalODESolver::ImplicitEuler_NewtonIteration", ptr %19, i32 0, i32 3
  %140 = load float, ptr %139, align 8, !tbaa !21
  %141 = fadd float %140, %138
  store float %141, ptr %139, align 8, !tbaa !21
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  ret void

142:                                              ; preds = %134, %123
  unreachable
}

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #4

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"float", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = !{!14, !12, i64 92}
!14 = !{!"_ZTSN18NumericalODESolver29ImplicitEuler_NewtonIterationE", !15, i64 0, !15, i64 32, !17, i64 64, !10, i64 88, !12, i64 92, !10, i64 96}
!15 = !{!"_ZTSSt8functionIFvPKfifPfEE", !16, i64 0, !6, i64 24}
!16 = !{!"_ZTSSt14_Function_base", !7, i64 0, !6, i64 16}
!17 = !{!"_ZTSSt6vectorIfSaIfEE", !18, i64 0}
!18 = !{!"_ZTSSt12_Vector_baseIfSaIfEE", !19, i64 0}
!19 = !{!"_ZTSNSt12_Vector_baseIfSaIfEE12_Vector_implE", !20, i64 0}
!20 = !{!"_ZTSNSt12_Vector_baseIfSaIfEE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!21 = !{!14, !10, i64 88}
!22 = !{!23, !23, i64 0}
!23 = !{!"bool", !7, i64 0}
!24 = !{!14, !10, i64 96}
!25 = distinct !{!25, !26}
!26 = !{!"llvm.loop.mustprogress"}
!27 = !{i8 0, i8 2}
!28 = !{}
!29 = distinct !{!29, !26}


; 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 nounwind uwtable
declare dso_local noundef i64 @_ZNKSt6vectorIfSaIfEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIfSaIfEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIfSaIfEEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNKSt8functionIFvPKfifPfEEclES1_ifS2_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, i32 noundef, float noundef, ptr noundef) local_unnamed_addr #1 align 2

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN18NumericalODESolver29ImplicitEuler_NewtonIteration9IntegrateEfiPf(ptr noundef nonnull align 8 dereferenceable(100) %0, float noundef %1, i32 noundef %2, ptr noundef %3) local_unnamed_addr #1 align 2 {
  %5 = getelementptr inbounds i8, ptr %0, i64 64
  %6 = tail call noundef i64 @_ZNKSt6vectorIfSaIfEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #4
  %7 = mul nsw i32 %2, 3
  %8 = sext i32 %7 to i64
  %9 = icmp ult i64 %6, %8
  br i1 %9, label %10, label %11

10:                                               ; preds = %4
  tail call void @_ZNSt6vectorIfSaIfEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef %8)
  br label %11

11:                                               ; preds = %10, %4
  %12 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIfSaIfEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %5, i64 noundef 0) #4
  %13 = sext i32 %2 to i64
  %14 = getelementptr inbounds float, ptr %12, i64 %13
  %15 = shl nsw i32 %2, 1
  %16 = sext i32 %15 to i64
  %17 = getelementptr inbounds float, ptr %12, i64 %16
  %18 = shl nsw i64 %13, 2
  tail call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 4 %17, ptr align 4 %3, i64 %18, i1 false)
  %19 = getelementptr inbounds i8, ptr %0, i64 92
  %20 = getelementptr inbounds i8, ptr %0, i64 88
  %21 = getelementptr inbounds i8, ptr %0, i64 32
  %22 = icmp sgt i32 %2, 0
  %23 = fneg float %1
  %24 = getelementptr inbounds i8, ptr %0, i64 96
  br i1 %22, label %.split.us.preheader, label %.split

.split.us.preheader:                              ; preds = %11
  %wide.trip.count = zext nneg i32 %2 to i64
  br label %.split.us

.split.us:                                        ; preds = %.split.us.preheader, %._crit_edge.us
  %.0.us = phi i32 [ %25, %._crit_edge.us ], [ 0, %.split.us.preheader ]
  %25 = add nuw nsw i32 %.0.us, 1
  %26 = load i32, ptr %19, align 4, !tbaa !5
  %27 = icmp slt i32 %.0.us, %26
  br i1 %27, label %.lr.ph.us, label %.split48.us

.lr.ph.us:                                        ; preds = %.split.us
  %28 = load float, ptr %20, align 8, !tbaa !18
  tail call void @_ZNKSt8functionIFvPKfifPfEEclES1_ifS2_(ptr noundef nonnull align 8 dereferenceable(32) %0, ptr noundef %3, i32 noundef %2, float noundef %28, ptr noundef nonnull %12)
  %29 = load float, ptr %20, align 8, !tbaa !18
  tail call void @_ZNKSt8functionIFvPKfifPfEEclES1_ifS2_(ptr noundef nonnull align 8 dereferenceable(32) %21, ptr noundef %3, i32 noundef %2, float noundef %29, ptr noundef nonnull %14)
  br label %30

30:                                               ; preds = %.lr.ph.us, %48
  %indvars.iv = phi i64 [ 0, %.lr.ph.us ], [ %indvars.iv.next, %48 ]
  %.04146.us = phi i1 [ true, %.lr.ph.us ], [ %.1.us, %48 ]
  %31 = getelementptr inbounds float, ptr %3, i64 %indvars.iv
  %32 = load float, ptr %31, align 4, !tbaa !19
  %33 = getelementptr inbounds float, ptr %17, i64 %indvars.iv
  %34 = load float, ptr %33, align 4, !tbaa !19
  %35 = fsub float %32, %34
  %36 = getelementptr inbounds float, ptr %12, i64 %indvars.iv
  %37 = load float, ptr %36, align 4, !tbaa !19
  %38 = tail call float @llvm.fmuladd.f32(float %23, float %37, float %35)
  %39 = getelementptr inbounds float, ptr %14, i64 %indvars.iv
  %40 = load float, ptr %39, align 4, !tbaa !19
  %41 = tail call float @llvm.fmuladd.f32(float %23, float %40, float 1.000000e+00)
  %42 = fdiv float %38, %41
  %43 = tail call float @llvm.fabs.f32(float %42)
  %44 = load float, ptr %24, align 8, !tbaa !20
  %45 = fcmp olt float %43, %44
  br i1 %45, label %48, label %46

46:                                               ; preds = %30
  %47 = fsub float %32, %42
  store float %47, ptr %31, align 4, !tbaa !19
  br label %48

48:                                               ; preds = %46, %30
  %.1.us = phi i1 [ false, %46 ], [ %.04146.us, %30 ]
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count
  br i1 %exitcond.not, label %._crit_edge.us, label %30, !llvm.loop !21

._crit_edge.us:                                   ; preds = %48
  br i1 %.1.us, label %.split48.us, label %.split.us

.split:                                           ; preds = %11
  %49 = load i32, ptr %19, align 4, !tbaa !5
  %50 = icmp sgt i32 %49, 0
  br i1 %50, label %51, label %.split48.us

51:                                               ; preds = %.split
  %52 = load float, ptr %20, align 8, !tbaa !18
  tail call void @_ZNKSt8functionIFvPKfifPfEEclES1_ifS2_(ptr noundef nonnull align 8 dereferenceable(32) %0, ptr noundef %3, i32 noundef %2, float noundef %52, ptr noundef nonnull %12)
  %53 = load float, ptr %20, align 8, !tbaa !18
  tail call void @_ZNKSt8functionIFvPKfifPfEEclES1_ifS2_(ptr noundef nonnull align 8 dereferenceable(32) %21, ptr noundef %3, i32 noundef %2, float noundef %53, ptr noundef nonnull %14)
  br label %.split48.us

.split48.us:                                      ; preds = %.split.us, %._crit_edge.us, %.split, %51
  %54 = load float, ptr %20, align 8, !tbaa !18
  %55 = fadd float %54, %1
  store float %55, ptr %20, align 8, !tbaa !18
  ret void
}

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #3

attributes #0 = { 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 #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 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !17, i64 92}
!6 = !{!"_ZTSN18NumericalODESolver29ImplicitEuler_NewtonIterationE", !7, i64 0, !7, i64 32, !12, i64 64, !16, i64 88, !17, i64 92, !16, i64 96}
!7 = !{!"_ZTSSt8functionIFvPKfifPfEE", !8, i64 0, !11, i64 24}
!8 = !{!"_ZTSSt14_Function_base", !9, i64 0, !11, i64 16}
!9 = !{!"omnipotent char", !10, i64 0}
!10 = !{!"Simple C++ TBAA"}
!11 = !{!"any pointer", !9, i64 0}
!12 = !{!"_ZTSSt6vectorIfSaIfEE", !13, i64 0}
!13 = !{!"_ZTSSt12_Vector_baseIfSaIfEE", !14, i64 0}
!14 = !{!"_ZTSNSt12_Vector_baseIfSaIfEE12_Vector_implE", !15, i64 0}
!15 = !{!"_ZTSNSt12_Vector_baseIfSaIfEE17_Vector_impl_dataE", !11, i64 0, !11, i64 8, !11, i64 16}
!16 = !{!"float", !9, i64 0}
!17 = !{!"int", !9, i64 0}
!18 = !{!6, !16, i64 88}
!19 = !{!16, !16, i64 0}
!20 = !{!6, !16, i64 96}
!21 = distinct !{!21, !22}
!22 = !{!"llvm.loop.mustprogress"}


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