radv: rely on non-NULL binaries when inserting shaders to the cache
authorSamuel Pitoiset <samuel.pitoiset@gmail.com>
Fri, 6 Jan 2023 08:27:30 +0000 (09:27 +0100)
committerMarge Bot <emma+marge@anholt.net>
Tue, 4 Apr 2023 14:47:39 +0000 (14:47 +0000)
commitba967e1a28c179d32ba0af2fb61759fd32a353d7
treed03705464ca5d8058bd7283cad733219e36a7596
parent1239fcab4d3ebbb9f225c17af41a6f6ee6178f01
radv: rely on non-NULL binaries when inserting shaders to the cache

With GPL, a stage can be imported from a library which means that the
binary is NULL (it's freed right after compilation) but the shader is
non-NULL. To avoid crashing, rely on non-NULL binaries because this
implies that the shader is non-NULL as well.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22264>
src/amd/vulkan/radv_pipeline_cache.c