aboutsummaryrefslogtreecommitdiffstats
path: root/src/glsl/nir
diff options
context:
space:
mode:
Diffstat (limited to 'src/glsl/nir')
-rw-r--r--src/glsl/nir/nir_opt_copy_propagate.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/glsl/nir/nir_opt_copy_propagate.c b/src/glsl/nir/nir_opt_copy_propagate.c
index 96520f8a361..7d8bdd7f2ca 100644
--- a/src/glsl/nir/nir_opt_copy_propagate.c
+++ b/src/glsl/nir/nir_opt_copy_propagate.c
@@ -262,6 +262,12 @@ nir_copy_prop_impl(nir_function_impl *impl)
bool progress = false;
nir_foreach_block(impl, copy_prop_block, &progress);
+
+ if (progress) {
+ nir_metadata_preserve(impl, nir_metadata_block_index |
+ nir_metadata_dominance);
+ }
+
return progress;
}