; LLVM IR from Dimandragon/non-parametric-dsp :: alglib-cpp/src (interpolation)

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

@.str.562 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.563 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.564 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.565 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.566 = external hidden unnamed_addr constant [49 x i8], align 1
@.str.567 = external hidden unnamed_addr constant [31 x i8], align 1
@.str.568 = external hidden unnamed_addr constant [31 x i8], align 1
@.str.569 = external hidden unnamed_addr constant [55 x i8], align 1
@.str.570 = external hidden unnamed_addr constant [31 x i8], align 1
@.str.571 = external hidden unnamed_addr constant [33 x i8], align 1
@.str.572 = external hidden unnamed_addr constant [55 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 nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #1

; 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) #2

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN11alglib_impl12lsfitlinearcEPKNS_9ae_vectorEPKNS_9ae_matrixES5_lllPS0_PNS_11lsfitreportEPNS_8ae_stateE(ptr noundef %0, ptr noundef %1, ptr noundef %2, i64 noundef %3, i64 noundef %4, i64 noundef %5, ptr noundef %6, ptr noundef %7, ptr noundef %8) #3 {
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca i64, align 8
  %14 = alloca i64, align 8
  %15 = alloca i64, align 8
  %16 = alloca ptr, align 8
  %17 = alloca ptr, align 8
  %18 = alloca ptr, align 8
  %19 = alloca %"struct.alglib_impl::ae_frame", align 8
  %20 = alloca %"struct.alglib_impl::ae_vector", align 8
  %21 = alloca %"struct.alglib_impl::ae_vector", align 8
  %22 = alloca i64, align 8
  store ptr %0, ptr %10, align 8, !tbaa !5
  store ptr %1, ptr %11, align 8, !tbaa !5
  store ptr %2, ptr %12, align 8, !tbaa !5
  store i64 %3, ptr %13, align 8, !tbaa !9
  store i64 %4, ptr %14, align 8, !tbaa !9
  store i64 %5, ptr %15, align 8, !tbaa !9
  store ptr %6, ptr %16, align 8, !tbaa !5
  store ptr %7, ptr %17, align 8, !tbaa !5
  store ptr %8, ptr %18, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr %19) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr %20) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr %21) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #4
  %23 = load ptr, ptr %18, align 8, !tbaa !5
  call void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef %23, ptr noundef %19)
  call void @llvm.memset.p0.i64(ptr align 8 %20, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %21, i8 0, i64 64, i1 false)
  %24 = load ptr, ptr %10, align 8, !tbaa !5
  %25 = load ptr, ptr %18, align 8, !tbaa !5
  call void @_ZN11alglib_impl19ae_vector_init_copyEPNS_9ae_vectorEPKS0_PNS_8ae_stateEb(ptr noundef %20, ptr noundef %24, ptr noundef %25, i1 noundef zeroext true)
  %26 = load ptr, ptr %16, align 8, !tbaa !5
  call void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef %26)
  %27 = load ptr, ptr %17, align 8, !tbaa !5
  call void @_ZN11alglib_impl18_lsfitreport_clearEPv(ptr noundef %27)
  %28 = load ptr, ptr %18, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef %21, i64 noundef 0, i64 noundef 3, ptr noundef %28, i1 noundef zeroext true)
  %29 = load i64, ptr %13, align 8, !tbaa !9
  %30 = icmp sge i64 %29, 1
  %31 = load ptr, ptr %18, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %30, ptr noundef @.str.562, ptr noundef %31)
  %32 = load i64, ptr %14, align 8, !tbaa !9
  %33 = icmp sge i64 %32, 1
  %34 = load ptr, ptr %18, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %33, ptr noundef @.str.563, ptr noundef %34)
  %35 = load i64, ptr %15, align 8, !tbaa !9
  %36 = icmp sge i64 %35, 0
  %37 = load ptr, ptr %18, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %36, ptr noundef @.str.564, ptr noundef %37)
  %38 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %20, i32 0, i32 0
  %39 = load i64, ptr %38, align 8, !tbaa !11
  %40 = load i64, ptr %13, align 8, !tbaa !9
  %41 = icmp sge i64 %39, %40
  %42 = load ptr, ptr %18, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %41, ptr noundef @.str.565, ptr noundef %42)
  %43 = load i64, ptr %13, align 8, !tbaa !9
  %44 = load ptr, ptr %18, align 8, !tbaa !5
  %45 = call noundef zeroext i1 @_ZN11alglib_impl14isfinitevectorEPKNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %20, i64 noundef %43, ptr noundef %44)
  %46 = load ptr, ptr %18, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %45, ptr noundef @.str.566, ptr noundef %46)
  %47 = load ptr, ptr %11, align 8, !tbaa !5
  %48 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %47, i32 0, i32 0
  %49 = load i64, ptr %48, align 8, !tbaa !15
  %50 = load i64, ptr %13, align 8, !tbaa !9
  %51 = icmp sge i64 %49, %50
  %52 = load ptr, ptr %18, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %51, ptr noundef @.str.567, ptr noundef %52)
  %53 = load ptr, ptr %11, align 8, !tbaa !5
  %54 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %53, i32 0, i32 1
  %55 = load i64, ptr %54, align 8, !tbaa !17
  %56 = load i64, ptr %14, align 8, !tbaa !9
  %57 = icmp sge i64 %55, %56
  %58 = load ptr, ptr %18, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %57, ptr noundef @.str.568, ptr noundef %58)
  %59 = load ptr, ptr %11, align 8, !tbaa !5
  %60 = load i64, ptr %13, align 8, !tbaa !9
  %61 = load i64, ptr %14, align 8, !tbaa !9
  %62 = load ptr, ptr %18, align 8, !tbaa !5
  %63 = call noundef zeroext i1 @_ZN11alglib_impl20apservisfinitematrixEPKNS_9ae_matrixEllPNS_8ae_stateE(ptr noundef %59, i64 noundef %60, i64 noundef %61, ptr noundef %62)
  %64 = load ptr, ptr %18, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %63, ptr noundef @.str.569, ptr noundef %64)
  %65 = load ptr, ptr %12, align 8, !tbaa !5
  %66 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %65, i32 0, i32 0
  %67 = load i64, ptr %66, align 8, !tbaa !15
  %68 = load i64, ptr %15, align 8, !tbaa !9
  %69 = icmp sge i64 %67, %68
  %70 = load ptr, ptr %18, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %69, ptr noundef @.str.570, ptr noundef %70)
  %71 = load ptr, ptr %12, align 8, !tbaa !5
  %72 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %71, i32 0, i32 1
  %73 = load i64, ptr %72, align 8, !tbaa !17
  %74 = load i64, ptr %14, align 8, !tbaa !9
  %75 = add nsw i64 %74, 1
  %76 = icmp sge i64 %73, %75
  br i1 %76, label %80, label %77

77:                                               ; preds = %9
  %78 = load i64, ptr %15, align 8, !tbaa !9
  %79 = icmp eq i64 %78, 0
  br label %80

80:                                               ; preds = %77, %9
  %81 = phi i1 [ true, %9 ], [ %79, %77 ]
  %82 = load ptr, ptr %18, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %81, ptr noundef @.str.571, ptr noundef %82)
  %83 = load ptr, ptr %12, align 8, !tbaa !5
  %84 = load i64, ptr %15, align 8, !tbaa !9
  %85 = load i64, ptr %14, align 8, !tbaa !9
  %86 = add nsw i64 %85, 1
  %87 = load ptr, ptr %18, align 8, !tbaa !5
  %88 = call noundef zeroext i1 @_ZN11alglib_impl20apservisfinitematrixEPKNS_9ae_matrixEllPNS_8ae_stateE(ptr noundef %83, i64 noundef %84, i64 noundef %86, ptr noundef %87)
  %89 = load ptr, ptr %18, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %88, ptr noundef @.str.572, ptr noundef %89)
  %90 = load i64, ptr %13, align 8, !tbaa !9
  %91 = load ptr, ptr %18, align 8, !tbaa !5
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %21, i64 noundef %90, ptr noundef %91)
  store i64 0, ptr %22, align 8, !tbaa !9
  br label %92

92:                                               ; preds = %102, %80
  %93 = load i64, ptr %22, align 8, !tbaa !9
  %94 = load i64, ptr %13, align 8, !tbaa !9
  %95 = sub nsw i64 %94, 1
  %96 = icmp sle i64 %93, %95
  br i1 %96, label %97, label %105

97:                                               ; preds = %92
  %98 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %21, i32 0, i32 4
  %99 = load ptr, ptr %98, align 8, !tbaa !18
  %100 = load i64, ptr %22, align 8, !tbaa !9
  %101 = getelementptr inbounds double, ptr %99, i64 %100
  store double 1.000000e+00, ptr %101, align 8, !tbaa !19
  br label %102

102:                                              ; preds = %97
  %103 = load i64, ptr %22, align 8, !tbaa !9
  %104 = add nsw i64 %103, 1
  store i64 %104, ptr %22, align 8, !tbaa !9
  br label %92, !llvm.loop !21

105:                                              ; preds = %92
  %106 = load ptr, ptr %11, align 8, !tbaa !5
  %107 = load ptr, ptr %12, align 8, !tbaa !5
  %108 = load i64, ptr %13, align 8, !tbaa !9
  %109 = load i64, ptr %14, align 8, !tbaa !9
  %110 = load i64, ptr %15, align 8, !tbaa !9
  %111 = load ptr, ptr %16, align 8, !tbaa !5
  %112 = load ptr, ptr %17, align 8, !tbaa !5
  %113 = load ptr, ptr %18, align 8, !tbaa !5
  call void @_ZN11alglib_impl13lsfitlinearwcEPKNS_9ae_vectorES2_PKNS_9ae_matrixES5_lllPS0_PNS_11lsfitreportEPNS_8ae_stateE(ptr noundef %20, ptr noundef %21, ptr noundef %106, ptr noundef %107, i64 noundef %108, i64 noundef %109, i64 noundef %110, ptr noundef %111, ptr noundef %112, ptr noundef %113)
  %114 = load ptr, ptr %18, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %114)
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr %21) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr %20) #4
  call void @llvm.lifetime.end.p0(i64 32, ptr %19) #4
  ret void
}

declare void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef) #2

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

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

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

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

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

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 = !{!12, !10, i64 0}
!12 = !{!"_ZTSN11alglib_impl9ae_vectorE", !10, i64 0, !10, i64 8, !13, i64 16, !14, i64 24, !7, i64 56}
!13 = !{!"bool", !7, i64 0}
!14 = !{!"_ZTSN11alglib_impl12ae_dyn_blockE", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24}
!15 = !{!16, !10, i64 0}
!16 = !{!"_ZTSN11alglib_impl9ae_matrixE", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !13, i64 32, !14, i64 40, !7, i64 72}
!17 = !{!16, !10, i64 8}
!18 = !{!7, !7, i64 0}
!19 = !{!20, !20, i64 0}
!20 = !{!"double", !7, i64 0}
!21 = distinct !{!21, !22}
!22 = !{!"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.0 }
%union.anon.0 = type { ptr }

@.str.562 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.563 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.564 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.565 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.566 = external hidden unnamed_addr constant [49 x i8], align 1
@.str.567 = external hidden unnamed_addr constant [31 x i8], align 1
@.str.568 = external hidden unnamed_addr constant [31 x i8], align 1
@.str.569 = external hidden unnamed_addr constant [55 x i8], align 1
@.str.570 = external hidden unnamed_addr constant [31 x i8], align 1
@.str.571 = external hidden unnamed_addr constant [33 x i8], align 1
@.str.572 = external hidden unnamed_addr constant [55 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 nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #1

; Function Attrs: mustprogress 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) local_unnamed_addr #2

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN11alglib_impl12lsfitlinearcEPKNS_9ae_vectorEPKNS_9ae_matrixES5_lllPS0_PNS_11lsfitreportEPNS_8ae_stateE(ptr noundef %0, ptr noundef %1, ptr noundef %2, i64 noundef %3, i64 noundef %4, i64 noundef %5, ptr noundef %6, ptr noundef %7, ptr noundef %8) local_unnamed_addr #3 {
  %10 = alloca %"struct.alglib_impl::ae_frame", align 8
  %11 = alloca %"struct.alglib_impl::ae_vector", align 8
  %12 = alloca %"struct.alglib_impl::ae_vector", align 8
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %10) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %11) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %12) #4
  call void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef %8, ptr noundef nonnull %10)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %11, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %12, i8 0, i64 64, i1 false)
  call void @_ZN11alglib_impl19ae_vector_init_copyEPNS_9ae_vectorEPKS0_PNS_8ae_stateEb(ptr noundef nonnull %11, ptr noundef %0, ptr noundef %8, i1 noundef zeroext true)
  call void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef %6)
  call void @_ZN11alglib_impl18_lsfitreport_clearEPv(ptr noundef %7)
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef nonnull %12, i64 noundef 0, i64 noundef 3, ptr noundef %8, i1 noundef zeroext true)
  %13 = icmp sgt i64 %3, 0
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %13, ptr noundef nonnull @.str.562, ptr noundef %8)
  %14 = icmp sgt i64 %4, 0
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %14, ptr noundef nonnull @.str.563, ptr noundef %8)
  %15 = icmp sgt i64 %5, -1
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %15, ptr noundef nonnull @.str.564, ptr noundef %8)
  %16 = load i64, ptr %11, align 8, !tbaa !5
  %17 = icmp sge i64 %16, %3
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %17, ptr noundef nonnull @.str.565, ptr noundef %8)
  %18 = call noundef zeroext i1 @_ZN11alglib_impl14isfinitevectorEPKNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %11, i64 noundef %3, ptr noundef %8)
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %18, ptr noundef nonnull @.str.566, ptr noundef %8)
  %19 = load i64, ptr %1, align 8, !tbaa !13
  %20 = icmp sge i64 %19, %3
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %20, ptr noundef nonnull @.str.567, ptr noundef %8)
  %21 = getelementptr inbounds i8, ptr %1, i64 8
  %22 = load i64, ptr %21, align 8, !tbaa !15
  %23 = icmp sge i64 %22, %4
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %23, ptr noundef nonnull @.str.568, ptr noundef %8)
  %24 = call noundef zeroext i1 @_ZN11alglib_impl20apservisfinitematrixEPKNS_9ae_matrixEllPNS_8ae_stateE(ptr noundef nonnull %1, i64 noundef %3, i64 noundef %4, ptr noundef %8)
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %24, ptr noundef nonnull @.str.569, ptr noundef %8)
  %25 = load i64, ptr %2, align 8, !tbaa !13
  %26 = icmp sge i64 %25, %5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %26, ptr noundef nonnull @.str.570, ptr noundef %8)
  %27 = getelementptr inbounds i8, ptr %2, i64 8
  %28 = load i64, ptr %27, align 8, !tbaa !15
  %29 = add nsw i64 %4, 1
  %30 = icmp sgt i64 %28, %4
  %31 = icmp eq i64 %5, 0
  %32 = or i1 %31, %30
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %32, ptr noundef nonnull @.str.571, ptr noundef %8)
  %33 = call noundef zeroext i1 @_ZN11alglib_impl20apservisfinitematrixEPKNS_9ae_matrixEllPNS_8ae_stateE(ptr noundef nonnull %2, i64 noundef %5, i64 noundef %29, ptr noundef %8)
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %33, ptr noundef nonnull @.str.572, ptr noundef %8)
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %12, i64 noundef %3, ptr noundef %8)
  br i1 %13, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %9
  %34 = getelementptr inbounds i8, ptr %12, i64 56
  %xtraiter = and i64 %3, 3
  %35 = icmp ult i64 %3, 4
  br i1 %35, label %._crit_edge.loopexit.unr-lcssa, label %.lr.ph.new

.lr.ph.new:                                       ; preds = %.lr.ph
  %unroll_iter = and i64 %3, 9223372036854775804
  br label %36

36:                                               ; preds = %36, %.lr.ph.new
  %.055 = phi i64 [ 0, %.lr.ph.new ], [ %48, %36 ]
  %niter = phi i64 [ 0, %.lr.ph.new ], [ %niter.next.3, %36 ]
  %37 = load ptr, ptr %34, align 8, !tbaa !16
  %38 = getelementptr inbounds double, ptr %37, i64 %.055
  store double 1.000000e+00, ptr %38, align 8, !tbaa !17
  %39 = or disjoint i64 %.055, 1
  %40 = load ptr, ptr %34, align 8, !tbaa !16
  %41 = getelementptr inbounds double, ptr %40, i64 %39
  store double 1.000000e+00, ptr %41, align 8, !tbaa !17
  %42 = or disjoint i64 %.055, 2
  %43 = load ptr, ptr %34, align 8, !tbaa !16
  %44 = getelementptr inbounds double, ptr %43, i64 %42
  store double 1.000000e+00, ptr %44, align 8, !tbaa !17
  %45 = or disjoint i64 %.055, 3
  %46 = load ptr, ptr %34, align 8, !tbaa !16
  %47 = getelementptr inbounds double, ptr %46, i64 %45
  store double 1.000000e+00, ptr %47, align 8, !tbaa !17
  %48 = add nuw nsw i64 %.055, 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_edge.loopexit.unr-lcssa, label %36, !llvm.loop !19

._crit_edge.loopexit.unr-lcssa:                   ; preds = %36, %.lr.ph
  %.055.unr = phi i64 [ 0, %.lr.ph ], [ %48, %36 ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %._crit_edge, label %.epil.preheader

.epil.preheader:                                  ; preds = %._crit_edge.loopexit.unr-lcssa, %.epil.preheader
  %.055.epil = phi i64 [ %51, %.epil.preheader ], [ %.055.unr, %._crit_edge.loopexit.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.epil.preheader ], [ 0, %._crit_edge.loopexit.unr-lcssa ]
  %49 = load ptr, ptr %34, align 8, !tbaa !16
  %50 = getelementptr inbounds double, ptr %49, i64 %.055.epil
  store double 1.000000e+00, ptr %50, align 8, !tbaa !17
  %51 = add nuw nsw i64 %.055.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_edge, label %.epil.preheader, !llvm.loop !21

._crit_edge:                                      ; preds = %._crit_edge.loopexit.unr-lcssa, %.epil.preheader, %9
  call void @_ZN11alglib_impl13lsfitlinearwcEPKNS_9ae_vectorES2_PKNS_9ae_matrixES5_lllPS0_PNS_11lsfitreportEPNS_8ae_stateE(ptr noundef nonnull %11, ptr noundef nonnull %12, ptr noundef nonnull %1, ptr noundef nonnull %2, i64 noundef %3, i64 noundef %4, i64 noundef %5, ptr noundef %6, ptr noundef %7, ptr noundef %8)
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %8)
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %12) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %11) #4
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %10) #4
  ret void
}

declare void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(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_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_impl19ae_vector_init_copyEPNS_9ae_vectorEPKS0_PNS_8ae_stateEb(ptr noundef, ptr noundef, ptr noundef, i1 noundef zeroext) local_unnamed_addr #2

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

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

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

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, !7, i64 0}
!6 = !{!"_ZTSN11alglib_impl9ae_vectorE", !7, i64 0, !7, i64 8, !10, i64 16, !11, i64 24, !8, i64 56}
!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 = !{!14, !7, i64 0}
!14 = !{!"_ZTSN11alglib_impl9ae_matrixE", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !10, i64 32, !11, i64 40, !8, i64 72}
!15 = !{!14, !7, i64 8}
!16 = !{!8, !8, i64 0}
!17 = !{!18, !18, i64 0}
!18 = !{!"double", !8, i64 0}
!19 = distinct !{!19, !20}
!20 = !{!"llvm.loop.mustprogress"}
!21 = distinct !{!21, !22}
!22 = !{!"llvm.loop.unroll.disable"}


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