; LLVM IR from NVIDIA/TensorRT :: plugin/skipLayerNormPlugin (skipLayerNormInt8InterleavedPlugin)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"struct.nvinfer1::PluginTensorDesc" = type { %"class.nvinfer1::Dims64", i32, i32, float }
%"class.nvinfer1::Dims64" = type { i32, [8 x i64] }
%"class.nvinfer1::plugin::bert::SkipLayerNormInterleavedPluginBase" = type <{ %"class.nvinfer1::v_1_0::IPluginV3", %"class.nvinfer1::v_1_0::IPluginV3OneCore", %"class.nvinfer1::v_1_0::IPluginV3OneBuild", %"class.nvinfer1::v_1_0::IPluginV3OneRuntime", ptr, %"class.std::__cxx11::basic_string", %"class.std::vector", %"struct.nvinfer1::PluginFieldCollection", %"struct.nvinfer1::plugin::bert::WeightsWithOwnership", %"struct.nvinfer1::plugin::bert::WeightsWithOwnership", %"class.std::unique_ptr", %"class.std::unique_ptr", i64, i64, i8, [7 x i8] }>
%"class.nvinfer1::v_1_0::IPluginV3" = type { %"class.nvinfer1::IVersionedInterface" }
%"class.nvinfer1::IVersionedInterface" = type { ptr }
%"class.nvinfer1::v_1_0::IPluginV3OneCore" = type { %"class.nvinfer1::v_1_0::IPluginCapability" }
%"class.nvinfer1::v_1_0::IPluginCapability" = type { %"class.nvinfer1::IVersionedInterface" }
%"class.nvinfer1::v_1_0::IPluginV3OneBuild" = type { %"class.nvinfer1::v_1_0::IPluginCapability" }
%"class.nvinfer1::v_1_0::IPluginV3OneRuntime" = type { %"class.nvinfer1::v_1_0::IPluginCapability" }
%"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] }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<nvinfer1::PluginField, std::allocator<nvinfer1::PluginField>>::_Vector_impl" }
%"struct.std::_Vector_base<nvinfer1::PluginField, std::allocator<nvinfer1::PluginField>>::_Vector_impl" = type { %"struct.std::_Vector_base<nvinfer1::PluginField, std::allocator<nvinfer1::PluginField>>::_Vector_impl_data" }
%"struct.std::_Vector_base<nvinfer1::PluginField, std::allocator<nvinfer1::PluginField>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.nvinfer1::PluginFieldCollection" = type { i32, ptr }
%"struct.nvinfer1::plugin::bert::WeightsWithOwnership" = type { %"class.nvinfer1::Weights" }
%"class.nvinfer1::Weights" = type { i32, ptr, i64 }
%"class.std::unique_ptr" = type { %"struct.std::__uniq_ptr_data" }
%"struct.std::__uniq_ptr_data" = type { %"class.std::__uniq_ptr_impl" }
%"class.std::__uniq_ptr_impl" = type { %"class.std::tuple" }
%"class.std::tuple" = type { %"struct.std::_Tuple_impl" }
%"struct.std::_Tuple_impl" = type { %"struct.std::_Head_base.5" }
%"struct.std::_Head_base.5" = type { ptr }

@.str = external hidden unnamed_addr constant [115 x i8], align 1
@_ZTISt9exception = external constant ptr
@__func__._ZN8nvinfer16plugin4bert35SkipLayerNormInterleavedPluginHFace7enqueueEPKNS_16PluginTensorDescES5_PKPKvPKPvSA_P11CUstream_st = external hidden unnamed_addr constant [8 x i8], align 1
@.str.23 = external hidden unnamed_addr constant [89 x i8], align 1

declare i32 @__gxx_personality_v0(...)

; Function Attrs: noreturn
declare void @_ZN8nvinfer16plugin16throwPluginErrorEPKcS2_iiS2_(ptr noundef, ptr noundef, i32 noundef, i32 noundef, ptr noundef) #0

; Function Attrs: nounwind memory(none)
declare i32 @llvm.eh.typeid.for.p0(ptr) #1

; Function Attrs: noinline noreturn nounwind uwtable
declare hidden void @__clang_call_terminate(ptr noundef) #2

declare ptr @__cxa_begin_catch(ptr)

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN8nvinfer16plugin11caughtErrorERKSt9exception(ptr noundef nonnull align 8 dereferenceable(8)) #4

declare void @__cxa_end_catch()

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

; Function Attrs: mustprogress nounwind uwtable
define dso_local noundef i32 @_ZN8nvinfer16plugin4bert35SkipLayerNormInterleavedPluginHFace7enqueueEPKNS_16PluginTensorDescES5_PKPKvPKPvSA_P11CUstream_st(ptr noundef nonnull align 8 dereferenceable(193) %0, ptr noundef %1, ptr noundef %2, ptr noundef %3, ptr noundef %4, ptr noundef %5, ptr noundef %6) unnamed_addr #5 align 2 personality ptr @__gxx_personality_v0 {
  %8 = alloca i32, align 4
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  %15 = alloca ptr, align 8
  %16 = alloca ptr, align 8
  %17 = alloca i32, align 4
  %18 = alloca %"struct.nvinfer1::PluginTensorDesc", align 8
  %19 = alloca %"struct.nvinfer1::PluginTensorDesc", align 8
  %20 = alloca %"struct.nvinfer1::PluginTensorDesc", align 8
  %21 = alloca i32, align 4
  %22 = alloca i32, align 4
  %23 = alloca float, align 4
  %24 = alloca float, align 4
  %25 = alloca float, align 4
  %26 = alloca ptr, align 8
  %27 = alloca ptr, align 8
  %28 = alloca ptr, align 8
  %29 = alloca ptr, align 8
  %30 = alloca ptr, align 8
  %31 = alloca i32, align 4
  %32 = alloca ptr, align 8
  store ptr %0, ptr %9, align 8, !tbaa !5
  store ptr %1, ptr %10, align 8, !tbaa !5
  store ptr %2, ptr %11, align 8, !tbaa !5
  store ptr %3, ptr %12, align 8, !tbaa !5
  store ptr %4, ptr %13, align 8, !tbaa !5
  store ptr %5, ptr %14, align 8, !tbaa !5
  store ptr %6, ptr %15, align 8, !tbaa !5
  %33 = load ptr, ptr %9, align 8
  %34 = load ptr, ptr %10, align 8, !tbaa !5
  %35 = icmp ne ptr %34, null
  br i1 %35, label %36, label %45

36:                                               ; preds = %7
  %37 = load ptr, ptr %11, align 8, !tbaa !5
  %38 = icmp ne ptr %37, null
  br i1 %38, label %39, label %45

39:                                               ; preds = %36
  %40 = load ptr, ptr %12, align 8, !tbaa !5
  %41 = icmp ne ptr %40, null
  br i1 %41, label %42, label %45

42:                                               ; preds = %39
  %43 = load ptr, ptr %13, align 8, !tbaa !5
  %44 = icmp ne ptr %43, null
  br i1 %44, label %51, label %45

45:                                               ; preds = %42, %39, %36, %7
  invoke void @_ZN8nvinfer16plugin16throwPluginErrorEPKcS2_iiS2_(ptr noundef @.str, ptr noundef @__func__._ZN8nvinfer16plugin4bert35SkipLayerNormInterleavedPluginHFace7enqueueEPKNS_16PluginTensorDescES5_PKPKvPKPvSA_P11CUstream_st, i32 noundef 283, i32 noundef 0, ptr noundef @.str.23) #9
          to label %46 unwind label %47

46:                                               ; preds = %45
  unreachable

47:                                               ; preds = %45
  %48 = landingpad { ptr, i32 }
          catch ptr @_ZTISt9exception
          catch ptr null
  %49 = extractvalue { ptr, i32 } %48, 0
  store ptr %49, ptr %16, align 8
  %50 = extractvalue { ptr, i32 } %48, 1
  store i32 %50, ptr %17, align 4
  br label %129

51:                                               ; preds = %42
  call void @llvm.lifetime.start.p0(i64 88, ptr %18) #10
  %52 = load ptr, ptr %10, align 8, !tbaa !5
  %53 = getelementptr inbounds %"struct.nvinfer1::PluginTensorDesc", ptr %52, i64 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %18, ptr align 8 %53, i64 88, i1 false), !tbaa.struct !9
  call void @llvm.lifetime.start.p0(i64 88, ptr %19) #10
  %54 = load ptr, ptr %10, align 8, !tbaa !5
  %55 = getelementptr inbounds %"struct.nvinfer1::PluginTensorDesc", ptr %54, i64 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %19, ptr align 8 %55, i64 88, i1 false), !tbaa.struct !9
  call void @llvm.lifetime.start.p0(i64 88, ptr %20) #10
  %56 = load ptr, ptr %11, align 8, !tbaa !5
  %57 = getelementptr inbounds %"struct.nvinfer1::PluginTensorDesc", ptr %56, i64 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %20, ptr align 8 %57, i64 88, i1 false), !tbaa.struct !9
  invoke void @_ZN12_GLOBAL__N_110checkDescsERKN8nvinfer116PluginTensorDescES3_S3_(ptr noundef nonnull align 8 dereferenceable(88) %18, ptr noundef nonnull align 8 dereferenceable(88) %19, ptr noundef nonnull align 8 dereferenceable(88) %20)
          to label %58 unwind label %105

58:                                               ; preds = %51
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #10
  %59 = getelementptr inbounds %"struct.nvinfer1::PluginTensorDesc", ptr %18, i32 0, i32 0
  %60 = getelementptr inbounds %"class.nvinfer1::Dims64", ptr %59, i32 0, i32 1
  %61 = getelementptr inbounds [8 x i64], ptr %60, i64 0, i64 1
  %62 = load i64, ptr %61, align 8, !tbaa !19
  %63 = trunc i64 %62 to i32
  store i32 %63, ptr %21, align 4, !tbaa !10
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #10
  %64 = getelementptr inbounds %"struct.nvinfer1::PluginTensorDesc", ptr %18, i32 0, i32 0
  %65 = getelementptr inbounds %"class.nvinfer1::Dims64", ptr %64, i32 0, i32 1
  %66 = getelementptr inbounds [8 x i64], ptr %65, i64 0, i64 2
  %67 = load i64, ptr %66, align 8, !tbaa !19
  %68 = trunc i64 %67 to i32
  store i32 %68, ptr %22, align 4, !tbaa !10
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #10
  %69 = getelementptr inbounds %"struct.nvinfer1::PluginTensorDesc", ptr %18, i32 0, i32 3
  %70 = load float, ptr %69, align 8, !tbaa !21
  store float %70, ptr %23, align 4, !tbaa !17
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #10
  %71 = getelementptr inbounds %"struct.nvinfer1::PluginTensorDesc", ptr %19, i32 0, i32 3
  %72 = load float, ptr %71, align 8, !tbaa !21
  store float %72, ptr %24, align 4, !tbaa !17
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #10
  %73 = getelementptr inbounds %"struct.nvinfer1::PluginTensorDesc", ptr %20, i32 0, i32 3
  %74 = load float, ptr %73, align 8, !tbaa !21
  %75 = fdiv float 1.000000e+00, %74
  store float %75, ptr %25, align 4, !tbaa !17
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #10
  %76 = load ptr, ptr %12, align 8, !tbaa !5
  %77 = getelementptr inbounds ptr, ptr %76, i64 0
  %78 = load ptr, ptr %77, align 8, !tbaa !5
  store ptr %78, ptr %26, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %27) #10
  %79 = load ptr, ptr %12, align 8, !tbaa !5
  %80 = getelementptr inbounds ptr, ptr %79, i64 1
  %81 = load ptr, ptr %80, align 8, !tbaa !5
  store ptr %81, ptr %27, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #10
  %82 = load ptr, ptr %13, align 8, !tbaa !5
  %83 = getelementptr inbounds ptr, ptr %82, i64 0
  %84 = load ptr, ptr %83, align 8, !tbaa !5
  store ptr %84, ptr %28, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %29) #10
  %85 = getelementptr inbounds %"class.nvinfer1::plugin::bert::SkipLayerNormInterleavedPluginBase", ptr %33, i32 0, i32 10
  %86 = call noundef ptr @_ZNKSt10unique_ptrIvN8nvinfer114pluginInternal11CudaDeleterIvEEE3getEv(ptr noundef nonnull align 8 dereferenceable(8) %85) #10
  store ptr %86, ptr %29, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %30) #10
  %87 = getelementptr inbounds %"class.nvinfer1::plugin::bert::SkipLayerNormInterleavedPluginBase", ptr %33, i32 0, i32 11
  %88 = call noundef ptr @_ZNKSt10unique_ptrIvN8nvinfer114pluginInternal11CudaDeleterIvEEE3getEv(ptr noundef nonnull align 8 dereferenceable(8) %87) #10
  store ptr %88, ptr %30, align 8, !tbaa !5
  %89 = load i32, ptr %22, align 4, !tbaa !10
  %90 = icmp slt i32 %89, 4096
  br i1 %90, label %91, label %113

91:                                               ; preds = %58
  %92 = load ptr, ptr %15, align 8, !tbaa !5
  %93 = load i32, ptr %21, align 4, !tbaa !10
  %94 = load i32, ptr %22, align 4, !tbaa !10
  %95 = load ptr, ptr %26, align 8, !tbaa !5
  %96 = load ptr, ptr %27, align 8, !tbaa !5
  %97 = load ptr, ptr %30, align 8, !tbaa !5
  %98 = load ptr, ptr %29, align 8, !tbaa !5
  %99 = load ptr, ptr %28, align 8, !tbaa !5
  %100 = load float, ptr %23, align 4, !tbaa !17
  %101 = load float, ptr %24, align 4, !tbaa !17
  %102 = load float, ptr %25, align 4, !tbaa !17
  %103 = invoke noundef i32 @_ZN8nvinfer16plugin4bert18launch_small_hfaceEP11CUstream_stiiPKaS5_PK6__halfS8_Pafff(ptr noundef %92, i32 noundef %93, i32 noundef %94, ptr noundef %95, ptr noundef %96, ptr noundef %97, ptr noundef %98, ptr noundef %99, float noundef %100, float noundef %101, float noundef %102)
          to label %104 unwind label %109

104:                                              ; preds = %91
  store i32 %103, ptr %8, align 4
  store i32 1, ptr %31, align 4
  br label %127

105:                                              ; preds = %51
  %106 = landingpad { ptr, i32 }
          catch ptr @_ZTISt9exception
          catch ptr null
  %107 = extractvalue { ptr, i32 } %106, 0
  store ptr %107, ptr %16, align 8
  %108 = extractvalue { ptr, i32 } %106, 1
  store i32 %108, ptr %17, align 4
  br label %128

109:                                              ; preds = %113, %91
  %110 = landingpad { ptr, i32 }
          catch ptr @_ZTISt9exception
          catch ptr null
  %111 = extractvalue { ptr, i32 } %110, 0
  store ptr %111, ptr %16, align 8
  %112 = extractvalue { ptr, i32 } %110, 1
  store i32 %112, ptr %17, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #10
  br label %128

113:                                              ; preds = %58
  %114 = load ptr, ptr %15, align 8, !tbaa !5
  %115 = load i32, ptr %21, align 4, !tbaa !10
  %116 = load i32, ptr %22, align 4, !tbaa !10
  %117 = load ptr, ptr %26, align 8, !tbaa !5
  %118 = load ptr, ptr %27, align 8, !tbaa !5
  %119 = load ptr, ptr %30, align 8, !tbaa !5
  %120 = load ptr, ptr %29, align 8, !tbaa !5
  %121 = load ptr, ptr %28, align 8, !tbaa !5
  %122 = load float, ptr %23, align 4, !tbaa !17
  %123 = load float, ptr %24, align 4, !tbaa !17
  %124 = load float, ptr %25, align 4, !tbaa !17
  %125 = invoke noundef i32 @_ZN8nvinfer16plugin4bert18launch_large_hfaceEP11CUstream_stiiPKaS5_PK6__halfS8_Pafff(ptr noundef %114, i32 noundef %115, i32 noundef %116, ptr noundef %117, ptr noundef %118, ptr noundef %119, ptr noundef %120, ptr noundef %121, float noundef %122, float noundef %123, float noundef %124)
          to label %126 unwind label %109

126:                                              ; preds = %113
  store i32 %125, ptr %8, align 4
  store i32 1, ptr %31, align 4
  br label %127

127:                                              ; preds = %126, %104
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #10
  call void @llvm.lifetime.end.p0(i64 88, ptr %20) #10
  call void @llvm.lifetime.end.p0(i64 88, ptr %19) #10
  call void @llvm.lifetime.end.p0(i64 88, ptr %18) #10
  br label %140

128:                                              ; preds = %109, %105
  call void @llvm.lifetime.end.p0(i64 88, ptr %20) #10
  call void @llvm.lifetime.end.p0(i64 88, ptr %19) #10
  call void @llvm.lifetime.end.p0(i64 88, ptr %18) #10
  br label %129

129:                                              ; preds = %128, %47
  %130 = load i32, ptr %17, align 4
  %131 = call i32 @llvm.eh.typeid.for.p0(ptr @_ZTISt9exception) #10
  %132 = icmp eq i32 %130, %131
  br i1 %132, label %133, label %145

133:                                              ; preds = %129
  call void @llvm.lifetime.start.p0(i64 8, ptr %32) #10
  %134 = load ptr, ptr %16, align 8
  %135 = call ptr @__cxa_begin_catch(ptr %134) #10
  store ptr %135, ptr %32, align 8
  %136 = load ptr, ptr %32, align 8, !tbaa !5
  invoke void @_ZN8nvinfer16plugin11caughtErrorERKSt9exception(ptr noundef nonnull align 8 dereferenceable(8) %136)
          to label %137 unwind label %142

137:                                              ; preds = %133
  invoke void @__cxa_end_catch()
          to label %138 unwind label %142

138:                                              ; preds = %137
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #10
  br label %139

139:                                              ; preds = %138
  store i32 -1, ptr %8, align 4
  br label %140

140:                                              ; preds = %139, %127
  %141 = load i32, ptr %8, align 4
  ret i32 %141

142:                                              ; preds = %137, %133
  %143 = landingpad { ptr, i32 }
          catch ptr null
  %144 = extractvalue { ptr, i32 } %143, 0
  call void @__clang_call_terminate(ptr %144) #11
  unreachable

145:                                              ; preds = %129
  %146 = load ptr, ptr %16, align 8
  call void @__clang_call_terminate(ptr %146) #11
  unreachable
}

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #6

; Function Attrs: mustprogress uwtable
declare hidden void @_ZN12_GLOBAL__N_110checkDescsERKN8nvinfer116PluginTensorDescES3_S3_(ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 8 dereferenceable(88)) #7

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

declare noundef i32 @_ZN8nvinfer16plugin4bert18launch_small_hfaceEP11CUstream_stiiPKaS5_PK6__halfS8_Pafff(ptr noundef, i32 noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, float noundef, float noundef, float noundef) #8

declare noundef i32 @_ZN8nvinfer16plugin4bert18launch_large_hfaceEP11CUstream_stiiPKaS5_PK6__halfS8_Pafff(ptr noundef, i32 noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, float noundef, float noundef, float noundef) #8

attributes #0 = { noreturn "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 = { nounwind memory(none) }
attributes #2 = { noinline noreturn nounwind uwtable "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { inlinehint 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 #5 = { 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 #6 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #7 = { 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 #8 = { "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 = { noreturn }
attributes #10 = { nounwind }
attributes #11 = { 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 = !{i64 0, i64 4, !10, i64 8, i64 64, !12, i64 72, i64 4, !13, i64 76, i64 4, !15, i64 80, i64 4, !17}
!10 = !{!11, !11, i64 0}
!11 = !{!"int", !7, i64 0}
!12 = !{!7, !7, i64 0}
!13 = !{!14, !14, i64 0}
!14 = !{!"_ZTSN8nvinfer18DataTypeE", !7, i64 0}
!15 = !{!16, !16, i64 0}
!16 = !{!"_ZTSN8nvinfer112TensorFormatE", !7, i64 0}
!17 = !{!18, !18, i64 0}
!18 = !{!"float", !7, i64 0}
!19 = !{!20, !20, i64 0}
!20 = !{!"long", !7, i64 0}
!21 = !{!22, !18, i64 80}
!22 = !{!"_ZTSN8nvinfer116PluginTensorDescE", !23, i64 0, !14, i64 72, !16, i64 76, !18, i64 80}
!23 = !{!"_ZTSN8nvinfer16Dims64E", !11, i64 0, !7, i64 8}


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

%"struct.nvinfer1::PluginTensorDesc" = type { %"class.nvinfer1::Dims64", i32, i32, float }
%"class.nvinfer1::Dims64" = type { i32, [8 x i64] }

@.str = external hidden unnamed_addr constant [115 x i8], align 1
@_ZTISt9exception = external constant ptr
@__func__._ZN8nvinfer16plugin4bert35SkipLayerNormInterleavedPluginHFace7enqueueEPKNS_16PluginTensorDescES5_PKPKvPKPvSA_P11CUstream_st = external hidden unnamed_addr constant [8 x i8], align 1
@.str.23 = external hidden unnamed_addr constant [89 x i8], align 1

declare i32 @__gxx_personality_v0(...)

; Function Attrs: noreturn
declare void @_ZN8nvinfer16plugin16throwPluginErrorEPKcS2_iiS2_(ptr noundef, ptr noundef, i32 noundef, i32 noundef, ptr noundef) local_unnamed_addr #0

; Function Attrs: nofree nosync nounwind memory(none)
declare i32 @llvm.eh.typeid.for.p0(ptr) #1

; Function Attrs: noinline noreturn nounwind uwtable
declare hidden void @__clang_call_terminate(ptr noundef) local_unnamed_addr #2

declare ptr @__cxa_begin_catch(ptr) local_unnamed_addr

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN8nvinfer16plugin11caughtErrorERKSt9exception(ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #4

declare void @__cxa_end_catch() local_unnamed_addr

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

; Function Attrs: mustprogress nounwind uwtable
define dso_local noundef i32 @_ZN8nvinfer16plugin4bert35SkipLayerNormInterleavedPluginHFace7enqueueEPKNS_16PluginTensorDescES5_PKPKvPKPvSA_P11CUstream_st(ptr noundef nonnull align 8 dereferenceable(193) %0, ptr noundef readonly %1, ptr noundef readonly %2, ptr noundef readonly %3, ptr noundef readonly %4, ptr nocapture noundef readnone %5, ptr noundef %6) unnamed_addr #5 align 2 personality ptr @__gxx_personality_v0 {
  %8 = alloca %"struct.nvinfer1::PluginTensorDesc", align 8
  %9 = alloca %"struct.nvinfer1::PluginTensorDesc", align 8
  %10 = alloca %"struct.nvinfer1::PluginTensorDesc", align 8
  %11 = insertelement <4 x ptr> poison, ptr %1, i64 0
  %12 = insertelement <4 x ptr> %11, ptr %2, i64 1
  %13 = insertelement <4 x ptr> %12, ptr %3, i64 2
  %14 = insertelement <4 x ptr> %13, ptr %4, i64 3
  %15 = icmp eq <4 x ptr> %14, zeroinitializer
  %16 = bitcast <4 x i1> %15 to i4
  %17 = icmp eq i4 %16, 0
  br i1 %17, label %22, label %18

18:                                               ; preds = %7
  invoke void @_ZN8nvinfer16plugin16throwPluginErrorEPKcS2_iiS2_(ptr noundef nonnull @.str, ptr noundef nonnull @__func__._ZN8nvinfer16plugin4bert35SkipLayerNormInterleavedPluginHFace7enqueueEPKNS_16PluginTensorDescES5_PKPKvPKPvSA_P11CUstream_st, i32 noundef 283, i32 noundef 0, ptr noundef nonnull @.str.23) #9
          to label %19 unwind label %20

19:                                               ; preds = %18
  unreachable

20:                                               ; preds = %18
  %21 = landingpad { ptr, i32 }
          catch ptr @_ZTISt9exception
          catch ptr null
  br label %57

22:                                               ; preds = %7
  call void @llvm.lifetime.start.p0(i64 88, ptr nonnull %8) #10
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(88) %8, ptr noundef nonnull align 8 dereferenceable(88) %1, i64 88, i1 false), !tbaa.struct !5
  call void @llvm.lifetime.start.p0(i64 88, ptr nonnull %9) #10
  %23 = getelementptr inbounds i8, ptr %1, i64 88
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(88) %9, ptr noundef nonnull align 8 dereferenceable(88) %23, i64 88, i1 false), !tbaa.struct !5
  call void @llvm.lifetime.start.p0(i64 88, ptr nonnull %10) #10
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(88) %10, ptr noundef nonnull align 8 dereferenceable(88) %2, i64 88, i1 false), !tbaa.struct !5
  invoke void @_ZN12_GLOBAL__N_110checkDescsERKN8nvinfer116PluginTensorDescES3_S3_(ptr noundef nonnull align 8 dereferenceable(88) %8, ptr noundef nonnull align 8 dereferenceable(88) %9, ptr noundef nonnull align 8 dereferenceable(88) %10)
          to label %24 unwind label %49

24:                                               ; preds = %22
  %25 = getelementptr inbounds i8, ptr %8, i64 16
  %26 = load i64, ptr %25, align 8, !tbaa !17
  %27 = trunc i64 %26 to i32
  %28 = getelementptr inbounds i8, ptr %8, i64 24
  %29 = load i64, ptr %28, align 8, !tbaa !17
  %30 = trunc i64 %29 to i32
  %31 = getelementptr inbounds i8, ptr %8, i64 80
  %32 = load float, ptr %31, align 8, !tbaa !19
  %33 = getelementptr inbounds i8, ptr %9, i64 80
  %34 = load float, ptr %33, align 8, !tbaa !19
  %35 = getelementptr inbounds i8, ptr %10, i64 80
  %36 = load float, ptr %35, align 8, !tbaa !19
  %37 = fdiv float 1.000000e+00, %36
  %38 = load ptr, ptr %3, align 8, !tbaa !22
  %39 = getelementptr inbounds i8, ptr %3, i64 8
  %40 = load ptr, ptr %39, align 8, !tbaa !22
  %41 = load ptr, ptr %4, align 8, !tbaa !22
  %42 = getelementptr inbounds i8, ptr %0, i64 160
  %43 = call noundef ptr @_ZNKSt10unique_ptrIvN8nvinfer114pluginInternal11CudaDeleterIvEEE3getEv(ptr noundef nonnull align 8 dereferenceable(8) %42) #10
  %44 = getelementptr inbounds i8, ptr %0, i64 168
  %45 = call noundef ptr @_ZNKSt10unique_ptrIvN8nvinfer114pluginInternal11CudaDeleterIvEEE3getEv(ptr noundef nonnull align 8 dereferenceable(8) %44) #10
  %46 = icmp slt i32 %30, 4096
  br i1 %46, label %47, label %53

47:                                               ; preds = %24
  %48 = invoke noundef i32 @_ZN8nvinfer16plugin4bert18launch_small_hfaceEP11CUstream_stiiPKaS5_PK6__halfS8_Pafff(ptr noundef %6, i32 noundef %27, i32 noundef %30, ptr noundef %38, ptr noundef %40, ptr noundef %45, ptr noundef %43, ptr noundef %41, float noundef %32, float noundef %34, float noundef %37)
          to label %55 unwind label %51

49:                                               ; preds = %22
  %50 = landingpad { ptr, i32 }
          catch ptr @_ZTISt9exception
          catch ptr null
  br label %56

51:                                               ; preds = %53, %47
  %52 = landingpad { ptr, i32 }
          catch ptr @_ZTISt9exception
          catch ptr null
  br label %56

53:                                               ; preds = %24
  %54 = invoke noundef i32 @_ZN8nvinfer16plugin4bert18launch_large_hfaceEP11CUstream_stiiPKaS5_PK6__halfS8_Pafff(ptr noundef %6, i32 noundef %27, i32 noundef %30, ptr noundef %38, ptr noundef %40, ptr noundef %45, ptr noundef %43, ptr noundef %41, float noundef %32, float noundef %34, float noundef %37)
          to label %55 unwind label %51

55:                                               ; preds = %53, %47
  %.0 = phi i32 [ %48, %47 ], [ %54, %53 ]
  call void @llvm.lifetime.end.p0(i64 88, ptr nonnull %10) #10
  call void @llvm.lifetime.end.p0(i64 88, ptr nonnull %9) #10
  call void @llvm.lifetime.end.p0(i64 88, ptr nonnull %8) #10
  br label %63

56:                                               ; preds = %51, %49
  %.pn = phi { ptr, i32 } [ %52, %51 ], [ %50, %49 ]
  call void @llvm.lifetime.end.p0(i64 88, ptr nonnull %10) #10
  call void @llvm.lifetime.end.p0(i64 88, ptr nonnull %9) #10
  call void @llvm.lifetime.end.p0(i64 88, ptr nonnull %8) #10
  br label %57

57:                                               ; preds = %56, %20
  %.pn.pn = phi { ptr, i32 } [ %.pn, %56 ], [ %21, %20 ]
  %.144 = extractvalue { ptr, i32 } %.pn.pn, 0
  %.146 = extractvalue { ptr, i32 } %.pn.pn, 1
  %58 = call i32 @llvm.eh.typeid.for.p0(ptr nonnull @_ZTISt9exception) #10
  %59 = icmp eq i32 %.146, %58
  br i1 %59, label %60, label %67

60:                                               ; preds = %57
  %61 = call ptr @__cxa_begin_catch(ptr %.144) #10
  invoke void @_ZN8nvinfer16plugin11caughtErrorERKSt9exception(ptr noundef nonnull align 8 dereferenceable(8) %61)
          to label %62 unwind label %64

62:                                               ; preds = %60
  invoke void @__cxa_end_catch()
          to label %63 unwind label %64

63:                                               ; preds = %62, %55
  %.1 = phi i32 [ %.0, %55 ], [ -1, %62 ]
  ret i32 %.1

64:                                               ; preds = %62, %60
  %65 = landingpad { ptr, i32 }
          catch ptr null
  %66 = extractvalue { ptr, i32 } %65, 0
  call void @__clang_call_terminate(ptr %66) #11
  unreachable

67:                                               ; preds = %57
  call void @__clang_call_terminate(ptr %.144) #11
  unreachable
}

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #6

; Function Attrs: mustprogress uwtable
declare hidden void @_ZN12_GLOBAL__N_110checkDescsERKN8nvinfer116PluginTensorDescES3_S3_(ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 8 dereferenceable(88)) local_unnamed_addr #7

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

declare noundef i32 @_ZN8nvinfer16plugin4bert18launch_small_hfaceEP11CUstream_stiiPKaS5_PK6__halfS8_Pafff(ptr noundef, i32 noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, float noundef, float noundef, float noundef) local_unnamed_addr #8

declare noundef i32 @_ZN8nvinfer16plugin4bert18launch_large_hfaceEP11CUstream_stiiPKaS5_PK6__halfS8_Pafff(ptr noundef, i32 noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, float noundef, float noundef, float noundef) local_unnamed_addr #8

attributes #0 = { noreturn "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 = { nofree nosync nounwind memory(none) }
attributes #2 = { noinline noreturn nounwind uwtable "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 nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { inlinehint 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 #5 = { 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 #6 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #7 = { 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 #8 = { "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 = { noreturn }
attributes #10 = { nounwind }
attributes #11 = { 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 = !{i64 0, i64 4, !6, i64 8, i64 64, !10, i64 72, i64 4, !11, i64 76, i64 4, !13, i64 80, i64 4, !15}
!6 = !{!7, !7, i64 0}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!8, !8, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"_ZTSN8nvinfer18DataTypeE", !8, i64 0}
!13 = !{!14, !14, i64 0}
!14 = !{!"_ZTSN8nvinfer112TensorFormatE", !8, i64 0}
!15 = !{!16, !16, i64 0}
!16 = !{!"float", !8, i64 0}
!17 = !{!18, !18, i64 0}
!18 = !{!"long", !8, i64 0}
!19 = !{!20, !16, i64 80}
!20 = !{!"_ZTSN8nvinfer116PluginTensorDescE", !21, i64 0, !12, i64 72, !14, i64 76, !16, i64 80}
!21 = !{!"_ZTSN8nvinfer16Dims64E", !7, i64 0, !8, i64 8}
!22 = !{!23, !23, i64 0}
!23 = !{!"any pointer", !8, i64 0}


; Effective O3 passes: EarlyCSEPass,GlobalDCEPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,PostOrderFunctionAttrsPass,SLPVectorizerPass,SROAPass,SimplifyCFGPass