nir: add single bit test opcodes
authorGeorg Lehmann <dadschoorse@gmail.com>
Sat, 27 May 2023 09:27:12 +0000 (11:27 +0200)
committerMarge Bot <emma+marge@anholt.net>
Thu, 29 Jun 2023 13:39:30 +0000 (13:39 +0000)
commit481a34e82e4a50e4ba2f8923c3d469fa506a1006
tree925fa8eec031520c2847891f7d27f42b74b6d7b7
parent9ca1bb3cf8f2f4d9378ceb8ae39e6f853fb900b0
nir: add single bit test opcodes

These directly map to amd's SALU s_bitcmp0/1.
For VALU we can use v_cmp_class_f32 if the second source is constant.

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23298>
src/compiler/nir/nir.c
src/compiler/nir/nir_opcodes.py