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

; 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_vector" = type { i64, i64, i8, %"struct.alglib_impl::ae_dyn_block", %union.anon.1 }
%union.anon.1 = type { 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 nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #1

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

declare void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef) #2

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

declare void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef) #2

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

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

declare noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef, i64 noundef) #2

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

declare noundef zeroext i1 @_ZN11alglib_impl8ae_fp_eqEdd(double noundef, double noundef) #2

declare noundef double @_ZN11alglib_impl7ae_sqrtEdPNS_8ae_stateE(double noundef, ptr noundef) #2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN11alglib_impl12dsnormalizecEPNS_9ae_matrixEllPlPNS_9ae_vectorES4_PNS_8ae_stateE(ptr noundef %0, i64 noundef %1, i64 noundef %2, ptr noundef %3, ptr noundef %4, ptr noundef %5, ptr noundef %6) #3 {
  %8 = alloca ptr, align 8
  %9 = alloca i64, align 8
  %10 = alloca i64, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  %15 = alloca %"struct.alglib_impl::ae_frame", align 8
  %16 = alloca i64, align 8
  %17 = alloca %"struct.alglib_impl::ae_vector", align 8
  %18 = alloca double, align 8
  %19 = alloca double, align 8
  %20 = alloca double, align 8
  %21 = alloca double, align 8
  %22 = alloca i32, align 4
  store ptr %0, ptr %8, align 8, !tbaa !5
  store i64 %1, ptr %9, align 8, !tbaa !9
  store i64 %2, ptr %10, align 8, !tbaa !9
  store ptr %3, ptr %11, align 8, !tbaa !5
  store ptr %4, ptr %12, align 8, !tbaa !5
  store ptr %5, ptr %13, align 8, !tbaa !5
  store ptr %6, ptr %14, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr %15) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr %17) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #4
  %23 = load ptr, ptr %14, align 8, !tbaa !5
  call void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef %23, ptr noundef %15)
  call void @llvm.memset.p0.i64(ptr align 8 %17, i8 0, i64 64, i1 false)
  %24 = load ptr, ptr %11, align 8, !tbaa !5
  store i64 0, ptr %24, align 8, !tbaa !9
  %25 = load ptr, ptr %12, align 8, !tbaa !5
  call void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef %25)
  %26 = load ptr, ptr %13, align 8, !tbaa !5
  call void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef %26)
  %27 = load ptr, ptr %14, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef %17, i64 noundef 0, i64 noundef 3, ptr noundef %27, i1 noundef zeroext true)
  %28 = load i64, ptr %9, align 8, !tbaa !9
  %29 = icmp sle i64 %28, 0
  br i1 %29, label %33, label %30

30:                                               ; preds = %7
  %31 = load i64, ptr %10, align 8, !tbaa !9
  %32 = icmp slt i64 %31, 1
  br i1 %32, label %33, label %36

33:                                               ; preds = %30, %7
  %34 = load ptr, ptr %11, align 8, !tbaa !5
  store i64 -1, ptr %34, align 8, !tbaa !9
  %35 = load ptr, ptr %14, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %35)
  store i32 1, ptr %22, align 4
  br label %109

36:                                               ; preds = %30
  %37 = load ptr, ptr %11, align 8, !tbaa !5
  store i64 1, ptr %37, align 8, !tbaa !9
  %38 = load ptr, ptr %12, align 8, !tbaa !5
  %39 = load i64, ptr %10, align 8, !tbaa !9
  %40 = sub nsw i64 %39, 1
  %41 = add nsw i64 %40, 1
  %42 = load ptr, ptr %14, align 8, !tbaa !5
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %38, i64 noundef %41, ptr noundef %42)
  %43 = load ptr, ptr %13, align 8, !tbaa !5
  %44 = load i64, ptr %10, align 8, !tbaa !9
  %45 = sub nsw i64 %44, 1
  %46 = add nsw i64 %45, 1
  %47 = load ptr, ptr %14, align 8, !tbaa !5
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %43, i64 noundef %46, ptr noundef %47)
  %48 = load i64, ptr %9, align 8, !tbaa !9
  %49 = sub nsw i64 %48, 1
  %50 = add nsw i64 %49, 1
  %51 = load ptr, ptr %14, align 8, !tbaa !5
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %17, i64 noundef %50, ptr noundef %51)
  store i64 0, ptr %16, align 8, !tbaa !9
  br label %52

52:                                               ; preds = %104, %36
  %53 = load i64, ptr %16, align 8, !tbaa !9
  %54 = load i64, ptr %10, align 8, !tbaa !9
  %55 = sub nsw i64 %54, 1
  %56 = icmp sle i64 %53, %55
  br i1 %56, label %57, label %107

57:                                               ; preds = %52
  %58 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %17, i32 0, i32 4
  %59 = load ptr, ptr %58, align 8, !tbaa !11
  %60 = getelementptr inbounds double, ptr %59, i64 0
  %61 = load ptr, ptr %8, align 8, !tbaa !5
  %62 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %61, i32 0, i32 6
  %63 = load ptr, ptr %62, align 8, !tbaa !11
  %64 = getelementptr inbounds ptr, ptr %63, i64 0
  %65 = load ptr, ptr %64, align 8, !tbaa !5
  %66 = load i64, ptr %16, align 8, !tbaa !9
  %67 = getelementptr inbounds double, ptr %65, i64 %66
  %68 = load ptr, ptr %8, align 8, !tbaa !5
  %69 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %68, i32 0, i32 2
  %70 = load i64, ptr %69, align 8, !tbaa !12
  %71 = load i64, ptr %9, align 8, !tbaa !9
  %72 = sub nsw i64 %71, 1
  %73 = call noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef 0, i64 noundef %72)
  call void @_ZN11alglib_impl9ae_v_moveEPdlPKdll(ptr noundef %60, i64 noundef 1, ptr noundef %67, i64 noundef %70, i64 noundef %73)
  %74 = load i64, ptr %9, align 8, !tbaa !9
  %75 = load ptr, ptr %14, align 8, !tbaa !5
  call void @_ZN11alglib_impl13samplemomentsEPNS_9ae_vectorElPdS2_S2_S2_PNS_8ae_stateE(ptr noundef %17, i64 noundef %74, ptr noundef %18, ptr noundef %19, ptr noundef %20, ptr noundef %21, ptr noundef %75)
  %76 = load double, ptr %18, align 8, !tbaa !16
  %77 = load ptr, ptr %12, align 8, !tbaa !5
  %78 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %77, i32 0, i32 4
  %79 = load ptr, ptr %78, align 8, !tbaa !11
  %80 = load i64, ptr %16, align 8, !tbaa !9
  %81 = getelementptr inbounds double, ptr %79, i64 %80
  store double %76, ptr %81, align 8, !tbaa !16
  %82 = load double, ptr %19, align 8, !tbaa !16
  %83 = load ptr, ptr %14, align 8, !tbaa !5
  %84 = call noundef double @_ZN11alglib_impl7ae_sqrtEdPNS_8ae_stateE(double noundef %82, ptr noundef %83)
  %85 = load ptr, ptr %13, align 8, !tbaa !5
  %86 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %85, i32 0, i32 4
  %87 = load ptr, ptr %86, align 8, !tbaa !11
  %88 = load i64, ptr %16, align 8, !tbaa !9
  %89 = getelementptr inbounds double, ptr %87, i64 %88
  store double %84, ptr %89, align 8, !tbaa !16
  %90 = load ptr, ptr %13, align 8, !tbaa !5
  %91 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %90, i32 0, i32 4
  %92 = load ptr, ptr %91, align 8, !tbaa !11
  %93 = load i64, ptr %16, align 8, !tbaa !9
  %94 = getelementptr inbounds double, ptr %92, i64 %93
  %95 = load double, ptr %94, align 8, !tbaa !16
  %96 = call noundef zeroext i1 @_ZN11alglib_impl8ae_fp_eqEdd(double noundef %95, double noundef 0.000000e+00)
  br i1 %96, label %97, label %103

97:                                               ; preds = %57
  %98 = load ptr, ptr %13, align 8, !tbaa !5
  %99 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %98, i32 0, i32 4
  %100 = load ptr, ptr %99, align 8, !tbaa !11
  %101 = load i64, ptr %16, align 8, !tbaa !9
  %102 = getelementptr inbounds double, ptr %100, i64 %101
  store double 1.000000e+00, ptr %102, align 8, !tbaa !16
  br label %103

103:                                              ; preds = %97, %57
  br label %104

104:                                              ; preds = %103
  %105 = load i64, ptr %16, align 8, !tbaa !9
  %106 = add nsw i64 %105, 1
  store i64 %106, ptr %16, align 8, !tbaa !9
  br label %52, !llvm.loop !18

107:                                              ; preds = %52
  %108 = load ptr, ptr %14, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %108)
  store i32 0, ptr %22, align 4
  br label %109

109:                                              ; preds = %107, %33
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr %17) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #4
  call void @llvm.lifetime.end.p0(i64 32, ptr %15) #4
  %110 = load i32, ptr %22, align 4
  switch i32 %110, label %112 [
    i32 0, label %111
    i32 1, label %111
  ]

111:                                              ; preds = %109, %109
  ret void

112:                                              ; preds = %109
  unreachable
}

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


; 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_vector" = type { i64, i64, i8, %"struct.alglib_impl::ae_dyn_block", %union.anon.1 }
%union.anon.1 = 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 nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #1

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

declare void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef) local_unnamed_addr #2

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

declare void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef) local_unnamed_addr #2

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

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

declare noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef, i64 noundef) local_unnamed_addr #2

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

declare noundef zeroext i1 @_ZN11alglib_impl8ae_fp_eqEdd(double noundef, double noundef) local_unnamed_addr #2

declare noundef double @_ZN11alglib_impl7ae_sqrtEdPNS_8ae_stateE(double noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN11alglib_impl12dsnormalizecEPNS_9ae_matrixEllPlPNS_9ae_vectorES4_PNS_8ae_stateE(ptr nocapture noundef readonly %0, i64 noundef %1, i64 noundef %2, ptr nocapture noundef writeonly %3, ptr noundef %4, ptr noundef %5, ptr noundef %6) local_unnamed_addr #3 {
  %8 = alloca %"struct.alglib_impl::ae_frame", align 8
  %9 = alloca %"struct.alglib_impl::ae_vector", align 8
  %10 = alloca double, align 8
  %11 = alloca double, align 8
  %12 = alloca double, align 8
  %13 = alloca double, align 8
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %8) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %9) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %11) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %12) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %13) #4
  call void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef %6, ptr noundef nonnull %8)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %9, i8 0, i64 64, i1 false)
  store i64 0, ptr %3, align 8, !tbaa !5
  call void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef %4)
  call void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef %5)
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef nonnull %9, i64 noundef 0, i64 noundef 3, ptr noundef %6, i1 noundef zeroext true)
  %14 = icmp slt i64 %1, 1
  %15 = icmp slt i64 %2, 1
  %or.cond = or i1 %14, %15
  br i1 %or.cond, label %16, label %17

16:                                               ; preds = %7
  store i64 -1, ptr %3, align 8, !tbaa !5
  br label %.loopexit

17:                                               ; preds = %7
  store i64 1, ptr %3, align 8, !tbaa !5
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %4, i64 noundef %2, ptr noundef %6)
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %5, i64 noundef %2, ptr noundef %6)
  %18 = add nsw i64 %1, -1
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %9, i64 noundef %1, ptr noundef %6)
  %19 = getelementptr inbounds i8, ptr %9, i64 56
  %20 = getelementptr inbounds i8, ptr %0, i64 72
  %21 = getelementptr inbounds i8, ptr %0, i64 16
  %22 = getelementptr inbounds i8, ptr %4, i64 56
  %23 = getelementptr inbounds i8, ptr %5, i64 56
  br label %24

24:                                               ; preds = %17, %45
  %.039 = phi i64 [ 0, %17 ], [ %46, %45 ]
  %25 = load ptr, ptr %19, align 8, !tbaa !9
  %26 = load ptr, ptr %20, align 8, !tbaa !9
  %27 = load ptr, ptr %26, align 8, !tbaa !10
  %28 = getelementptr inbounds double, ptr %27, i64 %.039
  %29 = load i64, ptr %21, align 8, !tbaa !12
  %30 = call noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef 0, i64 noundef %18)
  call void @_ZN11alglib_impl9ae_v_moveEPdlPKdll(ptr noundef %25, i64 noundef 1, ptr noundef %28, i64 noundef %29, i64 noundef %30)
  call void @_ZN11alglib_impl13samplemomentsEPNS_9ae_vectorElPdS2_S2_S2_PNS_8ae_stateE(ptr noundef nonnull %9, i64 noundef %1, ptr noundef nonnull %10, ptr noundef nonnull %11, ptr noundef nonnull %12, ptr noundef nonnull %13, ptr noundef %6)
  %31 = load double, ptr %10, align 8, !tbaa !16
  %32 = load ptr, ptr %22, align 8, !tbaa !9
  %33 = getelementptr inbounds double, ptr %32, i64 %.039
  store double %31, ptr %33, align 8, !tbaa !16
  %34 = load double, ptr %11, align 8, !tbaa !16
  %35 = call noundef double @_ZN11alglib_impl7ae_sqrtEdPNS_8ae_stateE(double noundef %34, ptr noundef %6)
  %36 = load ptr, ptr %23, align 8, !tbaa !9
  %37 = getelementptr inbounds double, ptr %36, i64 %.039
  store double %35, ptr %37, align 8, !tbaa !16
  %38 = load ptr, ptr %23, align 8, !tbaa !9
  %39 = getelementptr inbounds double, ptr %38, i64 %.039
  %40 = load double, ptr %39, align 8, !tbaa !16
  %41 = call noundef zeroext i1 @_ZN11alglib_impl8ae_fp_eqEdd(double noundef %40, double noundef 0.000000e+00)
  br i1 %41, label %42, label %45

42:                                               ; preds = %24
  %43 = load ptr, ptr %23, align 8, !tbaa !9
  %44 = getelementptr inbounds double, ptr %43, i64 %.039
  store double 1.000000e+00, ptr %44, align 8, !tbaa !16
  br label %45

45:                                               ; preds = %24, %42
  %46 = add nuw nsw i64 %.039, 1
  %exitcond.not = icmp eq i64 %46, %2
  br i1 %exitcond.not, label %.loopexit, label %24, !llvm.loop !18

.loopexit:                                        ; preds = %45, %16
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %6)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %9) #4
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %8) #4
  ret void
}

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


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass