; LLVM IR from venumb/ZSPACE :: cpp/depends/alglib/cpp/src (alglibinternal)

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

%"struct.alglib_impl::ae_frame" = type { %"struct.alglib_impl::ae_dyn_block" }
%"struct.alglib_impl::ae_dyn_block" = type { ptr, ptr, ptr, ptr }
%"struct.alglib_impl::ae_matrix" = type { i64, i64, i64, i64, i8, %"struct.alglib_impl::ae_dyn_block", %union.anon.0 }
%union.anon.0 = type { 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

declare void @_ZN11alglib_impl20ae_matrix_set_lengthEPNS_9ae_matrixEllPNS_8ae_stateE(ptr noundef, i64 noundef, i64 noundef, ptr noundef) #2

declare void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef, ptr noundef) #2

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #3

declare void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef) #2

declare noundef i64 @_ZN11alglib_impl9ae_maxintEllPNS_8ae_stateE(i64 noundef, i64 noundef, ptr noundef) #2

declare noundef i64 @_ZN11alglib_impl8ae_roundEdPNS_8ae_stateE(double noundef, ptr noundef) #2

declare void @_ZN11alglib_impl14ae_matrix_initEPNS_9ae_matrixElllPNS_8ae_stateEb(ptr noundef, i64 noundef, i64 noundef, i64 noundef, ptr noundef, i1 noundef zeroext) #2

declare noundef i64 @_ZN11alglib_impl9ae_minintEllPNS_8ae_stateE(i64 noundef, i64 noundef, ptr noundef) #2

declare void @_ZN11alglib_impl16ae_swap_matricesEPNS_9ae_matrixES1_(ptr noundef, ptr noundef) #2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN11alglib_impl17rmatrixgrowcolstoEPNS_9ae_matrixEllPNS_8ae_stateE(ptr noundef %0, i64 noundef %1, i64 noundef %2, ptr noundef %3) #4 {
  %5 = alloca ptr, align 8
  %6 = alloca i64, align 8
  %7 = alloca i64, align 8
  %8 = alloca ptr, align 8
  %9 = alloca %"struct.alglib_impl::ae_frame", align 8
  %10 = alloca %"struct.alglib_impl::ae_matrix", align 8
  %11 = alloca i64, align 8
  %12 = alloca i64, align 8
  %13 = alloca i64, align 8
  %14 = alloca i64, align 8
  %15 = alloca i32, align 4
  store ptr %0, ptr %5, align 8, !tbaa !5
  store i64 %1, ptr %6, align 8, !tbaa !9
  store i64 %2, ptr %7, align 8, !tbaa !9
  store ptr %3, ptr %8, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr %9) #5
  call void @llvm.lifetime.start.p0(i64 80, ptr %10) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #5
  %16 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef %16, ptr noundef %9)
  call void @llvm.memset.p0.i64(ptr align 8 %10, i8 0, i64 80, i1 false)
  %17 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_matrix_initEPNS_9ae_matrixElllPNS_8ae_stateEb(ptr noundef %10, i64 noundef 0, i64 noundef 0, i64 noundef 3, ptr noundef %17, i1 noundef zeroext true)
  %18 = load ptr, ptr %5, align 8, !tbaa !5
  %19 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %18, i32 0, i32 1
  %20 = load i64, ptr %19, align 8, !tbaa !11
  %21 = load i64, ptr %6, align 8, !tbaa !9
  %22 = icmp sge i64 %20, %21
  br i1 %22, label %23, label %31

23:                                               ; preds = %4
  %24 = load ptr, ptr %5, align 8, !tbaa !5
  %25 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %24, i32 0, i32 0
  %26 = load i64, ptr %25, align 8, !tbaa !15
  %27 = load i64, ptr %7, align 8, !tbaa !9
  %28 = icmp sge i64 %26, %27
  br i1 %28, label %29, label %31

29:                                               ; preds = %23
  %30 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %30)
  store i32 1, ptr %15, align 4
  br label %103

31:                                               ; preds = %23, %4
  %32 = load ptr, ptr %5, align 8, !tbaa !5
  %33 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %32, i32 0, i32 1
  %34 = load i64, ptr %33, align 8, !tbaa !11
  %35 = load i64, ptr %6, align 8, !tbaa !9
  %36 = icmp slt i64 %34, %35
  br i1 %36, label %37, label %48

37:                                               ; preds = %31
  %38 = load i64, ptr %6, align 8, !tbaa !9
  %39 = load ptr, ptr %5, align 8, !tbaa !5
  %40 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %39, i32 0, i32 1
  %41 = load i64, ptr %40, align 8, !tbaa !11
  %42 = sitofp i64 %41 to double
  %43 = call double @llvm.fmuladd.f64(double 1.800000e+00, double %42, double 1.000000e+00)
  %44 = load ptr, ptr %8, align 8, !tbaa !5
  %45 = call noundef i64 @_ZN11alglib_impl8ae_roundEdPNS_8ae_stateE(double noundef %43, ptr noundef %44)
  %46 = load ptr, ptr %8, align 8, !tbaa !5
  %47 = call noundef i64 @_ZN11alglib_impl9ae_maxintEllPNS_8ae_stateE(i64 noundef %38, i64 noundef %45, ptr noundef %46)
  store i64 %47, ptr %6, align 8, !tbaa !9
  br label %48

48:                                               ; preds = %37, %31
  %49 = load ptr, ptr %5, align 8, !tbaa !5
  %50 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %49, i32 0, i32 1
  %51 = load i64, ptr %50, align 8, !tbaa !11
  %52 = load i64, ptr %6, align 8, !tbaa !9
  %53 = load ptr, ptr %8, align 8, !tbaa !5
  %54 = call noundef i64 @_ZN11alglib_impl9ae_minintEllPNS_8ae_stateE(i64 noundef %51, i64 noundef %52, ptr noundef %53)
  store i64 %54, ptr %13, align 8, !tbaa !9
  %55 = load ptr, ptr %5, align 8, !tbaa !5
  %56 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %55, i32 0, i32 0
  %57 = load i64, ptr %56, align 8, !tbaa !15
  store i64 %57, ptr %14, align 8, !tbaa !9
  %58 = load ptr, ptr %5, align 8, !tbaa !5
  call void @_ZN11alglib_impl16ae_swap_matricesEPNS_9ae_matrixES1_(ptr noundef %58, ptr noundef %10)
  %59 = load ptr, ptr %5, align 8, !tbaa !5
  %60 = load i64, ptr %14, align 8, !tbaa !9
  %61 = load i64, ptr %7, align 8, !tbaa !9
  %62 = load ptr, ptr %8, align 8, !tbaa !5
  %63 = call noundef i64 @_ZN11alglib_impl9ae_maxintEllPNS_8ae_stateE(i64 noundef %60, i64 noundef %61, ptr noundef %62)
  %64 = load i64, ptr %6, align 8, !tbaa !9
  %65 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl20ae_matrix_set_lengthEPNS_9ae_matrixEllPNS_8ae_stateE(ptr noundef %59, i64 noundef %63, i64 noundef %64, ptr noundef %65)
  store i64 0, ptr %11, align 8, !tbaa !9
  br label %66

66:                                               ; preds = %98, %48
  %67 = load i64, ptr %11, align 8, !tbaa !9
  %68 = load i64, ptr %14, align 8, !tbaa !9
  %69 = sub nsw i64 %68, 1
  %70 = icmp sle i64 %67, %69
  br i1 %70, label %71, label %101

71:                                               ; preds = %66
  store i64 0, ptr %12, align 8, !tbaa !9
  br label %72

72:                                               ; preds = %94, %71
  %73 = load i64, ptr %12, align 8, !tbaa !9
  %74 = load i64, ptr %13, align 8, !tbaa !9
  %75 = sub nsw i64 %74, 1
  %76 = icmp sle i64 %73, %75
  br i1 %76, label %77, label %97

77:                                               ; preds = %72
  %78 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %10, i32 0, i32 6
  %79 = load ptr, ptr %78, align 8, !tbaa !16
  %80 = load i64, ptr %11, align 8, !tbaa !9
  %81 = getelementptr inbounds ptr, ptr %79, i64 %80
  %82 = load ptr, ptr %81, align 8, !tbaa !5
  %83 = load i64, ptr %12, align 8, !tbaa !9
  %84 = getelementptr inbounds double, ptr %82, i64 %83
  %85 = load double, ptr %84, align 8, !tbaa !17
  %86 = load ptr, ptr %5, align 8, !tbaa !5
  %87 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %86, i32 0, i32 6
  %88 = load ptr, ptr %87, align 8, !tbaa !16
  %89 = load i64, ptr %11, align 8, !tbaa !9
  %90 = getelementptr inbounds ptr, ptr %88, i64 %89
  %91 = load ptr, ptr %90, align 8, !tbaa !5
  %92 = load i64, ptr %12, align 8, !tbaa !9
  %93 = getelementptr inbounds double, ptr %91, i64 %92
  store double %85, ptr %93, align 8, !tbaa !17
  br label %94

94:                                               ; preds = %77
  %95 = load i64, ptr %12, align 8, !tbaa !9
  %96 = add nsw i64 %95, 1
  store i64 %96, ptr %12, align 8, !tbaa !9
  br label %72, !llvm.loop !19

97:                                               ; preds = %72
  br label %98

98:                                               ; preds = %97
  %99 = load i64, ptr %11, align 8, !tbaa !9
  %100 = add nsw i64 %99, 1
  store i64 %100, ptr %11, align 8, !tbaa !9
  br label %66, !llvm.loop !21

101:                                              ; preds = %66
  %102 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %102)
  store i32 0, ptr %15, align 4
  br label %103

103:                                              ; preds = %101, %29
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 80, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr %9) #5
  %104 = load i32, ptr %15, align 4
  switch i32 %104, label %106 [
    i32 0, label %105
    i32 1, label %105
  ]

105:                                              ; preds = %103, %103
  ret void

106:                                              ; preds = %103
  unreachable
}

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #2 = { "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 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #4 = { 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 #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 = !{!"long", !7, i64 0}
!11 = !{!12, !10, i64 8}
!12 = !{!"_ZTSN11alglib_impl9ae_matrixE", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !13, i64 32, !14, i64 40, !7, i64 72}
!13 = !{!"bool", !7, i64 0}
!14 = !{!"_ZTSN11alglib_impl12ae_dyn_blockE", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24}
!15 = !{!12, !10, i64 0}
!16 = !{!7, !7, i64 0}
!17 = !{!18, !18, i64 0}
!18 = !{!"double", !7, i64 0}
!19 = distinct !{!19, !20}
!20 = !{!"llvm.loop.mustprogress"}
!21 = distinct !{!21, !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"

%"struct.alglib_impl::ae_frame" = type { %"struct.alglib_impl::ae_dyn_block" }
%"struct.alglib_impl::ae_dyn_block" = type { ptr, ptr, ptr, ptr }
%"struct.alglib_impl::ae_matrix" = type { i64, i64, i64, i64, i8, %"struct.alglib_impl::ae_dyn_block", %union.anon.0 }
%union.anon.0 = type { ptr }

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

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

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

declare void @_ZN11alglib_impl20ae_matrix_set_lengthEPNS_9ae_matrixEllPNS_8ae_stateE(ptr noundef, i64 noundef, i64 noundef, ptr noundef) local_unnamed_addr #2

declare void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef, ptr noundef) local_unnamed_addr #2

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

declare void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef) local_unnamed_addr #2

declare noundef i64 @_ZN11alglib_impl9ae_maxintEllPNS_8ae_stateE(i64 noundef, i64 noundef, ptr noundef) local_unnamed_addr #2

declare noundef i64 @_ZN11alglib_impl8ae_roundEdPNS_8ae_stateE(double noundef, ptr noundef) local_unnamed_addr #2

declare void @_ZN11alglib_impl14ae_matrix_initEPNS_9ae_matrixElllPNS_8ae_stateEb(ptr noundef, i64 noundef, i64 noundef, i64 noundef, ptr noundef, i1 noundef zeroext) local_unnamed_addr #2

declare noundef i64 @_ZN11alglib_impl9ae_minintEllPNS_8ae_stateE(i64 noundef, i64 noundef, ptr noundef) local_unnamed_addr #2

declare void @_ZN11alglib_impl16ae_swap_matricesEPNS_9ae_matrixES1_(ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN11alglib_impl17rmatrixgrowcolstoEPNS_9ae_matrixEllPNS_8ae_stateE(ptr noundef %0, i64 noundef %1, i64 noundef %2, ptr noundef %3) local_unnamed_addr #4 {
  %5 = alloca %"struct.alglib_impl::ae_frame", align 8
  %6 = alloca %"struct.alglib_impl::ae_matrix", align 8
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %5) #5
  call void @llvm.lifetime.start.p0(i64 80, ptr nonnull %6) #5
  call void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef %3, ptr noundef nonnull %5)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(80) %6, i8 0, i64 80, i1 false)
  call void @_ZN11alglib_impl14ae_matrix_initEPNS_9ae_matrixElllPNS_8ae_stateEb(ptr noundef nonnull %6, i64 noundef 0, i64 noundef 0, i64 noundef 3, ptr noundef %3, i1 noundef zeroext true)
  %7 = getelementptr inbounds i8, ptr %0, i64 8
  %8 = load i64, ptr %7, align 8, !tbaa !5
  %.not = icmp slt i64 %8, %1
  br i1 %.not, label %11, label %9

9:                                                ; preds = %4
  %10 = load i64, ptr %0, align 8, !tbaa !13
  %.not39 = icmp slt i64 %10, %2
  br i1 %.not39, label %16, label %._crit_edge46

11:                                               ; preds = %4
  %12 = sitofp i64 %8 to double
  %13 = call double @llvm.fmuladd.f64(double %12, double 1.800000e+00, double 1.000000e+00)
  %14 = call noundef i64 @_ZN11alglib_impl8ae_roundEdPNS_8ae_stateE(double noundef %13, ptr noundef %3)
  %15 = call noundef i64 @_ZN11alglib_impl9ae_maxintEllPNS_8ae_stateE(i64 noundef %1, i64 noundef %14, ptr noundef %3)
  %.pre = load i64, ptr %7, align 8, !tbaa !5
  br label %16

16:                                               ; preds = %9, %11
  %17 = phi i64 [ %.pre, %11 ], [ %8, %9 ]
  %.0 = phi i64 [ %15, %11 ], [ %1, %9 ]
  %18 = call noundef i64 @_ZN11alglib_impl9ae_minintEllPNS_8ae_stateE(i64 noundef %17, i64 noundef %.0, ptr noundef %3)
  %19 = load i64, ptr %0, align 8, !tbaa !13
  call void @_ZN11alglib_impl16ae_swap_matricesEPNS_9ae_matrixES1_(ptr noundef nonnull %0, ptr noundef nonnull %6)
  %20 = call noundef i64 @_ZN11alglib_impl9ae_maxintEllPNS_8ae_stateE(i64 noundef %19, i64 noundef %2, ptr noundef %3)
  call void @_ZN11alglib_impl20ae_matrix_set_lengthEPNS_9ae_matrixEllPNS_8ae_stateE(ptr noundef nonnull %0, i64 noundef %20, i64 noundef %.0, ptr noundef %3)
  %.not40.not44 = icmp sgt i64 %19, 0
  br i1 %.not40.not44, label %.preheader.lr.ph, label %._crit_edge46

.preheader.lr.ph:                                 ; preds = %16
  %.not41.not42 = icmp sgt i64 %18, 0
  %21 = getelementptr inbounds i8, ptr %6, i64 72
  %22 = getelementptr inbounds i8, ptr %0, i64 72
  br i1 %.not41.not42, label %.preheader.us.preheader, label %._crit_edge46

.preheader.us.preheader:                          ; preds = %.preheader.lr.ph
  %xtraiter = and i64 %18, 1
  %23 = icmp eq i64 %18, 1
  %unroll_iter = and i64 %18, 9223372036854775806
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br label %.preheader.us

.preheader.us:                                    ; preds = %.preheader.us.preheader, %._crit_edge.us
  %.03545.us = phi i64 [ %53, %._crit_edge.us ], [ 0, %.preheader.us.preheader ]
  br i1 %23, label %._crit_edge.us.unr-lcssa, label %.preheader.us.new

.preheader.us.new:                                ; preds = %.preheader.us, %.preheader.us.new
  %.03643.us = phi i64 [ %43, %.preheader.us.new ], [ 0, %.preheader.us ]
  %niter = phi i64 [ %niter.next.1, %.preheader.us.new ], [ 0, %.preheader.us ]
  %24 = load ptr, ptr %21, align 8, !tbaa !14
  %25 = getelementptr inbounds ptr, ptr %24, i64 %.03545.us
  %26 = load ptr, ptr %25, align 8, !tbaa !15
  %27 = getelementptr inbounds double, ptr %26, i64 %.03643.us
  %28 = load double, ptr %27, align 8, !tbaa !16
  %29 = load ptr, ptr %22, align 8, !tbaa !14
  %30 = getelementptr inbounds ptr, ptr %29, i64 %.03545.us
  %31 = load ptr, ptr %30, align 8, !tbaa !15
  %32 = getelementptr inbounds double, ptr %31, i64 %.03643.us
  store double %28, ptr %32, align 8, !tbaa !16
  %33 = or disjoint i64 %.03643.us, 1
  %34 = load ptr, ptr %21, align 8, !tbaa !14
  %35 = getelementptr inbounds ptr, ptr %34, i64 %.03545.us
  %36 = load ptr, ptr %35, align 8, !tbaa !15
  %37 = getelementptr inbounds double, ptr %36, i64 %33
  %38 = load double, ptr %37, align 8, !tbaa !16
  %39 = load ptr, ptr %22, align 8, !tbaa !14
  %40 = getelementptr inbounds ptr, ptr %39, i64 %.03545.us
  %41 = load ptr, ptr %40, align 8, !tbaa !15
  %42 = getelementptr inbounds double, ptr %41, i64 %33
  store double %38, ptr %42, align 8, !tbaa !16
  %43 = add nuw nsw i64 %.03643.us, 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 %.preheader.us.new, !llvm.loop !18

._crit_edge.us.unr-lcssa:                         ; preds = %.preheader.us.new, %.preheader.us
  %.03643.us.unr = phi i64 [ 0, %.preheader.us ], [ %43, %.preheader.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
  %44 = load ptr, ptr %21, align 8, !tbaa !14
  %45 = getelementptr inbounds ptr, ptr %44, i64 %.03545.us
  %46 = load ptr, ptr %45, align 8, !tbaa !15
  %47 = getelementptr inbounds double, ptr %46, i64 %.03643.us.unr
  %48 = load double, ptr %47, align 8, !tbaa !16
  %49 = load ptr, ptr %22, align 8, !tbaa !14
  %50 = getelementptr inbounds ptr, ptr %49, i64 %.03545.us
  %51 = load ptr, ptr %50, align 8, !tbaa !15
  %52 = getelementptr inbounds double, ptr %51, i64 %.03643.us.unr
  store double %48, ptr %52, align 8, !tbaa !16
  br label %._crit_edge.us

._crit_edge.us:                                   ; preds = %._crit_edge.us.unr-lcssa, %._crit_edge.us.epilog-lcssa
  %53 = add nuw nsw i64 %.03545.us, 1
  %exitcond48.not = icmp eq i64 %53, %19
  br i1 %exitcond48.not, label %._crit_edge46, label %.preheader.us, !llvm.loop !20

._crit_edge46:                                    ; preds = %._crit_edge.us, %16, %.preheader.lr.ph, %9
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %3)
  call void @llvm.lifetime.end.p0(i64 80, ptr nonnull %6) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #5
  ret void
}

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #2 = { "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 nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #4 = { 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 #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, !7, i64 8}
!6 = !{!"_ZTSN11alglib_impl9ae_matrixE", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !10, i64 32, !11, i64 40, !8, i64 72}
!7 = !{!"long", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"bool", !8, i64 0}
!11 = !{!"_ZTSN11alglib_impl12ae_dyn_blockE", !12, i64 0, !12, i64 8, !12, i64 16, !12, i64 24}
!12 = !{!"any pointer", !8, i64 0}
!13 = !{!6, !7, i64 0}
!14 = !{!8, !8, i64 0}
!15 = !{!12, !12, i64 0}
!16 = !{!17, !17, i64 0}
!17 = !{!"double", !8, i64 0}
!18 = distinct !{!18, !19}
!19 = !{!"llvm.loop.mustprogress"}
!20 = distinct !{!20, !19}


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