radv: Add driconf to always drain waves before writing timestamps
authorFriedrich Vock <friedrich.vock@gmx.de>
Wed, 3 May 2023 10:20:39 +0000 (12:20 +0200)
committerMarge Bot <emma+marge@anholt.net>
Wed, 3 May 2023 15:24:00 +0000 (15:24 +0000)
commit0b251d43622391cbffad4a4e748e41223b2344fe
tree631bd4721e139e56dfa7ac63f234fba9a14c4894
parent284e604872205dfce528b7d764f3698478b693f5
radv: Add driconf to always drain waves before writing timestamps

UE4's Vulkan backend uses vkCmdWriteTimestamp with TOP_OF_PIPE
to measure how long a workload took in the GPU Benchmark. This is wrong
and writes the timestamp before the workload is actually finished,
making it seem like the GPU is much faster than it actually is.
This caused subsequent benchmark passes to contain way too big workloads,
which caused soft hangs on slower GPUs.

Fixes GPU hangs with Splitgate during automatic settings configuration.

Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22823>
src/amd/vulkan/radv_instance.c
src/amd/vulkan/radv_private.h
src/amd/vulkan/radv_query.c
src/util/00-radv-defaults.conf
src/util/driconf.h