Skip to content

Commit

Permalink
Exclude vkEnumInstanceExtProps from dispatch (#51)
Browse files Browse the repository at this point in the history
vkEnumerateInstanceExtensionProperties is resolved by the loader, so
do not dynamically query the instance to add it to the instance
dispatch table.
  • Loading branch information
solidpixel authored Jan 12, 2025
1 parent 97bf665 commit 4982028
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
5 changes: 3 additions & 2 deletions generator/generate_vulkan_common.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@

# These functions are excluded from generated intercept tables
NO_INTERCEPT_FUNCTIONS = {
# Functions exported as shared object exports and resolved by loader
# Functions exported as shared object symbols and resolved by loader
'vkEnumerateDeviceExtensionProperties',
'vkEnumerateDeviceLayerProperties',
'vkEnumerateInstanceExtensionProperties',
Expand All @@ -57,9 +57,10 @@

# These functions are excluded from generated dispatch tables
NO_DISPATCH_FUNCTIONS = {
# Functions resolved by the loaded not the implementation
# Functions resolved by the loader not the implementation
'vkCreateDevice',
'vkCreateInstance',
'vkEnumerateInstanceExtensionProperties',
}

# These functions are excluded from generated declarations
Expand Down
2 changes: 0 additions & 2 deletions source_common/framework/instance_dispatch_table.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -605,7 +605,6 @@ struct InstanceDispatchTable {
PFN_vkDestroySurfaceKHR vkDestroySurfaceKHR;
PFN_vkEnumerateDeviceExtensionProperties vkEnumerateDeviceExtensionProperties;
PFN_vkEnumerateDeviceLayerProperties vkEnumerateDeviceLayerProperties;
PFN_vkEnumerateInstanceExtensionProperties vkEnumerateInstanceExtensionProperties;
PFN_vkEnumerateInstanceLayerProperties vkEnumerateInstanceLayerProperties;
PFN_vkEnumeratePhysicalDeviceGroups vkEnumeratePhysicalDeviceGroups;
PFN_vkEnumeratePhysicalDeviceGroupsKHR vkEnumeratePhysicalDeviceGroupsKHR;
Expand Down Expand Up @@ -697,7 +696,6 @@ static inline void initDriverInstanceDispatchTable(
ENTRY(vkDestroySurfaceKHR);
ENTRY(vkEnumerateDeviceExtensionProperties);
ENTRY(vkEnumerateDeviceLayerProperties);
ENTRY(vkEnumerateInstanceExtensionProperties);
ENTRY(vkEnumerateInstanceLayerProperties);
ENTRY(vkEnumeratePhysicalDeviceGroups);
ENTRY(vkEnumeratePhysicalDeviceGroupsKHR);
Expand Down

0 comments on commit 4982028

Please sign in to comment.