panfrost,panvk: Make fixed_sysval_ubo < 0 mean compiler-assigned
authorJason Ekstrand <jason.ekstrand@collabora.com>
Wed, 4 May 2022 16:25:33 +0000 (11:25 -0500)
committerMarge Bot <emma+marge@anholt.net>
Thu, 12 May 2022 10:53:15 +0000 (10:53 +0000)
commit4e60f0655a831cae0cbf6de99994c6cf56ce28ce
tree87a48d58251db055e34dc9093df9ff75c690a307
parent42aca84704a36a6a9c52552c4dde77ef4c528a69
panfrost,panvk: Make fixed_sysval_ubo < 0 mean compiler-assigned

In 3559efb9bf5c ("panfrost: Allow passing an explicit UBO index for the
sysval UBO"), an explicit UBO index was added and it was implicitly
assumed that it would be > num_ubos.  This was convenient because it
meant 0, the default for designated initializers, implicitly meant
compiler-assigned.  However, we're about to move the sysval UBO to 0
which breaks this assumption.   Also, we don't want the back-end
compiler to even look at num_ubos since it's meaningless in Vulkan.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16276>
src/gallium/drivers/panfrost/pan_assemble.c
src/panfrost/bifrost/bifrost_compile.c
src/panfrost/bifrost/cmdline.c
src/panfrost/lib/pan_blend.c
src/panfrost/lib/pan_blitter.c
src/panfrost/lib/pan_indirect_dispatch.c
src/panfrost/lib/pan_indirect_draw.c
src/panfrost/lib/pan_shader.c
src/panfrost/midgard/midgard_compile.c
src/panfrost/util/pan_ir.h
src/panfrost/vulkan/panvk_vX_shader.c