summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/vc4/vc4_program.c
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2016-05-05 18:11:04 -0700
committerEric Anholt <eric@anholt.net>2016-07-13 23:54:15 -0700
commit9194473dd260fe72042807a97be0072c6f0537da (patch)
tree73bee220f5de595738a4f831b353c2444b0e642a /src/gallium/drivers/vc4/vc4_program.c
parent44df061aaad96fc5db630ae69fb2fe2a03bb5659 (diff)
downloadexternal_mesa3d-9194473dd260fe72042807a97be0072c6f0537da.zip
external_mesa3d-9194473dd260fe72042807a97be0072c6f0537da.tar.gz
external_mesa3d-9194473dd260fe72042807a97be0072c6f0537da.tar.bz2
vc4: Emit resets of the uniform stream at the starts of blocks.
If a block might be entered from multiple locations, then the uniform stream will (probably) be at different points, and we need to make sure that it's pointing where we expect it to be. The kernel also enforces that any block reading a uniform resets uniforms, to prevent reading outside of the uniform stream by using looping.
Diffstat (limited to 'src/gallium/drivers/vc4/vc4_program.c')
-rw-r--r--src/gallium/drivers/vc4/vc4_program.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/gallium/drivers/vc4/vc4_program.c b/src/gallium/drivers/vc4/vc4_program.c
index 465e052..521f971 100644
--- a/src/gallium/drivers/vc4/vc4_program.c
+++ b/src/gallium/drivers/vc4/vc4_program.c
@@ -2114,6 +2114,7 @@ vc4_shader_ntq(struct vc4_context *vc4, enum qstage stage,
qir_lower_uniforms(c);
qir_schedule_instructions(c);
+ qir_emit_uniform_stream_resets(c);
if (vc4_debug & VC4_DEBUG_QIR) {
fprintf(stderr, "%s prog %d/%d QIR:\n",