intel/rt: Implement push constants as global memory reads
authorJason Ekstrand <jason@jlekstrand.net>
Fri, 7 Aug 2020 03:17:17 +0000 (22:17 -0500)
committerMarge Bot <eric+marge@anholt.net>
Wed, 25 Nov 2020 05:37:10 +0000 (05:37 +0000)
commit9fa1cdfe7ffd9e7ebd83055e2008f3e4b8ada549
treefe795e28df4bede11bd4aea240afaf0ab302155d
parentf7e24e559fb632eae54e444b022db9da35922258
intel/rt: Implement push constants as global memory reads

They're not really "push" anymore but that's because there is no such
thing as push constants in bindless shaders on Intel.  They should be
fast enough, though.  There is some room for debate here as to whether
we want to do the pull in NIR or push it into the back-end.  The
advantage of doing it in the back-end is that it'd be easier to use
MOV_INDIRECT for indirect push constant access rather than falling back
to a dataport message.

Reviewed-by: Caio Marcelo de Oliveira Filho <caio.oliveira@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7356>
src/compiler/nir/nir_builder.h
src/intel/compiler/brw_nir_lower_rt_intrinsics.c
src/intel/compiler/brw_rt.h