mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-06 08:50:09 +01:00
nir/lower_indirect: Bail early if modes == 0
There's no point in walking the program if we're never going to actually lower anything. Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
This commit is contained in:
parent
4434591bf5
commit
7f75cf2a94
1 changed files with 3 additions and 0 deletions
|
|
@ -205,6 +205,9 @@ nir_lower_indirect_derefs(nir_shader *shader, nir_variable_mode modes)
|
|||
{
|
||||
bool progress = false;
|
||||
|
||||
if (modes == 0)
|
||||
return false;
|
||||
|
||||
nir_foreach_function(function, shader) {
|
||||
if (function->impl)
|
||||
progress = lower_indirects_impl(function->impl, modes) || progress;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue