diff --git a/src/panfrost/bifrost/ISA.xml b/src/panfrost/bifrost/ISA.xml index f5174d058bc..fb26ab6315f 100644 --- a/src/panfrost/bifrost/ISA.xml +++ b/src/panfrost/bifrost/ISA.xml @@ -2525,6 +2525,17 @@ + + f16 + f32 + s32 + u32 + s16 + u16 + f64 + i64 + auto + diff --git a/src/panfrost/bifrost/bifrost_compile.c b/src/panfrost/bifrost/bifrost_compile.c index e3a6f761889..26fa88f0f27 100644 --- a/src/panfrost/bifrost/bifrost_compile.c +++ b/src/panfrost/bifrost/bifrost_compile.c @@ -517,6 +517,7 @@ bi_emit_blend_op(bi_builder *b, bi_index rgba, nir_alu_type T, unsigned sr_count_2 = (size_2 <= 16) ? 2 : 4; const struct panfrost_compile_inputs *inputs = b->shader->inputs; uint64_t blend_desc = inputs->blend.bifrost_blend_desc; + enum bi_register_format regfmt = bi_reg_fmt_for_nir(T); if (inputs->is_blend && inputs->blend.nr_samples > 1) { /* Conversion descriptor comes from the compile inputs, pixel @@ -530,7 +531,7 @@ bi_emit_blend_op(bi_builder *b, bi_index rgba, nir_alu_type T, bi_register(60), bi_imm_u32(blend_desc & 0xffffffff), bi_imm_u32(blend_desc >> 32), - bi_null(), sr_count, 0); + bi_null(), regfmt, sr_count, 0); } else { /* Blend descriptor comes from the FAU RAM. By convention, the * return address is stored in r48 and will be used by the @@ -539,7 +540,7 @@ bi_emit_blend_op(bi_builder *b, bi_index rgba, nir_alu_type T, bi_register(60), bi_fau(BIR_FAU_BLEND_0 + rt, false), bi_fau(BIR_FAU_BLEND_0 + rt, true), - rgba2, sr_count, sr_count_2); + rgba2, regfmt, sr_count, sr_count_2); } assert(rt < 8); diff --git a/src/panfrost/bifrost/test/test-scheduler-predicates.cpp b/src/panfrost/bifrost/test/test-scheduler-predicates.cpp index 93aaf7fe196..3a15e50e94d 100644 --- a/src/panfrost/bifrost/test/test-scheduler-predicates.cpp +++ b/src/panfrost/bifrost/test/test-scheduler-predicates.cpp @@ -81,7 +81,8 @@ TEST_F(SchedulerPredicates, LOAD) TEST_F(SchedulerPredicates, BLEND) { - bi_instr *blend = bi_blend_to(b, TMP(), TMP(), TMP(), TMP(), TMP(), TMP(), 4, 4); + bi_instr *blend = bi_blend_to(b, TMP(), TMP(), TMP(), TMP(), TMP(), TMP(), + BI_REGISTER_FORMAT_F32, 4, 4); ASSERT_FALSE(bi_can_fma(blend)); ASSERT_TRUE(bi_can_add(blend)); ASSERT_TRUE(bi_must_message(blend));