; LLVM IR from geefr/vulkan-physics :: vulkanutils/util (deviceinstance)

; 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.std::vector.19" = type { %"struct.std::_Vector_base.20" }
%"struct.std::_Vector_base.20" = type { %"struct.std::_Vector_base<vk::ExtensionProperties, std::allocator<vk::ExtensionProperties>>::_Vector_impl" }
%"struct.std::_Vector_base<vk::ExtensionProperties, std::allocator<vk::ExtensionProperties>>::_Vector_impl" = type { %"struct.std::_Vector_base<vk::ExtensionProperties, std::allocator<vk::ExtensionProperties>>::_Vector_impl_data" }
%"struct.std::_Vector_base<vk::ExtensionProperties, std::allocator<vk::ExtensionProperties>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.vk::Optional.24" = type { ptr }
%"class.std::vector.14" = type { %"struct.std::_Vector_base.15" }
%"struct.std::_Vector_base.15" = type { %"struct.std::_Vector_base<const char *, std::allocator<const char *>>::_Vector_impl" }
%"struct.std::_Vector_base<const char *, std::allocator<const char *>>::_Vector_impl" = type { %"struct.std::_Vector_base<const char *, std::allocator<const char *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<const char *, std::allocator<const char *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.vk::ApplicationInfo" = type { i32, ptr, ptr, i32, ptr, i32, i32 }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%"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::allocator.11" = type { i8 }
%"struct.vk::InstanceCreateInfo" = type { i32, ptr, %"class.vk::Flags", ptr, i32, ptr, i32, ptr }
%"class.vk::Flags" = type { i32 }
%"class.vk::UniqueHandle" = type { %"class.vk::ObjectDestroy", %"class.vk::Instance" }
%"class.vk::ObjectDestroy" = type { %"class.vk::Optional", ptr }
%"class.vk::Optional" = type { ptr }
%"class.vk::Instance" = type { ptr }
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<vk::PhysicalDevice, std::allocator<vk::PhysicalDevice>>::_Vector_impl" }
%"struct.std::_Vector_base<vk::PhysicalDevice, std::allocator<vk::PhysicalDevice>>::_Vector_impl" = type { %"struct.std::_Vector_base<vk::PhysicalDevice, std::allocator<vk::PhysicalDevice>>::_Vector_impl_data" }
%"struct.std::_Vector_base<vk::PhysicalDevice, std::allocator<vk::PhysicalDevice>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.__gnu_cxx::__normal_iterator.26" = type { ptr }
%class.anon = type { i8 }
%class.DeviceInstance = type { %"class.std::vector.0", %"class.vk::UniqueHandle", %"class.vk::UniqueHandle.5", %"class.std::vector.6" }
%"class.vk::UniqueHandle.5" = type { %"class.vk::ObjectDestroy", %"class.vk::Device" }
%"class.vk::Device" = type { ptr }
%"class.std::vector.6" = type { %"struct.std::_Vector_base.7" }
%"struct.std::_Vector_base.7" = type { %"struct.std::_Vector_base<DeviceInstance::QueueRef, std::allocator<DeviceInstance::QueueRef>>::_Vector_impl" }
%"struct.std::_Vector_base<DeviceInstance::QueueRef, std::allocator<DeviceInstance::QueueRef>>::_Vector_impl" = type { %"struct.std::_Vector_base<DeviceInstance::QueueRef, std::allocator<DeviceInstance::QueueRef>>::_Vector_impl_data" }
%"struct.std::_Vector_base<DeviceInstance::QueueRef, std::allocator<DeviceInstance::QueueRef>>::_Vector_impl_data" = type { ptr, ptr, ptr }

@.str = external hidden unnamed_addr constant [64 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [37 x i8], align 1
@_ZTISt13runtime_error = external constant ptr

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN14DeviceInstance20createVulkanInstanceERKSt6vectorIPKcSaIS2_EENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEjjS6_(ptr noundef nonnull align 8 dereferenceable(96) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef %2, i32 noundef %3, i32 noundef %4, ptr noundef nonnull align 8 dereferenceable(24) %5) #0 align 2 personality ptr @__gxx_personality_v0 {
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca ptr, align 8
  %13 = alloca %"class.std::vector.19", align 8
  %14 = alloca %"class.vk::Optional.24", align 8
  %15 = alloca %"class.std::vector.14", align 8
  %16 = alloca ptr, align 8
  %17 = alloca i32, align 4
  %18 = alloca %"struct.vk::ApplicationInfo", align 8
  %19 = alloca %"struct.vk::ApplicationInfo", align 8
  %20 = alloca %"class.std::vector.14", align 8
  %21 = alloca i32, align 4
  %22 = alloca ptr, align 8
  %23 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %24 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %25 = alloca ptr, align 8
  %26 = alloca %"class.std::__cxx11::basic_string", align 8
  %27 = alloca %"class.std::allocator.11", align 1
  %28 = alloca %"struct.vk::InstanceCreateInfo", align 8
  %29 = alloca %"struct.vk::InstanceCreateInfo", align 8
  %30 = alloca %"class.vk::Flags", align 4
  %31 = alloca %"class.vk::Flags", align 4
  %32 = alloca %"class.vk::UniqueHandle", align 8
  %33 = alloca %"class.vk::Optional", align 8
  %34 = alloca %"class.std::vector.0", align 8
  %35 = alloca %"class.__gnu_cxx::__normal_iterator.26", align 8
  %36 = alloca %"class.__gnu_cxx::__normal_iterator.26", align 8
  %37 = alloca %class.anon, align 1
  store ptr %0, ptr %7, align 8, !tbaa !5
  store ptr %1, ptr %8, align 8, !tbaa !5
  store ptr %2, ptr %9, align 8, !tbaa !5
  store i32 %3, ptr %10, align 4, !tbaa !9
  store i32 %4, ptr %11, align 4, !tbaa !9
  store ptr %5, ptr %12, align 8, !tbaa !5
  %38 = load ptr, ptr %7, align 8
  call void @llvm.lifetime.start.p0(i64 24, ptr %13) #9
  call void @_ZN2vk8OptionalIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEC2EDn(ptr noundef nonnull align 8 dereferenceable(8) %14, ptr null) #9
  %39 = call noundef nonnull align 8 dereferenceable(9) ptr @_ZN2vkL23getDispatchLoaderStaticEv()
  %40 = getelementptr inbounds %"class.vk::Optional.24", ptr %14, i32 0, i32 0
  %41 = load ptr, ptr %40, align 8
  call void @_ZN2vk36enumerateInstanceExtensionPropertiesISaINS_19ExtensionPropertiesEENS_20DispatchLoaderStaticEEENS_15ResultValueTypeISt6vectorIS1_T_EE4typeENS_8OptionalIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEERKT0_(ptr dead_on_unwind writable sret(%"class.std::vector.19") align 8 %13, ptr %41, ptr noundef nonnull align 8 dereferenceable(9) %39)
  call void @llvm.lifetime.start.p0(i64 24, ptr %15) #9
  %42 = load ptr, ptr %8, align 8, !tbaa !5
  invoke void @_ZNSt6vectorIPKcSaIS1_EEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(24) %15, ptr noundef nonnull align 8 dereferenceable(24) %42)
          to label %43 unwind label %65

43:                                               ; preds = %6
  call void @llvm.lifetime.start.p0(i64 48, ptr %18) #9
  call void @llvm.lifetime.start.p0(i64 48, ptr %19) #9
  call void @_ZN2vk15ApplicationInfoC2EPKcjS2_jj(ptr noundef nonnull align 8 dereferenceable(48) %19, ptr noundef null, i32 noundef 0, ptr noundef null, i32 noundef 0, i32 noundef 0) #9
  %44 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %2) #9
  %45 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo19setPApplicationNameEPKc(ptr noundef nonnull align 8 dereferenceable(48) %19, ptr noundef %44) #9
  %46 = load i32, ptr %10, align 4, !tbaa !9
  %47 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo21setApplicationVersionEj(ptr noundef nonnull align 8 dereferenceable(48) %45, i32 noundef %46) #9
  %48 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo14setPEngineNameEPKc(ptr noundef nonnull align 8 dereferenceable(48) %47, ptr noundef @.str) #9
  %49 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo16setEngineVersionEj(ptr noundef nonnull align 8 dereferenceable(48) %48, i32 noundef 1) #9
  %50 = load i32, ptr %11, align 4, !tbaa !9
  %51 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo13setApiVersionEj(ptr noundef nonnull align 8 dereferenceable(48) %49, i32 noundef %50) #9
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %18, ptr align 8 %51, i64 48, i1 false), !tbaa.struct !11
  call void @llvm.lifetime.end.p0(i64 48, ptr %19) #9
  call void @llvm.lifetime.start.p0(i64 24, ptr %20) #9
  %52 = load ptr, ptr %12, align 8, !tbaa !5
  invoke void @_ZNSt6vectorIPKcSaIS1_EEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(24) %20, ptr noundef nonnull align 8 dereferenceable(24) %52)
          to label %53 unwind label %69

53:                                               ; preds = %43
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #9
  %54 = call noundef i64 @_ZNKSt6vectorIPKcSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %20) #9
  %55 = trunc i64 %54 to i32
  store i32 %55, ptr %21, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #9
  store ptr %15, ptr %22, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #9
  %56 = load ptr, ptr %22, align 8, !tbaa !5
  %57 = call ptr @_ZNSt6vectorIPKcSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %56) #9
  %58 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %23, i32 0, i32 0
  store ptr %57, ptr %58, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #9
  %59 = load ptr, ptr %22, align 8, !tbaa !5
  %60 = call ptr @_ZNSt6vectorIPKcSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %59) #9
  %61 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %24, i32 0, i32 0
  store ptr %60, ptr %61, align 8
  br label %62

62:                                               ; preds = %79, %53
  %63 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPPKcSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %23, ptr noundef nonnull align 8 dereferenceable(8) %24) #9
  br i1 %63, label %73, label %64

64:                                               ; preds = %62
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #9
  br label %90

65:                                               ; preds = %6
  %66 = landingpad { ptr, i32 }
          cleanup
  %67 = extractvalue { ptr, i32 } %66, 0
  store ptr %67, ptr %16, align 8
  %68 = extractvalue { ptr, i32 } %66, 1
  store i32 %68, ptr %17, align 4
  br label %162

69:                                               ; preds = %43
  %70 = landingpad { ptr, i32 }
          cleanup
  %71 = extractvalue { ptr, i32 } %70, 0
  store ptr %71, ptr %16, align 8
  %72 = extractvalue { ptr, i32 } %70, 1
  store i32 %72, ptr %17, align 4
  br label %161

73:                                               ; preds = %62
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #9
  %74 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPPKcSt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %23) #9
  store ptr %74, ptr %25, align 8, !tbaa !5
  %75 = load ptr, ptr %25, align 8, !tbaa !5
  %76 = load ptr, ptr %75, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr %27) #9
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %27) #9
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %26, ptr noundef %76, ptr noundef nonnull align 1 dereferenceable(1) %27)
          to label %77 unwind label %81

77:                                               ; preds = %73
  invoke void @_ZN4Util15ensureExtensionERKSt6vectorIN2vk19ExtensionPropertiesESaIS2_EENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(24) %13, ptr noundef %26)
          to label %78 unwind label %85

78:                                               ; preds = %77
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %26) #9
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %27) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr %27) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #9
  br label %79

79:                                               ; preds = %78
  %80 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPPKcSt6vectorIS2_SaIS2_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %23) #9
  br label %62

81:                                               ; preds = %73
  %82 = landingpad { ptr, i32 }
          cleanup
  %83 = extractvalue { ptr, i32 } %82, 0
  store ptr %83, ptr %16, align 8
  %84 = extractvalue { ptr, i32 } %82, 1
  store i32 %84, ptr %17, align 4
  br label %89

85:                                               ; preds = %77
  %86 = landingpad { ptr, i32 }
          cleanup
  %87 = extractvalue { ptr, i32 } %86, 0
  store ptr %87, ptr %16, align 8
  %88 = extractvalue { ptr, i32 } %86, 1
  store i32 %88, ptr %17, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %26) #9
  br label %89

89:                                               ; preds = %85, %81
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %27) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr %27) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #9
  br label %160

90:                                               ; preds = %64
  call void @llvm.lifetime.start.p0(i64 64, ptr %28) #9
  call void @llvm.lifetime.start.p0(i64 64, ptr %29) #9
  call void @_ZN2vk5FlagsINS_22InstanceCreateFlagBitsEEC2Ev(ptr noundef nonnull align 4 dereferenceable(4) %30) #9
  %91 = getelementptr inbounds %"class.vk::Flags", ptr %30, i32 0, i32 0
  %92 = load i32, ptr %91, align 4
  call void @_ZN2vk18InstanceCreateInfoC2ENS_5FlagsINS_22InstanceCreateFlagBitsEEEPKNS_15ApplicationInfoEjPKPKcjSA_(ptr noundef nonnull align 8 dereferenceable(64) %29, i32 %92, ptr noundef null, i32 noundef 0, ptr noundef null, i32 noundef 0, ptr noundef null) #9
  call void @_ZN2vk5FlagsINS_22InstanceCreateFlagBitsEEC2Ev(ptr noundef nonnull align 4 dereferenceable(4) %31) #9
  %93 = getelementptr inbounds %"class.vk::Flags", ptr %31, i32 0, i32 0
  %94 = load i32, ptr %93, align 4
  %95 = call noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo8setFlagsENS_5FlagsINS_22InstanceCreateFlagBitsEEE(ptr noundef nonnull align 8 dereferenceable(64) %29, i32 %94) #9
  %96 = call noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo19setPApplicationInfoEPKNS_15ApplicationInfoE(ptr noundef nonnull align 8 dereferenceable(64) %95, ptr noundef %18) #9
  %97 = load i32, ptr %21, align 4, !tbaa !9
  %98 = call noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo20setEnabledLayerCountEj(ptr noundef nonnull align 8 dereferenceable(64) %96, i32 noundef %97) #9
  %99 = load i32, ptr %21, align 4, !tbaa !9
  %100 = icmp ne i32 %99, 0
  br i1 %100, label %101, label %103

101:                                              ; preds = %90
  %102 = call noundef ptr @_ZNSt6vectorIPKcSaIS1_EE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %20) #9
  br label %104

103:                                              ; preds = %90
  br label %104

104:                                              ; preds = %103, %101
  %105 = phi ptr [ %102, %101 ], [ null, %103 ]
  %106 = call noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo22setPpEnabledLayerNamesEPKPKc(ptr noundef nonnull align 8 dereferenceable(64) %98, ptr noundef %105) #9
  %107 = call noundef i64 @_ZNKSt6vectorIPKcSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %15) #9
  %108 = trunc i64 %107 to i32
  %109 = call noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo24setEnabledExtensionCountEj(ptr noundef nonnull align 8 dereferenceable(64) %106, i32 noundef %108) #9
  %110 = call noundef ptr @_ZNSt6vectorIPKcSaIS1_EE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %15) #9
  %111 = call noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo26setPpEnabledExtensionNamesEPKPKc(ptr noundef nonnull align 8 dereferenceable(64) %109, ptr noundef %110) #9
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %28, ptr align 8 %111, i64 64, i1 false), !tbaa.struct !14
  call void @llvm.lifetime.end.p0(i64 64, ptr %29) #9
  call void @llvm.lifetime.start.p0(i64 24, ptr %32) #9
  call void @_ZN2vk8OptionalIKNS_19AllocationCallbacksEEC2EDn(ptr noundef nonnull align 8 dereferenceable(8) %33, ptr null) #9
  %112 = invoke noundef nonnull align 8 dereferenceable(9) ptr @_ZN2vkL23getDispatchLoaderStaticEv()
          to label %113 unwind label %131

113:                                              ; preds = %104
  %114 = getelementptr inbounds %"class.vk::Optional", ptr %33, i32 0, i32 0
  %115 = load ptr, ptr %114, align 8
  invoke void @_ZN2vk20createInstanceUniqueINS_20DispatchLoaderStaticEEENS_15ResultValueTypeINS_12UniqueHandleINS_8InstanceET_EEE4typeERKNS_18InstanceCreateInfoENS_8OptionalIKNS_19AllocationCallbacksEEERKS5_(ptr dead_on_unwind writable sret(%"class.vk::UniqueHandle") align 8 %32, ptr noundef nonnull align 8 dereferenceable(64) %28, ptr %115, ptr noundef nonnull align 8 dereferenceable(9) %112)
          to label %116 unwind label %131

116:                                              ; preds = %113
  %117 = getelementptr inbounds %class.DeviceInstance, ptr %38, i32 0, i32 1
  %118 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZN2vk12UniqueHandleINS_8InstanceENS_20DispatchLoaderStaticEEaSEOS3_(ptr noundef nonnull align 8 dereferenceable(24) %117, ptr noundef nonnull align 8 dereferenceable(24) %32) #9
  call void @_ZN2vk12UniqueHandleINS_8InstanceENS_20DispatchLoaderStaticEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %32) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %32) #9
  call void @llvm.lifetime.start.p0(i64 24, ptr %34) #9
  %119 = getelementptr inbounds %class.DeviceInstance, ptr %38, i32 0, i32 1
  %120 = call noundef ptr @_ZN2vk12UniqueHandleINS_8InstanceENS_20DispatchLoaderStaticEEptEv(ptr noundef nonnull align 8 dereferenceable(24) %119) #9
  %121 = invoke noundef nonnull align 8 dereferenceable(9) ptr @_ZN2vkL23getDispatchLoaderStaticEv()
          to label %122 unwind label %135

122:                                              ; preds = %116
  invoke void @_ZNK2vk8Instance24enumeratePhysicalDevicesISaINS_14PhysicalDeviceEENS_20DispatchLoaderStaticEEENS_15ResultValueTypeISt6vectorIS2_T_EE4typeERKT0_(ptr dead_on_unwind writable sret(%"class.std::vector.0") align 8 %34, ptr noundef nonnull align 8 dereferenceable(8) %120, ptr noundef nonnull align 8 dereferenceable(9) %121)
          to label %123 unwind label %135

123:                                              ; preds = %122
  %124 = getelementptr inbounds %class.DeviceInstance, ptr %38, i32 0, i32 0
  %125 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIN2vk14PhysicalDeviceESaIS1_EEaSEOS3_(ptr noundef nonnull align 8 dereferenceable(24) %124, ptr noundef nonnull align 8 dereferenceable(24) %34) #9
  call void @_ZNSt6vectorIN2vk14PhysicalDeviceESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %34) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %34) #9
  %126 = getelementptr inbounds %class.DeviceInstance, ptr %38, i32 0, i32 0
  %127 = call noundef zeroext i1 @_ZNKSt6vectorIN2vk14PhysicalDeviceESaIS1_EE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %126) #9
  br i1 %127, label %128, label %147

128:                                              ; preds = %123
  %129 = call ptr @__cxa_allocate_exception(i64 16) #9
  invoke void @_ZNSt13runtime_errorC1EPKc(ptr noundef nonnull align 8 dereferenceable(16) %129, ptr noundef @.str.1)
          to label %130 unwind label %139

130:                                              ; preds = %128
  invoke void @__cxa_throw(ptr %129, ptr @_ZTISt13runtime_error, ptr @_ZNSt13runtime_errorD1Ev) #10
          to label %168 unwind label %143

131:                                              ; preds = %113, %104
  %132 = landingpad { ptr, i32 }
          cleanup
  %133 = extractvalue { ptr, i32 } %132, 0
  store ptr %133, ptr %16, align 8
  %134 = extractvalue { ptr, i32 } %132, 1
  store i32 %134, ptr %17, align 4
  call void @llvm.lifetime.end.p0(i64 24, ptr %32) #9
  br label %159

135:                                              ; preds = %122, %116
  %136 = landingpad { ptr, i32 }
          cleanup
  %137 = extractvalue { ptr, i32 } %136, 0
  store ptr %137, ptr %16, align 8
  %138 = extractvalue { ptr, i32 } %136, 1
  store i32 %138, ptr %17, align 4
  call void @llvm.lifetime.end.p0(i64 24, ptr %34) #9
  br label %159

139:                                              ; preds = %128
  %140 = landingpad { ptr, i32 }
          cleanup
  %141 = extractvalue { ptr, i32 } %140, 0
  store ptr %141, ptr %16, align 8
  %142 = extractvalue { ptr, i32 } %140, 1
  store i32 %142, ptr %17, align 4
  call void @__cxa_free_exception(ptr %129) #9
  br label %159

143:                                              ; preds = %147, %130
  %144 = landingpad { ptr, i32 }
          cleanup
  %145 = extractvalue { ptr, i32 } %144, 0
  store ptr %145, ptr %16, align 8
  %146 = extractvalue { ptr, i32 } %144, 1
  store i32 %146, ptr %17, align 4
  br label %159

147:                                              ; preds = %123
  %148 = getelementptr inbounds %class.DeviceInstance, ptr %38, i32 0, i32 0
  %149 = call ptr @_ZNSt6vectorIN2vk14PhysicalDeviceESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %148) #9
  %150 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.26", ptr %35, i32 0, i32 0
  store ptr %149, ptr %150, align 8
  %151 = getelementptr inbounds %class.DeviceInstance, ptr %38, i32 0, i32 0
  %152 = call ptr @_ZNSt6vectorIN2vk14PhysicalDeviceESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %151) #9
  %153 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.26", ptr %36, i32 0, i32 0
  store ptr %152, ptr %153, align 8
  %154 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.26", ptr %35, i32 0, i32 0
  %155 = load ptr, ptr %154, align 8
  %156 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.26", ptr %36, i32 0, i32 0
  %157 = load ptr, ptr %156, align 8
  invoke void @"_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPN2vk14PhysicalDeviceESt6vectorIS3_SaIS3_EEEEZN14DeviceInstance20createVulkanInstanceERKS5_IPKcSaISB_EENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEjjSF_E3$_0EvT_SN_T0_"(ptr %155, ptr %157)
          to label %158 unwind label %143

158:                                              ; preds = %147
  call void @llvm.lifetime.end.p0(i64 64, ptr %28) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #9
  call void @_ZNSt6vectorIPKcSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %20) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %20) #9
  call void @llvm.lifetime.end.p0(i64 48, ptr %18) #9
  call void @_ZNSt6vectorIPKcSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %15) #9
  call void @_ZNSt6vectorIN2vk19ExtensionPropertiesESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %13) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %13) #9
  ret void

159:                                              ; preds = %143, %139, %135, %131
  call void @llvm.lifetime.end.p0(i64 64, ptr %28) #9
  br label %160

160:                                              ; preds = %159, %89
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #9
  call void @_ZNSt6vectorIPKcSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %20) #9
  br label %161

161:                                              ; preds = %160, %69
  call void @llvm.lifetime.end.p0(i64 24, ptr %20) #9
  call void @llvm.lifetime.end.p0(i64 48, ptr %18) #9
  call void @_ZNSt6vectorIPKcSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #9
  br label %162

162:                                              ; preds = %161, %65
  call void @llvm.lifetime.end.p0(i64 24, ptr %15) #9
  call void @_ZNSt6vectorIN2vk19ExtensionPropertiesESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %13) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %13) #9
  br label %163

163:                                              ; preds = %162
  %164 = load ptr, ptr %16, align 8
  %165 = load i32, ptr %17, align 4
  %166 = insertvalue { ptr, i32 } poison, ptr %164, 0
  %167 = insertvalue { ptr, i32 } %166, i32 %165, 1
  resume { ptr, i32 } %167

168:                                              ; preds = %130
  unreachable
}

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN2vk12UniqueHandleINS_8InstanceENS_20DispatchLoaderStaticEED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIN2vk14PhysicalDeviceESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #1 align 2

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

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

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local void @_ZN2vk36enumerateInstanceExtensionPropertiesISaINS_19ExtensionPropertiesEENS_20DispatchLoaderStaticEEENS_15ResultValueTypeISt6vectorIS1_T_EE4typeENS_8OptionalIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEERKT0_(ptr dead_on_unwind noalias writable sret(%"class.std::vector.19") align 8, ptr, ptr noundef nonnull align 8 dereferenceable(9)) #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN2vk8OptionalIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEC2EDn(ptr noundef nonnull align 8 dereferenceable(8), ptr) unnamed_addr #1 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden noundef nonnull align 8 dereferenceable(9) ptr @_ZN2vkL23getDispatchLoaderStaticEv() #4

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIPKcSaIS1_EEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN2vk15ApplicationInfoC2EPKcjS2_jj(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef, i32 noundef, ptr noundef, i32 noundef, i32 noundef) unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo19setPApplicationNameEPKc(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef) #1 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo21setApplicationVersionEj(ptr noundef nonnull align 8 dereferenceable(48), i32 noundef) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo14setPEngineNameEPKc(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo16setEngineVersionEj(ptr noundef nonnull align 8 dereferenceable(48), i32 noundef) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo13setApiVersionEj(ptr noundef nonnull align 8 dereferenceable(48), i32 noundef) #1 align 2

; 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) #5

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN9__gnu_cxxneIPPKcSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #4

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

declare void @_ZN4Util15ensureExtensionERKSt6vectorIN2vk19ExtensionPropertiesESaIS2_EENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef) #6

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #1 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN2vk5FlagsINS_22InstanceCreateFlagBitsEEC2Ev(ptr noundef nonnull align 4 dereferenceable(4)) unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN2vk18InstanceCreateInfoC2ENS_5FlagsINS_22InstanceCreateFlagBitsEEEPKNS_15ApplicationInfoEjPKPKcjSA_(ptr noundef nonnull align 8 dereferenceable(64), i32, ptr noundef, i32 noundef, ptr noundef, i32 noundef, ptr noundef) unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo8setFlagsENS_5FlagsINS_22InstanceCreateFlagBitsEEE(ptr noundef nonnull align 8 dereferenceable(64), i32) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo19setPApplicationInfoEPKNS_15ApplicationInfoE(ptr noundef nonnull align 8 dereferenceable(64), ptr noundef) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo20setEnabledLayerCountEj(ptr noundef nonnull align 8 dereferenceable(64), i32 noundef) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo22setPpEnabledLayerNamesEPKPKc(ptr noundef nonnull align 8 dereferenceable(64), ptr noundef) #1 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo24setEnabledExtensionCountEj(ptr noundef nonnull align 8 dereferenceable(64), i32 noundef) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo26setPpEnabledExtensionNamesEPKPKc(ptr noundef nonnull align 8 dereferenceable(64), ptr noundef) #1 align 2

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local void @_ZN2vk20createInstanceUniqueINS_20DispatchLoaderStaticEEENS_15ResultValueTypeINS_12UniqueHandleINS_8InstanceET_EEE4typeERKNS_18InstanceCreateInfoENS_8OptionalIKNS_19AllocationCallbacksEEERKS5_(ptr dead_on_unwind noalias writable sret(%"class.vk::UniqueHandle") align 8, ptr noundef nonnull align 8 dereferenceable(64), ptr, ptr noundef nonnull align 8 dereferenceable(9)) #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN2vk8OptionalIKNS_19AllocationCallbacksEEC2EDn(ptr noundef nonnull align 8 dereferenceable(8), ptr) unnamed_addr #1 align 2

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

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

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local void @_ZNK2vk8Instance24enumeratePhysicalDevicesISaINS_14PhysicalDeviceEENS_20DispatchLoaderStaticEEENS_15ResultValueTypeISt6vectorIS2_T_EE4typeERKT0_(ptr dead_on_unwind noalias writable sret(%"class.std::vector.0") align 8, ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(9)) #3 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNKSt6vectorIN2vk14PhysicalDeviceESaIS1_EE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24)) #1 align 2

declare ptr @__cxa_allocate_exception(i64)

declare void @_ZNSt13runtime_errorC1EPKc(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) unnamed_addr #6

declare void @__cxa_free_exception(ptr)

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

declare void @__cxa_throw(ptr, ptr, ptr)

; Function Attrs: inlinehint mustprogress uwtable
declare hidden void @"_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPN2vk14PhysicalDeviceESt6vectorIS3_SaIS3_EEEEZN14DeviceInstance20createVulkanInstanceERKS5_IPKcSaISB_EENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEjjSF_E3$_0EvT_SN_T0_"(ptr, ptr) #8

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIPKcSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIN2vk19ExtensionPropertiesESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #1 align 2

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

!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 = !{i64 0, i64 4, !12, i64 8, i64 8, !5, i64 16, i64 8, !5, i64 24, i64 4, !9, i64 32, i64 8, !5, i64 40, i64 4, !9, i64 44, i64 4, !9}
!12 = !{!13, !13, i64 0}
!13 = !{!"_ZTSN2vk13StructureTypeE", !7, i64 0}
!14 = !{i64 0, i64 4, !12, i64 8, i64 8, !5, i64 16, i64 4, !9, i64 24, i64 8, !5, i64 32, i64 4, !9, i64 40, i64 8, !5, i64 48, i64 4, !9, i64 56, i64 8, !5}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"class.std::vector.19" = type { %"struct.std::_Vector_base.20" }
%"struct.std::_Vector_base.20" = type { %"struct.std::_Vector_base<vk::ExtensionProperties, std::allocator<vk::ExtensionProperties>>::_Vector_impl" }
%"struct.std::_Vector_base<vk::ExtensionProperties, std::allocator<vk::ExtensionProperties>>::_Vector_impl" = type { %"struct.std::_Vector_base<vk::ExtensionProperties, std::allocator<vk::ExtensionProperties>>::_Vector_impl_data" }
%"struct.std::_Vector_base<vk::ExtensionProperties, std::allocator<vk::ExtensionProperties>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.vk::Optional.24" = type { ptr }
%"class.std::vector.14" = type { %"struct.std::_Vector_base.15" }
%"struct.std::_Vector_base.15" = type { %"struct.std::_Vector_base<const char *, std::allocator<const char *>>::_Vector_impl" }
%"struct.std::_Vector_base<const char *, std::allocator<const char *>>::_Vector_impl" = type { %"struct.std::_Vector_base<const char *, std::allocator<const char *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<const char *, std::allocator<const char *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.vk::ApplicationInfo" = type { i32, ptr, ptr, i32, ptr, i32, i32 }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%"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::allocator.11" = type { i8 }
%"struct.vk::InstanceCreateInfo" = type { i32, ptr, %"class.vk::Flags", ptr, i32, ptr, i32, ptr }
%"class.vk::Flags" = type { i32 }
%"class.vk::UniqueHandle" = type { %"class.vk::ObjectDestroy", %"class.vk::Instance" }
%"class.vk::ObjectDestroy" = type { %"class.vk::Optional", ptr }
%"class.vk::Optional" = type { ptr }
%"class.vk::Instance" = type { ptr }
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<vk::PhysicalDevice, std::allocator<vk::PhysicalDevice>>::_Vector_impl" }
%"struct.std::_Vector_base<vk::PhysicalDevice, std::allocator<vk::PhysicalDevice>>::_Vector_impl" = type { %"struct.std::_Vector_base<vk::PhysicalDevice, std::allocator<vk::PhysicalDevice>>::_Vector_impl_data" }
%"struct.std::_Vector_base<vk::PhysicalDevice, std::allocator<vk::PhysicalDevice>>::_Vector_impl_data" = type { ptr, ptr, ptr }

@.str = external hidden unnamed_addr constant [64 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [37 x i8], align 1
@_ZTISt13runtime_error = external constant ptr

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN14DeviceInstance20createVulkanInstanceERKSt6vectorIPKcSaIS2_EENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEjjS6_(ptr noundef nonnull align 8 dereferenceable(96) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef %2, i32 noundef %3, i32 noundef %4, ptr noundef nonnull align 8 dereferenceable(24) %5) local_unnamed_addr #0 align 2 personality ptr @__gxx_personality_v0 {
  %7 = alloca %"class.std::vector.19", align 8
  %8 = alloca %"class.vk::Optional.24", align 8
  %9 = alloca %"class.std::vector.14", align 8
  %10 = alloca %"struct.vk::ApplicationInfo", align 8
  %11 = alloca %"struct.vk::ApplicationInfo", align 8
  %12 = alloca %"class.std::vector.14", align 8
  %13 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %14 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %15 = alloca %"class.std::__cxx11::basic_string", align 8
  %16 = alloca %"class.std::allocator.11", align 1
  %17 = alloca %"struct.vk::InstanceCreateInfo", align 8
  %18 = alloca %"struct.vk::InstanceCreateInfo", align 8
  %19 = alloca %"class.vk::Flags", align 4
  %20 = alloca %"class.vk::Flags", align 4
  %21 = alloca %"class.vk::UniqueHandle", align 8
  %22 = alloca %"class.vk::Optional", align 8
  %23 = alloca %"class.std::vector.0", align 8
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %7) #9
  call void @_ZN2vk8OptionalIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEC2EDn(ptr noundef nonnull align 8 dereferenceable(8) %8, ptr null) #9
  %24 = call noundef nonnull align 8 dereferenceable(9) ptr @_ZN2vkL23getDispatchLoaderStaticEv()
  %25 = load ptr, ptr %8, align 8
  call void @_ZN2vk36enumerateInstanceExtensionPropertiesISaINS_19ExtensionPropertiesEENS_20DispatchLoaderStaticEEENS_15ResultValueTypeISt6vectorIS1_T_EE4typeENS_8OptionalIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEERKT0_(ptr dead_on_unwind nonnull writable sret(%"class.std::vector.19") align 8 %7, ptr %25, ptr noundef nonnull align 8 dereferenceable(9) %24)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %9) #9
  invoke void @_ZNSt6vectorIPKcSaIS1_EEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(24) %9, ptr noundef nonnull align 8 dereferenceable(24) %1)
          to label %26 unwind label %44

26:                                               ; preds = %6
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %10) #9
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %11) #9
  call void @_ZN2vk15ApplicationInfoC2EPKcjS2_jj(ptr noundef nonnull align 8 dereferenceable(48) %11, ptr noundef null, i32 noundef 0, ptr noundef null, i32 noundef 0, i32 noundef 0) #9
  %27 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %2) #9
  %28 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo19setPApplicationNameEPKc(ptr noundef nonnull align 8 dereferenceable(48) %11, ptr noundef %27) #9
  %29 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo21setApplicationVersionEj(ptr noundef nonnull align 8 dereferenceable(48) %28, i32 noundef %3) #9
  %30 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo14setPEngineNameEPKc(ptr noundef nonnull align 8 dereferenceable(48) %29, ptr noundef nonnull @.str) #9
  %31 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo16setEngineVersionEj(ptr noundef nonnull align 8 dereferenceable(48) %30, i32 noundef 1) #9
  %32 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo13setApiVersionEj(ptr noundef nonnull align 8 dereferenceable(48) %31, i32 noundef %4) #9
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(48) %10, ptr noundef nonnull align 8 dereferenceable(48) %32, i64 48, i1 false), !tbaa.struct !5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %11) #9
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %12) #9
  invoke void @_ZNSt6vectorIPKcSaIS1_EEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(24) %12, ptr noundef nonnull align 8 dereferenceable(24) %5)
          to label %33 unwind label %46

33:                                               ; preds = %26
  %34 = call noundef i64 @_ZNKSt6vectorIPKcSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %12) #9
  %35 = trunc i64 %34 to i32
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %13) #9
  %36 = call ptr @_ZNSt6vectorIPKcSaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %9) #9
  store ptr %36, ptr %13, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %14) #9
  %37 = call ptr @_ZNSt6vectorIPKcSaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %9) #9
  store ptr %37, ptr %14, align 8
  %38 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPPKcSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %13, ptr noundef nonnull align 8 dereferenceable(8) %14) #9
  br i1 %38, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %51, %33
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %14) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #9
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %17) #9
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %18) #9
  call void @_ZN2vk5FlagsINS_22InstanceCreateFlagBitsEEC2Ev(ptr noundef nonnull align 4 dereferenceable(4) %19) #9
  %39 = load i32, ptr %19, align 4
  call void @_ZN2vk18InstanceCreateInfoC2ENS_5FlagsINS_22InstanceCreateFlagBitsEEEPKNS_15ApplicationInfoEjPKPKcjSA_(ptr noundef nonnull align 8 dereferenceable(64) %18, i32 %39, ptr noundef null, i32 noundef 0, ptr noundef null, i32 noundef 0, ptr noundef null) #9
  call void @_ZN2vk5FlagsINS_22InstanceCreateFlagBitsEEC2Ev(ptr noundef nonnull align 4 dereferenceable(4) %20) #9
  %40 = load i32, ptr %20, align 4
  %41 = call noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo8setFlagsENS_5FlagsINS_22InstanceCreateFlagBitsEEE(ptr noundef nonnull align 8 dereferenceable(64) %18, i32 %40) #9
  %42 = call noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo19setPApplicationInfoEPKNS_15ApplicationInfoE(ptr noundef nonnull align 8 dereferenceable(64) %41, ptr noundef nonnull %10) #9
  %43 = call noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo20setEnabledLayerCountEj(ptr noundef nonnull align 8 dereferenceable(64) %42, i32 noundef %35) #9
  %.not = icmp eq i32 %35, 0
  br i1 %.not, label %61, label %59

44:                                               ; preds = %6
  %45 = landingpad { ptr, i32 }
          cleanup
  br label %97

46:                                               ; preds = %26
  %47 = landingpad { ptr, i32 }
          cleanup
  br label %96

.lr.ph:                                           ; preds = %33, %51
  %48 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPPKcSt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #9
  %49 = load ptr, ptr %48, align 8, !tbaa !10
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %16) #9
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %16) #9
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %15, ptr noundef %49, ptr noundef nonnull align 1 dereferenceable(1) %16)
          to label %50 unwind label %54

50:                                               ; preds = %.lr.ph
  invoke void @_ZN4Util15ensureExtensionERKSt6vectorIN2vk19ExtensionPropertiesESaIS2_EENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull %15)
          to label %51 unwind label %56

51:                                               ; preds = %50
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %15) #9
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %16) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %16) #9
  %52 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPPKcSt6vectorIS2_SaIS2_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #9
  %53 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPPKcSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %13, ptr noundef nonnull align 8 dereferenceable(8) %14) #9
  br i1 %53, label %.lr.ph, label %._crit_edge

54:                                               ; preds = %.lr.ph
  %55 = landingpad { ptr, i32 }
          cleanup
  br label %58

56:                                               ; preds = %50
  %57 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %15) #9
  br label %58

58:                                               ; preds = %56, %54
  %.pn18 = phi { ptr, i32 } [ %57, %56 ], [ %55, %54 ]
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %16) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %16) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %14) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #9
  br label %95

59:                                               ; preds = %._crit_edge
  %60 = call noundef ptr @_ZNSt6vectorIPKcSaIS1_EE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %12) #9
  br label %61

61:                                               ; preds = %._crit_edge, %59
  %62 = phi ptr [ %60, %59 ], [ null, %._crit_edge ]
  %63 = call noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo22setPpEnabledLayerNamesEPKPKc(ptr noundef nonnull align 8 dereferenceable(64) %43, ptr noundef %62) #9
  %64 = call noundef i64 @_ZNKSt6vectorIPKcSaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %9) #9
  %65 = trunc i64 %64 to i32
  %66 = call noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo24setEnabledExtensionCountEj(ptr noundef nonnull align 8 dereferenceable(64) %63, i32 noundef %65) #9
  %67 = call noundef ptr @_ZNSt6vectorIPKcSaIS1_EE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %9) #9
  %68 = call noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo26setPpEnabledExtensionNamesEPKPKc(ptr noundef nonnull align 8 dereferenceable(64) %66, ptr noundef %67) #9
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(64) %17, ptr noundef nonnull align 8 dereferenceable(64) %68, i64 64, i1 false), !tbaa.struct !14
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %18) #9
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %21) #9
  call void @_ZN2vk8OptionalIKNS_19AllocationCallbacksEEC2EDn(ptr noundef nonnull align 8 dereferenceable(8) %22, ptr null) #9
  %69 = call noundef nonnull align 8 dereferenceable(9) ptr @_ZN2vkL23getDispatchLoaderStaticEv()
  %70 = load ptr, ptr %22, align 8
  invoke void @_ZN2vk20createInstanceUniqueINS_20DispatchLoaderStaticEEENS_15ResultValueTypeINS_12UniqueHandleINS_8InstanceET_EEE4typeERKNS_18InstanceCreateInfoENS_8OptionalIKNS_19AllocationCallbacksEEERKS5_(ptr dead_on_unwind nonnull writable sret(%"class.vk::UniqueHandle") align 8 %21, ptr noundef nonnull align 8 dereferenceable(64) %17, ptr %70, ptr noundef nonnull align 8 dereferenceable(9) %69)
          to label %71 unwind label %82

71:                                               ; preds = %61
  %72 = getelementptr inbounds i8, ptr %0, i64 24
  %73 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZN2vk12UniqueHandleINS_8InstanceENS_20DispatchLoaderStaticEEaSEOS3_(ptr noundef nonnull align 8 dereferenceable(24) %72, ptr noundef nonnull align 8 dereferenceable(24) %21) #9
  call void @_ZN2vk12UniqueHandleINS_8InstanceENS_20DispatchLoaderStaticEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %21) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %21) #9
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %23) #9
  %74 = call noundef ptr @_ZN2vk12UniqueHandleINS_8InstanceENS_20DispatchLoaderStaticEEptEv(ptr noundef nonnull align 8 dereferenceable(24) %72) #9
  %75 = call noundef nonnull align 8 dereferenceable(9) ptr @_ZN2vkL23getDispatchLoaderStaticEv()
  invoke void @_ZNK2vk8Instance24enumeratePhysicalDevicesISaINS_14PhysicalDeviceEENS_20DispatchLoaderStaticEEENS_15ResultValueTypeISt6vectorIS2_T_EE4typeERKT0_(ptr dead_on_unwind nonnull writable sret(%"class.std::vector.0") align 8 %23, ptr noundef nonnull align 8 dereferenceable(8) %74, ptr noundef nonnull align 8 dereferenceable(9) %75)
          to label %76 unwind label %84

76:                                               ; preds = %71
  %77 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIN2vk14PhysicalDeviceESaIS1_EEaSEOS3_(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 8 dereferenceable(24) %23) #9
  call void @_ZNSt6vectorIN2vk14PhysicalDeviceESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %23) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %23) #9
  %78 = call noundef zeroext i1 @_ZNKSt6vectorIN2vk14PhysicalDeviceESaIS1_EE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #9
  br i1 %78, label %79, label %90

79:                                               ; preds = %76
  %80 = call ptr @__cxa_allocate_exception(i64 16) #9
  invoke void @_ZNSt13runtime_errorC1EPKc(ptr noundef nonnull align 8 dereferenceable(16) %80, ptr noundef nonnull @.str.1)
          to label %81 unwind label %86

81:                                               ; preds = %79
  invoke void @__cxa_throw(ptr nonnull %80, ptr nonnull @_ZTISt13runtime_error, ptr nonnull @_ZNSt13runtime_errorD1Ev) #10
          to label %98 unwind label %88

82:                                               ; preds = %61
  %83 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %21) #9
  br label %94

84:                                               ; preds = %71
  %85 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %23) #9
  br label %94

86:                                               ; preds = %79
  %87 = landingpad { ptr, i32 }
          cleanup
  call void @__cxa_free_exception(ptr %80) #9
  br label %94

88:                                               ; preds = %90, %81
  %89 = landingpad { ptr, i32 }
          cleanup
  br label %94

90:                                               ; preds = %76
  %91 = call ptr @_ZNSt6vectorIN2vk14PhysicalDeviceESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #9
  %92 = call ptr @_ZNSt6vectorIN2vk14PhysicalDeviceESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %0) #9
  invoke void @"_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPN2vk14PhysicalDeviceESt6vectorIS3_SaIS3_EEEEZN14DeviceInstance20createVulkanInstanceERKS5_IPKcSaISB_EENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEjjSF_E3$_0EvT_SN_T0_"(ptr %91, ptr %92)
          to label %93 unwind label %88

93:                                               ; preds = %90
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %17) #9
  call void @_ZNSt6vectorIPKcSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %12) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %12) #9
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %10) #9
  call void @_ZNSt6vectorIPKcSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %9) #9
  call void @_ZNSt6vectorIN2vk19ExtensionPropertiesESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #9
  ret void

94:                                               ; preds = %88, %86, %84, %82
  %.pn = phi { ptr, i32 } [ %89, %88 ], [ %87, %86 ], [ %85, %84 ], [ %83, %82 ]
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %17) #9
  br label %95

95:                                               ; preds = %94, %58
  %.pn18.pn = phi { ptr, i32 } [ %.pn18, %58 ], [ %.pn, %94 ]
  call void @_ZNSt6vectorIPKcSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %12) #9
  br label %96

96:                                               ; preds = %95, %46
  %.pn18.pn.pn = phi { ptr, i32 } [ %.pn18.pn, %95 ], [ %47, %46 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %12) #9
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %10) #9
  call void @_ZNSt6vectorIPKcSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #9
  br label %97

97:                                               ; preds = %96, %44
  %.pn18.pn.pn.pn = phi { ptr, i32 } [ %.pn18.pn.pn, %96 ], [ %45, %44 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %9) #9
  call void @_ZNSt6vectorIN2vk19ExtensionPropertiesESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #9
  resume { ptr, i32 } %.pn18.pn.pn.pn

98:                                               ; preds = %81
  unreachable
}

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN2vk12UniqueHandleINS_8InstanceENS_20DispatchLoaderStaticEED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIN2vk14PhysicalDeviceESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #1 align 2

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

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

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local void @_ZN2vk36enumerateInstanceExtensionPropertiesISaINS_19ExtensionPropertiesEENS_20DispatchLoaderStaticEEENS_15ResultValueTypeISt6vectorIS1_T_EE4typeENS_8OptionalIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEERKT0_(ptr dead_on_unwind noalias writable sret(%"class.std::vector.19") align 8, ptr, ptr noundef nonnull align 8 dereferenceable(9)) local_unnamed_addr #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN2vk8OptionalIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEC2EDn(ptr noundef nonnull align 8 dereferenceable(8), ptr) unnamed_addr #1 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden noundef nonnull align 8 dereferenceable(9) ptr @_ZN2vkL23getDispatchLoaderStaticEv() local_unnamed_addr #4

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIPKcSaIS1_EEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN2vk15ApplicationInfoC2EPKcjS2_jj(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef, i32 noundef, ptr noundef, i32 noundef, i32 noundef) unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo19setPApplicationNameEPKc(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef) local_unnamed_addr #1 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo21setApplicationVersionEj(ptr noundef nonnull align 8 dereferenceable(48), i32 noundef) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo14setPEngineNameEPKc(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo16setEngineVersionEj(ptr noundef nonnull align 8 dereferenceable(48), i32 noundef) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(48) ptr @_ZN2vk15ApplicationInfo13setApiVersionEj(ptr noundef nonnull align 8 dereferenceable(48), i32 noundef) local_unnamed_addr #1 align 2

; 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) #5

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN9__gnu_cxxneIPPKcSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #4

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

declare void @_ZN4Util15ensureExtensionERKSt6vectorIN2vk19ExtensionPropertiesESaIS2_EENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef) local_unnamed_addr #6

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #1 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN2vk5FlagsINS_22InstanceCreateFlagBitsEEC2Ev(ptr noundef nonnull align 4 dereferenceable(4)) unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN2vk18InstanceCreateInfoC2ENS_5FlagsINS_22InstanceCreateFlagBitsEEEPKNS_15ApplicationInfoEjPKPKcjSA_(ptr noundef nonnull align 8 dereferenceable(64), i32, ptr noundef, i32 noundef, ptr noundef, i32 noundef, ptr noundef) unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo8setFlagsENS_5FlagsINS_22InstanceCreateFlagBitsEEE(ptr noundef nonnull align 8 dereferenceable(64), i32) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo19setPApplicationInfoEPKNS_15ApplicationInfoE(ptr noundef nonnull align 8 dereferenceable(64), ptr noundef) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo20setEnabledLayerCountEj(ptr noundef nonnull align 8 dereferenceable(64), i32 noundef) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo22setPpEnabledLayerNamesEPKPKc(ptr noundef nonnull align 8 dereferenceable(64), ptr noundef) local_unnamed_addr #1 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo24setEnabledExtensionCountEj(ptr noundef nonnull align 8 dereferenceable(64), i32 noundef) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(64) ptr @_ZN2vk18InstanceCreateInfo26setPpEnabledExtensionNamesEPKPKc(ptr noundef nonnull align 8 dereferenceable(64), ptr noundef) local_unnamed_addr #1 align 2

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local void @_ZN2vk20createInstanceUniqueINS_20DispatchLoaderStaticEEENS_15ResultValueTypeINS_12UniqueHandleINS_8InstanceET_EEE4typeERKNS_18InstanceCreateInfoENS_8OptionalIKNS_19AllocationCallbacksEEERKS5_(ptr dead_on_unwind noalias writable sret(%"class.vk::UniqueHandle") align 8, ptr noundef nonnull align 8 dereferenceable(64), ptr, ptr noundef nonnull align 8 dereferenceable(9)) local_unnamed_addr #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN2vk8OptionalIKNS_19AllocationCallbacksEEC2EDn(ptr noundef nonnull align 8 dereferenceable(8), ptr) unnamed_addr #1 align 2

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

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

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local void @_ZNK2vk8Instance24enumeratePhysicalDevicesISaINS_14PhysicalDeviceEENS_20DispatchLoaderStaticEEENS_15ResultValueTypeISt6vectorIS2_T_EE4typeERKT0_(ptr dead_on_unwind noalias writable sret(%"class.std::vector.0") align 8, ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(9)) local_unnamed_addr #3 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNKSt6vectorIN2vk14PhysicalDeviceESaIS1_EE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #1 align 2

declare ptr @__cxa_allocate_exception(i64) local_unnamed_addr

declare void @_ZNSt13runtime_errorC1EPKc(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) unnamed_addr #6

declare void @__cxa_free_exception(ptr) local_unnamed_addr

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

declare void @__cxa_throw(ptr, ptr, ptr) local_unnamed_addr

; Function Attrs: inlinehint mustprogress uwtable
declare hidden void @"_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPN2vk14PhysicalDeviceESt6vectorIS3_SaIS3_EEEEZN14DeviceInstance20createVulkanInstanceERKS5_IPKcSaISB_EENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEjjSF_E3$_0EvT_SN_T0_"(ptr, ptr) local_unnamed_addr #8

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIPKcSaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIN2vk19ExtensionPropertiesESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #1 align 2

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

!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 8, !10, i64 16, i64 8, !10, i64 24, i64 4, !12, i64 32, i64 8, !10, i64 40, i64 4, !12, i64 44, i64 4, !12}
!6 = !{!7, !7, i64 0}
!7 = !{!"_ZTSN2vk13StructureTypeE", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!11, !11, i64 0}
!11 = !{!"any pointer", !8, i64 0}
!12 = !{!13, !13, i64 0}
!13 = !{!"int", !8, i64 0}
!14 = !{i64 0, i64 4, !6, i64 8, i64 8, !10, i64 16, i64 4, !12, i64 24, i64 8, !10, i64 32, i64 4, !12, i64 40, i64 8, !10, i64 48, i64 4, !12, i64 56, i64 8, !10}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass