Lines Matching refs:name

45  vk_icdGetPhysicalDeviceProcAddr is called, will return the custom_physical_device_function if the function name matches
64 Functions for testing of layer interception of unknown functions. Note the need to pass a pointer to the layer and the name
70 PFN_vkVoidFunction find_custom_func(TestLayer* layer, const char* name) {
71 if (layer->custom_dispatch_functions.count(name) > 0) {
72 return layer->custom_dispatch_functions.at(name);
79 static VKAPI_ATTR uint32_t VKAPI_CALL func_zero(DispatchableHandleType handle, TestLayer* layer, const char* name, uint32_t i) {
80 auto func = reinterpret_cast<decltype(&func_zero)>(find_custom_func(layer, name));
82 return func(handle, layer, name, i + 3);
84 static VKAPI_ATTR uint32_t VKAPI_CALL func_one(DispatchableHandleType handle, TestLayer* layer, const char* name, uint32_t i,
86 auto func = reinterpret_cast<decltype(&func_one)>(find_custom_func(layer, name));
88 return func(handle, layer, name, i + 2, f + 1.f);
90 static VKAPI_ATTR float VKAPI_CALL func_two(DispatchableHandleType handle, TestLayer* layer, const char* name, uint32_t foo,
92 auto func = reinterpret_cast<decltype(&func_two)>(find_custom_func(layer, name));
94 return func(handle, layer, name, foo + 1, bar + 2, baz * 2);
96 static VKAPI_ATTR int VKAPI_CALL func_three(DispatchableHandleType handle, TestLayer* layer, const char* name, int* ptr_a,
98 auto func = reinterpret_cast<decltype(&func_three)>(find_custom_func(layer, name));
102 return func(handle, layer, name, ptr_a, ptr_b);
104 static VKAPI_ATTR float VKAPI_CALL func_four(DispatchableHandleType handle, TestLayer* layer, const char* name, int* ptr_a,
106 auto func = reinterpret_cast<decltype(&func_four)>(find_custom_func(layer, name));
108 return func(handle, layer, name, ptr_a, ptr_b, foo + 4, bar + 5, k + 1, l + 2, 'd', 'e', 'f');
158 // to setup a unordered_map for storing the next function in the chain, and key it based on the name
171 // layer has to setup a unordered_map for storing the next function in the chain, and key it based on the name
792 static const char* name;
797 const char* LayerInterceptData<UniqueType>::name = nullptr;
806 reinterpret_cast<decltype(&implementation)>(LayerType::layer->get_custom_intercept_function(LayerType::name));
812 static void check(VulkanFunctions const& loader, ParentType parent, DispatchableHandle dispatch_type, const char* name,
814 decltype(implementation)* returned_func = loader.load(parent, name);
820 const char* name) {
821 decltype(implementation)* returned_func = loader.load(parent, name);
834 reinterpret_cast<decltype(&implementation)>(LayerType::layer->get_custom_intercept_function(LayerType::name));
840 static void check(VulkanFunctions const& loader, ParentType parent, DispatchableHandle dispatch_type, const char* name,
842 decltype(implementation)* returned_func = loader.load(parent, name);
849 const char* name) {
850 decltype(implementation)* returned_func = loader.load(parent, name);
865 reinterpret_cast<decltype(&implementation)>(LayerType::layer->get_custom_intercept_function(LayerType::name));
873 static void check(VulkanFunctions const& loader, ParentType parent, DispatchableHandle dispatch_type, const char* name,
875 decltype(implementation)* returned_func = loader.load(parent, name);
883 const char* name) {
884 decltype(implementation)* returned_func = loader.load(parent, name);
900 reinterpret_cast<decltype(&implementation)>(LayerType::layer->get_custom_intercept_function(LayerType::name));
908 static void check(VulkanFunctions const& loader, ParentType parent, DispatchableHandle dispatch_type, const char* name,
910 decltype(implementation)* returned_func = loader.load(parent, name);
920 const char* name) {
921 decltype(implementation)* returned_func = loader.load(parent, name);
949 reinterpret_cast<decltype(&implementation)>(LayerType::layer->get_custom_intercept_function(LayerType::name));
963 static void check(VulkanFunctions const& loader, ParentType parent, DispatchableHandle dispatch_type, const char* name,
965 decltype(implementation)* returned_func = loader.load(parent, name);
982 const char* name) {
983 decltype(implementation)* returned_func = loader.load(parent, name);
991 std::string name;
997 UnknownFunction(std::string name) : name(name) {}
1008 FunctionType::Function::check(loader, parent, dispatch_type, name.c_str(), intercept_count);
1010 FunctionType::Function::check_no_implementation(loader, parent, dispatch_type, name.c_str());
1024 physical_device.add_device_function({func.name.c_str(), to_vkVoidFunction(Function::implementation)});
1031 LayerInterceptData<LayerStruct>::name = func.name.c_str();
1033 func.name, to_vkVoidFunction(&Function::template intercept<LayerInterceptData<LayerStruct>>));
1038 layer.add_custom_device_implementation_function({func.name.c_str(), to_vkVoidFunction(Function::implementation)});
1051 physical_device.add_custom_physical_device_function({func.name.c_str(), to_vkVoidFunction(Function::implementation)});
1058 LayerInterceptData<LayerStruct>::name = func.name.c_str();
1060 func.name, to_vkVoidFunction(&Function::template intercept<LayerInterceptData<LayerStruct>>));
1065 layer.add_custom_physical_device_implementation_function({func.name.c_str(), to_vkVoidFunction(Function::implementation)});
1288 .add_instance_extension(ManifestLayer::LayerDescription::Extension{ext_name, 0, {unknown_func.name}}))