mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-25 08:40:11 +01:00
iris: Don't leak scratch BOs
Fixes: 4d219b0eb3 ("iris: implement scratch space!")
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15897>
This commit is contained in:
parent
394b93bfeb
commit
6ca328988f
1 changed files with 5 additions and 0 deletions
|
|
@ -232,6 +232,11 @@ iris_destroy_context(struct pipe_context *ctx)
|
|||
for (unsigned i = 0; i < ARRAY_SIZE(ice->shaders.scratch_surfs); i++)
|
||||
pipe_resource_reference(&ice->shaders.scratch_surfs[i].res, NULL);
|
||||
|
||||
for (unsigned i = 0; i < ARRAY_SIZE(ice->shaders.scratch_bos); i++) {
|
||||
for (unsigned j = 0; j < ARRAY_SIZE(ice->shaders.scratch_bos[i]); j++)
|
||||
iris_bo_unreference(ice->shaders.scratch_bos[i][j]);
|
||||
}
|
||||
|
||||
iris_destroy_program_cache(ice);
|
||||
if (screen->measure.config)
|
||||
iris_destroy_ctx_measure(ice);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue