r600: preserve all metadata when passes don't make progress

Signed-off-by: Marcin Ślusarz <marcin.slusarz@intel.com>
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12467>
This commit is contained in:
Marcin Ślusarz 2021-08-10 14:40:41 +02:00 committed by Marge Bot
parent 956d6461ef
commit 8892d276d2
2 changed files with 4 additions and 0 deletions

View File

@ -142,6 +142,8 @@ bool NirLowerIOToVector::run(nir_function_impl *impl)
bool progress = vectorize_block(&b, nir_start_block(impl));
if (progress) {
nir_metadata_preserve(impl, nir_metadata_block_index | nir_metadata_dominance);
} else {
nir_metadata_preserve(impl, nir_metadata_all);
}
return progress;
}

View File

@ -443,6 +443,8 @@ r600_vectorize_io_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);
}
r600_vec_instr_set_destroy(instr_set);