zink: combine loops for lazy descriptor program deinit

the bindless and push sets don't have update templates stored to
the program, so merging these loops avoids trying to destroy them

cc: mesa-stable

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17866>
This commit is contained in:
Mike Blumenkrantz 2022-08-02 08:18:34 -04:00 committed by Marge Bot
parent 7450990558
commit e13c9d2168

View file

@ -359,8 +359,6 @@ zink_descriptor_program_deinit_lazy(struct zink_context *ctx, struct zink_progra
for (unsigned i = 0; pg->num_dsl && i < ZINK_DESCRIPTOR_TYPES; i++) {
if (pg->dd->pool_key[i])
pg->dd->pool_key[i]->use_count--;
}
for (unsigned i = 0; i < pg->num_dsl; i++) {
if (pg->dd->templates[i])
VKSCR(DestroyDescriptorUpdateTemplate)(screen->dev, pg->dd->templates[i], NULL);
}