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

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

@.str.9 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [46 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: mustprogress uwtable
declare dso_local void @_ZN11alglib_impl6fftc1dEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef, i64 noundef, ptr noundef) #1

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN11alglib_impl9fftr1dbufEPKNS_9ae_vectorElPS0_PNS_8ae_stateE(ptr noundef %0, i64 noundef %1, ptr noundef %2, ptr noundef %3) #1 {
  %5 = alloca ptr, align 8
  %6 = alloca i64, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca %"struct.alglib_impl::ae_frame", align 8
  %10 = alloca i64, align 8
  %11 = alloca i64, align 8
  %12 = alloca i64, align 8
  %13 = alloca %"struct.alglib_impl::ae_complex", align 8
  %14 = alloca %"struct.alglib_impl::ae_complex", align 8
  %15 = alloca %"struct.alglib_impl::ae_complex", align 8
  %16 = alloca %"struct.alglib_impl::ae_vector", align 8
  %17 = alloca %"struct.alglib_impl::fasttransformplan", align 8
  %18 = alloca %"struct.alglib_impl::ae_complex", align 8
  %19 = alloca i32, align 4
  %20 = alloca %"struct.alglib_impl::ae_complex", align 8
  %21 = alloca %"struct.alglib_impl::ae_complex", align 8
  %22 = alloca %"struct.alglib_impl::ae_complex", align 8
  %23 = alloca %"struct.alglib_impl::ae_complex", align 8
  %24 = alloca %"struct.alglib_impl::ae_complex", align 8
  %25 = alloca %"struct.alglib_impl::ae_complex", align 8
  %26 = alloca %"struct.alglib_impl::ae_complex", align 8
  %27 = alloca %"struct.alglib_impl::ae_complex", align 8
  %28 = alloca %"struct.alglib_impl::ae_complex", align 8
  %29 = alloca %"struct.alglib_impl::ae_complex", align 8
  %30 = alloca %"struct.alglib_impl::ae_complex", align 8
  %31 = alloca %"struct.alglib_impl::ae_complex", align 8
  store ptr %0, ptr %5, align 8, !tbaa !5
  store i64 %1, ptr %6, align 8, !tbaa !9
  store ptr %2, ptr %7, align 8, !tbaa !5
  store ptr %3, ptr %8, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr %9) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #5
  call void @llvm.lifetime.start.p0(i64 16, ptr %13) #5
  call void @llvm.lifetime.start.p0(i64 16, ptr %14) #5
  call void @llvm.lifetime.start.p0(i64 16, ptr %15) #5
  call void @llvm.lifetime.start.p0(i64 64, ptr %16) #5
  call void @llvm.lifetime.start.p0(i64 408, ptr %17) #5
  %32 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef %32, ptr noundef %9)
  call void @llvm.memset.p0.i64(ptr align 8 %16, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr align 8 %17, i8 0, i64 408, i1 false)
  %33 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef %16, i64 noundef 0, i64 noundef 3, ptr noundef %33, i1 noundef zeroext true)
  %34 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl23_fasttransformplan_initEPvPNS_8ae_stateEb(ptr noundef %17, ptr noundef %34, i1 noundef zeroext true)
  %35 = load i64, ptr %6, align 8, !tbaa !9
  %36 = icmp sgt i64 %35, 0
  %37 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %36, ptr noundef @.str.9, ptr noundef %37)
  %38 = load ptr, ptr %5, align 8, !tbaa !5
  %39 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %38, i32 0, i32 0
  %40 = load i64, ptr %39, align 8, !tbaa !11
  %41 = load i64, ptr %6, align 8, !tbaa !9
  %42 = icmp sge i64 %40, %41
  %43 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %42, ptr noundef @.str.10, ptr noundef %43)
  %44 = load ptr, ptr %5, align 8, !tbaa !5
  %45 = load i64, ptr %6, align 8, !tbaa !9
  %46 = load ptr, ptr %8, align 8, !tbaa !5
  %47 = call noundef zeroext i1 @_ZN11alglib_impl14isfinitevectorEPKNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %44, i64 noundef %45, ptr noundef %46)
  %48 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %47, ptr noundef @.str.11, ptr noundef %48)
  %49 = load i64, ptr %6, align 8, !tbaa !9
  %50 = icmp eq i64 %49, 1
  br i1 %50, label %51, label %69

51:                                               ; preds = %4
  %52 = load ptr, ptr %7, align 8, !tbaa !5
  %53 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl7callocvElPNS_9ae_vectorEPNS_8ae_stateE(i64 noundef 1, ptr noundef %52, ptr noundef %53)
  call void @llvm.lifetime.start.p0(i64 16, ptr %18) #5
  %54 = load ptr, ptr %5, align 8, !tbaa !5
  %55 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %54, i32 0, i32 4
  %56 = load ptr, ptr %55, align 8, !tbaa !15
  %57 = getelementptr inbounds double, ptr %56, i64 0
  %58 = load double, ptr %57, align 8, !tbaa !16
  %59 = call { double, double } @_ZN11alglib_impl17ae_complex_from_dEd(double noundef %58)
  %60 = getelementptr inbounds { double, double }, ptr %18, i32 0, i32 0
  %61 = extractvalue { double, double } %59, 0
  store double %61, ptr %60, align 8
  %62 = getelementptr inbounds { double, double }, ptr %18, i32 0, i32 1
  %63 = extractvalue { double, double } %59, 1
  store double %63, ptr %62, align 8
  %64 = load ptr, ptr %7, align 8, !tbaa !5
  %65 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %64, i32 0, i32 4
  %66 = load ptr, ptr %65, align 8, !tbaa !15
  %67 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %66, i64 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %67, ptr align 8 %18, i64 16, i1 false), !tbaa.struct !18
  call void @llvm.lifetime.end.p0(i64 16, ptr %18) #5
  %68 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %68)
  store i32 1, ptr %19, align 4
  br label %364

69:                                               ; preds = %4
  %70 = load i64, ptr %6, align 8, !tbaa !9
  %71 = icmp eq i64 %70, 2
  br i1 %71, label %72, label %118

72:                                               ; preds = %69
  %73 = load ptr, ptr %7, align 8, !tbaa !5
  %74 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl7callocvElPNS_9ae_vectorEPNS_8ae_stateE(i64 noundef 2, ptr noundef %73, ptr noundef %74)
  %75 = load ptr, ptr %5, align 8, !tbaa !5
  %76 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %75, i32 0, i32 4
  %77 = load ptr, ptr %76, align 8, !tbaa !15
  %78 = getelementptr inbounds double, ptr %77, i64 0
  %79 = load double, ptr %78, align 8, !tbaa !16
  %80 = load ptr, ptr %5, align 8, !tbaa !5
  %81 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %80, i32 0, i32 4
  %82 = load ptr, ptr %81, align 8, !tbaa !15
  %83 = getelementptr inbounds double, ptr %82, i64 1
  %84 = load double, ptr %83, align 8, !tbaa !16
  %85 = fadd double %79, %84
  %86 = load ptr, ptr %7, align 8, !tbaa !5
  %87 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %86, i32 0, i32 4
  %88 = load ptr, ptr %87, align 8, !tbaa !15
  %89 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %88, i64 0
  %90 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %89, i32 0, i32 0
  store double %85, ptr %90, align 8, !tbaa !19
  %91 = load ptr, ptr %7, align 8, !tbaa !5
  %92 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %91, i32 0, i32 4
  %93 = load ptr, ptr %92, align 8, !tbaa !15
  %94 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %93, i64 0
  %95 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %94, i32 0, i32 1
  store double 0.000000e+00, ptr %95, align 8, !tbaa !21
  %96 = load ptr, ptr %5, align 8, !tbaa !5
  %97 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %96, i32 0, i32 4
  %98 = load ptr, ptr %97, align 8, !tbaa !15
  %99 = getelementptr inbounds double, ptr %98, i64 0
  %100 = load double, ptr %99, align 8, !tbaa !16
  %101 = load ptr, ptr %5, align 8, !tbaa !5
  %102 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %101, i32 0, i32 4
  %103 = load ptr, ptr %102, align 8, !tbaa !15
  %104 = getelementptr inbounds double, ptr %103, i64 1
  %105 = load double, ptr %104, align 8, !tbaa !16
  %106 = fsub double %100, %105
  %107 = load ptr, ptr %7, align 8, !tbaa !5
  %108 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %107, i32 0, i32 4
  %109 = load ptr, ptr %108, align 8, !tbaa !15
  %110 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %109, i64 1
  %111 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %110, i32 0, i32 0
  store double %106, ptr %111, align 8, !tbaa !19
  %112 = load ptr, ptr %7, align 8, !tbaa !5
  %113 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %112, i32 0, i32 4
  %114 = load ptr, ptr %113, align 8, !tbaa !15
  %115 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %114, i64 1
  %116 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %115, i32 0, i32 1
  store double 0.000000e+00, ptr %116, align 8, !tbaa !21
  %117 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %117)
  store i32 1, ptr %19, align 4
  br label %364

118:                                              ; preds = %69
  %119 = load i64, ptr %6, align 8, !tbaa !9
  %120 = srem i64 %119, 2
  %121 = icmp eq i64 %120, 0
  br i1 %121, label %122, label %329

122:                                              ; preds = %118
  %123 = load i64, ptr %6, align 8, !tbaa !9
  %124 = sdiv i64 %123, 2
  store i64 %124, ptr %11, align 8, !tbaa !9
  %125 = load i64, ptr %6, align 8, !tbaa !9
  %126 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %16, i64 noundef %125, ptr noundef %126)
  %127 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %16, i32 0, i32 4
  %128 = load ptr, ptr %127, align 8, !tbaa !15
  %129 = getelementptr inbounds double, ptr %128, i64 0
  %130 = load ptr, ptr %5, align 8, !tbaa !5
  %131 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %130, 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 %6, align 8, !tbaa !9
  %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_moveEPdlPKdll(ptr noundef %129, i64 noundef 1, ptr noundef %133, i64 noundef 1, i64 noundef %136)
  %137 = load i64, ptr %11, align 8, !tbaa !9
  %138 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl16ftcomplexfftplanEllPNS_17fasttransformplanEPNS_8ae_stateE(i64 noundef %137, i64 noundef 1, ptr noundef %17, ptr noundef %138)
  %139 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl11ftapplyplanEPNS_17fasttransformplanEPNS_9ae_vectorEllPNS_8ae_stateE(ptr noundef %17, ptr noundef %16, i64 noundef 0, i64 noundef 1, ptr noundef %139)
  %140 = load i64, ptr %6, align 8, !tbaa !9
  %141 = load ptr, ptr %7, align 8, !tbaa !5
  %142 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl7callocvElPNS_9ae_vectorEPNS_8ae_stateE(i64 noundef %140, ptr noundef %141, ptr noundef %142)
  store i64 0, ptr %10, align 8, !tbaa !9
  br label %143

143:                                              ; preds = %291, %122
  %144 = load i64, ptr %10, align 8, !tbaa !9
  %145 = load i64, ptr %11, align 8, !tbaa !9
  %146 = icmp sle i64 %144, %145
  br i1 %146, label %147, label %294

147:                                              ; preds = %143
  %148 = load i64, ptr %10, align 8, !tbaa !9
  %149 = load i64, ptr %11, align 8, !tbaa !9
  %150 = srem i64 %148, %149
  %151 = mul nsw i64 2, %150
  store i64 %151, ptr %12, align 8, !tbaa !9
  %152 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %16, i32 0, i32 4
  %153 = load ptr, ptr %152, align 8, !tbaa !15
  %154 = load i64, ptr %12, align 8, !tbaa !9
  %155 = add nsw i64 %154, 0
  %156 = getelementptr inbounds double, ptr %153, i64 %155
  %157 = load double, ptr %156, align 8, !tbaa !16
  %158 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %13, i32 0, i32 0
  store double %157, ptr %158, align 8, !tbaa !19
  %159 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %16, i32 0, i32 4
  %160 = load ptr, ptr %159, align 8, !tbaa !15
  %161 = load i64, ptr %12, align 8, !tbaa !9
  %162 = add nsw i64 %161, 1
  %163 = getelementptr inbounds double, ptr %160, i64 %162
  %164 = load double, ptr %163, align 8, !tbaa !16
  %165 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %13, i32 0, i32 1
  store double %164, ptr %165, align 8, !tbaa !21
  %166 = load i64, ptr %11, align 8, !tbaa !9
  %167 = load i64, ptr %10, align 8, !tbaa !9
  %168 = sub nsw i64 %166, %167
  %169 = load i64, ptr %11, align 8, !tbaa !9
  %170 = srem i64 %168, %169
  %171 = mul nsw i64 2, %170
  store i64 %171, ptr %12, align 8, !tbaa !9
  %172 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %16, i32 0, i32 4
  %173 = load ptr, ptr %172, align 8, !tbaa !15
  %174 = load i64, ptr %12, align 8, !tbaa !9
  %175 = add nsw i64 %174, 0
  %176 = getelementptr inbounds double, ptr %173, i64 %175
  %177 = load double, ptr %176, align 8, !tbaa !16
  %178 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %14, i32 0, i32 0
  store double %177, ptr %178, align 8, !tbaa !19
  %179 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %16, i32 0, i32 4
  %180 = load ptr, ptr %179, align 8, !tbaa !15
  %181 = load i64, ptr %12, align 8, !tbaa !9
  %182 = add nsw i64 %181, 1
  %183 = getelementptr inbounds double, ptr %180, i64 %182
  %184 = load double, ptr %183, align 8, !tbaa !16
  %185 = fneg double %184
  %186 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %14, i32 0, i32 1
  store double %185, ptr %186, align 8, !tbaa !21
  %187 = load i64, ptr %10, align 8, !tbaa !9
  %188 = sitofp i64 %187 to double
  %189 = fmul double 0xC01921FB54442D18, %188
  %190 = load i64, ptr %6, align 8, !tbaa !9
  %191 = sitofp i64 %190 to double
  %192 = fdiv double %189, %191
  %193 = load ptr, ptr %8, align 8, !tbaa !5
  %194 = call noundef double @_ZN11alglib_impl6ae_sinEdPNS_8ae_stateE(double noundef %192, ptr noundef %193)
  %195 = fneg double %194
  %196 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %15, i32 0, i32 0
  store double %195, ptr %196, align 8, !tbaa !19
  %197 = load i64, ptr %10, align 8, !tbaa !9
  %198 = sitofp i64 %197 to double
  %199 = fmul double 0xC01921FB54442D18, %198
  %200 = load i64, ptr %6, align 8, !tbaa !9
  %201 = sitofp i64 %200 to double
  %202 = fdiv double %199, %201
  %203 = load ptr, ptr %8, align 8, !tbaa !5
  %204 = call noundef double @_ZN11alglib_impl6ae_cosEdPNS_8ae_stateE(double noundef %202, ptr noundef %203)
  %205 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %15, i32 0, i32 1
  store double %204, ptr %205, align 8, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 16, ptr %20) #5
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %22, ptr align 8 %13, i64 16, i1 false), !tbaa.struct !18
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %23, ptr align 8 %14, i64 16, i1 false), !tbaa.struct !18
  %206 = getelementptr inbounds { double, double }, ptr %22, i32 0, i32 0
  %207 = load double, ptr %206, align 8
  %208 = getelementptr inbounds { double, double }, ptr %22, i32 0, i32 1
  %209 = load double, ptr %208, align 8
  %210 = getelementptr inbounds { double, double }, ptr %23, i32 0, i32 0
  %211 = load double, ptr %210, align 8
  %212 = getelementptr inbounds { double, double }, ptr %23, i32 0, i32 1
  %213 = load double, ptr %212, align 8
  %214 = call { double, double } @_ZN11alglib_impl8ae_c_addENS_10ae_complexES0_(double %207, double %209, double %211, double %213)
  %215 = getelementptr inbounds { double, double }, ptr %21, i32 0, i32 0
  %216 = extractvalue { double, double } %214, 0
  store double %216, ptr %215, align 8
  %217 = getelementptr inbounds { double, double }, ptr %21, i32 0, i32 1
  %218 = extractvalue { double, double } %214, 1
  store double %218, ptr %217, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %25, ptr align 8 %15, i64 16, i1 false), !tbaa.struct !18
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %27, ptr align 8 %13, i64 16, i1 false), !tbaa.struct !18
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %28, ptr align 8 %14, i64 16, i1 false), !tbaa.struct !18
  %219 = getelementptr inbounds { double, double }, ptr %27, i32 0, i32 0
  %220 = load double, ptr %219, align 8
  %221 = getelementptr inbounds { double, double }, ptr %27, i32 0, i32 1
  %222 = load double, ptr %221, align 8
  %223 = getelementptr inbounds { double, double }, ptr %28, i32 0, i32 0
  %224 = load double, ptr %223, align 8
  %225 = getelementptr inbounds { double, double }, ptr %28, i32 0, i32 1
  %226 = load double, ptr %225, align 8
  %227 = call { double, double } @_ZN11alglib_impl8ae_c_subENS_10ae_complexES0_(double %220, double %222, double %224, double %226)
  %228 = getelementptr inbounds { double, double }, ptr %26, i32 0, i32 0
  %229 = extractvalue { double, double } %227, 0
  store double %229, ptr %228, align 8
  %230 = getelementptr inbounds { double, double }, ptr %26, i32 0, i32 1
  %231 = extractvalue { double, double } %227, 1
  store double %231, ptr %230, align 8
  %232 = getelementptr inbounds { double, double }, ptr %25, i32 0, i32 0
  %233 = load double, ptr %232, align 8
  %234 = getelementptr inbounds { double, double }, ptr %25, i32 0, i32 1
  %235 = load double, ptr %234, align 8
  %236 = getelementptr inbounds { double, double }, ptr %26, i32 0, i32 0
  %237 = load double, ptr %236, align 8
  %238 = getelementptr inbounds { double, double }, ptr %26, i32 0, i32 1
  %239 = load double, ptr %238, align 8
  %240 = call { double, double } @_ZN11alglib_impl8ae_c_mulENS_10ae_complexES0_(double %233, double %235, double %237, double %239)
  %241 = getelementptr inbounds { double, double }, ptr %24, i32 0, i32 0
  %242 = extractvalue { double, double } %240, 0
  store double %242, ptr %241, align 8
  %243 = getelementptr inbounds { double, double }, ptr %24, i32 0, i32 1
  %244 = extractvalue { double, double } %240, 1
  store double %244, ptr %243, align 8
  %245 = getelementptr inbounds { double, double }, ptr %21, i32 0, i32 0
  %246 = load double, ptr %245, align 8
  %247 = getelementptr inbounds { double, double }, ptr %21, i32 0, i32 1
  %248 = load double, ptr %247, align 8
  %249 = getelementptr inbounds { double, double }, ptr %24, i32 0, i32 0
  %250 = load double, ptr %249, align 8
  %251 = getelementptr inbounds { double, double }, ptr %24, i32 0, i32 1
  %252 = load double, ptr %251, align 8
  %253 = call { double, double } @_ZN11alglib_impl8ae_c_subENS_10ae_complexES0_(double %246, double %248, double %250, double %252)
  %254 = getelementptr inbounds { double, double }, ptr %20, i32 0, i32 0
  %255 = extractvalue { double, double } %253, 0
  store double %255, ptr %254, align 8
  %256 = getelementptr inbounds { double, double }, ptr %20, i32 0, i32 1
  %257 = extractvalue { double, double } %253, 1
  store double %257, ptr %256, align 8
  %258 = load ptr, ptr %7, align 8, !tbaa !5
  %259 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %258, i32 0, i32 4
  %260 = load ptr, ptr %259, align 8, !tbaa !15
  %261 = load i64, ptr %10, align 8, !tbaa !9
  %262 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %260, i64 %261
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %262, ptr align 8 %20, i64 16, i1 false), !tbaa.struct !18
  call void @llvm.lifetime.end.p0(i64 16, ptr %20) #5
  %263 = load ptr, ptr %7, align 8, !tbaa !5
  %264 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %263, i32 0, i32 4
  %265 = load ptr, ptr %264, align 8, !tbaa !15
  %266 = load i64, ptr %10, align 8, !tbaa !9
  %267 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %265, i64 %266
  %268 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %267, i32 0, i32 0
  %269 = load double, ptr %268, align 8, !tbaa !19
  %270 = fmul double 5.000000e-01, %269
  %271 = load ptr, ptr %7, align 8, !tbaa !5
  %272 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %271, i32 0, i32 4
  %273 = load ptr, ptr %272, align 8, !tbaa !15
  %274 = load i64, ptr %10, align 8, !tbaa !9
  %275 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %273, i64 %274
  %276 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %275, i32 0, i32 0
  store double %270, ptr %276, align 8, !tbaa !19
  %277 = load ptr, ptr %7, align 8, !tbaa !5
  %278 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %277, i32 0, i32 4
  %279 = load ptr, ptr %278, align 8, !tbaa !15
  %280 = load i64, ptr %10, align 8, !tbaa !9
  %281 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %279, i64 %280
  %282 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %281, i32 0, i32 1
  %283 = load double, ptr %282, align 8, !tbaa !21
  %284 = fmul double 5.000000e-01, %283
  %285 = load ptr, ptr %7, align 8, !tbaa !5
  %286 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %285, i32 0, i32 4
  %287 = load ptr, ptr %286, align 8, !tbaa !15
  %288 = load i64, ptr %10, align 8, !tbaa !9
  %289 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %287, i64 %288
  %290 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %289, i32 0, i32 1
  store double %284, ptr %290, align 8, !tbaa !21
  br label %291

291:                                              ; preds = %147
  %292 = load i64, ptr %10, align 8, !tbaa !9
  %293 = add nsw i64 %292, 1
  store i64 %293, ptr %10, align 8, !tbaa !9
  br label %143, !llvm.loop !22

294:                                              ; preds = %143
  %295 = load i64, ptr %11, align 8, !tbaa !9
  %296 = add nsw i64 %295, 1
  store i64 %296, ptr %10, align 8, !tbaa !9
  br label %297

297:                                              ; preds = %325, %294
  %298 = load i64, ptr %10, align 8, !tbaa !9
  %299 = load i64, ptr %6, align 8, !tbaa !9
  %300 = sub nsw i64 %299, 1
  %301 = icmp sle i64 %298, %300
  br i1 %301, label %302, label %328

302:                                              ; preds = %297
  call void @llvm.lifetime.start.p0(i64 16, ptr %29) #5
  %303 = load ptr, ptr %7, align 8, !tbaa !5
  %304 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %303, i32 0, i32 4
  %305 = load ptr, ptr %304, align 8, !tbaa !15
  %306 = load i64, ptr %6, align 8, !tbaa !9
  %307 = load i64, ptr %10, align 8, !tbaa !9
  %308 = sub nsw i64 %306, %307
  %309 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %305, i64 %308
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %30, ptr align 8 %309, i64 16, i1 false), !tbaa.struct !18
  %310 = load ptr, ptr %8, align 8, !tbaa !5
  %311 = getelementptr inbounds { double, double }, ptr %30, i32 0, i32 0
  %312 = load double, ptr %311, align 8
  %313 = getelementptr inbounds { double, double }, ptr %30, i32 0, i32 1
  %314 = load double, ptr %313, align 8
  %315 = call { double, double } @_ZN11alglib_impl9ae_c_conjENS_10ae_complexEPNS_8ae_stateE(double %312, double %314, ptr noundef %310)
  %316 = getelementptr inbounds { double, double }, ptr %29, i32 0, i32 0
  %317 = extractvalue { double, double } %315, 0
  store double %317, ptr %316, align 8
  %318 = getelementptr inbounds { double, double }, ptr %29, i32 0, i32 1
  %319 = extractvalue { double, double } %315, 1
  store double %319, ptr %318, align 8
  %320 = load ptr, ptr %7, align 8, !tbaa !5
  %321 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %320, i32 0, i32 4
  %322 = load ptr, ptr %321, align 8, !tbaa !15
  %323 = load i64, ptr %10, align 8, !tbaa !9
  %324 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %322, i64 %323
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %324, ptr align 8 %29, i64 16, i1 false), !tbaa.struct !18
  call void @llvm.lifetime.end.p0(i64 16, ptr %29) #5
  br label %325

325:                                              ; preds = %302
  %326 = load i64, ptr %10, align 8, !tbaa !9
  %327 = add nsw i64 %326, 1
  store i64 %327, ptr %10, align 8, !tbaa !9
  br label %297, !llvm.loop !24

328:                                              ; preds = %297
  br label %362

329:                                              ; preds = %118
  %330 = load i64, ptr %6, align 8, !tbaa !9
  %331 = load ptr, ptr %7, align 8, !tbaa !5
  %332 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl7callocvElPNS_9ae_vectorEPNS_8ae_stateE(i64 noundef %330, ptr noundef %331, ptr noundef %332)
  store i64 0, ptr %10, align 8, !tbaa !9
  br label %333

333:                                              ; preds = %355, %329
  %334 = load i64, ptr %10, align 8, !tbaa !9
  %335 = load i64, ptr %6, align 8, !tbaa !9
  %336 = sub nsw i64 %335, 1
  %337 = icmp sle i64 %334, %336
  br i1 %337, label %338, label %358

338:                                              ; preds = %333
  call void @llvm.lifetime.start.p0(i64 16, ptr %31) #5
  %339 = load ptr, ptr %5, align 8, !tbaa !5
  %340 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %339, i32 0, i32 4
  %341 = load ptr, ptr %340, align 8, !tbaa !15
  %342 = load i64, ptr %10, align 8, !tbaa !9
  %343 = getelementptr inbounds double, ptr %341, i64 %342
  %344 = load double, ptr %343, align 8, !tbaa !16
  %345 = call { double, double } @_ZN11alglib_impl17ae_complex_from_dEd(double noundef %344)
  %346 = getelementptr inbounds { double, double }, ptr %31, i32 0, i32 0
  %347 = extractvalue { double, double } %345, 0
  store double %347, ptr %346, align 8
  %348 = getelementptr inbounds { double, double }, ptr %31, i32 0, i32 1
  %349 = extractvalue { double, double } %345, 1
  store double %349, ptr %348, align 8
  %350 = load ptr, ptr %7, align 8, !tbaa !5
  %351 = getelementptr inbounds %"struct.alglib_impl::ae_vector", ptr %350, i32 0, i32 4
  %352 = load ptr, ptr %351, align 8, !tbaa !15
  %353 = load i64, ptr %10, align 8, !tbaa !9
  %354 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %352, i64 %353
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %354, ptr align 8 %31, i64 16, i1 false), !tbaa.struct !18
  call void @llvm.lifetime.end.p0(i64 16, ptr %31) #5
  br label %355

355:                                              ; preds = %338
  %356 = load i64, ptr %10, align 8, !tbaa !9
  %357 = add nsw i64 %356, 1
  store i64 %357, ptr %10, align 8, !tbaa !9
  br label %333, !llvm.loop !25

358:                                              ; preds = %333
  %359 = load ptr, ptr %7, align 8, !tbaa !5
  %360 = load i64, ptr %6, align 8, !tbaa !9
  %361 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl6fftc1dEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %359, i64 noundef %360, ptr noundef %361)
  br label %362

362:                                              ; preds = %358, %328
  %363 = load ptr, ptr %8, align 8, !tbaa !5
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %363)
  store i32 0, ptr %19, align 4
  br label %364

364:                                              ; preds = %362, %72, %51
  call void @llvm.lifetime.end.p0(i64 408, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 64, ptr %16) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr %14) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr %13) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr %9) #5
  %365 = load i32, ptr %19, align 4
  switch i32 %365, label %367 [
    i32 0, label %366
    i32 1, label %366
  ]

366:                                              ; preds = %364, %364
  ret void

367:                                              ; preds = %364
  unreachable
}

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

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

declare void @_ZN11alglib_impl23_fasttransformplan_initEPvPNS_8ae_stateEb(ptr noundef, ptr noundef, i1 noundef zeroext) #2

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

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

declare void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef) #2

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

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

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

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

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

declare { double, double } @_ZN11alglib_impl17ae_complex_from_dEd(double noundef) #2

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #4

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

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

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

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

declare { double, double } @_ZN11alglib_impl8ae_c_subENS_10ae_complexES0_(double, double, double, double) #2

declare { double, double } @_ZN11alglib_impl8ae_c_addENS_10ae_complexES0_(double, double, double, double) #2

declare { double, double } @_ZN11alglib_impl8ae_c_mulENS_10ae_complexES0_(double, double, double, double) #2

declare { double, double } @_ZN11alglib_impl9ae_c_conjENS_10ae_complexEPNS_8ae_stateE(double, double, ptr noundef) #2

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { "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 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #4 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
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 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = !{!12, !10, i64 0}
!12 = !{!"_ZTSN11alglib_impl9ae_vectorE", !10, i64 0, !10, i64 8, !13, i64 16, !14, i64 24, !7, i64 56}
!13 = !{!"bool", !7, i64 0}
!14 = !{!"_ZTSN11alglib_impl12ae_dyn_blockE", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24}
!15 = !{!7, !7, i64 0}
!16 = !{!17, !17, i64 0}
!17 = !{!"double", !7, i64 0}
!18 = !{i64 0, i64 8, !16, i64 8, i64 8, !16}
!19 = !{!20, !17, i64 0}
!20 = !{!"_ZTSN11alglib_impl10ae_complexE", !17, i64 0, !17, i64 8}
!21 = !{!20, !17, i64 8}
!22 = distinct !{!22, !23}
!23 = !{!"llvm.loop.mustprogress"}
!24 = distinct !{!24, !23}
!25 = distinct !{!25, !23}


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

%"struct.alglib_impl::ae_frame" = type { %"struct.alglib_impl::ae_dyn_block" }
%"struct.alglib_impl::ae_dyn_block" = type { ptr, ptr, ptr, ptr }
%"struct.alglib_impl::ae_vector" = type { i64, i64, i8, %"struct.alglib_impl::ae_dyn_block", %union.anon.0 }
%union.anon.0 = type { ptr }
%"struct.alglib_impl::fasttransformplan" = type { %"struct.alglib_impl::ae_matrix", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_vector", %"struct.alglib_impl::ae_shared_pool" }
%"struct.alglib_impl::ae_matrix" = type { i64, i64, i64, i64, i8, %"struct.alglib_impl::ae_dyn_block", %union.anon.1 }
%union.anon.1 = type { ptr }
%"struct.alglib_impl::ae_shared_pool" = type { %"struct.alglib_impl::ae_lock", ptr, ptr, ptr, ptr, i64, ptr, ptr, %"struct.alglib_impl::ae_dyn_block" }
%"struct.alglib_impl::ae_lock" = type { ptr, %"struct.alglib_impl::ae_dyn_block", i8 }
%"struct.alglib_impl::ae_complex" = type { double, double }

@.str.9 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [46 x i8], align 1

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN11alglib_impl6fftc1dEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef, i64 noundef, 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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN11alglib_impl9fftr1dbufEPKNS_9ae_vectorElPS0_PNS_8ae_stateE(ptr noundef %0, i64 noundef %1, ptr noundef %2, ptr noundef %3) local_unnamed_addr #1 {
  %5 = alloca %"struct.alglib_impl::ae_frame", align 8
  %6 = alloca %"struct.alglib_impl::ae_vector", align 8
  %7 = alloca %"struct.alglib_impl::fasttransformplan", align 8
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %5) #4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %6) #4
  call void @llvm.lifetime.start.p0(i64 408, ptr nonnull %7) #4
  call void @_ZN11alglib_impl13ae_frame_makeEPNS_8ae_stateEPNS_8ae_frameE(ptr noundef %3, ptr noundef nonnull %5)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %6, i8 0, i64 64, i1 false)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(408) %7, i8 0, i64 408, i1 false)
  call void @_ZN11alglib_impl14ae_vector_initEPNS_9ae_vectorEllPNS_8ae_stateEb(ptr noundef nonnull %6, i64 noundef 0, i64 noundef 3, ptr noundef %3, i1 noundef zeroext true)
  call void @_ZN11alglib_impl23_fasttransformplan_initEPvPNS_8ae_stateEb(ptr noundef nonnull %7, ptr noundef %3, i1 noundef zeroext true)
  %8 = icmp sgt i64 %1, 0
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %8, ptr noundef nonnull @.str.9, ptr noundef %3)
  %9 = load i64, ptr %0, align 8, !tbaa !5
  %10 = icmp sge i64 %9, %1
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %10, ptr noundef nonnull @.str.10, ptr noundef %3)
  %11 = call noundef zeroext i1 @_ZN11alglib_impl14isfinitevectorEPKNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %0, i64 noundef %1, ptr noundef %3)
  call void @_ZN11alglib_impl9ae_assertEbPKcPNS_8ae_stateE(i1 noundef zeroext %11, ptr noundef nonnull @.str.11, ptr noundef %3)
  switch i64 %1, label %41 [
    i64 1, label %12
    i64 2, label %21
  ]

12:                                               ; preds = %4
  call void @_ZN11alglib_impl7callocvElPNS_9ae_vectorEPNS_8ae_stateE(i64 noundef 1, ptr noundef %2, ptr noundef %3)
  %13 = getelementptr inbounds i8, ptr %0, i64 56
  %14 = load ptr, ptr %13, align 8, !tbaa !13
  %15 = load double, ptr %14, align 8, !tbaa !14
  %16 = call { double, double } @_ZN11alglib_impl17ae_complex_from_dEd(double noundef %15)
  %17 = extractvalue { double, double } %16, 0
  %18 = extractvalue { double, double } %16, 1
  %19 = getelementptr inbounds i8, ptr %2, i64 56
  %20 = load ptr, ptr %19, align 8, !tbaa !13
  store double %17, ptr %20, align 8, !tbaa !14
  %.sroa.423.0..sroa_idx = getelementptr inbounds i8, ptr %20, i64 8
  store double %18, ptr %.sroa.423.0..sroa_idx, align 8, !tbaa !14
  br label %.loopexit

21:                                               ; preds = %4
  call void @_ZN11alglib_impl7callocvElPNS_9ae_vectorEPNS_8ae_stateE(i64 noundef 2, ptr noundef %2, ptr noundef %3)
  %22 = getelementptr inbounds i8, ptr %0, i64 56
  %23 = load ptr, ptr %22, align 8, !tbaa !13
  %24 = load double, ptr %23, align 8, !tbaa !14
  %25 = getelementptr inbounds i8, ptr %23, i64 8
  %26 = load double, ptr %25, align 8, !tbaa !14
  %27 = fadd double %24, %26
  %28 = getelementptr inbounds i8, ptr %2, i64 56
  %29 = load ptr, ptr %28, align 8, !tbaa !13
  store double %27, ptr %29, align 8, !tbaa !16
  %30 = load ptr, ptr %28, align 8, !tbaa !13
  %31 = getelementptr inbounds i8, ptr %30, i64 8
  store double 0.000000e+00, ptr %31, align 8, !tbaa !18
  %32 = load ptr, ptr %22, align 8, !tbaa !13
  %33 = load double, ptr %32, align 8, !tbaa !14
  %34 = getelementptr inbounds i8, ptr %32, i64 8
  %35 = load double, ptr %34, align 8, !tbaa !14
  %36 = fsub double %33, %35
  %37 = load ptr, ptr %28, align 8, !tbaa !13
  %38 = getelementptr inbounds i8, ptr %37, i64 16
  store double %36, ptr %38, align 8, !tbaa !16
  %39 = load ptr, ptr %28, align 8, !tbaa !13
  %40 = getelementptr inbounds i8, ptr %39, i64 24
  store double 0.000000e+00, ptr %40, align 8, !tbaa !18
  br label %.loopexit

41:                                               ; preds = %4
  %42 = and i64 %1, 1
  %43 = icmp eq i64 %42, 0
  br i1 %43, label %44, label %111

44:                                               ; preds = %41
  %45 = ashr exact i64 %1, 1
  call void @_ZN11alglib_impl20ae_vector_set_lengthEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef nonnull %6, i64 noundef %1, ptr noundef %3)
  %46 = getelementptr inbounds i8, ptr %6, i64 56
  %47 = load ptr, ptr %46, align 8, !tbaa !13
  %48 = getelementptr inbounds i8, ptr %0, i64 56
  %49 = load ptr, ptr %48, align 8, !tbaa !13
  %50 = add nsw i64 %1, -1
  %51 = call noundef i64 @_ZN11alglib_impl8ae_v_lenEll(i64 noundef 0, i64 noundef %50)
  call void @_ZN11alglib_impl9ae_v_moveEPdlPKdll(ptr noundef %47, i64 noundef 1, ptr noundef %49, i64 noundef 1, i64 noundef %51)
  call void @_ZN11alglib_impl16ftcomplexfftplanEllPNS_17fasttransformplanEPNS_8ae_stateE(i64 noundef %45, i64 noundef 1, ptr noundef nonnull %7, ptr noundef %3)
  call void @_ZN11alglib_impl11ftapplyplanEPNS_17fasttransformplanEPNS_9ae_vectorEllPNS_8ae_stateE(ptr noundef nonnull %7, ptr noundef nonnull %6, i64 noundef 0, i64 noundef 1, ptr noundef %3)
  call void @_ZN11alglib_impl7callocvElPNS_9ae_vectorEPNS_8ae_stateE(i64 noundef %1, ptr noundef %2, ptr noundef %3)
  %.not127 = icmp slt i64 %45, 0
  br i1 %.not127, label %.preheader, label %.lr.ph130

.lr.ph130:                                        ; preds = %44
  %52 = uitofp nneg i64 %1 to double
  %53 = getelementptr inbounds i8, ptr %2, i64 56
  br label %55

.preheader:                                       ; preds = %55, %44
  %.not124.not131 = icmp slt i64 %45, %50
  br i1 %.not124.not131, label %.lr.ph133, label %.loopexit

.lr.ph133:                                        ; preds = %.preheader
  %54 = getelementptr inbounds i8, ptr %2, i64 56
  br label %102

55:                                               ; preds = %.lr.ph130, %55
  %.0128 = phi i64 [ 0, %.lr.ph130 ], [ %101, %55 ]
  %56 = urem i64 %.0128, %45
  %57 = shl nuw nsw i64 %56, 1
  %58 = load ptr, ptr %46, align 8, !tbaa !13
  %59 = getelementptr inbounds double, ptr %58, i64 %57
  %60 = load double, ptr %59, align 8, !tbaa !14
  %61 = or disjoint i64 %57, 1
  %62 = getelementptr inbounds double, ptr %58, i64 %61
  %63 = load double, ptr %62, align 8, !tbaa !14
  %64 = sub nsw i64 %45, %.0128
  %65 = srem i64 %64, %45
  %66 = shl nsw i64 %65, 1
  %67 = getelementptr inbounds double, ptr %58, i64 %66
  %68 = load double, ptr %67, align 8, !tbaa !14
  %69 = or disjoint i64 %66, 1
  %70 = getelementptr inbounds double, ptr %58, i64 %69
  %71 = load double, ptr %70, align 8, !tbaa !14
  %72 = fneg double %71
  %73 = uitofp nneg i64 %.0128 to double
  %74 = fmul double %73, 0xC01921FB54442D18
  %75 = fdiv double %74, %52
  %76 = call noundef double @_ZN11alglib_impl6ae_sinEdPNS_8ae_stateE(double noundef %75, ptr noundef %3)
  %77 = fneg double %76
  %78 = call noundef double @_ZN11alglib_impl6ae_cosEdPNS_8ae_stateE(double noundef %75, ptr noundef %3)
  %79 = call { double, double } @_ZN11alglib_impl8ae_c_addENS_10ae_complexES0_(double %60, double %63, double %68, double %72)
  %80 = extractvalue { double, double } %79, 0
  %81 = extractvalue { double, double } %79, 1
  %82 = call { double, double } @_ZN11alglib_impl8ae_c_subENS_10ae_complexES0_(double %60, double %63, double %68, double %72)
  %83 = extractvalue { double, double } %82, 0
  %84 = extractvalue { double, double } %82, 1
  %85 = call { double, double } @_ZN11alglib_impl8ae_c_mulENS_10ae_complexES0_(double %77, double %78, double %83, double %84)
  %86 = extractvalue { double, double } %85, 0
  %87 = extractvalue { double, double } %85, 1
  %88 = call { double, double } @_ZN11alglib_impl8ae_c_subENS_10ae_complexES0_(double %80, double %81, double %86, double %87)
  %89 = extractvalue { double, double } %88, 0
  %90 = extractvalue { double, double } %88, 1
  %91 = load ptr, ptr %53, align 8, !tbaa !13
  %92 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %91, i64 %.0128
  store double %89, ptr %92, align 8, !tbaa !14
  %.sroa.421.0..sroa_idx = getelementptr inbounds i8, ptr %92, i64 8
  store double %90, ptr %.sroa.421.0..sroa_idx, align 8, !tbaa !14
  %93 = load ptr, ptr %53, align 8, !tbaa !13
  %94 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %93, i64 %.0128
  %95 = load double, ptr %94, align 8, !tbaa !16
  %96 = fmul double %95, 5.000000e-01
  store double %96, ptr %94, align 8, !tbaa !16
  %97 = load ptr, ptr %53, align 8, !tbaa !13
  %98 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %97, i64 %.0128, i32 1
  %99 = load double, ptr %98, align 8, !tbaa !18
  %100 = fmul double %99, 5.000000e-01
  store double %100, ptr %98, align 8, !tbaa !18
  %101 = add nuw nsw i64 %.0128, 1
  %exitcond135.not = icmp eq i64 %.0128, %45
  br i1 %exitcond135.not, label %.preheader, label %55, !llvm.loop !19

102:                                              ; preds = %.lr.ph133, %102
  %.1.in132 = phi i64 [ %45, %.lr.ph133 ], [ %.1, %102 ]
  %.1 = add nsw i64 %.1.in132, 1
  %103 = load ptr, ptr %54, align 8, !tbaa !13
  %104 = sub nsw i64 %1, %.1
  %105 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %103, i64 %104
  %.sroa.01.0.copyload = load double, ptr %105, align 8, !tbaa !14
  %.sroa.2.0..sroa_idx = getelementptr inbounds i8, ptr %105, i64 8
  %.sroa.2.0.copyload = load double, ptr %.sroa.2.0..sroa_idx, align 8, !tbaa !14
  %106 = call { double, double } @_ZN11alglib_impl9ae_c_conjENS_10ae_complexEPNS_8ae_stateE(double %.sroa.01.0.copyload, double %.sroa.2.0.copyload, ptr noundef %3)
  %107 = extractvalue { double, double } %106, 0
  %108 = extractvalue { double, double } %106, 1
  %109 = load ptr, ptr %54, align 8, !tbaa !13
  %110 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %109, i64 %.1
  store double %107, ptr %110, align 8, !tbaa !14
  %.sroa.43.0..sroa_idx = getelementptr inbounds i8, ptr %110, i64 8
  store double %108, ptr %.sroa.43.0..sroa_idx, align 8, !tbaa !14
  %exitcond136.not = icmp eq i64 %.1, %50
  br i1 %exitcond136.not, label %.loopexit, label %102, !llvm.loop !21

111:                                              ; preds = %41
  call void @_ZN11alglib_impl7callocvElPNS_9ae_vectorEPNS_8ae_stateE(i64 noundef %1, ptr noundef %2, ptr noundef %3)
  br i1 %8, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %111
  %112 = getelementptr inbounds i8, ptr %0, i64 56
  %113 = getelementptr inbounds i8, ptr %2, i64 56
  br label %114

114:                                              ; preds = %.lr.ph, %114
  %.2126 = phi i64 [ 0, %.lr.ph ], [ %123, %114 ]
  %115 = load ptr, ptr %112, align 8, !tbaa !13
  %116 = getelementptr inbounds double, ptr %115, i64 %.2126
  %117 = load double, ptr %116, align 8, !tbaa !14
  %118 = call { double, double } @_ZN11alglib_impl17ae_complex_from_dEd(double noundef %117)
  %119 = extractvalue { double, double } %118, 0
  %120 = extractvalue { double, double } %118, 1
  %121 = load ptr, ptr %113, align 8, !tbaa !13
  %122 = getelementptr inbounds %"struct.alglib_impl::ae_complex", ptr %121, i64 %.2126
  store double %119, ptr %122, align 8, !tbaa !14
  %.sroa.4.0..sroa_idx = getelementptr inbounds i8, ptr %122, i64 8
  store double %120, ptr %.sroa.4.0..sroa_idx, align 8, !tbaa !14
  %123 = add nuw nsw i64 %.2126, 1
  %exitcond.not = icmp eq i64 %123, %1
  br i1 %exitcond.not, label %._crit_edge, label %114, !llvm.loop !22

._crit_edge:                                      ; preds = %114, %111
  call void @_ZN11alglib_impl6fftc1dEPNS_9ae_vectorElPNS_8ae_stateE(ptr noundef %2, i64 noundef %1, ptr noundef %3)
  br label %.loopexit

.loopexit:                                        ; preds = %102, %._crit_edge, %.preheader, %21, %12
  call void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef %3)
  call void @llvm.lifetime.end.p0(i64 408, ptr nonnull %7) #4
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %6) #4
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #4
  ret void
}

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

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

declare void @_ZN11alglib_impl23_fasttransformplan_initEPvPNS_8ae_stateEb(ptr noundef, ptr noundef, i1 noundef zeroext) local_unnamed_addr #2

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

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

declare void @_ZN11alglib_impl14ae_frame_leaveEPNS_8ae_stateE(ptr noundef) local_unnamed_addr #2

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

declare void @_ZN11alglib_impl16ftcomplexfftplanEllPNS_17fasttransformplanEPNS_8ae_stateE(i64 noundef, i64 noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

declare void @_ZN11alglib_impl11ftapplyplanEPNS_17fasttransformplanEPNS_9ae_vectorEllPNS_8ae_stateE(ptr noundef, ptr noundef, i64 noundef, i64 noundef, ptr noundef) local_unnamed_addr #2

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

declare void @_ZN11alglib_impl7callocvElPNS_9ae_vectorEPNS_8ae_stateE(i64 noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

declare { double, double } @_ZN11alglib_impl17ae_complex_from_dEd(double noundef) local_unnamed_addr #2

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

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

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

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

declare { double, double } @_ZN11alglib_impl8ae_c_subENS_10ae_complexES0_(double, double, double, double) local_unnamed_addr #2

declare { double, double } @_ZN11alglib_impl8ae_c_addENS_10ae_complexES0_(double, double, double, double) local_unnamed_addr #2

declare { double, double } @_ZN11alglib_impl8ae_c_mulENS_10ae_complexES0_(double, double, double, double) local_unnamed_addr #2

declare { double, double } @_ZN11alglib_impl9ae_c_conjENS_10ae_complexEPNS_8ae_stateE(double, double, ptr noundef) local_unnamed_addr #2

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { "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 nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #4 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !7, i64 0}
!6 = !{!"_ZTSN11alglib_impl9ae_vectorE", !7, i64 0, !7, i64 8, !10, i64 16, !11, i64 24, !8, i64 56}
!7 = !{!"long", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"bool", !8, i64 0}
!11 = !{!"_ZTSN11alglib_impl12ae_dyn_blockE", !12, i64 0, !12, i64 8, !12, i64 16, !12, i64 24}
!12 = !{!"any pointer", !8, i64 0}
!13 = !{!8, !8, i64 0}
!14 = !{!15, !15, i64 0}
!15 = !{!"double", !8, i64 0}
!16 = !{!17, !15, i64 0}
!17 = !{!"_ZTSN11alglib_impl10ae_complexE", !15, i64 0, !15, i64 8}
!18 = !{!17, !15, i64 8}
!19 = distinct !{!19, !20}
!20 = !{!"llvm.loop.mustprogress"}
!21 = distinct !{!21, !20}
!22 = distinct !{!22, !20}


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