Mesa (main): nir: call nir_metadata_preserve in nir_vectorize_tess_levels

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Thu May 19 14:36:43 UTC 2022


Module: Mesa
Branch: main
Commit: 3eed871f41fd7d590c57c684ca841a61513b7b8d
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=3eed871f41fd7d590c57c684ca841a61513b7b8d

Author: Rhys Perry <pendingchaos02 at gmail.com>
Date:   Wed Aug 18 14:24:50 2021 +0100

nir: call nir_metadata_preserve in nir_vectorize_tess_levels

This is necessary to use this pass with the NIR_PASS() macro.

Signed-off-by: Rhys Perry <pendingchaos02 at gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12448>

---

 src/compiler/nir/nir_lower_io_to_vector.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/src/compiler/nir/nir_lower_io_to_vector.c b/src/compiler/nir/nir_lower_io_to_vector.c
index e49fda5d587..e17f6ddb158 100644
--- a/src/compiler/nir/nir_lower_io_to_vector.c
+++ b/src/compiler/nir/nir_lower_io_to_vector.c
@@ -677,6 +677,11 @@ nir_vectorize_tess_levels_impl(nir_function_impl *impl)
       }
    }
 
+   if (progress)
+      nir_metadata_preserve(impl, nir_metadata_block_index | nir_metadata_dominance);
+   else
+      nir_metadata_preserve(impl, nir_metadata_all);
+
    return progress;
 }
 



More information about the mesa-commit mailing list