pan/bi: Ensure CONSTANT srcs have types
authorAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Wed, 15 Apr 2020 00:09:00 +0000 (20:09 -0400)
committerAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Fri, 17 Apr 2020 20:25:35 +0000 (16:25 -0400)
So the next commit is valid.

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4615>

src/panfrost/bifrost/bifrost_compile.c

index 42abe567ee744a7b844382069b2c7cbe123d2e78..53bb703aeaaba839d380112713dafb8555f7030f 100644 (file)
@@ -74,6 +74,7 @@ bi_load(enum bi_class T, nir_intrinsic_instr *instr)
                 .type = T,
                 .writemask = bi_mask_for_channels_32(instr->num_components),
                 .src = { BIR_INDEX_CONSTANT },
+                .src_types = { nir_type_uint32 },
                 .constant = { .u64 = nir_intrinsic_base(instr) },
         };
 
@@ -245,6 +246,7 @@ bi_emit_sysval(bi_context *ctx, nir_instr *instr,
                 .type = BI_LOAD_UNIFORM,
                 .writemask = (1 << (nr_components * 4)) - 1,
                 .src = { BIR_INDEX_CONSTANT, BIR_INDEX_ZERO },
+                .src_types = { nir_type_uint32, nir_type_uint32 },
                 .constant = { (uniform * 16) + offset },
                 .dest = bir_dest_index(&nir_dest),
                 .dest_type = nir_type_uint32, /* TODO */