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

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"struct.alglib_impl::ssamodel" = type { i64, %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", i64, i64, i64, i64, i64, i64, %"struct.alglib_impl::ae_matrix", i64, i64, i8, %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", i64, %"struct.alglib_impl::eigsubspacestate", %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::hqrndstate", i64, %"struct.alglib_impl::ae_vector", i64, i64, i64, %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::eigsubspacereport", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::ae_matrix", i64, i64, i64 }
%"struct.alglib_impl::eigsubspacestate" = type { i64, i64, i64, i64, double, i64, i64, i8, i8, %"struct.alglib_impl::hqrndstate", i8, %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::apbuffers", %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::ae_matrix", i64, i64, i64, %"struct.alglib_impl::rcommstate" }
%"struct.alglib_impl::apbuffers" = type { %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::ae_matrix" }
%"struct.alglib_impl::rcommstate" = type { i32, %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector" }
%"struct.alglib_impl::hqrndstate" = type { i64, i64, i64 }
%"struct.alglib_impl::eigsubspacereport" = type { i64 }
%"struct.alglib_impl::ae_vector" = type { i64, i64, i8, %"struct.alglib_impl::ae_dyn_block", %union.anon.1 }
%"struct.alglib_impl::ae_dyn_block" = type { ptr, ptr, ptr, ptr }
%union.anon.1 = type { ptr }
%"struct.alglib_impl::ae_matrix" = type { i64, i64, i64, i64, i8, %"struct.alglib_impl::ae_dyn_block", %union.anon.0 }
%union.anon.0 = type { ptr }

@.str.262 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.263 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.264 = external hidden unnamed_addr constant [43 x i8], align 1
@.str.265 = external hidden unnamed_addr constant [50 x i8], align 1
@.str.266 = external hidden unnamed_addr constant [51 x i8], align 1

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #0

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #0

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN11alglib_impl18ssaforecastavglastEPNS_8ssamodelEllPNS_9ae_vectorEPNS_8ae_stateE(ptr noundef %0, i64 noundef %1, i64 noundef %2, ptr noundef %3, ptr noundef %4) #2 {
  %6 = alloca ptr, align 8
  %7 = alloca i64, align 8
  %8 = alloca i64, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca i64, align 8
  %12 = alloca i64, align 8
  %13 = alloca i32, align 4
  store ptr %0, ptr %6, align 8, !tbaa !5
  store i64 %1, ptr %7, align 8, !tbaa !9
  store i64 %2, ptr %8, align 8, !tbaa !9
  store ptr %3, ptr %9, align 8, !tbaa !5
  store ptr %4, ptr %10, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #4
  %14 = load ptr, ptr %9, align 8, !tbaa !5
  call void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef %14)
  %15 = load i64, ptr %8, align 8, !tbaa !9
  %16 = icmp sge i64 %15, 1
  %17 = load ptr, ptr %10, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %16, ptr noundef @.str.262, ptr noundef %17)
  %18 = load i64, ptr %7, align 8, !tbaa !9
  %19 = icmp sge i64 %18, 1
  %20 = load ptr, ptr %10, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %19, ptr noundef @.str.263, ptr noundef %20)
  %21 = load ptr, ptr %6, align 8, !tbaa !5
  %22 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %21, i32 0, i32 4
  %23 = load i64, ptr %22, align 8, !tbaa !11
  store i64 %23, ptr %12, align 8, !tbaa !9
  %24 = load ptr, ptr %9, align 8, !tbaa !5
  %25 = load i64, ptr %8, align 8, !tbaa !9
  %26 = load ptr, ptr %10, align 8, !tbaa !5
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %24, i64 noundef %25, ptr noundef %26)
  %27 = load ptr, ptr %6, align 8, !tbaa !5
  %28 = load ptr, ptr %10, align 8, !tbaa !5
  %29 = call noundef zeroext i1 @_ZN11alglib_implL25ssa_hassomethingtoanalyzeEPNS_8ssamodelEPNS_8ae_stateE(ptr noundef %27, ptr noundef %28)
  br i1 %29, label %46, label %30

30:                                               ; preds = %5
  store i64 0, ptr %11, align 8, !tbaa !9
  br label %31

31:                                               ; preds = %42, %30
  %32 = load i64, ptr %11, align 8, !tbaa !9
  %33 = load i64, ptr %8, align 8, !tbaa !9
  %34 = sub nsw i64 %33, 1
  %35 = icmp sle i64 %32, %34
  br i1 %35, label %36, label %45

36:                                               ; preds = %31
  %37 = load ptr, ptr %9, align 8, !tbaa !5
  %38 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %37, i32 0, i32 4
  %39 = load ptr, ptr %38, align 8, !tbaa !24
  %40 = load i64, ptr %11, align 8, !tbaa !9
  %41 = getelementptr inbounds double, ptr %39, i64 %40
  store double 0.000000e+00, ptr %41, align 8, !tbaa !25
  br label %42

42:                                               ; preds = %36
  %43 = load i64, ptr %11, align 8, !tbaa !9
  %44 = add nsw i64 %43, 1
  store i64 %44, ptr %11, align 8, !tbaa !9
  br label %31, !llvm.loop !26

45:                                               ; preds = %31
  store i32 1, ptr %13, align 4
  br label %288

46:                                               ; preds = %5
  %47 = load ptr, ptr %6, align 8, !tbaa !5
  %48 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %47, i32 0, i32 0
  %49 = load i64, ptr %48, align 8, !tbaa !28
  %50 = icmp sgt i64 %49, 0
  %51 = load ptr, ptr %10, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %50, ptr noundef @.str.264, ptr noundef %51)
  %52 = load ptr, ptr %6, align 8, !tbaa !5
  %53 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %52, i32 0, i32 1
  %54 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %53, i32 0, i32 4
  %55 = load ptr, ptr %54, align 8, !tbaa !24
  %56 = load ptr, ptr %6, align 8, !tbaa !5
  %57 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %56, i32 0, i32 0
  %58 = load i64, ptr %57, align 8, !tbaa !28
  %59 = getelementptr inbounds i64, ptr %55, i64 %58
  %60 = load i64, ptr %59, align 8, !tbaa !9
  %61 = load ptr, ptr %6, align 8, !tbaa !5
  %62 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %61, i32 0, i32 1
  %63 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %62, i32 0, i32 4
  %64 = load ptr, ptr %63, align 8, !tbaa !24
  %65 = load ptr, ptr %6, align 8, !tbaa !5
  %66 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %65, i32 0, i32 0
  %67 = load i64, ptr %66, align 8, !tbaa !28
  %68 = sub nsw i64 %67, 1
  %69 = getelementptr inbounds i64, ptr %64, i64 %68
  %70 = load i64, ptr %69, align 8, !tbaa !9
  %71 = sub nsw i64 %60, %70
  %72 = load i64, ptr %12, align 8, !tbaa !9
  %73 = icmp slt i64 %71, %72
  br i1 %73, label %74, label %90

74:                                               ; preds = %46
  store i64 0, ptr %11, align 8, !tbaa !9
  br label %75

75:                                               ; preds = %86, %74
  %76 = load i64, ptr %11, align 8, !tbaa !9
  %77 = load i64, ptr %8, align 8, !tbaa !9
  %78 = sub nsw i64 %77, 1
  %79 = icmp sle i64 %76, %78
  br i1 %79, label %80, label %89

80:                                               ; preds = %75
  %81 = load ptr, ptr %9, align 8, !tbaa !5
  %82 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %81, i32 0, i32 4
  %83 = load ptr, ptr %82, align 8, !tbaa !24
  %84 = load i64, ptr %11, align 8, !tbaa !9
  %85 = getelementptr inbounds double, ptr %83, i64 %84
  store double 0.000000e+00, ptr %85, align 8, !tbaa !25
  br label %86

86:                                               ; preds = %80
  %87 = load i64, ptr %11, align 8, !tbaa !9
  %88 = add nsw i64 %87, 1
  store i64 %88, ptr %11, align 8, !tbaa !9
  br label %75, !llvm.loop !29

89:                                               ; preds = %75
  store i32 1, ptr %13, align 4
  br label %288

90:                                               ; preds = %46
  %91 = load i64, ptr %12, align 8, !tbaa !9
  %92 = icmp eq i64 %91, 1
  br i1 %92, label %93, label %152

93:                                               ; preds = %90
  %94 = load ptr, ptr %6, align 8, !tbaa !5
  %95 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %94, i32 0, i32 0
  %96 = load i64, ptr %95, align 8, !tbaa !28
  %97 = icmp sgt i64 %96, 0
  %98 = load ptr, ptr %10, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %97, ptr noundef @.str.265, ptr noundef %98)
  %99 = load ptr, ptr %6, align 8, !tbaa !5
  %100 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %99, i32 0, i32 1
  %101 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %100, i32 0, i32 4
  %102 = load ptr, ptr %101, align 8, !tbaa !24
  %103 = load ptr, ptr %6, align 8, !tbaa !5
  %104 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %103, i32 0, i32 0
  %105 = load i64, ptr %104, align 8, !tbaa !28
  %106 = getelementptr inbounds i64, ptr %102, i64 %105
  %107 = load i64, ptr %106, align 8, !tbaa !9
  %108 = load ptr, ptr %6, align 8, !tbaa !5
  %109 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %108, i32 0, i32 1
  %110 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %109, i32 0, i32 4
  %111 = load ptr, ptr %110, align 8, !tbaa !24
  %112 = load ptr, ptr %6, align 8, !tbaa !5
  %113 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %112, i32 0, i32 0
  %114 = load i64, ptr %113, align 8, !tbaa !28
  %115 = sub nsw i64 %114, 1
  %116 = getelementptr inbounds i64, ptr %111, i64 %115
  %117 = load i64, ptr %116, align 8, !tbaa !9
  %118 = sub nsw i64 %107, %117
  %119 = icmp sgt i64 %118, 0
  %120 = load ptr, ptr %10, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %119, ptr noundef @.str.264, ptr noundef %120)
  store i64 0, ptr %11, align 8, !tbaa !9
  br label %121

121:                                              ; preds = %148, %93
  %122 = load i64, ptr %11, align 8, !tbaa !9
  %123 = load i64, ptr %8, align 8, !tbaa !9
  %124 = sub nsw i64 %123, 1
  %125 = icmp sle i64 %122, %124
  br i1 %125, label %126, label %151

126:                                              ; preds = %121
  %127 = load ptr, ptr %6, align 8, !tbaa !5
  %128 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %127, i32 0, i32 2
  %129 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %128, i32 0, i32 4
  %130 = load ptr, ptr %129, align 8, !tbaa !24
  %131 = load ptr, ptr %6, align 8, !tbaa !5
  %132 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %131, i32 0, i32 1
  %133 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %132, i32 0, i32 4
  %134 = load ptr, ptr %133, align 8, !tbaa !24
  %135 = load ptr, ptr %6, align 8, !tbaa !5
  %136 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %135, i32 0, i32 0
  %137 = load i64, ptr %136, align 8, !tbaa !28
  %138 = getelementptr inbounds i64, ptr %134, i64 %137
  %139 = load i64, ptr %138, align 8, !tbaa !9
  %140 = sub nsw i64 %139, 1
  %141 = getelementptr inbounds double, ptr %130, i64 %140
  %142 = load double, ptr %141, align 8, !tbaa !25
  %143 = load ptr, ptr %9, align 8, !tbaa !5
  %144 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %143, i32 0, i32 4
  %145 = load ptr, ptr %144, align 8, !tbaa !24
  %146 = load i64, ptr %11, align 8, !tbaa !9
  %147 = getelementptr inbounds double, ptr %145, i64 %146
  store double %142, ptr %147, align 8, !tbaa !25
  br label %148

148:                                              ; preds = %126
  %149 = load i64, ptr %11, align 8, !tbaa !9
  %150 = add nsw i64 %149, 1
  store i64 %150, ptr %11, align 8, !tbaa !9
  br label %121, !llvm.loop !30

151:                                              ; preds = %121
  store i32 1, ptr %13, align 4
  br label %288

152:                                              ; preds = %90
  %153 = load ptr, ptr %6, align 8, !tbaa !5
  %154 = load ptr, ptr %10, align 8, !tbaa !5
  call void @_ZN11alglib_implL15ssa_updatebasisEPNS_8ssamodelEldPNS_8ae_stateE(ptr noundef %153, i64 noundef 0, double noundef 0.000000e+00, ptr noundef %154)
  %155 = load ptr, ptr %6, align 8, !tbaa !5
  %156 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %155, i32 0, i32 17
  %157 = load i64, ptr %156, align 8, !tbaa !31
  %158 = load i64, ptr %12, align 8, !tbaa !9
  %159 = icmp sle i64 %157, %158
  br i1 %159, label %160, label %165

160:                                              ; preds = %152
  %161 = load ptr, ptr %6, align 8, !tbaa !5
  %162 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %161, i32 0, i32 17
  %163 = load i64, ptr %162, align 8, !tbaa !31
  %164 = icmp sgt i64 %163, 0
  br label %165

165:                                              ; preds = %160, %152
  %166 = phi i1 [ false, %152 ], [ %164, %160 ]
  %167 = load ptr, ptr %10, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %166, ptr noundef @.str.266, ptr noundef %167)
  %168 = load ptr, ptr %6, align 8, !tbaa !5
  %169 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %168, i32 0, i32 17
  %170 = load i64, ptr %169, align 8, !tbaa !31
  %171 = load i64, ptr %12, align 8, !tbaa !9
  %172 = icmp eq i64 %170, %171
  br i1 %172, label %173, label %232

173:                                              ; preds = %165
  %174 = load ptr, ptr %6, align 8, !tbaa !5
  %175 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %174, i32 0, i32 0
  %176 = load i64, ptr %175, align 8, !tbaa !28
  %177 = icmp sgt i64 %176, 0
  %178 = load ptr, ptr %10, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %177, ptr noundef @.str.265, ptr noundef %178)
  %179 = load ptr, ptr %6, align 8, !tbaa !5
  %180 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %179, i32 0, i32 1
  %181 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %180, i32 0, i32 4
  %182 = load ptr, ptr %181, align 8, !tbaa !24
  %183 = load ptr, ptr %6, align 8, !tbaa !5
  %184 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %183, i32 0, i32 0
  %185 = load i64, ptr %184, align 8, !tbaa !28
  %186 = getelementptr inbounds i64, ptr %182, i64 %185
  %187 = load i64, ptr %186, align 8, !tbaa !9
  %188 = load ptr, ptr %6, align 8, !tbaa !5
  %189 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %188, i32 0, i32 1
  %190 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %189, i32 0, i32 4
  %191 = load ptr, ptr %190, align 8, !tbaa !24
  %192 = load ptr, ptr %6, align 8, !tbaa !5
  %193 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %192, i32 0, i32 0
  %194 = load i64, ptr %193, align 8, !tbaa !28
  %195 = sub nsw i64 %194, 1
  %196 = getelementptr inbounds i64, ptr %191, i64 %195
  %197 = load i64, ptr %196, align 8, !tbaa !9
  %198 = sub nsw i64 %187, %197
  %199 = icmp sgt i64 %198, 0
  %200 = load ptr, ptr %10, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %199, ptr noundef @.str.264, ptr noundef %200)
  store i64 0, ptr %11, align 8, !tbaa !9
  br label %201

201:                                              ; preds = %228, %173
  %202 = load i64, ptr %11, align 8, !tbaa !9
  %203 = load i64, ptr %8, align 8, !tbaa !9
  %204 = sub nsw i64 %203, 1
  %205 = icmp sle i64 %202, %204
  br i1 %205, label %206, label %231

206:                                              ; preds = %201
  %207 = load ptr, ptr %6, align 8, !tbaa !5
  %208 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %207, i32 0, i32 2
  %209 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %208, i32 0, i32 4
  %210 = load ptr, ptr %209, align 8, !tbaa !24
  %211 = load ptr, ptr %6, align 8, !tbaa !5
  %212 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %211, i32 0, i32 1
  %213 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %212, i32 0, i32 4
  %214 = load ptr, ptr %213, align 8, !tbaa !24
  %215 = load ptr, ptr %6, align 8, !tbaa !5
  %216 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %215, i32 0, i32 0
  %217 = load i64, ptr %216, align 8, !tbaa !28
  %218 = getelementptr inbounds i64, ptr %214, i64 %217
  %219 = load i64, ptr %218, align 8, !tbaa !9
  %220 = sub nsw i64 %219, 1
  %221 = getelementptr inbounds double, ptr %210, i64 %220
  %222 = load double, ptr %221, align 8, !tbaa !25
  %223 = load ptr, ptr %9, align 8, !tbaa !5
  %224 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %223, i32 0, i32 4
  %225 = load ptr, ptr %224, align 8, !tbaa !24
  %226 = load i64, ptr %11, align 8, !tbaa !9
  %227 = getelementptr inbounds double, ptr %225, i64 %226
  store double %222, ptr %227, align 8, !tbaa !25
  br label %228

228:                                              ; preds = %206
  %229 = load i64, ptr %11, align 8, !tbaa !9
  %230 = add nsw i64 %229, 1
  store i64 %230, ptr %11, align 8, !tbaa !9
  br label %201, !llvm.loop !32

231:                                              ; preds = %201
  store i32 1, ptr %13, align 4
  br label %288

232:                                              ; preds = %165
  %233 = load i64, ptr %7, align 8, !tbaa !9
  %234 = load ptr, ptr %6, align 8, !tbaa !5
  %235 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %234, i32 0, i32 1
  %236 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %235, i32 0, i32 4
  %237 = load ptr, ptr %236, align 8, !tbaa !24
  %238 = load ptr, ptr %6, align 8, !tbaa !5
  %239 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %238, i32 0, i32 0
  %240 = load i64, ptr %239, align 8, !tbaa !28
  %241 = getelementptr inbounds i64, ptr %237, i64 %240
  %242 = load i64, ptr %241, align 8, !tbaa !9
  %243 = load ptr, ptr %6, align 8, !tbaa !5
  %244 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %243, i32 0, i32 1
  %245 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %244, i32 0, i32 4
  %246 = load ptr, ptr %245, align 8, !tbaa !24
  %247 = load ptr, ptr %6, align 8, !tbaa !5
  %248 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %247, i32 0, i32 0
  %249 = load i64, ptr %248, align 8, !tbaa !28
  %250 = sub nsw i64 %249, 1
  %251 = getelementptr inbounds i64, ptr %246, i64 %250
  %252 = load i64, ptr %251, align 8, !tbaa !9
  %253 = sub nsw i64 %242, %252
  %254 = load i64, ptr %12, align 8, !tbaa !9
  %255 = sub nsw i64 %253, %254
  %256 = add nsw i64 %255, 1
  %257 = load ptr, ptr %10, align 8, !tbaa !5
  %258 = call noundef i64 @_ZN11alglib_impl9ae_minintEllPNS_8ae_stateE(i64 noundef %233, i64 noundef %256, ptr noundef %257)
  store i64 %258, ptr %7, align 8, !tbaa !9
  %259 = load i64, ptr %7, align 8, !tbaa !9
  %260 = icmp sge i64 %259, 1
  %261 = load ptr, ptr %10, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %260, ptr noundef @.str.264, ptr noundef %261)
  %262 = load ptr, ptr %6, align 8, !tbaa !5
  %263 = load ptr, ptr %6, align 8, !tbaa !5
  %264 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %263, i32 0, i32 2
  %265 = load ptr, ptr %6, align 8, !tbaa !5
  %266 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %265, i32 0, i32 1
  %267 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %266, i32 0, i32 4
  %268 = load ptr, ptr %267, align 8, !tbaa !24
  %269 = load ptr, ptr %6, align 8, !tbaa !5
  %270 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %269, i32 0, i32 0
  %271 = load i64, ptr %270, align 8, !tbaa !28
  %272 = sub nsw i64 %271, 1
  %273 = getelementptr inbounds i64, ptr %268, i64 %272
  %274 = load i64, ptr %273, align 8, !tbaa !9
  %275 = load ptr, ptr %6, align 8, !tbaa !5
  %276 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %275, i32 0, i32 1
  %277 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %276, i32 0, i32 4
  %278 = load ptr, ptr %277, align 8, !tbaa !24
  %279 = load ptr, ptr %6, align 8, !tbaa !5
  %280 = getelementptr inbounds %"struct.alglib_impl::ssamodel", ptr %279, i32 0, i32 0
  %281 = load i64, ptr %280, align 8, !tbaa !28
  %282 = getelementptr inbounds i64, ptr %278, i64 %281
  %283 = load i64, ptr %282, align 8, !tbaa !9
  %284 = load i64, ptr %7, align 8, !tbaa !9
  %285 = load i64, ptr %8, align 8, !tbaa !9
  %286 = load ptr, ptr %9, align 8, !tbaa !5
  %287 = load ptr, ptr %10, align 8, !tbaa !5
  call void @_ZN11alglib_implL23ssa_forecastavgsequenceEPNS_8ssamodelEPNS_9ae_vectorEllllbS3_lPNS_8ae_stateE(ptr noundef %262, ptr noundef %264, i64 noundef %274, i64 noundef %283, i64 noundef %284, i64 noundef %285, i1 noundef zeroext true, ptr noundef %286, i64 noundef 0, ptr noundef %287)
  store i32 0, ptr %13, align 4
  br label %288

288:                                              ; preds = %232, %231, %151, %89, %45
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #4
  %289 = load i32, ptr %13, align 4
  switch i32 %289, label %291 [
    i32 0, label %290
    i32 1, label %290
  ]

290:                                              ; preds = %288, %288
  ret void

291:                                              ; preds = %288
  unreachable
}

declare void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef) #1

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

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

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef zeroext i1 @_ZN11alglib_implL25ssa_hassomethingtoanalyzeEPNS_8ssamodelEPNS_8ae_stateE(ptr noundef, ptr noundef) #3

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

; Function Attrs: mustprogress uwtable
declare hidden void @_ZN11alglib_implL23ssa_forecastavgsequenceEPNS_8ssamodelEPNS_9ae_vectorEllllbS3_lPNS_8ae_stateE(ptr noundef, ptr noundef, i64 noundef, i64 noundef, i64 noundef, i64 noundef, i1 noundef zeroext, ptr noundef, i64 noundef, ptr noundef) #2

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { mustprogress nounwind 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 144}
!12 = !{!"_ZTSN11alglib_impl8ssamodelE", !10, i64 0, !13, i64 8, !13, i64 72, !10, i64 136, !10, i64 144, !10, i64 152, !10, i64 160, !10, i64 168, !10, i64 176, !16, i64 184, !10, i64 264, !10, i64 272, !14, i64 280, !16, i64 288, !16, i64 368, !13, i64 448, !13, i64 512, !10, i64 576, !17, i64 584, !16, i64 2968, !19, i64 3048, !10, i64 3072, !13, i64 3080, !10, i64 3144, !10, i64 3152, !10, i64 3160, !13, i64 3168, !13, i64 3232, !23, i64 3296, !13, i64 3304, !13, i64 3368, !16, i64 3432, !16, i64 3512, !13, i64 3592, !13, i64 3656, !13, i64 3720, !16, i64 3784, !16, i64 3864, !10, i64 3944, !10, i64 3952, !10, i64 3960}
!13 = !{!"_ZTSN11alglib_impl9ae_vectorE", !10, i64 0, !10, i64 8, !14, i64 16, !15, i64 24, !7, i64 56}
!14 = !{!"bool", !7, i64 0}
!15 = !{!"_ZTSN11alglib_impl12ae_dyn_blockE", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24}
!16 = !{!"_ZTSN11alglib_impl9ae_matrixE", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !14, i64 32, !15, i64 40, !7, i64 72}
!17 = !{!"_ZTSN11alglib_impl16eigsubspacestateE", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !18, i64 32, !10, i64 40, !10, i64 48, !14, i64 56, !14, i64 57, !19, i64 64, !14, i64 88, !13, i64 96, !16, i64 160, !16, i64 240, !16, i64 320, !16, i64 400, !16, i64 480, !16, i64 560, !16, i64 640, !16, i64 720, !16, i64 800, !13, i64 880, !13, i64 944, !13, i64 1008, !13, i64 1072, !13, i64 1136, !20, i64 1200, !16, i64 1936, !16, i64 2016, !10, i64 2096, !10, i64 2104, !10, i64 2112, !21, i64 2120}
!18 = !{!"double", !7, i64 0}
!19 = !{!"_ZTSN11alglib_impl10hqrndstateE", !10, i64 0, !10, i64 8, !10, i64 16}
!20 = !{!"_ZTSN11alglib_impl9apbuffersE", !13, i64 0, !13, i64 64, !13, i64 128, !13, i64 192, !13, i64 256, !13, i64 320, !13, i64 384, !13, i64 448, !13, i64 512, !16, i64 576, !16, i64 656}
!21 = !{!"_ZTSN11alglib_impl10rcommstateE", !22, i64 0, !13, i64 8, !13, i64 72, !13, i64 136, !13, i64 200}
!22 = !{!"int", !7, i64 0}
!23 = !{!"_ZTSN11alglib_impl17eigsubspacereportE", !10, i64 0}
!24 = !{!7, !7, i64 0}
!25 = !{!18, !18, i64 0}
!26 = distinct !{!26, !27}
!27 = !{!"llvm.loop.mustprogress"}
!28 = !{!12, !10, i64 0}
!29 = distinct !{!29, !27}
!30 = distinct !{!30, !27}
!31 = !{!12, !10, i64 576}
!32 = distinct !{!32, !27}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

@.str.262 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.263 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.264 = external hidden unnamed_addr constant [43 x i8], align 1
@.str.265 = external hidden unnamed_addr constant [50 x i8], align 1
@.str.266 = external hidden unnamed_addr constant [51 x i8], align 1

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN11alglib_impl18ssaforecastavglastEPNS_8ssamodelEllPNS_9ae_vectorEPNS_8ae_stateE(ptr noundef %0, i64 noundef %1, i64 noundef %2, ptr noundef %3, ptr noundef %4) local_unnamed_addr #1 {
  tail call void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef %3)
  %6 = icmp sgt i64 %2, 0
  tail call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %6, ptr noundef nonnull @.str.262, ptr noundef %4)
  %7 = icmp sgt i64 %1, 0
  tail call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %7, ptr noundef nonnull @.str.263, ptr noundef %4)
  %8 = getelementptr inbounds i8, ptr %0, i64 144
  %9 = load i64, ptr %8, align 8, !tbaa !5
  tail call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %3, i64 noundef %2, ptr noundef %4)
  %10 = tail call noundef zeroext i1 @_ZN11alglib_implL25ssa_hassomethingtoanalyzeEPNS_8ssamodelEPNS_8ae_stateE(ptr noundef %0, ptr noundef %4)
  br i1 %10, label %26, label %.preheader94

.preheader94:                                     ; preds = %5
  br i1 %6, label %.lr.ph, label %.loopexit

.lr.ph:                                           ; preds = %.preheader94
  %11 = getelementptr inbounds i8, ptr %3, i64 56
  %xtraiter = and i64 %2, 3
  %12 = icmp ult i64 %2, 4
  br i1 %12, label %.loopexit.loopexit121.unr-lcssa, label %.lr.ph.new

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

13:                                               ; preds = %13, %.lr.ph.new
  %.097 = phi i64 [ 0, %.lr.ph.new ], [ %25, %13 ]
  %niter = phi i64 [ 0, %.lr.ph.new ], [ %niter.next.3, %13 ]
  %14 = load ptr, ptr %11, align 8, !tbaa !22
  %15 = getelementptr inbounds double, ptr %14, i64 %.097
  store double 0.000000e+00, ptr %15, align 8, !tbaa !23
  %16 = or disjoint i64 %.097, 1
  %17 = load ptr, ptr %11, align 8, !tbaa !22
  %18 = getelementptr inbounds double, ptr %17, i64 %16
  store double 0.000000e+00, ptr %18, align 8, !tbaa !23
  %19 = or disjoint i64 %.097, 2
  %20 = load ptr, ptr %11, align 8, !tbaa !22
  %21 = getelementptr inbounds double, ptr %20, i64 %19
  store double 0.000000e+00, ptr %21, align 8, !tbaa !23
  %22 = or disjoint i64 %.097, 3
  %23 = load ptr, ptr %11, align 8, !tbaa !22
  %24 = getelementptr inbounds double, ptr %23, i64 %22
  store double 0.000000e+00, ptr %24, align 8, !tbaa !23
  %25 = add nuw nsw i64 %.097, 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 %.loopexit.loopexit121.unr-lcssa, label %13, !llvm.loop !24

26:                                               ; preds = %5
  %27 = load i64, ptr %0, align 8, !tbaa !26
  %28 = icmp sgt i64 %27, 0
  tail call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %28, ptr noundef nonnull @.str.264, ptr noundef %4)
  %29 = getelementptr inbounds i8, ptr %0, i64 64
  %30 = load ptr, ptr %29, align 8, !tbaa !22
  %31 = load i64, ptr %0, align 8, !tbaa !26
  %32 = getelementptr inbounds i64, ptr %30, i64 %31
  %33 = load i64, ptr %32, align 8, !tbaa !27
  %34 = getelementptr i8, ptr %32, i64 -8
  %35 = load i64, ptr %34, align 8, !tbaa !27
  %36 = sub nsw i64 %33, %35
  %37 = icmp slt i64 %36, %9
  br i1 %37, label %.preheader, label %53

.preheader:                                       ; preds = %26
  br i1 %6, label %.lr.ph106, label %.loopexit

.lr.ph106:                                        ; preds = %.preheader
  %38 = getelementptr inbounds i8, ptr %3, i64 56
  %xtraiter135 = and i64 %2, 3
  %39 = icmp ult i64 %2, 4
  br i1 %39, label %.loopexit.loopexit.unr-lcssa, label %.lr.ph106.new

.lr.ph106.new:                                    ; preds = %.lr.ph106
  %unroll_iter138 = and i64 %2, 9223372036854775804
  br label %40

40:                                               ; preds = %40, %.lr.ph106.new
  %.1105 = phi i64 [ 0, %.lr.ph106.new ], [ %52, %40 ]
  %niter139 = phi i64 [ 0, %.lr.ph106.new ], [ %niter139.next.3, %40 ]
  %41 = load ptr, ptr %38, align 8, !tbaa !22
  %42 = getelementptr inbounds double, ptr %41, i64 %.1105
  store double 0.000000e+00, ptr %42, align 8, !tbaa !23
  %43 = or disjoint i64 %.1105, 1
  %44 = load ptr, ptr %38, align 8, !tbaa !22
  %45 = getelementptr inbounds double, ptr %44, i64 %43
  store double 0.000000e+00, ptr %45, align 8, !tbaa !23
  %46 = or disjoint i64 %.1105, 2
  %47 = load ptr, ptr %38, align 8, !tbaa !22
  %48 = getelementptr inbounds double, ptr %47, i64 %46
  store double 0.000000e+00, ptr %48, align 8, !tbaa !23
  %49 = or disjoint i64 %.1105, 3
  %50 = load ptr, ptr %38, align 8, !tbaa !22
  %51 = getelementptr inbounds double, ptr %50, i64 %49
  store double 0.000000e+00, ptr %51, align 8, !tbaa !23
  %52 = add nuw nsw i64 %.1105, 4
  %niter139.next.3 = add i64 %niter139, 4
  %niter139.ncmp.3 = icmp eq i64 %niter139.next.3, %unroll_iter138
  br i1 %niter139.ncmp.3, label %.loopexit.loopexit.unr-lcssa, label %40, !llvm.loop !28

53:                                               ; preds = %26
  %54 = icmp eq i64 %9, 1
  br i1 %54, label %55, label %89

55:                                               ; preds = %53
  %56 = icmp sgt i64 %31, 0
  tail call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %56, ptr noundef nonnull @.str.265, ptr noundef %4)
  %57 = load ptr, ptr %29, align 8, !tbaa !22
  %58 = load i64, ptr %0, align 8, !tbaa !26
  %59 = getelementptr inbounds i64, ptr %57, i64 %58
  %60 = load i64, ptr %59, align 8, !tbaa !27
  %61 = getelementptr i8, ptr %59, i64 -8
  %62 = load i64, ptr %61, align 8, !tbaa !27
  %63 = icmp sgt i64 %60, %62
  tail call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %63, ptr noundef nonnull @.str.264, ptr noundef %4)
  br i1 %6, label %.lr.ph103, label %.loopexit

.lr.ph103:                                        ; preds = %55
  %64 = getelementptr inbounds i8, ptr %0, i64 128
  %65 = load i64, ptr %0, align 8, !tbaa !26
  %66 = getelementptr inbounds i8, ptr %3, i64 56
  %xtraiter129 = and i64 %2, 1
  %67 = icmp eq i64 %2, 1
  br i1 %67, label %.loopexit.loopexit119.unr-lcssa, label %.lr.ph103.new

.lr.ph103.new:                                    ; preds = %.lr.ph103
  %unroll_iter132 = and i64 %2, 9223372036854775806
  br label %68

68:                                               ; preds = %68, %.lr.ph103.new
  %.2102 = phi i64 [ 0, %.lr.ph103.new ], [ %88, %68 ]
  %niter133 = phi i64 [ 0, %.lr.ph103.new ], [ %niter133.next.1, %68 ]
  %69 = load ptr, ptr %64, align 8, !tbaa !22
  %70 = load ptr, ptr %29, align 8, !tbaa !22
  %71 = getelementptr inbounds i64, ptr %70, i64 %65
  %72 = load i64, ptr %71, align 8, !tbaa !27
  %73 = getelementptr double, ptr %69, i64 %72
  %74 = getelementptr i8, ptr %73, i64 -8
  %75 = load double, ptr %74, align 8, !tbaa !23
  %76 = load ptr, ptr %66, align 8, !tbaa !22
  %77 = getelementptr inbounds double, ptr %76, i64 %.2102
  store double %75, ptr %77, align 8, !tbaa !23
  %78 = or disjoint i64 %.2102, 1
  %79 = load ptr, ptr %64, align 8, !tbaa !22
  %80 = load ptr, ptr %29, align 8, !tbaa !22
  %81 = getelementptr inbounds i64, ptr %80, i64 %65
  %82 = load i64, ptr %81, align 8, !tbaa !27
  %83 = getelementptr double, ptr %79, i64 %82
  %84 = getelementptr i8, ptr %83, i64 -8
  %85 = load double, ptr %84, align 8, !tbaa !23
  %86 = load ptr, ptr %66, align 8, !tbaa !22
  %87 = getelementptr inbounds double, ptr %86, i64 %78
  store double %85, ptr %87, align 8, !tbaa !23
  %88 = add nuw nsw i64 %.2102, 2
  %niter133.next.1 = add i64 %niter133, 2
  %niter133.ncmp.1 = icmp eq i64 %niter133.next.1, %unroll_iter132
  br i1 %niter133.ncmp.1, label %.loopexit.loopexit119.unr-lcssa, label %68, !llvm.loop !29

89:                                               ; preds = %53
  tail call void @_ZN11alglib_implL15ssa_updatebasisEPNS_8ssamodelEldPNS_8ae_stateE(ptr noundef nonnull %0, i64 noundef 0, double noundef 0.000000e+00, ptr noundef %4)
  %90 = getelementptr inbounds i8, ptr %0, i64 576
  %91 = load i64, ptr %90, align 8, !tbaa !30
  %.not = icmp sle i64 %91, %9
  %92 = icmp sgt i64 %91, 0
  %spec.select = and i1 %.not, %92
  tail call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %spec.select, ptr noundef nonnull @.str.266, ptr noundef %4)
  %93 = load i64, ptr %90, align 8, !tbaa !30
  %94 = icmp eq i64 %93, %9
  br i1 %94, label %95, label %130

95:                                               ; preds = %89
  %96 = load i64, ptr %0, align 8, !tbaa !26
  %97 = icmp sgt i64 %96, 0
  tail call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %97, ptr noundef nonnull @.str.265, ptr noundef %4)
  %98 = load ptr, ptr %29, align 8, !tbaa !22
  %99 = load i64, ptr %0, align 8, !tbaa !26
  %100 = getelementptr inbounds i64, ptr %98, i64 %99
  %101 = load i64, ptr %100, align 8, !tbaa !27
  %102 = getelementptr i8, ptr %100, i64 -8
  %103 = load i64, ptr %102, align 8, !tbaa !27
  %104 = icmp sgt i64 %101, %103
  tail call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %104, ptr noundef nonnull @.str.264, ptr noundef %4)
  br i1 %6, label %.lr.ph100, label %.loopexit

.lr.ph100:                                        ; preds = %95
  %105 = getelementptr inbounds i8, ptr %0, i64 128
  %106 = load i64, ptr %0, align 8, !tbaa !26
  %107 = getelementptr inbounds i8, ptr %3, i64 56
  %xtraiter123 = and i64 %2, 1
  %108 = icmp eq i64 %2, 1
  br i1 %108, label %.loopexit.loopexit120.unr-lcssa, label %.lr.ph100.new

.lr.ph100.new:                                    ; preds = %.lr.ph100
  %unroll_iter126 = and i64 %2, 9223372036854775806
  br label %109

109:                                              ; preds = %109, %.lr.ph100.new
  %.399 = phi i64 [ 0, %.lr.ph100.new ], [ %129, %109 ]
  %niter127 = phi i64 [ 0, %.lr.ph100.new ], [ %niter127.next.1, %109 ]
  %110 = load ptr, ptr %105, align 8, !tbaa !22
  %111 = load ptr, ptr %29, align 8, !tbaa !22
  %112 = getelementptr inbounds i64, ptr %111, i64 %106
  %113 = load i64, ptr %112, align 8, !tbaa !27
  %114 = getelementptr double, ptr %110, i64 %113
  %115 = getelementptr i8, ptr %114, i64 -8
  %116 = load double, ptr %115, align 8, !tbaa !23
  %117 = load ptr, ptr %107, align 8, !tbaa !22
  %118 = getelementptr inbounds double, ptr %117, i64 %.399
  store double %116, ptr %118, align 8, !tbaa !23
  %119 = or disjoint i64 %.399, 1
  %120 = load ptr, ptr %105, align 8, !tbaa !22
  %121 = load ptr, ptr %29, align 8, !tbaa !22
  %122 = getelementptr inbounds i64, ptr %121, i64 %106
  %123 = load i64, ptr %122, align 8, !tbaa !27
  %124 = getelementptr double, ptr %120, i64 %123
  %125 = getelementptr i8, ptr %124, i64 -8
  %126 = load double, ptr %125, align 8, !tbaa !23
  %127 = load ptr, ptr %107, align 8, !tbaa !22
  %128 = getelementptr inbounds double, ptr %127, i64 %119
  store double %126, ptr %128, align 8, !tbaa !23
  %129 = add nuw nsw i64 %.399, 2
  %niter127.next.1 = add i64 %niter127, 2
  %niter127.ncmp.1 = icmp eq i64 %niter127.next.1, %unroll_iter126
  br i1 %niter127.ncmp.1, label %.loopexit.loopexit120.unr-lcssa, label %109, !llvm.loop !31

130:                                              ; preds = %89
  %131 = load ptr, ptr %29, align 8, !tbaa !22
  %132 = load i64, ptr %0, align 8, !tbaa !26
  %133 = getelementptr inbounds i64, ptr %131, i64 %132
  %134 = load i64, ptr %133, align 8, !tbaa !27
  %135 = getelementptr i8, ptr %133, i64 -8
  %136 = load i64, ptr %135, align 8, !tbaa !27
  %137 = add i64 %134, 1
  %138 = add i64 %9, %136
  %139 = sub i64 %137, %138
  %140 = tail call noundef i64 @_ZN11alglib_impl9ae_minintEllPNS_8ae_stateE(i64 noundef %1, i64 noundef %139, ptr noundef %4)
  %141 = icmp sgt i64 %140, 0
  tail call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %141, ptr noundef nonnull @.str.264, ptr noundef %4)
  %142 = getelementptr inbounds i8, ptr %0, i64 72
  %143 = load ptr, ptr %29, align 8, !tbaa !22
  %144 = load i64, ptr %0, align 8, !tbaa !26
  %145 = getelementptr i64, ptr %143, i64 %144
  %146 = getelementptr i8, ptr %145, i64 -8
  %147 = load i64, ptr %146, align 8, !tbaa !27
  %148 = load i64, ptr %145, align 8, !tbaa !27
  tail call void @_ZN11alglib_implL23ssa_forecastavgsequenceEPNS_8ssamodelEPNS_9ae_vectorEllllbS3_lPNS_8ae_stateE(ptr noundef nonnull %0, ptr noundef nonnull %142, i64 noundef %147, i64 noundef %148, i64 noundef %140, i64 noundef %2, i1 noundef zeroext true, ptr noundef %3, i64 noundef 0, ptr noundef %4)
  br label %.loopexit

.loopexit.loopexit.unr-lcssa:                     ; preds = %40, %.lr.ph106
  %.1105.unr = phi i64 [ 0, %.lr.ph106 ], [ %52, %40 ]
  %lcmp.mod137.not = icmp eq i64 %xtraiter135, 0
  br i1 %lcmp.mod137.not, label %.loopexit, label %.epil.preheader134

.epil.preheader134:                               ; preds = %.loopexit.loopexit.unr-lcssa, %.epil.preheader134
  %.1105.epil = phi i64 [ %151, %.epil.preheader134 ], [ %.1105.unr, %.loopexit.loopexit.unr-lcssa ]
  %epil.iter136 = phi i64 [ %epil.iter136.next, %.epil.preheader134 ], [ 0, %.loopexit.loopexit.unr-lcssa ]
  %149 = load ptr, ptr %38, align 8, !tbaa !22
  %150 = getelementptr inbounds double, ptr %149, i64 %.1105.epil
  store double 0.000000e+00, ptr %150, align 8, !tbaa !23
  %151 = add nuw nsw i64 %.1105.epil, 1
  %epil.iter136.next = add i64 %epil.iter136, 1
  %epil.iter136.cmp.not = icmp eq i64 %epil.iter136.next, %xtraiter135
  br i1 %epil.iter136.cmp.not, label %.loopexit, label %.epil.preheader134, !llvm.loop !32

.loopexit.loopexit119.unr-lcssa:                  ; preds = %68, %.lr.ph103
  %.2102.unr = phi i64 [ 0, %.lr.ph103 ], [ %88, %68 ]
  %lcmp.mod131.not = icmp eq i64 %xtraiter129, 0
  br i1 %lcmp.mod131.not, label %.loopexit, label %.loopexit.loopexit119.epilog-lcssa

.loopexit.loopexit119.epilog-lcssa:               ; preds = %.loopexit.loopexit119.unr-lcssa
  %152 = load ptr, ptr %64, align 8, !tbaa !22
  %153 = load ptr, ptr %29, align 8, !tbaa !22
  %154 = getelementptr inbounds i64, ptr %153, i64 %65
  %155 = load i64, ptr %154, align 8, !tbaa !27
  %156 = getelementptr double, ptr %152, i64 %155
  %157 = getelementptr i8, ptr %156, i64 -8
  %158 = load double, ptr %157, align 8, !tbaa !23
  %159 = load ptr, ptr %66, align 8, !tbaa !22
  %160 = getelementptr inbounds double, ptr %159, i64 %.2102.unr
  store double %158, ptr %160, align 8, !tbaa !23
  br label %.loopexit

.loopexit.loopexit120.unr-lcssa:                  ; preds = %109, %.lr.ph100
  %.399.unr = phi i64 [ 0, %.lr.ph100 ], [ %129, %109 ]
  %lcmp.mod125.not = icmp eq i64 %xtraiter123, 0
  br i1 %lcmp.mod125.not, label %.loopexit, label %.loopexit.loopexit120.epilog-lcssa

.loopexit.loopexit120.epilog-lcssa:               ; preds = %.loopexit.loopexit120.unr-lcssa
  %161 = load ptr, ptr %105, align 8, !tbaa !22
  %162 = load ptr, ptr %29, align 8, !tbaa !22
  %163 = getelementptr inbounds i64, ptr %162, i64 %106
  %164 = load i64, ptr %163, align 8, !tbaa !27
  %165 = getelementptr double, ptr %161, i64 %164
  %166 = getelementptr i8, ptr %165, i64 -8
  %167 = load double, ptr %166, align 8, !tbaa !23
  %168 = load ptr, ptr %107, align 8, !tbaa !22
  %169 = getelementptr inbounds double, ptr %168, i64 %.399.unr
  store double %167, ptr %169, align 8, !tbaa !23
  br label %.loopexit

.loopexit.loopexit121.unr-lcssa:                  ; preds = %13, %.lr.ph
  %.097.unr = phi i64 [ 0, %.lr.ph ], [ %25, %13 ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %.loopexit, label %.epil.preheader

.epil.preheader:                                  ; preds = %.loopexit.loopexit121.unr-lcssa, %.epil.preheader
  %.097.epil = phi i64 [ %172, %.epil.preheader ], [ %.097.unr, %.loopexit.loopexit121.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.epil.preheader ], [ 0, %.loopexit.loopexit121.unr-lcssa ]
  %170 = load ptr, ptr %11, align 8, !tbaa !22
  %171 = getelementptr inbounds double, ptr %170, i64 %.097.epil
  store double 0.000000e+00, ptr %171, align 8, !tbaa !23
  %172 = add nuw nsw i64 %.097.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 %.loopexit, label %.epil.preheader, !llvm.loop !34

.loopexit:                                        ; preds = %.loopexit.loopexit121.unr-lcssa, %.epil.preheader, %.loopexit.loopexit120.epilog-lcssa, %.loopexit.loopexit120.unr-lcssa, %.loopexit.loopexit119.epilog-lcssa, %.loopexit.loopexit119.unr-lcssa, %.loopexit.loopexit.unr-lcssa, %.epil.preheader134, %.preheader94, %95, %55, %.preheader, %130
  ret void
}

declare void @_ZN11alglib_impl15ae_vector_clearEPNS_9ae_vectorE(ptr noundef) local_unnamed_addr #0

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

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

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef zeroext i1 @_ZN11alglib_implL25ssa_hassomethingtoanalyzeEPNS_8ssamodelEPNS_8ae_stateE(ptr noundef, ptr noundef) local_unnamed_addr #2

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

; Function Attrs: mustprogress uwtable
declare hidden void @_ZN11alglib_implL23ssa_forecastavgsequenceEPNS_8ssamodelEPNS_9ae_vectorEllllbS3_lPNS_8ae_stateE(ptr noundef, ptr noundef, i64 noundef, i64 noundef, i64 noundef, i64 noundef, i1 noundef zeroext, ptr noundef, i64 noundef, ptr noundef) local_unnamed_addr #1

attributes #0 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !7, i64 144}
!6 = !{!"_ZTSN11alglib_impl8ssamodelE", !7, i64 0, !10, i64 8, !10, i64 72, !7, i64 136, !7, i64 144, !7, i64 152, !7, i64 160, !7, i64 168, !7, i64 176, !14, i64 184, !7, i64 264, !7, i64 272, !11, i64 280, !14, i64 288, !14, i64 368, !10, i64 448, !10, i64 512, !7, i64 576, !15, i64 584, !14, i64 2968, !17, i64 3048, !7, i64 3072, !10, i64 3080, !7, i64 3144, !7, i64 3152, !7, i64 3160, !10, i64 3168, !10, i64 3232, !21, i64 3296, !10, i64 3304, !10, i64 3368, !14, i64 3432, !14, i64 3512, !10, i64 3592, !10, i64 3656, !10, i64 3720, !14, i64 3784, !14, i64 3864, !7, i64 3944, !7, i64 3952, !7, i64 3960}
!7 = !{!"long", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"_ZTSN11alglib_impl9ae_vectorE", !7, i64 0, !7, i64 8, !11, i64 16, !12, i64 24, !8, i64 56}
!11 = !{!"bool", !8, i64 0}
!12 = !{!"_ZTSN11alglib_impl12ae_dyn_blockE", !13, i64 0, !13, i64 8, !13, i64 16, !13, i64 24}
!13 = !{!"any pointer", !8, i64 0}
!14 = !{!"_ZTSN11alglib_impl9ae_matrixE", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !11, i64 32, !12, i64 40, !8, i64 72}
!15 = !{!"_ZTSN11alglib_impl16eigsubspacestateE", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !16, i64 32, !7, i64 40, !7, i64 48, !11, i64 56, !11, i64 57, !17, i64 64, !11, i64 88, !10, i64 96, !14, i64 160, !14, i64 240, !14, i64 320, !14, i64 400, !14, i64 480, !14, i64 560, !14, i64 640, !14, i64 720, !14, i64 800, !10, i64 880, !10, i64 944, !10, i64 1008, !10, i64 1072, !10, i64 1136, !18, i64 1200, !14, i64 1936, !14, i64 2016, !7, i64 2096, !7, i64 2104, !7, i64 2112, !19, i64 2120}
!16 = !{!"double", !8, i64 0}
!17 = !{!"_ZTSN11alglib_impl10hqrndstateE", !7, i64 0, !7, i64 8, !7, i64 16}
!18 = !{!"_ZTSN11alglib_impl9apbuffersE", !10, i64 0, !10, i64 64, !10, i64 128, !10, i64 192, !10, i64 256, !10, i64 320, !10, i64 384, !10, i64 448, !10, i64 512, !14, i64 576, !14, i64 656}
!19 = !{!"_ZTSN11alglib_impl10rcommstateE", !20, i64 0, !10, i64 8, !10, i64 72, !10, i64 136, !10, i64 200}
!20 = !{!"int", !8, i64 0}
!21 = !{!"_ZTSN11alglib_impl17eigsubspacereportE", !7, i64 0}
!22 = !{!8, !8, i64 0}
!23 = !{!16, !16, i64 0}
!24 = distinct !{!24, !25}
!25 = !{!"llvm.loop.mustprogress"}
!26 = !{!6, !7, i64 0}
!27 = !{!7, !7, i64 0}
!28 = distinct !{!28, !25}
!29 = distinct !{!29, !25}
!30 = !{!6, !7, i64 576}
!31 = distinct !{!31, !25}
!32 = distinct !{!32, !33}
!33 = !{!"llvm.loop.unroll.disable"}
!34 = distinct !{!34, !33}


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