; LLVM IR from jgaeddert/liquid-dsp :: src/filter/src (filter_cccf)

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

@.str.3 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.129 = external hidden unnamed_addr constant [90 x i8], align 1
@.str.130 = external hidden unnamed_addr constant [62 x i8], align 1
@.str.131 = external hidden unnamed_addr constant [65 x i8], align 1
@.str.132 = external hidden unnamed_addr constant [53 x i8], align 1
@.str.133 = external hidden unnamed_addr constant [75 x i8], align 1
@.str.134 = external hidden unnamed_addr constant [65 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: nounwind allocsize(0)
declare noalias ptr @malloc(i64 noundef) #1

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

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

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

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

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

; Function Attrs: nounwind uwtable
declare dso_local ptr @firpfb_cccf_create(i32 noundef, ptr noundef, i32 noundef) #4

; Function Attrs: nounwind uwtable
define dso_local ptr @resamp_cccf_create(float noundef %0, i32 noundef %1, float noundef %2, float noundef %3, i32 noundef %4) #4 {
  %6 = alloca ptr, align 8
  %7 = alloca float, align 4
  %8 = alloca i32, align 4
  %9 = alloca float, align 4
  %10 = alloca float, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca ptr, align 8
  %15 = alloca i32, align 4
  %16 = alloca ptr, align 8
  %17 = alloca i64, align 8
  %18 = alloca i64, align 8
  %19 = alloca i32, align 4
  %20 = alloca float, align 4
  store float %0, ptr %7, align 4, !tbaa !5
  store i32 %1, ptr %8, align 4, !tbaa !9
  store float %2, ptr %9, align 4, !tbaa !5
  store float %3, ptr %10, align 4, !tbaa !5
  store i32 %4, ptr %11, align 4, !tbaa !9
  %21 = load float, ptr %7, align 4, !tbaa !5
  %22 = fcmp ole float %21, 0.000000e+00
  br i1 %22, label %23, label %25

23:                                               ; preds = %5
  %24 = call ptr (ptr, i32, ptr, ...) @liquid_error_config_fl(ptr noundef @.str.129, i32 noundef 62, ptr noundef @.str.130, ptr noundef @.str.3)
  store ptr %24, ptr %6, align 8
  br label %159

25:                                               ; preds = %5
  %26 = load i32, ptr %8, align 4, !tbaa !9
  %27 = icmp eq i32 %26, 0
  br i1 %27, label %28, label %30

28:                                               ; preds = %25
  %29 = call ptr (ptr, i32, ptr, ...) @liquid_error_config_fl(ptr noundef @.str.129, i32 noundef 64, ptr noundef @.str.131, ptr noundef @.str.3)
  store ptr %29, ptr %6, align 8
  br label %159

30:                                               ; preds = %25
  %31 = load float, ptr %9, align 4, !tbaa !5
  %32 = fcmp ole float %31, 0.000000e+00
  br i1 %32, label %36, label %33

33:                                               ; preds = %30
  %34 = load float, ptr %9, align 4, !tbaa !5
  %35 = fcmp oge float %34, 5.000000e-01
  br i1 %35, label %36, label %38

36:                                               ; preds = %33, %30
  %37 = call ptr (ptr, i32, ptr, ...) @liquid_error_config_fl(ptr noundef @.str.129, i32 noundef 66, ptr noundef @.str.132, ptr noundef @.str.3)
  store ptr %37, ptr %6, align 8
  br label %159

38:                                               ; preds = %33
  %39 = load float, ptr %10, align 4, !tbaa !5
  %40 = fcmp ole float %39, 0.000000e+00
  br i1 %40, label %41, label %43

41:                                               ; preds = %38
  %42 = call ptr (ptr, i32, ptr, ...) @liquid_error_config_fl(ptr noundef @.str.129, i32 noundef 68, ptr noundef @.str.133, ptr noundef @.str.3)
  store ptr %42, ptr %6, align 8
  br label %159

43:                                               ; preds = %38
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #5
  %44 = load i32, ptr %11, align 4, !tbaa !9
  %45 = call i32 @liquid_nextpow2(i32 noundef %44)
  store i32 %45, ptr %12, align 4, !tbaa !9
  %46 = load i32, ptr %12, align 4, !tbaa !9
  %47 = icmp ult i32 %46, 1
  br i1 %47, label %51, label %48

48:                                               ; preds = %43
  %49 = load i32, ptr %12, align 4, !tbaa !9
  %50 = icmp ugt i32 %49, 16
  br i1 %50, label %51, label %53

51:                                               ; preds = %48, %43
  %52 = call ptr (ptr, i32, ptr, ...) @liquid_error_config_fl(ptr noundef @.str.129, i32 noundef 73, ptr noundef @.str.134, ptr noundef @.str.3)
  store ptr %52, ptr %6, align 8
  store i32 1, ptr %13, align 4
  br label %158

53:                                               ; preds = %48
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #5
  %54 = call noalias ptr @malloc(i64 noundef 40) #6
  store ptr %54, ptr %14, align 8, !tbaa !11
  %55 = load ptr, ptr %14, align 8, !tbaa !11
  %56 = load float, ptr %7, align 4, !tbaa !5
  %57 = call i32 @resamp_cccf_set_rate(ptr noundef %55, float noundef %56)
  %58 = load i32, ptr %8, align 4, !tbaa !9
  %59 = load ptr, ptr %14, align 8, !tbaa !11
  %60 = getelementptr inbounds %struct.resamp_cccf_s, ptr %59, i32 0, i32 0
  store i32 %58, ptr %60, align 8, !tbaa !13
  %61 = load float, ptr %9, align 4, !tbaa !5
  %62 = load ptr, ptr %14, align 8, !tbaa !11
  %63 = getelementptr inbounds %struct.resamp_cccf_s, ptr %62, i32 0, i32 2
  store float %61, ptr %63, align 8, !tbaa !15
  %64 = load float, ptr %10, align 4, !tbaa !5
  %65 = load ptr, ptr %14, align 8, !tbaa !11
  %66 = getelementptr inbounds %struct.resamp_cccf_s, ptr %65, i32 0, i32 1
  store float %64, ptr %66, align 4, !tbaa !16
  %67 = load i32, ptr %12, align 4, !tbaa !9
  %68 = load ptr, ptr %14, align 8, !tbaa !11
  %69 = getelementptr inbounds %struct.resamp_cccf_s, ptr %68, i32 0, i32 6
  store i32 %67, ptr %69, align 8, !tbaa !17
  %70 = load ptr, ptr %14, align 8, !tbaa !11
  %71 = getelementptr inbounds %struct.resamp_cccf_s, ptr %70, i32 0, i32 6
  %72 = load i32, ptr %71, align 8, !tbaa !17
  %73 = shl i32 1, %72
  %74 = load ptr, ptr %14, align 8, !tbaa !11
  %75 = getelementptr inbounds %struct.resamp_cccf_s, ptr %74, i32 0, i32 7
  store i32 %73, ptr %75, align 4, !tbaa !18
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #5
  %76 = load ptr, ptr %14, align 8, !tbaa !11
  %77 = getelementptr inbounds %struct.resamp_cccf_s, ptr %76, i32 0, i32 0
  %78 = load i32, ptr %77, align 8, !tbaa !13
  %79 = mul i32 2, %78
  %80 = load ptr, ptr %14, align 8, !tbaa !11
  %81 = getelementptr inbounds %struct.resamp_cccf_s, ptr %80, i32 0, i32 7
  %82 = load i32, ptr %81, align 4, !tbaa !18
  %83 = mul i32 %79, %82
  %84 = add i32 %83, 1
  store i32 %84, ptr %15, align 4, !tbaa !9
  %85 = load i32, ptr %15, align 4, !tbaa !9
  %86 = zext i32 %85 to i64
  %87 = call ptr @llvm.stacksave.p0()
  store ptr %87, ptr %16, align 8
  %88 = alloca float, i64 %86, align 16
  store i64 %86, ptr %17, align 8
  %89 = load i32, ptr %15, align 4, !tbaa !9
  %90 = zext i32 %89 to i64
  %91 = alloca { float, float }, i64 %90, align 16
  store i64 %90, ptr %18, align 8
  %92 = load i32, ptr %15, align 4, !tbaa !9
  %93 = load ptr, ptr %14, align 8, !tbaa !11
  %94 = getelementptr inbounds %struct.resamp_cccf_s, ptr %93, i32 0, i32 2
  %95 = load float, ptr %94, align 8, !tbaa !15
  %96 = load ptr, ptr %14, align 8, !tbaa !11
  %97 = getelementptr inbounds %struct.resamp_cccf_s, ptr %96, i32 0, i32 7
  %98 = load i32, ptr %97, align 4, !tbaa !18
  %99 = uitofp i32 %98 to float
  %100 = fdiv float %95, %99
  %101 = load ptr, ptr %14, align 8, !tbaa !11
  %102 = getelementptr inbounds %struct.resamp_cccf_s, ptr %101, i32 0, i32 1
  %103 = load float, ptr %102, align 4, !tbaa !16
  %104 = call i32 @liquid_firdes_kaiser(i32 noundef %92, float noundef %100, float noundef %103, float noundef 0.000000e+00, ptr noundef %88)
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #5
  store float 0.000000e+00, ptr %20, align 4, !tbaa !5
  store i32 0, ptr %19, align 4, !tbaa !9
  br label %105

105:                                              ; preds = %116, %53
  %106 = load i32, ptr %19, align 4, !tbaa !9
  %107 = load i32, ptr %15, align 4, !tbaa !9
  %108 = icmp ult i32 %106, %107
  br i1 %108, label %109, label %119

109:                                              ; preds = %105
  %110 = load i32, ptr %19, align 4, !tbaa !9
  %111 = zext i32 %110 to i64
  %112 = getelementptr inbounds float, ptr %88, i64 %111
  %113 = load float, ptr %112, align 4, !tbaa !5
  %114 = load float, ptr %20, align 4, !tbaa !5
  %115 = fadd float %114, %113
  store float %115, ptr %20, align 4, !tbaa !5
  br label %116

116:                                              ; preds = %109
  %117 = load i32, ptr %19, align 4, !tbaa !9
  %118 = add i32 %117, 1
  store i32 %118, ptr %19, align 4, !tbaa !9
  br label %105, !llvm.loop !19

119:                                              ; preds = %105
  %120 = load ptr, ptr %14, align 8, !tbaa !11
  %121 = getelementptr inbounds %struct.resamp_cccf_s, ptr %120, i32 0, i32 7
  %122 = load i32, ptr %121, align 4, !tbaa !18
  %123 = uitofp i32 %122 to float
  %124 = load float, ptr %20, align 4, !tbaa !5
  %125 = fdiv float %123, %124
  store float %125, ptr %20, align 4, !tbaa !5
  store i32 0, ptr %19, align 4, !tbaa !9
  br label %126

126:                                              ; preds = %142, %119
  %127 = load i32, ptr %19, align 4, !tbaa !9
  %128 = load i32, ptr %15, align 4, !tbaa !9
  %129 = icmp ult i32 %127, %128
  br i1 %129, label %130, label %145

130:                                              ; preds = %126
  %131 = load i32, ptr %19, align 4, !tbaa !9
  %132 = zext i32 %131 to i64
  %133 = getelementptr inbounds float, ptr %88, i64 %132
  %134 = load float, ptr %133, align 4, !tbaa !5
  %135 = load float, ptr %20, align 4, !tbaa !5
  %136 = fmul float %134, %135
  %137 = load i32, ptr %19, align 4, !tbaa !9
  %138 = zext i32 %137 to i64
  %139 = getelementptr inbounds { float, float }, ptr %91, i64 %138
  %140 = getelementptr inbounds { float, float }, ptr %139, i32 0, i32 0
  %141 = getelementptr inbounds { float, float }, ptr %139, i32 0, i32 1
  store float %136, ptr %140, align 8
  store float 0.000000e+00, ptr %141, align 4
  br label %142

142:                                              ; preds = %130
  %143 = load i32, ptr %19, align 4, !tbaa !9
  %144 = add i32 %143, 1
  store i32 %144, ptr %19, align 4, !tbaa !9
  br label %126, !llvm.loop !21

145:                                              ; preds = %126
  %146 = load ptr, ptr %14, align 8, !tbaa !11
  %147 = getelementptr inbounds %struct.resamp_cccf_s, ptr %146, i32 0, i32 7
  %148 = load i32, ptr %147, align 4, !tbaa !18
  %149 = load i32, ptr %15, align 4, !tbaa !9
  %150 = sub i32 %149, 1
  %151 = call ptr @firpfb_cccf_create(i32 noundef %148, ptr noundef %91, i32 noundef %150)
  %152 = load ptr, ptr %14, align 8, !tbaa !11
  %153 = getelementptr inbounds %struct.resamp_cccf_s, ptr %152, i32 0, i32 8
  store ptr %151, ptr %153, align 8, !tbaa !22
  %154 = load ptr, ptr %14, align 8, !tbaa !11
  %155 = call i32 @resamp_cccf_reset(ptr noundef %154)
  %156 = load ptr, ptr %14, align 8, !tbaa !11
  store ptr %156, ptr %6, align 8
  store i32 1, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #5
  %157 = load ptr, ptr %16, align 8
  call void @llvm.stackrestore.p0(ptr %157)
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #5
  br label %158

158:                                              ; preds = %145, %51
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  br label %159

159:                                              ; preds = %158, %41, %36, %28, %23
  %160 = load ptr, ptr %6, align 8
  ret ptr %160
}

; Function Attrs: nounwind uwtable
declare dso_local i32 @resamp_cccf_reset(ptr noundef) #4

declare i32 @liquid_nextpow2(i32 noundef) #2

; Function Attrs: nounwind uwtable
declare dso_local i32 @resamp_cccf_set_rate(ptr noundef, float noundef) #4

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nounwind allocsize(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 nosync nounwind willreturn }
attributes #4 = { 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 #5 = { nounwind }
attributes #6 = { nounwind allocsize(0) }

!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 = !{!14, !10, i64 0}
!14 = !{!"resamp_cccf_s", !10, i64 0, !6, i64 4, !6, i64 8, !6, i64 12, !10, i64 16, !10, i64 20, !10, i64 24, !10, i64 28, !12, i64 32}
!15 = !{!14, !6, i64 8}
!16 = !{!14, !6, i64 4}
!17 = !{!14, !10, i64 24}
!18 = !{!14, !10, i64 28}
!19 = distinct !{!19, !20}
!20 = !{!"llvm.loop.mustprogress"}
!21 = distinct !{!21, !20}
!22 = !{!14, !12, i64 32}


; 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.3 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.129 = external hidden unnamed_addr constant [90 x i8], align 1
@.str.130 = external hidden unnamed_addr constant [62 x i8], align 1
@.str.131 = external hidden unnamed_addr constant [65 x i8], align 1
@.str.132 = external hidden unnamed_addr constant [53 x i8], align 1
@.str.133 = external hidden unnamed_addr constant [75 x i8], align 1
@.str.134 = external hidden unnamed_addr constant [65 x i8], align 1

; Function Attrs: mustprogress nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite)
declare noalias noundef ptr @malloc(i64 noundef) local_unnamed_addr #0

declare ptr @liquid_error_config_fl(ptr noundef, i32 noundef, ptr noundef, ...) local_unnamed_addr #1

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

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

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

; Function Attrs: nounwind uwtable
declare dso_local ptr @firpfb_cccf_create(i32 noundef, ptr noundef, i32 noundef) local_unnamed_addr #3

; Function Attrs: nounwind uwtable
define dso_local ptr @resamp_cccf_create(float noundef %0, i32 noundef %1, float noundef %2, float noundef %3, i32 noundef %4) local_unnamed_addr #3 {
  %6 = fcmp ugt float %0, 0.000000e+00
  br i1 %6, label %9, label %7

7:                                                ; preds = %5
  %8 = tail call ptr (ptr, i32, ptr, ...) @liquid_error_config_fl(ptr noundef nonnull @.str.129, i32 noundef 62, ptr noundef nonnull @.str.130, ptr noundef nonnull @.str.3) #4
  br label %98

9:                                                ; preds = %5
  %10 = icmp eq i32 %1, 0
  br i1 %10, label %11, label %13

11:                                               ; preds = %9
  %12 = tail call ptr (ptr, i32, ptr, ...) @liquid_error_config_fl(ptr noundef nonnull @.str.129, i32 noundef 64, ptr noundef nonnull @.str.131, ptr noundef nonnull @.str.3) #4
  br label %98

13:                                               ; preds = %9
  %14 = fcmp ole float %2, 0.000000e+00
  %15 = fcmp oge float %2, 5.000000e-01
  %or.cond = or i1 %14, %15
  br i1 %or.cond, label %16, label %18

16:                                               ; preds = %13
  %17 = tail call ptr (ptr, i32, ptr, ...) @liquid_error_config_fl(ptr noundef nonnull @.str.129, i32 noundef 66, ptr noundef nonnull @.str.132, ptr noundef nonnull @.str.3) #4
  br label %98

18:                                               ; preds = %13
  %19 = fcmp ugt float %3, 0.000000e+00
  br i1 %19, label %22, label %20

20:                                               ; preds = %18
  %21 = tail call ptr (ptr, i32, ptr, ...) @liquid_error_config_fl(ptr noundef nonnull @.str.129, i32 noundef 68, ptr noundef nonnull @.str.133, ptr noundef nonnull @.str.3) #4
  br label %98

22:                                               ; preds = %18
  %23 = tail call i32 @liquid_nextpow2(i32 noundef %4) #4
  %24 = add i32 %23, -17
  %or.cond3 = icmp ult i32 %24, -16
  br i1 %or.cond3, label %25, label %27

25:                                               ; preds = %22
  %26 = tail call ptr (ptr, i32, ptr, ...) @liquid_error_config_fl(ptr noundef nonnull @.str.129, i32 noundef 73, ptr noundef nonnull @.str.134, ptr noundef nonnull @.str.3) #4
  br label %98

27:                                               ; preds = %22
  %28 = tail call noalias dereferenceable_or_null(40) ptr @malloc(i64 noundef 40) #5
  %29 = tail call i32 @resamp_cccf_set_rate(ptr noundef %28, float noundef %0)
  store i32 %1, ptr %28, align 8, !tbaa !5
  %30 = getelementptr inbounds i8, ptr %28, i64 8
  store float %2, ptr %30, align 8, !tbaa !12
  %31 = getelementptr inbounds i8, ptr %28, i64 4
  store float %3, ptr %31, align 4, !tbaa !13
  %32 = getelementptr inbounds i8, ptr %28, i64 24
  store i32 %23, ptr %32, align 8, !tbaa !14
  %33 = shl nuw nsw i32 1, %23
  %34 = getelementptr inbounds i8, ptr %28, i64 28
  store i32 %33, ptr %34, align 4, !tbaa !15
  %35 = shl i32 %1, 1
  %36 = shl i32 %35, %23
  %37 = or disjoint i32 %36, 1
  %38 = zext i32 %37 to i64
  %39 = tail call ptr @llvm.stacksave.p0()
  %40 = alloca float, i64 %38, align 16
  %41 = alloca { float, float }, i64 %38, align 16
  %42 = load float, ptr %30, align 8, !tbaa !12
  %43 = load i32, ptr %34, align 4, !tbaa !15
  %44 = uitofp i32 %43 to float
  %45 = fdiv float %42, %44
  %46 = load float, ptr %31, align 4, !tbaa !13
  %47 = call i32 @liquid_firdes_kaiser(i32 noundef %37, float noundef %45, float noundef %46, float noundef 0.000000e+00, ptr noundef nonnull %40) #4
  %48 = or disjoint i32 %36, 1
  %wide.trip.count = zext i32 %48 to i64
  %xtraiter = and i64 %wide.trip.count, 7
  %49 = icmp ult i32 %36, 7
  br i1 %49, label %.epil.preheader, label %.new

.new:                                             ; preds = %27
  %unroll_iter = and i64 %wide.trip.count, 4294967288
  br label %50

50:                                               ; preds = %50, %.new
  %indvars.iv = phi i64 [ 0, %.new ], [ %indvars.iv.next.7, %50 ]
  %.061 = phi float [ 0.000000e+00, %.new ], [ %74, %50 ]
  %niter = phi i64 [ 0, %.new ], [ %niter.next.7, %50 ]
  %51 = getelementptr inbounds float, ptr %40, i64 %indvars.iv
  %52 = load float, ptr %51, align 16, !tbaa !16
  %53 = fadd float %.061, %52
  %indvars.iv.next = or disjoint i64 %indvars.iv, 1
  %54 = getelementptr inbounds float, ptr %40, i64 %indvars.iv.next
  %55 = load float, ptr %54, align 4, !tbaa !16
  %56 = fadd float %53, %55
  %indvars.iv.next.1 = or disjoint i64 %indvars.iv, 2
  %57 = getelementptr inbounds float, ptr %40, i64 %indvars.iv.next.1
  %58 = load float, ptr %57, align 8, !tbaa !16
  %59 = fadd float %56, %58
  %indvars.iv.next.2 = or disjoint i64 %indvars.iv, 3
  %60 = getelementptr inbounds float, ptr %40, i64 %indvars.iv.next.2
  %61 = load float, ptr %60, align 4, !tbaa !16
  %62 = fadd float %59, %61
  %indvars.iv.next.3 = or disjoint i64 %indvars.iv, 4
  %63 = getelementptr inbounds float, ptr %40, i64 %indvars.iv.next.3
  %64 = load float, ptr %63, align 16, !tbaa !16
  %65 = fadd float %62, %64
  %indvars.iv.next.4 = or disjoint i64 %indvars.iv, 5
  %66 = getelementptr inbounds float, ptr %40, i64 %indvars.iv.next.4
  %67 = load float, ptr %66, align 4, !tbaa !16
  %68 = fadd float %65, %67
  %indvars.iv.next.5 = or disjoint i64 %indvars.iv, 6
  %69 = getelementptr inbounds float, ptr %40, i64 %indvars.iv.next.5
  %70 = load float, ptr %69, align 8, !tbaa !16
  %71 = fadd float %68, %70
  %indvars.iv.next.6 = or disjoint i64 %indvars.iv, 7
  %72 = getelementptr inbounds float, ptr %40, i64 %indvars.iv.next.6
  %73 = load float, ptr %72, align 4, !tbaa !16
  %74 = fadd float %71, %73
  %indvars.iv.next.7 = add nuw nsw i64 %indvars.iv, 8
  %niter.next.7 = add i64 %niter, 8
  %niter.ncmp.7 = icmp eq i64 %niter.next.7, %unroll_iter
  br i1 %niter.ncmp.7, label %.epil.preheader, label %50, !llvm.loop !17

.epil.preheader:                                  ; preds = %27, %50
  %indvars.iv.unr = phi i64 [ 0, %27 ], [ %indvars.iv.next.7, %50 ]
  %.061.unr = phi float [ 0.000000e+00, %27 ], [ %74, %50 ]
  br label %75

75:                                               ; preds = %75, %.epil.preheader
  %indvars.iv.epil = phi i64 [ %indvars.iv.unr, %.epil.preheader ], [ %indvars.iv.next.epil, %75 ]
  %.061.epil = phi float [ %.061.unr, %.epil.preheader ], [ %78, %75 ]
  %epil.iter = phi i64 [ 0, %.epil.preheader ], [ %epil.iter.next, %75 ]
  %76 = getelementptr inbounds float, ptr %40, i64 %indvars.iv.epil
  %77 = load float, ptr %76, align 4, !tbaa !16
  %78 = fadd float %.061.epil, %77
  %indvars.iv.next.epil = add nuw nsw i64 %indvars.iv.epil, 1
  %epil.iter.next = add i64 %epil.iter, 1
  %epil.iter.cmp.not = icmp eq i64 %epil.iter.next, %xtraiter
  br i1 %epil.iter.cmp.not, label %.epilog-lcssa, label %75, !llvm.loop !19

.epilog-lcssa:                                    ; preds = %75
  %79 = load i32, ptr %34, align 4, !tbaa !15
  %80 = uitofp i32 %79 to float
  %81 = fdiv float %80, %78
  %min.iters.check = icmp ult i32 %36, 4
  br i1 %min.iters.check, label %scalar.ph.preheader, label %vector.ph

vector.ph:                                        ; preds = %.epilog-lcssa
  %n.vec = and i64 %wide.trip.count, 4294967292
  %broadcast.splatinsert = insertelement <2 x float> poison, float %81, i64 0
  %broadcast.splat = shufflevector <2 x float> %broadcast.splatinsert, <2 x float> poison, <2 x i32> zeroinitializer
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %82 = or disjoint i64 %index, 2
  %83 = getelementptr inbounds float, ptr %40, i64 %index
  %84 = getelementptr inbounds i8, ptr %83, i64 8
  %wide.load = load <2 x float>, ptr %83, align 16, !tbaa !16
  %wide.load69 = load <2 x float>, ptr %84, align 8, !tbaa !16
  %85 = fmul <2 x float> %broadcast.splat, %wide.load
  %86 = fmul <2 x float> %broadcast.splat, %wide.load69
  %87 = getelementptr inbounds { float, float }, ptr %41, i64 %index
  %88 = getelementptr inbounds { float, float }, ptr %41, i64 %82
  %interleaved.vec = shufflevector <2 x float> %85, <2 x float> zeroinitializer, <4 x i32> <i32 0, i32 2, i32 1, i32 3>
  store <4 x float> %interleaved.vec, ptr %87, align 16
  %interleaved.vec70 = shufflevector <2 x float> %86, <2 x float> zeroinitializer, <4 x i32> <i32 0, i32 2, i32 1, i32 3>
  store <4 x float> %interleaved.vec70, ptr %88, align 16
  %index.next = add nuw i64 %index, 4
  %89 = icmp eq i64 %index.next, %n.vec
  br i1 %89, label %scalar.ph.preheader, label %vector.body, !llvm.loop !21

scalar.ph.preheader:                              ; preds = %vector.body, %.epilog-lcssa
  %indvars.iv64.ph = phi i64 [ 0, %.epilog-lcssa ], [ %n.vec, %vector.body ]
  br label %scalar.ph

scalar.ph:                                        ; preds = %scalar.ph.preheader, %scalar.ph
  %indvars.iv64 = phi i64 [ %indvars.iv.next65, %scalar.ph ], [ %indvars.iv64.ph, %scalar.ph.preheader ]
  %90 = getelementptr inbounds float, ptr %40, i64 %indvars.iv64
  %91 = load float, ptr %90, align 4, !tbaa !16
  %92 = fmul float %81, %91
  %93 = getelementptr inbounds { float, float }, ptr %41, i64 %indvars.iv64
  %94 = getelementptr inbounds i8, ptr %93, i64 4
  store float %92, ptr %93, align 8
  store float 0.000000e+00, ptr %94, align 4
  %indvars.iv.next65 = add nuw nsw i64 %indvars.iv64, 1
  %exitcond68 = icmp eq i64 %indvars.iv.next65, %wide.trip.count
  br i1 %exitcond68, label %.loopexit, label %scalar.ph, !llvm.loop !24

.loopexit:                                        ; preds = %scalar.ph
  %95 = call ptr @firpfb_cccf_create(i32 noundef %79, ptr noundef nonnull %41, i32 noundef %36)
  %96 = getelementptr inbounds i8, ptr %28, i64 32
  store ptr %95, ptr %96, align 8, !tbaa !25
  %97 = call i32 @resamp_cccf_reset(ptr noundef nonnull %28)
  call void @llvm.stackrestore.p0(ptr %39)
  br label %98

98:                                               ; preds = %25, %.loopexit, %20, %16, %11, %7
  %.152 = phi ptr [ %8, %7 ], [ %12, %11 ], [ %17, %16 ], [ %21, %20 ], [ %26, %25 ], [ %28, %.loopexit ]
  ret ptr %.152
}

; Function Attrs: nounwind uwtable
declare dso_local i32 @resamp_cccf_reset(ptr noundef) local_unnamed_addr #3

declare i32 @liquid_nextpow2(i32 noundef) local_unnamed_addr #1

; Function Attrs: nounwind uwtable
declare dso_local i32 @resamp_cccf_set_rate(ptr noundef, float noundef) local_unnamed_addr #3

attributes #0 = { mustprogress nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite) "alloc-family"="malloc" "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 = { mustprogress nocallback nofree nosync nounwind willreturn }
attributes #3 = { 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 #4 = { nounwind }
attributes #5 = { nounwind allocsize(0) }

!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 = !{!"resamp_cccf_s", !7, i64 0, !10, i64 4, !10, i64 8, !10, i64 12, !7, i64 16, !7, i64 20, !7, i64 24, !7, i64 28, !11, i64 32}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"float", !8, i64 0}
!11 = !{!"any pointer", !8, i64 0}
!12 = !{!6, !10, i64 8}
!13 = !{!6, !10, i64 4}
!14 = !{!6, !7, i64 24}
!15 = !{!6, !7, i64 28}
!16 = !{!10, !10, i64 0}
!17 = distinct !{!17, !18}
!18 = !{!"llvm.loop.mustprogress"}
!19 = distinct !{!19, !20}
!20 = !{!"llvm.loop.unroll.disable"}
!21 = distinct !{!21, !18, !22, !23}
!22 = !{!"llvm.loop.isvectorized", i32 1}
!23 = !{!"llvm.loop.unroll.runtime.disable"}
!24 = distinct !{!24, !18, !23, !22}
!25 = !{!6, !11, i64 32}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,LCSSAPass,LoopLoadEliminationPass,LoopRotatePass,LoopUnrollPass,LoopVectorizePass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass