panfrost: Make the sysval logic more generic
authorBoris Brezillon <boris.brezillon@collabora.com>
Fri, 14 Jun 2019 07:59:20 +0000 (09:59 +0200)
committerAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Tue, 18 Jun 2019 13:36:07 +0000 (06:36 -0700)
commitbd49c8f0ebaed08b06feadcdb7dadf6b7b64f21f
treed18295742239b57c6d81b2fc93ccf99bfd001ef1
parent296c5fd25db15a535920fc43deea2b279e11c5d6
panfrost: Make the sysval logic more generic

We are about to add support for nir_texop_txs which requires adding a
sysval/uniform containing the texture size. Let's change the
emit_sysval_read() prototype to take a nir_instr object instead of
a nir_intrinsic_instr one so we can re-use this function when emitting
a sysval for a txs instruction.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
src/gallium/drivers/panfrost/midgard/midgard_compile.c