panfrost: Allow passing an explicit UBO index for the sysval UBO
authorBoris Brezillon <boris.brezillon@collabora.com>
Fri, 5 Mar 2021 12:20:03 +0000 (13:20 +0100)
committerMarge Bot <eric+marge@anholt.net>
Thu, 11 Mar 2021 15:10:58 +0000 (15:10 +0000)
commit3559efb9bf5cb69c9ddad377ed121685954f10f1
treea01c903f02b24a4b39df4b542b5d0588f90237b9
parent92d9f090d9faa83a6f3215682f6b7a5a6844b160
panfrost: Allow passing an explicit UBO index for the sysval UBO

UBO index assignment is a bit special in Vulkan, it's based on the
descriptor set layout, which doesn't know about shaders' internal UBOs
(our sysval UBOs). Extend the backend compilers so we can place sysval
UBOs where we want: after all explicit UBOs.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9517>
src/panfrost/bifrost/bifrost_compile.c
src/panfrost/lib/pan_shader.c
src/panfrost/midgard/midgard_compile.c
src/panfrost/util/pan_ir.h