; LLVM IR from sp-nitech/SPTK :: third_party/REAPER/epoch_tracker (epoch_tracker)

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

%"class.sptk::reaper::FFT" = type { ptr, ptr, i32, i32, i32, i32 }

@stderr = external global ptr, align 8
@.str = external hidden unnamed_addr constant [48 x i8], align 1

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIfSaIfEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIfSaIfEEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) #2 align 2

; Function Attrs: nobuiltin nounwind
declare void @_ZdaPv(ptr noundef) #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN4sptk6reaper3FFT25fft_pow2_from_window_sizeEi(i32 noundef) #2 align 2

declare void @_ZN4sptk6reaper3FFTC1Ei(ptr noundef nonnull align 8 dereferenceable(32), i32 noundef) unnamed_addr #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN4sptk6reaper3FFT11get_fftSizeEv(ptr noundef nonnull align 8 dereferenceable(32)) #2 align 2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare { i64, i1 } @llvm.umul.with.overflow.i64(i64, i64) #5

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znam(i64 noundef) #6

declare void @_ZN4sptk6reaper3FFT3fftEPfS2_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef) #4

; Function Attrs: nounwind
declare void @_ZN4sptk6reaper3FFTD1Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #7

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNKSt6vectorIfSaIfEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24)) #2 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden noundef i32 @_ZN4sptk6reaperL7RoundUpEf(float noundef) #8

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4sptk6reaper12EpochTracker6WindowERKSt6vectorIfSaIfEEimPf(ptr noundef nonnull align 8 dereferenceable(500), ptr noundef nonnull align 8 dereferenceable(24), i32 noundef, i64 noundef, ptr noundef) #1 align 2

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_ZN4sptk6reaper12EpochTracker22GetBandpassedRmsSignalERKSt6vectorIfSaIfEEfffffPS4_(ptr noundef nonnull align 8 dereferenceable(500) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, float noundef %2, float noundef %3, float noundef %4, float noundef %5, float noundef %6, ptr noundef %7) #1 align 2 personality ptr @__gxx_personality_v0 {
  %9 = alloca i1, align 1
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca float, align 4
  %13 = alloca float, align 4
  %14 = alloca float, align 4
  %15 = alloca float, align 4
  %16 = alloca float, align 4
  %17 = alloca ptr, align 8
  %18 = alloca i64, align 8
  %19 = alloca i64, align 8
  %20 = alloca i64, align 8
  %21 = alloca i32, align 4
  %22 = alloca %"class.sptk::reaper::FFT", align 8
  %23 = alloca i32, align 4
  %24 = alloca ptr, align 8
  %25 = alloca i32, align 4
  %26 = alloca i32, align 4
  %27 = alloca i32, align 4
  %28 = alloca ptr, align 8
  %29 = alloca ptr, align 8
  %30 = alloca i64, align 8
  %31 = alloca i64, align 8
  %32 = alloca i64, align 8
  %33 = alloca i32, align 4
  %34 = alloca float, align 4
  %35 = alloca i64, align 8
  store ptr %0, ptr %10, align 8, !tbaa !5
  store ptr %1, ptr %11, align 8, !tbaa !5
  store float %2, ptr %12, align 4, !tbaa !9
  store float %3, ptr %13, align 4, !tbaa !9
  store float %4, ptr %14, align 4, !tbaa !9
  store float %5, ptr %15, align 4, !tbaa !9
  store float %6, ptr %16, align 4, !tbaa !9
  store ptr %7, ptr %17, align 8, !tbaa !5
  %36 = load ptr, ptr %10, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #9
  %37 = load float, ptr %12, align 4, !tbaa !9
  %38 = load float, ptr %15, align 4, !tbaa !9
  %39 = fmul float %37, %38
  %40 = call noundef i32 @_ZN4sptk6reaperL7RoundUpEf(float noundef %39)
  %41 = sext i32 %40 to i64
  store i64 %41, ptr %18, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #9
  %42 = load float, ptr %12, align 4, !tbaa !9
  %43 = load float, ptr %16, align 4, !tbaa !9
  %44 = fmul float %42, %43
  %45 = call noundef i32 @_ZN4sptk6reaperL7RoundUpEf(float noundef %44)
  %46 = sext i32 %45 to i64
  store i64 %46, ptr %19, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #9
  %47 = load ptr, ptr %11, align 8, !tbaa !5
  %48 = call noundef i64 @_ZNKSt6vectorIfSaIfEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %47) #9
  %49 = load i64, ptr %19, align 8, !tbaa !11
  %50 = sub i64 %48, %49
  %51 = load i64, ptr %18, align 8, !tbaa !11
  %52 = udiv i64 %50, %51
  %53 = add i64 1, %52
  store i64 %53, ptr %20, align 8, !tbaa !11
  %54 = load i64, ptr %20, align 8, !tbaa !11
  %55 = icmp ult i64 %54, 2
  br i1 %55, label %56, label %63

56:                                               ; preds = %8
  %57 = load ptr, ptr @stderr, align 8, !tbaa !5
  %58 = load ptr, ptr %11, align 8, !tbaa !5
  %59 = call noundef i64 @_ZNKSt6vectorIfSaIfEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %58) #9
  %60 = trunc i64 %59 to i32
  %61 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %57, ptr noundef @.str, i32 noundef %60) #9
  %62 = load ptr, ptr %17, align 8, !tbaa !5
  call void @_ZNSt6vectorIfSaIfEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %62, i64 noundef 0)
  store i1 false, ptr %9, align 1
  store i32 1, ptr %21, align 4
  br label %250

63:                                               ; preds = %8
  %64 = load ptr, ptr %17, align 8, !tbaa !5
  %65 = load i64, ptr %20, align 8, !tbaa !11
  call void @_ZNSt6vectorIfSaIfEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %64, i64 noundef %65)
  call void @llvm.lifetime.start.p0(i64 32, ptr %22) #9
  %66 = load i64, ptr %19, align 8, !tbaa !11
  %67 = trunc i64 %66 to i32
  %68 = call noundef i32 @_ZN4sptk6reaper3FFT25fft_pow2_from_window_sizeEi(i32 noundef %67)
  call void @_ZN4sptk6reaper3FFTC1Ei(ptr noundef nonnull align 8 dereferenceable(32) %22, i32 noundef %68)
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #9
  %69 = invoke noundef i32 @_ZN4sptk6reaper3FFT11get_fftSizeEv(ptr noundef nonnull align 8 dereferenceable(32) %22)
          to label %70 unwind label %116

70:                                               ; preds = %63
  store i32 %69, ptr %23, align 4, !tbaa !13
  call void @llvm.lifetime.start.p0(i64 4, ptr %26) #9
  %71 = load i32, ptr %23, align 4, !tbaa !13
  %72 = sitofp i32 %71 to float
  %73 = load float, ptr %13, align 4, !tbaa !9
  %74 = fmul float %72, %73
  %75 = load float, ptr %12, align 4, !tbaa !9
  %76 = fdiv float %74, %75
  %77 = invoke noundef i32 @_ZN4sptk6reaperL7RoundUpEf(float noundef %76)
          to label %78 unwind label %120

78:                                               ; preds = %70
  store i32 %77, ptr %26, align 4, !tbaa !13
  call void @llvm.lifetime.start.p0(i64 4, ptr %27) #9
  %79 = load i32, ptr %23, align 4, !tbaa !13
  %80 = sitofp i32 %79 to float
  %81 = load float, ptr %14, align 4, !tbaa !9
  %82 = fmul float %80, %81
  %83 = load float, ptr %12, align 4, !tbaa !9
  %84 = fdiv float %82, %83
  %85 = invoke noundef i32 @_ZN4sptk6reaperL7RoundUpEf(float noundef %84)
          to label %86 unwind label %124

86:                                               ; preds = %78
  store i32 %85, ptr %27, align 4, !tbaa !13
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #9
  %87 = load i32, ptr %23, align 4, !tbaa !13
  %88 = sext i32 %87 to i64
  %89 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %88, i64 4)
  %90 = extractvalue { i64, i1 } %89, 1
  %91 = extractvalue { i64, i1 } %89, 0
  %92 = select i1 %90, i64 -1, i64 %91
  %93 = invoke noalias noundef nonnull ptr @_Znam(i64 noundef %92) #10
          to label %94 unwind label %128

94:                                               ; preds = %86
  store ptr %93, ptr %28, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %29) #9
  %95 = load i32, ptr %23, align 4, !tbaa !13
  %96 = sext i32 %95 to i64
  %97 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %96, i64 4)
  %98 = extractvalue { i64, i1 } %97, 1
  %99 = extractvalue { i64, i1 } %97, 0
  %100 = select i1 %98, i64 -1, i64 %99
  %101 = invoke noalias noundef nonnull ptr @_Znam(i64 noundef %100) #10
          to label %102 unwind label %132

102:                                              ; preds = %94
  store ptr %101, ptr %29, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %30) #9
  %103 = load i64, ptr %19, align 8, !tbaa !11
  %104 = load i64, ptr %18, align 8, !tbaa !11
  %105 = mul i64 2, %104
  %106 = udiv i64 %103, %105
  store i64 %106, ptr %30, align 8, !tbaa !11
  %107 = load i64, ptr %30, align 8, !tbaa !11
  %108 = mul i64 %107, 2
  %109 = load i64, ptr %18, align 8, !tbaa !11
  %110 = mul i64 %108, %109
  %111 = load i64, ptr %19, align 8, !tbaa !11
  %112 = icmp ult i64 %110, %111
  br i1 %112, label %113, label %136

113:                                              ; preds = %102
  %114 = load i64, ptr %30, align 8, !tbaa !11
  %115 = add i64 %114, 1
  store i64 %115, ptr %30, align 8, !tbaa !11
  br label %136

116:                                              ; preds = %63
  %117 = landingpad { ptr, i32 }
          cleanup
  %118 = extractvalue { ptr, i32 } %117, 0
  store ptr %118, ptr %24, align 8
  %119 = extractvalue { ptr, i32 } %117, 1
  store i32 %119, ptr %25, align 4
  br label %249

120:                                              ; preds = %70
  %121 = landingpad { ptr, i32 }
          cleanup
  %122 = extractvalue { ptr, i32 } %121, 0
  store ptr %122, ptr %24, align 8
  %123 = extractvalue { ptr, i32 } %121, 1
  store i32 %123, ptr %25, align 4
  br label %248

124:                                              ; preds = %78
  %125 = landingpad { ptr, i32 }
          cleanup
  %126 = extractvalue { ptr, i32 } %125, 0
  store ptr %126, ptr %24, align 8
  %127 = extractvalue { ptr, i32 } %125, 1
  store i32 %127, ptr %25, align 4
  br label %247

128:                                              ; preds = %86
  %129 = landingpad { ptr, i32 }
          cleanup
  %130 = extractvalue { ptr, i32 } %129, 0
  store ptr %130, ptr %24, align 8
  %131 = extractvalue { ptr, i32 } %129, 1
  store i32 %131, ptr %25, align 4
  br label %246

132:                                              ; preds = %94
  %133 = landingpad { ptr, i32 }
          cleanup
  %134 = extractvalue { ptr, i32 } %133, 0
  store ptr %134, ptr %24, align 8
  %135 = extractvalue { ptr, i32 } %133, 1
  store i32 %135, ptr %25, align 4
  br label %245

136:                                              ; preds = %113, %102
  call void @llvm.lifetime.start.p0(i64 8, ptr %31) #9
  %137 = load i64, ptr %30, align 8, !tbaa !11
  store i64 %137, ptr %31, align 8, !tbaa !11
  br label %138

138:                                              ; preds = %232, %136
  %139 = load i64, ptr %31, align 8, !tbaa !11
  %140 = load i64, ptr %20, align 8, !tbaa !11
  %141 = icmp ult i64 %139, %140
  br i1 %141, label %143, label %142

142:                                              ; preds = %138
  store i32 2, ptr %21, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #9
  br label %236

143:                                              ; preds = %138
  %144 = load ptr, ptr %11, align 8, !tbaa !5
  %145 = load i64, ptr %31, align 8, !tbaa !11
  %146 = load i64, ptr %30, align 8, !tbaa !11
  %147 = sub i64 %145, %146
  %148 = load i64, ptr %18, align 8, !tbaa !11
  %149 = mul i64 %147, %148
  %150 = trunc i64 %149 to i32
  %151 = load i64, ptr %19, align 8, !tbaa !11
  %152 = load ptr, ptr %28, align 8, !tbaa !5
  invoke void @_ZN4sptk6reaper12EpochTracker6WindowERKSt6vectorIfSaIfEEimPf(ptr noundef nonnull align 8 dereferenceable(500) %36, ptr noundef nonnull align 8 dereferenceable(24) %144, i32 noundef %150, i64 noundef %151, ptr noundef %152)
          to label %153 unwind label %159

153:                                              ; preds = %143
  call void @llvm.lifetime.start.p0(i64 8, ptr %32) #9
  store i64 0, ptr %32, align 8, !tbaa !11
  br label %154

154:                                              ; preds = %167, %153
  %155 = load i64, ptr %32, align 8, !tbaa !11
  %156 = load i64, ptr %19, align 8, !tbaa !11
  %157 = icmp ult i64 %155, %156
  br i1 %157, label %163, label %158

158:                                              ; preds = %154
  store i32 5, ptr %21, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #9
  br label %170

159:                                              ; preds = %190, %143
  %160 = landingpad { ptr, i32 }
          cleanup
  %161 = extractvalue { ptr, i32 } %160, 0
  store ptr %161, ptr %24, align 8
  %162 = extractvalue { ptr, i32 } %160, 1
  store i32 %162, ptr %25, align 4
  br label %235

163:                                              ; preds = %154
  %164 = load ptr, ptr %29, align 8, !tbaa !5
  %165 = load i64, ptr %32, align 8, !tbaa !11
  %166 = getelementptr inbounds float, ptr %164, i64 %165
  store float 0.000000e+00, ptr %166, align 4, !tbaa !9
  br label %167

167:                                              ; preds = %163
  %168 = load i64, ptr %32, align 8, !tbaa !11
  %169 = add i64 %168, 1
  store i64 %169, ptr %32, align 8, !tbaa !11
  br label %154, !llvm.loop !15

170:                                              ; preds = %158
  call void @llvm.lifetime.start.p0(i64 4, ptr %33) #9
  %171 = load i64, ptr %19, align 8, !tbaa !11
  %172 = trunc i64 %171 to i32
  store i32 %172, ptr %33, align 4, !tbaa !13
  br label %173

173:                                              ; preds = %187, %170
  %174 = load i32, ptr %33, align 4, !tbaa !13
  %175 = load i32, ptr %23, align 4, !tbaa !13
  %176 = icmp slt i32 %174, %175
  br i1 %176, label %178, label %177

177:                                              ; preds = %173
  store i32 8, ptr %21, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %33) #9
  br label %190

178:                                              ; preds = %173
  %179 = load ptr, ptr %29, align 8, !tbaa !5
  %180 = load i32, ptr %33, align 4, !tbaa !13
  %181 = sext i32 %180 to i64
  %182 = getelementptr inbounds float, ptr %179, i64 %181
  store float 0.000000e+00, ptr %182, align 4, !tbaa !9
  %183 = load ptr, ptr %28, align 8, !tbaa !5
  %184 = load i32, ptr %33, align 4, !tbaa !13
  %185 = sext i32 %184 to i64
  %186 = getelementptr inbounds float, ptr %183, i64 %185
  store float 0.000000e+00, ptr %186, align 4, !tbaa !9
  br label %187

187:                                              ; preds = %178
  %188 = load i32, ptr %33, align 4, !tbaa !13
  %189 = add nsw i32 %188, 1
  store i32 %189, ptr %33, align 4, !tbaa !13
  br label %173, !llvm.loop !17

190:                                              ; preds = %177
  %191 = load ptr, ptr %28, align 8, !tbaa !5
  %192 = load ptr, ptr %29, align 8, !tbaa !5
  invoke void @_ZN4sptk6reaper3FFT3fftEPfS2_(ptr noundef nonnull align 8 dereferenceable(32) %22, ptr noundef %191, ptr noundef %192)
          to label %193 unwind label %159

193:                                              ; preds = %190
  call void @llvm.lifetime.start.p0(i64 4, ptr %34) #9
  %194 = load ptr, ptr %28, align 8, !tbaa !5
  %195 = load ptr, ptr %29, align 8, !tbaa !5
  %196 = load i32, ptr %26, align 4, !tbaa !13
  %197 = load i32, ptr %27, align 4, !tbaa !13
  %198 = invoke noundef float @_ZN4sptk6reaper3FFT12get_band_rmsEPfS2_ii(ptr noundef nonnull align 8 dereferenceable(32) %22, ptr noundef %194, ptr noundef %195, i32 noundef %196, i32 noundef %197)
          to label %199 unwind label %218

199:                                              ; preds = %193
  %200 = fpext float %198 to double
  %201 = fadd double 1.000000e+00, %200
  %202 = call double @log10(double noundef %201) #9
  %203 = fmul double 2.000000e+01, %202
  %204 = fptrunc double %203 to float
  store float %204, ptr %34, align 4, !tbaa !9
  %205 = load float, ptr %34, align 4, !tbaa !9
  %206 = load ptr, ptr %17, align 8, !tbaa !5
  %207 = load i64, ptr %31, align 8, !tbaa !11
  %208 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIfSaIfEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %206, i64 noundef %207) #9
  store float %205, ptr %208, align 4, !tbaa !9
  %209 = load i64, ptr %31, align 8, !tbaa !11
  %210 = load i64, ptr %30, align 8, !tbaa !11
  %211 = icmp eq i64 %209, %210
  br i1 %211, label %212, label %231

212:                                              ; preds = %199
  call void @llvm.lifetime.start.p0(i64 8, ptr %35) #9
  store i64 0, ptr %35, align 8, !tbaa !11
  br label %213

213:                                              ; preds = %227, %212
  %214 = load i64, ptr %35, align 8, !tbaa !11
  %215 = load i64, ptr %30, align 8, !tbaa !11
  %216 = icmp ult i64 %214, %215
  br i1 %216, label %222, label %217

217:                                              ; preds = %213
  store i32 11, ptr %21, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %35) #9
  br label %230

218:                                              ; preds = %193
  %219 = landingpad { ptr, i32 }
          cleanup
  %220 = extractvalue { ptr, i32 } %219, 0
  store ptr %220, ptr %24, align 8
  %221 = extractvalue { ptr, i32 } %219, 1
  store i32 %221, ptr %25, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %34) #9
  br label %235

222:                                              ; preds = %213
  %223 = load float, ptr %34, align 4, !tbaa !9
  %224 = load ptr, ptr %17, align 8, !tbaa !5
  %225 = load i64, ptr %35, align 8, !tbaa !11
  %226 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIfSaIfEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %224, i64 noundef %225) #9
  store float %223, ptr %226, align 4, !tbaa !9
  br label %227

227:                                              ; preds = %222
  %228 = load i64, ptr %35, align 8, !tbaa !11
  %229 = add i64 %228, 1
  store i64 %229, ptr %35, align 8, !tbaa !11
  br label %213, !llvm.loop !18

230:                                              ; preds = %217
  br label %231

231:                                              ; preds = %230, %199
  call void @llvm.lifetime.end.p0(i64 4, ptr %34) #9
  br label %232

232:                                              ; preds = %231
  %233 = load i64, ptr %31, align 8, !tbaa !11
  %234 = add i64 %233, 1
  store i64 %234, ptr %31, align 8, !tbaa !11
  br label %138, !llvm.loop !19

235:                                              ; preds = %218, %159
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #9
  br label %245

236:                                              ; preds = %142
  %237 = load ptr, ptr %28, align 8, !tbaa !5
  %238 = icmp eq ptr %237, null
  br i1 %238, label %240, label %239

239:                                              ; preds = %236
  call void @_ZdaPv(ptr noundef %237) #11
  br label %240

240:                                              ; preds = %239, %236
  %241 = load ptr, ptr %29, align 8, !tbaa !5
  %242 = icmp eq ptr %241, null
  br i1 %242, label %244, label %243

243:                                              ; preds = %240
  call void @_ZdaPv(ptr noundef %241) #11
  br label %244

244:                                              ; preds = %243, %240
  store i1 true, ptr %9, align 1
  store i32 1, ptr %21, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #9
  call void @_ZN4sptk6reaper3FFTD1Ev(ptr noundef nonnull align 8 dereferenceable(32) %22) #9
  call void @llvm.lifetime.end.p0(i64 32, ptr %22) #9
  br label %250

245:                                              ; preds = %235, %132
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #9
  br label %246

246:                                              ; preds = %245, %128
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #9
  br label %247

247:                                              ; preds = %246, %124
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #9
  br label %248

248:                                              ; preds = %247, %120
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #9
  br label %249

249:                                              ; preds = %248, %116
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #9
  call void @_ZN4sptk6reaper3FFTD1Ev(ptr noundef nonnull align 8 dereferenceable(32) %22) #9
  call void @llvm.lifetime.end.p0(i64 32, ptr %22) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #9
  br label %252

250:                                              ; preds = %244, %56
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #9
  %251 = load i1, ptr %9, align 1
  ret i1 %251

252:                                              ; preds = %249
  %253 = load ptr, ptr %24, align 8
  %254 = load i32, ptr %25, align 4
  %255 = insertvalue { ptr, i32 } poison, ptr %253, 0
  %256 = insertvalue { ptr, i32 } %255, i32 %254, 1
  resume { ptr, i32 } %256
}

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

; Function Attrs: nounwind
declare double @log10(double noundef) #7

declare noundef float @_ZN4sptk6reaper3FFT12get_band_rmsEPfS2_ii(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef, i32 noundef, i32 noundef) #4

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { mustprogress 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 #3 = { nobuiltin 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 = { "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 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #6 = { nobuiltin 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 #7 = { 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 #8 = { inlinehint mustprogress 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 #9 = { nounwind }
attributes #10 = { builtin allocsize(0) }
attributes #11 = { builtin nounwind }

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

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


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

%"class.sptk::reaper::FFT" = type { ptr, ptr, i32, i32, i32, i32 }

@stderr = external local_unnamed_addr global ptr, align 8
@.str = external hidden unnamed_addr constant [48 x i8], align 1

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIfSaIfEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIfSaIfEEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #2 align 2

; Function Attrs: nobuiltin nounwind
declare void @_ZdaPv(ptr noundef) local_unnamed_addr #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN4sptk6reaper3FFT25fft_pow2_from_window_sizeEi(i32 noundef) local_unnamed_addr #2 align 2

declare void @_ZN4sptk6reaper3FFTC1Ei(ptr noundef nonnull align 8 dereferenceable(32), i32 noundef) unnamed_addr #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN4sptk6reaper3FFT11get_fftSizeEv(ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #2 align 2

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znam(i64 noundef) local_unnamed_addr #5

declare void @_ZN4sptk6reaper3FFT3fftEPfS2_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef) local_unnamed_addr #4

; Function Attrs: nounwind
declare void @_ZN4sptk6reaper3FFTD1Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #6

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNKSt6vectorIfSaIfEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden noundef i32 @_ZN4sptk6reaperL7RoundUpEf(float noundef) local_unnamed_addr #7

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4sptk6reaper12EpochTracker6WindowERKSt6vectorIfSaIfEEimPf(ptr noundef nonnull align 8 dereferenceable(500), ptr noundef nonnull align 8 dereferenceable(24), i32 noundef, i64 noundef, ptr noundef) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_ZN4sptk6reaper12EpochTracker22GetBandpassedRmsSignalERKSt6vectorIfSaIfEEfffffPS4_(ptr noundef nonnull align 8 dereferenceable(500) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, float noundef %2, float noundef %3, float noundef %4, float noundef %5, float noundef %6, ptr noundef %7) local_unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %9 = alloca %"class.sptk::reaper::FFT", align 8
  %10 = fmul float %2, %5
  %11 = tail call noundef i32 @_ZN4sptk6reaperL7RoundUpEf(float noundef %10)
  %12 = sext i32 %11 to i64
  %13 = fmul float %2, %6
  %14 = tail call noundef i32 @_ZN4sptk6reaperL7RoundUpEf(float noundef %13)
  %15 = sext i32 %14 to i64
  %16 = tail call noundef i64 @_ZNKSt6vectorIfSaIfEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #11
  %17 = sub i64 %16, %15
  %18 = udiv i64 %17, %12
  %19 = add i64 %18, 1
  %20 = icmp ugt i64 %19, 1
  br i1 %20, label %26, label %21

21:                                               ; preds = %8
  %22 = load ptr, ptr @stderr, align 8, !tbaa !5
  %23 = tail call noundef i64 @_ZNKSt6vectorIfSaIfEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #11
  %24 = trunc i64 %23 to i32
  %25 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %22, ptr noundef nonnull @.str, i32 noundef %24) #12
  tail call void @_ZNSt6vectorIfSaIfEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef 0)
  br label %85

26:                                               ; preds = %8
  tail call void @_ZNSt6vectorIfSaIfEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %19)
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %9) #11
  %27 = tail call noundef i32 @_ZN4sptk6reaper3FFT25fft_pow2_from_window_sizeEi(i32 noundef %14)
  call void @_ZN4sptk6reaper3FFTC1Ei(ptr noundef nonnull align 8 dereferenceable(32) %9, i32 noundef %27)
  %28 = call noundef i32 @_ZN4sptk6reaper3FFT11get_fftSizeEv(ptr noundef nonnull align 8 dereferenceable(32) %9)
  %29 = sitofp i32 %28 to float
  %30 = fmul float %29, %3
  %31 = fdiv float %30, %2
  %32 = call noundef i32 @_ZN4sptk6reaperL7RoundUpEf(float noundef %31)
  %33 = fmul float %29, %4
  %34 = fdiv float %33, %2
  %35 = call noundef i32 @_ZN4sptk6reaperL7RoundUpEf(float noundef %34)
  %36 = zext nneg i32 %28 to i64
  %37 = icmp slt i32 %28, 0
  %38 = shl nuw nsw i64 %36, 2
  %39 = select i1 %37, i64 -1, i64 %38
  %40 = invoke noalias noundef nonnull ptr @_Znam(i64 noundef %39) #13
          to label %41 unwind label %57

41:                                               ; preds = %26
  %42 = invoke noalias noundef nonnull ptr @_Znam(i64 noundef %39) #13
          to label %43 unwind label %59

43:                                               ; preds = %41
  %44 = shl nsw i64 %12, 1
  %45 = udiv i64 %15, %44
  %46 = mul i64 %44, %45
  %47 = icmp ult i64 %46, %15
  %48 = zext i1 %47 to i64
  %spec.select = add i64 %45, %48
  %49 = icmp ult i64 %spec.select, %19
  br i1 %49, label %.lr.ph94, label %._crit_edge95

.lr.ph94:                                         ; preds = %43
  %.not97 = icmp eq i32 %14, 0
  %50 = icmp slt i32 %14, %28
  %.not98 = icmp eq i64 %spec.select, 0
  %51 = shl nuw nsw i64 %15, 2
  %scevgep = getelementptr i8, ptr %42, i64 %51
  %52 = xor i32 %14, -1
  %53 = add i32 %28, %52
  %54 = zext i32 %53 to i64
  %55 = shl nuw nsw i64 %54, 2
  %56 = add nuw nsw i64 %55, 4
  %scevgep99 = getelementptr i8, ptr %40, i64 %51
  br label %61

57:                                               ; preds = %26
  %58 = landingpad { ptr, i32 }
          cleanup
  br label %84

59:                                               ; preds = %41
  %60 = landingpad { ptr, i32 }
          cleanup
  br label %84

61:                                               ; preds = %.lr.ph94, %.loopexit
  %.07592 = phi i64 [ %spec.select, %.lr.ph94 ], [ %82, %.loopexit ]
  %62 = sub nuw i64 %.07592, %spec.select
  %63 = trunc i64 %62 to i32
  %64 = mul i32 %11, %63
  invoke void @_ZN4sptk6reaper12EpochTracker6WindowERKSt6vectorIfSaIfEEimPf(ptr noundef nonnull align 8 dereferenceable(500) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, i32 noundef %64, i64 noundef %15, ptr noundef nonnull %40)
          to label %.preheader86 unwind label %65

.preheader86:                                     ; preds = %61
  br i1 %.not97, label %.preheader85, label %.lr.ph.preheader

.lr.ph.preheader:                                 ; preds = %.preheader86
  call void @llvm.memset.p0.i64(ptr nonnull align 4 %42, i8 0, i64 %51, i1 false), !tbaa !9
  br label %.preheader85

.preheader85:                                     ; preds = %.lr.ph.preheader, %.preheader86
  br i1 %50, label %.lr.ph89.preheader, label %._crit_edge

.lr.ph89.preheader:                               ; preds = %.preheader85
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 4 dereferenceable(1) %scevgep, i8 0, i64 %56, i1 false), !tbaa !9
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 4 dereferenceable(1) %scevgep99, i8 0, i64 %56, i1 false), !tbaa !9
  br label %._crit_edge

65:                                               ; preds = %._crit_edge, %61
  %66 = landingpad { ptr, i32 }
          cleanup
  br label %84

._crit_edge:                                      ; preds = %.lr.ph89.preheader, %.preheader85
  invoke void @_ZN4sptk6reaper3FFT3fftEPfS2_(ptr noundef nonnull align 8 dereferenceable(32) %9, ptr noundef nonnull %40, ptr noundef nonnull %42)
          to label %67 unwind label %65

67:                                               ; preds = %._crit_edge
  %68 = invoke noundef float @_ZN4sptk6reaper3FFT12get_band_rmsEPfS2_ii(ptr noundef nonnull align 8 dereferenceable(32) %9, ptr noundef nonnull %40, ptr noundef nonnull %42, i32 noundef %32, i32 noundef %35)
          to label %69 unwind label %77

69:                                               ; preds = %67
  %70 = fpext float %68 to double
  %71 = fadd double %70, 1.000000e+00
  %72 = call double @log10(double noundef %71) #11
  %73 = fmul double %72, 2.000000e+01
  %74 = fptrunc double %73 to float
  %75 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIfSaIfEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %.07592) #11
  store float %74, ptr %75, align 4, !tbaa !9
  %76 = icmp ne i64 %.07592, %spec.select
  %brmerge = or i1 %76, %.not98
  br i1 %brmerge, label %.loopexit, label %.lr.ph91

77:                                               ; preds = %67
  %78 = landingpad { ptr, i32 }
          cleanup
  br label %84

.lr.ph91:                                         ; preds = %69, %.lr.ph91
  %.090 = phi i64 [ %80, %.lr.ph91 ], [ 0, %69 ]
  %79 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIfSaIfEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %.090) #11
  store float %74, ptr %79, align 4, !tbaa !9
  %80 = add nuw i64 %.090, 1
  %81 = icmp ult i64 %80, %spec.select
  br i1 %81, label %.lr.ph91, label %.loopexit, !llvm.loop !11

.loopexit:                                        ; preds = %.lr.ph91, %69
  %82 = add nuw i64 %.07592, 1
  %83 = icmp ult i64 %82, %19
  br i1 %83, label %61, label %._crit_edge95, !llvm.loop !13

._crit_edge95:                                    ; preds = %.loopexit, %43
  call void @_ZdaPv(ptr noundef nonnull %40) #14
  call void @_ZdaPv(ptr noundef nonnull %42) #14
  call void @_ZN4sptk6reaper3FFTD1Ev(ptr noundef nonnull align 8 dereferenceable(32) %9) #11
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %9) #11
  br label %85

84:                                               ; preds = %59, %77, %65, %57
  %.pn.pn.pn = phi { ptr, i32 } [ %58, %57 ], [ %60, %59 ], [ %78, %77 ], [ %66, %65 ]
  call void @_ZN4sptk6reaper3FFTD1Ev(ptr noundef nonnull align 8 dereferenceable(32) %9) #11
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %9) #11
  resume { ptr, i32 } %.pn.pn.pn

85:                                               ; preds = %._crit_edge95, %21
  ret i1 %20
}

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

; Function Attrs: mustprogress nofree nounwind willreturn memory(write)
declare double @log10(double noundef) local_unnamed_addr #9

declare noundef float @_ZN4sptk6reaper3FFT12get_band_rmsEPfS2_ii(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef, i32 noundef, i32 noundef) local_unnamed_addr #4

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

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { mustprogress 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 #3 = { nobuiltin 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 = { "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 = { nobuiltin 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 #6 = { 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 #7 = { inlinehint mustprogress 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 #8 = { 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 #9 = { mustprogress nofree nounwind willreturn memory(write) "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 #10 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #11 = { nounwind }
attributes #12 = { cold nounwind }
attributes #13 = { builtin allocsize(0) }
attributes #14 = { builtin nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"float", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}


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