intel/vulkan: assume() that we don't use "ISL_NUM_FORMATS"

Which coverity thinks will happen, even though we never return
ISL_NUM_FORMATS.

CID: 1559463
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27369>
This commit is contained in:
Dylan Baker
2024-01-30 11:43:52 -08:00
committed by Marge Bot
parent 529e7ab975
commit 3d4ef6f983

View File

@@ -185,6 +185,7 @@ genX(emit_vertex_input)(struct anv_batch *batch,
vi->attributes[a].format, vi->attributes[a].format,
VK_IMAGE_ASPECT_COLOR_BIT, VK_IMAGE_ASPECT_COLOR_BIT,
VK_IMAGE_TILING_LINEAR); VK_IMAGE_TILING_LINEAR);
assume(format < ISL_NUM_FORMATS);
uint32_t binding = vi->attributes[a].binding; uint32_t binding = vi->attributes[a].binding;
assert(binding < MAX_VBS); assert(binding < MAX_VBS);