diff options
author | Timothy Arceri <tarceri@itsqueeze.com> | 2020-05-28 10:59:28 +1000 |
---|---|---|
committer | Marge Bot <eric+marge@anholt.net> | 2020-06-03 02:22:23 +0000 |
commit | 04dbf709edf069bc720d941fab27c53269336bcf (patch) | |
tree | e3c561c6c20d201d7b6cd2da5336afff921807e6 /src/gallium/drivers/v3d/v3d_program.c | |
parent | bc79442f3fa23ecb40fcc67ea3cf4fd73fb0d3fe (diff) |
nir: add callback to nir_remove_dead_variables()
This allows us to do API specific checks before removing variable
without filling nir_remove_dead_variables() with API specific code.
In the following patches we will use this to support the removal
of dead uniforms in GLSL.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Eric Anholt <eric@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4797>
Diffstat (limited to 'src/gallium/drivers/v3d/v3d_program.c')
-rw-r--r-- | src/gallium/drivers/v3d/v3d_program.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gallium/drivers/v3d/v3d_program.c b/src/gallium/drivers/v3d/v3d_program.c index ad6a796866a..dbe3c7b4454 100644 --- a/src/gallium/drivers/v3d/v3d_program.c +++ b/src/gallium/drivers/v3d/v3d_program.c @@ -322,7 +322,7 @@ v3d_uncompiled_shader_create(struct pipe_context *pctx, v3d_optimize_nir(s); - NIR_PASS_V(s, nir_remove_dead_variables, nir_var_function_temp); + NIR_PASS_V(s, nir_remove_dead_variables, nir_var_function_temp, NULL); /* Garbage collect dead instructions */ nir_sweep(s); |