aboutsummaryrefslogtreecommitdiffstats
path: root/src/intel/vulkan/anv_pipeline.c
diff options
context:
space:
mode:
authorJason Ekstrand <[email protected]>2016-06-16 10:57:39 -0700
committerJason Ekstrand <[email protected]>2016-06-20 12:02:58 -0700
commite6c2fe451962e364f30f689dc48c34e2b6161b25 (patch)
tree45597c9477e0651a590e3dd904b6946d7029a4c6 /src/intel/vulkan/anv_pipeline.c
parentbec07b729242f6a2dcf5a12ce75bf8b07ea658e0 (diff)
anv/pipeline: Do invariance propagation on SPIR-V shaders
Signed-off-by: Jason Ekstrand <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]> Cc: "12.0" <[email protected]>
Diffstat (limited to 'src/intel/vulkan/anv_pipeline.c')
-rw-r--r--src/intel/vulkan/anv_pipeline.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/intel/vulkan/anv_pipeline.c b/src/intel/vulkan/anv_pipeline.c
index b41e11e5dca..1c54081d47c 100644
--- a/src/intel/vulkan/anv_pipeline.c
+++ b/src/intel/vulkan/anv_pipeline.c
@@ -165,6 +165,9 @@ anv_shader_compile_to_nir(struct anv_device *device,
nir_remove_dead_variables(nir, nir_var_system_value);
nir_validate_shader(nir);
+ nir_propagate_invariant(nir);
+ nir_validate_shader(nir);
+
nir_lower_io_to_temporaries(entry_point->shader, entry_point, true, false);
nir_lower_system_values(nir);