; LLVM IR from jgaeddert/liquid-dsp :: examples (nco_crcf_mix_example)

; 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"

@.str = external hidden unnamed_addr constant [19 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [33 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [41 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [60 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [60 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [41 x i8], align 1
@.str.17 = external hidden unnamed_addr constant [40 x i8], align 1
@.str.18 = external hidden unnamed_addr constant [41 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.20 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.21 = external hidden unnamed_addr constant [24 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local i32 @main() #0 {
  %1 = alloca i32, align 4
  %2 = alloca i32, align 4
  %3 = alloca float, align 4
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca ptr, align 8
  %12 = alloca i64, align 8
  %13 = alloca i32, align 4
  %14 = alloca i64, align 8
  %15 = alloca i64, align 8
  %16 = alloca ptr, align 8
  %17 = alloca i32, align 4
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #5
  store i32 0, ptr %2, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #5
  store float 0x3FA99999A0000000, ptr %3, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #5
  store i32 240000, ptr %4, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #5
  store i32 1200, ptr %5, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #5
  %18 = call ptr @msourcecf_create_default()
  store ptr %18, ptr %6, align 8, !tbaa !11
  %19 = load ptr, ptr %6, align 8, !tbaa !11
  %20 = call i32 @msourcecf_add_noise(ptr noundef %19, float noundef 0.000000e+00, float noundef 1.000000e+00, float noundef -6.000000e+01)
  %21 = load ptr, ptr %6, align 8, !tbaa !11
  %22 = call i32 @msourcecf_add_noise(ptr noundef %21, float noundef 0.000000e+00, float noundef 0x3FC99999A0000000, float noundef -4.000000e+01)
  %23 = load ptr, ptr %6, align 8, !tbaa !11
  %24 = call i32 @msourcecf_add_tone(ptr noundef %23, float noundef 0xBFD99999A0000000, float noundef 0.000000e+00, float noundef -2.000000e+01)
  %25 = load ptr, ptr %6, align 8, !tbaa !11
  %26 = call i32 @msourcecf_add_modem(ptr noundef %25, float noundef 0x3FC99999A0000000, float noundef 0x3FB99999A0000000, float noundef -3.000000e+01, i32 noundef 40, i32 noundef 12, float noundef 2.500000e-01)
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #5
  %27 = load i32, ptr %2, align 4, !tbaa !5
  %28 = call ptr @nco_crcf_create(i32 noundef %27)
  store ptr %28, ptr %7, align 8, !tbaa !11
  %29 = load ptr, ptr %7, align 8, !tbaa !11
  %30 = load float, ptr %3, align 4, !tbaa !9
  %31 = fpext float %30 to double
  %32 = fmul double 0x401921FB54442D18, %31
  %33 = fptrunc double %32 to float
  %34 = call i32 @nco_crcf_set_frequency(ptr noundef %29, float noundef %33)
  %35 = load ptr, ptr %7, align 8, !tbaa !11
  %36 = call i32 @nco_crcf_print(ptr noundef %35)
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #5
  %37 = load i32, ptr %5, align 4, !tbaa !5
  %38 = call ptr @spgramcf_create_default(i32 noundef %37)
  store ptr %38, ptr %8, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #5
  %39 = load i32, ptr %5, align 4, !tbaa !5
  %40 = call ptr @spgramcf_create_default(i32 noundef %39)
  store ptr %40, ptr %9, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #5
  store i32 1024, ptr %10, align 4, !tbaa !5
  %41 = load i32, ptr %10, align 4, !tbaa !5
  %42 = zext i32 %41 to i64
  %43 = call ptr @llvm.stacksave.p0()
  store ptr %43, ptr %11, align 8
  %44 = alloca { float, float }, i64 %42, align 16
  store i64 %42, ptr %12, align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #5
  store i32 0, ptr %13, align 4, !tbaa !5
  br label %45

45:                                               ; preds = %49, %0
  %46 = load i32, ptr %13, align 4, !tbaa !5
  %47 = load i32, ptr %4, align 4, !tbaa !5
  %48 = icmp ult i32 %46, %47
  br i1 %48, label %49, label %65

49:                                               ; preds = %45
  %50 = load ptr, ptr %6, align 8, !tbaa !11
  %51 = load i32, ptr %10, align 4, !tbaa !5
  %52 = call i32 @msourcecf_write_samples(ptr noundef %50, ptr noundef %44, i32 noundef %51)
  %53 = load ptr, ptr %8, align 8, !tbaa !11
  %54 = load i32, ptr %10, align 4, !tbaa !5
  %55 = call i32 @spgramcf_write(ptr noundef %53, ptr noundef %44, i32 noundef %54)
  %56 = load ptr, ptr %7, align 8, !tbaa !11
  %57 = load i32, ptr %10, align 4, !tbaa !5
  %58 = call i32 @nco_crcf_mix_block_down(ptr noundef %56, ptr noundef %44, ptr noundef %44, i32 noundef %57)
  %59 = load ptr, ptr %9, align 8, !tbaa !11
  %60 = load i32, ptr %10, align 4, !tbaa !5
  %61 = call i32 @spgramcf_write(ptr noundef %59, ptr noundef %44, i32 noundef %60)
  %62 = load i32, ptr %10, align 4, !tbaa !5
  %63 = load i32, ptr %13, align 4, !tbaa !5
  %64 = add i32 %63, %62
  store i32 %64, ptr %13, align 4, !tbaa !5
  br label %45, !llvm.loop !13

65:                                               ; preds = %45
  %66 = load i32, ptr %13, align 4, !tbaa !5
  %67 = call i32 (ptr, ...) @printf(ptr noundef @.str, i32 noundef %66)
  %68 = load i32, ptr %5, align 4, !tbaa !5
  %69 = zext i32 %68 to i64
  %70 = alloca float, i64 %69, align 16
  store i64 %69, ptr %14, align 8
  %71 = load i32, ptr %5, align 4, !tbaa !5
  %72 = zext i32 %71 to i64
  %73 = alloca float, i64 %72, align 16
  store i64 %72, ptr %15, align 8
  %74 = load ptr, ptr %8, align 8, !tbaa !11
  %75 = call i32 @spgramcf_get_psd(ptr noundef %74, ptr noundef %70)
  %76 = load ptr, ptr %9, align 8, !tbaa !11
  %77 = call i32 @spgramcf_get_psd(ptr noundef %76, ptr noundef %73)
  %78 = load ptr, ptr %8, align 8, !tbaa !11
  %79 = call i32 @spgramcf_destroy(ptr noundef %78)
  %80 = load ptr, ptr %9, align 8, !tbaa !11
  %81 = call i32 @spgramcf_destroy(ptr noundef %80)
  %82 = load ptr, ptr %7, align 8, !tbaa !11
  %83 = call i32 @nco_crcf_destroy(ptr noundef %82)
  %84 = load ptr, ptr %6, align 8, !tbaa !11
  %85 = call i32 @msourcecf_destroy(ptr noundef %84)
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #5
  %86 = call noalias ptr @fopen(ptr noundef @.str.1, ptr noundef @.str.2)
  store ptr %86, ptr %16, align 8, !tbaa !11
  %87 = load ptr, ptr %16, align 8, !tbaa !11
  %88 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %87, ptr noundef @.str.3, ptr noundef @.str.1) #5
  %89 = load ptr, ptr %16, align 8, !tbaa !11
  %90 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %89, ptr noundef @.str.4) #5
  %91 = load ptr, ptr %16, align 8, !tbaa !11
  %92 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %91, ptr noundef @.str.5) #5
  %93 = load ptr, ptr %16, align 8, !tbaa !11
  %94 = load i32, ptr %5, align 4, !tbaa !5
  %95 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %93, ptr noundef @.str.6, i32 noundef %94) #5
  %96 = load ptr, ptr %16, align 8, !tbaa !11
  %97 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %96, ptr noundef @.str.7) #5
  %98 = load ptr, ptr %16, align 8, !tbaa !11
  %99 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %98, ptr noundef @.str.8) #5
  %100 = load ptr, ptr %16, align 8, !tbaa !11
  %101 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %100, ptr noundef @.str.9) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #5
  store i32 0, ptr %17, align 4, !tbaa !5
  br label %102

102:                                              ; preds = %123, %65
  %103 = load i32, ptr %17, align 4, !tbaa !5
  %104 = load i32, ptr %5, align 4, !tbaa !5
  %105 = icmp ult i32 %103, %104
  br i1 %105, label %106, label %126

106:                                              ; preds = %102
  %107 = load ptr, ptr %16, align 8, !tbaa !11
  %108 = load i32, ptr %17, align 4, !tbaa !5
  %109 = add i32 %108, 1
  %110 = load i32, ptr %17, align 4, !tbaa !5
  %111 = zext i32 %110 to i64
  %112 = getelementptr inbounds float, ptr %70, i64 %111
  %113 = load float, ptr %112, align 4, !tbaa !9
  %114 = fpext float %113 to double
  %115 = load i32, ptr %17, align 4, !tbaa !5
  %116 = add i32 %115, 1
  %117 = load i32, ptr %17, align 4, !tbaa !5
  %118 = zext i32 %117 to i64
  %119 = getelementptr inbounds float, ptr %73, i64 %118
  %120 = load float, ptr %119, align 4, !tbaa !9
  %121 = fpext float %120 to double
  %122 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %107, ptr noundef @.str.10, i32 noundef %109, double noundef %114, i32 noundef %116, double noundef %121) #5
  br label %123

123:                                              ; preds = %106
  %124 = load i32, ptr %17, align 4, !tbaa !5
  %125 = add i32 %124, 1
  store i32 %125, ptr %17, align 4, !tbaa !5
  br label %102, !llvm.loop !15

126:                                              ; preds = %102
  %127 = load ptr, ptr %16, align 8, !tbaa !11
  %128 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %127, ptr noundef @.str.11) #5
  %129 = load ptr, ptr %16, align 8, !tbaa !11
  %130 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %129, ptr noundef @.str.12) #5
  %131 = load ptr, ptr %16, align 8, !tbaa !11
  %132 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %131, ptr noundef @.str.13) #5
  %133 = load ptr, ptr %16, align 8, !tbaa !11
  %134 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %133, ptr noundef @.str.14) #5
  %135 = load ptr, ptr %16, align 8, !tbaa !11
  %136 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %135, ptr noundef @.str.15) #5
  %137 = load ptr, ptr %16, align 8, !tbaa !11
  %138 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %137, ptr noundef @.str.16) #5
  %139 = load ptr, ptr %16, align 8, !tbaa !11
  %140 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %139, ptr noundef @.str.17) #5
  %141 = load ptr, ptr %16, align 8, !tbaa !11
  %142 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %141, ptr noundef @.str.18) #5
  %143 = load ptr, ptr %16, align 8, !tbaa !11
  %144 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %143, ptr noundef @.str.19) #5
  %145 = load ptr, ptr %16, align 8, !tbaa !11
  %146 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %145, ptr noundef @.str.20) #5
  %147 = load ptr, ptr %16, align 8, !tbaa !11
  %148 = call i32 @fclose(ptr noundef %147)
  %149 = call i32 (ptr, ...) @printf(ptr noundef @.str.21, ptr noundef @.str.1)
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #5
  %150 = load ptr, ptr %11, align 8
  call void @llvm.stackrestore.p0(ptr %150)
  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 8, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #5
  %151 = load i32, ptr %1, align 4
  ret i32 %151
}

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

declare ptr @msourcecf_create_default() #2

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

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

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

declare ptr @nco_crcf_create(i32 noundef) #2

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

declare i32 @nco_crcf_print(ptr noundef) #2

declare ptr @spgramcf_create_default(i32 noundef) #2

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

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

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

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

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

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

declare i32 @spgramcf_destroy(ptr noundef) #2

declare i32 @nco_crcf_destroy(ptr noundef) #2

declare i32 @msourcecf_destroy(ptr noundef) #2

declare noalias ptr @fopen(ptr noundef, ptr noundef) #2

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

declare i32 @fclose(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 = !{!"any pointer", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = distinct !{!15, !14}


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

@.str = external hidden unnamed_addr constant [19 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [33 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [41 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [60 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [60 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [41 x i8], align 1
@.str.17 = external hidden unnamed_addr constant [40 x i8], align 1
@.str.18 = external hidden unnamed_addr constant [41 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.20 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.21 = external hidden unnamed_addr constant [24 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 {
  %1 = tail call ptr @msourcecf_create_default() #3
  %2 = tail call i32 @msourcecf_add_noise(ptr noundef %1, float noundef 0.000000e+00, float noundef 1.000000e+00, float noundef -6.000000e+01) #3
  %3 = tail call i32 @msourcecf_add_noise(ptr noundef %1, float noundef 0.000000e+00, float noundef 0x3FC99999A0000000, float noundef -4.000000e+01) #3
  %4 = tail call i32 @msourcecf_add_tone(ptr noundef %1, float noundef 0xBFD99999A0000000, float noundef 0.000000e+00, float noundef -2.000000e+01) #3
  %5 = tail call i32 @msourcecf_add_modem(ptr noundef %1, float noundef 0x3FC99999A0000000, float noundef 0x3FB99999A0000000, float noundef -3.000000e+01, i32 noundef 40, i32 noundef 12, float noundef 2.500000e-01) #3
  %6 = tail call ptr @nco_crcf_create(i32 noundef 0) #3
  %7 = tail call i32 @nco_crcf_set_frequency(ptr noundef %6, float noundef 0x3FD41B2F80000000) #3
  %8 = tail call i32 @nco_crcf_print(ptr noundef %6) #3
  %9 = tail call ptr @spgramcf_create_default(i32 noundef 1200) #3
  %10 = tail call ptr @spgramcf_create_default(i32 noundef 1200) #3
  %11 = alloca [1024 x { float, float }], align 16
  br label %12

12:                                               ; preds = %0, %12
  %.06061 = phi i32 [ 0, %0 ], [ %17, %12 ]
  %13 = call i32 @msourcecf_write_samples(ptr noundef %1, ptr noundef nonnull %11, i32 noundef 1024) #3
  %14 = call i32 @spgramcf_write(ptr noundef %9, ptr noundef nonnull %11, i32 noundef 1024) #3
  %15 = call i32 @nco_crcf_mix_block_down(ptr noundef %6, ptr noundef nonnull %11, ptr noundef nonnull %11, i32 noundef 1024) #3
  %16 = call i32 @spgramcf_write(ptr noundef %10, ptr noundef nonnull %11, i32 noundef 1024) #3
  %17 = add nuw nsw i32 %.06061, 1024
  %18 = icmp ult i32 %.06061, 238976
  br i1 %18, label %12, label %19, !llvm.loop !5

19:                                               ; preds = %12
  %20 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str, i32 noundef 240640)
  %21 = alloca [1200 x float], align 16
  %22 = alloca [1200 x float], align 16
  %23 = call i32 @spgramcf_get_psd(ptr noundef %9, ptr noundef nonnull %21) #3
  %24 = call i32 @spgramcf_get_psd(ptr noundef %10, ptr noundef nonnull %22) #3
  %25 = call i32 @spgramcf_destroy(ptr noundef %9) #3
  %26 = call i32 @spgramcf_destroy(ptr noundef %10) #3
  %27 = call i32 @nco_crcf_destroy(ptr noundef %6) #3
  %28 = call i32 @msourcecf_destroy(ptr noundef %1) #3
  %29 = call noalias ptr @fopen(ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.2)
  %30 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.3, ptr noundef nonnull @.str.1) #3
  %31 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.4) #3
  %32 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.5) #3
  %33 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.6, i32 noundef 1200) #3
  %34 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.7) #3
  %35 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.8) #3
  %36 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.9) #3
  br label %37

37:                                               ; preds = %19, %37
  %indvars.iv = phi i64 [ 0, %19 ], [ %indvars.iv.next, %37 ]
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %38 = getelementptr inbounds float, ptr %21, i64 %indvars.iv
  %39 = load float, ptr %38, align 4, !tbaa !7
  %40 = fpext float %39 to double
  %41 = getelementptr inbounds float, ptr %22, i64 %indvars.iv
  %42 = load float, ptr %41, align 4, !tbaa !7
  %43 = fpext float %42 to double
  %44 = trunc nuw nsw i64 %indvars.iv.next to i32
  %45 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.10, i32 noundef %44, double noundef %40, i32 noundef %44, double noundef %43) #3
  %exitcond.not = icmp eq i64 %indvars.iv.next, 1200
  br i1 %exitcond.not, label %46, label %37, !llvm.loop !11

46:                                               ; preds = %37
  %47 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.11) #3
  %48 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.12) #3
  %49 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.13) #3
  %50 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.14) #3
  %51 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.15) #3
  %52 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.16) #3
  %53 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.17) #3
  %54 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.18) #3
  %55 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.19) #3
  %56 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %29, ptr noundef nonnull @.str.20) #3
  %57 = call i32 @fclose(ptr noundef %29)
  %58 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.21, ptr noundef nonnull @.str.1)
  ret i32 0
}

declare ptr @msourcecf_create_default() local_unnamed_addr #1

declare i32 @msourcecf_add_noise(ptr noundef, float noundef, float noundef, float noundef) local_unnamed_addr #1

declare i32 @msourcecf_add_tone(ptr noundef, float noundef, float noundef, float noundef) local_unnamed_addr #1

declare i32 @msourcecf_add_modem(ptr noundef, float noundef, float noundef, float noundef, i32 noundef, i32 noundef, float noundef) local_unnamed_addr #1

declare ptr @nco_crcf_create(i32 noundef) local_unnamed_addr #1

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

declare i32 @nco_crcf_print(ptr noundef) local_unnamed_addr #1

declare ptr @spgramcf_create_default(i32 noundef) local_unnamed_addr #1

declare i32 @msourcecf_write_samples(ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #1

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

declare i32 @nco_crcf_mix_block_down(ptr noundef, ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #1

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

declare i32 @spgramcf_get_psd(ptr noundef, ptr noundef) local_unnamed_addr #1

declare i32 @spgramcf_destroy(ptr noundef) local_unnamed_addr #1

declare i32 @nco_crcf_destroy(ptr noundef) local_unnamed_addr #1

declare i32 @msourcecf_destroy(ptr noundef) local_unnamed_addr #1

; Function Attrs: nofree nounwind
declare noalias noundef ptr @fopen(ptr nocapture noundef readonly, ptr nocapture noundef readonly) local_unnamed_addr #2

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

; Function Attrs: nofree nounwind
declare noundef i32 @fclose(ptr nocapture noundef) local_unnamed_addr #2

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 = { "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 = { 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 #3 = { 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}
!6 = !{!"llvm.loop.mustprogress"}
!7 = !{!8, !8, i64 0}
!8 = !{!"float", !9, i64 0}
!9 = !{!"omnipotent char", !10, i64 0}
!10 = !{!"Simple C/C++ TBAA"}
!11 = distinct !{!11, !6}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,LCSSAPass,LoopRotatePass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass,TailCallElimPass