radv: mark VK_IMAGE_CREATE_SPARSE_RESIDENCY_BIT as unsupported on GFX6-7

This is only supported on GFX8+, this fixes a ton of CTS failures
on my Pitcairn (GFX6).

Fixes: af7fb4df50 ("radv: Add sparse image queries.")
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8415>
This commit is contained in:
Samuel Pitoiset
2021-01-11 16:00:47 +01:00
committed by Marge Bot
parent 4ea0ce2f55
commit d2524ed4a0
+4
View File
@@ -1284,6 +1284,10 @@ static VkResult radv_get_image_format_properties(struct radv_physical_device *ph
}
if (info->flags & VK_IMAGE_CREATE_SPARSE_RESIDENCY_BIT) {
/* Sparse textures are only supported on GFX8+. */
if (physical_device->rad_info.chip_class < GFX8)
goto unsupported;
if (desc->plane_count > 1 || info->type != VK_IMAGE_TYPE_2D ||
info->tiling != VK_IMAGE_TILING_OPTIMAL ||
vk_format_is_depth_or_stencil(format))