; LLVM IR from venumb/ZSPACE :: cpp/depends/alglib/cpp/tests/test_c.ll (Z13testodesolverbPN11alglib_impl8ae_stateE)

; 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 }
%union.anon = 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 }
%"struct.alglib_impl::odesolverreport" = type { i64, i64 }
%"struct.alglib_impl::odesolverstate" = type { i64, i64, double, double, double, i8, %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", i64, i8, double, %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_matrix", i64, i64, %"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" }
%"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" }

@.str.1 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.26 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.27 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.28 = external hidden unnamed_addr constant [43 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

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

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #2

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

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

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

declare i32 @printf(ptr noundef, ...) #1

declare void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef) #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_impl14ae_matrix_initEPNS_9ae_matrixElllPNS_8ae_stateEb(ptr noundef, i64 noundef, i64 noundef, i64 noundef, ptr noundef, i1 noundef zeroext) #1

declare noundef double @_ZN11alglib_impl13ae_randomrealEPNS_8ae_stateE(ptr noundef) #1

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #3

declare noundef double @_ZN11alglib_impl10ae_maxrealEddPNS_8ae_stateE(double noundef, double noundef, ptr noundef) #1

declare noundef double @_ZN11alglib_impl7ae_fabsEdPNS_8ae_stateE(double noundef, ptr noundef) #1

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

declare noundef double @_ZN11alglib_impl6ae_sqrEdPNS_8ae_stateE(double noundef, ptr noundef) #1

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_Z13testodesolverbPN11alglib_impl8ae_stateE(i1 noundef zeroext %0, ptr noundef %1) #4 {
  %3 = alloca i8, align 1
  %4 = alloca ptr, align 8
  %5 = alloca %"struct.alglib_impl::ae_frame", align 8
  %6 = alloca i64, align 8
  %7 = alloca i8, align 1
  %8 = alloca i8, align 1
  %9 = alloca i8, align 1
  %10 = alloca %"struct.alglib_impl::ae_vector", align 8
  %11 = alloca %"struct.alglib_impl::ae_matrix", align 8
  %12 = alloca %"struct.alglib_impl::odesolverreport", align 8
  %13 = alloca %"struct.alglib_impl::ae_vector", align 8
  %14 = alloca %"struct.alglib_impl::ae_vector", align 8
  %15 = alloca double, align 8
  %16 = alloca double, align 8
  %17 = alloca i64, align 8
  %18 = alloca i64, align 8
  %19 = alloca i64, align 8
  %20 = alloca double, align 8
  %21 = alloca i64, align 8
  %22 = alloca i64, align 8
  %23 = alloca i64, align 8
  %24 = alloca double, align 8
  %25 = alloca %"struct.alglib_impl::odesolverstate", align 8
  %26 = alloca i8, align 1
  %27 = zext i1 %0 to i8
  store i8 %27, ptr %3, align 1, !tbaa !5
  store ptr %1, ptr %4, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 32, ptr %5) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #5
  call void @llvm.lifetime.start.p0(i64 1, ptr %7) #5
  call void @llvm.lifetime.start.p0(i64 1, ptr %8) #5
  call void @llvm.lifetime.start.p0(i64 1, ptr %9) #5
  call void @llvm.lifetime.start.p0(i64 64, ptr %10) #5
  call void @llvm.lifetime.start.p0(i64 80, ptr %11) #5
  call void @llvm.lifetime.start.p0(i64 16, ptr %12) #5
  call void @llvm.lifetime.start.p0(i64 64, ptr %13) #5
  call void @llvm.lifetime.start.p0(i64 64, ptr %14) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #5
  call void @llvm.lifetime.start.p0(i64 1232, ptr %25) #5
  call void @llvm.lifetime.start.p0(i64 1, ptr %26) #5
  %28 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef %28, ptr noundef %5)
  call void @llvm.memset.p0.i64(ptr align 8 %10, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %11, i8 0, i64 80, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %12, i8 0, i64 16, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %13, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %14, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %25, i8 0, i64 1232, i1 false)
  %29 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef %10, i64 noundef 0, i64 noundef 3, ptr noundef %29, i1 noundef zeroext true)
  %30 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl14ae_matrix_initEPNS_9ae_matrixElllPNS_8ae_stateEb(ptr noundef %11, i64 noundef 0, i64 noundef 0, i64 noundef 3, ptr noundef %30, i1 noundef zeroext true)
  %31 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl21_odesolverreport_initEPvPNS_8ae_stateEb(ptr noundef %12, ptr noundef %31, i1 noundef zeroext true)
  %32 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef %13, i64 noundef 0, i64 noundef 3, ptr noundef %32, i1 noundef zeroext true)
  %33 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef %14, i64 noundef 0, i64 noundef 3, ptr noundef %33, i1 noundef zeroext true)
  %34 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl20_odesolverstate_initEPvPNS_8ae_stateEb(ptr noundef %25, ptr noundef %34, i1 noundef zeroext true)
  store i8 0, ptr %8, align 1, !tbaa !5
  store i8 0, ptr %9, align 1, !tbaa !5
  store i64 10, ptr %6, align 8, !tbaa !11
  %35 = load i64, ptr %6, align 8, !tbaa !11
  %36 = icmp sge i64 %35, 2
  %37 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %36, ptr noundef @.str.26, ptr noundef %37)
  store i64 0, ptr %18, align 8, !tbaa !11
  br label %38

38:                                               ; preds = %331, %2
  %39 = load i64, ptr %18, align 8, !tbaa !11
  %40 = load i64, ptr %6, align 8, !tbaa !11
  %41 = sub nsw i64 %40, 1
  %42 = icmp sle i64 %39, %41
  br i1 %42, label %43, label %334

43:                                               ; preds = %38
  store i64 0, ptr %17, align 8, !tbaa !11
  br label %44

44:                                               ; preds = %327, %43
  %45 = load i64, ptr %17, align 8, !tbaa !11
  %46 = icmp sle i64 %45, 0
  br i1 %46, label %47, label %330

47:                                               ; preds = %44
  store double 1.000000e-02, ptr %15, align 8, !tbaa !13
  store double 1.000000e-05, ptr %16, align 8, !tbaa !13
  %48 = load i64, ptr %18, align 8, !tbaa !11
  %49 = srem i64 %48, 2
  %50 = icmp eq i64 %49, 0
  br i1 %50, label %51, label %54

51:                                               ; preds = %47
  %52 = load double, ptr %16, align 8, !tbaa !13
  %53 = fneg double %52
  store double %53, ptr %16, align 8, !tbaa !13
  br label %54

54:                                               ; preds = %51, %47
  %55 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %14, i64 noundef 2, ptr noundef %55)
  store i64 0, ptr %23, align 8, !tbaa !11
  br label %56

56:                                               ; preds = %67, %54
  %57 = load i64, ptr %23, align 8, !tbaa !11
  %58 = icmp sle i64 %57, 1
  br i1 %58, label %59, label %70

59:                                               ; preds = %56
  %60 = load ptr, ptr %4, align 8, !tbaa !9
  %61 = call noundef double @_ZN11alglib_impl13ae_randomrealEPNS_8ae_stateE(ptr noundef %60)
  %62 = call double @llvm.fmuladd.f64(double 2.000000e+00, double %61, double -1.000000e+00)
  %63 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %14, i32 0, i32 4
  %64 = load ptr, ptr %63, align 8, !tbaa !15
  %65 = load i64, ptr %23, align 8, !tbaa !11
  %66 = getelementptr inbounds double, ptr %64, i64 %65
  store double %62, ptr %66, align 8, !tbaa !13
  br label %67

67:                                               ; preds = %59
  %68 = load i64, ptr %23, align 8, !tbaa !11
  %69 = add nsw i64 %68, 1
  store i64 %69, ptr %23, align 8, !tbaa !11
  br label %56, !llvm.loop !16

70:                                               ; preds = %56
  %71 = load ptr, ptr %4, align 8, !tbaa !9
  %72 = call noundef i64 @_ZN11alglib_impl16ae_randomintegerElPNS_8ae_stateE(i64 noundef 10, ptr noundef %71)
  %73 = add nsw i64 2, %72
  store i64 %73, ptr %21, align 8, !tbaa !11
  %74 = load i64, ptr %21, align 8, !tbaa !11
  %75 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %13, i64 noundef %74, ptr noundef %75)
  %76 = load i64, ptr %21, align 8, !tbaa !11
  %77 = sub nsw i64 %76, 1
  %78 = sitofp i64 %77 to double
  %79 = load ptr, ptr %4, align 8, !tbaa !9
  %80 = call noundef double @_ZN11alglib_impl13ae_randomrealEPNS_8ae_stateE(ptr noundef %79)
  %81 = fmul double %78, %80
  %82 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %13, i32 0, i32 4
  %83 = load ptr, ptr %82, align 8, !tbaa !15
  %84 = getelementptr inbounds double, ptr %83, i64 0
  store double %81, ptr %84, align 8, !tbaa !13
  store i64 1, ptr %23, align 8, !tbaa !11
  br label %85

85:                                               ; preds = %104, %70
  %86 = load i64, ptr %23, align 8, !tbaa !11
  %87 = load i64, ptr %21, align 8, !tbaa !11
  %88 = sub nsw i64 %87, 1
  %89 = icmp sle i64 %86, %88
  br i1 %89, label %90, label %107

90:                                               ; preds = %85
  %91 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %13, i32 0, i32 4
  %92 = load ptr, ptr %91, align 8, !tbaa !15
  %93 = load i64, ptr %23, align 8, !tbaa !11
  %94 = sub nsw i64 %93, 1
  %95 = getelementptr inbounds double, ptr %92, i64 %94
  %96 = load double, ptr %95, align 8, !tbaa !13
  %97 = load ptr, ptr %4, align 8, !tbaa !9
  %98 = call noundef double @_ZN11alglib_impl13ae_randomrealEPNS_8ae_stateE(ptr noundef %97)
  %99 = fadd double %96, %98
  %100 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %13, i32 0, i32 4
  %101 = load ptr, ptr %100, align 8, !tbaa !15
  %102 = load i64, ptr %23, align 8, !tbaa !11
  %103 = getelementptr inbounds double, ptr %101, i64 %102
  store double %99, ptr %103, align 8, !tbaa !13
  br label %104

104:                                              ; preds = %90
  %105 = load i64, ptr %23, align 8, !tbaa !11
  %106 = add nsw i64 %105, 1
  store i64 %106, ptr %23, align 8, !tbaa !11
  br label %85, !llvm.loop !18

107:                                              ; preds = %85
  %108 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %13, i32 0, i32 4
  %109 = load ptr, ptr %108, align 8, !tbaa !15
  %110 = load i64, ptr %21, align 8, !tbaa !11
  %111 = sub nsw i64 %110, 1
  %112 = getelementptr inbounds double, ptr %109, i64 %111
  %113 = load double, ptr %112, align 8, !tbaa !13
  %114 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %13, i32 0, i32 4
  %115 = load ptr, ptr %114, align 8, !tbaa !15
  %116 = getelementptr inbounds double, ptr %115, i64 0
  %117 = load double, ptr %116, align 8, !tbaa !13
  %118 = fsub double %113, %117
  %119 = fdiv double 0x401921FB54442D18, %118
  store double %119, ptr %20, align 8, !tbaa !13
  %120 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %13, i32 0, i32 4
  %121 = load ptr, ptr %120, align 8, !tbaa !15
  %122 = getelementptr inbounds double, ptr %121, i64 0
  %123 = load i64, ptr %21, align 8, !tbaa !11
  %124 = sub nsw i64 %123, 1
  %125 = call noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef 0, i64 noundef %124)
  %126 = load double, ptr %20, align 8, !tbaa !13
  call void @_ZN11alglib_impl9ae_v_muldEPdlld(ptr noundef %122, i64 noundef 1, i64 noundef %125, double noundef %126)
  %127 = load ptr, ptr %4, align 8, !tbaa !9
  %128 = call noundef double @_ZN11alglib_impl13ae_randomrealEPNS_8ae_stateE(ptr noundef %127)
  %129 = call noundef zeroext i1 @_ZN11alglib_impl13ae_fp_greaterEdd(double noundef %128, double noundef 5.000000e-01)
  br i1 %129, label %130, label %137

130:                                              ; preds = %107
  %131 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %13, i32 0, i32 4
  %132 = load ptr, ptr %131, align 8, !tbaa !15
  %133 = getelementptr inbounds double, ptr %132, i64 0
  %134 = load i64, ptr %21, align 8, !tbaa !11
  %135 = sub nsw i64 %134, 1
  %136 = call noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef 0, i64 noundef %135)
  call void @_ZN11alglib_impl9ae_v_muldEPdlld(ptr noundef %133, i64 noundef 1, i64 noundef %136, double noundef -1.000000e+00)
  br label %137

137:                                              ; preds = %130, %107
  store i64 0, ptr %19, align 8, !tbaa !11
  %138 = load i64, ptr %17, align 8, !tbaa !11
  %139 = icmp eq i64 %138, 0
  br i1 %139, label %140, label %145

140:                                              ; preds = %137
  %141 = load i64, ptr %21, align 8, !tbaa !11
  %142 = load double, ptr %16, align 8, !tbaa !13
  %143 = load double, ptr %15, align 8, !tbaa !13
  %144 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl13odesolverrkckEPNS_9ae_vectorElS1_lddPNS_14odesolverstateEPNS_8ae_stateE(ptr noundef %14, i64 noundef 2, ptr noundef %13, i64 noundef %141, double noundef %142, double noundef %143, ptr noundef %25, ptr noundef %144)
  br label %145

145:                                              ; preds = %140, %137
  br label %146

146:                                              ; preds = %149, %145
  %147 = load ptr, ptr %4, align 8, !tbaa !9
  %148 = call noundef zeroext i1 @_ZN11alglib_impl18odesolveriterationEPNS_14odesolverstateEPNS_8ae_stateE(ptr noundef %25, ptr noundef %147)
  br i1 %148, label %149, label %171

149:                                              ; preds = %146
  %150 = getelementptr inbounds %"struct.alglib_impl::odesolverstate", ptr %25, i32 0, i32 12
  %151 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %150, i32 0, i32 4
  %152 = load ptr, ptr %151, align 8, !tbaa !15
  %153 = getelementptr inbounds double, ptr %152, i64 1
  %154 = load double, ptr %153, align 8, !tbaa !13
  %155 = getelementptr inbounds %"struct.alglib_impl::odesolverstate", ptr %25, i32 0, i32 13
  %156 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %155, i32 0, i32 4
  %157 = load ptr, ptr %156, align 8, !tbaa !15
  %158 = getelementptr inbounds double, ptr %157, i64 0
  store double %154, ptr %158, align 8, !tbaa !13
  %159 = getelementptr inbounds %"struct.alglib_impl::odesolverstate", ptr %25, i32 0, i32 12
  %160 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %159, i32 0, i32 4
  %161 = load ptr, ptr %160, align 8, !tbaa !15
  %162 = getelementptr inbounds double, ptr %161, i64 0
  %163 = load double, ptr %162, align 8, !tbaa !13
  %164 = fneg double %163
  %165 = getelementptr inbounds %"struct.alglib_impl::odesolverstate", ptr %25, i32 0, i32 13
  %166 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %165, i32 0, i32 4
  %167 = load ptr, ptr %166, align 8, !tbaa !15
  %168 = getelementptr inbounds double, ptr %167, i64 1
  store double %164, ptr %168, align 8, !tbaa !13
  %169 = load i64, ptr %19, align 8, !tbaa !11
  %170 = add nsw i64 %169, 1
  store i64 %170, ptr %19, align 8, !tbaa !11
  br label %146, !llvm.loop !19

171:                                              ; preds = %146
  %172 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl16odesolverresultsEPNS_14odesolverstateEPlPNS_9ae_vectorEPNS_9ae_matrixEPNS_15odesolverreportEPNS_8ae_stateE(ptr noundef %25, ptr noundef %22, ptr noundef %10, ptr noundef %11, ptr noundef %12, ptr noundef %172)
  store i8 0, ptr %7, align 1, !tbaa !5
  %173 = getelementptr inbounds %"struct.alglib_impl::odesolverreport", ptr %12, i32 0, i32 1
  %174 = load i64, ptr %173, align 8, !tbaa !20
  %175 = icmp sle i64 %174, 0
  br i1 %175, label %176, label %177

176:                                              ; preds = %171
  store i8 1, ptr %7, align 1, !tbaa !5
  br label %314

177:                                              ; preds = %171
  %178 = load i8, ptr %7, align 1, !tbaa !5, !range !22, !noundef !23
  %179 = trunc i8 %178 to i1
  br i1 %179, label %184, label %180

180:                                              ; preds = %177
  %181 = load i64, ptr %22, align 8, !tbaa !11
  %182 = load i64, ptr %21, align 8, !tbaa !11
  %183 = icmp ne i64 %181, %182
  br label %184

184:                                              ; preds = %180, %177
  %185 = phi i1 [ true, %177 ], [ %183, %180 ]
  %186 = zext i1 %185 to i8
  store i8 %186, ptr %7, align 1, !tbaa !5
  store double 0.000000e+00, ptr %24, align 8, !tbaa !13
  store i64 0, ptr %23, align 8, !tbaa !11
  br label %187

187:                                              ; preds = %288, %184
  %188 = load i64, ptr %23, align 8, !tbaa !11
  %189 = load i64, ptr %21, align 8, !tbaa !11
  %190 = sub nsw i64 %189, 1
  %191 = icmp sle i64 %188, %190
  br i1 %191, label %192, label %291

192:                                              ; preds = %187
  %193 = load double, ptr %24, align 8, !tbaa !13
  %194 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %11, i32 0, i32 6
  %195 = load ptr, ptr %194, align 8, !tbaa !15
  %196 = load i64, ptr %23, align 8, !tbaa !11
  %197 = getelementptr inbounds ptr, ptr %195, i64 %196
  %198 = load ptr, ptr %197, align 8, !tbaa !9
  %199 = getelementptr inbounds double, ptr %198, i64 0
  %200 = load double, ptr %199, align 8, !tbaa !13
  %201 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %14, i32 0, i32 4
  %202 = load ptr, ptr %201, align 8, !tbaa !15
  %203 = getelementptr inbounds double, ptr %202, i64 0
  %204 = load double, ptr %203, align 8, !tbaa !13
  %205 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %10, i32 0, i32 4
  %206 = load ptr, ptr %205, align 8, !tbaa !15
  %207 = load i64, ptr %23, align 8, !tbaa !11
  %208 = getelementptr inbounds double, ptr %206, i64 %207
  %209 = load double, ptr %208, align 8, !tbaa !13
  %210 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %10, i32 0, i32 4
  %211 = load ptr, ptr %210, align 8, !tbaa !15
  %212 = getelementptr inbounds double, ptr %211, i64 0
  %213 = load double, ptr %212, align 8, !tbaa !13
  %214 = fsub double %209, %213
  %215 = load ptr, ptr %4, align 8, !tbaa !9
  %216 = call noundef double @_ZN11alglib_impl6ae_cosEdPNS_8ae_stateE(double noundef %214, ptr noundef %215)
  %217 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %14, i32 0, i32 4
  %218 = load ptr, ptr %217, align 8, !tbaa !15
  %219 = getelementptr inbounds double, ptr %218, i64 1
  %220 = load double, ptr %219, align 8, !tbaa !13
  %221 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %10, i32 0, i32 4
  %222 = load ptr, ptr %221, align 8, !tbaa !15
  %223 = load i64, ptr %23, align 8, !tbaa !11
  %224 = getelementptr inbounds double, ptr %222, i64 %223
  %225 = load double, ptr %224, align 8, !tbaa !13
  %226 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %10, i32 0, i32 4
  %227 = load ptr, ptr %226, align 8, !tbaa !15
  %228 = getelementptr inbounds double, ptr %227, i64 0
  %229 = load double, ptr %228, align 8, !tbaa !13
  %230 = fsub double %225, %229
  %231 = load ptr, ptr %4, align 8, !tbaa !9
  %232 = call noundef double @_ZN11alglib_impl6ae_sinEdPNS_8ae_stateE(double noundef %230, ptr noundef %231)
  %233 = fmul double %220, %232
  %234 = call double @llvm.fmuladd.f64(double %204, double %216, double %233)
  %235 = fsub double %200, %234
  %236 = load ptr, ptr %4, align 8, !tbaa !9
  %237 = call noundef double @_ZN11alglib_impl7ae_fabsEdPNS_8ae_stateE(double noundef %235, ptr noundef %236)
  %238 = load ptr, ptr %4, align 8, !tbaa !9
  %239 = call noundef double @_ZN11alglib_impl10ae_maxrealEddPNS_8ae_stateE(double noundef %193, double noundef %237, ptr noundef %238)
  store double %239, ptr %24, align 8, !tbaa !13
  %240 = load double, ptr %24, align 8, !tbaa !13
  %241 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %11, i32 0, i32 6
  %242 = load ptr, ptr %241, align 8, !tbaa !15
  %243 = load i64, ptr %23, align 8, !tbaa !11
  %244 = getelementptr inbounds ptr, ptr %242, i64 %243
  %245 = load ptr, ptr %244, align 8, !tbaa !9
  %246 = getelementptr inbounds double, ptr %245, i64 1
  %247 = load double, ptr %246, align 8, !tbaa !13
  %248 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %14, i32 0, i32 4
  %249 = load ptr, ptr %248, align 8, !tbaa !15
  %250 = getelementptr inbounds double, ptr %249, i64 0
  %251 = load double, ptr %250, align 8, !tbaa !13
  %252 = fneg double %251
  %253 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %10, i32 0, i32 4
  %254 = load ptr, ptr %253, align 8, !tbaa !15
  %255 = load i64, ptr %23, align 8, !tbaa !11
  %256 = getelementptr inbounds double, ptr %254, i64 %255
  %257 = load double, ptr %256, align 8, !tbaa !13
  %258 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %10, i32 0, i32 4
  %259 = load ptr, ptr %258, align 8, !tbaa !15
  %260 = getelementptr inbounds double, ptr %259, i64 0
  %261 = load double, ptr %260, align 8, !tbaa !13
  %262 = fsub double %257, %261
  %263 = load ptr, ptr %4, align 8, !tbaa !9
  %264 = call noundef double @_ZN11alglib_impl6ae_sinEdPNS_8ae_stateE(double noundef %262, ptr noundef %263)
  %265 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %14, i32 0, i32 4
  %266 = load ptr, ptr %265, align 8, !tbaa !15
  %267 = getelementptr inbounds double, ptr %266, i64 1
  %268 = load double, ptr %267, align 8, !tbaa !13
  %269 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %10, i32 0, i32 4
  %270 = load ptr, ptr %269, align 8, !tbaa !15
  %271 = load i64, ptr %23, align 8, !tbaa !11
  %272 = getelementptr inbounds double, ptr %270, i64 %271
  %273 = load double, ptr %272, align 8, !tbaa !13
  %274 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %10, i32 0, i32 4
  %275 = load ptr, ptr %274, align 8, !tbaa !15
  %276 = getelementptr inbounds double, ptr %275, i64 0
  %277 = load double, ptr %276, align 8, !tbaa !13
  %278 = fsub double %273, %277
  %279 = load ptr, ptr %4, align 8, !tbaa !9
  %280 = call noundef double @_ZN11alglib_impl6ae_cosEdPNS_8ae_stateE(double noundef %278, ptr noundef %279)
  %281 = fmul double %268, %280
  %282 = call double @llvm.fmuladd.f64(double %252, double %264, double %281)
  %283 = fsub double %247, %282
  %284 = load ptr, ptr %4, align 8, !tbaa !9
  %285 = call noundef double @_ZN11alglib_impl7ae_fabsEdPNS_8ae_stateE(double noundef %283, ptr noundef %284)
  %286 = load ptr, ptr %4, align 8, !tbaa !9
  %287 = call noundef double @_ZN11alglib_impl10ae_maxrealEddPNS_8ae_stateE(double noundef %240, double noundef %285, ptr noundef %286)
  store double %287, ptr %24, align 8, !tbaa !13
  br label %288

288:                                              ; preds = %192
  %289 = load i64, ptr %23, align 8, !tbaa !11
  %290 = add nsw i64 %289, 1
  store i64 %290, ptr %23, align 8, !tbaa !11
  br label %187, !llvm.loop !24

291:                                              ; preds = %187
  %292 = load i8, ptr %7, align 1, !tbaa !5, !range !22, !noundef !23
  %293 = trunc i8 %292 to i1
  br i1 %293, label %301, label %294

294:                                              ; preds = %291
  %295 = load double, ptr %24, align 8, !tbaa !13
  %296 = load double, ptr %16, align 8, !tbaa !13
  %297 = load ptr, ptr %4, align 8, !tbaa !9
  %298 = call noundef double @_ZN11alglib_impl7ae_fabsEdPNS_8ae_stateE(double noundef %296, ptr noundef %297)
  %299 = fmul double 1.000000e+01, %298
  %300 = call noundef zeroext i1 @_ZN11alglib_impl13ae_fp_greaterEdd(double noundef %295, double noundef %299)
  br label %301

301:                                              ; preds = %294, %291
  %302 = phi i1 [ true, %291 ], [ %300, %294 ]
  %303 = zext i1 %302 to i8
  store i8 %303, ptr %7, align 1, !tbaa !5
  %304 = load i8, ptr %7, align 1, !tbaa !5, !range !22, !noundef !23
  %305 = trunc i8 %304 to i1
  br i1 %305, label %311, label %306

306:                                              ; preds = %301
  %307 = load i64, ptr %19, align 8, !tbaa !11
  %308 = getelementptr inbounds %"struct.alglib_impl::odesolverreport", ptr %12, i32 0, i32 0
  %309 = load i64, ptr %308, align 8, !tbaa !25
  %310 = icmp ne i64 %307, %309
  br label %311

311:                                              ; preds = %306, %301
  %312 = phi i1 [ true, %301 ], [ %310, %306 ]
  %313 = zext i1 %312 to i8
  store i8 %313, ptr %7, align 1, !tbaa !5
  br label %314

314:                                              ; preds = %311, %176
  %315 = load i64, ptr %17, align 8, !tbaa !11
  %316 = icmp eq i64 %315, 0
  br i1 %316, label %317, label %326

317:                                              ; preds = %314
  %318 = load i8, ptr %8, align 1, !tbaa !5, !range !22, !noundef !23
  %319 = trunc i8 %318 to i1
  br i1 %319, label %323, label %320

320:                                              ; preds = %317
  %321 = load i8, ptr %7, align 1, !tbaa !5, !range !22, !noundef !23
  %322 = trunc i8 %321 to i1
  br label %323

323:                                              ; preds = %320, %317
  %324 = phi i1 [ true, %317 ], [ %322, %320 ]
  %325 = zext i1 %324 to i8
  store i8 %325, ptr %8, align 1, !tbaa !5
  br label %326

326:                                              ; preds = %323, %314
  br label %327

327:                                              ; preds = %326
  %328 = load i64, ptr %17, align 8, !tbaa !11
  %329 = add nsw i64 %328, 1
  store i64 %329, ptr %17, align 8, !tbaa !11
  br label %44, !llvm.loop !26

330:                                              ; preds = %44
  br label %331

331:                                              ; preds = %330
  %332 = load i64, ptr %18, align 8, !tbaa !11
  %333 = add nsw i64 %332, 1
  store i64 %333, ptr %18, align 8, !tbaa !11
  br label %38, !llvm.loop !27

334:                                              ; preds = %38
  %335 = load i64, ptr %6, align 8, !tbaa !11
  %336 = icmp sge i64 %335, 2
  %337 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %336, ptr noundef @.str.26, ptr noundef %337)
  store i64 0, ptr %18, align 8, !tbaa !11
  br label %338

338:                                              ; preds = %469, %334
  %339 = load i64, ptr %18, align 8, !tbaa !11
  %340 = load i64, ptr %6, align 8, !tbaa !11
  %341 = sub nsw i64 %340, 1
  %342 = icmp sle i64 %339, %341
  br i1 %342, label %343, label %472

343:                                              ; preds = %338
  store double 1.000000e-04, ptr %15, align 8, !tbaa !13
  store double 1.000000e-04, ptr %16, align 8, !tbaa !13
  %344 = load i64, ptr %18, align 8, !tbaa !11
  %345 = srem i64 %344, 2
  %346 = icmp eq i64 %345, 0
  br i1 %346, label %347, label %350

347:                                              ; preds = %343
  %348 = load double, ptr %16, align 8, !tbaa !13
  %349 = fneg double %348
  store double %349, ptr %16, align 8, !tbaa !13
  br label %350

350:                                              ; preds = %347, %343
  %351 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %14, i64 noundef 1, ptr noundef %351)
  %352 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %14, i32 0, i32 4
  %353 = load ptr, ptr %352, align 8, !tbaa !15
  %354 = getelementptr inbounds double, ptr %353, i64 0
  store double 0.000000e+00, ptr %354, align 8, !tbaa !13
  store i64 21, ptr %21, align 8, !tbaa !11
  %355 = load i64, ptr %21, align 8, !tbaa !11
  %356 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %13, i64 noundef %355, ptr noundef %356)
  store i64 0, ptr %23, align 8, !tbaa !11
  br label %357

357:                                              ; preds = %374, %350
  %358 = load i64, ptr %23, align 8, !tbaa !11
  %359 = load i64, ptr %21, align 8, !tbaa !11
  %360 = sub nsw i64 %359, 1
  %361 = icmp sle i64 %358, %360
  br i1 %361, label %362, label %377

362:                                              ; preds = %357
  %363 = load i64, ptr %23, align 8, !tbaa !11
  %364 = mul nsw i64 2, %363
  %365 = sitofp i64 %364 to double
  %366 = load i64, ptr %21, align 8, !tbaa !11
  %367 = sub nsw i64 %366, 1
  %368 = sitofp i64 %367 to double
  %369 = fdiv double %365, %368
  %370 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %13, i32 0, i32 4
  %371 = load ptr, ptr %370, align 8, !tbaa !15
  %372 = load i64, ptr %23, align 8, !tbaa !11
  %373 = getelementptr inbounds double, ptr %371, i64 %372
  store double %369, ptr %373, align 8, !tbaa !13
  br label %374

374:                                              ; preds = %362
  %375 = load i64, ptr %23, align 8, !tbaa !11
  %376 = add nsw i64 %375, 1
  store i64 %376, ptr %23, align 8, !tbaa !11
  br label %357, !llvm.loop !28

377:                                              ; preds = %357
  store i64 0, ptr %19, align 8, !tbaa !11
  %378 = load i64, ptr %21, align 8, !tbaa !11
  %379 = load double, ptr %16, align 8, !tbaa !13
  %380 = load double, ptr %15, align 8, !tbaa !13
  %381 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl13odesolverrkckEPNS_9ae_vectorElS1_lddPNS_14odesolverstateEPNS_8ae_stateE(ptr noundef %14, i64 noundef 1, ptr noundef %13, i64 noundef %378, double noundef %379, double noundef %380, ptr noundef %25, ptr noundef %381)
  br label %382

382:                                              ; preds = %385, %377
  %383 = load ptr, ptr %4, align 8, !tbaa !9
  %384 = call noundef zeroext i1 @_ZN11alglib_impl18odesolveriterationEPNS_14odesolverstateEPNS_8ae_stateE(ptr noundef %25, ptr noundef %383)
  br i1 %384, label %385, label %397

385:                                              ; preds = %382
  %386 = getelementptr inbounds %"struct.alglib_impl::odesolverstate", ptr %25, i32 0, i32 11
  %387 = load double, ptr %386, align 8, !tbaa !29
  %388 = fsub double %387, 1.000000e+00
  %389 = load ptr, ptr %4, align 8, !tbaa !9
  %390 = call noundef double @_ZN11alglib_impl10ae_maxrealEddPNS_8ae_stateE(double noundef %388, double noundef 0.000000e+00, ptr noundef %389)
  %391 = getelementptr inbounds %"struct.alglib_impl::odesolverstate", ptr %25, i32 0, i32 13
  %392 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %391, i32 0, i32 4
  %393 = load ptr, ptr %392, align 8, !tbaa !15
  %394 = getelementptr inbounds double, ptr %393, i64 0
  store double %390, ptr %394, align 8, !tbaa !13
  %395 = load i64, ptr %19, align 8, !tbaa !11
  %396 = add nsw i64 %395, 1
  store i64 %396, ptr %19, align 8, !tbaa !11
  br label %382, !llvm.loop !36

397:                                              ; preds = %382
  %398 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl16odesolverresultsEPNS_14odesolverstateEPlPNS_9ae_vectorEPNS_9ae_matrixEPNS_15odesolverreportEPNS_8ae_stateE(ptr noundef %25, ptr noundef %22, ptr noundef %10, ptr noundef %11, ptr noundef %12, ptr noundef %398)
  %399 = getelementptr inbounds %"struct.alglib_impl::odesolverreport", ptr %12, i32 0, i32 1
  %400 = load i64, ptr %399, align 8, !tbaa !20
  %401 = icmp sle i64 %400, 0
  br i1 %401, label %402, label %403

402:                                              ; preds = %397
  store i8 1, ptr %8, align 1, !tbaa !5
  br label %468

403:                                              ; preds = %397
  %404 = load i8, ptr %8, align 1, !tbaa !5, !range !22, !noundef !23
  %405 = trunc i8 %404 to i1
  br i1 %405, label %410, label %406

406:                                              ; preds = %403
  %407 = load i64, ptr %22, align 8, !tbaa !11
  %408 = load i64, ptr %21, align 8, !tbaa !11
  %409 = icmp ne i64 %407, %408
  br label %410

410:                                              ; preds = %406, %403
  %411 = phi i1 [ true, %403 ], [ %409, %406 ]
  %412 = zext i1 %411 to i8
  store i8 %412, ptr %8, align 1, !tbaa !5
  store double 0.000000e+00, ptr %24, align 8, !tbaa !13
  store i64 0, ptr %23, align 8, !tbaa !11
  br label %413

413:                                              ; preds = %443, %410
  %414 = load i64, ptr %23, align 8, !tbaa !11
  %415 = load i64, ptr %21, align 8, !tbaa !11
  %416 = sub nsw i64 %415, 1
  %417 = icmp sle i64 %414, %416
  br i1 %417, label %418, label %446

418:                                              ; preds = %413
  %419 = load double, ptr %24, align 8, !tbaa !13
  %420 = getelementptr inbounds %"struct.alglib_impl::ae_matrix", ptr %11, i32 0, i32 6
  %421 = load ptr, ptr %420, align 8, !tbaa !15
  %422 = load i64, ptr %23, align 8, !tbaa !11
  %423 = getelementptr inbounds ptr, ptr %421, i64 %422
  %424 = load ptr, ptr %423, align 8, !tbaa !9
  %425 = getelementptr inbounds double, ptr %424, i64 0
  %426 = load double, ptr %425, align 8, !tbaa !13
  %427 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %13, i32 0, i32 4
  %428 = load ptr, ptr %427, align 8, !tbaa !15
  %429 = load i64, ptr %23, align 8, !tbaa !11
  %430 = getelementptr inbounds double, ptr %428, i64 %429
  %431 = load double, ptr %430, align 8, !tbaa !13
  %432 = fsub double %431, 1.000000e+00
  %433 = load ptr, ptr %4, align 8, !tbaa !9
  %434 = call noundef double @_ZN11alglib_impl10ae_maxrealEddPNS_8ae_stateE(double noundef %432, double noundef 0.000000e+00, ptr noundef %433)
  %435 = load ptr, ptr %4, align 8, !tbaa !9
  %436 = call noundef double @_ZN11alglib_impl6ae_sqrEdPNS_8ae_stateE(double noundef %434, ptr noundef %435)
  %437 = fdiv double %436, 2.000000e+00
  %438 = fsub double %426, %437
  %439 = load ptr, ptr %4, align 8, !tbaa !9
  %440 = call noundef double @_ZN11alglib_impl7ae_fabsEdPNS_8ae_stateE(double noundef %438, ptr noundef %439)
  %441 = load ptr, ptr %4, align 8, !tbaa !9
  %442 = call noundef double @_ZN11alglib_impl10ae_maxrealEddPNS_8ae_stateE(double noundef %419, double noundef %440, ptr noundef %441)
  store double %442, ptr %24, align 8, !tbaa !13
  br label %443

443:                                              ; preds = %418
  %444 = load i64, ptr %23, align 8, !tbaa !11
  %445 = add nsw i64 %444, 1
  store i64 %445, ptr %23, align 8, !tbaa !11
  br label %413, !llvm.loop !37

446:                                              ; preds = %413
  %447 = load i8, ptr %8, align 1, !tbaa !5, !range !22, !noundef !23
  %448 = trunc i8 %447 to i1
  br i1 %448, label %455, label %449

449:                                              ; preds = %446
  %450 = load double, ptr %24, align 8, !tbaa !13
  %451 = load double, ptr %16, align 8, !tbaa !13
  %452 = load ptr, ptr %4, align 8, !tbaa !9
  %453 = call noundef double @_ZN11alglib_impl7ae_fabsEdPNS_8ae_stateE(double noundef %451, ptr noundef %452)
  %454 = call noundef zeroext i1 @_ZN11alglib_impl13ae_fp_greaterEdd(double noundef %450, double noundef %453)
  br label %455

455:                                              ; preds = %449, %446
  %456 = phi i1 [ true, %446 ], [ %454, %449 ]
  %457 = zext i1 %456 to i8
  store i8 %457, ptr %8, align 1, !tbaa !5
  %458 = load i8, ptr %8, align 1, !tbaa !5, !range !22, !noundef !23
  %459 = trunc i8 %458 to i1
  br i1 %459, label %465, label %460

460:                                              ; preds = %455
  %461 = load i64, ptr %19, align 8, !tbaa !11
  %462 = getelementptr inbounds %"struct.alglib_impl::odesolverreport", ptr %12, i32 0, i32 0
  %463 = load i64, ptr %462, align 8, !tbaa !25
  %464 = icmp ne i64 %461, %463
  br label %465

465:                                              ; preds = %460, %455
  %466 = phi i1 [ true, %455 ], [ %464, %460 ]
  %467 = zext i1 %466 to i8
  store i8 %467, ptr %8, align 1, !tbaa !5
  br label %468

468:                                              ; preds = %465, %402
  br label %469

469:                                              ; preds = %468
  %470 = load i64, ptr %18, align 8, !tbaa !11
  %471 = add nsw i64 %470, 1
  store i64 %471, ptr %18, align 8, !tbaa !11
  br label %338, !llvm.loop !38

472:                                              ; preds = %338
  %473 = load i8, ptr %8, align 1, !tbaa !5, !range !22, !noundef !23
  %474 = trunc i8 %473 to i1
  %475 = zext i1 %474 to i8
  store i8 %475, ptr %9, align 1, !tbaa !5
  %476 = load i8, ptr %3, align 1, !tbaa !5, !range !22, !noundef !23
  %477 = trunc i8 %476 to i1
  br i1 %477, label %495, label %478

478:                                              ; preds = %472
  %479 = call i32 (ptr, ...) @printf(ptr noundef @.str.27)
  %480 = call i32 (ptr, ...) @printf(ptr noundef @.str.28)
  %481 = load i8, ptr %8, align 1, !tbaa !5, !range !22, !noundef !23
  %482 = trunc i8 %481 to i1
  br i1 %482, label %483, label %485

483:                                              ; preds = %478
  %484 = call i32 (ptr, ...) @printf(ptr noundef @.str.7)
  br label %487

485:                                              ; preds = %478
  %486 = call i32 (ptr, ...) @printf(ptr noundef @.str.6)
  br label %487

487:                                              ; preds = %485, %483
  %488 = load i8, ptr %9, align 1, !tbaa !5, !range !22, !noundef !23
  %489 = trunc i8 %488 to i1
  br i1 %489, label %490, label %492

490:                                              ; preds = %487
  %491 = call i32 (ptr, ...) @printf(ptr noundef @.str.1)
  br label %494

492:                                              ; preds = %487
  %493 = call i32 (ptr, ...) @printf(ptr noundef @.str.2)
  br label %494

494:                                              ; preds = %492, %490
  br label %495

495:                                              ; preds = %494, %472
  %496 = load i8, ptr %9, align 1, !tbaa !5, !range !22, !noundef !23
  %497 = trunc i8 %496 to i1
  %498 = xor i1 %497, true
  %499 = zext i1 %498 to i8
  store i8 %499, ptr %26, align 1, !tbaa !5
  %500 = load ptr, ptr %4, align 8, !tbaa !9
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %500)
  %501 = load i8, ptr %26, align 1, !tbaa !5, !range !22, !noundef !23
  %502 = trunc i8 %501 to i1
  call void @llvm.lifetime.end.p0(i64 1, ptr %26) #5
  call void @llvm.lifetime.end.p0(i64 1232, ptr %25) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 64, ptr %14) #5
  call void @llvm.lifetime.end.p0(i64 64, ptr %13) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 80, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 64, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %9) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr %5) #5
  ret i1 %502
}

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

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

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

declare void @_ZN11alglib_impl9ae_v_muldEPdlld(ptr noundef, i64 noundef, i64 noundef, double noundef) #1

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

declare void @_ZN11alglib_impl13odesolverrkckEPNS_9ae_vectorElS1_lddPNS_14odesolverstateEPNS_8ae_stateE(ptr noundef, i64 noundef, ptr noundef, i64 noundef, double noundef, double noundef, ptr noundef, ptr noundef) #1

declare noundef zeroext i1 @_ZN11alglib_impl18odesolveriterationEPNS_14odesolverstateEPNS_8ae_stateE(ptr noundef, ptr noundef) #1

declare void @_ZN11alglib_impl16odesolverresultsEPNS_14odesolverstateEPlPNS_9ae_vectorEPNS_9ae_matrixEPNS_15odesolverreportEPNS_8ae_stateE(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #1

declare noundef double @_ZN11alglib_impl6ae_cosEdPNS_8ae_stateE(double noundef, ptr noundef) #1

declare noundef double @_ZN11alglib_impl6ae_sinEdPNS_8ae_stateE(double noundef, ptr noundef) #1

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #3 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #4 = { 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 #5 = { 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 = !{!"bool", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"long", !7, i64 0}
!13 = !{!14, !14, i64 0}
!14 = !{!"double", !7, i64 0}
!15 = !{!7, !7, i64 0}
!16 = distinct !{!16, !17}
!17 = !{!"llvm.loop.mustprogress"}
!18 = distinct !{!18, !17}
!19 = distinct !{!19, !17}
!20 = !{!21, !12, i64 8}
!21 = !{!"_ZTSN11alglib_impl15odesolverreportE", !12, i64 0, !12, i64 8}
!22 = !{i8 0, i8 2}
!23 = !{}
!24 = distinct !{!24, !17}
!25 = !{!21, !12, i64 0}
!26 = distinct !{!26, !17}
!27 = distinct !{!27, !17}
!28 = distinct !{!28, !17}
!29 = !{!30, !14, i64 256}
!30 = !{!"_ZTSN11alglib_impl14odesolverstateE", !12, i64 0, !12, i64 8, !14, i64 16, !14, i64 24, !14, i64 32, !6, i64 40, !31, i64 48, !31, i64 112, !31, i64 176, !12, i64 240, !6, i64 248, !14, i64 256, !31, i64 264, !31, i64 328, !33, i64 392, !12, i64 472, !12, i64 480, !31, i64 488, !31, i64 552, !31, i64 616, !31, i64 680, !31, i64 744, !33, i64 808, !33, i64 888, !34, i64 968}
!31 = !{!"_ZTSN11alglib_impl9ae_vectorE", !12, i64 0, !12, i64 8, !6, i64 16, !32, i64 24, !7, i64 56}
!32 = !{!"_ZTSN11alglib_impl12ae_dyn_blockE", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24}
!33 = !{!"_ZTSN11alglib_impl9ae_matrixE", !12, i64 0, !12, i64 8, !12, i64 16, !12, i64 24, !6, i64 32, !32, i64 40, !7, i64 72}
!34 = !{!"_ZTSN11alglib_impl10rcommstateE", !35, i64 0, !31, i64 8, !31, i64 72, !31, i64 136, !31, i64 200}
!35 = !{!"int", !7, i64 0}
!36 = distinct !{!36, !17}
!37 = distinct !{!37, !17}
!38 = distinct !{!38, !17}


; 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 }
%union.anon = 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 }
%"struct.alglib_impl::odesolverreport" = type { i64, i64 }
%"struct.alglib_impl::odesolverstate" = type { i64, i64, double, double, double, i8, %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", i64, i8, double, %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_matrix", i64, i64, %"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" }
%"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" }

@.str.1 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.26 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.27 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.28 = external hidden unnamed_addr constant [43 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

declare void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef, ptr noundef) local_unnamed_addr #1

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #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 #1

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

declare noundef i64 @_ZN11alglib_impl16ae_randomintegerElPNS_8ae_stateE(i64 noundef, ptr noundef) local_unnamed_addr #1

; Function Attrs: nofree nounwind
declare noundef i32 @printf(ptr nocapture noundef readonly, ...) local_unnamed_addr #3

declare void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef) local_unnamed_addr #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_impl14ae_matrix_initEPNS_9ae_matrixElllPNS_8ae_stateEb(ptr noundef, i64 noundef, i64 noundef, i64 noundef, ptr noundef, i1 noundef zeroext) local_unnamed_addr #1

declare noundef double @_ZN11alglib_impl13ae_randomrealEPNS_8ae_stateE(ptr noundef) local_unnamed_addr #1

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #4

declare noundef double @_ZN11alglib_impl10ae_maxrealEddPNS_8ae_stateE(double noundef, double noundef, ptr noundef) local_unnamed_addr #1

declare noundef double @_ZN11alglib_impl7ae_fabsEdPNS_8ae_stateE(double noundef, ptr noundef) local_unnamed_addr #1

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

declare noundef double @_ZN11alglib_impl6ae_sqrEdPNS_8ae_stateE(double noundef, ptr noundef) local_unnamed_addr #1

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_Z13testodesolverbPN11alglib_impl8ae_stateE(i1 noundef zeroext %0, ptr noundef %1) local_unnamed_addr #5 {
  %3 = alloca %"struct.alglib_impl::ae_frame", align 8
  %4 = alloca %"struct.alglib_impl::ae_vector", align 8
  %5 = alloca %"struct.alglib_impl::ae_matrix", align 8
  %6 = alloca %"struct.alglib_impl::odesolverreport", align 8
  %7 = alloca %"struct.alglib_impl::ae_vector", align 8
  %8 = alloca %"struct.alglib_impl::ae_vector", align 8
  %9 = alloca i64, align 8
  %10 = alloca %"struct.alglib_impl::odesolverstate", align 8
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %3) #6
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %4) #6
  call void @llvm.lifetime.start.p0(i64 80, ptr nonnull %5) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %6) #6
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %7) #6
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %8) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #6
  call void @llvm.lifetime.start.p0(i64 1232, ptr nonnull %10) #6
  call void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef %1, ptr noundef nonnull %3)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %4, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(80) %5, i8 0, i64 80, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %6, i8 0, i64 16, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %7, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %8, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(1232) %10, i8 0, i64 1232, i1 false)
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef nonnull %4, i64 noundef 0, i64 noundef 3, ptr noundef %1, i1 noundef zeroext true)
  call void @_ZN11alglib_impl14ae_matrix_initEPNS_9ae_matrixElllPNS_8ae_stateEb(ptr noundef nonnull %5, i64 noundef 0, i64 noundef 0, i64 noundef 3, ptr noundef %1, i1 noundef zeroext true)
  call void @_ZN11alglib_impl21_odesolverreport_initEPvPNS_8ae_stateEb(ptr noundef nonnull %6, ptr noundef %1, i1 noundef zeroext true)
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef nonnull %7, i64 noundef 0, i64 noundef 3, ptr noundef %1, i1 noundef zeroext true)
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef nonnull %8, i64 noundef 0, i64 noundef 3, ptr noundef %1, i1 noundef zeroext true)
  call void @_ZN11alglib_impl20_odesolverstate_initEPvPNS_8ae_stateEb(ptr noundef nonnull %10, ptr noundef %1, i1 noundef zeroext true)
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext true, ptr noundef nonnull @.str.26, ptr noundef %1)
  %11 = getelementptr inbounds i8, ptr %8, i64 56
  %12 = getelementptr inbounds i8, ptr %7, i64 56
  %13 = getelementptr inbounds i8, ptr %10, i64 320
  %14 = getelementptr inbounds i8, ptr %10, i64 384
  %15 = getelementptr inbounds i8, ptr %6, i64 8
  %16 = getelementptr inbounds i8, ptr %5, i64 72
  %17 = getelementptr inbounds i8, ptr %4, i64 56
  br label %.preheader

.preheader:                                       ; preds = %2, %136
  %.0126157 = phi i1 [ false, %2 ], [ %137, %136 ]
  %.0133156 = phi i64 [ 0, %2 ], [ %138, %136 ]
  %18 = and i64 %.0133156, 1
  %19 = icmp eq i64 %18, 0
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %8, i64 noundef 2, ptr noundef %1)
  %20 = call noundef double @_ZN11alglib_impl13ae_randomrealEPNS_8ae_stateE(ptr noundef %1)
  %21 = call double @llvm.fmuladd.f64(double %20, double 2.000000e+00, double -1.000000e+00)
  %22 = load ptr, ptr %11, align 8, !tbaa !5
  store double %21, ptr %22, align 8, !tbaa !8
  %23 = call noundef double @_ZN11alglib_impl13ae_randomrealEPNS_8ae_stateE(ptr noundef %1)
  %24 = call double @llvm.fmuladd.f64(double %23, double 2.000000e+00, double -1.000000e+00)
  %25 = load ptr, ptr %11, align 8, !tbaa !5
  %26 = getelementptr inbounds i8, ptr %25, i64 8
  store double %24, ptr %26, align 8, !tbaa !8
  %.0136 = select i1 %19, double -1.000000e-05, double 1.000000e-05
  %27 = call noundef i64 @_ZN11alglib_impl16ae_randomintegerElPNS_8ae_stateE(i64 noundef 10, ptr noundef %1)
  %28 = add i64 %27, 2
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %7, i64 noundef %28, ptr noundef %1)
  %29 = add nsw i64 %27, 1
  %30 = sitofp i64 %29 to double
  %31 = call noundef double @_ZN11alglib_impl13ae_randomrealEPNS_8ae_stateE(ptr noundef %1)
  %32 = fmul double %31, %30
  %33 = load ptr, ptr %12, align 8, !tbaa !5
  store double %32, ptr %33, align 8, !tbaa !8
  %.not142 = icmp slt i64 %27, 0
  br i1 %.not142, label %._crit_edge, label %.lr.ph

.lr.ph:                                           ; preds = %.preheader, %.lr.ph
  %.1125143 = phi i64 [ %42, %.lr.ph ], [ 1, %.preheader ]
  %34 = load ptr, ptr %12, align 8, !tbaa !5
  %35 = getelementptr double, ptr %34, i64 %.1125143
  %36 = getelementptr i8, ptr %35, i64 -8
  %37 = load double, ptr %36, align 8, !tbaa !8
  %38 = call noundef double @_ZN11alglib_impl13ae_randomrealEPNS_8ae_stateE(ptr noundef %1)
  %39 = fadd double %37, %38
  %40 = load ptr, ptr %12, align 8, !tbaa !5
  %41 = getelementptr inbounds double, ptr %40, i64 %.1125143
  store double %39, ptr %41, align 8, !tbaa !8
  %42 = add nuw i64 %.1125143, 1
  %exitcond = icmp eq i64 %42, %28
  br i1 %exitcond, label %._crit_edge, label %.lr.ph, !llvm.loop !10

._crit_edge:                                      ; preds = %.lr.ph, %.preheader
  %43 = load ptr, ptr %12, align 8, !tbaa !5
  %44 = getelementptr inbounds double, ptr %43, i64 %29
  %45 = load double, ptr %44, align 8, !tbaa !8
  %46 = load double, ptr %43, align 8, !tbaa !8
  %47 = fsub double %45, %46
  %48 = fdiv double 0x401921FB54442D18, %47
  %49 = call noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef 0, i64 noundef %29)
  call void @_ZN11alglib_impl9ae_v_muldEPdlld(ptr noundef nonnull %43, i64 noundef 1, i64 noundef %49, double noundef %48)
  %50 = call noundef double @_ZN11alglib_impl13ae_randomrealEPNS_8ae_stateE(ptr noundef %1)
  %51 = call noundef zeroext i1 @_ZN11alglib_impl13ae_fp_greaterEdd(double noundef %50, double noundef 5.000000e-01)
  br i1 %51, label %52, label %55

52:                                               ; preds = %._crit_edge
  %53 = load ptr, ptr %12, align 8, !tbaa !5
  %54 = call noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef 0, i64 noundef %29)
  call void @_ZN11alglib_impl9ae_v_muldEPdlld(ptr noundef %53, i64 noundef 1, i64 noundef %54, double noundef -1.000000e+00)
  br label %55

55:                                               ; preds = %._crit_edge, %52
  call void @_ZN11alglib_impl13odesolverrkckEPNS_9ae_vectorElS1_lddPNS_14odesolverstateEPNS_8ae_stateE(ptr noundef nonnull %8, i64 noundef 2, ptr noundef nonnull %7, i64 noundef %28, double noundef %.0136, double noundef 1.000000e-02, ptr noundef nonnull %10, ptr noundef %1)
  %56 = call noundef zeroext i1 @_ZN11alglib_impl18odesolveriterationEPNS_14odesolverstateEPNS_8ae_stateE(ptr noundef nonnull %10, ptr noundef %1)
  br i1 %56, label %.lr.ph146, label %._crit_edge147

.lr.ph146:                                        ; preds = %55, %.lr.ph146
  %.0131144 = phi i64 [ %66, %.lr.ph146 ], [ 0, %55 ]
  %57 = load ptr, ptr %13, align 8, !tbaa !5
  %58 = getelementptr inbounds i8, ptr %57, i64 8
  %59 = load double, ptr %58, align 8, !tbaa !8
  %60 = load ptr, ptr %14, align 8, !tbaa !5
  store double %59, ptr %60, align 8, !tbaa !8
  %61 = load ptr, ptr %13, align 8, !tbaa !5
  %62 = load double, ptr %61, align 8, !tbaa !8
  %63 = fneg double %62
  %64 = load ptr, ptr %14, align 8, !tbaa !5
  %65 = getelementptr inbounds i8, ptr %64, i64 8
  store double %63, ptr %65, align 8, !tbaa !8
  %66 = add nuw nsw i64 %.0131144, 1
  %67 = call noundef zeroext i1 @_ZN11alglib_impl18odesolveriterationEPNS_14odesolverstateEPNS_8ae_stateE(ptr noundef nonnull %10, ptr noundef %1)
  br i1 %67, label %.lr.ph146, label %._crit_edge147, !llvm.loop !12

._crit_edge147:                                   ; preds = %.lr.ph146, %55
  %.0131.lcssa = phi i64 [ 0, %55 ], [ %66, %.lr.ph146 ]
  call void @_ZN11alglib_impl16odesolverresultsEPNS_14odesolverstateEPlPNS_9ae_vectorEPNS_9ae_matrixEPNS_15odesolverreportEPNS_8ae_stateE(ptr noundef nonnull %10, ptr noundef nonnull %9, ptr noundef nonnull %4, ptr noundef nonnull %5, ptr noundef nonnull %6, ptr noundef %1)
  %68 = load i64, ptr %15, align 8, !tbaa !13
  %69 = icmp slt i64 %68, 1
  br i1 %69, label %136, label %70

70:                                               ; preds = %._crit_edge147
  %71 = load i64, ptr %9, align 8
  %.not139 = icmp eq i64 %71, %28
  %.not140148 = icmp slt i64 %27, -1
  br i1 %.not140148, label %._crit_edge153, label %.lr.ph152

.lr.ph152:                                        ; preds = %70, %.lr.ph152
  %.0123150 = phi double [ %125, %.lr.ph152 ], [ 0.000000e+00, %70 ]
  %.2149 = phi i64 [ %126, %.lr.ph152 ], [ 0, %70 ]
  %72 = load ptr, ptr %16, align 8, !tbaa !5
  %73 = getelementptr inbounds ptr, ptr %72, i64 %.2149
  %74 = load ptr, ptr %73, align 8, !tbaa !16
  %75 = load double, ptr %74, align 8, !tbaa !8
  %76 = load ptr, ptr %11, align 8, !tbaa !5
  %77 = load double, ptr %76, align 8, !tbaa !8
  %78 = load ptr, ptr %17, align 8, !tbaa !5
  %79 = getelementptr inbounds double, ptr %78, i64 %.2149
  %80 = load double, ptr %79, align 8, !tbaa !8
  %81 = load double, ptr %78, align 8, !tbaa !8
  %82 = fsub double %80, %81
  %83 = call noundef double @_ZN11alglib_impl6ae_cosEdPNS_8ae_stateE(double noundef %82, ptr noundef %1)
  %84 = load ptr, ptr %11, align 8, !tbaa !5
  %85 = getelementptr inbounds i8, ptr %84, i64 8
  %86 = load double, ptr %85, align 8, !tbaa !8
  %87 = load ptr, ptr %17, align 8, !tbaa !5
  %88 = getelementptr inbounds double, ptr %87, i64 %.2149
  %89 = load double, ptr %88, align 8, !tbaa !8
  %90 = load double, ptr %87, align 8, !tbaa !8
  %91 = fsub double %89, %90
  %92 = call noundef double @_ZN11alglib_impl6ae_sinEdPNS_8ae_stateE(double noundef %91, ptr noundef %1)
  %93 = fmul double %86, %92
  %94 = call double @llvm.fmuladd.f64(double %77, double %83, double %93)
  %95 = fsub double %75, %94
  %96 = call noundef double @_ZN11alglib_impl7ae_fabsEdPNS_8ae_stateE(double noundef %95, ptr noundef %1)
  %97 = call noundef double @_ZN11alglib_impl10ae_maxrealEddPNS_8ae_stateE(double noundef %.0123150, double noundef %96, ptr noundef %1)
  %98 = load ptr, ptr %16, align 8, !tbaa !5
  %99 = getelementptr inbounds ptr, ptr %98, i64 %.2149
  %100 = load ptr, ptr %99, align 8, !tbaa !16
  %101 = getelementptr inbounds i8, ptr %100, i64 8
  %102 = load double, ptr %101, align 8, !tbaa !8
  %103 = load ptr, ptr %11, align 8, !tbaa !5
  %104 = load double, ptr %103, align 8, !tbaa !8
  %105 = fneg double %104
  %106 = load ptr, ptr %17, align 8, !tbaa !5
  %107 = getelementptr inbounds double, ptr %106, i64 %.2149
  %108 = load double, ptr %107, align 8, !tbaa !8
  %109 = load double, ptr %106, align 8, !tbaa !8
  %110 = fsub double %108, %109
  %111 = call noundef double @_ZN11alglib_impl6ae_sinEdPNS_8ae_stateE(double noundef %110, ptr noundef %1)
  %112 = load ptr, ptr %11, align 8, !tbaa !5
  %113 = getelementptr inbounds i8, ptr %112, i64 8
  %114 = load double, ptr %113, align 8, !tbaa !8
  %115 = load ptr, ptr %17, align 8, !tbaa !5
  %116 = getelementptr inbounds double, ptr %115, i64 %.2149
  %117 = load double, ptr %116, align 8, !tbaa !8
  %118 = load double, ptr %115, align 8, !tbaa !8
  %119 = fsub double %117, %118
  %120 = call noundef double @_ZN11alglib_impl6ae_cosEdPNS_8ae_stateE(double noundef %119, ptr noundef %1)
  %121 = fmul double %114, %120
  %122 = call double @llvm.fmuladd.f64(double %105, double %111, double %121)
  %123 = fsub double %102, %122
  %124 = call noundef double @_ZN11alglib_impl7ae_fabsEdPNS_8ae_stateE(double noundef %123, ptr noundef %1)
  %125 = call noundef double @_ZN11alglib_impl10ae_maxrealEddPNS_8ae_stateE(double noundef %97, double noundef %124, ptr noundef %1)
  %126 = add nuw i64 %.2149, 1
  %exitcond172 = icmp eq i64 %126, %28
  br i1 %exitcond172, label %._crit_edge153, label %.lr.ph152, !llvm.loop !18

._crit_edge153:                                   ; preds = %.lr.ph152, %70
  %.0123.lcssa = phi double [ 0.000000e+00, %70 ], [ %125, %.lr.ph152 ]
  br i1 %.not139, label %127, label %131

127:                                              ; preds = %._crit_edge153
  %128 = call noundef double @_ZN11alglib_impl7ae_fabsEdPNS_8ae_stateE(double noundef %.0136, ptr noundef %1)
  %129 = fmul double %128, 1.000000e+01
  %130 = call noundef zeroext i1 @_ZN11alglib_impl13ae_fp_greaterEdd(double noundef %.0123.lcssa, double noundef %129)
  br label %131

131:                                              ; preds = %127, %._crit_edge153
  %132 = phi i1 [ true, %._crit_edge153 ], [ %130, %127 ]
  %133 = load i64, ptr %6, align 8
  %134 = icmp ne i64 %.0131.lcssa, %133
  %135 = select i1 %132, i1 true, i1 %134
  br label %136

136:                                              ; preds = %._crit_edge147, %131
  %.0 = phi i1 [ %135, %131 ], [ true, %._crit_edge147 ]
  %137 = select i1 %.0126157, i1 true, i1 %.0
  %138 = add nuw nsw i64 %.0133156, 1
  %exitcond173.not = icmp eq i64 %138, 10
  br i1 %exitcond173.not, label %139, label %.preheader, !llvm.loop !19

139:                                              ; preds = %136
  %140 = zext i1 %137 to i8
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext true, ptr noundef nonnull @.str.26, ptr noundef %1)
  %141 = getelementptr inbounds i8, ptr %10, i64 256
  br label %142

142:                                              ; preds = %139, %209
  %.3129167 = phi i8 [ %140, %139 ], [ %.4130, %209 ]
  %.1134166 = phi i64 [ 0, %139 ], [ %210, %209 ]
  %143 = and i64 %.1134166, 1
  %144 = icmp eq i64 %143, 0
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %8, i64 noundef 1, ptr noundef %1)
  %145 = load ptr, ptr %11, align 8, !tbaa !5
  store double 0.000000e+00, ptr %145, align 8, !tbaa !8
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %7, i64 noundef 21, ptr noundef %1)
  %146 = load ptr, ptr %12, align 8, !tbaa !5
  store double 0.000000e+00, ptr %146, align 8, !tbaa !8
  %147 = load ptr, ptr %12, align 8, !tbaa !5
  %148 = getelementptr inbounds i8, ptr %147, i64 8
  store double 1.000000e-01, ptr %148, align 8, !tbaa !8
  %149 = load ptr, ptr %12, align 8, !tbaa !5
  %150 = getelementptr inbounds i8, ptr %149, i64 16
  store double 2.000000e-01, ptr %150, align 8, !tbaa !8
  %151 = load ptr, ptr %12, align 8, !tbaa !5
  %152 = getelementptr inbounds i8, ptr %151, i64 24
  store double 3.000000e-01, ptr %152, align 8, !tbaa !8
  %153 = load ptr, ptr %12, align 8, !tbaa !5
  %154 = getelementptr inbounds i8, ptr %153, i64 32
  store double 4.000000e-01, ptr %154, align 8, !tbaa !8
  %155 = load ptr, ptr %12, align 8, !tbaa !5
  %156 = getelementptr inbounds i8, ptr %155, i64 40
  store double 5.000000e-01, ptr %156, align 8, !tbaa !8
  %157 = load ptr, ptr %12, align 8, !tbaa !5
  %158 = getelementptr inbounds i8, ptr %157, i64 48
  store double 6.000000e-01, ptr %158, align 8, !tbaa !8
  %159 = load ptr, ptr %12, align 8, !tbaa !5
  %160 = getelementptr inbounds i8, ptr %159, i64 56
  store double 0x3FE6666666666666, ptr %160, align 8, !tbaa !8
  %161 = load ptr, ptr %12, align 8, !tbaa !5
  %162 = getelementptr inbounds i8, ptr %161, i64 64
  store <2 x double> <double 8.000000e-01, double 9.000000e-01>, ptr %162, align 8, !tbaa !8
  %163 = getelementptr inbounds i8, ptr %161, i64 80
  store <2 x double> <double 1.000000e+00, double 1.100000e+00>, ptr %163, align 8, !tbaa !8
  %164 = getelementptr inbounds i8, ptr %161, i64 96
  store <2 x double> <double 1.200000e+00, double 1.300000e+00>, ptr %164, align 8, !tbaa !8
  %165 = getelementptr inbounds i8, ptr %161, i64 112
  store <2 x double> <double 1.400000e+00, double 1.500000e+00>, ptr %165, align 8, !tbaa !8
  %166 = getelementptr inbounds i8, ptr %161, i64 128
  store <2 x double> <double 1.600000e+00, double 1.700000e+00>, ptr %166, align 8, !tbaa !8
  %167 = getelementptr inbounds i8, ptr %161, i64 144
  store <2 x double> <double 1.800000e+00, double 1.900000e+00>, ptr %167, align 8, !tbaa !8
  %168 = getelementptr inbounds i8, ptr %161, i64 160
  store double 2.000000e+00, ptr %168, align 8, !tbaa !8
  %.1137 = select i1 %144, double -1.000000e-04, double 1.000000e-04
  call void @_ZN11alglib_impl13odesolverrkckEPNS_9ae_vectorElS1_lddPNS_14odesolverstateEPNS_8ae_stateE(ptr noundef nonnull %8, i64 noundef 1, ptr noundef nonnull %7, i64 noundef 21, double noundef %.1137, double noundef 1.000000e-04, ptr noundef nonnull %10, ptr noundef %1)
  %169 = call noundef zeroext i1 @_ZN11alglib_impl18odesolveriterationEPNS_14odesolverstateEPNS_8ae_stateE(ptr noundef nonnull %10, ptr noundef %1)
  br i1 %169, label %.lr.ph161, label %._crit_edge162

.lr.ph161:                                        ; preds = %142, %.lr.ph161
  %.1132159 = phi i64 [ %174, %.lr.ph161 ], [ 0, %142 ]
  %170 = load double, ptr %141, align 8, !tbaa !20
  %171 = fadd double %170, -1.000000e+00
  %172 = call noundef double @_ZN11alglib_impl10ae_maxrealEddPNS_8ae_stateE(double noundef %171, double noundef 0.000000e+00, ptr noundef %1)
  %173 = load ptr, ptr %14, align 8, !tbaa !5
  store double %172, ptr %173, align 8, !tbaa !8
  %174 = add nuw nsw i64 %.1132159, 1
  %175 = call noundef zeroext i1 @_ZN11alglib_impl18odesolveriterationEPNS_14odesolverstateEPNS_8ae_stateE(ptr noundef nonnull %10, ptr noundef %1)
  br i1 %175, label %.lr.ph161, label %._crit_edge162, !llvm.loop !28

._crit_edge162:                                   ; preds = %.lr.ph161, %142
  %.1132.lcssa = phi i64 [ 0, %142 ], [ %174, %.lr.ph161 ]
  call void @_ZN11alglib_impl16odesolverresultsEPNS_14odesolverstateEPlPNS_9ae_vectorEPNS_9ae_matrixEPNS_15odesolverreportEPNS_8ae_stateE(ptr noundef nonnull %10, ptr noundef nonnull %9, ptr noundef nonnull %4, ptr noundef nonnull %5, ptr noundef nonnull %6, ptr noundef %1)
  %176 = load i64, ptr %15, align 8, !tbaa !13
  %177 = icmp slt i64 %176, 1
  br i1 %177, label %209, label %178

178:                                              ; preds = %._crit_edge162
  %179 = load i64, ptr %9, align 8
  %180 = icmp ne i64 %179, 21
  br label %181

181:                                              ; preds = %178, %181
  %.1165 = phi double [ 0.000000e+00, %178 ], [ %195, %181 ]
  %.4164 = phi i64 [ 0, %178 ], [ %196, %181 ]
  %182 = load ptr, ptr %16, align 8, !tbaa !5
  %183 = getelementptr inbounds ptr, ptr %182, i64 %.4164
  %184 = load ptr, ptr %183, align 8, !tbaa !16
  %185 = load double, ptr %184, align 8, !tbaa !8
  %186 = load ptr, ptr %12, align 8, !tbaa !5
  %187 = getelementptr inbounds double, ptr %186, i64 %.4164
  %188 = load double, ptr %187, align 8, !tbaa !8
  %189 = fadd double %188, -1.000000e+00
  %190 = call noundef double @_ZN11alglib_impl10ae_maxrealEddPNS_8ae_stateE(double noundef %189, double noundef 0.000000e+00, ptr noundef %1)
  %191 = call noundef double @_ZN11alglib_impl6ae_sqrEdPNS_8ae_stateE(double noundef %190, ptr noundef %1)
  %192 = fmul double %191, 5.000000e-01
  %193 = fsub double %185, %192
  %194 = call noundef double @_ZN11alglib_impl7ae_fabsEdPNS_8ae_stateE(double noundef %193, ptr noundef %1)
  %195 = call noundef double @_ZN11alglib_impl10ae_maxrealEddPNS_8ae_stateE(double noundef %.1165, double noundef %194, ptr noundef %1)
  %196 = add nuw nsw i64 %.4164, 1
  %exitcond175.not = icmp eq i64 %196, 21
  br i1 %exitcond175.not, label %197, label %181, !llvm.loop !29

197:                                              ; preds = %181
  %198 = trunc nuw i8 %.3129167 to i1
  %199 = select i1 %198, i1 true, i1 %180
  br i1 %199, label %203, label %200

200:                                              ; preds = %197
  %201 = call noundef double @_ZN11alglib_impl7ae_fabsEdPNS_8ae_stateE(double noundef %.1137, ptr noundef %1)
  %202 = call noundef zeroext i1 @_ZN11alglib_impl13ae_fp_greaterEdd(double noundef %195, double noundef %201)
  br label %203

203:                                              ; preds = %200, %197
  %204 = phi i1 [ true, %197 ], [ %202, %200 ]
  %205 = load i64, ptr %6, align 8
  %206 = icmp ne i64 %.1132.lcssa, %205
  %207 = select i1 %204, i1 true, i1 %206
  %208 = zext i1 %207 to i8
  br label %209

209:                                              ; preds = %._crit_edge162, %203
  %.4130 = phi i8 [ %208, %203 ], [ 1, %._crit_edge162 ]
  %210 = add nuw nsw i64 %.1134166, 1
  %exitcond176.not = icmp eq i64 %210, 10
  br i1 %exitcond176.not, label %211, label %142, !llvm.loop !30

211:                                              ; preds = %209
  %212 = trunc nuw i8 %.4130 to i1
  br i1 %0, label %217, label %.sink.split

.sink.split:                                      ; preds = %211
  %213 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.27)
  %214 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.28)
  %.str.7..str.6 = select i1 %212, ptr @.str.7, ptr @.str.6
  %.str.1..str.2 = select i1 %212, ptr @.str.1, ptr @.str.2
  %215 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) %.str.7..str.6)
  %216 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) %.str.1..str.2)
  br label %217

217:                                              ; preds = %.sink.split, %211
  %218 = xor i1 %212, true
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %1)
  call void @llvm.lifetime.end.p0(i64 1232, ptr nonnull %10) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #6
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %8) #6
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %7) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %6) #6
  call void @llvm.lifetime.end.p0(i64 80, ptr nonnull %5) #6
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %4) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %3) #6
  ret i1 %218
}

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

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

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

declare void @_ZN11alglib_impl9ae_v_muldEPdlld(ptr noundef, i64 noundef, i64 noundef, double noundef) local_unnamed_addr #1

declare noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef, i64 noundef) local_unnamed_addr #1

declare void @_ZN11alglib_impl13odesolverrkckEPNS_9ae_vectorElS1_lddPNS_14odesolverstateEPNS_8ae_stateE(ptr noundef, i64 noundef, ptr noundef, i64 noundef, double noundef, double noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare noundef zeroext i1 @_ZN11alglib_impl18odesolveriterationEPNS_14odesolverstateEPNS_8ae_stateE(ptr noundef, ptr noundef) local_unnamed_addr #1

declare void @_ZN11alglib_impl16odesolverresultsEPNS_14odesolverstateEPlPNS_9ae_vectorEPNS_9ae_matrixEPNS_15odesolverreportEPNS_8ae_stateE(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare noundef double @_ZN11alglib_impl6ae_cosEdPNS_8ae_stateE(double noundef, ptr noundef) local_unnamed_addr #1

declare noundef double @_ZN11alglib_impl6ae_sinEdPNS_8ae_stateE(double noundef, ptr noundef) local_unnamed_addr #1

attributes #0 = { mustprogress 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 nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #3 = { nofree nounwind "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 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #5 = { 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 #6 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !9, i64 0}
!9 = !{!"double", !6, i64 0}
!10 = distinct !{!10, !11}
!11 = !{!"llvm.loop.mustprogress"}
!12 = distinct !{!12, !11}
!13 = !{!14, !15, i64 8}
!14 = !{!"_ZTSN11alglib_impl15odesolverreportE", !15, i64 0, !15, i64 8}
!15 = !{!"long", !6, i64 0}
!16 = !{!17, !17, i64 0}
!17 = !{!"any pointer", !6, i64 0}
!18 = distinct !{!18, !11}
!19 = distinct !{!19, !11}
!20 = !{!21, !9, i64 256}
!21 = !{!"_ZTSN11alglib_impl14odesolverstateE", !15, i64 0, !15, i64 8, !9, i64 16, !9, i64 24, !9, i64 32, !22, i64 40, !23, i64 48, !23, i64 112, !23, i64 176, !15, i64 240, !22, i64 248, !9, i64 256, !23, i64 264, !23, i64 328, !25, i64 392, !15, i64 472, !15, i64 480, !23, i64 488, !23, i64 552, !23, i64 616, !23, i64 680, !23, i64 744, !25, i64 808, !25, i64 888, !26, i64 968}
!22 = !{!"bool", !6, i64 0}
!23 = !{!"_ZTSN11alglib_impl9ae_vectorE", !15, i64 0, !15, i64 8, !22, i64 16, !24, i64 24, !6, i64 56}
!24 = !{!"_ZTSN11alglib_impl12ae_dyn_blockE", !17, i64 0, !17, i64 8, !17, i64 16, !17, i64 24}
!25 = !{!"_ZTSN11alglib_impl9ae_matrixE", !15, i64 0, !15, i64 8, !15, i64 16, !15, i64 24, !22, i64 32, !24, i64 40, !6, i64 72}
!26 = !{!"_ZTSN11alglib_impl10rcommstateE", !27, i64 0, !23, i64 8, !23, i64 72, !23, i64 136, !23, i64 200}
!27 = !{!"int", !6, i64 0}
!28 = distinct !{!28, !11}
!29 = distinct !{!29, !11}
!30 = distinct !{!30, !11}


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