st/oxr: disable stencil-only swapchain formats (VK_FORMAT_S8_UINT)
Stencil-only formats cause VK_ERROR_DEVICE_LOST on NVIDIA GPUs when using the compute based pipeline. The failure occurs during image layout barrier transitions in swapchain initialization. Since no OpenXR core or extensions currently require stencil-only swapchains, disable them until a (driver) fix is available. Part-of: <https://gitlab.freedesktop.org/monado/monado/-/merge_requests/2657>
67 unmodified lines686970717273747576777879808182838485868788897290919293941780 unmodified linesExpand all67 unmodified linesstatic boolshould_skip_format_vk_1_and_2(const struct oxr_instance *inst, uint64_t format){ bool skip_depth_stencil = inst->quirks.disable_vulkan_format_depth_stencil; /*! * WARNING: Stencil-only formats have not been thoroughly tested. * * As of writing, when enabled using the compute-pipeline path with * CTS 1.1.53 on Linux with an NVIDIA GPU (driver v580.105.8.0): * * The CTS swapchain creation tests attempt to create a swapchain * with VK_FORMAT_S8_UINT format. The test fails because native * swapchain creation returns VK_ERROR_DEVICE_LOST from * `do_post_create_vulkan_setup()` when waiting on a fence after * submitting commands that perform image layout barrier transitions * on a compute-only queue. * * This is most likely a driver bug with stencil image barriers on * compute queues. Since no OpenXR core or extensions currently * utilize stencil-only swapchains, they are not required to be * supported. */ bool skip_stencil = false; bool skip_stencil = true; bool skip_depth = inst->quirks.disable_vulkan_format_depth;
// Access to Vulkan headers are not guaranteed. switch (format) {1780 unmodified linesExpand all