r600/sfn: Don't deref unused group slots
authorGert Wollny <gert.wollny@collabora.com>
Sun, 18 Jun 2023 07:58:32 +0000 (09:58 +0200)
committerMarge Bot <emma+marge@anholt.net>
Sun, 18 Jun 2023 19:01:01 +0000 (19:01 +0000)
Fixes: e57643cf5 (r600/sfn: Add handling for R600 indirect access alias handling)
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/9219

Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23711>

src/gallium/drivers/r600/sfn/sfn_scheduler.cpp

index fb85022..ef42d78 100644 (file)
@@ -1207,6 +1207,8 @@ bool BlockScheduler::check_array_reads(const AluGroup& group)
                              m_last_direct_array_write);
 
       for (auto alu : group) {
+         if (!alu)
+            continue;
          for (auto& s : alu->sources()) {
             s->accept(visitor);
          }