; 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::logitmodel" = type { %"struct.alglib_impl::ae_vector" }
%"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 }

@_ZN11alglib_implL15logit_logitvnumE = external hidden global i64, align 8
@.str.289 = external hidden unnamed_addr constant [38 x i8], align 1

; 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_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext, ptr noundef, ptr noundef) #2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN11alglib_impl10mnlprocessEPNS_10logitmodelEPNS_9ae_vectorES3_PNS_8ae_stateE(ptr noundef, ptr noundef, ptr noundef, ptr noundef) #3

; Function Attrs: mustprogress uwtable
define dso_local noundef i64 @_ZN11alglib_impl11mnlclserrorEPNS_10logitmodelEPNS_9ae_matrixElPNS_8ae_stateE(ptr noundef %0, ptr noundef %1, i64 noundef %2, ptr noundef %3) #3 {
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i64, align 8
  %8 = alloca ptr, align 8
  %9 = alloca %"struct.alglib_impl::ae_frame", align 8
  %10 = alloca i64, align 8
  %11 = alloca i64, align 8
  %12 = alloca i64, align 8
  %13 = alloca i64, align 8
  %14 = alloca %"struct.alglib_impl::ae_vector", align 8
  %15 = alloca %"struct.alglib_impl::ae_vector", align 8
  %16 = alloca i64, align 8
  %17 = alloca i64, align 8
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  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) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr %14) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr %15) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #4
  %18 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef %18, ptr noundef %9)
  call void @llvm.memset.p0.i64(ptr align 8 %14, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %15, i8 0, i64 64, i1 false)
  %19 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef %14, i64 noundef 0, i64 noundef 3, ptr noundef %19, i1 noundef zeroext true)
  %20 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef %15, i64 noundef 0, i64 noundef 3, ptr noundef %20, i1 noundef zeroext true)
  %21 = load ptr, ptr %5, align 8, !tbaa !5
  %22 = getelementptr inbounds %"struct.alglib_impl::logitmodel", ptr %21, i32 0, i32 0
  %23 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %22, i32 0, i32 4
  %24 = load ptr, ptr %23, align 8, !tbaa !11
  %25 = getelementptr inbounds double, ptr %24, i64 1
  %26 = load double, ptr %25, align 8, !tbaa !12
  %27 = load i64, ptr @_ZN11alglib_implL15logit_logitvnumE, align 8, !tbaa !9
  %28 = sitofp i64 %27 to double
  %29 = call noundef zeroext i1 @_ZN11alglib_impl8ae_fp_eqEdd(double noundef %26, double noundef %28)
  %30 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %29, ptr noundef @.str.289, ptr noundef %30)
  %31 = load ptr, ptr %5, align 8, !tbaa !5
  %32 = getelementptr inbounds %"struct.alglib_impl::logitmodel", ptr %31, i32 0, i32 0
  %33 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %32, i32 0, i32 4
  %34 = load ptr, ptr %33, align 8, !tbaa !11
  %35 = getelementptr inbounds double, ptr %34, i64 2
  %36 = load double, ptr %35, align 8, !tbaa !12
  %37 = load ptr, ptr %8, align 8, !tbaa !5
  %38 = call noundef i64 @_ZN11alglib_impl8ae_roundEdPNS_8ae_stateE(double noundef %36, ptr noundef %37)
  store i64 %38, ptr %10, align 8, !tbaa !9
  %39 = load ptr, ptr %5, align 8, !tbaa !5
  %40 = getelementptr inbounds %"struct.alglib_impl::logitmodel", ptr %39, i32 0, i32 0
  %41 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %40, i32 0, i32 4
  %42 = load ptr, ptr %41, align 8, !tbaa !11
  %43 = getelementptr inbounds double, ptr %42, i64 3
  %44 = load double, ptr %43, align 8, !tbaa !12
  %45 = load ptr, ptr %8, align 8, !tbaa !5
  %46 = call noundef i64 @_ZN11alglib_impl8ae_roundEdPNS_8ae_stateE(double noundef %44, ptr noundef %45)
  store i64 %46, ptr %11, align 8, !tbaa !9
  %47 = load i64, ptr %10, align 8, !tbaa !9
  %48 = sub nsw i64 %47, 1
  %49 = add nsw i64 %48, 1
  %50 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %14, i64 noundef %49, ptr noundef %50)
  %51 = load i64, ptr %11, align 8, !tbaa !9
  %52 = sub nsw i64 %51, 1
  %53 = add nsw i64 %52, 1
  %54 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %15, i64 noundef %53, ptr noundef %54)
  store i64 0, ptr %17, align 8, !tbaa !9
  store i64 0, ptr %12, align 8, !tbaa !9
  br label %55

55:                                               ; preds = %117, %4
  %56 = load i64, ptr %12, align 8, !tbaa !9
  %57 = load i64, ptr %7, align 8, !tbaa !9
  %58 = sub nsw i64 %57, 1
  %59 = icmp sle i64 %56, %58
  br i1 %59, label %60, label %120

60:                                               ; preds = %55
  %61 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %14, i32 0, i32 4
  %62 = load ptr, ptr %61, align 8, !tbaa !11
  %63 = getelementptr inbounds double, ptr %62, i64 0
  %64 = load ptr, ptr %6, align 8, !tbaa !5
  %65 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %64, i32 0, i32 6
  %66 = load ptr, ptr %65, align 8, !tbaa !11
  %67 = load i64, ptr %12, align 8, !tbaa !9
  %68 = getelementptr inbounds ptr, ptr %66, i64 %67
  %69 = load ptr, ptr %68, align 8, !tbaa !5
  %70 = getelementptr inbounds double, ptr %69, i64 0
  %71 = load i64, ptr %10, 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 %63, i64 noundef 1, ptr noundef %70, i64 noundef 1, i64 noundef %73)
  %74 = load ptr, ptr %5, align 8, !tbaa !5
  %75 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl10mnlprocessEPNS_10logitmodelEPNS_9ae_vectorES3_PNS_8ae_stateE(ptr noundef %74, ptr noundef %14, ptr noundef %15, ptr noundef %75)
  store i64 0, ptr %16, align 8, !tbaa !9
  store i64 0, ptr %13, align 8, !tbaa !9
  br label %76

76:                                               ; preds = %96, %60
  %77 = load i64, ptr %13, align 8, !tbaa !9
  %78 = load i64, ptr %11, align 8, !tbaa !9
  %79 = sub nsw i64 %78, 1
  %80 = icmp sle i64 %77, %79
  br i1 %80, label %81, label %99

81:                                               ; preds = %76
  %82 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %15, i32 0, i32 4
  %83 = load ptr, ptr %82, align 8, !tbaa !11
  %84 = load i64, ptr %13, align 8, !tbaa !9
  %85 = getelementptr inbounds double, ptr %83, i64 %84
  %86 = load double, ptr %85, align 8, !tbaa !12
  %87 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %15, i32 0, i32 4
  %88 = load ptr, ptr %87, align 8, !tbaa !11
  %89 = load i64, ptr %16, align 8, !tbaa !9
  %90 = getelementptr inbounds double, ptr %88, i64 %89
  %91 = load double, ptr %90, align 8, !tbaa !12
  %92 = call noundef zeroext i1 @_ZN11alglib_impl13ae_fp_greaterEdd(double noundef %86, double noundef %91)
  br i1 %92, label %93, label %95

93:                                               ; preds = %81
  %94 = load i64, ptr %13, align 8, !tbaa !9
  store i64 %94, ptr %16, align 8, !tbaa !9
  br label %95

95:                                               ; preds = %93, %81
  br label %96

96:                                               ; preds = %95
  %97 = load i64, ptr %13, align 8, !tbaa !9
  %98 = add nsw i64 %97, 1
  store i64 %98, ptr %13, align 8, !tbaa !9
  br label %76, !llvm.loop !14

99:                                               ; preds = %76
  %100 = load i64, ptr %16, align 8, !tbaa !9
  %101 = load ptr, ptr %6, align 8, !tbaa !5
  %102 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %101, i32 0, i32 6
  %103 = load ptr, ptr %102, align 8, !tbaa !11
  %104 = load i64, ptr %12, align 8, !tbaa !9
  %105 = getelementptr inbounds ptr, ptr %103, i64 %104
  %106 = load ptr, ptr %105, align 8, !tbaa !5
  %107 = load i64, ptr %10, align 8, !tbaa !9
  %108 = getelementptr inbounds double, ptr %106, i64 %107
  %109 = load double, ptr %108, align 8, !tbaa !12
  %110 = load ptr, ptr %8, align 8, !tbaa !5
  %111 = call noundef i64 @_ZN11alglib_impl8ae_roundEdPNS_8ae_stateE(double noundef %109, ptr noundef %110)
  %112 = icmp ne i64 %100, %111
  br i1 %112, label %113, label %116

113:                                              ; preds = %99
  %114 = load i64, ptr %17, align 8, !tbaa !9
  %115 = add nsw i64 %114, 1
  store i64 %115, ptr %17, align 8, !tbaa !9
  br label %116

116:                                              ; preds = %113, %99
  br label %117

117:                                              ; preds = %116
  %118 = load i64, ptr %12, align 8, !tbaa !9
  %119 = add nsw i64 %118, 1
  store i64 %119, ptr %12, align 8, !tbaa !9
  br label %55, !llvm.loop !16

120:                                              ; preds = %55
  %121 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %121)
  %122 = load i64, ptr %17, align 8, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr %14) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #4
  call void @llvm.lifetime.end.p0(i64 32, ptr %9) #4
  ret i64 %122
}

declare void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef, 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 noundef zeroext i1 @_ZN11alglib_impl8ae_fp_eqEdd(double noundef, double noundef) #2

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

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

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, !13, i64 0}
!13 = !{!"double", !7, i64 0}
!14 = distinct !{!14, !15}
!15 = !{!"llvm.loop.mustprogress"}
!16 = distinct !{!16, !15}


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

@_ZN11alglib_implL15logit_logitvnumE = external hidden local_unnamed_addr global i64, align 8
@.str.289 = external hidden unnamed_addr constant [38 x i8], align 1

; 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_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext, ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN11alglib_impl10mnlprocessEPNS_10logitmodelEPNS_9ae_vectorES3_PNS_8ae_stateE(ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
define dso_local noundef i64 @_ZN11alglib_impl11mnlclserrorEPNS_10logitmodelEPNS_9ae_matrixElPNS_8ae_stateE(ptr noundef %0, ptr nocapture noundef readonly %1, i64 noundef %2, ptr noundef %3) local_unnamed_addr #3 {
  %5 = alloca %"struct.alglib_impl::ae_frame", align 8
  %6 = alloca %"struct.alglib_impl::ae_vector", align 8
  %7 = alloca %"struct.alglib_impl::ae_vector", align 8
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %5) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %6) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %7) #4
  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(64) %6, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %7, i8 0, i64 64, i1 false)
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef nonnull %6, i64 noundef 0, i64 noundef 3, ptr noundef %3, i1 noundef zeroext true)
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef nonnull %7, i64 noundef 0, i64 noundef 3, ptr noundef %3, i1 noundef zeroext true)
  %8 = getelementptr inbounds i8, ptr %0, i64 56
  %9 = load ptr, ptr %8, align 8, !tbaa !5
  %10 = getelementptr inbounds i8, ptr %9, i64 8
  %11 = load double, ptr %10, align 8, !tbaa !8
  %12 = load i64, ptr @_ZN11alglib_implL15logit_logitvnumE, align 8, !tbaa !10
  %13 = sitofp i64 %12 to double
  %14 = call noundef zeroext i1 @_ZN11alglib_impl8ae_fp_eqEdd(double noundef %11, double noundef %13)
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %14, ptr noundef nonnull @.str.289, ptr noundef %3)
  %15 = load ptr, ptr %8, align 8, !tbaa !5
  %16 = getelementptr inbounds i8, ptr %15, i64 16
  %17 = load double, ptr %16, align 8, !tbaa !8
  %18 = call noundef i64 @_ZN11alglib_impl8ae_roundEdPNS_8ae_stateE(double noundef %17, ptr noundef %3)
  %19 = load ptr, ptr %8, align 8, !tbaa !5
  %20 = getelementptr inbounds i8, ptr %19, i64 24
  %21 = load double, ptr %20, align 8, !tbaa !8
  %22 = call noundef i64 @_ZN11alglib_impl8ae_roundEdPNS_8ae_stateE(double noundef %21, ptr noundef %3)
  %23 = add nsw i64 %18, -1
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %6, i64 noundef %18, ptr noundef %3)
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %7, i64 noundef %22, ptr noundef %3)
  %.not.not43 = icmp sgt i64 %2, 0
  br i1 %.not.not43, label %.lr.ph47, label %._crit_edge48

.lr.ph47:                                         ; preds = %4
  %24 = getelementptr inbounds i8, ptr %6, i64 56
  %25 = getelementptr inbounds i8, ptr %1, i64 72
  %.not.not3840 = icmp sgt i64 %22, 0
  %26 = getelementptr inbounds i8, ptr %7, i64 56
  br i1 %.not.not3840, label %.lr.ph.us, label %.lr.ph47.split

.lr.ph.us:                                        ; preds = %.lr.ph47, %._crit_edge.us
  %.045.us = phi i64 [ %spec.select39.us, %._crit_edge.us ], [ 0, %.lr.ph47 ]
  %.03744.us = phi i64 [ %47, %._crit_edge.us ], [ 0, %.lr.ph47 ]
  %27 = load ptr, ptr %24, align 8, !tbaa !5
  %28 = load ptr, ptr %25, align 8, !tbaa !5
  %29 = getelementptr inbounds ptr, ptr %28, i64 %.03744.us
  %30 = load ptr, ptr %29, align 8, !tbaa !12
  %31 = call noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef 0, i64 noundef %23)
  call void @_ZN11alglib_impl9ae_v_moveEPdlPKdll(ptr noundef %27, i64 noundef 1, ptr noundef %30, i64 noundef 1, i64 noundef %31)
  call void @_ZN11alglib_impl10mnlprocessEPNS_10logitmodelEPNS_9ae_vectorES3_PNS_8ae_stateE(ptr noundef %0, ptr noundef nonnull %6, ptr noundef nonnull %7, ptr noundef %3)
  br label %32

32:                                               ; preds = %.lr.ph.us, %32
  %.03442.us = phi i64 [ 0, %.lr.ph.us ], [ %spec.select.us, %32 ]
  %.03641.us = phi i64 [ 0, %.lr.ph.us ], [ %39, %32 ]
  %33 = load ptr, ptr %26, align 8, !tbaa !5
  %34 = getelementptr inbounds double, ptr %33, i64 %.03641.us
  %35 = load double, ptr %34, align 8, !tbaa !8
  %36 = getelementptr inbounds double, ptr %33, i64 %.03442.us
  %37 = load double, ptr %36, align 8, !tbaa !8
  %38 = call noundef zeroext i1 @_ZN11alglib_impl13ae_fp_greaterEdd(double noundef %35, double noundef %37)
  %spec.select.us = select i1 %38, i64 %.03641.us, i64 %.03442.us
  %39 = add nuw nsw i64 %.03641.us, 1
  %exitcond51.not = icmp eq i64 %39, %22
  br i1 %exitcond51.not, label %._crit_edge.us, label %32, !llvm.loop !14

._crit_edge.us:                                   ; preds = %32
  %40 = load ptr, ptr %25, align 8, !tbaa !5
  %41 = getelementptr inbounds ptr, ptr %40, i64 %.03744.us
  %42 = load ptr, ptr %41, align 8, !tbaa !12
  %43 = getelementptr inbounds double, ptr %42, i64 %18
  %44 = load double, ptr %43, align 8, !tbaa !8
  %45 = call noundef i64 @_ZN11alglib_impl8ae_roundEdPNS_8ae_stateE(double noundef %44, ptr noundef %3)
  %.not.us = icmp ne i64 %spec.select.us, %45
  %46 = zext i1 %.not.us to i64
  %spec.select39.us = add nuw nsw i64 %.045.us, %46
  %47 = add nuw nsw i64 %.03744.us, 1
  %exitcond52.not = icmp eq i64 %47, %2
  br i1 %exitcond52.not, label %._crit_edge48, label %.lr.ph.us, !llvm.loop !16

.lr.ph47.split:                                   ; preds = %.lr.ph47, %.lr.ph47.split
  %.045 = phi i64 [ %spec.select39, %.lr.ph47.split ], [ 0, %.lr.ph47 ]
  %.03744 = phi i64 [ %60, %.lr.ph47.split ], [ 0, %.lr.ph47 ]
  %48 = load ptr, ptr %24, align 8, !tbaa !5
  %49 = load ptr, ptr %25, align 8, !tbaa !5
  %50 = getelementptr inbounds ptr, ptr %49, i64 %.03744
  %51 = load ptr, ptr %50, align 8, !tbaa !12
  %52 = call noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef 0, i64 noundef %23)
  call void @_ZN11alglib_impl9ae_v_moveEPdlPKdll(ptr noundef %48, i64 noundef 1, ptr noundef %51, i64 noundef 1, i64 noundef %52)
  call void @_ZN11alglib_impl10mnlprocessEPNS_10logitmodelEPNS_9ae_vectorES3_PNS_8ae_stateE(ptr noundef %0, ptr noundef nonnull %6, ptr noundef nonnull %7, ptr noundef %3)
  %53 = load ptr, ptr %25, align 8, !tbaa !5
  %54 = getelementptr inbounds ptr, ptr %53, i64 %.03744
  %55 = load ptr, ptr %54, align 8, !tbaa !12
  %56 = getelementptr inbounds double, ptr %55, i64 %18
  %57 = load double, ptr %56, align 8, !tbaa !8
  %58 = call noundef i64 @_ZN11alglib_impl8ae_roundEdPNS_8ae_stateE(double noundef %57, ptr noundef %3)
  %.not = icmp ne i64 %58, 0
  %59 = zext i1 %.not to i64
  %spec.select39 = add nuw nsw i64 %.045, %59
  %60 = add nuw nsw i64 %.03744, 1
  %exitcond.not = icmp eq i64 %60, %2
  br i1 %exitcond.not, label %._crit_edge48, label %.lr.ph47.split, !llvm.loop !16

._crit_edge48:                                    ; preds = %.lr.ph47.split, %._crit_edge.us, %4
  %.0.lcssa = phi i64 [ 0, %4 ], [ %spec.select39.us, %._crit_edge.us ], [ %spec.select39, %.lr.ph47.split ]
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %3)
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %7) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %6) #4
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #4
  ret i64 %.0.lcssa
}

declare void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef, 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 noundef zeroext i1 @_ZN11alglib_impl8ae_fp_eqEdd(double noundef, double noundef) local_unnamed_addr #2

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

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

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 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !9, i64 0}
!9 = !{!"double", !6, i64 0}
!10 = !{!11, !11, i64 0}
!11 = !{!"long", !6, i64 0}
!12 = !{!13, !13, i64 0}
!13 = !{!"any pointer", !6, i64 0}
!14 = distinct !{!14, !15}
!15 = !{!"llvm.loop.mustprogress"}
!16 = distinct !{!16, !15}


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