The Vulkan loader may disable the Vulkan WSI Layer depending on apiVersion
When calling vkCreateInstance
, an application can provide the VkInstanceCreateInfo::pApplicationInfo::apiVersion
field, defined as the highest Vulkan version the application is designed to use, see https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/VkApplicationInfo.html. This is not necessarily the API version that the application will end up using. In particular, the application may end up using an earlier Vulkan API version if there are no Installable Client Drivers (ICDs) in the system that support the newer version.
At the same time, the Vulkan specification demands that: “Implicit layers must be disabled if they do not support a version at least as high as apiVersion
” and the Khronos Vulkan loader implements this recommendation. Unfortunately, this recommendation is problematic for implicit layers that implement one or more Vulkan extensions. It means that an implementation of a Vulkan extension provided as an implicit layer can stop working for applications that advertise ability to use newer Vulkan APIs. The problem would not occur if the extension was implemented in the ICD, instead.
This problem can be worked around by updating the Vulkan WSI Layer so that it supports the latest Vulkan API at all times. However, this approach may not be practical in certain cases. For example, in cases where a device stops receiving updates but still allows its user to access applications from an online store, which is continuously updated.
Another possible workaround is changing the Vulkan Loader to never disable the Vulkan WSI Layer. It is then the system integrator’s responsibility to ensure the Vulkan runtime is consistent, i.e. the Vulkan WSI Layer supported API version is not lower than the API version supported by all the other components in the Vulkan runtime (loader, ICDS, other layers.)
A solution to this problem is currently being investigated.