nir: require nir_metadata_divergence if needed
Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Reviewed-by: Rhys Perry <pendingchaos02@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30814>
This commit is contained in:
committed by
Marge Bot
parent
01f2d494d0
commit
86fd673ade
@@ -331,7 +331,7 @@ nir_opt_uniform_atomics(nir_shader *shader, bool fs_atomics_predicated)
|
||||
return false;
|
||||
|
||||
nir_foreach_function_impl(impl, shader) {
|
||||
nir_metadata_require(impl, nir_metadata_block_index);
|
||||
nir_metadata_require(impl, nir_metadata_block_index | nir_metadata_divergence);
|
||||
|
||||
if (opt_uniform_atomics(impl, fs_atomics_predicated)) {
|
||||
progress = true;
|
||||
|
||||
@@ -151,6 +151,8 @@ bool
|
||||
nir_opt_uniform_subgroup(nir_shader *shader,
|
||||
const nir_lower_subgroups_options *options)
|
||||
{
|
||||
nir_divergence_analysis(shader);
|
||||
|
||||
bool progress = nir_shader_lower_instructions(shader,
|
||||
opt_uniform_subgroup_filter,
|
||||
opt_uniform_subgroup_instr,
|
||||
|
||||
Reference in New Issue
Block a user