nir: add a bool bitsize lowering pass
authorIago Toral Quiroga <itoral@igalia.com>
Wed, 24 Oct 2018 07:25:29 +0000 (09:25 +0200)
committerMarge Bot <eric+marge@anholt.net>
Tue, 24 Mar 2020 23:21:21 +0000 (23:21 +0000)
commit467c9a0faa0a27a14bbf5fb42bbf806382d2d3f0
treee2003c8f2ede523d85621a0c15d3daf16cdc1e3e
parent75674ed4d4ec868fe116df84be1366b0fcd6c942
nir: add a bool bitsize lowering pass

The pass lowers 1-bit booleans produced by NIR to the native bitsize
of the operations that produce them.

v2: change on lower_load_const_instr after upstream changes. Added
    TODO2 to explain it, as it was not properly tested yet (see
    already existing TODO) (Neil)

Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Kristian H. Kristensen <hoegsberg@google.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3885>
src/compiler/Makefile.sources
src/compiler/nir/meson.build
src/compiler/nir/nir.h
src/compiler/nir/nir_lower_bool_to_bitsize.c [new file with mode: 0644]