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

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

@.str.71 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.72 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.73 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.74 = external hidden unnamed_addr constant [29 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

declare void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext, ptr noundef, ptr noundef) #1

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN11alglib_impl22sparsecreatesksbandbufElllPNS_12sparsematrixEPNS_8ae_stateE(i64 noundef %0, i64 noundef %1, i64 noundef %2, ptr noundef %3, ptr noundef %4) #2 {
  %6 = alloca i64, align 8
  %7 = alloca i64, align 8
  %8 = alloca i64, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca i64, align 8
  %12 = alloca i64, align 8
  %13 = alloca i64, align 8
  %14 = alloca i64, align 8
  %15 = alloca i64, align 8
  %16 = alloca i64, align 8
  store i64 %0, ptr %6, align 8, !tbaa !5
  store i64 %1, ptr %7, align 8, !tbaa !5
  store i64 %2, ptr %8, align 8, !tbaa !5
  store ptr %3, ptr %9, align 8, !tbaa !9
  store ptr %4, ptr %10, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #3
  %17 = load i64, ptr %6, align 8, !tbaa !5
  %18 = icmp sgt i64 %17, 0
  %19 = load ptr, ptr %10, align 8, !tbaa !9
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %18, ptr noundef @.str.71, ptr noundef %19)
  %20 = load i64, ptr %7, align 8, !tbaa !5
  %21 = icmp sgt i64 %20, 0
  %22 = load ptr, ptr %10, align 8, !tbaa !9
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %21, ptr noundef @.str.72, ptr noundef %22)
  %23 = load i64, ptr %6, align 8, !tbaa !5
  %24 = load i64, ptr %7, align 8, !tbaa !5
  %25 = icmp eq i64 %23, %24
  %26 = load ptr, ptr %10, align 8, !tbaa !9
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %25, ptr noundef @.str.73, ptr noundef %26)
  %27 = load i64, ptr %8, align 8, !tbaa !5
  %28 = icmp sge i64 %27, 0
  %29 = load ptr, ptr %10, align 8, !tbaa !9
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %28, ptr noundef @.str.74, ptr noundef %29)
  %30 = load i64, ptr %6, align 8, !tbaa !5
  %31 = load i64, ptr %7, align 8, !tbaa !5
  %32 = load ptr, ptr %10, align 8, !tbaa !9
  %33 = call noundef i64 @_ZN11alglib_impl9ae_minintEllPNS_8ae_stateE(i64 noundef %30, i64 noundef %31, ptr noundef %32)
  store i64 %33, ptr %12, align 8, !tbaa !5
  %34 = load ptr, ptr %9, align 8, !tbaa !9
  %35 = getelementptr inbounds %"struct.alglib_impl::sparsematrix", ptr %34, i32 0, i32 5
  store i64 2, ptr %35, align 8, !tbaa !11
  %36 = load ptr, ptr %9, align 8, !tbaa !9
  %37 = getelementptr inbounds %"struct.alglib_impl::sparsematrix", ptr %36, i32 0, i32 9
  store i64 0, ptr %37, align 8, !tbaa !16
  %38 = load i64, ptr %6, align 8, !tbaa !5
  %39 = load ptr, ptr %9, align 8, !tbaa !9
  %40 = getelementptr inbounds %"struct.alglib_impl::sparsematrix", ptr %39, i32 0, i32 6
  store i64 %38, ptr %40, align 8, !tbaa !17
  %41 = load i64, ptr %7, align 8, !tbaa !5
  %42 = load ptr, ptr %9, align 8, !tbaa !9
  %43 = getelementptr inbounds %"struct.alglib_impl::sparsematrix", ptr %42, i32 0, i32 7
  store i64 %41, ptr %43, align 8, !tbaa !18
  %44 = load ptr, ptr %9, align 8, !tbaa !9
  %45 = getelementptr inbounds %"struct.alglib_impl::sparsematrix", ptr %44, i32 0, i32 2
  %46 = load i64, ptr %12, align 8, !tbaa !5
  %47 = add nsw i64 %46, 1
  %48 = load ptr, ptr %10, align 8, !tbaa !9
  call void @_ZN11alglib_impl23ivectorsetlengthatleastEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %45, i64 noundef %47, ptr noundef %48)
  %49 = load ptr, ptr %9, align 8, !tbaa !9
  %50 = getelementptr inbounds %"struct.alglib_impl::sparsematrix", ptr %49, i32 0, i32 2
  %51 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %50, i32 0, i32 4
  %52 = load ptr, ptr %51, align 8, !tbaa !19
  %53 = getelementptr inbounds i64, ptr %52, i64 0
  store i64 0, ptr %53, align 8, !tbaa !5
  store i64 0, ptr %13, align 8, !tbaa !5
  store i64 0, ptr %11, align 8, !tbaa !5
  br label %54

54:                                               ; preds = %87, %5
  %55 = load i64, ptr %11, align 8, !tbaa !5
  %56 = load i64, ptr %12, align 8, !tbaa !5
  %57 = sub nsw i64 %56, 1
  %58 = icmp sle i64 %55, %57
  br i1 %58, label %59, label %90

59:                                               ; preds = %54
  %60 = load i64, ptr %11, align 8, !tbaa !5
  %61 = load i64, ptr %8, align 8, !tbaa !5
  %62 = load ptr, ptr %10, align 8, !tbaa !9
  %63 = call noundef i64 @_ZN11alglib_impl9ae_minintEllPNS_8ae_stateE(i64 noundef %60, i64 noundef %61, ptr noundef %62)
  store i64 %63, ptr %16, align 8, !tbaa !5
  %64 = load i64, ptr %13, align 8, !tbaa !5
  %65 = add nsw i64 %64, 1
  %66 = load i64, ptr %16, align 8, !tbaa !5
  %67 = mul nsw i64 2, %66
  %68 = add nsw i64 %65, %67
  store i64 %68, ptr %13, align 8, !tbaa !5
  %69 = load ptr, ptr %9, align 8, !tbaa !9
  %70 = getelementptr inbounds %"struct.alglib_impl::sparsematrix", ptr %69, i32 0, i32 2
  %71 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %70, i32 0, i32 4
  %72 = load ptr, ptr %71, align 8, !tbaa !19
  %73 = load i64, ptr %11, align 8, !tbaa !5
  %74 = getelementptr inbounds i64, ptr %72, i64 %73
  %75 = load i64, ptr %74, align 8, !tbaa !5
  %76 = add nsw i64 %75, 1
  %77 = load i64, ptr %16, align 8, !tbaa !5
  %78 = mul nsw i64 2, %77
  %79 = add nsw i64 %76, %78
  %80 = load ptr, ptr %9, align 8, !tbaa !9
  %81 = getelementptr inbounds %"struct.alglib_impl::sparsematrix", ptr %80, i32 0, i32 2
  %82 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %81, i32 0, i32 4
  %83 = load ptr, ptr %82, align 8, !tbaa !19
  %84 = load i64, ptr %11, align 8, !tbaa !5
  %85 = add nsw i64 %84, 1
  %86 = getelementptr inbounds i64, ptr %83, i64 %85
  store i64 %79, ptr %86, align 8, !tbaa !5
  br label %87

87:                                               ; preds = %59
  %88 = load i64, ptr %11, align 8, !tbaa !5
  %89 = add nsw i64 %88, 1
  store i64 %89, ptr %11, align 8, !tbaa !5
  br label %54, !llvm.loop !20

90:                                               ; preds = %54
  %91 = load ptr, ptr %9, align 8, !tbaa !9
  %92 = getelementptr inbounds %"struct.alglib_impl::sparsematrix", ptr %91, i32 0, i32 0
  %93 = load i64, ptr %13, align 8, !tbaa !5
  %94 = load ptr, ptr %10, align 8, !tbaa !9
  call void @_ZN11alglib_impl23rvectorsetlengthatleastEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %92, i64 noundef %93, ptr noundef %94)
  store i64 0, ptr %11, align 8, !tbaa !5
  br label %95

95:                                               ; preds = %107, %90
  %96 = load i64, ptr %11, align 8, !tbaa !5
  %97 = load i64, ptr %13, align 8, !tbaa !5
  %98 = sub nsw i64 %97, 1
  %99 = icmp sle i64 %96, %98
  br i1 %99, label %100, label %110

100:                                              ; preds = %95
  %101 = load ptr, ptr %9, align 8, !tbaa !9
  %102 = getelementptr inbounds %"struct.alglib_impl::sparsematrix", ptr %101, i32 0, i32 0
  %103 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %102, i32 0, i32 4
  %104 = load ptr, ptr %103, align 8, !tbaa !19
  %105 = load i64, ptr %11, align 8, !tbaa !5
  %106 = getelementptr inbounds double, ptr %104, i64 %105
  store double 0.000000e+00, ptr %106, align 8, !tbaa !22
  br label %107

107:                                              ; preds = %100
  %108 = load i64, ptr %11, align 8, !tbaa !5
  %109 = add nsw i64 %108, 1
  store i64 %109, ptr %11, align 8, !tbaa !5
  br label %95, !llvm.loop !24

110:                                              ; preds = %95
  %111 = load ptr, ptr %9, align 8, !tbaa !9
  %112 = getelementptr inbounds %"struct.alglib_impl::sparsematrix", ptr %111, i32 0, i32 3
  %113 = load i64, ptr %6, align 8, !tbaa !5
  %114 = add nsw i64 %113, 1
  %115 = load ptr, ptr %10, align 8, !tbaa !9
  call void @_ZN11alglib_impl23ivectorsetlengthatleastEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %112, i64 noundef %114, ptr noundef %115)
  store i64 0, ptr %14, align 8, !tbaa !5
  store i64 0, ptr %11, align 8, !tbaa !5
  br label %116

116:                                              ; preds = %137, %110
  %117 = load i64, ptr %11, align 8, !tbaa !5
  %118 = load i64, ptr %6, align 8, !tbaa !5
  %119 = sub nsw i64 %118, 1
  %120 = icmp sle i64 %117, %119
  br i1 %120, label %121, label %140

121:                                              ; preds = %116
  %122 = load i64, ptr %11, align 8, !tbaa !5
  %123 = load i64, ptr %8, align 8, !tbaa !5
  %124 = load ptr, ptr %10, align 8, !tbaa !9
  %125 = call noundef i64 @_ZN11alglib_impl9ae_minintEllPNS_8ae_stateE(i64 noundef %122, i64 noundef %123, ptr noundef %124)
  store i64 %125, ptr %16, align 8, !tbaa !5
  %126 = load i64, ptr %16, align 8, !tbaa !5
  %127 = load ptr, ptr %9, align 8, !tbaa !9
  %128 = getelementptr inbounds %"struct.alglib_impl::sparsematrix", ptr %127, i32 0, i32 3
  %129 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %128, i32 0, i32 4
  %130 = load ptr, ptr %129, align 8, !tbaa !19
  %131 = load i64, ptr %11, align 8, !tbaa !5
  %132 = getelementptr inbounds i64, ptr %130, i64 %131
  store i64 %126, ptr %132, align 8, !tbaa !5
  %133 = load i64, ptr %14, align 8, !tbaa !5
  %134 = load i64, ptr %16, align 8, !tbaa !5
  %135 = load ptr, ptr %10, align 8, !tbaa !9
  %136 = call noundef i64 @_ZN11alglib_impl9ae_maxintEllPNS_8ae_stateE(i64 noundef %133, i64 noundef %134, ptr noundef %135)
  store i64 %136, ptr %14, align 8, !tbaa !5
  br label %137

137:                                              ; preds = %121
  %138 = load i64, ptr %11, align 8, !tbaa !5
  %139 = add nsw i64 %138, 1
  store i64 %139, ptr %11, align 8, !tbaa !5
  br label %116, !llvm.loop !25

140:                                              ; preds = %116
  %141 = load i64, ptr %14, align 8, !tbaa !5
  %142 = load ptr, ptr %9, align 8, !tbaa !9
  %143 = getelementptr inbounds %"struct.alglib_impl::sparsematrix", ptr %142, i32 0, i32 3
  %144 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %143, i32 0, i32 4
  %145 = load ptr, ptr %144, align 8, !tbaa !19
  %146 = load i64, ptr %6, align 8, !tbaa !5
  %147 = getelementptr inbounds i64, ptr %145, i64 %146
  store i64 %141, ptr %147, align 8, !tbaa !5
  %148 = load ptr, ptr %9, align 8, !tbaa !9
  %149 = getelementptr inbounds %"struct.alglib_impl::sparsematrix", ptr %148, i32 0, i32 4
  %150 = load i64, ptr %7, align 8, !tbaa !5
  %151 = add nsw i64 %150, 1
  %152 = load ptr, ptr %10, align 8, !tbaa !9
  call void @_ZN11alglib_impl23ivectorsetlengthatleastEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %149, i64 noundef %151, ptr noundef %152)
  store i64 0, ptr %15, align 8, !tbaa !5
  store i64 0, ptr %11, align 8, !tbaa !5
  br label %153

153:                                              ; preds = %174, %140
  %154 = load i64, ptr %11, align 8, !tbaa !5
  %155 = load i64, ptr %7, align 8, !tbaa !5
  %156 = sub nsw i64 %155, 1
  %157 = icmp sle i64 %154, %156
  br i1 %157, label %158, label %177

158:                                              ; preds = %153
  %159 = load i64, ptr %11, align 8, !tbaa !5
  %160 = load i64, ptr %8, align 8, !tbaa !5
  %161 = load ptr, ptr %10, align 8, !tbaa !9
  %162 = call noundef i64 @_ZN11alglib_impl9ae_minintEllPNS_8ae_stateE(i64 noundef %159, i64 noundef %160, ptr noundef %161)
  store i64 %162, ptr %16, align 8, !tbaa !5
  %163 = load i64, ptr %16, align 8, !tbaa !5
  %164 = load ptr, ptr %9, align 8, !tbaa !9
  %165 = getelementptr inbounds %"struct.alglib_impl::sparsematrix", ptr %164, i32 0, i32 4
  %166 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %165, i32 0, i32 4
  %167 = load ptr, ptr %166, align 8, !tbaa !19
  %168 = load i64, ptr %11, align 8, !tbaa !5
  %169 = getelementptr inbounds i64, ptr %167, i64 %168
  store i64 %163, ptr %169, align 8, !tbaa !5
  %170 = load i64, ptr %15, align 8, !tbaa !5
  %171 = load i64, ptr %16, align 8, !tbaa !5
  %172 = load ptr, ptr %10, align 8, !tbaa !9
  %173 = call noundef i64 @_ZN11alglib_impl9ae_maxintEllPNS_8ae_stateE(i64 noundef %170, i64 noundef %171, ptr noundef %172)
  store i64 %173, ptr %15, align 8, !tbaa !5
  br label %174

174:                                              ; preds = %158
  %175 = load i64, ptr %11, align 8, !tbaa !5
  %176 = add nsw i64 %175, 1
  store i64 %176, ptr %11, align 8, !tbaa !5
  br label %153, !llvm.loop !26

177:                                              ; preds = %153
  %178 = load i64, ptr %15, align 8, !tbaa !5
  %179 = load ptr, ptr %9, align 8, !tbaa !9
  %180 = getelementptr inbounds %"struct.alglib_impl::sparsematrix", ptr %179, i32 0, i32 4
  %181 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %180, i32 0, i32 4
  %182 = load ptr, ptr %181, align 8, !tbaa !19
  %183 = load i64, ptr %7, align 8, !tbaa !5
  %184 = getelementptr inbounds i64, ptr %182, i64 %183
  store i64 %178, ptr %184, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #3
  ret void
}

declare void @_ZN11alglib_impl23rvectorsetlengthatleastEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef, i64 noundef, ptr noundef) #1

declare void @_ZN11alglib_impl23ivectorsetlengthatleastEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef, i64 noundef, ptr noundef) #1

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

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

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "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 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 #3 = { 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 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = !{!12, !6, i64 320}
!12 = !{!"_ZTSN11alglib_impl12sparsematrixE", !13, i64 0, !13, i64 64, !13, i64 128, !13, i64 192, !13, i64 256, !6, i64 320, !6, i64 328, !6, i64 336, !6, i64 344, !6, i64 352, !6, i64 360}
!13 = !{!"_ZTSN11alglib_impl9ae_vectorE", !6, i64 0, !6, i64 8, !14, i64 16, !15, i64 24, !7, i64 56}
!14 = !{!"bool", !7, i64 0}
!15 = !{!"_ZTSN11alglib_impl12ae_dyn_blockE", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24}
!16 = !{!12, !6, i64 352}
!17 = !{!12, !6, i64 328}
!18 = !{!12, !6, i64 336}
!19 = !{!7, !7, i64 0}
!20 = distinct !{!20, !21}
!21 = !{!"llvm.loop.mustprogress"}
!22 = !{!23, !23, i64 0}
!23 = !{!"double", !7, i64 0}
!24 = distinct !{!24, !21}
!25 = distinct !{!25, !21}
!26 = distinct !{!26, !21}


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

@.str.71 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.72 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.73 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.74 = external hidden unnamed_addr constant [29 x i8], align 1

declare void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext, ptr noundef, ptr noundef) local_unnamed_addr #0

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN11alglib_impl22sparsecreatesksbandbufElllPNS_12sparsematrixEPNS_8ae_stateE(i64 noundef %0, i64 noundef %1, i64 noundef %2, ptr noundef %3, ptr noundef %4) local_unnamed_addr #1 {
  %6 = icmp sgt i64 %0, 0
  tail call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %6, ptr noundef nonnull @.str.71, ptr noundef %4)
  %7 = icmp sgt i64 %1, 0
  tail call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %7, ptr noundef nonnull @.str.72, ptr noundef %4)
  %8 = icmp eq i64 %0, %1
  tail call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %8, ptr noundef nonnull @.str.73, ptr noundef %4)
  %9 = icmp sgt i64 %2, -1
  tail call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %9, ptr noundef nonnull @.str.74, ptr noundef %4)
  %10 = tail call noundef i64 @_ZN11alglib_impl9ae_minintEllPNS_8ae_stateE(i64 noundef %0, i64 noundef %1, ptr noundef %4)
  %11 = getelementptr inbounds i8, ptr %3, i64 320
  store i64 2, ptr %11, align 8, !tbaa !5
  %12 = getelementptr inbounds i8, ptr %3, i64 352
  store i64 0, ptr %12, align 8, !tbaa !14
  %13 = getelementptr inbounds i8, ptr %3, i64 328
  store i64 %0, ptr %13, align 8, !tbaa !15
  %14 = getelementptr inbounds i8, ptr %3, i64 336
  store i64 %1, ptr %14, align 8, !tbaa !16
  %15 = getelementptr inbounds i8, ptr %3, i64 128
  %16 = add nsw i64 %10, 1
  tail call void @_ZN11alglib_impl23ivectorsetlengthatleastEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %15, i64 noundef %16, ptr noundef %4)
  %17 = getelementptr inbounds i8, ptr %3, i64 184
  %18 = load ptr, ptr %17, align 8, !tbaa !17
  store i64 0, ptr %18, align 8, !tbaa !18
  %.not.not84 = icmp sgt i64 %10, 0
  br i1 %.not.not84, label %.lr.ph, label %._crit_edge.thread

._crit_edge.thread:                               ; preds = %5
  tail call void @_ZN11alglib_impl23rvectorsetlengthatleastEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %3, i64 noundef 0, ptr noundef %4)
  br label %._crit_edge91

.lr.ph:                                           ; preds = %5, %.lr.ph
  %.07986 = phi i64 [ %22, %.lr.ph ], [ 0, %5 ]
  %.08085 = phi i64 [ %28, %.lr.ph ], [ 0, %5 ]
  %19 = tail call noundef i64 @_ZN11alglib_impl9ae_minintEllPNS_8ae_stateE(i64 noundef %.08085, i64 noundef %2, ptr noundef %4)
  %20 = add nsw i64 %.07986, 1
  %21 = shl nsw i64 %19, 1
  %22 = add nsw i64 %20, %21
  %23 = load ptr, ptr %17, align 8, !tbaa !17
  %24 = getelementptr inbounds i64, ptr %23, i64 %.08085
  %25 = load i64, ptr %24, align 8, !tbaa !18
  %26 = or disjoint i64 %21, 1
  %27 = add i64 %26, %25
  %28 = add nuw nsw i64 %.08085, 1
  %29 = getelementptr inbounds i64, ptr %23, i64 %28
  store i64 %27, ptr %29, align 8, !tbaa !18
  %exitcond.not = icmp eq i64 %28, %10
  br i1 %exitcond.not, label %._crit_edge, label %.lr.ph, !llvm.loop !19

._crit_edge:                                      ; preds = %.lr.ph
  tail call void @_ZN11alglib_impl23rvectorsetlengthatleastEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %3, i64 noundef %22, ptr noundef %4)
  %.not.not8187 = icmp sgt i64 %22, 0
  br i1 %.not.not8187, label %.lr.ph90, label %._crit_edge91

.lr.ph90:                                         ; preds = %._crit_edge
  %30 = getelementptr inbounds i8, ptr %3, i64 56
  %31 = shl i64 %19, 1
  %32 = add i64 %.07986, %31
  %xtraiter = and i64 %22, 3
  %33 = icmp ult i64 %32, 3
  br i1 %33, label %._crit_edge91.loopexit.unr-lcssa, label %.lr.ph90.new

.lr.ph90.new:                                     ; preds = %.lr.ph90
  %unroll_iter = and i64 %22, 9223372036854775804
  br label %34

34:                                               ; preds = %34, %.lr.ph90.new
  %.188 = phi i64 [ 0, %.lr.ph90.new ], [ %46, %34 ]
  %niter = phi i64 [ 0, %.lr.ph90.new ], [ %niter.next.3, %34 ]
  %35 = load ptr, ptr %30, align 8, !tbaa !17
  %36 = getelementptr inbounds double, ptr %35, i64 %.188
  store double 0.000000e+00, ptr %36, align 8, !tbaa !21
  %37 = or disjoint i64 %.188, 1
  %38 = load ptr, ptr %30, align 8, !tbaa !17
  %39 = getelementptr inbounds double, ptr %38, i64 %37
  store double 0.000000e+00, ptr %39, align 8, !tbaa !21
  %40 = or disjoint i64 %.188, 2
  %41 = load ptr, ptr %30, align 8, !tbaa !17
  %42 = getelementptr inbounds double, ptr %41, i64 %40
  store double 0.000000e+00, ptr %42, align 8, !tbaa !21
  %43 = or disjoint i64 %.188, 3
  %44 = load ptr, ptr %30, align 8, !tbaa !17
  %45 = getelementptr inbounds double, ptr %44, i64 %43
  store double 0.000000e+00, ptr %45, align 8, !tbaa !21
  %46 = add nuw nsw i64 %.188, 4
  %niter.next.3 = add i64 %niter, 4
  %niter.ncmp.3 = icmp eq i64 %niter.next.3, %unroll_iter
  br i1 %niter.ncmp.3, label %._crit_edge91.loopexit.unr-lcssa, label %34, !llvm.loop !23

._crit_edge91.loopexit.unr-lcssa:                 ; preds = %34, %.lr.ph90
  %.188.unr = phi i64 [ 0, %.lr.ph90 ], [ %46, %34 ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %._crit_edge91, label %.epil.preheader

.epil.preheader:                                  ; preds = %._crit_edge91.loopexit.unr-lcssa, %.epil.preheader
  %.188.epil = phi i64 [ %49, %.epil.preheader ], [ %.188.unr, %._crit_edge91.loopexit.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.epil.preheader ], [ 0, %._crit_edge91.loopexit.unr-lcssa ]
  %47 = load ptr, ptr %30, align 8, !tbaa !17
  %48 = getelementptr inbounds double, ptr %47, i64 %.188.epil
  store double 0.000000e+00, ptr %48, align 8, !tbaa !21
  %49 = add nuw nsw i64 %.188.epil, 1
  %epil.iter.next = add i64 %epil.iter, 1
  %epil.iter.cmp.not = icmp eq i64 %epil.iter.next, %xtraiter
  br i1 %epil.iter.cmp.not, label %._crit_edge91, label %.epil.preheader, !llvm.loop !24

._crit_edge91:                                    ; preds = %._crit_edge91.loopexit.unr-lcssa, %.epil.preheader, %._crit_edge.thread, %._crit_edge
  %50 = getelementptr inbounds i8, ptr %3, i64 192
  %51 = add nsw i64 %0, 1
  tail call void @_ZN11alglib_impl23ivectorsetlengthatleastEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %50, i64 noundef %51, ptr noundef %4)
  br i1 %6, label %.lr.ph96, label %._crit_edge97

.lr.ph96:                                         ; preds = %._crit_edge91
  %52 = getelementptr inbounds i8, ptr %3, i64 248
  br label %53

53:                                               ; preds = %.lr.ph96, %53
  %.07894 = phi i64 [ 0, %.lr.ph96 ], [ %57, %53 ]
  %.293 = phi i64 [ 0, %.lr.ph96 ], [ %58, %53 ]
  %54 = tail call noundef i64 @_ZN11alglib_impl9ae_minintEllPNS_8ae_stateE(i64 noundef %.293, i64 noundef %2, ptr noundef %4)
  %55 = load ptr, ptr %52, align 8, !tbaa !17
  %56 = getelementptr inbounds i64, ptr %55, i64 %.293
  store i64 %54, ptr %56, align 8, !tbaa !18
  %57 = tail call noundef i64 @_ZN11alglib_impl9ae_maxintEllPNS_8ae_stateE(i64 noundef %.07894, i64 noundef %54, ptr noundef %4)
  %58 = add nuw nsw i64 %.293, 1
  %exitcond109.not = icmp eq i64 %58, %0
  br i1 %exitcond109.not, label %._crit_edge97, label %53, !llvm.loop !26

._crit_edge97:                                    ; preds = %53, %._crit_edge91
  %.078.lcssa = phi i64 [ 0, %._crit_edge91 ], [ %57, %53 ]
  %59 = getelementptr inbounds i8, ptr %3, i64 248
  %60 = load ptr, ptr %59, align 8, !tbaa !17
  %61 = getelementptr inbounds i64, ptr %60, i64 %0
  store i64 %.078.lcssa, ptr %61, align 8, !tbaa !18
  %62 = getelementptr inbounds i8, ptr %3, i64 256
  %63 = add nsw i64 %1, 1
  tail call void @_ZN11alglib_impl23ivectorsetlengthatleastEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %62, i64 noundef %63, ptr noundef %4)
  br i1 %7, label %.lr.ph103, label %._crit_edge104

.lr.ph103:                                        ; preds = %._crit_edge97
  %64 = getelementptr inbounds i8, ptr %3, i64 312
  br label %65

65:                                               ; preds = %.lr.ph103, %65
  %.0101 = phi i64 [ 0, %.lr.ph103 ], [ %69, %65 ]
  %.3100 = phi i64 [ 0, %.lr.ph103 ], [ %70, %65 ]
  %66 = tail call noundef i64 @_ZN11alglib_impl9ae_minintEllPNS_8ae_stateE(i64 noundef %.3100, i64 noundef %2, ptr noundef %4)
  %67 = load ptr, ptr %64, align 8, !tbaa !17
  %68 = getelementptr inbounds i64, ptr %67, i64 %.3100
  store i64 %66, ptr %68, align 8, !tbaa !18
  %69 = tail call noundef i64 @_ZN11alglib_impl9ae_maxintEllPNS_8ae_stateE(i64 noundef %.0101, i64 noundef %66, ptr noundef %4)
  %70 = add nuw nsw i64 %.3100, 1
  %exitcond110.not = icmp eq i64 %70, %1
  br i1 %exitcond110.not, label %._crit_edge104, label %65, !llvm.loop !27

._crit_edge104:                                   ; preds = %65, %._crit_edge97
  %.0.lcssa = phi i64 [ 0, %._crit_edge97 ], [ %69, %65 ]
  %71 = getelementptr inbounds i8, ptr %3, i64 312
  %72 = load ptr, ptr %71, align 8, !tbaa !17
  %73 = getelementptr inbounds i64, ptr %72, i64 %1
  store i64 %.0.lcssa, ptr %73, align 8, !tbaa !18
  ret void
}

declare void @_ZN11alglib_impl23rvectorsetlengthatleastEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef, i64 noundef, ptr noundef) local_unnamed_addr #0

declare void @_ZN11alglib_impl23ivectorsetlengthatleastEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef, i64 noundef, ptr noundef) local_unnamed_addr #0

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

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

attributes #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" }

!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, !8, i64 320}
!6 = !{!"_ZTSN11alglib_impl12sparsematrixE", !7, i64 0, !7, i64 64, !7, i64 128, !7, i64 192, !7, i64 256, !8, i64 320, !8, i64 328, !8, i64 336, !8, i64 344, !8, i64 352, !8, i64 360}
!7 = !{!"_ZTSN11alglib_impl9ae_vectorE", !8, i64 0, !8, i64 8, !11, i64 16, !12, i64 24, !9, i64 56}
!8 = !{!"long", !9, i64 0}
!9 = !{!"omnipotent char", !10, i64 0}
!10 = !{!"Simple C++ TBAA"}
!11 = !{!"bool", !9, i64 0}
!12 = !{!"_ZTSN11alglib_impl12ae_dyn_blockE", !13, i64 0, !13, i64 8, !13, i64 16, !13, i64 24}
!13 = !{!"any pointer", !9, i64 0}
!14 = !{!6, !8, i64 352}
!15 = !{!6, !8, i64 328}
!16 = !{!6, !8, i64 336}
!17 = !{!9, !9, i64 0}
!18 = !{!8, !8, i64 0}
!19 = distinct !{!19, !20}
!20 = !{!"llvm.loop.mustprogress"}
!21 = !{!22, !22, i64 0}
!22 = !{!"double", !9, i64 0}
!23 = distinct !{!23, !20}
!24 = distinct !{!24, !25}
!25 = !{!"llvm.loop.unroll.disable"}
!26 = distinct !{!26, !20}
!27 = distinct !{!27, !20}


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