mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 19:58:09 +02:00
agx: Allow some 8-bit sources
8-bit sources are useful for int8->float32 conversions, which we can do in a single hardware instruction. Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19996>
This commit is contained in:
parent
ba209fe493
commit
8127737c1e
2 changed files with 2 additions and 1 deletions
|
|
@ -852,7 +852,7 @@ agx_alu_src_index(agx_builder *b, nir_alu_src src)
|
|||
unsigned comps = nir_src_num_components(src.src);
|
||||
unsigned channel = src.swizzle[0];
|
||||
|
||||
assert(bitsize == 1 || bitsize == 16 || bitsize == 32 || bitsize == 64);
|
||||
assert(bitsize == 1 || bitsize == 8 || bitsize == 16 || bitsize == 32 || bitsize == 64);
|
||||
assert(!(src.negate || src.abs));
|
||||
assert(channel < comps);
|
||||
|
||||
|
|
|
|||
|
|
@ -442,6 +442,7 @@ agx_size_for_bits(unsigned bits)
|
|||
{
|
||||
switch (bits) {
|
||||
case 1:
|
||||
case 8:
|
||||
case 16: return AGX_SIZE_16;
|
||||
case 32: return AGX_SIZE_32;
|
||||
case 64: return AGX_SIZE_64;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue