mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-24 17:30:12 +01:00
turnip: remove useless tu_image asserts
Validation layer already catches these errors, so don't bother. Signed-off-by: Jonathan Marek <jonathan@marek.ca> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6940>
This commit is contained in:
parent
dfaa8b9ae7
commit
c64cd6988f
1 changed files with 0 additions and 26 deletions
|
|
@ -205,20 +205,6 @@ tu_image_view_init(struct tu_image_view *iview,
|
|||
const struct tu_sampler_ycbcr_conversion *conversion = ycbcr_conversion ?
|
||||
tu_sampler_ycbcr_conversion_from_handle(ycbcr_conversion->conversion) : NULL;
|
||||
|
||||
switch (image->type) {
|
||||
case VK_IMAGE_TYPE_1D:
|
||||
case VK_IMAGE_TYPE_2D:
|
||||
assert(range->baseArrayLayer + tu_get_layerCount(image, range) <=
|
||||
image->layer_count);
|
||||
break;
|
||||
case VK_IMAGE_TYPE_3D:
|
||||
assert(range->baseArrayLayer + tu_get_layerCount(image, range) <=
|
||||
u_minify(image->extent.depth, range->baseMipLevel));
|
||||
break;
|
||||
default:
|
||||
unreachable("bad VkImageType");
|
||||
}
|
||||
|
||||
iview->image = image;
|
||||
|
||||
memset(iview->descriptor, 0, sizeof(iview->descriptor));
|
||||
|
|
@ -514,15 +500,6 @@ tu_CreateImage(VkDevice _device,
|
|||
}
|
||||
#endif
|
||||
|
||||
assert(pCreateInfo->sType == VK_STRUCTURE_TYPE_IMAGE_CREATE_INFO);
|
||||
|
||||
assert(pCreateInfo->mipLevels > 0);
|
||||
assert(pCreateInfo->arrayLayers > 0);
|
||||
assert(pCreateInfo->samples > 0);
|
||||
assert(pCreateInfo->extent.width > 0);
|
||||
assert(pCreateInfo->extent.height > 0);
|
||||
assert(pCreateInfo->extent.depth > 0);
|
||||
|
||||
image = vk_object_zalloc(&device->vk, alloc, sizeof(*image),
|
||||
VK_OBJECT_TYPE_IMAGE);
|
||||
if (!image)
|
||||
|
|
@ -788,9 +765,6 @@ VkResult tu_GetImageDrmFormatModifierPropertiesEXT(
|
|||
{
|
||||
TU_FROM_HANDLE(tu_image, image, _image);
|
||||
|
||||
assert(pProperties->sType ==
|
||||
VK_STRUCTURE_TYPE_IMAGE_DRM_FORMAT_MODIFIER_PROPERTIES_EXT);
|
||||
|
||||
/* TODO invent a modifier for tiled but not UBWC buffers */
|
||||
|
||||
if (!image->layout[0].tile_mode)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue