summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/llvmpipe
diff options
context:
space:
mode:
authorDave Airlie <[email protected]>2020-04-15 10:45:47 +1000
committerDave Airlie <[email protected]>2020-04-16 06:25:46 +1000
commitbefe2ff3a610c468fb0bbb67624cc5b531a3fefe (patch)
tree683b1c92764a707c9b5bbb54782416894049f7b5 /src/gallium/drivers/llvmpipe
parentcb0a2b3df68d33be7c5bfbbb62825608b1b1948e (diff)
llvmpipe/nir: free the nir shader
Fixes: 18f896e55d96 (llvmpipe: add initial nir support) Reviewed-by: Roland Scheidegger <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4563>
Diffstat (limited to 'src/gallium/drivers/llvmpipe')
-rw-r--r--src/gallium/drivers/llvmpipe/lp_state_fs.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/gallium/drivers/llvmpipe/lp_state_fs.c b/src/gallium/drivers/llvmpipe/lp_state_fs.c
index cb1627849d0..f55cfa9a85d 100644
--- a/src/gallium/drivers/llvmpipe/lp_state_fs.c
+++ b/src/gallium/drivers/llvmpipe/lp_state_fs.c
@@ -3138,6 +3138,8 @@ llvmpipe_delete_fs_state(struct pipe_context *pipe, void *fs)
/* Delete draw module's data */
draw_delete_fragment_shader(llvmpipe->draw, shader->draw_data);
+ if (shader->base.ir.nir)
+ ralloc_free(shader->base.ir.nir);
assert(shader->variants_cached == 0);
FREE((void *) shader->base.tokens);
FREE(shader);