From fe413962b4dd89ec5be539b13e7cbf7f871dd04a Mon Sep 17 00:00:00 2001 From: Lionel Landwerlin Date: Wed, 13 Apr 2022 11:42:45 +0300 Subject: [PATCH] anv: skip acceleration structure in binding table emission With mutable descriptor types, we can end up in a situation where a binding can be, for instance, both a UBO and an acceleration structure. While we can promote the UBO to a binding table entry and the shader can use it, this isn't true of acceleration structures that have no surface state. In that case just skip the entry. The shader is already compiled to use the descriptor entry. In the non mutable case, the entry will not be created by anv_nir_apply_pipeline_layout. Signed-off-by: Lionel Landwerlin Fixes: 63e91148b7fe ("anv: Enable VK_VALVE_mutable_descriptor_type") Reviewed-by: Rohan Garg Part-of: --- src/intel/vulkan/genX_cmd_buffer.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/intel/vulkan/genX_cmd_buffer.c b/src/intel/vulkan/genX_cmd_buffer.c index 0f3caa24f6d..0faa2163eed 100644 --- a/src/intel/vulkan/genX_cmd_buffer.c +++ b/src/intel/vulkan/genX_cmd_buffer.c @@ -2689,6 +2689,7 @@ emit_binding_table(struct anv_cmd_buffer *cmd_buffer, const struct anv_descriptor *desc = &set->descriptors[binding->index]; switch (desc->type) { + case VK_DESCRIPTOR_TYPE_ACCELERATION_STRUCTURE_KHR: case VK_DESCRIPTOR_TYPE_SAMPLER: /* Nothing for us to do here */ continue;