Extent extension dependency inspection to allow multiple sets of dependencies per version. (#1578)

This commit is contained in:
Andreas Süßenbach 2023-05-17 10:23:27 +02:00 committed by GitHub
parent 40e76b7c24
commit 523491a7df
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 1769 additions and 398 deletions

View File

@ -575,10 +575,10 @@ Some functions might provide information that depends on the vulkan version. As
Gets all instance extensions specified for the current platform. Note, that not all of them might be supported by the actual instances. Gets all instance extensions specified for the current platform. Note, that not all of them might be supported by the actual instances.
- `std::map<std::string, std::string> const & getDeprecatedExtensions();` - `std::map<std::string, std::string> const & getDeprecatedExtensions();`
Gets a map of all deprecated extensions to the extension or vulkan version that is supposed to replace that functionality. Gets a map of all deprecated extensions to the extension or vulkan version that is supposed to replace that functionality.
- `std::map<std::string, std::vector<std::string>> const & getExtensionDepends( std::string const & extension );` - `std::map<std::string, std::vector<std::vector<std::string>>> const & getExtensionDepends( std::string const & extension );`
Some extensions depends on other extensions. That dependencies might differ for different vulkan versions. This function gets a vector of extensions per vulkan version that the given extension depends on. Some extensions depends on other extensions. That dependencies might differ for different vulkan versions, and there might be different sets of dependencies for the very same vulkan version. This function gets a vector of vectors of extensions per vulkan version that the given extension depends on.
- `std::pair<bool, std::vector<std::string> const &> getExtensionDepends( std::string const & version, std::string const & extension );` - `std::pair<bool, std::vector<std::vector<std::string>> const &> getExtensionDepends( std::string const & version, std::string const & extension );`
The `first` member of the returned `std::pair` is true, if the given extension is specified for the given vulkan version, otherwise `false`. The `second` member of the returned `std::pair` is a vector of extensions, the given extension depends on for the given vulkan version. The `first` member of the returned `std::pair` is true, if the given extension is specified for the given vulkan version, otherwise `false`. The `second` member of the returned `std::pair` is a vector of vectors of extensions, listing the separate sets of extensions the given extension depends on for the given vulkan version.
- `std::map<std::string, std::string> const & getObsoletedExtensions();` - `std::map<std::string, std::string> const & getObsoletedExtensions();`
Gets a map of all obsoleted extensions to the extension or vulkan version that has obsoleted that extension. Gets a map of all obsoleted extensions to the extension or vulkan version that has obsoleted that extension.
- `std::map<std::string, std::string> const & getPromotedExtensions();` - `std::map<std::string, std::string> const & getPromotedExtensions();`

View File

@ -137,10 +137,10 @@ namespace VULKAN_HPP_NAMESPACE
//=== Extension inspection functions === //=== Extension inspection functions ===
//====================================== //======================================
std::set<std::string> const & getDeviceExtensions(); std::set<std::string> const & getDeviceExtensions();
std::set<std::string> const & getInstanceExtensions(); std::set<std::string> const & getInstanceExtensions();
std::map<std::string, std::string> const & getDeprecatedExtensions(); std::map<std::string, std::string> const & getDeprecatedExtensions();
std::map<std::string, std::vector<std::string>> const & getExtensionDepends( std::string const & extension ); std::map<std::string, std::vector<std::vector<std::string>>> const & getExtensionDepends( std::string const & extension );
${getExtensionDependsByVersionDeclaration} ${getExtensionDependsByVersionDeclaration}
std::map<std::string, std::string> const & getObsoletedExtensions(); std::map<std::string, std::string> const & getObsoletedExtensions();
std::map<std::string, std::string> const & getPromotedExtensions(); std::map<std::string, std::string> const & getPromotedExtensions();
@ -175,10 +175,10 @@ namespace VULKAN_HPP_NAMESPACE
return instanceExtensions; return instanceExtensions;
} }
VULKAN_HPP_INLINE std::map<std::string, std::vector<std::string>> const & getExtensionDepends( std::string const & extension ) VULKAN_HPP_INLINE std::map<std::string, std::vector<std::vector<std::string>>> const & getExtensionDepends( std::string const & extension )
{ {
static std::map<std::string, std::vector<std::string>> noDependencies; static std::map<std::string, std::vector<std::vector<std::string>>> noDependencies;
static std::map<std::string, std::map<std::string, std::vector<std::string>>> dependencies = { ${extensionDependencies} }; static std::map<std::string, std::map<std::string, std::vector<std::vector<std::string>>>> dependencies = { ${extensionDependencies} };
auto depIt = dependencies.find( extension ); auto depIt = dependencies.find( extension );
return ( depIt != dependencies.end() ) ? depIt->second : noDependencies; return ( depIt != dependencies.end() ) ? depIt->second : noDependencies;
} }
@ -1189,14 +1189,17 @@ void VulkanHppGenerator::checkExtensionCorrectness() const
for ( auto const & extension : m_extensions ) for ( auto const & extension : m_extensions )
{ {
// check for existence of any depends, deprecation, obsoletion, or promotion // check for existence of any depends, deprecation, obsoletion, or promotion
for ( auto const & dependsPerVersion : extension.depends ) for ( auto const & dependsByVersion : extension.depends )
{ {
checkForError( isFeature( dependsPerVersion.first ), checkForError( isFeature( dependsByVersion.first ),
extension.xmlLine, extension.xmlLine,
"extension <" + extension.name + "> lists an unknown feature <" + dependsPerVersion.first + ">" ); "extension <" + extension.name + "> lists an unknown feature <" + dependsByVersion.first + ">" );
for ( auto const & depends : dependsPerVersion.second ) for ( auto const & dependsSet : dependsByVersion.second )
{ {
checkForError( isExtension( depends ), extension.xmlLine, "extension <" + extension.name + "> lists an unknown depends <" + depends + ">" ); for ( auto const & depends : dependsSet )
{
checkForError( isExtension( depends ), extension.xmlLine, "extension <" + extension.name + "> lists an unknown depends <" + depends + ">" );
}
} }
} }
if ( !extension.deprecatedBy.empty() ) if ( !extension.deprecatedBy.empty() )
@ -5723,15 +5726,20 @@ std::string VulkanHppGenerator::generateExtensionDependencies() const
if ( !extension.depends.empty() ) if ( !extension.depends.empty() )
{ {
std::string dependsPerExtension = "{ \"" + extension.name + "\", { "; std::string dependsPerExtension = "{ \"" + extension.name + "\", { ";
for ( auto const & dependsPerVersion : extension.depends ) for ( auto const & dependsByVersion : extension.depends )
{ {
dependsPerExtension += "{ \"" + dependsPerVersion.first + "\", { "; dependsPerExtension += "{ \"" + dependsByVersion.first + "\", { ";
if ( !dependsPerVersion.second.empty() ) if ( !dependsByVersion.second.empty() )
{ {
for ( auto const & depends : dependsPerVersion.second ) dependsPerExtension += " { ";
for ( auto const & dependsSet : dependsByVersion.second )
{ {
dependsPerExtension += "\"" + depends + "\", "; for ( auto const & depends : dependsSet )
{
dependsPerExtension += "\"" + depends + "\", ";
}
} }
dependsPerExtension += " }, ";
assert( dependsPerExtension.ends_with( ", " ) ); assert( dependsPerExtension.ends_with( ", " ) );
dependsPerExtension = dependsPerExtension.substr( 0, dependsPerExtension.length() - 2 ); dependsPerExtension = dependsPerExtension.substr( 0, dependsPerExtension.length() - 2 );
} }
@ -5767,15 +5775,15 @@ std::string VulkanHppGenerator::generateExtensionDependsByVersion( bool definiti
if ( definition ) if ( definition )
{ {
const std::string generateExtensionDependsTemplate = const std::string generateExtensionDependsTemplate =
R"( VULKAN_HPP_INLINE std::pair<bool, std::vector<std::string> const &> getExtensionDepends( std::string const & version, std::string const & extension ) R"( VULKAN_HPP_INLINE std::pair<bool, std::vector<std::vector<std::string>> const &> getExtensionDepends( std::string const & version, std::string const & extension )
{ {
#if !defined( NDEBUG ) #if !defined( NDEBUG )
static std::set<std::string> versions = { ${versions} }; static std::set<std::string> versions = { ${versions} };
assert( versions.find( version ) != versions.end() ); assert( versions.find( version ) != versions.end() );
#endif #endif
static std::vector<std::string> noDependencies; static std::vector<std::vector<std::string>> noDependencies;
std::map<std::string, std::vector<std::string>> const & dependencies = getExtensionDepends( extension ); std::map<std::string, std::vector<std::vector<std::string>>> const & dependencies = getExtensionDepends( extension );
if ( dependencies.empty() ) if ( dependencies.empty() )
{ {
return { true, noDependencies }; return { true, noDependencies };
@ -5808,7 +5816,7 @@ std::string VulkanHppGenerator::generateExtensionDependsByVersion( bool definiti
} }
else else
{ {
return "std::pair<bool, std::vector<std::string> const &> getExtensionDepends( std::string const & version, std::string const & extension );"; return "std::pair<bool, std::vector<std::vector<std::string>> const &> getExtensionDepends( std::string const & version, std::string const & extension );";
} }
} }
@ -11965,28 +11973,32 @@ void VulkanHppGenerator::readExtension( tinyxml2::XMLElement const * element )
{ "(VK_KHR_get_physical_device_properties2,VK_VERSION_1_1)+(VK_KHR_dynamic_rendering,VK_VERSION_1_3)", { "(VK_KHR_get_physical_device_properties2,VK_VERSION_1_1)+(VK_KHR_dynamic_rendering,VK_VERSION_1_3)",
"VK_KHR_get_physical_device_properties2+VK_KHR_dynamic_rendering,VK_VERSION_1_1+VK_KHR_dynamic_rendering,VK_VERSION_1_3" } "VK_KHR_get_physical_device_properties2+VK_KHR_dynamic_rendering,VK_VERSION_1_1+VK_KHR_dynamic_rendering,VK_VERSION_1_3" }
}; };
auto canonicalIt = complexToCanonicalDepends.find( attribute.second ); auto canonicalIt = complexToCanonicalDepends.find( attribute.second );
std::string depends = ( canonicalIt == complexToCanonicalDepends.end() ) ? attribute.second : canonicalIt->second; std::string depends;
checkForError( depends.find( '(' ) == std::string::npos, line, "encountered not-yet-handled complex attribute depends=\"" + depends + "\"" ); if ( canonicalIt == complexToCanonicalDepends.end() )
// for ease of handling, prepend the (optional) VK_VERSION_1_0
if ( !depends.starts_with( "VK_VERSION" ) )
{ {
depends = "VK_VERSION_1_0+" + depends; depends = attribute.second;
std::erase_if( depends, []( char c ) { return ( c == '(' ) || ( c == ')' ); } );
}
else
{
depends = canonicalIt->second;
} }
// first tokenize by ',', giving a vector of dependencies for different vulkan versions // first tokenize by ',', giving a vector of dependencies for different vulkan versions
std::vector<std::string> allDependencies = tokenize( depends, "," ); std::vector<std::string> allDependencies = tokenize( depends, "," );
for ( auto dep : allDependencies ) for ( auto dep : allDependencies )
{ {
// for ease of handling, prepend the (optional) VK_VERSION_1_0
if ( !dep.starts_with( "VK_VERSION" ) )
{
assert( dep.find( "VK_VERSION" ) == std::string::npos );
dep = "VK_VERSION_1_0+" + dep;
}
// then tokenize by '+', giving a vector of dependendies for the vulkan version listed as the first element here // then tokenize by '+', giving a vector of dependendies for the vulkan version listed as the first element here
std::vector<std::string> dependsPerVersion = tokenize( dep, "+" ); std::vector<std::string> dependsByVersion = tokenize( dep, "+" );
assert( dependsPerVersion[0].starts_with( "VK_VERSION_" ) ); extensionData.depends[dependsByVersion[0]].push_back( { std::next( dependsByVersion.begin() ), dependsByVersion.end() } );
assert( std::find_if( std::next( dependsPerVersion.begin() ),
dependsPerVersion.end(),
[]( std::string const & d ) { return d.starts_with( "VK_VERSION_" ); } ) == dependsPerVersion.end() );
assert( extensionData.depends.find( dependsPerVersion[0] ) == extensionData.depends.end() );
extensionData.depends[dependsPerVersion[0]] = { std::next( dependsPerVersion.begin() ), dependsPerVersion.end() };
} }
} }
else if ( attribute.first == "deprecatedby" ) else if ( attribute.first == "deprecatedby" )

View File

@ -244,17 +244,17 @@ private:
struct ExtensionData struct ExtensionData
{ {
std::string deprecatedBy = {}; std::string deprecatedBy = {};
bool isDeprecated = false; bool isDeprecated = false;
std::string name = {}; std::string name = {};
std::string number = {}; std::string number = {};
std::string obsoletedBy = {}; std::string obsoletedBy = {};
std::string platform = {}; std::string platform = {};
std::string promotedTo = {}; std::string promotedTo = {};
std::map<std::string, std::vector<std::string>> depends = {}; std::map<std::string, std::vector<std::vector<std::string>>> depends = {};
std::vector<RequireData> requireData = {}; std::vector<RequireData> requireData = {};
std::string type = {}; std::string type = {};
int xmlLine = 0; int xmlLine = 0;
}; };
struct ExternalTypeData struct ExternalTypeData

View File

@ -49,18 +49,18 @@ int main( int /*argc*/, char ** /*argv*/ )
std::set<std::string> const & deviceExtensions = vk::getDeviceExtensions(); std::set<std::string> const & deviceExtensions = vk::getDeviceExtensions();
assert( deviceExtensions.find( VK_KHR_SWAPCHAIN_EXTENSION_NAME ) != deviceExtensions.end() ); assert( deviceExtensions.find( VK_KHR_SWAPCHAIN_EXTENSION_NAME ) != deviceExtensions.end() );
std::map<std::string, std::vector<std::string>> depends = vk::getExtensionDepends( VK_KHR_SWAPCHAIN_EXTENSION_NAME ); std::map<std::string, std::vector<std::vector<std::string>>> depends = vk::getExtensionDepends( VK_KHR_SWAPCHAIN_EXTENSION_NAME );
assert( ( depends.size() == 1 ) && ( depends.begin()->first == "VK_VERSION_1_0" ) && ( depends.begin()->second.size() == 1 ) && assert( ( depends.size() == 1 ) && ( depends.begin()->first == "VK_VERSION_1_0" ) && ( depends.begin()->second.size() == 1 ) &&
( depends.begin()->second[0] == VK_KHR_SURFACE_EXTENSION_NAME ) ); ( depends.begin()->second[0].size() == 1 ) && ( depends.begin()->second[0][0] == VK_KHR_SURFACE_EXTENSION_NAME ) );
auto [available0, deps0] = vk::getExtensionDepends( "VK_VERSION_1_0", VK_KHR_SURFACE_EXTENSION_NAME ); auto [available0, deps0] = vk::getExtensionDepends( "VK_VERSION_1_0", VK_KHR_SURFACE_EXTENSION_NAME );
assert( available0 && deps0.empty() ); assert( available0 && deps0.empty() );
auto [available1, deps1] = vk::getExtensionDepends( "VK_VERSION_1_0", VK_KHR_SWAPCHAIN_EXTENSION_NAME ); auto [available1, deps1] = vk::getExtensionDepends( "VK_VERSION_1_0", VK_KHR_SWAPCHAIN_EXTENSION_NAME );
assert( available1 && ( deps1.size() == 1 ) && ( deps1[0] == VK_KHR_SURFACE_EXTENSION_NAME ) ); assert( available1 && ( deps1.size() == 1 ) && ( deps1[0].size() == 1 ) && ( deps1[0][0] == VK_KHR_SURFACE_EXTENSION_NAME ) );
auto [available2, deps2] = vk::getExtensionDepends( "VK_VERSION_1_1", VK_KHR_SWAPCHAIN_EXTENSION_NAME ); auto [available2, deps2] = vk::getExtensionDepends( "VK_VERSION_1_1", VK_KHR_SWAPCHAIN_EXTENSION_NAME );
assert( available2 && ( deps2.size() == 1 ) && ( deps2[0] == VK_KHR_SURFACE_EXTENSION_NAME ) ); assert( available2 && ( deps2.size() == 1 ) && ( deps2[0].size() == 1 ) && ( deps2[0][0] == VK_KHR_SURFACE_EXTENSION_NAME ) );
auto [available3, deps3] = vk::getExtensionDepends( "VK_VERSION_1_1", VK_EXT_SHADER_TILE_IMAGE_EXTENSION_NAME ); auto [available3, deps3] = vk::getExtensionDepends( "VK_VERSION_1_1", VK_EXT_SHADER_TILE_IMAGE_EXTENSION_NAME );
assert( !available3 ); assert( !available3 );

File diff suppressed because it is too large Load Diff

View File

@ -18,10 +18,10 @@ namespace VULKAN_HPP_NAMESPACE
//=== Extension inspection functions === //=== Extension inspection functions ===
//====================================== //======================================
std::set<std::string> const & getDeviceExtensions(); std::set<std::string> const & getDeviceExtensions();
std::set<std::string> const & getInstanceExtensions(); std::set<std::string> const & getInstanceExtensions();
std::map<std::string, std::string> const & getDeprecatedExtensions(); std::map<std::string, std::string> const & getDeprecatedExtensions();
std::map<std::string, std::vector<std::string>> const & getExtensionDepends( std::string const & extension ); std::map<std::string, std::vector<std::vector<std::string>>> const & getExtensionDepends( std::string const & extension );
std::map<std::string, std::string> const & getObsoletedExtensions(); std::map<std::string, std::string> const & getObsoletedExtensions();
std::map<std::string, std::string> const & getPromotedExtensions(); std::map<std::string, std::string> const & getPromotedExtensions();
@ -134,84 +134,364 @@ namespace VULKAN_HPP_NAMESPACE
return instanceExtensions; return instanceExtensions;
} }
VULKAN_HPP_INLINE std::map<std::string, std::vector<std::string>> const & getExtensionDepends( std::string const & extension ) VULKAN_HPP_INLINE std::map<std::string, std::vector<std::vector<std::string>>> const & getExtensionDepends( std::string const & extension )
{ {
static std::map<std::string, std::vector<std::string>> noDependencies; static std::map<std::string, std::vector<std::vector<std::string>>> noDependencies;
static std::map<std::string, std::map<std::string, std::vector<std::string>>> dependencies = { static std::map<std::string, std::map<std::string, std::vector<std::vector<std::string>>>> dependencies = {
{ "VK_KHR_swapchain", { { "VK_VERSION_1_0", { "VK_KHR_surface" } } } }, { "VK_KHR_swapchain",
{ "VK_KHR_display", { { "VK_VERSION_1_0", { "VK_KHR_surface" } } } }, { { "VK_VERSION_1_0",
{ "VK_KHR_display_swapchain", { { "VK_VERSION_1_0", { "VK_KHR_swapchain", "VK_KHR_display" } } } }, { {
{ "VK_EXT_texture_compression_astc_hdr", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, "VK_KHR_surface",
{ "VK_EXT_astc_decode_mode", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, } } } } },
{ "VK_KHR_external_memory_fd", { { "VK_VERSION_1_0", { "VK_KHR_external_memory" } }, { "VK_VERSION_1_1", {} } } }, { "VK_KHR_display",
{ "VK_KHR_external_semaphore_fd", { { "VK_VERSION_1_0", { "VK_KHR_external_semaphore" } }, { "VK_VERSION_1_1", {} } } }, { { "VK_VERSION_1_0",
{ "VK_KHR_incremental_present", { { "VK_VERSION_1_0", { "VK_KHR_swapchain" } } } }, { {
{ "VK_EXT_direct_mode_display", { { "VK_VERSION_1_0", { "VK_KHR_display" } } } }, "VK_KHR_surface",
{ "VK_EXT_display_surface_counter", { { "VK_VERSION_1_0", { "VK_KHR_display" } } } }, } } } } },
{ "VK_EXT_display_control", { { "VK_VERSION_1_0", { "VK_EXT_display_surface_counter", "VK_KHR_swapchain" } } } }, { "VK_KHR_display_swapchain",
{ "VK_EXT_discard_rectangles", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, { { "VK_VERSION_1_0",
{ "VK_EXT_conservative_rasterization", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, { {
{ "VK_EXT_depth_clip_enable", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, "VK_KHR_swapchain",
{ "VK_EXT_swapchain_colorspace", { { "VK_VERSION_1_0", { "VK_KHR_surface" } } } }, "VK_KHR_display",
{ "VK_EXT_hdr_metadata", { { "VK_VERSION_1_0", { "VK_KHR_swapchain" } } } }, } } } } },
{ "VK_EXT_texture_compression_astc_hdr",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_astc_decode_mode",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_KHR_external_memory_fd",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_external_memory",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_KHR_external_semaphore_fd",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_external_semaphore",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_KHR_incremental_present",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_swapchain",
} } } } },
{ "VK_EXT_direct_mode_display",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_display",
} } } } },
{ "VK_EXT_display_surface_counter",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_display",
} } } } },
{ "VK_EXT_display_control",
{ { "VK_VERSION_1_0",
{ {
"VK_EXT_display_surface_counter",
"VK_KHR_swapchain",
} } } } },
{ "VK_EXT_discard_rectangles",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_conservative_rasterization",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_depth_clip_enable",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_swapchain_colorspace",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_surface",
} } } } },
{ "VK_EXT_hdr_metadata",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_swapchain",
} } } } },
{ "VK_KHR_shared_presentable_image", { "VK_KHR_shared_presentable_image",
{ { "VK_VERSION_1_0", { "VK_KHR_swapchain", "VK_KHR_get_surface_capabilities2", "VK_KHR_get_physical_device_properties2" } }, { { "VK_VERSION_1_0",
{ "VK_VERSION_1_1", { "VK_KHR_swapchain", "VK_KHR_get_surface_capabilities2" } } } }, { {
{ "VK_KHR_external_fence_fd", { { "VK_VERSION_1_0", { "VK_KHR_external_fence" } }, { "VK_VERSION_1_1", {} } } }, "VK_KHR_swapchain",
{ "VK_KHR_performance_query", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, "VK_KHR_get_surface_capabilities2",
{ "VK_KHR_get_surface_capabilities2", { { "VK_VERSION_1_0", { "VK_KHR_surface" } } } }, "VK_KHR_get_physical_device_properties2",
{ "VK_KHR_get_display_properties2", { { "VK_VERSION_1_0", { "VK_KHR_display" } } } }, } } },
{ "VK_EXT_external_memory_dma_buf", { { "VK_VERSION_1_0", { "VK_KHR_external_memory_fd" } } } }, { "VK_VERSION_1_1",
{ "VK_EXT_queue_family_foreign", { { "VK_VERSION_1_0", { "VK_KHR_external_memory" } }, { "VK_VERSION_1_1", {} } } }, { {
{ "VK_EXT_sample_locations", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, "VK_KHR_swapchain",
{ "VK_EXT_blend_operation_advanced", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, "VK_KHR_get_surface_capabilities2",
} } } } },
{ "VK_KHR_external_fence_fd",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_external_fence",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_KHR_performance_query",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_KHR_get_surface_capabilities2",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_surface",
} } } } },
{ "VK_KHR_get_display_properties2",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_display",
} } } } },
{ "VK_EXT_external_memory_dma_buf",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_external_memory_fd",
} } } } },
{ "VK_EXT_queue_family_foreign",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_external_memory",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_sample_locations",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_blend_operation_advanced",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_image_drm_format_modifier", { "VK_EXT_image_drm_format_modifier",
{ { "VK_VERSION_1_0", { { "VK_VERSION_1_0",
{ "VK_KHR_bind_memory2", "VK_KHR_get_physical_device_properties2", "VK_KHR_sampler_ycbcr_conversion", "VK_KHR_image_format_list" } }, { {
{ "VK_VERSION_1_1", { "VK_KHR_image_format_list" } }, "VK_KHR_bind_memory2",
{ "VK_VERSION_1_2", {} } } }, "VK_KHR_get_physical_device_properties2",
{ "VK_EXT_external_memory_host", { { "VK_VERSION_1_0", { "VK_KHR_external_memory" } }, { "VK_VERSION_1_1", {} } } }, "VK_KHR_sampler_ycbcr_conversion",
{ "VK_KHR_shader_clock", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, "VK_KHR_image_format_list",
{ "VK_EXT_calibrated_timestamps", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, } } },
{ "VK_EXT_vertex_attribute_divisor", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, { "VK_VERSION_1_1",
{ {
"VK_KHR_image_format_list",
} } },
{ "VK_VERSION_1_2", { {} } } } },
{ "VK_EXT_external_memory_host",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_external_memory",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_KHR_shader_clock",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_calibrated_timestamps",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_vertex_attribute_divisor",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_KHR_swapchain_mutable_format", { "VK_KHR_swapchain_mutable_format",
{ { "VK_VERSION_1_0", { "VK_KHR_swapchain", "VK_KHR_maintenance2", "VK_KHR_image_format_list" } }, { { "VK_VERSION_1_0",
{ "VK_VERSION_1_1", { "VK_KHR_swapchain", "VK_KHR_image_format_list" } }, { {
{ "VK_VERSION_1_2", { "VK_KHR_swapchain" } } } }, "VK_KHR_swapchain",
{ "VK_EXT_pci_bus_info", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, "VK_KHR_maintenance2",
{ "VK_KHR_shader_terminate_invocation", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, "VK_KHR_image_format_list",
{ "VK_EXT_subgroup_size_control", { { "VK_VERSION_1_1", {} } } }, } } },
{ "VK_VERSION_1_1",
{ {
"VK_KHR_swapchain",
"VK_KHR_image_format_list",
} } },
{ "VK_VERSION_1_2",
{ {
"VK_KHR_swapchain",
} } } } },
{ "VK_EXT_pci_bus_info",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_KHR_shader_terminate_invocation",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_subgroup_size_control", { { "VK_VERSION_1_1", { {} } } } },
{ "VK_KHR_fragment_shading_rate", { "VK_KHR_fragment_shading_rate",
{ { "VK_VERSION_1_0", { "VK_KHR_create_renderpass2", "VK_KHR_get_physical_device_properties2" } }, { { "VK_VERSION_1_0",
{ "VK_VERSION_1_1", { "VK_KHR_create_renderpass2" } }, { {
{ "VK_VERSION_1_2", {} } } }, "VK_KHR_create_renderpass2",
{ "VK_EXT_shader_image_atomic_int64", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, "VK_KHR_get_physical_device_properties2",
{ "VK_EXT_memory_budget", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, } } },
{ "VK_EXT_fragment_shader_interlock", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, { "VK_VERSION_1_1",
{ "VK_EXT_ycbcr_image_arrays", { { "VK_VERSION_1_0", { "VK_KHR_sampler_ycbcr_conversion" } }, { "VK_VERSION_1_1", {} } } }, { {
{ "VK_EXT_headless_surface", { { "VK_VERSION_1_0", { "VK_KHR_surface" } } } }, "VK_KHR_create_renderpass2",
{ "VK_EXT_line_rasterization", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, } } },
{ "VK_EXT_shader_atomic_float", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, { "VK_VERSION_1_2", { {} } } } },
{ "VK_EXT_index_type_uint8", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, { "VK_EXT_shader_image_atomic_int64",
{ "VK_EXT_extended_dynamic_state", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, { { "VK_VERSION_1_0",
{ "VK_EXT_shader_demote_to_helper_invocation", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, { {
{ "VK_EXT_texel_buffer_alignment", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, "VK_KHR_get_physical_device_properties2",
{ "VK_EXT_robustness2", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, } } },
{ "VK_EXT_custom_border_color", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, { "VK_VERSION_1_1", { {} } } } },
{ "VK_KHR_synchronization2", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, { "VK_EXT_memory_budget",
{ "VK_EXT_ycbcr_2plane_444_formats", { { "VK_VERSION_1_0", { "VK_KHR_sampler_ycbcr_conversion" } }, { "VK_VERSION_1_1", {} } } }, { { "VK_VERSION_1_0",
{ "VK_EXT_image_robustness", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, { {
{ "VK_KHR_copy_commands2", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, "VK_KHR_get_physical_device_properties2",
{ "VK_EXT_4444_formats", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, } } },
{ "VK_EXT_vertex_input_dynamic_state", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, { "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_fragment_shader_interlock",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_ycbcr_image_arrays",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_sampler_ycbcr_conversion",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_headless_surface",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_surface",
} } } } },
{ "VK_EXT_line_rasterization",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_shader_atomic_float",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_index_type_uint8",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_extended_dynamic_state",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_shader_demote_to_helper_invocation",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_texel_buffer_alignment",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_robustness2",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_custom_border_color",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_KHR_synchronization2",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_ycbcr_2plane_444_formats",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_sampler_ycbcr_conversion",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_image_robustness",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_KHR_copy_commands2",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_4444_formats",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_vertex_input_dynamic_state",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
#if defined( VK_USE_PLATFORM_SCI ) #if defined( VK_USE_PLATFORM_SCI )
{ "VK_NV_external_sci_sync", { { "VK_VERSION_1_1", {} } } }, { "VK_NV_external_sci_sync", { { "VK_VERSION_1_1", { {} } } } },
{ "VK_NV_external_memory_sci_buf", { { "VK_VERSION_1_1", {} } } }, { "VK_NV_external_memory_sci_buf", { { "VK_VERSION_1_1", { {} } } } },
#endif /*VK_USE_PLATFORM_SCI*/ #endif /*VK_USE_PLATFORM_SCI*/
{ "VK_EXT_extended_dynamic_state2", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, { "VK_EXT_extended_dynamic_state2",
{ "VK_EXT_color_write_enable", { { "VK_VERSION_1_0", { "VK_KHR_get_physical_device_properties2" } }, { "VK_VERSION_1_1", {} } } }, { { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
{ "VK_EXT_color_write_enable",
{ { "VK_VERSION_1_0",
{ {
"VK_KHR_get_physical_device_properties2",
} } },
{ "VK_VERSION_1_1", { {} } } } },
#if defined( VK_USE_PLATFORM_SCI ) #if defined( VK_USE_PLATFORM_SCI )
{ "VK_NV_external_sci_sync2", { { "VK_VERSION_1_1", {} } } } { "VK_NV_external_sci_sync2", { { "VK_VERSION_1_1", { {} } } } }
#endif /*VK_USE_PLATFORM_SCI*/ #endif /*VK_USE_PLATFORM_SCI*/
}; };
auto depIt = dependencies.find( extension ); auto depIt = dependencies.find( extension );