From: Rob Clark <robcl...@freedesktop.org>

Just because there is array access, doesn't mean everything is an array.

Signed-off-by: Rob Clark <robcl...@freedesktop.org>
---
 src/gallium/auxiliary/nir/tgsi_to_nir.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/gallium/auxiliary/nir/tgsi_to_nir.c 
b/src/gallium/auxiliary/nir/tgsi_to_nir.c
index da935a4..57a7b03 100644
--- a/src/gallium/auxiliary/nir/tgsi_to_nir.c
+++ b/src/gallium/auxiliary/nir/tgsi_to_nir.c
@@ -121,7 +121,7 @@ ttn_emit_declaration(struct ttn_compile *c)
 
    if (file == TGSI_FILE_TEMPORARY) {
       nir_register *reg;
-      if (c->scan->indirect_files & (1 << file)) {
+      if (decl->Declaration.Array) {
          reg = nir_local_reg_create(b->impl);
          reg->num_components = 4;
          reg->num_array_elems = array_size;
-- 
2.1.0

_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to