; LLVM IR from venumb/ZSPACE :: cpp/depends/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 }

@.str.230 = external hidden unnamed_addr constant [46 x i8], align 1
@.str.231 = external hidden unnamed_addr constant [46 x i8], align 1
@.str.232 = external hidden unnamed_addr constant [57 x i8], align 1
@.str.233 = external hidden unnamed_addr constant [51 x i8], align 1
@.str.234 = external hidden unnamed_addr constant [51 x i8], align 1
@.str.235 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.236 = external hidden unnamed_addr constant [37 x i8], align 1
@.str.237 = external hidden unnamed_addr constant [37 x i8], align 1
@.str.238 = external hidden unnamed_addr constant [30 x i8], align 1
@.str.239 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.240 = external hidden unnamed_addr constant [59 x i8], align 1
@.str.241 = external hidden unnamed_addr constant [59 x i8], align 1
@.str.242 = external hidden unnamed_addr constant [60 x i8], align 1
@.str.243 = external hidden unnamed_addr constant [70 x i8], align 1
@.str.244 = external hidden unnamed_addr constant [40 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
define dso_local void @_ZN11alglib_impl22spline1dconvdiff2cubicEPNS_9ae_vectorES1_lldldS1_lS1_S1_S1_PNS_8ae_stateE(ptr noundef %0, ptr noundef %1, i64 noundef %2, i64 noundef %3, double noundef %4, i64 noundef %5, double noundef %6, ptr noundef %7, i64 noundef %8, ptr noundef %9, ptr noundef %10, ptr noundef %11, ptr noundef %12) #3 {
  %14 = alloca ptr, align 8
  %15 = alloca ptr, align 8
  %16 = alloca i64, align 8
  %17 = alloca i64, align 8
  %18 = alloca double, align 8
  %19 = alloca i64, align 8
  %20 = alloca double, align 8
  %21 = alloca ptr, align 8
  %22 = alloca i64, align 8
  %23 = alloca ptr, align 8
  %24 = alloca ptr, align 8
  %25 = alloca ptr, align 8
  %26 = alloca ptr, align 8
  %27 = alloca %"struct.alglib_impl::ae_frame", align 8
  %28 = alloca %"struct.alglib_impl::ae_vector", align 8
  %29 = alloca %"struct.alglib_impl::ae_vector", align 8
  %30 = alloca %"struct.alglib_impl::ae_vector", align 8
  %31 = alloca %"struct.alglib_impl::ae_vector", align 8
  %32 = alloca %"struct.alglib_impl::ae_vector", align 8
  %33 = alloca %"struct.alglib_impl::ae_vector", align 8
  %34 = alloca %"struct.alglib_impl::ae_vector", align 8
  %35 = alloca %"struct.alglib_impl::ae_vector", align 8
  %36 = alloca %"struct.alglib_impl::ae_vector", align 8
  %37 = alloca %"struct.alglib_impl::ae_vector", align 8
  %38 = alloca %"struct.alglib_impl::ae_vector", align 8
  %39 = alloca i64, align 8
  %40 = alloca i64, align 8
  %41 = alloca double, align 8
  %42 = alloca double, align 8
  store ptr %0, ptr %14, align 8, !tbaa !5
  store ptr %1, ptr %15, align 8, !tbaa !5
  store i64 %2, ptr %16, align 8, !tbaa !9
  store i64 %3, ptr %17, align 8, !tbaa !9
  store double %4, ptr %18, align 8, !tbaa !11
  store i64 %5, ptr %19, align 8, !tbaa !9
  store double %6, ptr %20, align 8, !tbaa !11
  store ptr %7, ptr %21, align 8, !tbaa !5
  store i64 %8, ptr %22, align 8, !tbaa !9
  store ptr %9, ptr %23, align 8, !tbaa !5
  store ptr %10, ptr %24, align 8, !tbaa !5
  store ptr %11, ptr %25, align 8, !tbaa !5
  store ptr %12, ptr %26, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr %27) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr %28) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr %29) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr %30) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr %31) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr %32) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr %33) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr %34) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr %35) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr %36) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr %37) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr %38) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %39) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %40) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %41) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %42) #4
  %43 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef %43, ptr noundef %27)
  call void @llvm.memset.p0.i64(ptr align 8 %28, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %29, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %30, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %31, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %32, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %33, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %34, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %35, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %36, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %37, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %38, i8 0, i64 64, i1 false)
  %44 = load ptr, ptr %14, align 8, !tbaa !5
  %45 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl19ae_vector_init_copyEPNS_9ae_vectorES1_PNS_8ae_stateEb(ptr noundef %28, ptr noundef %44, ptr noundef %45, i1 noundef zeroext true)
  store ptr %28, ptr %14, align 8, !tbaa !5
  %46 = load ptr, ptr %15, align 8, !tbaa !5
  %47 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl19ae_vector_init_copyEPNS_9ae_vectorES1_PNS_8ae_stateEb(ptr noundef %29, ptr noundef %46, ptr noundef %47, i1 noundef zeroext true)
  store ptr %29, ptr %15, align 8, !tbaa !5
  %48 = load ptr, ptr %21, align 8, !tbaa !5
  %49 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl19ae_vector_init_copyEPNS_9ae_vectorES1_PNS_8ae_stateEb(ptr noundef %30, ptr noundef %48, ptr noundef %49, i1 noundef zeroext true)
  store ptr %30, ptr %21, align 8, !tbaa !5
  %50 = load ptr, ptr %23, align 8, !tbaa !5
  call void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef %50)
  %51 = load ptr, ptr %24, align 8, !tbaa !5
  call void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef %51)
  %52 = load ptr, ptr %25, align 8, !tbaa !5
  call void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef %52)
  %53 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef %31, i64 noundef 0, i64 noundef 3, ptr noundef %53, i1 noundef zeroext true)
  %54 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef %32, i64 noundef 0, i64 noundef 3, ptr noundef %54, i1 noundef zeroext true)
  %55 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef %33, i64 noundef 0, i64 noundef 3, ptr noundef %55, i1 noundef zeroext true)
  %56 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef %34, i64 noundef 0, i64 noundef 3, ptr noundef %56, i1 noundef zeroext true)
  %57 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef %35, i64 noundef 0, i64 noundef 3, ptr noundef %57, i1 noundef zeroext true)
  %58 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef %36, i64 noundef 0, i64 noundef 3, ptr noundef %58, i1 noundef zeroext true)
  %59 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef %37, i64 noundef 0, i64 noundef 2, ptr noundef %59, i1 noundef zeroext true)
  %60 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef %38, i64 noundef 0, i64 noundef 2, ptr noundef %60, i1 noundef zeroext true)
  %61 = load i64, ptr %17, align 8, !tbaa !9
  %62 = icmp eq i64 %61, -1
  br i1 %62, label %72, label %63

63:                                               ; preds = %13
  %64 = load i64, ptr %17, align 8, !tbaa !9
  %65 = icmp eq i64 %64, 0
  br i1 %65, label %72, label %66

66:                                               ; preds = %63
  %67 = load i64, ptr %17, align 8, !tbaa !9
  %68 = icmp eq i64 %67, 1
  br i1 %68, label %72, label %69

69:                                               ; preds = %66
  %70 = load i64, ptr %17, align 8, !tbaa !9
  %71 = icmp eq i64 %70, 2
  br label %72

72:                                               ; preds = %69, %66, %63, %13
  %73 = phi i1 [ true, %66 ], [ true, %63 ], [ true, %13 ], [ %71, %69 ]
  %74 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %73, ptr noundef @.str.230, ptr noundef %74)
  %75 = load i64, ptr %19, align 8, !tbaa !9
  %76 = icmp eq i64 %75, -1
  br i1 %76, label %86, label %77

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

80:                                               ; preds = %77
  %81 = load i64, ptr %19, align 8, !tbaa !9
  %82 = icmp eq i64 %81, 1
  br i1 %82, label %86, label %83

83:                                               ; preds = %80
  %84 = load i64, ptr %19, align 8, !tbaa !9
  %85 = icmp eq i64 %84, 2
  br label %86

86:                                               ; preds = %83, %80, %77, %72
  %87 = phi i1 [ true, %80 ], [ true, %77 ], [ true, %72 ], [ %85, %83 ]
  %88 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %87, ptr noundef @.str.231, ptr noundef %88)
  %89 = load i64, ptr %19, align 8, !tbaa !9
  %90 = icmp eq i64 %89, -1
  br i1 %90, label %91, label %94

91:                                               ; preds = %86
  %92 = load i64, ptr %17, align 8, !tbaa !9
  %93 = icmp eq i64 %92, -1
  br i1 %93, label %102, label %94

94:                                               ; preds = %91, %86
  %95 = load i64, ptr %19, align 8, !tbaa !9
  %96 = icmp ne i64 %95, -1
  br i1 %96, label %97, label %100

97:                                               ; preds = %94
  %98 = load i64, ptr %17, align 8, !tbaa !9
  %99 = icmp ne i64 %98, -1
  br label %100

100:                                              ; preds = %97, %94
  %101 = phi i1 [ false, %94 ], [ %99, %97 ]
  br label %102

102:                                              ; preds = %100, %91
  %103 = phi i1 [ true, %91 ], [ %101, %100 ]
  %104 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %103, ptr noundef @.str.232, ptr noundef %104)
  %105 = load i64, ptr %17, align 8, !tbaa !9
  %106 = icmp eq i64 %105, 1
  br i1 %106, label %110, label %107

107:                                              ; preds = %102
  %108 = load i64, ptr %17, align 8, !tbaa !9
  %109 = icmp eq i64 %108, 2
  br i1 %109, label %110, label %115

110:                                              ; preds = %107, %102
  %111 = load double, ptr %18, align 8, !tbaa !11
  %112 = load ptr, ptr %26, align 8, !tbaa !5
  %113 = call noundef zeroext i1 @_ZN11alglib_impl11ae_isfiniteEdPNS_8ae_stateE(double noundef %111, ptr noundef %112)
  %114 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %113, ptr noundef @.str.233, ptr noundef %114)
  br label %115

115:                                              ; preds = %110, %107
  %116 = load i64, ptr %19, align 8, !tbaa !9
  %117 = icmp eq i64 %116, 1
  br i1 %117, label %121, label %118

118:                                              ; preds = %115
  %119 = load i64, ptr %19, align 8, !tbaa !9
  %120 = icmp eq i64 %119, 2
  br i1 %120, label %121, label %126

121:                                              ; preds = %118, %115
  %122 = load double, ptr %20, align 8, !tbaa !11
  %123 = load ptr, ptr %26, align 8, !tbaa !5
  %124 = call noundef zeroext i1 @_ZN11alglib_impl11ae_isfiniteEdPNS_8ae_stateE(double noundef %122, ptr noundef %123)
  %125 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %124, ptr noundef @.str.234, ptr noundef %125)
  br label %126

126:                                              ; preds = %121, %118
  %127 = load i64, ptr %16, align 8, !tbaa !9
  %128 = icmp sge i64 %127, 2
  %129 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %128, ptr noundef @.str.235, ptr noundef %129)
  %130 = load ptr, ptr %14, align 8, !tbaa !5
  %131 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %130, i32 0, i32 0
  %132 = load i64, ptr %131, align 8, !tbaa !13
  %133 = load i64, ptr %16, align 8, !tbaa !9
  %134 = icmp sge i64 %132, %133
  %135 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %134, ptr noundef @.str.236, ptr noundef %135)
  %136 = load ptr, ptr %15, align 8, !tbaa !5
  %137 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %136, i32 0, i32 0
  %138 = load i64, ptr %137, align 8, !tbaa !13
  %139 = load i64, ptr %16, align 8, !tbaa !9
  %140 = icmp sge i64 %138, %139
  %141 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %140, ptr noundef @.str.237, ptr noundef %141)
  %142 = load i64, ptr %22, align 8, !tbaa !9
  %143 = icmp sge i64 %142, 2
  %144 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %143, ptr noundef @.str.238, ptr noundef %144)
  %145 = load ptr, ptr %21, align 8, !tbaa !5
  %146 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %145, i32 0, i32 0
  %147 = load i64, ptr %146, align 8, !tbaa !13
  %148 = load i64, ptr %22, align 8, !tbaa !9
  %149 = icmp sge i64 %147, %148
  %150 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %149, ptr noundef @.str.239, ptr noundef %150)
  %151 = load i64, ptr %16, align 8, !tbaa !9
  store i64 %151, ptr %40, align 8, !tbaa !9
  %152 = load i64, ptr %17, align 8, !tbaa !9
  %153 = icmp eq i64 %152, -1
  br i1 %153, label %154, label %157

154:                                              ; preds = %126
  %155 = load i64, ptr %16, align 8, !tbaa !9
  %156 = sub nsw i64 %155, 1
  store i64 %156, ptr %40, align 8, !tbaa !9
  br label %157

157:                                              ; preds = %154, %126
  %158 = load ptr, ptr %14, align 8, !tbaa !5
  %159 = load i64, ptr %16, align 8, !tbaa !9
  %160 = load ptr, ptr %26, align 8, !tbaa !5
  %161 = call noundef zeroext i1 @_ZN11alglib_impl14isfinitevectorEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %158, i64 noundef %159, ptr noundef %160)
  %162 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %161, ptr noundef @.str.240, ptr noundef %162)
  %163 = load ptr, ptr %15, align 8, !tbaa !5
  %164 = load i64, ptr %40, align 8, !tbaa !9
  %165 = load ptr, ptr %26, align 8, !tbaa !5
  %166 = call noundef zeroext i1 @_ZN11alglib_impl14isfinitevectorEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %163, i64 noundef %164, ptr noundef %165)
  %167 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %166, ptr noundef @.str.241, ptr noundef %167)
  %168 = load ptr, ptr %21, align 8, !tbaa !5
  %169 = load i64, ptr %22, align 8, !tbaa !9
  %170 = load ptr, ptr %26, align 8, !tbaa !5
  %171 = call noundef zeroext i1 @_ZN11alglib_impl14isfinitevectorEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %168, i64 noundef %169, ptr noundef %170)
  %172 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %171, ptr noundef @.str.242, ptr noundef %172)
  %173 = load ptr, ptr %14, align 8, !tbaa !5
  %174 = load ptr, ptr %15, align 8, !tbaa !5
  %175 = load i64, ptr %16, align 8, !tbaa !9
  %176 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_implL24spline1d_heapsortppointsEPNS_9ae_vectorES1_S1_lPNS_8ae_stateE(ptr noundef %173, ptr noundef %174, ptr noundef %37, i64 noundef %175, ptr noundef %176)
  %177 = load ptr, ptr %14, align 8, !tbaa !5
  %178 = load i64, ptr %16, align 8, !tbaa !9
  %179 = load ptr, ptr %26, align 8, !tbaa !5
  %180 = call noundef zeroext i1 @_ZN11alglib_impl11aredistinctEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %177, i64 noundef %178, ptr noundef %179)
  %181 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %180, ptr noundef @.str.243, ptr noundef %181)
  %182 = load i64, ptr %16, align 8, !tbaa !9
  %183 = load i64, ptr %22, align 8, !tbaa !9
  %184 = load ptr, ptr %26, align 8, !tbaa !5
  %185 = call noundef i64 @_ZN11alglib_impl9ae_maxintEllPNS_8ae_stateE(i64 noundef %182, i64 noundef %183, ptr noundef %184)
  %186 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %36, i64 noundef %185, ptr noundef %186)
  %187 = load i64, ptr %19, align 8, !tbaa !9
  %188 = icmp eq i64 %187, -1
  br i1 %188, label %189, label %228

189:                                              ; preds = %157
  %190 = load i64, ptr %17, align 8, !tbaa !9
  %191 = icmp eq i64 %190, -1
  br i1 %191, label %192, label %228

192:                                              ; preds = %189
  store i64 0, ptr %39, align 8, !tbaa !9
  br label %193

193:                                              ; preds = %224, %192
  %194 = load i64, ptr %39, align 8, !tbaa !9
  %195 = load i64, ptr %22, align 8, !tbaa !9
  %196 = sub nsw i64 %195, 1
  %197 = icmp sle i64 %194, %196
  br i1 %197, label %198, label %227

198:                                              ; preds = %193
  %199 = load ptr, ptr %21, align 8, !tbaa !5
  %200 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %199, i32 0, i32 4
  %201 = load ptr, ptr %200, align 8, !tbaa !17
  %202 = load i64, ptr %39, align 8, !tbaa !9
  %203 = getelementptr inbounds double, ptr %201, i64 %202
  %204 = load double, ptr %203, align 8, !tbaa !11
  store double %204, ptr %41, align 8, !tbaa !11
  %205 = load ptr, ptr %14, align 8, !tbaa !5
  %206 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %205, i32 0, i32 4
  %207 = load ptr, ptr %206, align 8, !tbaa !17
  %208 = getelementptr inbounds double, ptr %207, i64 0
  %209 = load double, ptr %208, align 8, !tbaa !11
  %210 = load ptr, ptr %14, align 8, !tbaa !5
  %211 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %210, i32 0, i32 4
  %212 = load ptr, ptr %211, align 8, !tbaa !17
  %213 = load i64, ptr %16, align 8, !tbaa !9
  %214 = sub nsw i64 %213, 1
  %215 = getelementptr inbounds double, ptr %212, i64 %214
  %216 = load double, ptr %215, align 8, !tbaa !11
  %217 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl13apperiodicmapEPdddS0_PNS_8ae_stateE(ptr noundef %41, double noundef %209, double noundef %216, ptr noundef %42, ptr noundef %217)
  %218 = load double, ptr %41, align 8, !tbaa !11
  %219 = load ptr, ptr %21, align 8, !tbaa !5
  %220 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %219, i32 0, i32 4
  %221 = load ptr, ptr %220, align 8, !tbaa !17
  %222 = load i64, ptr %39, align 8, !tbaa !9
  %223 = getelementptr inbounds double, ptr %221, i64 %222
  store double %218, ptr %223, align 8, !tbaa !11
  br label %224

224:                                              ; preds = %198
  %225 = load i64, ptr %39, align 8, !tbaa !9
  %226 = add nsw i64 %225, 1
  store i64 %226, ptr %39, align 8, !tbaa !9
  br label %193, !llvm.loop !18

227:                                              ; preds = %193
  br label %228

228:                                              ; preds = %227, %189, %157
  %229 = load ptr, ptr %21, align 8, !tbaa !5
  %230 = load i64, ptr %22, align 8, !tbaa !9
  %231 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_implL24spline1d_heapsortppointsEPNS_9ae_vectorES1_S1_lPNS_8ae_stateE(ptr noundef %229, ptr noundef %36, ptr noundef %38, i64 noundef %230, ptr noundef %231)
  %232 = load ptr, ptr %14, align 8, !tbaa !5
  %233 = load ptr, ptr %15, align 8, !tbaa !5
  %234 = load i64, ptr %16, align 8, !tbaa !9
  %235 = load i64, ptr %17, align 8, !tbaa !9
  %236 = load double, ptr %18, align 8, !tbaa !11
  %237 = load i64, ptr %19, align 8, !tbaa !9
  %238 = load double, ptr %20, align 8, !tbaa !11
  %239 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_implL38spline1d_spline1dgriddiffcubicinternalEPNS_9ae_vectorES1_lldldS1_S1_S1_S1_S1_S1_PNS_8ae_stateE(ptr noundef %232, ptr noundef %233, i64 noundef %234, i64 noundef %235, double noundef %236, i64 noundef %237, double noundef %238, ptr noundef %35, ptr noundef %31, ptr noundef %32, ptr noundef %33, ptr noundef %34, ptr noundef %36, ptr noundef %239)
  %240 = load ptr, ptr %14, align 8, !tbaa !5
  %241 = load ptr, ptr %15, align 8, !tbaa !5
  %242 = load i64, ptr %16, align 8, !tbaa !9
  %243 = load ptr, ptr %21, align 8, !tbaa !5
  %244 = load i64, ptr %22, align 8, !tbaa !9
  %245 = load ptr, ptr %23, align 8, !tbaa !5
  %246 = load ptr, ptr %24, align 8, !tbaa !5
  %247 = load ptr, ptr %25, align 8, !tbaa !5
  %248 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl24spline1dconvdiffinternalEPNS_9ae_vectorES1_S1_lS1_lS1_bS1_bS1_bPNS_8ae_stateE(ptr noundef %240, ptr noundef %241, ptr noundef %35, i64 noundef %242, ptr noundef %243, i64 noundef %244, ptr noundef %245, i1 noundef zeroext true, ptr noundef %246, i1 noundef zeroext true, ptr noundef %247, i1 noundef zeroext true, ptr noundef %248)
  %249 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %36, i32 0, i32 0
  %250 = load i64, ptr %249, align 8, !tbaa !13
  %251 = load i64, ptr %22, align 8, !tbaa !9
  %252 = icmp sge i64 %250, %251
  %253 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %252, ptr noundef @.str.244, ptr noundef %253)
  store i64 0, ptr %39, align 8, !tbaa !9
  br label %254

254:                                              ; preds = %274, %228
  %255 = load i64, ptr %39, align 8, !tbaa !9
  %256 = load i64, ptr %22, align 8, !tbaa !9
  %257 = sub nsw i64 %256, 1
  %258 = icmp sle i64 %255, %257
  br i1 %258, label %259, label %277

259:                                              ; preds = %254
  %260 = load ptr, ptr %23, align 8, !tbaa !5
  %261 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %260, i32 0, i32 4
  %262 = load ptr, ptr %261, align 8, !tbaa !17
  %263 = load i64, ptr %39, align 8, !tbaa !9
  %264 = getelementptr inbounds double, ptr %262, i64 %263
  %265 = load double, ptr %264, align 8, !tbaa !11
  %266 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %36, i32 0, i32 4
  %267 = load ptr, ptr %266, align 8, !tbaa !17
  %268 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %38, i32 0, i32 4
  %269 = load ptr, ptr %268, align 8, !tbaa !17
  %270 = load i64, ptr %39, align 8, !tbaa !9
  %271 = getelementptr inbounds i64, ptr %269, i64 %270
  %272 = load i64, ptr %271, align 8, !tbaa !9
  %273 = getelementptr inbounds double, ptr %267, i64 %272
  store double %265, ptr %273, align 8, !tbaa !11
  br label %274

274:                                              ; preds = %259
  %275 = load i64, ptr %39, align 8, !tbaa !9
  %276 = add nsw i64 %275, 1
  store i64 %276, ptr %39, align 8, !tbaa !9
  br label %254, !llvm.loop !20

277:                                              ; preds = %254
  %278 = load ptr, ptr %23, align 8, !tbaa !5
  %279 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %278, i32 0, i32 4
  %280 = load ptr, ptr %279, align 8, !tbaa !17
  %281 = getelementptr inbounds double, ptr %280, i64 0
  %282 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %36, i32 0, i32 4
  %283 = load ptr, ptr %282, align 8, !tbaa !17
  %284 = getelementptr inbounds double, ptr %283, i64 0
  %285 = load i64, ptr %22, align 8, !tbaa !9
  %286 = sub nsw i64 %285, 1
  %287 = call noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef 0, i64 noundef %286)
  call void @_ZN11alglib_impl9ae_v_moveEPdlPKdll(ptr noundef %281, i64 noundef 1, ptr noundef %284, i64 noundef 1, i64 noundef %287)
  store i64 0, ptr %39, align 8, !tbaa !9
  br label %288

288:                                              ; preds = %308, %277
  %289 = load i64, ptr %39, align 8, !tbaa !9
  %290 = load i64, ptr %22, align 8, !tbaa !9
  %291 = sub nsw i64 %290, 1
  %292 = icmp sle i64 %289, %291
  br i1 %292, label %293, label %311

293:                                              ; preds = %288
  %294 = load ptr, ptr %24, align 8, !tbaa !5
  %295 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %294, i32 0, i32 4
  %296 = load ptr, ptr %295, align 8, !tbaa !17
  %297 = load i64, ptr %39, align 8, !tbaa !9
  %298 = getelementptr inbounds double, ptr %296, i64 %297
  %299 = load double, ptr %298, align 8, !tbaa !11
  %300 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %36, i32 0, i32 4
  %301 = load ptr, ptr %300, align 8, !tbaa !17
  %302 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %38, i32 0, i32 4
  %303 = load ptr, ptr %302, align 8, !tbaa !17
  %304 = load i64, ptr %39, align 8, !tbaa !9
  %305 = getelementptr inbounds i64, ptr %303, i64 %304
  %306 = load i64, ptr %305, align 8, !tbaa !9
  %307 = getelementptr inbounds double, ptr %301, i64 %306
  store double %299, ptr %307, align 8, !tbaa !11
  br label %308

308:                                              ; preds = %293
  %309 = load i64, ptr %39, align 8, !tbaa !9
  %310 = add nsw i64 %309, 1
  store i64 %310, ptr %39, align 8, !tbaa !9
  br label %288, !llvm.loop !21

311:                                              ; preds = %288
  %312 = load ptr, ptr %24, align 8, !tbaa !5
  %313 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %312, i32 0, i32 4
  %314 = load ptr, ptr %313, align 8, !tbaa !17
  %315 = getelementptr inbounds double, ptr %314, i64 0
  %316 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %36, i32 0, i32 4
  %317 = load ptr, ptr %316, align 8, !tbaa !17
  %318 = getelementptr inbounds double, ptr %317, i64 0
  %319 = load i64, ptr %22, align 8, !tbaa !9
  %320 = sub nsw i64 %319, 1
  %321 = call noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef 0, i64 noundef %320)
  call void @_ZN11alglib_impl9ae_v_moveEPdlPKdll(ptr noundef %315, i64 noundef 1, ptr noundef %318, i64 noundef 1, i64 noundef %321)
  store i64 0, ptr %39, align 8, !tbaa !9
  br label %322

322:                                              ; preds = %342, %311
  %323 = load i64, ptr %39, align 8, !tbaa !9
  %324 = load i64, ptr %22, align 8, !tbaa !9
  %325 = sub nsw i64 %324, 1
  %326 = icmp sle i64 %323, %325
  br i1 %326, label %327, label %345

327:                                              ; preds = %322
  %328 = load ptr, ptr %25, align 8, !tbaa !5
  %329 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %328, i32 0, i32 4
  %330 = load ptr, ptr %329, align 8, !tbaa !17
  %331 = load i64, ptr %39, align 8, !tbaa !9
  %332 = getelementptr inbounds double, ptr %330, i64 %331
  %333 = load double, ptr %332, align 8, !tbaa !11
  %334 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %36, i32 0, i32 4
  %335 = load ptr, ptr %334, align 8, !tbaa !17
  %336 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %38, i32 0, i32 4
  %337 = load ptr, ptr %336, align 8, !tbaa !17
  %338 = load i64, ptr %39, align 8, !tbaa !9
  %339 = getelementptr inbounds i64, ptr %337, i64 %338
  %340 = load i64, ptr %339, align 8, !tbaa !9
  %341 = getelementptr inbounds double, ptr %335, i64 %340
  store double %333, ptr %341, align 8, !tbaa !11
  br label %342

342:                                              ; preds = %327
  %343 = load i64, ptr %39, align 8, !tbaa !9
  %344 = add nsw i64 %343, 1
  store i64 %344, ptr %39, align 8, !tbaa !9
  br label %322, !llvm.loop !22

345:                                              ; preds = %322
  %346 = load ptr, ptr %25, align 8, !tbaa !5
  %347 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %346, i32 0, i32 4
  %348 = load ptr, ptr %347, align 8, !tbaa !17
  %349 = getelementptr inbounds double, ptr %348, i64 0
  %350 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %36, i32 0, i32 4
  %351 = load ptr, ptr %350, align 8, !tbaa !17
  %352 = getelementptr inbounds double, ptr %351, i64 0
  %353 = load i64, ptr %22, align 8, !tbaa !9
  %354 = sub nsw i64 %353, 1
  %355 = call noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef 0, i64 noundef %354)
  call void @_ZN11alglib_impl9ae_v_moveEPdlPKdll(ptr noundef %349, i64 noundef 1, ptr noundef %352, i64 noundef 1, i64 noundef %355)
  %356 = load ptr, ptr %26, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %356)
  call void @llvm.lifetime.end.p0(i64 8, ptr %42) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %41) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %40) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %39) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr %38) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr %37) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr %36) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr %35) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr %34) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr %33) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr %32) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr %31) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr %30) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr %29) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr %28) #4
  call void @llvm.lifetime.end.p0(i64 32, ptr %27) #4
  ret void
}

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

declare noundef zeroext i1 @_ZN11alglib_impl11ae_isfiniteEdPNS_8ae_stateE(double noundef, ptr noundef) #2

declare void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef) #2

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

declare void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef, i64 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_impl19ae_vector_init_copyEPNS_9ae_vectorES1_PNS_8ae_stateEb(ptr noundef, ptr noundef, ptr noundef, i1 noundef zeroext) #2

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

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

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

declare void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef) #2

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

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

; Function Attrs: mustprogress uwtable
declare hidden void @_ZN11alglib_implL38spline1d_spline1dgriddiffcubicinternalEPNS_9ae_vectorES1_lldldS1_S1_S1_S1_S1_S1_PNS_8ae_stateE(ptr noundef, ptr noundef, i64 noundef, i64 noundef, double noundef, i64 noundef, double noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #3

declare void @_ZN11alglib_impl13apperiodicmapEPdddS0_PNS_8ae_stateE(ptr noundef, double noundef, double noundef, ptr noundef, ptr noundef) #2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN11alglib_impl24spline1dconvdiffinternalEPNS_9ae_vectorES1_S1_lS1_lS1_bS1_bS1_bPNS_8ae_stateE(ptr noundef, ptr noundef, ptr noundef, i64 noundef, ptr noundef, i64 noundef, ptr noundef, i1 noundef zeroext, ptr noundef, i1 noundef zeroext, ptr noundef, i1 noundef zeroext, 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, !12, i64 0}
!12 = !{!"double", !7, i64 0}
!13 = !{!14, !10, i64 0}
!14 = !{!"_ZTSN11alglib_impl9ae_vectorE", !10, i64 0, !10, i64 8, !15, i64 16, !16, i64 24, !7, i64 56}
!15 = !{!"bool", !7, i64 0}
!16 = !{!"_ZTSN11alglib_impl12ae_dyn_blockE", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24}
!17 = !{!7, !7, i64 0}
!18 = distinct !{!18, !19}
!19 = !{!"llvm.loop.mustprogress"}
!20 = distinct !{!20, !19}
!21 = distinct !{!21, !19}
!22 = distinct !{!22, !19}


; 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.230 = external hidden unnamed_addr constant [46 x i8], align 1
@.str.231 = external hidden unnamed_addr constant [46 x i8], align 1
@.str.232 = external hidden unnamed_addr constant [57 x i8], align 1
@.str.233 = external hidden unnamed_addr constant [51 x i8], align 1
@.str.234 = external hidden unnamed_addr constant [51 x i8], align 1
@.str.235 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.236 = external hidden unnamed_addr constant [37 x i8], align 1
@.str.237 = external hidden unnamed_addr constant [37 x i8], align 1
@.str.238 = external hidden unnamed_addr constant [30 x i8], align 1
@.str.239 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.240 = external hidden unnamed_addr constant [59 x i8], align 1
@.str.241 = external hidden unnamed_addr constant [59 x i8], align 1
@.str.242 = external hidden unnamed_addr constant [60 x i8], align 1
@.str.243 = external hidden unnamed_addr constant [70 x i8], align 1
@.str.244 = external hidden unnamed_addr constant [40 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
define dso_local void @_ZN11alglib_impl22spline1dconvdiff2cubicEPNS_9ae_vectorES1_lldldS1_lS1_S1_S1_PNS_8ae_stateE(ptr noundef %0, ptr noundef %1, i64 noundef %2, i64 noundef %3, double noundef %4, i64 noundef %5, double noundef %6, ptr noundef %7, i64 noundef %8, ptr noundef %9, ptr noundef %10, ptr noundef %11, ptr noundef %12) local_unnamed_addr #3 {
  %14 = alloca %"struct.alglib_impl::ae_frame", align 8
  %15 = alloca %"struct.alglib_impl::ae_vector", align 8
  %16 = alloca %"struct.alglib_impl::ae_vector", align 8
  %17 = alloca %"struct.alglib_impl::ae_vector", align 8
  %18 = alloca %"struct.alglib_impl::ae_vector", align 8
  %19 = alloca %"struct.alglib_impl::ae_vector", align 8
  %20 = alloca %"struct.alglib_impl::ae_vector", align 8
  %21 = alloca %"struct.alglib_impl::ae_vector", align 8
  %22 = alloca %"struct.alglib_impl::ae_vector", align 8
  %23 = alloca %"struct.alglib_impl::ae_vector", align 8
  %24 = alloca %"struct.alglib_impl::ae_vector", align 8
  %25 = alloca %"struct.alglib_impl::ae_vector", align 8
  %26 = alloca double, align 8
  %27 = alloca double, align 8
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %14) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %15) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %16) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %17) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %18) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %19) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %20) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %21) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %22) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %23) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %24) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %25) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %26) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %27) #4
  call void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef %12, ptr noundef nonnull %14)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %15, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %16, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %17, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %18, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %19, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %20, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %21, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %22, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %23, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %24, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %25, i8 0, i64 64, i1 false)
  call void @_ZN11alglib_impl19ae_vector_init_copyEPNS_9ae_vectorES1_PNS_8ae_stateEb(ptr noundef nonnull %15, ptr noundef %0, ptr noundef %12, i1 noundef zeroext true)
  call void @_ZN11alglib_impl19ae_vector_init_copyEPNS_9ae_vectorES1_PNS_8ae_stateEb(ptr noundef nonnull %16, ptr noundef %1, ptr noundef %12, i1 noundef zeroext true)
  call void @_ZN11alglib_impl19ae_vector_init_copyEPNS_9ae_vectorES1_PNS_8ae_stateEb(ptr noundef nonnull %17, ptr noundef %7, ptr noundef %12, i1 noundef zeroext true)
  call void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef %9)
  call void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef %10)
  call void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef %11)
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef nonnull %18, i64 noundef 0, i64 noundef 3, ptr noundef %12, i1 noundef zeroext true)
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef nonnull %19, i64 noundef 0, i64 noundef 3, ptr noundef %12, i1 noundef zeroext true)
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef nonnull %20, i64 noundef 0, i64 noundef 3, ptr noundef %12, i1 noundef zeroext true)
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef nonnull %21, i64 noundef 0, i64 noundef 3, ptr noundef %12, i1 noundef zeroext true)
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef nonnull %22, i64 noundef 0, i64 noundef 3, ptr noundef %12, i1 noundef zeroext true)
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef nonnull %23, i64 noundef 0, i64 noundef 3, ptr noundef %12, i1 noundef zeroext true)
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef nonnull %24, i64 noundef 0, i64 noundef 2, ptr noundef %12, i1 noundef zeroext true)
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef nonnull %25, i64 noundef 0, i64 noundef 2, ptr noundef %12, i1 noundef zeroext true)
  %28 = icmp eq i64 %3, -1
  %29 = add i64 %3, 1
  %spec.select = icmp ult i64 %29, 4
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %spec.select, ptr noundef nonnull @.str.230, ptr noundef %12)
  %30 = add i64 %5, 1
  %31 = icmp ult i64 %30, 4
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %31, ptr noundef nonnull @.str.231, ptr noundef %12)
  %32 = and i64 %5, %3
  %or.cond9 = icmp eq i64 %32, -1
  br i1 %or.cond9, label %37, label %33

33:                                               ; preds = %13
  %34 = icmp ne i64 %5, -1
  %35 = icmp ne i64 %3, -1
  %36 = and i1 %35, %34
  br label %37

37:                                               ; preds = %13, %33
  %38 = phi i1 [ %36, %33 ], [ true, %13 ]
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %38, ptr noundef nonnull @.str.232, ptr noundef %12)
  %39 = add i64 %3, -1
  %or.cond11 = icmp ult i64 %39, 2
  br i1 %or.cond11, label %40, label %42

40:                                               ; preds = %37
  %41 = call noundef zeroext i1 @_ZN11alglib_impl11ae_isfiniteEdPNS_8ae_stateE(double noundef %4, ptr noundef %12)
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %41, ptr noundef nonnull @.str.233, ptr noundef %12)
  br label %42

42:                                               ; preds = %37, %40
  %43 = add i64 %5, -1
  %or.cond13 = icmp ult i64 %43, 2
  br i1 %or.cond13, label %44, label %46

44:                                               ; preds = %42
  %45 = call noundef zeroext i1 @_ZN11alglib_impl11ae_isfiniteEdPNS_8ae_stateE(double noundef %6, ptr noundef %12)
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %45, ptr noundef nonnull @.str.234, ptr noundef %12)
  br label %46

46:                                               ; preds = %42, %44
  %47 = icmp sgt i64 %2, 1
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %47, ptr noundef nonnull @.str.235, ptr noundef %12)
  %48 = load i64, ptr %15, align 8, !tbaa !5
  %49 = icmp sge i64 %48, %2
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %49, ptr noundef nonnull @.str.236, ptr noundef %12)
  %50 = load i64, ptr %16, align 8, !tbaa !5
  %51 = icmp sge i64 %50, %2
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %51, ptr noundef nonnull @.str.237, ptr noundef %12)
  %52 = icmp sgt i64 %8, 1
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %52, ptr noundef nonnull @.str.238, ptr noundef %12)
  %53 = load i64, ptr %17, align 8, !tbaa !5
  %54 = icmp sge i64 %53, %8
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %54, ptr noundef nonnull @.str.239, ptr noundef %12)
  %55 = sext i1 %28 to i64
  %spec.select164 = add nsw i64 %55, %2
  %56 = call noundef zeroext i1 @_ZN11alglib_impl14isfinitevectorEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %15, i64 noundef %2, ptr noundef %12)
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %56, ptr noundef nonnull @.str.240, ptr noundef %12)
  %57 = call noundef zeroext i1 @_ZN11alglib_impl14isfinitevectorEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %16, i64 noundef %spec.select164, ptr noundef %12)
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %57, ptr noundef nonnull @.str.241, ptr noundef %12)
  %58 = call noundef zeroext i1 @_ZN11alglib_impl14isfinitevectorEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %17, i64 noundef %8, ptr noundef %12)
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %58, ptr noundef nonnull @.str.242, ptr noundef %12)
  call void @_ZN11alglib_implL24spline1d_heapsortppointsEPNS_9ae_vectorES1_S1_lPNS_8ae_stateE(ptr noundef nonnull %15, ptr noundef nonnull %16, ptr noundef nonnull %24, i64 noundef %2, ptr noundef %12)
  %59 = call noundef zeroext i1 @_ZN11alglib_impl11aredistinctEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %15, i64 noundef %2, ptr noundef %12)
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %59, ptr noundef nonnull @.str.243, ptr noundef %12)
  %60 = call noundef i64 @_ZN11alglib_impl9ae_maxintEllPNS_8ae_stateE(i64 noundef %2, i64 noundef %8, ptr noundef %12)
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %23, i64 noundef %60, ptr noundef %12)
  %.not.not165 = icmp sgt i64 %8, 0
  %or.cond = and i1 %or.cond9, %.not.not165
  br i1 %or.cond, label %.lr.ph, label %.loopexit

.lr.ph:                                           ; preds = %46
  %61 = getelementptr inbounds i8, ptr %17, i64 56
  %62 = getelementptr inbounds i8, ptr %15, i64 56
  br label %63

63:                                               ; preds = %.lr.ph, %63
  %.0157166 = phi i64 [ 0, %.lr.ph ], [ %75, %63 ]
  %64 = load ptr, ptr %61, align 8, !tbaa !13
  %65 = getelementptr inbounds double, ptr %64, i64 %.0157166
  %66 = load double, ptr %65, align 8, !tbaa !14
  store double %66, ptr %26, align 8, !tbaa !14
  %67 = load ptr, ptr %62, align 8, !tbaa !13
  %68 = load double, ptr %67, align 8, !tbaa !14
  %69 = getelementptr double, ptr %67, i64 %2
  %70 = getelementptr i8, ptr %69, i64 -8
  %71 = load double, ptr %70, align 8, !tbaa !14
  call void @_ZN11alglib_impl13apperiodicmapEPdddS0_PNS_8ae_stateE(ptr noundef nonnull %26, double noundef %68, double noundef %71, ptr noundef nonnull %27, ptr noundef %12)
  %72 = load double, ptr %26, align 8, !tbaa !14
  %73 = load ptr, ptr %61, align 8, !tbaa !13
  %74 = getelementptr inbounds double, ptr %73, i64 %.0157166
  store double %72, ptr %74, align 8, !tbaa !14
  %75 = add nuw nsw i64 %.0157166, 1
  %exitcond.not = icmp eq i64 %75, %8
  br i1 %exitcond.not, label %.loopexit, label %63, !llvm.loop !16

.loopexit:                                        ; preds = %63, %46
  call void @_ZN11alglib_implL24spline1d_heapsortppointsEPNS_9ae_vectorES1_S1_lPNS_8ae_stateE(ptr noundef nonnull %17, ptr noundef nonnull %23, ptr noundef nonnull %25, i64 noundef %8, ptr noundef %12)
  call void @_ZN11alglib_implL38spline1d_spline1dgriddiffcubicinternalEPNS_9ae_vectorES1_lldldS1_S1_S1_S1_S1_S1_PNS_8ae_stateE(ptr noundef nonnull %15, ptr noundef nonnull %16, i64 noundef %2, i64 noundef %3, double noundef %4, i64 noundef %5, double noundef %6, ptr noundef nonnull %22, ptr noundef nonnull %18, ptr noundef nonnull %19, ptr noundef nonnull %20, ptr noundef nonnull %21, ptr noundef nonnull %23, ptr noundef %12)
  call void @_ZN11alglib_impl24spline1dconvdiffinternalEPNS_9ae_vectorES1_S1_lS1_lS1_bS1_bS1_bPNS_8ae_stateE(ptr noundef nonnull %15, ptr noundef nonnull %16, ptr noundef nonnull %22, i64 noundef %2, ptr noundef nonnull %17, i64 noundef %8, ptr noundef %9, i1 noundef zeroext true, ptr noundef %10, i1 noundef zeroext true, ptr noundef %11, i1 noundef zeroext true, ptr noundef %12)
  %76 = load i64, ptr %23, align 8, !tbaa !5
  %77 = icmp sge i64 %76, %8
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %77, ptr noundef nonnull @.str.244, ptr noundef %12)
  br i1 %.not.not165, label %.lr.ph169, label %._crit_edge

.lr.ph169:                                        ; preds = %.loopexit
  %78 = getelementptr inbounds i8, ptr %9, i64 56
  %79 = getelementptr inbounds i8, ptr %23, i64 56
  %80 = getelementptr inbounds i8, ptr %25, i64 56
  %xtraiter = and i64 %8, 1
  %81 = icmp eq i64 %8, 1
  br i1 %81, label %._crit_edge.loopexit.unr-lcssa, label %.lr.ph169.new

.lr.ph169.new:                                    ; preds = %.lr.ph169
  %unroll_iter = and i64 %8, 9223372036854775806
  br label %82

82:                                               ; preds = %82, %.lr.ph169.new
  %.1168 = phi i64 [ 0, %.lr.ph169.new ], [ %100, %82 ]
  %niter = phi i64 [ 0, %.lr.ph169.new ], [ %niter.next.1, %82 ]
  %83 = load ptr, ptr %78, align 8, !tbaa !13
  %84 = getelementptr inbounds double, ptr %83, i64 %.1168
  %85 = load double, ptr %84, align 8, !tbaa !14
  %86 = load ptr, ptr %79, align 8, !tbaa !13
  %87 = load ptr, ptr %80, align 8, !tbaa !13
  %88 = getelementptr inbounds i64, ptr %87, i64 %.1168
  %89 = load i64, ptr %88, align 8, !tbaa !18
  %90 = getelementptr inbounds double, ptr %86, i64 %89
  store double %85, ptr %90, align 8, !tbaa !14
  %91 = or disjoint i64 %.1168, 1
  %92 = load ptr, ptr %78, align 8, !tbaa !13
  %93 = getelementptr inbounds double, ptr %92, i64 %91
  %94 = load double, ptr %93, align 8, !tbaa !14
  %95 = load ptr, ptr %79, align 8, !tbaa !13
  %96 = load ptr, ptr %80, align 8, !tbaa !13
  %97 = getelementptr inbounds i64, ptr %96, i64 %91
  %98 = load i64, ptr %97, align 8, !tbaa !18
  %99 = getelementptr inbounds double, ptr %95, i64 %98
  store double %94, ptr %99, align 8, !tbaa !14
  %100 = add nuw nsw i64 %.1168, 2
  %niter.next.1 = add i64 %niter, 2
  %niter.ncmp.1 = icmp eq i64 %niter.next.1, %unroll_iter
  br i1 %niter.ncmp.1, label %._crit_edge.loopexit.unr-lcssa, label %82, !llvm.loop !19

._crit_edge.loopexit.unr-lcssa:                   ; preds = %82, %.lr.ph169
  %.1168.unr = phi i64 [ 0, %.lr.ph169 ], [ %100, %82 ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %._crit_edge, label %._crit_edge.loopexit.epilog-lcssa

._crit_edge.loopexit.epilog-lcssa:                ; preds = %._crit_edge.loopexit.unr-lcssa
  %101 = load ptr, ptr %78, align 8, !tbaa !13
  %102 = getelementptr inbounds double, ptr %101, i64 %.1168.unr
  %103 = load double, ptr %102, align 8, !tbaa !14
  %104 = load ptr, ptr %79, align 8, !tbaa !13
  %105 = load ptr, ptr %80, align 8, !tbaa !13
  %106 = getelementptr inbounds i64, ptr %105, i64 %.1168.unr
  %107 = load i64, ptr %106, align 8, !tbaa !18
  %108 = getelementptr inbounds double, ptr %104, i64 %107
  store double %103, ptr %108, align 8, !tbaa !14
  br label %._crit_edge

._crit_edge:                                      ; preds = %._crit_edge.loopexit.epilog-lcssa, %._crit_edge.loopexit.unr-lcssa, %.loopexit
  %109 = add nsw i64 %8, -1
  %110 = getelementptr inbounds i8, ptr %9, i64 56
  %111 = load ptr, ptr %110, align 8, !tbaa !13
  %112 = getelementptr inbounds i8, ptr %23, i64 56
  %113 = load ptr, ptr %112, align 8, !tbaa !13
  %114 = call noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef 0, i64 noundef %109)
  call void @_ZN11alglib_impl9ae_v_moveEPdlPKdll(ptr noundef %111, i64 noundef 1, ptr noundef %113, i64 noundef 1, i64 noundef %114)
  %115 = getelementptr inbounds i8, ptr %10, i64 56
  br i1 %.not.not165, label %.lr.ph173, label %._crit_edge179.critedge

.lr.ph173:                                        ; preds = %._crit_edge
  %116 = getelementptr inbounds i8, ptr %25, i64 56
  %117 = add nsw i64 %8, -1
  %xtraiter184 = and i64 %8, 1
  %118 = icmp eq i64 %117, 0
  br i1 %118, label %._crit_edge174.unr-lcssa, label %.lr.ph173.new

.lr.ph173.new:                                    ; preds = %.lr.ph173
  %unroll_iter186 = and i64 %8, 9223372036854775806
  br label %119

119:                                              ; preds = %119, %.lr.ph173.new
  %.2171 = phi i64 [ 0, %.lr.ph173.new ], [ %137, %119 ]
  %niter187 = phi i64 [ 0, %.lr.ph173.new ], [ %niter187.next.1, %119 ]
  %120 = load ptr, ptr %115, align 8, !tbaa !13
  %121 = getelementptr inbounds double, ptr %120, i64 %.2171
  %122 = load double, ptr %121, align 8, !tbaa !14
  %123 = load ptr, ptr %112, align 8, !tbaa !13
  %124 = load ptr, ptr %116, align 8, !tbaa !13
  %125 = getelementptr inbounds i64, ptr %124, i64 %.2171
  %126 = load i64, ptr %125, align 8, !tbaa !18
  %127 = getelementptr inbounds double, ptr %123, i64 %126
  store double %122, ptr %127, align 8, !tbaa !14
  %128 = or disjoint i64 %.2171, 1
  %129 = load ptr, ptr %115, align 8, !tbaa !13
  %130 = getelementptr inbounds double, ptr %129, i64 %128
  %131 = load double, ptr %130, align 8, !tbaa !14
  %132 = load ptr, ptr %112, align 8, !tbaa !13
  %133 = load ptr, ptr %116, align 8, !tbaa !13
  %134 = getelementptr inbounds i64, ptr %133, i64 %128
  %135 = load i64, ptr %134, align 8, !tbaa !18
  %136 = getelementptr inbounds double, ptr %132, i64 %135
  store double %131, ptr %136, align 8, !tbaa !14
  %137 = add nuw nsw i64 %.2171, 2
  %niter187.next.1 = add i64 %niter187, 2
  %niter187.ncmp.1 = icmp eq i64 %niter187.next.1, %unroll_iter186
  br i1 %niter187.ncmp.1, label %._crit_edge174.unr-lcssa, label %119, !llvm.loop !20

._crit_edge174.unr-lcssa:                         ; preds = %119, %.lr.ph173
  %.2171.unr = phi i64 [ 0, %.lr.ph173 ], [ %137, %119 ]
  %lcmp.mod185.not = icmp eq i64 %xtraiter184, 0
  br i1 %lcmp.mod185.not, label %._crit_edge174, label %._crit_edge174.epilog-lcssa

._crit_edge174.epilog-lcssa:                      ; preds = %._crit_edge174.unr-lcssa
  %138 = load ptr, ptr %115, align 8, !tbaa !13
  %139 = getelementptr inbounds double, ptr %138, i64 %.2171.unr
  %140 = load double, ptr %139, align 8, !tbaa !14
  %141 = load ptr, ptr %112, align 8, !tbaa !13
  %142 = load ptr, ptr %116, align 8, !tbaa !13
  %143 = getelementptr inbounds i64, ptr %142, i64 %.2171.unr
  %144 = load i64, ptr %143, align 8, !tbaa !18
  %145 = getelementptr inbounds double, ptr %141, i64 %144
  store double %140, ptr %145, align 8, !tbaa !14
  br label %._crit_edge174

._crit_edge174:                                   ; preds = %._crit_edge174.unr-lcssa, %._crit_edge174.epilog-lcssa
  %146 = getelementptr inbounds i8, ptr %10, i64 56
  %147 = load ptr, ptr %146, align 8, !tbaa !13
  %148 = load ptr, ptr %112, align 8, !tbaa !13
  %149 = call noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef 0, i64 noundef %109)
  call void @_ZN11alglib_impl9ae_v_moveEPdlPKdll(ptr noundef %147, i64 noundef 1, ptr noundef %148, i64 noundef 1, i64 noundef %149)
  br i1 %.not.not165, label %.lr.ph178, label %._crit_edge179

.lr.ph178:                                        ; preds = %._crit_edge174
  %150 = getelementptr inbounds i8, ptr %11, i64 56
  %151 = getelementptr inbounds i8, ptr %25, i64 56
  %xtraiter189 = and i64 %8, 1
  %152 = icmp eq i64 %117, 0
  br i1 %152, label %._crit_edge179.loopexit.unr-lcssa, label %.lr.ph178.new

.lr.ph178.new:                                    ; preds = %.lr.ph178
  %unroll_iter191 = and i64 %8, 9223372036854775806
  br label %153

153:                                              ; preds = %153, %.lr.ph178.new
  %.3176 = phi i64 [ 0, %.lr.ph178.new ], [ %171, %153 ]
  %niter192 = phi i64 [ 0, %.lr.ph178.new ], [ %niter192.next.1, %153 ]
  %154 = load ptr, ptr %150, align 8, !tbaa !13
  %155 = getelementptr inbounds double, ptr %154, i64 %.3176
  %156 = load double, ptr %155, align 8, !tbaa !14
  %157 = load ptr, ptr %112, align 8, !tbaa !13
  %158 = load ptr, ptr %151, align 8, !tbaa !13
  %159 = getelementptr inbounds i64, ptr %158, i64 %.3176
  %160 = load i64, ptr %159, align 8, !tbaa !18
  %161 = getelementptr inbounds double, ptr %157, i64 %160
  store double %156, ptr %161, align 8, !tbaa !14
  %162 = or disjoint i64 %.3176, 1
  %163 = load ptr, ptr %150, align 8, !tbaa !13
  %164 = getelementptr inbounds double, ptr %163, i64 %162
  %165 = load double, ptr %164, align 8, !tbaa !14
  %166 = load ptr, ptr %112, align 8, !tbaa !13
  %167 = load ptr, ptr %151, align 8, !tbaa !13
  %168 = getelementptr inbounds i64, ptr %167, i64 %162
  %169 = load i64, ptr %168, align 8, !tbaa !18
  %170 = getelementptr inbounds double, ptr %166, i64 %169
  store double %165, ptr %170, align 8, !tbaa !14
  %171 = add nuw nsw i64 %.3176, 2
  %niter192.next.1 = add i64 %niter192, 2
  %niter192.ncmp.1 = icmp eq i64 %niter192.next.1, %unroll_iter191
  br i1 %niter192.ncmp.1, label %._crit_edge179.loopexit.unr-lcssa, label %153, !llvm.loop !21

._crit_edge179.critedge:                          ; preds = %._crit_edge
  %172 = load ptr, ptr %115, align 8, !tbaa !13
  %173 = load ptr, ptr %112, align 8, !tbaa !13
  %174 = call noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef 0, i64 noundef %109)
  call void @_ZN11alglib_impl9ae_v_moveEPdlPKdll(ptr noundef %172, i64 noundef 1, ptr noundef %173, i64 noundef 1, i64 noundef %174)
  br label %._crit_edge179

._crit_edge179.loopexit.unr-lcssa:                ; preds = %153, %.lr.ph178
  %.3176.unr = phi i64 [ 0, %.lr.ph178 ], [ %171, %153 ]
  %lcmp.mod190.not = icmp eq i64 %xtraiter189, 0
  br i1 %lcmp.mod190.not, label %._crit_edge179, label %._crit_edge179.loopexit.epilog-lcssa

._crit_edge179.loopexit.epilog-lcssa:             ; preds = %._crit_edge179.loopexit.unr-lcssa
  %175 = load ptr, ptr %150, align 8, !tbaa !13
  %176 = getelementptr inbounds double, ptr %175, i64 %.3176.unr
  %177 = load double, ptr %176, align 8, !tbaa !14
  %178 = load ptr, ptr %112, align 8, !tbaa !13
  %179 = load ptr, ptr %151, align 8, !tbaa !13
  %180 = getelementptr inbounds i64, ptr %179, i64 %.3176.unr
  %181 = load i64, ptr %180, align 8, !tbaa !18
  %182 = getelementptr inbounds double, ptr %178, i64 %181
  store double %177, ptr %182, align 8, !tbaa !14
  br label %._crit_edge179

._crit_edge179:                                   ; preds = %._crit_edge179.loopexit.epilog-lcssa, %._crit_edge179.loopexit.unr-lcssa, %._crit_edge179.critedge, %._crit_edge174
  %183 = getelementptr inbounds i8, ptr %11, i64 56
  %184 = load ptr, ptr %183, align 8, !tbaa !13
  %185 = load ptr, ptr %112, align 8, !tbaa !13
  %186 = call noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef 0, i64 noundef %109)
  call void @_ZN11alglib_impl9ae_v_moveEPdlPKdll(ptr noundef %184, i64 noundef 1, ptr noundef %185, i64 noundef 1, i64 noundef %186)
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %12)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %27) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %26) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %25) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %24) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %23) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %22) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %21) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %20) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %19) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %18) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %17) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %16) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %15) #4
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %14) #4
  ret void
}

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

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

declare void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef) local_unnamed_addr #2

declare noundef zeroext i1 @_ZN11alglib_impl14isfinitevectorEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef, i64 noundef, 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_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_impl19ae_vector_init_copyEPNS_9ae_vectorES1_PNS_8ae_stateEb(ptr noundef, ptr noundef, ptr noundef, i1 noundef zeroext) local_unnamed_addr #2

declare noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef, i64 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 void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef, ptr noundef) local_unnamed_addr #2

declare void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef) local_unnamed_addr #2

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

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

; Function Attrs: mustprogress uwtable
declare hidden void @_ZN11alglib_implL38spline1d_spline1dgriddiffcubicinternalEPNS_9ae_vectorES1_lldldS1_S1_S1_S1_S1_S1_PNS_8ae_stateE(ptr noundef, ptr noundef, i64 noundef, i64 noundef, double noundef, i64 noundef, double noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @_ZN11alglib_impl13apperiodicmapEPdddS0_PNS_8ae_stateE(ptr noundef, double noundef, double noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN11alglib_impl24spline1dconvdiffinternalEPNS_9ae_vectorES1_S1_lS1_lS1_bS1_bS1_bPNS_8ae_stateE(ptr noundef, ptr noundef, ptr noundef, i64 noundef, ptr noundef, i64 noundef, ptr noundef, i1 noundef zeroext, ptr noundef, i1 noundef zeroext, ptr noundef, i1 noundef zeroext, 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 = !{!8, !8, i64 0}
!14 = !{!15, !15, i64 0}
!15 = !{!"double", !8, i64 0}
!16 = distinct !{!16, !17}
!17 = !{!"llvm.loop.mustprogress"}
!18 = !{!7, !7, i64 0}
!19 = distinct !{!19, !17}
!20 = distinct !{!20, !17}
!21 = distinct !{!21, !17}


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