From: Alyssa Rosenzweig Date: Mon, 3 May 2021 16:11:26 +0000 (-0400) Subject: pan/bi: Add single-component 8-bit mkvec lowering X-Git-Tag: upstream/21.2.3~3854 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=e180374ab131374043d5ae5405238cd30f52bcbd;p=platform%2Fupstream%2Fmesa.git pan/bi: Add single-component 8-bit mkvec lowering So we can implement scalar i2i8. Signed-off-by: Alyssa Rosenzweig Part-of: --- diff --git a/src/panfrost/bifrost/bifrost_compile.c b/src/panfrost/bifrost/bifrost_compile.c index a27a7dc..6584cc4 100644 --- a/src/panfrost/bifrost/bifrost_compile.c +++ b/src/panfrost/bifrost/bifrost_compile.c @@ -323,6 +323,10 @@ bi_make_vec_to(bi_builder *b, bi_index final_dst, } } else if (bitsize == 16) { bi_make_vec16_to(b, dst, src, channel, count); + } else if (bitsize == 8 && count == 1) { + bi_swz_v4i8_to(b, dst, bi_byte( + bi_word(src[0], channel[0] >> 2), + channel[0] & 3)); } else { unreachable("8-bit mkvec not yet supported"); }