From f847ab8566a81da84aa38afe7c19f3abf6210b98 Mon Sep 17 00:00:00 2001 From: Charles Giessen Date: Mon, 20 Jun 2022 10:52:16 -0500 Subject: [PATCH] Add exclusion list for alias in generator code Some alias types are not pure promotional types, and need to be excluded from the code which replaces types with their alias. This may be a stopgap solution for a larger underlying problem of not being able to determine if an alias is promoted or not. --- script/generate_dispatch.py | 10 +++++++--- src/VkBootstrapDispatch.h | 2 +- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/script/generate_dispatch.py b/script/generate_dispatch.py index 7445324..bd96f32 100644 --- a/script/generate_dispatch.py +++ b/script/generate_dispatch.py @@ -29,7 +29,7 @@ # User will be prompted to install if not detected # Command Line Arguments -# [--auto] Don't ask for input from the command line +# [--auto] Don't ask for input from the command line # Exclusions exclusions = [ @@ -43,6 +43,10 @@ excluded_extension_authors = [ 'NVX' ] +excluded_alias_types = [ + 'VkPipelineInfoKHR' +] + # Check for/install xmltodict import sys import os @@ -288,7 +292,7 @@ for command in device_commands: if i > 0: args_names += ', ' else: - if arg_type in aliased_types: + if arg_type in aliased_types and arg_type not in excluded_alias_types: arg_type = aliased_types[arg_type] args_full += arg_template.substitute(front_mods = front_mods, arg_type = arg_type, back_mods = back_mods, arg_name = arg_name, array = array) args_names += arg_name @@ -355,4 +359,4 @@ cmake_version_file.write(f'set(VK_BOOTSTRAP_SOURCE_HEADER_VERSION {version_tag}) cmake_version_file.write(f'set(VK_BOOTSTRAP_SOURCE_HEADER_VERSION_GIT_TAG v{version_tag})\n') cmake_version_file.close() -print("Generation finished.") \ No newline at end of file +print("Generation finished.") diff --git a/src/VkBootstrapDispatch.h b/src/VkBootstrapDispatch.h index cd3ba34..2d7526d 100644 --- a/src/VkBootstrapDispatch.h +++ b/src/VkBootstrapDispatch.h @@ -2318,7 +2318,7 @@ struct DispatchTable { } #endif #if (defined(VK_KHR_pipeline_executable_properties)) - VkResult getPipelineExecutablePropertiesKHR(const VkPipelineInfoEXT* pPipelineInfo, uint32_t* pExecutableCount, VkPipelineExecutablePropertiesKHR* pProperties) const noexcept { + VkResult getPipelineExecutablePropertiesKHR(const VkPipelineInfoKHR* pPipelineInfo, uint32_t* pExecutableCount, VkPipelineExecutablePropertiesKHR* pProperties) const noexcept { return fp_vkGetPipelineExecutablePropertiesKHR(device, pPipelineInfo, pExecutableCount, pProperties); } #endif