; LLVM IR from ermig1979/Simd :: src/Simd/SimdBaseSynetConvolution16b.ll (ZN4Simd19SynetConvolution16b9SetParamsEPKfm)

; 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.Simd::SynetConvolution16b" = type { %"struct.Simd::Deletable", %"struct.Simd::ConvParam", %"struct.Simd::Array", %"class.std::__cxx11::basic_string", %"struct.Simd::Array.0", %"struct.Simd::Array.1", %"struct.Simd::Array.1", i8, i8, i8, i64, i64, i64, i64 }
%"struct.Simd::Deletable" = type { ptr }
%"struct.Simd::ConvParam" = type <{ %struct.SimdConvolutionParameters, i32, [4 x i8], i64, i32, [4 x i8] }>
%struct.SimdConvolutionParameters = type { i64, i64, i64, i32, i32, i64, i64, i64, i32, i32, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i32 }
%"struct.Simd::Array" = type { ptr, i64 }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"struct.Simd::Array.0" = type { ptr, i64 }
%"struct.Simd::Array.1" = type { ptr, i64 }

@.str = external hidden unnamed_addr constant [2 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [89 x i8], align 1
@__PRETTY_FUNCTION__._ZN4Simd19SynetConvolution16b9SetParamsEPKfm = 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: alwaysinline mustprogress uwtable
declare dso_local void @_ZN4Simd5ArrayIfE6ResizeEmbm(ptr noundef nonnull align 8 dereferenceable(16), i64 noundef, i1 noundef zeroext, i64 noundef) #1 align 2

; Function Attrs: alwaysinline mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZN4Simd7AlignHiEmm(i64 noundef, i64 noundef) #2

; 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 void @_ZN4Simd19SynetConvolution16b9SetParamsEPKfm(ptr noundef nonnull align 8 dereferenceable(328) %0, ptr noundef %1, i64 noundef %2) #3 align 2 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca i64, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i64, align 8
  %9 = alloca i64, align 8
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  store i64 %2, ptr %6, align 8, !tbaa !9
  %10 = load ptr, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #5
  %11 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 1
  store ptr %11, ptr %7, align 8, !tbaa !5
  %12 = load ptr, ptr %7, align 8, !tbaa !5
  %13 = getelementptr inbounds %struct.SimdConvolutionParameters, ptr %12, i32 0, i32 21
  %14 = load i32, ptr %13, align 8, !tbaa !11
  %15 = icmp eq i32 %14, 2
  br i1 %15, label %21, label %16

16:                                               ; preds = %3
  %17 = load ptr, ptr %7, align 8, !tbaa !5
  %18 = getelementptr inbounds %struct.SimdConvolutionParameters, ptr %17, i32 0, i32 21
  %19 = load i32, ptr %18, align 8, !tbaa !11
  %20 = icmp eq i32 %19, 4
  br i1 %20, label %21, label %28

21:                                               ; preds = %16, %3
  %22 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 6
  %23 = load ptr, ptr %7, align 8, !tbaa !5
  %24 = getelementptr inbounds %struct.SimdConvolutionParameters, ptr %23, i32 0, i32 5
  %25 = load i64, ptr %24, align 8, !tbaa !16
  %26 = load i64, ptr %6, align 8, !tbaa !9
  %27 = call noundef i64 @_ZN4Simd7AlignHiEmm(i64 noundef %25, i64 noundef %26)
  call void @_ZN4Simd5ArrayIfE6ResizeEmbm(ptr noundef nonnull align 8 dereferenceable(16) %22, i64 noundef %27, i1 noundef zeroext true, i64 noundef 8)
  br label %30

28:                                               ; preds = %16
  %29 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 6
  call void @_ZN4Simd5ArrayIfE6ResizeEmbm(ptr noundef nonnull align 8 dereferenceable(16) %29, i64 noundef 2, i1 noundef zeroext true, i64 noundef 8)
  br label %30

30:                                               ; preds = %28, %21
  %31 = load ptr, ptr %7, align 8, !tbaa !5
  %32 = getelementptr inbounds %struct.SimdConvolutionParameters, ptr %31, i32 0, i32 21
  %33 = load i32, ptr %32, align 8, !tbaa !11
  switch i32 %33, label %164 [
    i32 0, label %34
    i32 1, label %43
    i32 2, label %52
    i32 3, label %73
    i32 4, label %88
    i32 5, label %110
    i32 6, label %118
    i32 7, label %133
    i32 8, label %141
    i32 9, label %156
    i32 10, label %165
  ]

34:                                               ; preds = %30
  %35 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 6
  %36 = getelementptr inbounds %"struct.Simd::Array.1", ptr %35, i32 0, i32 0
  %37 = load ptr, ptr %36, align 8, !tbaa !17
  %38 = getelementptr inbounds float, ptr %37, i64 0
  store float 0xC7EFFFFFE0000000, ptr %38, align 4, !tbaa !29
  %39 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 6
  %40 = getelementptr inbounds %"struct.Simd::Array.1", ptr %39, i32 0, i32 0
  %41 = load ptr, ptr %40, align 8, !tbaa !17
  %42 = getelementptr inbounds float, ptr %41, i64 1
  store float 0x47EFFFFFE0000000, ptr %42, align 4, !tbaa !29
  br label %165

43:                                               ; preds = %30
  %44 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 6
  %45 = getelementptr inbounds %"struct.Simd::Array.1", ptr %44, i32 0, i32 0
  %46 = load ptr, ptr %45, align 8, !tbaa !17
  %47 = getelementptr inbounds float, ptr %46, i64 0
  store float 0.000000e+00, ptr %47, align 4, !tbaa !29
  %48 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 6
  %49 = getelementptr inbounds %"struct.Simd::Array.1", ptr %48, i32 0, i32 0
  %50 = load ptr, ptr %49, align 8, !tbaa !17
  %51 = getelementptr inbounds float, ptr %50, i64 1
  store float 0x47EFFFFFE0000000, ptr %51, align 4, !tbaa !29
  br label %165

52:                                               ; preds = %30
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #5
  store i64 0, ptr %8, align 8, !tbaa !9
  br label %53

53:                                               ; preds = %69, %52
  %54 = load i64, ptr %8, align 8, !tbaa !9
  %55 = load ptr, ptr %7, align 8, !tbaa !5
  %56 = getelementptr inbounds %struct.SimdConvolutionParameters, ptr %55, i32 0, i32 5
  %57 = load i64, ptr %56, align 8, !tbaa !16
  %58 = icmp ult i64 %54, %57
  br i1 %58, label %60, label %59

59:                                               ; preds = %53
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #5
  br label %72

60:                                               ; preds = %53
  %61 = load ptr, ptr %5, align 8, !tbaa !5
  %62 = getelementptr inbounds float, ptr %61, i64 0
  %63 = load float, ptr %62, align 4, !tbaa !29
  %64 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 6
  %65 = getelementptr inbounds %"struct.Simd::Array.1", ptr %64, i32 0, i32 0
  %66 = load ptr, ptr %65, align 8, !tbaa !17
  %67 = load i64, ptr %8, align 8, !tbaa !9
  %68 = getelementptr inbounds float, ptr %66, i64 %67
  store float %63, ptr %68, align 4, !tbaa !29
  br label %69

69:                                               ; preds = %60
  %70 = load i64, ptr %8, align 8, !tbaa !9
  %71 = add i64 %70, 1
  store i64 %71, ptr %8, align 8, !tbaa !9
  br label %53, !llvm.loop !31

72:                                               ; preds = %59
  br label %165

73:                                               ; preds = %30
  %74 = load ptr, ptr %5, align 8, !tbaa !5
  %75 = getelementptr inbounds float, ptr %74, i64 0
  %76 = load float, ptr %75, align 4, !tbaa !29
  %77 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 6
  %78 = getelementptr inbounds %"struct.Simd::Array.1", ptr %77, i32 0, i32 0
  %79 = load ptr, ptr %78, align 8, !tbaa !17
  %80 = getelementptr inbounds float, ptr %79, i64 0
  store float %76, ptr %80, align 4, !tbaa !29
  %81 = load ptr, ptr %5, align 8, !tbaa !5
  %82 = getelementptr inbounds float, ptr %81, i64 1
  %83 = load float, ptr %82, align 4, !tbaa !29
  %84 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 6
  %85 = getelementptr inbounds %"struct.Simd::Array.1", ptr %84, i32 0, i32 0
  %86 = load ptr, ptr %85, align 8, !tbaa !17
  %87 = getelementptr inbounds float, ptr %86, i64 1
  store float %83, ptr %87, align 4, !tbaa !29
  br label %165

88:                                               ; preds = %30
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #5
  store i64 0, ptr %9, align 8, !tbaa !9
  br label %89

89:                                               ; preds = %106, %88
  %90 = load i64, ptr %9, align 8, !tbaa !9
  %91 = load ptr, ptr %7, align 8, !tbaa !5
  %92 = getelementptr inbounds %struct.SimdConvolutionParameters, ptr %91, i32 0, i32 5
  %93 = load i64, ptr %92, align 8, !tbaa !16
  %94 = icmp ult i64 %90, %93
  br i1 %94, label %96, label %95

95:                                               ; preds = %89
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  br label %109

96:                                               ; preds = %89
  %97 = load ptr, ptr %5, align 8, !tbaa !5
  %98 = load i64, ptr %9, align 8, !tbaa !9
  %99 = getelementptr inbounds float, ptr %97, i64 %98
  %100 = load float, ptr %99, align 4, !tbaa !29
  %101 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 6
  %102 = getelementptr inbounds %"struct.Simd::Array.1", ptr %101, i32 0, i32 0
  %103 = load ptr, ptr %102, align 8, !tbaa !17
  %104 = load i64, ptr %9, align 8, !tbaa !9
  %105 = getelementptr inbounds float, ptr %103, i64 %104
  store float %100, ptr %105, align 4, !tbaa !29
  br label %106

106:                                              ; preds = %96
  %107 = load i64, ptr %9, align 8, !tbaa !9
  %108 = add i64 %107, 1
  store i64 %108, ptr %9, align 8, !tbaa !9
  br label %89, !llvm.loop !33

109:                                              ; preds = %95
  br label %165

110:                                              ; preds = %30
  %111 = load ptr, ptr %5, align 8, !tbaa !5
  %112 = getelementptr inbounds float, ptr %111, i64 0
  %113 = load float, ptr %112, align 4, !tbaa !29
  %114 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 6
  %115 = getelementptr inbounds %"struct.Simd::Array.1", ptr %114, i32 0, i32 0
  %116 = load ptr, ptr %115, align 8, !tbaa !17
  %117 = getelementptr inbounds float, ptr %116, i64 0
  store float %113, ptr %117, align 4, !tbaa !29
  br label %165

118:                                              ; preds = %30
  %119 = load ptr, ptr %5, align 8, !tbaa !5
  %120 = getelementptr inbounds float, ptr %119, i64 0
  %121 = load float, ptr %120, align 4, !tbaa !29
  %122 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 6
  %123 = getelementptr inbounds %"struct.Simd::Array.1", ptr %122, i32 0, i32 0
  %124 = load ptr, ptr %123, align 8, !tbaa !17
  %125 = getelementptr inbounds float, ptr %124, i64 0
  store float %121, ptr %125, align 4, !tbaa !29
  %126 = load ptr, ptr %5, align 8, !tbaa !5
  %127 = getelementptr inbounds float, ptr %126, i64 1
  %128 = load float, ptr %127, align 4, !tbaa !29
  %129 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 6
  %130 = getelementptr inbounds %"struct.Simd::Array.1", ptr %129, i32 0, i32 0
  %131 = load ptr, ptr %130, align 8, !tbaa !17
  %132 = getelementptr inbounds float, ptr %131, i64 1
  store float %128, ptr %132, align 4, !tbaa !29
  br label %165

133:                                              ; preds = %30
  %134 = load ptr, ptr %5, align 8, !tbaa !5
  %135 = getelementptr inbounds float, ptr %134, i64 0
  %136 = load float, ptr %135, align 4, !tbaa !29
  %137 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 6
  %138 = getelementptr inbounds %"struct.Simd::Array.1", ptr %137, i32 0, i32 0
  %139 = load ptr, ptr %138, align 8, !tbaa !17
  %140 = getelementptr inbounds float, ptr %139, i64 0
  store float %136, ptr %140, align 4, !tbaa !29
  br label %165

141:                                              ; preds = %30
  %142 = load ptr, ptr %5, align 8, !tbaa !5
  %143 = getelementptr inbounds float, ptr %142, i64 0
  %144 = load float, ptr %143, align 4, !tbaa !29
  %145 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 6
  %146 = getelementptr inbounds %"struct.Simd::Array.1", ptr %145, i32 0, i32 0
  %147 = load ptr, ptr %146, align 8, !tbaa !17
  %148 = getelementptr inbounds float, ptr %147, i64 0
  store float %144, ptr %148, align 4, !tbaa !29
  %149 = load ptr, ptr %5, align 8, !tbaa !5
  %150 = getelementptr inbounds float, ptr %149, i64 1
  %151 = load float, ptr %150, align 4, !tbaa !29
  %152 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 6
  %153 = getelementptr inbounds %"struct.Simd::Array.1", ptr %152, i32 0, i32 0
  %154 = load ptr, ptr %153, align 8, !tbaa !17
  %155 = getelementptr inbounds float, ptr %154, i64 1
  store float %151, ptr %155, align 4, !tbaa !29
  br label %165

156:                                              ; preds = %30
  %157 = load ptr, ptr %5, align 8, !tbaa !5
  %158 = getelementptr inbounds float, ptr %157, i64 0
  %159 = load float, ptr %158, align 4, !tbaa !29
  %160 = getelementptr inbounds %"class.Simd::SynetConvolution16b", ptr %10, i32 0, i32 6
  %161 = getelementptr inbounds %"struct.Simd::Array.1", ptr %160, i32 0, i32 0
  %162 = load ptr, ptr %161, align 8, !tbaa !17
  %163 = getelementptr inbounds float, ptr %162, i64 0
  store float %159, ptr %163, align 4, !tbaa !29
  br label %165

164:                                              ; preds = %30
  call void @__assert_fail(ptr noundef @.str, ptr noundef @.str.1, i32 noundef 115, ptr noundef @__PRETTY_FUNCTION__._ZN4Simd19SynetConvolution16b9SetParamsEPKfm) #6
  unreachable

165:                                              ; preds = %156, %141, %133, %118, %110, %109, %73, %72, %43, %34, %30
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  ret void
}

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) #4

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { alwaysinline 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 = { alwaysinline 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 = { 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 #4 = { noreturn nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { nounwind }
attributes #6 = { noreturn 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 = !{!"long", !7, i64 0}
!11 = !{!12, !15, i64 152}
!12 = !{!"_ZTS25SimdConvolutionParameters", !10, i64 0, !10, i64 8, !10, i64 16, !13, i64 24, !14, i64 28, !10, i64 32, !10, i64 40, !10, i64 48, !13, i64 56, !14, i64 60, !10, i64 64, !10, i64 72, !10, i64 80, !10, i64 88, !10, i64 96, !10, i64 104, !10, i64 112, !10, i64 120, !10, i64 128, !10, i64 136, !10, i64 144, !15, i64 152}
!13 = !{!"_ZTS18SimdTensorDataType", !7, i64 0}
!14 = !{!"_ZTS20SimdTensorFormatType", !7, i64 0}
!15 = !{!"_ZTS29SimdConvolutionActivationType", !7, i64 0}
!16 = !{!12, !10, i64 32}
!17 = !{!18, !6, i64 272}
!18 = !{!"_ZTSN4Simd19SynetConvolution16bE", !19, i64 0, !20, i64 8, !23, i64 192, !24, i64 208, !26, i64 240, !27, i64 256, !27, i64 272, !28, i64 288, !28, i64 289, !28, i64 290, !10, i64 296, !10, i64 304, !10, i64 312, !10, i64 320}
!19 = !{!"_ZTSN4Simd9DeletableE"}
!20 = !{!"_ZTSN4Simd9ConvParamE", !12, i64 0, !21, i64 160, !10, i64 168, !22, i64 176}
!21 = !{!"_ZTS8SimdBool", !7, i64 0}
!22 = !{!"_ZTS26SimdSynetCompatibilityType", !7, i64 0}
!23 = !{!"_ZTSN4Simd5ArrayIhEE", !6, i64 0, !10, i64 8}
!24 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !25, i64 0, !10, i64 8, !7, i64 16}
!25 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !6, i64 0}
!26 = !{!"_ZTSN4Simd5ArrayItEE", !6, i64 0, !10, i64 8}
!27 = !{!"_ZTSN4Simd5ArrayIfEE", !6, i64 0, !10, i64 8}
!28 = !{!"bool", !7, i64 0}
!29 = !{!30, !30, i64 0}
!30 = !{!"float", !7, i64 0}
!31 = distinct !{!31, !32}
!32 = !{!"llvm.loop.mustprogress"}
!33 = distinct !{!33, !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 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [89 x i8], align 1
@__PRETTY_FUNCTION__._ZN4Simd19SynetConvolution16b9SetParamsEPKfm = external hidden unnamed_addr constant [65 x i8], align 1

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local void @_ZN4Simd5ArrayIfE6ResizeEmbm(ptr noundef nonnull align 8 dereferenceable(16), i64 noundef, i1 noundef zeroext, i64 noundef) local_unnamed_addr #0 align 2

; Function Attrs: alwaysinline mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZN4Simd7AlignHiEmm(i64 noundef, i64 noundef) local_unnamed_addr #1

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN4Simd19SynetConvolution16b9SetParamsEPKfm(ptr noundef nonnull align 8 dereferenceable(328) %0, ptr nocapture noundef readonly %1, i64 noundef %2) local_unnamed_addr #2 align 2 {
  %4 = ptrtoint ptr %1 to i64
  %5 = getelementptr inbounds i8, ptr %0, i64 160
  %6 = load i32, ptr %5, align 8, !tbaa !5
  switch i32 %6, label %12 [
    i32 2, label %7
    i32 4, label %7
  ]

7:                                                ; preds = %3, %3
  %8 = getelementptr inbounds i8, ptr %0, i64 272
  %9 = getelementptr inbounds i8, ptr %0, i64 40
  %10 = load i64, ptr %9, align 8, !tbaa !13
  %11 = tail call noundef i64 @_ZN4Simd7AlignHiEmm(i64 noundef %10, i64 noundef %2)
  tail call void @_ZN4Simd5ArrayIfE6ResizeEmbm(ptr noundef nonnull align 8 dereferenceable(16) %8, i64 noundef %11, i1 noundef zeroext true, i64 noundef 8)
  br label %14

12:                                               ; preds = %3
  %13 = getelementptr inbounds i8, ptr %0, i64 272
  tail call void @_ZN4Simd5ArrayIfE6ResizeEmbm(ptr noundef nonnull align 8 dereferenceable(16) %13, i64 noundef 2, i1 noundef zeroext true, i64 noundef 8)
  br label %14

14:                                               ; preds = %12, %7
  %15 = load i32, ptr %5, align 8, !tbaa !5
  switch i32 %15, label %97 [
    i32 0, label %40
    i32 1, label %43
    i32 2, label %.preheader
    i32 3, label %48
    i32 4, label %.preheader27
    i32 5, label %71
    i32 6, label %75
    i32 7, label %82
    i32 8, label %86
    i32 9, label %93
    i32 10, label %.loopexit
  ]

.preheader27:                                     ; preds = %14
  %16 = getelementptr inbounds i8, ptr %0, i64 40
  %17 = load i64, ptr %16, align 8, !tbaa !13
  %.not = icmp eq i64 %17, 0
  br i1 %.not, label %.loopexit, label %.lr.ph

.lr.ph:                                           ; preds = %.preheader27
  %18 = getelementptr inbounds i8, ptr %0, i64 272
  %19 = load ptr, ptr %18, align 8, !tbaa !14
  %min.iters.check = icmp ult i64 %17, 8
  %20 = ptrtoint ptr %19 to i64
  %21 = sub i64 %20, %4
  %diff.check = icmp ult i64 %21, 32
  %or.cond = select i1 %min.iters.check, i1 true, i1 %diff.check
  br i1 %or.cond, label %scalar.ph.preheader, label %vector.ph

scalar.ph.preheader:                              ; preds = %middle.block, %.lr.ph
  %.029.ph = phi i64 [ 0, %.lr.ph ], [ %n.vec, %middle.block ]
  %xtraiter = and i64 %17, 3
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %scalar.ph.prol.loopexit, label %scalar.ph.prol

scalar.ph.prol:                                   ; preds = %scalar.ph.preheader, %scalar.ph.prol
  %.029.prol = phi i64 [ %25, %scalar.ph.prol ], [ %.029.ph, %scalar.ph.preheader ]
  %prol.iter = phi i64 [ %prol.iter.next, %scalar.ph.prol ], [ 0, %scalar.ph.preheader ]
  %22 = getelementptr inbounds float, ptr %1, i64 %.029.prol
  %23 = load float, ptr %22, align 4, !tbaa !27
  %24 = getelementptr inbounds float, ptr %19, i64 %.029.prol
  store float %23, ptr %24, align 4, !tbaa !27
  %25 = add nuw i64 %.029.prol, 1
  %prol.iter.next = add i64 %prol.iter, 1
  %prol.iter.cmp.not = icmp eq i64 %prol.iter.next, %xtraiter
  br i1 %prol.iter.cmp.not, label %scalar.ph.prol.loopexit, label %scalar.ph.prol, !llvm.loop !29

scalar.ph.prol.loopexit:                          ; preds = %scalar.ph.prol, %scalar.ph.preheader
  %.029.unr = phi i64 [ %.029.ph, %scalar.ph.preheader ], [ %25, %scalar.ph.prol ]
  %26 = sub i64 %.029.ph, %17
  %27 = icmp ugt i64 %26, -4
  br i1 %27, label %.loopexit, label %scalar.ph

vector.ph:                                        ; preds = %.lr.ph
  %n.vec = and i64 %17, -8
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %28 = getelementptr inbounds float, ptr %1, i64 %index
  %29 = getelementptr inbounds i8, ptr %28, i64 16
  %wide.load = load <4 x float>, ptr %28, align 4, !tbaa !27
  %wide.load37 = load <4 x float>, ptr %29, align 4, !tbaa !27
  %30 = getelementptr inbounds float, ptr %19, i64 %index
  %31 = getelementptr inbounds i8, ptr %30, i64 16
  store <4 x float> %wide.load, ptr %30, align 4, !tbaa !27
  store <4 x float> %wide.load37, ptr %31, align 4, !tbaa !27
  %index.next = add nuw i64 %index, 8
  %32 = icmp eq i64 %index.next, %n.vec
  br i1 %32, label %middle.block, label %vector.body, !llvm.loop !31

middle.block:                                     ; preds = %vector.body
  %cmp.n = icmp eq i64 %17, %n.vec
  br i1 %cmp.n, label %.loopexit, label %scalar.ph.preheader

.preheader:                                       ; preds = %14
  %33 = getelementptr inbounds i8, ptr %0, i64 40
  %34 = load i64, ptr %33, align 8, !tbaa !13
  %.not32 = icmp eq i64 %34, 0
  br i1 %.not32, label %.loopexit, label %.lr.ph31

.lr.ph31:                                         ; preds = %.preheader
  %35 = getelementptr inbounds i8, ptr %0, i64 272
  %36 = load ptr, ptr %35, align 8, !tbaa !14
  %.pre = load float, ptr %1, align 4, !tbaa !27
  %min.iters.check40 = icmp ult i64 %34, 8
  br i1 %min.iters.check40, label %scalar.ph39.preheader, label %vector.ph41

scalar.ph39.preheader:                            ; preds = %middle.block38, %.lr.ph31
  %.02530.ph = phi i64 [ 0, %.lr.ph31 ], [ %n.vec43, %middle.block38 ]
  br label %scalar.ph39

vector.ph41:                                      ; preds = %.lr.ph31
  %n.vec43 = and i64 %34, -8
  %broadcast.splatinsert = insertelement <4 x float> poison, float %.pre, i64 0
  %broadcast.splat = shufflevector <4 x float> %broadcast.splatinsert, <4 x float> poison, <4 x i32> zeroinitializer
  br label %vector.body45

vector.body45:                                    ; preds = %vector.body45, %vector.ph41
  %index46 = phi i64 [ 0, %vector.ph41 ], [ %index.next47, %vector.body45 ]
  %37 = getelementptr inbounds float, ptr %36, i64 %index46
  %38 = getelementptr inbounds i8, ptr %37, i64 16
  store <4 x float> %broadcast.splat, ptr %37, align 4, !tbaa !27
  store <4 x float> %broadcast.splat, ptr %38, align 4, !tbaa !27
  %index.next47 = add nuw i64 %index46, 8
  %39 = icmp eq i64 %index.next47, %n.vec43
  br i1 %39, label %middle.block38, label %vector.body45, !llvm.loop !35

middle.block38:                                   ; preds = %vector.body45
  %cmp.n48 = icmp eq i64 %34, %n.vec43
  br i1 %cmp.n48, label %.loopexit, label %scalar.ph39.preheader

40:                                               ; preds = %14
  %41 = getelementptr inbounds i8, ptr %0, i64 272
  %42 = load ptr, ptr %41, align 8, !tbaa !14
  store <2 x float> <float 0xC7EFFFFFE0000000, float 0x47EFFFFFE0000000>, ptr %42, align 4, !tbaa !27
  br label %.loopexit

43:                                               ; preds = %14
  %44 = getelementptr inbounds i8, ptr %0, i64 272
  %45 = load ptr, ptr %44, align 8, !tbaa !14
  store <2 x float> <float 0.000000e+00, float 0x47EFFFFFE0000000>, ptr %45, align 4, !tbaa !27
  br label %.loopexit

scalar.ph39:                                      ; preds = %scalar.ph39.preheader, %scalar.ph39
  %.02530 = phi i64 [ %47, %scalar.ph39 ], [ %.02530.ph, %scalar.ph39.preheader ]
  %46 = getelementptr inbounds float, ptr %36, i64 %.02530
  store float %.pre, ptr %46, align 4, !tbaa !27
  %47 = add nuw i64 %.02530, 1
  %exitcond34.not = icmp eq i64 %47, %34
  br i1 %exitcond34.not, label %.loopexit, label %scalar.ph39, !llvm.loop !36

48:                                               ; preds = %14
  %49 = load float, ptr %1, align 4, !tbaa !27
  %50 = getelementptr inbounds i8, ptr %0, i64 272
  %51 = load ptr, ptr %50, align 8, !tbaa !14
  store float %49, ptr %51, align 4, !tbaa !27
  %52 = getelementptr inbounds i8, ptr %1, i64 4
  %53 = load float, ptr %52, align 4, !tbaa !27
  %54 = getelementptr inbounds i8, ptr %51, i64 4
  store float %53, ptr %54, align 4, !tbaa !27
  br label %.loopexit

scalar.ph:                                        ; preds = %scalar.ph.prol.loopexit, %scalar.ph
  %.029 = phi i64 [ %70, %scalar.ph ], [ %.029.unr, %scalar.ph.prol.loopexit ]
  %55 = getelementptr inbounds float, ptr %1, i64 %.029
  %56 = load float, ptr %55, align 4, !tbaa !27
  %57 = getelementptr inbounds float, ptr %19, i64 %.029
  store float %56, ptr %57, align 4, !tbaa !27
  %58 = add nuw i64 %.029, 1
  %59 = getelementptr inbounds float, ptr %1, i64 %58
  %60 = load float, ptr %59, align 4, !tbaa !27
  %61 = getelementptr inbounds float, ptr %19, i64 %58
  store float %60, ptr %61, align 4, !tbaa !27
  %62 = add nuw i64 %.029, 2
  %63 = getelementptr inbounds float, ptr %1, i64 %62
  %64 = load float, ptr %63, align 4, !tbaa !27
  %65 = getelementptr inbounds float, ptr %19, i64 %62
  store float %64, ptr %65, align 4, !tbaa !27
  %66 = add nuw i64 %.029, 3
  %67 = getelementptr inbounds float, ptr %1, i64 %66
  %68 = load float, ptr %67, align 4, !tbaa !27
  %69 = getelementptr inbounds float, ptr %19, i64 %66
  store float %68, ptr %69, align 4, !tbaa !27
  %70 = add nuw i64 %.029, 4
  %exitcond.not.3 = icmp eq i64 %70, %17
  br i1 %exitcond.not.3, label %.loopexit, label %scalar.ph, !llvm.loop !37

71:                                               ; preds = %14
  %72 = load float, ptr %1, align 4, !tbaa !27
  %73 = getelementptr inbounds i8, ptr %0, i64 272
  %74 = load ptr, ptr %73, align 8, !tbaa !14
  store float %72, ptr %74, align 4, !tbaa !27
  br label %.loopexit

75:                                               ; preds = %14
  %76 = load float, ptr %1, align 4, !tbaa !27
  %77 = getelementptr inbounds i8, ptr %0, i64 272
  %78 = load ptr, ptr %77, align 8, !tbaa !14
  store float %76, ptr %78, align 4, !tbaa !27
  %79 = getelementptr inbounds i8, ptr %1, i64 4
  %80 = load float, ptr %79, align 4, !tbaa !27
  %81 = getelementptr inbounds i8, ptr %78, i64 4
  store float %80, ptr %81, align 4, !tbaa !27
  br label %.loopexit

82:                                               ; preds = %14
  %83 = load float, ptr %1, align 4, !tbaa !27
  %84 = getelementptr inbounds i8, ptr %0, i64 272
  %85 = load ptr, ptr %84, align 8, !tbaa !14
  store float %83, ptr %85, align 4, !tbaa !27
  br label %.loopexit

86:                                               ; preds = %14
  %87 = load float, ptr %1, align 4, !tbaa !27
  %88 = getelementptr inbounds i8, ptr %0, i64 272
  %89 = load ptr, ptr %88, align 8, !tbaa !14
  store float %87, ptr %89, align 4, !tbaa !27
  %90 = getelementptr inbounds i8, ptr %1, i64 4
  %91 = load float, ptr %90, align 4, !tbaa !27
  %92 = getelementptr inbounds i8, ptr %89, i64 4
  store float %91, ptr %92, align 4, !tbaa !27
  br label %.loopexit

93:                                               ; preds = %14
  %94 = load float, ptr %1, align 4, !tbaa !27
  %95 = getelementptr inbounds i8, ptr %0, i64 272
  %96 = load ptr, ptr %95, align 8, !tbaa !14
  store float %94, ptr %96, align 4, !tbaa !27
  br label %.loopexit

97:                                               ; preds = %14
  tail call void @__assert_fail(ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, i32 noundef 115, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN4Simd19SynetConvolution16b9SetParamsEPKfm) #4
  unreachable

.loopexit:                                        ; preds = %scalar.ph.prol.loopexit, %scalar.ph, %scalar.ph39, %middle.block, %middle.block38, %.preheader27, %.preheader, %93, %86, %82, %75, %71, %48, %43, %40, %14
  ret void
}

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #3

attributes #0 = { alwaysinline 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 #1 = { alwaysinline 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 #2 = { 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 #3 = { noreturn 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 = { noreturn 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, !12, i64 152}
!6 = !{!"_ZTS25SimdConvolutionParameters", !7, i64 0, !7, i64 8, !7, i64 16, !10, i64 24, !11, i64 28, !7, i64 32, !7, i64 40, !7, i64 48, !10, i64 56, !11, i64 60, !7, i64 64, !7, i64 72, !7, i64 80, !7, i64 88, !7, i64 96, !7, i64 104, !7, i64 112, !7, i64 120, !7, i64 128, !7, i64 136, !7, i64 144, !12, i64 152}
!7 = !{!"long", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"_ZTS18SimdTensorDataType", !8, i64 0}
!11 = !{!"_ZTS20SimdTensorFormatType", !8, i64 0}
!12 = !{!"_ZTS29SimdConvolutionActivationType", !8, i64 0}
!13 = !{!6, !7, i64 32}
!14 = !{!15, !21, i64 272}
!15 = !{!"_ZTSN4Simd19SynetConvolution16bE", !16, i64 0, !17, i64 8, !20, i64 192, !22, i64 208, !24, i64 240, !25, i64 256, !25, i64 272, !26, i64 288, !26, i64 289, !26, i64 290, !7, i64 296, !7, i64 304, !7, i64 312, !7, i64 320}
!16 = !{!"_ZTSN4Simd9DeletableE"}
!17 = !{!"_ZTSN4Simd9ConvParamE", !6, i64 0, !18, i64 160, !7, i64 168, !19, i64 176}
!18 = !{!"_ZTS8SimdBool", !8, i64 0}
!19 = !{!"_ZTS26SimdSynetCompatibilityType", !8, i64 0}
!20 = !{!"_ZTSN4Simd5ArrayIhEE", !21, i64 0, !7, i64 8}
!21 = !{!"any pointer", !8, i64 0}
!22 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !23, i64 0, !7, i64 8, !8, i64 16}
!23 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !21, i64 0}
!24 = !{!"_ZTSN4Simd5ArrayItEE", !21, i64 0, !7, i64 8}
!25 = !{!"_ZTSN4Simd5ArrayIfEE", !21, i64 0, !7, i64 8}
!26 = !{!"bool", !8, i64 0}
!27 = !{!28, !28, i64 0}
!28 = !{!"float", !8, i64 0}
!29 = distinct !{!29, !30}
!30 = !{!"llvm.loop.unroll.disable"}
!31 = distinct !{!31, !32, !33, !34}
!32 = !{!"llvm.loop.mustprogress"}
!33 = !{!"llvm.loop.isvectorized", i32 1}
!34 = !{!"llvm.loop.unroll.runtime.disable"}
!35 = distinct !{!35, !32, !33, !34}
!36 = distinct !{!36, !32, !34, !33}
!37 = distinct !{!37, !32, !33}


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