zink: always create descriptor templates

the 'notemplates' debug mode is somewhat misleading since there's no
uncached+notemplates mechanism, meaning that if the descriptor cache
explodes it'll still use templates for updating in the fallback path

Fixes: 4e3768914d ("zink: add ZINK_DESCRIPTORS env var to explicitly set a mode")

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16927>
This commit is contained in:
Mike Blumenkrantz 2022-06-08 13:52:47 -04:00 committed by Marge Bot
parent 3156a5705d
commit ee1a0a0772
1 changed files with 2 additions and 1 deletions

View File

@ -302,7 +302,8 @@ zink_descriptor_program_init_lazy(struct zink_context *ctx, struct zink_program
pg->layout = zink_pipeline_layout_create(screen, pg, &pg->compat_id);
if (!pg->layout)
return false;
if (!screen->info.have_KHR_descriptor_update_template || screen->descriptor_mode == ZINK_DESCRIPTOR_MODE_NOTEMPLATES)
/* TODO: figure out uncached+notemplate and return on screen->descriptor_mode == ZINK_DESCRIPTOR_MODE_NOTEMPLATES */
if (!screen->info.have_KHR_descriptor_update_template)
return true;
VkDescriptorUpdateTemplateCreateInfo template[ZINK_DESCRIPTOR_TYPES + 1] = {0};