KhronosGroup / MoltenVK

MoltenVK is a Vulkan Portability implementation. It layers a subset of the high-performance, industry-standard Vulkan graphics and compute API over Apple's Metal graphics framework, enabling Vulkan applications to run on macOS, iOS and tvOS.
Apache License 2.0
4.76k stars 419 forks source link

[1.3.280] Confusing Validation error stating I'm trying to use 1.3 features but my API version is 1.3.0 #2193

Closed RefuX closed 4 months ago

RefuX commented 6 months ago

Updated to 1.3.280 and now getting this validation error:

Validation Error: [ VUID-VkDeviceCreateInfo-pNext-pNext ] Object 0: handle = 0x13da30e00, type = VK_OBJECT_TYPE_INSTANCE; | MessageID = 0x901f59ec | vkCreateDevice(): pCreateInfo->pNext includes a pointer to a VkStructureType (VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_VULKAN_1_3_FEATURES) which was added in VK_API_VERSION_1_3 but the current effective API version is 1.3.0 (0x00403000). The Vulkan spec states: Each pNext member of any structure (including this one) in the pNext chain must be either NULL or a pointer to a valid struct for extending VkDeviceCreateInfo

cdavis5e commented 6 months ago

That's probably because MoltenVK doesn't support Vulkan 1.3 yet. We're still working on that; see #1930.

Perhaps the better question is: why weren't you getting a validation error before?

It has also occurred to me that the validation layer's message could probably be improved by showing the API version supported by the ICD.

saemideluxe commented 6 months ago

Edit: Sorry, I just noticed that this is actually the MoltenVK repo. Should we open an issue in a vulkan repo?

I get the same error:

ERROR @[VK_DEBUG_UTILS_MESSAGE_TYPE_VALIDATION_BIT_EXT]: Validation Error: [ VUID-VkDeviceCreateInfo-pNext-pNext ] Object 0: handle = 0x212ad432b70, type = VK_OBJECT_TYPE_INSTANCE; | MessageID = 0x901f59ec | vkCreateDevice(): pCreateInfo->pNext includes a pointer to a VkStructureType (VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_VULKAN_1_3_FEATURES) which was added in VK_API_VERSION_1_3 but the current effective API version is 1.3.0 (0x00403000). The Vulkan spec states: Each pNext member of any structure (including this one) in the pNext chain must be either NULL or a pointer to a valid struct for extending VkDeviceCreateInfo (https://vulkan.lunarg.com/doc/view/1.3.280.0/windows/1.3-extensions/vkspec.html#VUID-VkDeviceCreateInfo-pNext-pNext)

OS: Windows 10 64 bit Created Vulkan instance with VK_MAKE_API_VERSION(0, 1, 3, 0) Only happens when using VkPhysicalDeviceVulkan13Features

billhollings commented 6 months ago

Edit: Sorry, I just noticed that this is actually the MoltenVK repo. Should we open an issue in a vulkan repo?

Yes. For Vulkan SDK Validation errors, it's best to post to the Vulkan SDK issues list.

saemideluxe commented 6 months ago

Okay, it looks like I was using VkPhysicalDeviceVulkan13Features with a driver that does not support Vulkan 1.3 (I initially assumed that if I can create an instance with version 1.3 the device created with it would support 1.3 as well).

KarenGhavam-lunarG commented 6 months ago

For Vulkan SDK Validation errors, it's best to post to the Vulkan SDK issues list.

Actually, if you have a validation error, it is best to submit to the validation layer repository. The SDK issue list is for SDK packaging issues.

kanerogers commented 4 months ago

It seems like this issue can be safely closed, right?