; LLVM IR from tanakamasayuki/Arduino_TensorFlowLite_ESP32 :: examples/micro_speech (feature_provider)

; 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.FeatureProvider = type <{ i32, [4 x i8], ptr, i8, [7 x i8] }>

@.str = external hidden unnamed_addr constant [49 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [38 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: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #0

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_ZN15FeatureProvider19PopulateFeatureDataEPN6tflite13ErrorReporterEiiPi(ptr noundef nonnull align 8 dereferenceable(17) %0, ptr noundef %1, i32 noundef %2, i32 noundef %3, ptr noundef %4) #1 align 2 {
  %6 = alloca i32, align 4
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca ptr, align 8
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca i32, align 4
  %20 = alloca ptr, align 8
  %21 = alloca i32, align 4
  %22 = alloca ptr, align 8
  %23 = alloca i32, align 4
  %24 = alloca i32, align 4
  %25 = alloca i32, align 4
  %26 = alloca i32, align 4
  %27 = alloca ptr, align 8
  %28 = alloca i32, align 4
  %29 = alloca ptr, align 8
  %30 = alloca i64, align 8
  %31 = alloca i32, align 4
  store ptr %0, ptr %7, align 8, !tbaa !5
  store ptr %1, ptr %8, align 8, !tbaa !5
  store i32 %2, ptr %9, align 4, !tbaa !9
  store i32 %3, ptr %10, align 4, !tbaa !9
  store ptr %4, ptr %11, align 8, !tbaa !5
  %32 = load ptr, ptr %7, align 8
  %33 = getelementptr inbounds %class.FeatureProvider, ptr %32, i32 0, i32 0
  %34 = load i32, ptr %33, align 8, !tbaa !11
  %35 = icmp ne i32 %34, 1960
  br i1 %35, label %36, label %43

36:                                               ; preds = %5
  br label %37

37:                                               ; preds = %36
  %38 = load ptr, ptr %8, align 8, !tbaa !5
  %39 = getelementptr inbounds %class.FeatureProvider, ptr %32, i32 0, i32 0
  %40 = load i32, ptr %39, align 8, !tbaa !11
  %41 = call noundef i32 (ptr, ptr, ...) @_ZN6tflite13ErrorReporter6ReportEPKcz(ptr noundef nonnull align 8 dereferenceable(8) %38, ptr noundef @.str, i32 noundef %40, i32 noundef 1960)
  br label %42

42:                                               ; preds = %37
  store i32 1, ptr %6, align 4
  br label %188

43:                                               ; preds = %5
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #3
  %44 = load i32, ptr %9, align 4, !tbaa !9
  %45 = sdiv i32 %44, 20
  store i32 %45, ptr %12, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #3
  %46 = load i32, ptr %10, align 4, !tbaa !9
  %47 = sdiv i32 %46, 20
  store i32 %47, ptr %13, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #3
  %48 = load i32, ptr %13, align 4, !tbaa !9
  %49 = load i32, ptr %12, align 4, !tbaa !9
  %50 = sub nsw i32 %48, %49
  store i32 %50, ptr %14, align 4, !tbaa !9
  %51 = getelementptr inbounds %class.FeatureProvider, ptr %32, i32 0, i32 3
  %52 = load i8, ptr %51, align 8, !tbaa !14, !range !15, !noundef !16
  %53 = trunc i8 %52 to i1
  br i1 %53, label %54, label %66

54:                                               ; preds = %43
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #3
  %55 = load ptr, ptr %8, align 8, !tbaa !5
  %56 = call noundef i32 @_Z23InitializeMicroFeaturesPN6tflite13ErrorReporterE(ptr noundef %55)
  store i32 %56, ptr %15, align 4, !tbaa !17
  %57 = load i32, ptr %15, align 4, !tbaa !17
  %58 = icmp ne i32 %57, 0
  br i1 %58, label %59, label %61

59:                                               ; preds = %54
  %60 = load i32, ptr %15, align 4, !tbaa !17
  store i32 %60, ptr %6, align 4
  store i32 1, ptr %16, align 4
  br label %63

61:                                               ; preds = %54
  %62 = getelementptr inbounds %class.FeatureProvider, ptr %32, i32 0, i32 3
  store i8 0, ptr %62, align 8, !tbaa !14
  store i32 49, ptr %14, align 4, !tbaa !9
  store i32 0, ptr %16, align 4
  br label %63

63:                                               ; preds = %61, %59
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #3
  %64 = load i32, ptr %16, align 4
  switch i32 %64, label %187 [
    i32 0, label %65
  ]

65:                                               ; preds = %63
  br label %66

66:                                               ; preds = %65, %43
  %67 = load i32, ptr %14, align 4, !tbaa !9
  %68 = icmp sgt i32 %67, 49
  br i1 %68, label %69, label %70

69:                                               ; preds = %66
  store i32 49, ptr %14, align 4, !tbaa !9
  br label %70

70:                                               ; preds = %69, %66
  %71 = load i32, ptr %14, align 4, !tbaa !9
  %72 = load ptr, ptr %11, align 8, !tbaa !5
  store i32 %71, ptr %72, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #3
  %73 = load i32, ptr %14, align 4, !tbaa !9
  %74 = sub nsw i32 49, %73
  store i32 %74, ptr %17, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #3
  %75 = load i32, ptr %17, align 4, !tbaa !9
  %76 = sub nsw i32 49, %75
  store i32 %76, ptr %18, align 4, !tbaa !9
  %77 = load i32, ptr %17, align 4, !tbaa !9
  %78 = icmp sgt i32 %77, 0
  br i1 %78, label %79, label %123

79:                                               ; preds = %70
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #3
  store i32 0, ptr %19, align 4, !tbaa !9
  br label %80

80:                                               ; preds = %119, %79
  %81 = load i32, ptr %19, align 4, !tbaa !9
  %82 = load i32, ptr %17, align 4, !tbaa !9
  %83 = icmp slt i32 %81, %82
  br i1 %83, label %85, label %84

84:                                               ; preds = %80
  store i32 4, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #3
  br label %122

85:                                               ; preds = %80
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #3
  %86 = getelementptr inbounds %class.FeatureProvider, ptr %32, i32 0, i32 2
  %87 = load ptr, ptr %86, align 8, !tbaa !19
  %88 = load i32, ptr %19, align 4, !tbaa !9
  %89 = mul nsw i32 %88, 40
  %90 = sext i32 %89 to i64
  %91 = getelementptr inbounds i8, ptr %87, i64 %90
  store ptr %91, ptr %20, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #3
  %92 = load i32, ptr %19, align 4, !tbaa !9
  %93 = load i32, ptr %18, align 4, !tbaa !9
  %94 = add nsw i32 %92, %93
  store i32 %94, ptr %21, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #3
  %95 = getelementptr inbounds %class.FeatureProvider, ptr %32, i32 0, i32 2
  %96 = load ptr, ptr %95, align 8, !tbaa !19
  %97 = load i32, ptr %21, align 4, !tbaa !9
  %98 = mul nsw i32 %97, 40
  %99 = sext i32 %98 to i64
  %100 = getelementptr inbounds i8, ptr %96, i64 %99
  store ptr %100, ptr %22, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #3
  store i32 0, ptr %23, align 4, !tbaa !9
  br label %101

101:                                              ; preds = %115, %85
  %102 = load i32, ptr %23, align 4, !tbaa !9
  %103 = icmp slt i32 %102, 40
  br i1 %103, label %105, label %104

104:                                              ; preds = %101
  store i32 7, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #3
  br label %118

105:                                              ; preds = %101
  %106 = load ptr, ptr %22, align 8, !tbaa !5
  %107 = load i32, ptr %23, align 4, !tbaa !9
  %108 = sext i32 %107 to i64
  %109 = getelementptr inbounds i8, ptr %106, i64 %108
  %110 = load i8, ptr %109, align 1, !tbaa !20
  %111 = load ptr, ptr %20, align 8, !tbaa !5
  %112 = load i32, ptr %23, align 4, !tbaa !9
  %113 = sext i32 %112 to i64
  %114 = getelementptr inbounds i8, ptr %111, i64 %113
  store i8 %110, ptr %114, align 1, !tbaa !20
  br label %115

115:                                              ; preds = %105
  %116 = load i32, ptr %23, align 4, !tbaa !9
  %117 = add nsw i32 %116, 1
  store i32 %117, ptr %23, align 4, !tbaa !9
  br label %101, !llvm.loop !21

118:                                              ; preds = %104
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #3
  br label %119

119:                                              ; preds = %118
  %120 = load i32, ptr %19, align 4, !tbaa !9
  %121 = add nsw i32 %120, 1
  store i32 %121, ptr %19, align 4, !tbaa !9
  br label %80, !llvm.loop !23

122:                                              ; preds = %84
  br label %123

123:                                              ; preds = %122, %70
  %124 = load i32, ptr %14, align 4, !tbaa !9
  %125 = icmp sgt i32 %124, 0
  br i1 %125, label %126, label %185

126:                                              ; preds = %123
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #3
  %127 = load i32, ptr %17, align 4, !tbaa !9
  store i32 %127, ptr %24, align 4, !tbaa !9
  br label %128

128:                                              ; preds = %179, %126
  %129 = load i32, ptr %24, align 4, !tbaa !9
  %130 = icmp slt i32 %129, 49
  br i1 %130, label %132, label %131

131:                                              ; preds = %128
  store i32 10, ptr %16, align 4
  br label %182

132:                                              ; preds = %128
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #3
  %133 = load i32, ptr %13, align 4, !tbaa !9
  %134 = sub nsw i32 %133, 49
  %135 = add nsw i32 %134, 1
  %136 = load i32, ptr %24, align 4, !tbaa !9
  %137 = add nsw i32 %135, %136
  store i32 %137, ptr %25, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %26) #3
  %138 = load i32, ptr %25, align 4, !tbaa !9
  %139 = mul nsw i32 %138, 20
  store i32 %139, ptr %26, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %27) #3
  store ptr null, ptr %27, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %28) #3
  store i32 0, ptr %28, align 4, !tbaa !9
  %140 = load ptr, ptr %8, align 8, !tbaa !5
  %141 = load i32, ptr %26, align 4, !tbaa !9
  %142 = icmp sgt i32 %141, 0
  br i1 %142, label %143, label %145

143:                                              ; preds = %132
  %144 = load i32, ptr %26, align 4, !tbaa !9
  br label %146

145:                                              ; preds = %132
  br label %146

146:                                              ; preds = %145, %143
  %147 = phi i32 [ %144, %143 ], [ 0, %145 ]
  %148 = call noundef i32 @_Z15GetAudioSamplesPN6tflite13ErrorReporterEiiPiPPs(ptr noundef %140, i32 noundef %147, i32 noundef 30, ptr noundef %28, ptr noundef %27)
  %149 = load i32, ptr %28, align 4, !tbaa !9
  %150 = icmp slt i32 %149, 512
  br i1 %150, label %151, label %158

151:                                              ; preds = %146
  br label %152

152:                                              ; preds = %151
  %153 = load ptr, ptr %8, align 8, !tbaa !5
  %154 = load i32, ptr %28, align 4, !tbaa !9
  %155 = call noundef i32 (ptr, ptr, ...) @_ZN6tflite13ErrorReporter6ReportEPKcz(ptr noundef nonnull align 8 dereferenceable(8) %153, ptr noundef @.str.1, i32 noundef %154, i32 noundef 512)
  br label %156

156:                                              ; preds = %152
  br label %157

157:                                              ; preds = %156
  store i32 1, ptr %6, align 4
  store i32 1, ptr %16, align 4
  br label %176

158:                                              ; preds = %146
  call void @llvm.lifetime.start.p0(i64 8, ptr %29) #3
  %159 = getelementptr inbounds %class.FeatureProvider, ptr %32, i32 0, i32 2
  %160 = load ptr, ptr %159, align 8, !tbaa !19
  %161 = load i32, ptr %24, align 4, !tbaa !9
  %162 = mul nsw i32 %161, 40
  %163 = sext i32 %162 to i64
  %164 = getelementptr inbounds i8, ptr %160, i64 %163
  store ptr %164, ptr %29, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %30) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %31) #3
  %165 = load ptr, ptr %8, align 8, !tbaa !5
  %166 = load ptr, ptr %27, align 8, !tbaa !5
  %167 = load i32, ptr %28, align 4, !tbaa !9
  %168 = load ptr, ptr %29, align 8, !tbaa !5
  %169 = call noundef i32 @_Z21GenerateMicroFeaturesPN6tflite13ErrorReporterEPKsiiPaPm(ptr noundef %165, ptr noundef %166, i32 noundef %167, i32 noundef 40, ptr noundef %168, ptr noundef %30)
  store i32 %169, ptr %31, align 4, !tbaa !17
  %170 = load i32, ptr %31, align 4, !tbaa !17
  %171 = icmp ne i32 %170, 0
  br i1 %171, label %172, label %174

172:                                              ; preds = %158
  %173 = load i32, ptr %31, align 4, !tbaa !17
  store i32 %173, ptr %6, align 4
  store i32 1, ptr %16, align 4
  br label %175

174:                                              ; preds = %158
  store i32 0, ptr %16, align 4
  br label %175

175:                                              ; preds = %174, %172
  call void @llvm.lifetime.end.p0(i64 4, ptr %31) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #3
  br label %176

176:                                              ; preds = %175, %157
  call void @llvm.lifetime.end.p0(i64 4, ptr %28) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #3
  %177 = load i32, ptr %16, align 4
  switch i32 %177, label %182 [
    i32 0, label %178
  ]

178:                                              ; preds = %176
  br label %179

179:                                              ; preds = %178
  %180 = load i32, ptr %24, align 4, !tbaa !9
  %181 = add nsw i32 %180, 1
  store i32 %181, ptr %24, align 4, !tbaa !9
  br label %128, !llvm.loop !24

182:                                              ; preds = %176, %131
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #3
  %183 = load i32, ptr %16, align 4
  switch i32 %183, label %186 [
    i32 10, label %184
  ]

184:                                              ; preds = %182
  br label %185

185:                                              ; preds = %184, %123
  store i32 0, ptr %6, align 4
  store i32 1, ptr %16, align 4
  br label %186

186:                                              ; preds = %185, %182
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #3
  br label %187

187:                                              ; preds = %186, %63
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #3
  br label %188

188:                                              ; preds = %187, %42
  %189 = load i32, ptr %6, align 4
  ret i32 %189
}

declare noundef i32 @_ZN6tflite13ErrorReporter6ReportEPKcz(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef, ...) #2

declare noundef i32 @_Z23InitializeMicroFeaturesPN6tflite13ErrorReporterE(ptr noundef) #2

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

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

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 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!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 = !{!"int", !7, i64 0}
!11 = !{!12, !10, i64 0}
!12 = !{!"_ZTS15FeatureProvider", !10, i64 0, !6, i64 8, !13, i64 16}
!13 = !{!"bool", !7, i64 0}
!14 = !{!12, !13, i64 16}
!15 = !{i8 0, i8 2}
!16 = !{}
!17 = !{!18, !18, i64 0}
!18 = !{!"_ZTS12TfLiteStatus", !7, i64 0}
!19 = !{!12, !6, i64 8}
!20 = !{!7, !7, i64 0}
!21 = distinct !{!21, !22}
!22 = !{!"llvm.loop.mustprogress"}
!23 = distinct !{!23, !22}
!24 = distinct !{!24, !22}


; 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 [49 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [38 x i8], align 1

; 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
define dso_local noundef i32 @_ZN15FeatureProvider19PopulateFeatureDataEPN6tflite13ErrorReporterEiiPi(ptr nocapture noundef nonnull align 8 dereferenceable(17) %0, ptr noundef %1, i32 noundef %2, i32 noundef %3, ptr nocapture noundef writeonly %4) local_unnamed_addr #1 align 2 {
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca i64, align 8
  %9 = load i32, ptr %0, align 8, !tbaa !5
  %.not = icmp eq i32 %9, 1960
  br i1 %.not, label %12, label %10

10:                                               ; preds = %5
  %11 = tail call noundef i32 (ptr, ptr, ...) @_ZN6tflite13ErrorReporter6ReportEPKcz(ptr noundef nonnull align 8 dereferenceable(8) %1, ptr noundef nonnull @.str, i32 noundef %9, i32 noundef 1960)
  br label %.thread74

12:                                               ; preds = %5
  %.neg = sdiv i32 %2, -20
  %13 = sdiv i32 %3, 20
  %14 = add nsw i32 %13, %.neg
  %15 = getelementptr inbounds i8, ptr %0, i64 16
  %16 = load i8, ptr %15, align 8, !tbaa !12, !range !13, !noundef !14
  %17 = trunc nuw i8 %16 to i1
  br i1 %17, label %18, label %20

18:                                               ; preds = %12
  %19 = tail call noundef i32 @_Z23InitializeMicroFeaturesPN6tflite13ErrorReporterE(ptr noundef %1)
  %.not61 = icmp eq i32 %19, 0
  br i1 %.not61, label %.thread64, label %.thread74

.thread64:                                        ; preds = %18
  store i8 0, ptr %15, align 8, !tbaa !12
  store i32 49, ptr %4, align 4, !tbaa !15
  br label %.loopexit77

20:                                               ; preds = %12
  %spec.store.select = tail call i32 @llvm.smin.i32(i32 %14, i32 49)
  store i32 %spec.store.select, ptr %4, align 4, !tbaa !15
  %21 = sub nsw i32 49, %spec.store.select
  %22 = icmp slt i32 %14, 49
  br i1 %22, label %.lr.ph, label %.loopexit77

.lr.ph:                                           ; preds = %20
  %23 = getelementptr inbounds i8, ptr %0, i64 8
  %24 = sext i32 %spec.store.select to i64
  %25 = tail call i32 @llvm.umax.i32(i32 %21, i32 1)
  %wide.trip.count = zext nneg i32 %25 to i64
  %xtraiter = and i64 %wide.trip.count, 1
  %26 = icmp ult i32 %21, 2
  br i1 %26, label %.loopexit77.loopexit.unr-lcssa, label %.lr.ph.new

.lr.ph.new:                                       ; preds = %.lr.ph
  %unroll_iter = and i64 %wide.trip.count, 2147483646
  br label %27

27:                                               ; preds = %27, %.lr.ph.new
  %indvars.iv = phi i64 [ 0, %.lr.ph.new ], [ %indvars.iv.next.1, %27 ]
  %niter = phi i64 [ 0, %.lr.ph.new ], [ %niter.next.1, %27 ]
  %28 = load ptr, ptr %23, align 8, !tbaa !16
  %29 = mul nuw nsw i64 %indvars.iv, 40
  %30 = getelementptr inbounds i8, ptr %28, i64 %29
  %31 = add nsw i64 %indvars.iv, %24
  %32 = mul nsw i64 %31, 40
  %33 = getelementptr inbounds i8, ptr %28, i64 %32
  %34 = load <16 x i8>, ptr %33, align 1, !tbaa !17
  store <16 x i8> %34, ptr %30, align 1, !tbaa !17
  %35 = getelementptr inbounds i8, ptr %33, i64 16
  %36 = getelementptr inbounds i8, ptr %30, i64 16
  %37 = load <16 x i8>, ptr %35, align 1, !tbaa !17
  store <16 x i8> %37, ptr %36, align 1, !tbaa !17
  %38 = getelementptr inbounds i8, ptr %33, i64 32
  %39 = getelementptr inbounds i8, ptr %30, i64 32
  %40 = load <8 x i8>, ptr %38, align 1, !tbaa !17
  store <8 x i8> %40, ptr %39, align 1, !tbaa !17
  %indvars.iv.next = or disjoint i64 %indvars.iv, 1
  %41 = load ptr, ptr %23, align 8, !tbaa !16
  %42 = mul nuw nsw i64 %indvars.iv.next, 40
  %43 = getelementptr inbounds i8, ptr %41, i64 %42
  %44 = add nsw i64 %indvars.iv.next, %24
  %45 = mul nsw i64 %44, 40
  %46 = getelementptr inbounds i8, ptr %41, i64 %45
  %47 = load <16 x i8>, ptr %46, align 1, !tbaa !17
  store <16 x i8> %47, ptr %43, align 1, !tbaa !17
  %48 = getelementptr inbounds i8, ptr %46, i64 16
  %49 = getelementptr inbounds i8, ptr %43, i64 16
  %50 = load <16 x i8>, ptr %48, align 1, !tbaa !17
  store <16 x i8> %50, ptr %49, align 1, !tbaa !17
  %51 = getelementptr inbounds i8, ptr %46, i64 32
  %52 = getelementptr inbounds i8, ptr %43, i64 32
  %53 = load <8 x i8>, ptr %51, align 1, !tbaa !17
  store <8 x i8> %53, ptr %52, align 1, !tbaa !17
  %indvars.iv.next.1 = add nuw nsw i64 %indvars.iv, 2
  %niter.next.1 = add i64 %niter, 2
  %niter.ncmp.1 = icmp eq i64 %niter.next.1, %unroll_iter
  br i1 %niter.ncmp.1, label %.loopexit77.loopexit.unr-lcssa, label %27, !llvm.loop !18

.loopexit77.loopexit.unr-lcssa:                   ; preds = %27, %.lr.ph
  %indvars.iv.unr = phi i64 [ 0, %.lr.ph ], [ %indvars.iv.next.1, %27 ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %.loopexit77.loopexit, label %.loopexit77.loopexit.epilog-lcssa

.loopexit77.loopexit.epilog-lcssa:                ; preds = %.loopexit77.loopexit.unr-lcssa
  %54 = load ptr, ptr %23, align 8, !tbaa !16
  %55 = mul nuw nsw i64 %indvars.iv.unr, 40
  %56 = getelementptr inbounds i8, ptr %54, i64 %55
  %57 = add nsw i64 %indvars.iv.unr, %24
  %58 = mul nsw i64 %57, 40
  %59 = getelementptr inbounds i8, ptr %54, i64 %58
  %60 = load <16 x i8>, ptr %59, align 1, !tbaa !17
  store <16 x i8> %60, ptr %56, align 1, !tbaa !17
  %61 = getelementptr inbounds i8, ptr %59, i64 16
  %62 = getelementptr inbounds i8, ptr %56, i64 16
  %63 = load <16 x i8>, ptr %61, align 1, !tbaa !17
  store <16 x i8> %63, ptr %62, align 1, !tbaa !17
  %64 = getelementptr inbounds i8, ptr %59, i64 32
  %65 = getelementptr inbounds i8, ptr %56, i64 32
  %66 = load <8 x i8>, ptr %64, align 1, !tbaa !17
  store <8 x i8> %66, ptr %65, align 1, !tbaa !17
  br label %.loopexit77.loopexit

.loopexit77.loopexit:                             ; preds = %.loopexit77.loopexit.unr-lcssa, %.loopexit77.loopexit.epilog-lcssa
  %67 = icmp slt i32 %14, 1
  br label %.loopexit77

.loopexit77:                                      ; preds = %.loopexit77.loopexit, %.thread64, %20
  %68 = phi i32 [ 0, %.thread64 ], [ %21, %20 ], [ %21, %.loopexit77.loopexit ]
  %.15068 = phi i1 [ false, %.thread64 ], [ false, %20 ], [ %67, %.loopexit77.loopexit ]
  %69 = icmp sgt i32 %68, 48
  %or.cond84 = select i1 %.15068, i1 true, i1 %69
  br i1 %or.cond84, label %.thread74, label %.lr.ph83

.lr.ph83:                                         ; preds = %.loopexit77
  %70 = add nsw i32 %13, -48
  %71 = getelementptr inbounds i8, ptr %0, i64 8
  %72 = zext nneg i32 %68 to i64
  br label %73

73:                                               ; preds = %.lr.ph83, %89
  %indvars.iv91 = phi i64 [ %72, %.lr.ph83 ], [ %indvars.iv.next92, %89 ]
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #4
  store ptr null, ptr %6, align 8, !tbaa !20
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %7) #4
  store i32 0, ptr %7, align 4, !tbaa !15
  %74 = trunc i64 %indvars.iv91 to i32
  %75 = add i32 %70, %74
  %76 = mul i32 %75, 20
  %77 = call i32 @llvm.smax.i32(i32 %76, i32 0)
  %78 = call noundef i32 @_Z15GetAudioSamplesPN6tflite13ErrorReporterEiiPiPPs(ptr noundef %1, i32 noundef %77, i32 noundef 30, ptr noundef nonnull %7, ptr noundef nonnull %6)
  %79 = load i32, ptr %7, align 4, !tbaa !15
  %80 = icmp slt i32 %79, 512
  br i1 %80, label %81, label %83

81:                                               ; preds = %73
  %82 = call noundef i32 (ptr, ptr, ...) @_ZN6tflite13ErrorReporter6ReportEPKcz(ptr noundef nonnull align 8 dereferenceable(8) %1, ptr noundef nonnull @.str.1, i32 noundef %79, i32 noundef 512)
  br label %.loopexit

83:                                               ; preds = %73
  %84 = load ptr, ptr %71, align 8, !tbaa !16
  %85 = mul nuw nsw i64 %indvars.iv91, 40
  %86 = getelementptr inbounds i8, ptr %84, i64 %85
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #4
  %87 = load ptr, ptr %6, align 8, !tbaa !20
  %88 = call noundef i32 @_Z21GenerateMicroFeaturesPN6tflite13ErrorReporterEPKsiiPaPm(ptr noundef %1, ptr noundef %87, i32 noundef %79, i32 noundef 40, ptr noundef %86, ptr noundef nonnull %8)
  %.not62 = icmp eq i32 %88, 0
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #4
  br i1 %.not62, label %89, label %.loopexit

89:                                               ; preds = %83
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %7) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #4
  %indvars.iv.next92 = add nuw nsw i64 %indvars.iv91, 1
  %90 = and i64 %indvars.iv.next92, 4294967295
  %exitcond94 = icmp eq i64 %90, 49
  br i1 %exitcond94, label %.thread74, label %73, !llvm.loop !21

.loopexit:                                        ; preds = %83, %81
  %.4.ph = phi i32 [ 1, %81 ], [ %88, %83 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %7) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #4
  br label %.thread74

.thread74:                                        ; preds = %89, %.loopexit77, %.loopexit, %18, %10
  %.8 = phi i32 [ 1, %10 ], [ %.4.ph, %.loopexit ], [ %19, %18 ], [ 0, %.loopexit77 ], [ 0, %89 ]
  ret i32 %.8
}

declare noundef i32 @_ZN6tflite13ErrorReporter6ReportEPKcz(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef, ...) local_unnamed_addr #2

declare noundef i32 @_Z23InitializeMicroFeaturesPN6tflite13ErrorReporterE(ptr noundef) local_unnamed_addr #2

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

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

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.smin.i32(i32, i32) #3

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.smax.i32(i32, i32) #3

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.umax.i32(i32, i32) #3

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 = { "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 speculatable willreturn memory(none) }
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, !7, i64 0}
!6 = !{!"_ZTS15FeatureProvider", !7, i64 0, !10, i64 8, !11, i64 16}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"any pointer", !8, i64 0}
!11 = !{!"bool", !8, i64 0}
!12 = !{!6, !11, i64 16}
!13 = !{i8 0, i8 2}
!14 = !{}
!15 = !{!7, !7, i64 0}
!16 = !{!6, !10, i64 8}
!17 = !{!8, !8, i64 0}
!18 = distinct !{!18, !19}
!19 = !{!"llvm.loop.mustprogress"}
!20 = !{!10, !10, i64 0}
!21 = distinct !{!21, !19}


; Effective O3 passes: BDCEPass,CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,ReassociatePass,SCCPPass,SLPVectorizerPass,SROAPass,SimplifyCFGPass,TailCallElimPass