pan/bi: Flesh out BI_BLEND
authorAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Thu, 19 Mar 2020 03:12:23 +0000 (23:12 -0400)
committerMarge Bot <eric+marge@anholt.net>
Thu, 19 Mar 2020 03:23:07 +0000 (03:23 +0000)
It ingests the output of ATEST, whatever that actually is.

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

src/panfrost/bifrost/bifrost_compile.c

index e19f0961e9be60ba324a3a0cfff39f6411208dfc..0755d1313fc5bd18677f047860b4205c548dd89e 100644 (file)
@@ -147,14 +147,20 @@ bi_emit_frag_out(bi_context *ctx, nir_intrinsic_instr *instr)
                 .type = BI_BLEND,
                 .blend_location = nir_intrinsic_base(instr),
                 .src = {
+                        BIR_INDEX_REGISTER | 60 /* Can this be arbitrary? */,
                         bir_src_index(&instr->src[0])
                 },
                 .src_types = {
+                        nir_type_uint32,
                         nir_type_float32,
                 },
                 .swizzle = {
+                        { 0 },
                         { 0, 1, 2, 3 }
-                }
+                },
+                .dest = BIR_INDEX_REGISTER | 48 /* Looks like magic */,
+                .dest_type = nir_type_uint32,
+                .writemask = 0xF
         };
 
         bi_emit(ctx, blend);