mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-09 12:40:23 +01:00
zink: destroy shader modules on program free to avoid leaking
it's irrelevant whether the shader pointer is valid, the shader cache
may still exist
Fixes: a92442225c ("zink: split up shader cache per-stage")
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12650>
This commit is contained in:
parent
eb7eccc76f
commit
b7534fe82a
1 changed files with 1 additions and 1 deletions
|
|
@ -683,8 +683,8 @@ zink_destroy_gfx_program(struct zink_screen *screen,
|
|||
if (prog->shaders[i]) {
|
||||
_mesa_set_remove_key(prog->shaders[i]->programs, prog);
|
||||
prog->shaders[i] = NULL;
|
||||
destroy_shader_cache(screen, &prog->base.shader_cache[i]);
|
||||
}
|
||||
destroy_shader_cache(screen, &prog->base.shader_cache[i]);
|
||||
ralloc_free(prog->nir[i]);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue