[Impeller] Validation failures on AHB import on low-end PowerVR device.
- Dominant language
- Dart
- Stars
- 179k
- Forks
- 31.1k
- PR merge metrics
- PR metrics pending
Description
The following validation failures were discovered on Android in the Wondrous app during AHB import. These seem to be caused by using values unguarded by capability checks.
The tripped validation IDs were:
* VUID-VkImageCreateInfo-pNext-00990
* VUID-VkSamplerYcbcrConversionCreateInfo-format-01650
These were discovered on a Samsung A03s ([GPUInfo](https://vulkan.gpuinfo.org/displayreport.php?id=17029)) which is a very low-end (sub $50) device that incidentally also uses PowerVR GPUs.
```
E/flutter (11738): [ERROR:flutter/impeller/renderer/backend/vulkan/debug_report_vk.cc(198)] Break on 'ImpellerValidationBreak' to inspect point of failure:
E/flutter (11738): --- Vulkan Debug Report ----------------------------------------
E/flutter (11738): | Severity: Error
E/flutter (11738): | Type: { Validation }
E/flutter (11738): | ID Name: VUID-VkImageCreateInfo-pNext-00990
E/flutter (11738): | ID Number: 1181525669
E/flutter (11738): | Queue Breadcrumbs: [NONE]
E/flutter (11738): | CMD Buffer Breadcrumbs: [NONE]
E/flutter (11738): | Trigger: Validation Error: [ VUID-VkImageCreateInfo-pNext-00990 ] | MessageID = 0x466ca6a5 | vkCreateImage(): pCreateInfo->pNext.handleTypes (VK_EXTERNAL_MEMORY_HANDLE_TYPE_ANDROID_HARDWARE_BUFFER_BIT_ANDROID) is not reported as compatible by vkGetPhysicalDeviceImageFormatProperties2. Compatible types are VkExternalMemoryHandleTypeFlags(0). The Vulkan spec states: If the pNext chain includes a VkExternalMemoryImageCreateInfo structure, its handleTypes member must only contain bits that are also in VkExternalImageFormatProperties::externalMemoryProperties.compatibleHandleTypes, as returned by vkGetPhysicalDeviceImageFormatProperties2 with format, imageType, tiling, usage, and flags equal to those in this structure, and with a VkPhysicalDeviceExternalImageFormatInfo structure included in the pNext chain, with a handleType equal to any one of the handle types specified in VkExternalMemoryImageCreateInfo::handleTypes (https://www.khronos.org/registry/vulkan/specs/1.3-extensions/html/vkspec.html#VUID-VkImageCreateInfo-pNext-00990)
E/flutter (11738): -----------------------------------------------------------------
E/flutter (11738): [ERROR:flutter/impeller/renderer/backend/vulkan/debug_report_vk.cc(198)] Break on 'ImpellerValidationBreak' to inspect point of failure:
E/flutter (11738): --- Vulkan Debug Report ----------------------------------------
E/flutter (11738): | Severity: Error
E/flutter (11738): | Type: { Validation }
E/flutter (11738): | ID Name: VUID-VkSamplerYcbcrConversionCreateInfo-format-01650
E/flutter (11738): | ID Number: -1618959383
E/flutter (11738): | Queue Breadcrumbs: [NONE]
E/flutter (11738): | CMD Buffer Breadcrumbs: [NONE]
E/flutter (11738): | Trigger: Validation Error: [ VUID-VkSamplerYcbcrConversionCreateInfo-format-01650 ] | MessageID = 0x9f80a3e9 | vkCreateSamplerYcbcrConversion(): pCreateInfo->format (VK_FORMAT_R8G8B8A8_UNORM) does not support either VK_FORMAT_FEATURE_MIDPOINT_CHROMA_SAMPLES_BIT or VK_FORMAT_FEATURE_COSITED_CHROMA_SAMPLES_BIT. The Vulkan spec states: The potential format features of the sampler Y'CBCR conversion must support VK_FORMAT_FEATURE_MIDPOINT_CHROMA_SAMPLES_BIT or VK_FORMAT_FEATURE_COSITED_CHROMA_SAMPLES_BIT (https://www.khronos.org/registry/vulkan/specs/1.3-extensions/html/vkspec.html#VUID-VkSamplerYcbcrConversionCreateInfo-format-01650)
E/flutter (11738): -----------------------------------------------------------------
```
Contributor guide
Assessment
This issue has not been assessed yet.