From 586f4a42e78f171c28c3ae37adb8671e09bd74b4 Mon Sep 17 00:00:00 2001 From: Kenneth Graunke Date: Tue, 21 Jun 2016 17:42:59 -0700 Subject: [PATCH] glsl: Propagate invariant/precise after lowering const arrays. The new uniform may need precise as well. Fixes copy propagation of constant array uniforms in Tomb Raider shaders. Cc: mesa-stable@lists.freedesktop.org Signed-off-by: Kenneth Graunke Reviewed-by: Timothy Arceri --- src/compiler/glsl/linker.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/compiler/glsl/linker.cpp b/src/compiler/glsl/linker.cpp index c7cf56eaa0b..3bcb907f9b1 100644 --- a/src/compiler/glsl/linker.cpp +++ b/src/compiler/glsl/linker.cpp @@ -4760,6 +4760,7 @@ link_shaders(struct gl_context *ctx, struct gl_shader_program *prog) ; lower_const_arrays_to_uniforms(prog->_LinkedShaders[i]->ir); + propagate_invariance(prog->_LinkedShaders[i]->ir); } /* Validation for special cases where we allow sampler array indexing -- 2.30.2