nir/zink: use sysvals in `nir_create_passthrough_gs`
authorantonino <antonino.maniscalco@collabora.com>
Mon, 24 Apr 2023 11:46:52 +0000 (13:46 +0200)
committerMarge Bot <emma+marge@anholt.net>
Tue, 25 Apr 2023 13:11:59 +0000 (13:11 +0000)
commita0645e3383ed8476c1bf7e16115395ab6a0de086
tree7b7372e4577e936ff9c1137705c0d5c790da78b1
parentcfd525d09730b82e635608955477a66dc56844c1
nir/zink: use sysvals in `nir_create_passthrough_gs`

Previously the passthrough gs shader loaded some values with uniform
loads using sevaral hardcoded values.

This was not flexible for other drivers and started becoming too
unflexible for zink itself.

Use system values instead and use a lowering pass in zink.

Acked-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22667>
src/compiler/nir/nir.h
src/compiler/nir/nir_intrinsics.py
src/compiler/nir/nir_passthrough_gs.c
src/gallium/drivers/zink/zink_compiler.c
src/gallium/drivers/zink/zink_compiler.h
src/gallium/drivers/zink/zink_program.c