projects
/
platform
/
upstream
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ba17342
)
pan/bi: Add single-component 8-bit mkvec lowering
author
Alyssa Rosenzweig
<alyssa@collabora.com>
Mon, 3 May 2021 16:11:26 +0000
(12:11 -0400)
committer
Marge Bot
<eric+marge@anholt.net>
Tue, 4 May 2021 20:04:03 +0000
(20:04 +0000)
So we can implement scalar i2i8.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10393>
src/panfrost/bifrost/bifrost_compile.c
patch
|
blob
|
history
diff --git
a/src/panfrost/bifrost/bifrost_compile.c
b/src/panfrost/bifrost/bifrost_compile.c
index
a27a7dc
..
6584cc4
100644
(file)
--- 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");
}