; LLVM IR from jgaeddert/liquid-dsp :: src/nco/tests (nco_crcf_spectrum_autotest)

; 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.autotest_psd_s = type { float, float, float, float, i32, i32 }

@.str = external hidden unnamed_addr constant [43 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1
@liquid_autotest_verbose = external global i32, align 4

; Function Attrs: nounwind uwtable
define dso_local void @nco_crcf_spectrum_test(i32 noundef %0, i32 noundef %1, float noundef %2) #0 {
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca float, align 4
  %7 = alloca i64, align 8
  %8 = alloca i32, align 4
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca ptr, align 8
  %12 = alloca i64, align 8
  %13 = alloca i64, align 8
  %14 = alloca i32, align 4
  %15 = alloca ptr, align 8
  %16 = alloca [3 x %struct.autotest_psd_s], align 16
  %17 = alloca [256 x i8], align 16
  store i32 %0, ptr %4, align 4, !tbaa !5
  store i32 %1, ptr %5, align 4, !tbaa !5
  store float %2, ptr %6, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #5
  store i64 65536, ptr %7, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #5
  store i32 9600, ptr %8, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #5
  %18 = load i32, ptr %5, align 4, !tbaa !5
  %19 = call ptr @nco_crcf_create(i32 noundef %18)
  store ptr %19, ptr %9, align 8, !tbaa !13
  %20 = load ptr, ptr %9, align 8, !tbaa !13
  %21 = load float, ptr %6, align 4, !tbaa !9
  %22 = fpext float %21 to double
  %23 = fmul double 0x401921FB54442D18, %22
  %24 = fptrunc double %23 to float
  %25 = call i32 @nco_crcf_set_frequency(ptr noundef %20, float noundef %24)
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #5
  %26 = load i32, ptr %8, align 4, !tbaa !5
  %27 = mul i32 3, %26
  store i32 %27, ptr %10, align 4, !tbaa !5
  %28 = load i32, ptr %10, align 4, !tbaa !5
  %29 = zext i32 %28 to i64
  %30 = call ptr @llvm.stacksave.p0()
  store ptr %30, ptr %11, align 8
  %31 = alloca { float, float }, i64 %29, align 16
  store i64 %29, ptr %12, align 8
  %32 = load i32, ptr %10, align 4, !tbaa !5
  %33 = zext i32 %32 to i64
  %34 = alloca { float, float }, i64 %33, align 16
  store i64 %33, ptr %13, align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #5
  store i32 0, ptr %14, align 4, !tbaa !5
  br label %35

35:                                               ; preds = %49, %3
  %36 = load i32, ptr %14, align 4, !tbaa !5
  %37 = load i32, ptr %10, align 4, !tbaa !5
  %38 = icmp ult i32 %36, %37
  br i1 %38, label %39, label %52

39:                                               ; preds = %35
  %40 = load i32, ptr %8, align 4, !tbaa !5
  %41 = uitofp i32 %40 to float
  %42 = call float @sqrtf(float noundef %41) #5
  %43 = fdiv float 1.000000e+00, %42
  %44 = load i32, ptr %14, align 4, !tbaa !5
  %45 = zext i32 %44 to i64
  %46 = getelementptr inbounds { float, float }, ptr %31, i64 %45
  %47 = getelementptr inbounds { float, float }, ptr %46, i32 0, i32 0
  %48 = getelementptr inbounds { float, float }, ptr %46, i32 0, i32 1
  store float %43, ptr %47, align 8
  store float 0.000000e+00, ptr %48, align 4
  br label %49

49:                                               ; preds = %39
  %50 = load i32, ptr %14, align 4, !tbaa !5
  %51 = add i32 %50, 1
  store i32 %51, ptr %14, align 4, !tbaa !5
  br label %35, !llvm.loop !15

52:                                               ; preds = %35
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #5
  %53 = load i32, ptr %8, align 4, !tbaa !5
  %54 = load i32, ptr %8, align 4, !tbaa !5
  %55 = load i32, ptr %8, align 4, !tbaa !5
  %56 = udiv i32 %55, 2
  %57 = call ptr @spgramcf_create(i32 noundef %53, i32 noundef 3, i32 noundef %54, i32 noundef %56)
  store ptr %57, ptr %15, align 8, !tbaa !13
  br label %58

58:                                               ; preds = %95, %52
  %59 = load ptr, ptr %15, align 8, !tbaa !13
  %60 = call i64 @spgramcf_get_num_samples_total(ptr noundef %59)
  %61 = load i64, ptr %7, align 8, !tbaa !11
  %62 = icmp ult i64 %60, %61
  br i1 %62, label %63, label %99

63:                                               ; preds = %58
  %64 = load ptr, ptr %9, align 8, !tbaa !13
  %65 = load i32, ptr %10, align 4, !tbaa !5
  %66 = call i32 @nco_crcf_mix_block_up(ptr noundef %64, ptr noundef %31, ptr noundef %34, i32 noundef %65)
  %67 = load ptr, ptr %15, align 8, !tbaa !13
  %68 = call i64 @spgramcf_get_num_samples_total(ptr noundef %67)
  %69 = icmp eq i64 %68, 0
  br i1 %69, label %70, label %95

70:                                               ; preds = %63
  store i32 0, ptr %14, align 4, !tbaa !5
  br label %71

71:                                               ; preds = %91, %70
  %72 = load i32, ptr %14, align 4, !tbaa !5
  %73 = load i32, ptr %10, align 4, !tbaa !5
  %74 = icmp ult i32 %72, %73
  br i1 %74, label %75, label %94

75:                                               ; preds = %71
  %76 = load i32, ptr %14, align 4, !tbaa !5
  %77 = load i32, ptr %10, align 4, !tbaa !5
  %78 = mul i32 2, %77
  %79 = call float @liquid_hann(i32 noundef %76, i32 noundef %78)
  %80 = load i32, ptr %14, align 4, !tbaa !5
  %81 = zext i32 %80 to i64
  %82 = getelementptr inbounds { float, float }, ptr %34, i64 %81
  %83 = getelementptr inbounds { float, float }, ptr %82, i32 0, i32 0
  %84 = load float, ptr %83, align 8
  %85 = getelementptr inbounds { float, float }, ptr %82, i32 0, i32 1
  %86 = load float, ptr %85, align 4
  %87 = fmul float %84, %79
  %88 = fmul float %86, %79
  %89 = getelementptr inbounds { float, float }, ptr %82, i32 0, i32 0
  %90 = getelementptr inbounds { float, float }, ptr %82, i32 0, i32 1
  store float %87, ptr %89, align 8
  store float %88, ptr %90, align 4
  br label %91

91:                                               ; preds = %75
  %92 = load i32, ptr %14, align 4, !tbaa !5
  %93 = add i32 %92, 1
  store i32 %93, ptr %14, align 4, !tbaa !5
  br label %71, !llvm.loop !17

94:                                               ; preds = %71
  br label %95

95:                                               ; preds = %94, %63
  %96 = load ptr, ptr %15, align 8, !tbaa !13
  %97 = load i32, ptr %10, align 4, !tbaa !5
  %98 = call i32 @spgramcf_write(ptr noundef %96, ptr noundef %34, i32 noundef %97)
  br label %58, !llvm.loop !18

99:                                               ; preds = %58
  call void @llvm.lifetime.start.p0(i64 72, ptr %16) #5
  %100 = getelementptr inbounds %struct.autotest_psd_s, ptr %16, i32 0, i32 0
  store float -5.000000e-01, ptr %100, align 8, !tbaa !19
  %101 = getelementptr inbounds %struct.autotest_psd_s, ptr %16, i32 0, i32 1
  %102 = load float, ptr %6, align 4, !tbaa !9
  %103 = fpext float %102 to double
  %104 = fsub double %103, 2.000000e-03
  %105 = fptrunc double %104 to float
  store float %105, ptr %101, align 4, !tbaa !21
  %106 = getelementptr inbounds %struct.autotest_psd_s, ptr %16, i32 0, i32 2
  store float 0.000000e+00, ptr %106, align 8, !tbaa !22
  %107 = getelementptr inbounds %struct.autotest_psd_s, ptr %16, i32 0, i32 3
  store float -6.000000e+01, ptr %107, align 4, !tbaa !23
  %108 = getelementptr inbounds %struct.autotest_psd_s, ptr %16, i32 0, i32 4
  store i32 0, ptr %108, align 8, !tbaa !24
  %109 = getelementptr inbounds %struct.autotest_psd_s, ptr %16, i32 0, i32 5
  store i32 1, ptr %109, align 4, !tbaa !25
  %110 = getelementptr inbounds %struct.autotest_psd_s, ptr %16, i64 1
  %111 = getelementptr inbounds %struct.autotest_psd_s, ptr %110, i32 0, i32 0
  %112 = load float, ptr %6, align 4, !tbaa !9
  %113 = fpext float %112 to double
  %114 = fsub double %113, 2.000000e-03
  %115 = fptrunc double %114 to float
  store float %115, ptr %111, align 8, !tbaa !19
  %116 = getelementptr inbounds %struct.autotest_psd_s, ptr %110, i32 0, i32 1
  %117 = load float, ptr %6, align 4, !tbaa !9
  %118 = fpext float %117 to double
  %119 = fadd double %118, 2.000000e-03
  %120 = fptrunc double %119 to float
  store float %120, ptr %116, align 4, !tbaa !21
  %121 = getelementptr inbounds %struct.autotest_psd_s, ptr %110, i32 0, i32 2
  store float 0.000000e+00, ptr %121, align 8, !tbaa !22
  %122 = getelementptr inbounds %struct.autotest_psd_s, ptr %110, i32 0, i32 3
  store float 0.000000e+00, ptr %122, align 4, !tbaa !23
  %123 = getelementptr inbounds %struct.autotest_psd_s, ptr %110, i32 0, i32 4
  store i32 0, ptr %123, align 8, !tbaa !24
  %124 = getelementptr inbounds %struct.autotest_psd_s, ptr %110, i32 0, i32 5
  store i32 1, ptr %124, align 4, !tbaa !25
  %125 = getelementptr inbounds %struct.autotest_psd_s, ptr %16, i64 2
  %126 = getelementptr inbounds %struct.autotest_psd_s, ptr %125, i32 0, i32 0
  %127 = load float, ptr %6, align 4, !tbaa !9
  %128 = fpext float %127 to double
  %129 = fadd double %128, 2.000000e-03
  %130 = fptrunc double %129 to float
  store float %130, ptr %126, align 8, !tbaa !19
  %131 = getelementptr inbounds %struct.autotest_psd_s, ptr %125, i32 0, i32 1
  store float 5.000000e-01, ptr %131, align 4, !tbaa !21
  %132 = getelementptr inbounds %struct.autotest_psd_s, ptr %125, i32 0, i32 2
  store float 0.000000e+00, ptr %132, align 8, !tbaa !22
  %133 = getelementptr inbounds %struct.autotest_psd_s, ptr %125, i32 0, i32 3
  store float -6.000000e+01, ptr %133, align 4, !tbaa !23
  %134 = getelementptr inbounds %struct.autotest_psd_s, ptr %125, i32 0, i32 4
  store i32 0, ptr %134, align 8, !tbaa !24
  %135 = getelementptr inbounds %struct.autotest_psd_s, ptr %125, i32 0, i32 5
  store i32 1, ptr %135, align 4, !tbaa !25
  call void @llvm.lifetime.start.p0(i64 256, ptr %17) #5
  %136 = getelementptr inbounds [256 x i8], ptr %17, i64 0, i64 0
  %137 = load i32, ptr %5, align 4, !tbaa !5
  %138 = icmp eq i32 %137, 0
  %139 = zext i1 %138 to i64
  %140 = select i1 %138, ptr @.str.1, ptr @.str.2
  %141 = load i32, ptr %4, align 4, !tbaa !5
  %142 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %136, ptr noundef @.str, ptr noundef %140, i32 noundef %141) #5
  %143 = load ptr, ptr %15, align 8, !tbaa !13
  %144 = getelementptr inbounds [3 x %struct.autotest_psd_s], ptr %16, i64 0, i64 0
  %145 = load i32, ptr @liquid_autotest_verbose, align 4, !tbaa !5
  %146 = icmp ne i32 %145, 0
  br i1 %146, label %147, label %149

147:                                              ; preds = %99
  %148 = getelementptr inbounds [256 x i8], ptr %17, i64 0, i64 0
  br label %150

149:                                              ; preds = %99
  br label %150

150:                                              ; preds = %149, %147
  %151 = phi ptr [ %148, %147 ], [ null, %149 ]
  %152 = call i32 @liquid_autotest_validate_psd_spgramcf(ptr noundef %143, ptr noundef %144, i32 noundef 3, ptr noundef %151)
  %153 = load ptr, ptr %9, align 8, !tbaa !13
  %154 = call i32 @nco_crcf_destroy(ptr noundef %153)
  %155 = load ptr, ptr %15, align 8, !tbaa !13
  %156 = call i32 @spgramcf_destroy(ptr noundef %155)
  call void @llvm.lifetime.end.p0(i64 256, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 72, ptr %16) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  %157 = load ptr, ptr %11, align 8
  call void @llvm.stackrestore.p0(ptr %157)
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  ret void
}

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

declare ptr @nco_crcf_create(i32 noundef) #2

declare i32 @nco_crcf_set_frequency(ptr noundef, float noundef) #2

; Function Attrs: nocallback nofree nosync nounwind willreturn
declare ptr @llvm.stacksave.p0() #3

; Function Attrs: nounwind
declare float @sqrtf(float noundef) #4

declare ptr @spgramcf_create(i32 noundef, i32 noundef, i32 noundef, i32 noundef) #2

declare i64 @spgramcf_get_num_samples_total(ptr noundef) #2

declare i32 @nco_crcf_mix_block_up(ptr noundef, ptr noundef, ptr noundef, i32 noundef) #2

declare float @liquid_hann(i32 noundef, i32 noundef) #2

declare i32 @spgramcf_write(ptr noundef, ptr noundef, i32 noundef) #2

; Function Attrs: nounwind
declare i32 @sprintf(ptr noundef, ptr noundef, ...) #4

declare i32 @liquid_autotest_validate_psd_spgramcf(ptr noundef, ptr noundef, i32 noundef, ptr noundef) #2

declare i32 @nco_crcf_destroy(ptr noundef) #2

declare i32 @spgramcf_destroy(ptr noundef) #2

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

; Function Attrs: nocallback nofree nosync nounwind willreturn
declare void @llvm.stackrestore.p0(ptr) #3

attributes #0 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 nosync nounwind willreturn }
attributes #4 = { 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 #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 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"float", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"long", !7, i64 0}
!13 = !{!14, !14, i64 0}
!14 = !{!"any pointer", !7, i64 0}
!15 = distinct !{!15, !16}
!16 = !{!"llvm.loop.mustprogress"}
!17 = distinct !{!17, !16}
!18 = distinct !{!18, !16}
!19 = !{!20, !10, i64 0}
!20 = !{!"", !10, i64 0, !10, i64 4, !10, i64 8, !10, i64 12, !6, i64 16, !6, i64 20}
!21 = !{!20, !10, i64 4}
!22 = !{!20, !10, i64 8}
!23 = !{!20, !10, i64 12}
!24 = !{!20, !6, i64 16}
!25 = !{!20, !6, i64 20}


; 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.autotest_psd_s = type { float, float, float, float, i32, i32 }

@.str = external hidden unnamed_addr constant [43 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [4 x i8], align 1
@liquid_autotest_verbose = external local_unnamed_addr global i32, align 4

; Function Attrs: nounwind uwtable
define dso_local void @nco_crcf_spectrum_test(i32 noundef %0, i32 noundef %1, float noundef %2) local_unnamed_addr #0 {
vector.ph:
  %3 = alloca [3 x %struct.autotest_psd_s], align 16
  %4 = alloca [256 x i8], align 16
  %5 = tail call ptr @nco_crcf_create(i32 noundef %1) #4
  %6 = fpext float %2 to double
  %7 = fmul double %6, 0x401921FB54442D18
  %8 = fptrunc double %7 to float
  %9 = tail call i32 @nco_crcf_set_frequency(ptr noundef %5, float noundef %8) #4
  %10 = alloca [28800 x { float, float }], align 16
  %11 = alloca [28800 x { float, float }], align 16
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next.3, %vector.body ]
  %12 = or disjoint i64 %index, 2
  %13 = getelementptr inbounds { float, float }, ptr %10, i64 %index
  %14 = getelementptr inbounds { float, float }, ptr %10, i64 %12
  store <4 x float> <float 0x3F84E6FDE0000000, float 0.000000e+00, float 0x3F84E6FDE0000000, float 0.000000e+00>, ptr %13, align 16
  store <4 x float> <float 0x3F84E6FDE0000000, float 0.000000e+00, float 0x3F84E6FDE0000000, float 0.000000e+00>, ptr %14, align 16
  %index.next = or disjoint i64 %index, 4
  %15 = or disjoint i64 %index, 6
  %16 = getelementptr inbounds { float, float }, ptr %10, i64 %index.next
  %17 = getelementptr inbounds { float, float }, ptr %10, i64 %15
  store <4 x float> <float 0x3F84E6FDE0000000, float 0.000000e+00, float 0x3F84E6FDE0000000, float 0.000000e+00>, ptr %16, align 16
  store <4 x float> <float 0x3F84E6FDE0000000, float 0.000000e+00, float 0x3F84E6FDE0000000, float 0.000000e+00>, ptr %17, align 16
  %index.next.1 = or disjoint i64 %index, 8
  %18 = or disjoint i64 %index, 10
  %19 = getelementptr inbounds { float, float }, ptr %10, i64 %index.next.1
  %20 = getelementptr inbounds { float, float }, ptr %10, i64 %18
  store <4 x float> <float 0x3F84E6FDE0000000, float 0.000000e+00, float 0x3F84E6FDE0000000, float 0.000000e+00>, ptr %19, align 16
  store <4 x float> <float 0x3F84E6FDE0000000, float 0.000000e+00, float 0x3F84E6FDE0000000, float 0.000000e+00>, ptr %20, align 16
  %index.next.2 = or disjoint i64 %index, 12
  %21 = or disjoint i64 %index, 14
  %22 = getelementptr inbounds { float, float }, ptr %10, i64 %index.next.2
  %23 = getelementptr inbounds { float, float }, ptr %10, i64 %21
  store <4 x float> <float 0x3F84E6FDE0000000, float 0.000000e+00, float 0x3F84E6FDE0000000, float 0.000000e+00>, ptr %22, align 16
  store <4 x float> <float 0x3F84E6FDE0000000, float 0.000000e+00, float 0x3F84E6FDE0000000, float 0.000000e+00>, ptr %23, align 16
  %index.next.3 = add nuw nsw i64 %index, 16
  %24 = icmp eq i64 %index.next.3, 28800
  br i1 %24, label %middle.block, label %vector.body, !llvm.loop !5

middle.block:                                     ; preds = %vector.body
  %25 = tail call ptr @spgramcf_create(i32 noundef 9600, i32 noundef 3, i32 noundef 9600, i32 noundef 4800) #4
  %26 = tail call i64 @spgramcf_get_num_samples_total(ptr noundef %25) #4
  %27 = icmp ult i64 %26, 65536
  br i1 %27, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %middle.block, %.loopexit
  %28 = call i32 @nco_crcf_mix_block_up(ptr noundef %5, ptr noundef nonnull %10, ptr noundef nonnull %11, i32 noundef 28800) #4
  %29 = call i64 @spgramcf_get_num_samples_total(ptr noundef %25) #4
  %30 = icmp eq i64 %29, 0
  br i1 %30, label %.preheader, label %.loopexit

.preheader:                                       ; preds = %.lr.ph, %.preheader
  %indvars.iv39 = phi i64 [ %indvars.iv.next40, %.preheader ], [ 0, %.lr.ph ]
  %31 = trunc nuw nsw i64 %indvars.iv39 to i32
  %32 = call float @liquid_hann(i32 noundef %31, i32 noundef 57600) #4
  %33 = getelementptr inbounds { float, float }, ptr %11, i64 %indvars.iv39
  %34 = load <2 x float>, ptr %33, align 8
  %35 = insertelement <2 x float> poison, float %32, i64 0
  %36 = shufflevector <2 x float> %35, <2 x float> poison, <2 x i32> zeroinitializer
  %37 = fmul <2 x float> %36, %34
  store <2 x float> %37, ptr %33, align 8
  %indvars.iv.next40 = add nuw nsw i64 %indvars.iv39, 1
  %exitcond42.not = icmp eq i64 %indvars.iv.next40, 28800
  br i1 %exitcond42.not, label %.loopexit, label %.preheader, !llvm.loop !9

.loopexit:                                        ; preds = %.preheader, %.lr.ph
  %38 = call i32 @spgramcf_write(ptr noundef %25, ptr noundef nonnull %11, i32 noundef 28800) #4
  %39 = call i64 @spgramcf_get_num_samples_total(ptr noundef %25) #4
  %40 = icmp ult i64 %39, 65536
  br i1 %40, label %.lr.ph, label %._crit_edge, !llvm.loop !10

._crit_edge:                                      ; preds = %.loopexit, %middle.block
  call void @llvm.lifetime.start.p0(i64 72, ptr nonnull %3) #4
  store float -5.000000e-01, ptr %3, align 16, !tbaa !11
  %41 = getelementptr inbounds i8, ptr %3, i64 4
  %42 = insertelement <2 x double> poison, double %6, i64 0
  %43 = shufflevector <2 x double> %42, <2 x double> poison, <2 x i32> zeroinitializer
  %44 = fadd <2 x double> %43, <double -2.000000e-03, double 2.000000e-03>
  %45 = getelementptr inbounds i8, ptr %3, i64 8
  store <2 x float> <float 0.000000e+00, float -6.000000e+01>, ptr %45, align 8, !tbaa !17
  %46 = getelementptr inbounds i8, ptr %3, i64 16
  store i32 0, ptr %46, align 16, !tbaa !18
  %47 = getelementptr inbounds i8, ptr %3, i64 20
  store i32 1, ptr %47, align 4, !tbaa !19
  %48 = getelementptr inbounds i8, ptr %3, i64 24
  %49 = fptrunc <2 x double> %44 to <2 x float>
  %50 = extractelement <2 x float> %49, i64 0
  store float %50, ptr %41, align 4, !tbaa !20
  store <2 x float> %49, ptr %48, align 8, !tbaa !17
  %51 = getelementptr inbounds i8, ptr %3, i64 32
  store <2 x float> zeroinitializer, ptr %51, align 16, !tbaa !17
  %52 = getelementptr inbounds i8, ptr %3, i64 40
  store i32 0, ptr %52, align 8, !tbaa !18
  %53 = getelementptr inbounds i8, ptr %3, i64 44
  store i32 1, ptr %53, align 4, !tbaa !19
  %54 = getelementptr inbounds i8, ptr %3, i64 48
  %55 = extractelement <2 x float> %49, i64 1
  store float %55, ptr %54, align 16, !tbaa !11
  %56 = getelementptr inbounds i8, ptr %3, i64 52
  store <2 x float> <float 5.000000e-01, float 0.000000e+00>, ptr %56, align 4, !tbaa !17
  %57 = getelementptr inbounds i8, ptr %3, i64 60
  store float -6.000000e+01, ptr %57, align 4, !tbaa !21
  %58 = getelementptr inbounds i8, ptr %3, i64 64
  store i32 0, ptr %58, align 16, !tbaa !18
  %59 = getelementptr inbounds i8, ptr %3, i64 68
  store i32 1, ptr %59, align 4, !tbaa !19
  call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %4) #4
  %60 = icmp eq i32 %1, 0
  %61 = select i1 %60, ptr @.str.1, ptr @.str.2
  %62 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef nonnull dereferenceable(1) %4, ptr noundef nonnull dereferenceable(1) @.str, ptr noundef nonnull %61, i32 noundef %0) #4
  %63 = load i32, ptr @liquid_autotest_verbose, align 4, !tbaa !22
  %.not = icmp eq i32 %63, 0
  %64 = select i1 %.not, ptr null, ptr %4
  %65 = call i32 @liquid_autotest_validate_psd_spgramcf(ptr noundef %25, ptr noundef nonnull %3, i32 noundef 3, ptr noundef %64) #4
  %66 = call i32 @nco_crcf_destroy(ptr noundef %5) #4
  %67 = call i32 @spgramcf_destroy(ptr noundef %25) #4
  call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %4) #4
  call void @llvm.lifetime.end.p0(i64 72, ptr nonnull %3) #4
  ret void
}

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

declare ptr @nco_crcf_create(i32 noundef) local_unnamed_addr #2

declare i32 @nco_crcf_set_frequency(ptr noundef, float noundef) local_unnamed_addr #2

declare ptr @spgramcf_create(i32 noundef, i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #2

declare i64 @spgramcf_get_num_samples_total(ptr noundef) local_unnamed_addr #2

declare i32 @nco_crcf_mix_block_up(ptr noundef, ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #2

declare float @liquid_hann(i32 noundef, i32 noundef) local_unnamed_addr #2

declare i32 @spgramcf_write(ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #2

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

declare i32 @liquid_autotest_validate_psd_spgramcf(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #2

declare i32 @nco_crcf_destroy(ptr noundef) local_unnamed_addr #2

declare i32 @spgramcf_destroy(ptr noundef) local_unnamed_addr #2

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

attributes #0 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { 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 = { 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 = distinct !{!5, !6, !7, !8}
!6 = !{!"llvm.loop.mustprogress"}
!7 = !{!"llvm.loop.isvectorized", i32 1}
!8 = !{!"llvm.loop.unroll.runtime.disable"}
!9 = distinct !{!9, !6}
!10 = distinct !{!10, !6}
!11 = !{!12, !13, i64 0}
!12 = !{!"", !13, i64 0, !13, i64 4, !13, i64 8, !13, i64 12, !16, i64 16, !16, i64 20}
!13 = !{!"float", !14, i64 0}
!14 = !{!"omnipotent char", !15, i64 0}
!15 = !{!"Simple C/C++ TBAA"}
!16 = !{!"int", !14, i64 0}
!17 = !{!13, !13, i64 0}
!18 = !{!12, !16, i64 16}
!19 = !{!12, !16, i64 20}
!20 = !{!12, !13, i64 4}
!21 = !{!12, !13, i64 12}
!22 = !{!16, !16, i64 0}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LoopLoadEliminationPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,LoopVectorizePass,ReassociatePass,SLPVectorizerPass,SROAPass,SimplifyCFGPass,TailCallElimPass