descriptorBindingUniformBufferUpdateAfterBind is false for Intel Skylake (and maybe others).
Signed-off-by: Conor McCarthy cmccarthy@codeweavers.com --- libs/vkd3d/device.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/libs/vkd3d/device.c b/libs/vkd3d/device.c index bd471a72..459aa615 100644 --- a/libs/vkd3d/device.c +++ b/libs/vkd3d/device.c @@ -1657,7 +1657,12 @@ static HRESULT vkd3d_init_device_caps(struct d3d12_device *device, * use only enough descriptors for the descriptor tables of the currently bound * root signature, and don't require a 32-bit push constant for each table. */ device->use_vk_heaps = vulkan_info->EXT_descriptor_indexing - && !(device->vkd3d_instance->config_flags & VKD3D_CONFIG_FLAG_VIRTUAL_HEAPS); + && !(device->vkd3d_instance->config_flags & VKD3D_CONFIG_FLAG_VIRTUAL_HEAPS) + && descriptor_indexing->descriptorBindingUniformBufferUpdateAfterBind + && descriptor_indexing->descriptorBindingSampledImageUpdateAfterBind + && descriptor_indexing->descriptorBindingStorageImageUpdateAfterBind + && descriptor_indexing->descriptorBindingUniformTexelBufferUpdateAfterBind + && descriptor_indexing->descriptorBindingStorageTexelBufferUpdateAfterBind;
if (device->use_vk_heaps) vkd3d_device_vk_heaps_descriptor_limits_init(&vulkan_info->descriptor_limits,
The pointer is never NULL.
Signed-off-by: Conor McCarthy cmccarthy@codeweavers.com --- libs/vkd3d/device.c | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-)
diff --git a/libs/vkd3d/device.c b/libs/vkd3d/device.c index 459aa615..d1629284 100644 --- a/libs/vkd3d/device.c +++ b/libs/vkd3d/device.c @@ -1629,16 +1629,13 @@ static HRESULT vkd3d_init_device_caps(struct d3d12_device *device, features->shaderTessellationAndGeometryPointSize = VK_FALSE;
descriptor_indexing = &physical_device_info->descriptor_indexing_features; - if (descriptor_indexing) - { - descriptor_indexing->shaderInputAttachmentArrayDynamicIndexing = VK_FALSE; - descriptor_indexing->shaderInputAttachmentArrayNonUniformIndexing = VK_FALSE; + descriptor_indexing->shaderInputAttachmentArrayDynamicIndexing = VK_FALSE; + descriptor_indexing->shaderInputAttachmentArrayNonUniformIndexing = VK_FALSE;
- /* We do not use storage buffers currently. */ - features->shaderStorageBufferArrayDynamicIndexing = VK_FALSE; - descriptor_indexing->shaderStorageBufferArrayNonUniformIndexing = VK_FALSE; - descriptor_indexing->descriptorBindingStorageBufferUpdateAfterBind = VK_FALSE; - } + /* We do not use storage buffers currently. */ + features->shaderStorageBufferArrayDynamicIndexing = VK_FALSE; + descriptor_indexing->shaderStorageBufferArrayNonUniformIndexing = VK_FALSE; + descriptor_indexing->descriptorBindingStorageBufferUpdateAfterBind = VK_FALSE;
if (vulkan_info->EXT_descriptor_indexing && descriptor_indexing && (descriptor_indexing->descriptorBindingUniformBufferUpdateAfterBind
Signed-off-by: Henri Verbeet hverbeet@codeweavers.com
On Tue, 22 Mar 2022 at 15:33, Conor McCarthy cmccarthy@codeweavers.com wrote:
descriptorBindingUniformBufferUpdateAfterBind is false for Intel Skylake (and maybe others).
For what's it's worth, Giovanni also ran into this issue on NVIDIA. It would be a bit unfortunate if the new implementation would only be usable on AMD/radv. Is it feasible to split this per descriptor type, or otherwise salvage the approach for the affected hardware/drivers?
March 24, 2022 1:37 AM, "Henri Verbeet" hverbeet@gmail.com wrote:
For what's it's worth, Giovanni also ran into this issue on NVIDIA. It would be a bit unfortunate if the new implementation would only be usable on AMD/radv. Is it feasible to split this per descriptor type, or otherwise salvage the approach for the affected hardware/drivers?
It looks like storage buffers will work as a substitute, if descriptorBindingUniformBufferUpdateAfterBind is true for them (I have no hardware to check).
Hi,
Il 24/03/22 02:16, Conor McCarthy ha scritto:
It looks like storage buffers will work as a substitute, if descriptorBindingUniformBufferUpdateAfterBind is true for them (I have no hardware to check).
My NVIDIA Quadro P2000 does not seem to have it, unfortunately. Interestingly, all flags in VkPhysicalDeviceDescriptorIndexingFeatures from vulkaninfo are true, except for that one.
BTW, https://vulkan.gpuinfo.org/ is a good resource to know which features are advertised for each combination of hardware and driver, though it has so much data that sometimes it is a big daunting to get what you need.
Giovanni.