panfrost: Add optional opaque packs to GenXML
authorAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Fri, 21 Aug 2020 22:11:57 +0000 (18:11 -0400)
committerTomeu Vizoso <tomeu.vizoso@collabora.com>
Tue, 25 Aug 2020 15:05:39 +0000 (17:05 +0200)
commit100b15cdc827feb5b9339502af9a3b10cc31a059
tree2124f5fa76cb8c09de8fd2244057417c012f0eb7
parenta7b2317d0a06c0c4c7f0fb2d7ab0c72f68ce6383
panfrost: Add optional opaque packs to GenXML

These special OPAQUE packs use packed structs in the struct template,
instead of struct templates. The use case is packing nested structs
out-of-band, to fit into the CSO model.

A more conventional GenXML solution would be an overlapping uint, but
this breaks our assumptions about struct packing which are otherwise
correct, so this seemed less intrusive than risk disrupting the main
pack routines.

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6440>
src/panfrost/lib/gen_pack.py