; LLVM IR from jgaeddert/liquid-dsp :: examples (nco_pll_real_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 [23 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [57 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [50 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [37 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.17 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.18 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.20 = external hidden unnamed_addr constant [32 x i8], align 1
@.str.21 = external hidden unnamed_addr constant [26 x i8], align 1
@.str.22 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.23 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.24 = external hidden unnamed_addr constant [32 x i8], align 1
@.str.25 = external hidden unnamed_addr constant [26 x i8], align 1
@.str.26 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.27 = external hidden unnamed_addr constant [7 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local i32 @main() #0 {
  %1 = alloca i32, align 4
  %2 = alloca float, align 4
  %3 = alloca i32, align 4
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca float, align 4
  %9 = alloca float, align 4
  %10 = alloca float, align 4
  %11 = alloca float, align 4
  %12 = alloca { float, float }, align 4
  %13 = alloca { float, float }, align 4
  %14 = alloca { float, float }, align 4
  %15 = alloca float, align 4
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr %2) #4
  store float 0x3F60624DE0000000, ptr %2, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #4
  store i32 500, ptr %3, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %4) #4
  %16 = call ptr @nco_crcf_create(i32 noundef 1)
  store ptr %16, ptr %4, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #4
  %17 = call ptr @nco_crcf_create(i32 noundef 1)
  store ptr %17, ptr %5, align 8, !tbaa !11
  %18 = load ptr, ptr %4, align 8, !tbaa !11
  %19 = call i32 @nco_crcf_set_frequency(ptr noundef %18, float noundef 0x3FD99999A0000000)
  %20 = load ptr, ptr %5, align 8, !tbaa !11
  %21 = call i32 @nco_crcf_set_frequency(ptr noundef %20, float noundef 0x3FD3333340000000)
  %22 = load ptr, ptr %5, align 8, !tbaa !11
  %23 = call i32 @nco_crcf_set_phase(ptr noundef %22, float noundef 3.000000e+00)
  %24 = load ptr, ptr %5, align 8, !tbaa !11
  %25 = load float, ptr %2, align 4, !tbaa !5
  %26 = call i32 @nco_crcf_pll_set_bandwidth(ptr noundef %24, float noundef %25)
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #4
  %27 = call noalias ptr @fopen(ptr noundef @.str, ptr noundef @.str.1)
  store ptr %27, ptr %6, align 8, !tbaa !11
  %28 = load ptr, ptr %6, align 8, !tbaa !11
  %29 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %28, ptr noundef @.str.2, ptr noundef @.str) #4
  %30 = load ptr, ptr %6, align 8, !tbaa !11
  %31 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %30, ptr noundef @.str.3) #4
  %32 = load ptr, ptr %6, align 8, !tbaa !11
  %33 = load i32, ptr %3, align 4, !tbaa !9
  %34 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %32, ptr noundef @.str.4, i32 noundef %33) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #4
  store i32 0, ptr %7, align 4, !tbaa !9
  br label %35

35:                                               ; preds = %126, %0
  %36 = load i32, ptr %7, align 4, !tbaa !9
  %37 = load i32, ptr %3, align 4, !tbaa !9
  %38 = icmp ult i32 %36, %37
  br i1 %38, label %39, label %129

39:                                               ; preds = %35
  %40 = load ptr, ptr %4, align 8, !tbaa !11
  %41 = call float @nco_crcf_sin(ptr noundef %40)
  store float %41, ptr %8, align 4, !tbaa !5
  %42 = load ptr, ptr %5, align 8, !tbaa !11
  %43 = call float @nco_crcf_sin(ptr noundef %42)
  store float %43, ptr %9, align 4, !tbaa !5
  %44 = load ptr, ptr %4, align 8, !tbaa !11
  %45 = call float @nco_crcf_sin(ptr noundef %44)
  %46 = fmul float 2.000000e+00, %45
  %47 = load ptr, ptr %5, align 8, !tbaa !11
  %48 = call float @nco_crcf_cos(ptr noundef %47)
  %49 = fmul float %46, %48
  store float %49, ptr %10, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #4
  %50 = load ptr, ptr %5, align 8, !tbaa !11
  %51 = call float @nco_crcf_get_phase(ptr noundef %50)
  %52 = load ptr, ptr %4, align 8, !tbaa !11
  %53 = call float @nco_crcf_get_phase(ptr noundef %52)
  %54 = fsub float %51, %53
  %55 = fmul float 0.000000e+00, %54
  %56 = fmul float 1.000000e+00, %54
  %57 = getelementptr inbounds { float, float }, ptr %12, i32 0, i32 0
  %58 = getelementptr inbounds { float, float }, ptr %12, i32 0, i32 1
  store float %55, ptr %57, align 4
  store float %56, ptr %58, align 4
  %59 = load <2 x float>, ptr %12, align 4
  %60 = call <2 x float> @cexpf(<2 x float> noundef %59) #4
  store <2 x float> %60, ptr %13, align 4
  %61 = getelementptr inbounds { float, float }, ptr %13, i32 0, i32 0
  %62 = load float, ptr %61, align 4
  %63 = getelementptr inbounds { float, float }, ptr %13, i32 0, i32 1
  %64 = load float, ptr %63, align 4
  %65 = getelementptr inbounds { float, float }, ptr %14, i32 0, i32 0
  %66 = getelementptr inbounds { float, float }, ptr %14, i32 0, i32 1
  store float %62, ptr %65, align 4
  store float %64, ptr %66, align 4
  %67 = load <2 x float>, ptr %14, align 4
  %68 = call float @cargf(<2 x float> noundef %67) #4
  store float %68, ptr %11, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #4
  %69 = load ptr, ptr %5, align 8, !tbaa !11
  %70 = call float @nco_crcf_get_frequency(ptr noundef %69)
  %71 = load ptr, ptr %4, align 8, !tbaa !11
  %72 = call float @nco_crcf_get_frequency(ptr noundef %71)
  %73 = fsub float %70, %72
  store float %73, ptr %15, align 4, !tbaa !5
  %74 = load ptr, ptr %5, align 8, !tbaa !11
  %75 = load float, ptr %10, align 4, !tbaa !5
  %76 = call i32 @nco_crcf_pll_step(ptr noundef %74, float noundef %75)
  %77 = load ptr, ptr %4, align 8, !tbaa !11
  %78 = call i32 @nco_crcf_step(ptr noundef %77)
  %79 = load ptr, ptr %5, align 8, !tbaa !11
  %80 = call i32 @nco_crcf_step(ptr noundef %79)
  %81 = load i32, ptr %7, align 4, !tbaa !9
  %82 = add i32 %81, 1
  %83 = urem i32 %82, 50
  %84 = icmp eq i32 %83, 0
  br i1 %84, label %93, label %85

85:                                               ; preds = %39
  %86 = load i32, ptr %7, align 4, !tbaa !9
  %87 = load i32, ptr %3, align 4, !tbaa !9
  %88 = sub i32 %87, 1
  %89 = icmp eq i32 %86, %88
  br i1 %89, label %93, label %90

90:                                               ; preds = %85
  %91 = load i32, ptr %7, align 4, !tbaa !9
  %92 = icmp eq i32 %91, 0
  br i1 %92, label %93, label %101

93:                                               ; preds = %90, %85, %39
  %94 = load i32, ptr %7, align 4, !tbaa !9
  %95 = add i32 %94, 1
  %96 = load float, ptr %11, align 4, !tbaa !5
  %97 = fpext float %96 to double
  %98 = load float, ptr %15, align 4, !tbaa !5
  %99 = fpext float %98 to double
  %100 = call i32 (ptr, ...) @printf(ptr noundef @.str.5, i32 noundef %95, double noundef %97, double noundef %99)
  br label %101

101:                                              ; preds = %93, %90
  %102 = load ptr, ptr %6, align 8, !tbaa !11
  %103 = load i32, ptr %7, align 4, !tbaa !9
  %104 = add i32 %103, 1
  %105 = load float, ptr %8, align 4, !tbaa !5
  %106 = fpext float %105 to double
  %107 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %102, ptr noundef @.str.6, i32 noundef %104, double noundef %106) #4
  %108 = load ptr, ptr %6, align 8, !tbaa !11
  %109 = load i32, ptr %7, align 4, !tbaa !9
  %110 = add i32 %109, 1
  %111 = load float, ptr %9, align 4, !tbaa !5
  %112 = fpext float %111 to double
  %113 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %108, ptr noundef @.str.7, i32 noundef %110, double noundef %112) #4
  %114 = load ptr, ptr %6, align 8, !tbaa !11
  %115 = load i32, ptr %7, align 4, !tbaa !9
  %116 = add i32 %115, 1
  %117 = load float, ptr %11, align 4, !tbaa !5
  %118 = fpext float %117 to double
  %119 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %114, ptr noundef @.str.8, i32 noundef %116, double noundef %118) #4
  %120 = load ptr, ptr %6, align 8, !tbaa !11
  %121 = load i32, ptr %7, align 4, !tbaa !9
  %122 = add i32 %121, 1
  %123 = load float, ptr %15, align 4, !tbaa !5
  %124 = fpext float %123 to double
  %125 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %120, ptr noundef @.str.9, i32 noundef %122, double noundef %124) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #4
  br label %126

126:                                              ; preds = %101
  %127 = load i32, ptr %7, align 4, !tbaa !9
  %128 = add i32 %127, 1
  store i32 %128, ptr %7, align 4, !tbaa !9
  br label %35, !llvm.loop !13

129:                                              ; preds = %35
  %130 = load ptr, ptr %4, align 8, !tbaa !11
  %131 = call i32 @nco_crcf_destroy(ptr noundef %130)
  %132 = load ptr, ptr %5, align 8, !tbaa !11
  %133 = call i32 @nco_crcf_destroy(ptr noundef %132)
  %134 = load ptr, ptr %6, align 8, !tbaa !11
  %135 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %134, ptr noundef @.str.10) #4
  %136 = load ptr, ptr %6, align 8, !tbaa !11
  %137 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %136, ptr noundef @.str.11) #4
  %138 = load ptr, ptr %6, align 8, !tbaa !11
  %139 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %138, ptr noundef @.str.12) #4
  %140 = load ptr, ptr %6, align 8, !tbaa !11
  %141 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %140, ptr noundef @.str.13) #4
  %142 = load ptr, ptr %6, align 8, !tbaa !11
  %143 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %142, ptr noundef @.str.14) #4
  %144 = load ptr, ptr %6, align 8, !tbaa !11
  %145 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %144, ptr noundef @.str.15) #4
  %146 = load ptr, ptr %6, align 8, !tbaa !11
  %147 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %146, ptr noundef @.str.16) #4
  %148 = load ptr, ptr %6, align 8, !tbaa !11
  %149 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %148, ptr noundef @.str.17) #4
  %150 = load ptr, ptr %6, align 8, !tbaa !11
  %151 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %150, ptr noundef @.str.18) #4
  %152 = load ptr, ptr %6, align 8, !tbaa !11
  %153 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %152, ptr noundef @.str.19) #4
  %154 = load ptr, ptr %6, align 8, !tbaa !11
  %155 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %154, ptr noundef @.str.20) #4
  %156 = load ptr, ptr %6, align 8, !tbaa !11
  %157 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %156, ptr noundef @.str.15) #4
  %158 = load ptr, ptr %6, align 8, !tbaa !11
  %159 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %158, ptr noundef @.str.21) #4
  %160 = load ptr, ptr %6, align 8, !tbaa !11
  %161 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %160, ptr noundef @.str.22) #4
  %162 = load ptr, ptr %6, align 8, !tbaa !11
  %163 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %162, ptr noundef @.str.18) #4
  %164 = load ptr, ptr %6, align 8, !tbaa !11
  %165 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %164, ptr noundef @.str.23) #4
  %166 = load ptr, ptr %6, align 8, !tbaa !11
  %167 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %166, ptr noundef @.str.24) #4
  %168 = load ptr, ptr %6, align 8, !tbaa !11
  %169 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %168, ptr noundef @.str.15) #4
  %170 = load ptr, ptr %6, align 8, !tbaa !11
  %171 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %170, ptr noundef @.str.25) #4
  %172 = load ptr, ptr %6, align 8, !tbaa !11
  %173 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %172, ptr noundef @.str.18) #4
  %174 = load ptr, ptr %6, align 8, !tbaa !11
  %175 = call i32 @fclose(ptr noundef %174)
  %176 = call i32 (ptr, ...) @printf(ptr noundef @.str.26, ptr noundef @.str)
  %177 = call i32 (ptr, ...) @printf(ptr noundef @.str.27)
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %2) #4
  ret i32 0
}

; 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

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

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

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

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

declare float @nco_crcf_sin(ptr noundef) #2

declare float @nco_crcf_cos(ptr noundef) #2

; Function Attrs: nounwind
declare float @cargf(<2 x float> noundef) #3

; Function Attrs: nounwind
declare <2 x float> @cexpf(<2 x float> noundef) #3

declare float @nco_crcf_get_phase(ptr noundef) #2

declare float @nco_crcf_get_frequency(ptr noundef) #2

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

declare i32 @nco_crcf_step(ptr noundef) #2

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

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

declare i32 @nco_crcf_destroy(ptr noundef) #2

declare i32 @fclose(ptr noundef) #2

attributes #0 = { nounwind uwtable "min-legal-vector-width"="64" "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 = { 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 = !{!6, !6, i64 0}
!6 = !{!"float", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"any pointer", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}


; 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 [23 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [57 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [50 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [37 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.17 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.18 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.20 = external hidden unnamed_addr constant [32 x i8], align 1
@.str.21 = external hidden unnamed_addr constant [26 x i8], align 1
@.str.22 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.23 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.24 = external hidden unnamed_addr constant [32 x i8], align 1
@.str.25 = external hidden unnamed_addr constant [26 x i8], align 1
@.str.26 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.27 = external hidden unnamed_addr constant [7 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local noundef i32 @main() local_unnamed_addr #0 {
  %1 = tail call ptr @nco_crcf_create(i32 noundef 1) #4
  %2 = tail call ptr @nco_crcf_create(i32 noundef 1) #4
  %3 = tail call i32 @nco_crcf_set_frequency(ptr noundef %1, float noundef 0x3FD99999A0000000) #4
  %4 = tail call i32 @nco_crcf_set_frequency(ptr noundef %2, float noundef 0x3FD3333340000000) #4
  %5 = tail call i32 @nco_crcf_set_phase(ptr noundef %2, float noundef 3.000000e+00) #4
  %6 = tail call i32 @nco_crcf_pll_set_bandwidth(ptr noundef %2, float noundef 0x3F60624DE0000000) #4
  %7 = tail call noalias ptr @fopen(ptr noundef nonnull @.str, ptr noundef nonnull @.str.1)
  %8 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.2, ptr noundef nonnull @.str) #4
  %9 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.3) #4
  %10 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.4, i32 noundef 500) #4
  br label %11

11:                                               ; preds = %0, %38
  %.070 = phi i32 [ 0, %0 ], [ %30, %38 ]
  %12 = tail call float @nco_crcf_sin(ptr noundef %1) #4
  %13 = tail call float @nco_crcf_sin(ptr noundef %2) #4
  %14 = tail call float @nco_crcf_sin(ptr noundef %1) #4
  %15 = fmul float %14, 2.000000e+00
  %16 = tail call float @nco_crcf_cos(ptr noundef %2) #4
  %17 = fmul float %15, %16
  %18 = tail call float @nco_crcf_get_phase(ptr noundef %2) #4
  %19 = tail call float @nco_crcf_get_phase(ptr noundef %1) #4
  %20 = fsub float %18, %19
  %21 = fmul float %20, 0.000000e+00
  %.sroa.05.0.vec.insert = insertelement <2 x float> poison, float %21, i64 0
  %.sroa.05.4.vec.insert = insertelement <2 x float> %.sroa.05.0.vec.insert, float %20, i64 1
  %22 = tail call <2 x float> @cexpf(<2 x float> noundef %.sroa.05.4.vec.insert) #4
  %23 = tail call float @cargf(<2 x float> noundef %22) #4
  %24 = tail call float @nco_crcf_get_frequency(ptr noundef %2) #4
  %25 = tail call float @nco_crcf_get_frequency(ptr noundef %1) #4
  %26 = fsub float %24, %25
  %27 = tail call i32 @nco_crcf_pll_step(ptr noundef %2, float noundef %17) #4
  %28 = tail call i32 @nco_crcf_step(ptr noundef %1) #4
  %29 = tail call i32 @nco_crcf_step(ptr noundef %2) #4
  %30 = add nuw nsw i32 %.070, 1
  %.lhs.trunc = trunc nuw i32 %30 to i16
  %31 = urem i16 %.lhs.trunc, 50
  %32 = icmp eq i16 %31, 0
  br i1 %32, label %34, label %33

33:                                               ; preds = %11
  switch i32 %.070, label %._crit_edge [
    i32 499, label %34
    i32 0, label %34
  ]

._crit_edge:                                      ; preds = %33
  %.pre = fpext float %23 to double
  %.pre71 = fpext float %26 to double
  br label %38

34:                                               ; preds = %33, %33, %11
  %35 = fpext float %23 to double
  %36 = fpext float %26 to double
  %37 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.5, i32 noundef %30, double noundef %35, double noundef %36)
  br label %38

38:                                               ; preds = %._crit_edge, %34
  %.pre-phi72 = phi double [ %.pre71, %._crit_edge ], [ %36, %34 ]
  %.pre-phi = phi double [ %.pre, %._crit_edge ], [ %35, %34 ]
  %39 = fpext float %12 to double
  %40 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.6, i32 noundef %30, double noundef %39) #4
  %41 = fpext float %13 to double
  %42 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.7, i32 noundef %30, double noundef %41) #4
  %43 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.8, i32 noundef %30, double noundef %.pre-phi) #4
  %44 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.9, i32 noundef %30, double noundef %.pre-phi72) #4
  %exitcond.not = icmp eq i32 %30, 500
  br i1 %exitcond.not, label %45, label %11, !llvm.loop !5

45:                                               ; preds = %38
  %46 = tail call i32 @nco_crcf_destroy(ptr noundef %1) #4
  %47 = tail call i32 @nco_crcf_destroy(ptr noundef %2) #4
  %48 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.10) #4
  %49 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.11) #4
  %50 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.12) #4
  %51 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.13) #4
  %52 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.14) #4
  %53 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.15) #4
  %54 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.16) #4
  %55 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.17) #4
  %56 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.18) #4
  %57 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.19) #4
  %58 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.20) #4
  %59 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.15) #4
  %60 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.21) #4
  %61 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.22) #4
  %62 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.18) #4
  %63 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.23) #4
  %64 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.24) #4
  %65 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.15) #4
  %66 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.25) #4
  %67 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.18) #4
  %68 = tail call i32 @fclose(ptr noundef %7)
  %69 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.26, ptr noundef nonnull @.str)
  %70 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.27)
  ret i32 0
}

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_set_phase(ptr noundef, float noundef) local_unnamed_addr #1

declare i32 @nco_crcf_pll_set_bandwidth(ptr noundef, float 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

declare float @nco_crcf_sin(ptr noundef) local_unnamed_addr #1

declare float @nco_crcf_cos(ptr noundef) local_unnamed_addr #1

; Function Attrs: nounwind
declare float @cargf(<2 x float> noundef) local_unnamed_addr #3

; Function Attrs: nounwind
declare <2 x float> @cexpf(<2 x float> noundef) local_unnamed_addr #3

declare float @nco_crcf_get_phase(ptr noundef) local_unnamed_addr #1

declare float @nco_crcf_get_frequency(ptr noundef) local_unnamed_addr #1

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

declare i32 @nco_crcf_step(ptr noundef) local_unnamed_addr #1

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

declare i32 @nco_crcf_destroy(ptr noundef) local_unnamed_addr #1

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

attributes #0 = { nounwind uwtable "min-legal-vector-width"="64" "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 "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}
!6 = !{!"llvm.loop.mustprogress"}


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