summaryrefslogtreecommitdiffstats
path: root/src/glsl/nir/nir_opt_dce.c
diff options
context:
space:
mode:
authorJason Ekstrand <[email protected]>2014-12-12 16:25:38 -0800
committerJason Ekstrand <[email protected]>2015-01-15 07:20:21 -0800
commit295faf9462cba88250d8581f65611996eba5e389 (patch)
treeaafe263df770d4596119f8b62547a96430fead15 /src/glsl/nir/nir_opt_dce.c
parentb6c81b3ff453d51898f86a819f80ea1128aea0fe (diff)
nir: Call nir_metadata_preserve more places
Reviewed-by: Connor Abbott <[email protected]>
Diffstat (limited to 'src/glsl/nir/nir_opt_dce.c')
-rw-r--r--src/glsl/nir/nir_opt_dce.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/glsl/nir/nir_opt_dce.c b/src/glsl/nir/nir_opt_dce.c
index 365a8cd75df..8a7490dc3e0 100644
--- a/src/glsl/nir/nir_opt_dce.c
+++ b/src/glsl/nir/nir_opt_dce.c
@@ -166,6 +166,10 @@ nir_opt_dce_impl(nir_function_impl *impl)
bool progress = false;
nir_foreach_block(impl, delete_block_cb, &progress);
+ if (progress)
+ nir_metadata_preserve(impl, nir_metadata_block_index |
+ nir_metadata_dominance);
+
return progress;
}