bifrost: Add support for nir_op_ishl
authorChris Forbes <chrisforbes@google.com>
Sun, 26 Jul 2020 19:18:54 +0000 (12:18 -0700)
committerMarge Bot <eric+marge@anholt.net>
Tue, 28 Jul 2020 01:13:09 +0000 (01:13 +0000)
commit946ff9b439660cb762072da615f040f8aa433267
treed777b42b9d89df63bd4881996359fc603e2852a1
parent539ea0873688da083a0e5ae3e4f887c48070ce31
bifrost: Add support for nir_op_ishl

Bifrost's bitwise ops include the shift capability. Previously we had
hardcoded the shift to zero in all cases.

There's room in future to emit slightly better code if a shift and a
bitwise operation can be folded together, but not going after that for
now.

This change also removes the separate BI_SHIFT instruction class as
BI_BITWISE can cover both cases.

Signed-off-by: Chris Forbes <chrisforbes@google.com>
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6091>
src/panfrost/bifrost/bi_pack.c
src/panfrost/bifrost/bi_print.c
src/panfrost/bifrost/bi_tables.c
src/panfrost/bifrost/bifrost_compile.c
src/panfrost/bifrost/compiler.h