nir/opt_uniform_atomics: require block index metadata

is_atomic_already_optimized() uses this.

Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30518>
This commit is contained in:
Rhys Perry
2024-08-05 12:07:32 +01:00
committed by Marge Bot
parent 373851e7ee
commit 810808b778

View File

@@ -369,6 +369,8 @@ nir_opt_uniform_atomics(nir_shader *shader)
return false;
nir_foreach_function_impl(impl, shader) {
nir_metadata_require(impl, nir_metadata_block_index);
if (opt_uniform_atomics(impl)) {
progress = true;
nir_metadata_preserve(impl, nir_metadata_none);