summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJason Ekstrand <jason@jlekstrand.net>2020-06-10 17:53:18 -0500
committerMarge Bot <eric+marge@anholt.net>2020-07-06 19:54:30 +0000
commit96d99f2eccb4bea4b9ede38f9b2e472cdc617e99 (patch)
treebfdb0297e8a19d946fcb9f302e8f329e869d735a
parent786325fdb02b6561f243c82d359da8e5b3360a73 (diff)
vc4: Only call nir_lower_io on shader_in/out
Gallium drivers should never see nir_var_uniform because gallium lowers regular uniforms to a UBO. No GL driver should ever see either nir_var_mem_shared because that's lowered in GLSL IR. Reviewed-by: Eric Anholt <eric@anholt.net> Reviewed-by: Connor Abbott <cwabbott0@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5418>
-rw-r--r--src/gallium/drivers/vc4/vc4_program.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gallium/drivers/vc4/vc4_program.c b/src/gallium/drivers/vc4/vc4_program.c
index b06bd89963c..3ad81a05909 100644
--- a/src/gallium/drivers/vc4/vc4_program.c
+++ b/src/gallium/drivers/vc4/vc4_program.c
@@ -2470,8 +2470,8 @@ vc4_shader_state_create(struct pipe_context *pctx,
if (s->info.stage == MESA_SHADER_VERTEX)
NIR_PASS_V(s, nir_lower_point_size, 1.0f, 0.0f);
- NIR_PASS_V(s, nir_lower_io, nir_var_all, type_size,
- (nir_lower_io_options)0);
+ NIR_PASS_V(s, nir_lower_io, nir_var_shader_in | nir_var_shader_out,
+ type_size, (nir_lower_io_options)0);
NIR_PASS_V(s, nir_lower_regs_to_ssa);
NIR_PASS_V(s, nir_normalize_cubemap_coords);