2
1
Fork 0
mirror of https://github.com/yuzu-emu/yuzu.git synced 2024-07-04 23:31:19 +01:00

Merge pull request #8369 from lat9nq/amd-wmel-workaround

vulkan_device: Workaround extension bug
This commit is contained in:
bunnei 2022-05-25 13:07:28 -07:00 committed by GitHub
commit 79352ee9d5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -566,7 +566,7 @@ Device::Device(VkInstance instance_, vk::PhysicalDevice physical_, VkSurfaceKHR
} }
VkPhysicalDeviceWorkgroupMemoryExplicitLayoutFeaturesKHR workgroup_layout; VkPhysicalDeviceWorkgroupMemoryExplicitLayoutFeaturesKHR workgroup_layout;
if (khr_workgroup_memory_explicit_layout) { if (khr_workgroup_memory_explicit_layout && is_shader_int16_supported) {
workgroup_layout = { workgroup_layout = {
.sType = .sType =
VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_WORKGROUP_MEMORY_EXPLICIT_LAYOUT_FEATURES_KHR, VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_WORKGROUP_MEMORY_EXPLICIT_LAYOUT_FEATURES_KHR,
@ -577,6 +577,11 @@ Device::Device(VkInstance instance_, vk::PhysicalDevice physical_, VkSurfaceKHR
.workgroupMemoryExplicitLayout16BitAccess = VK_TRUE, .workgroupMemoryExplicitLayout16BitAccess = VK_TRUE,
}; };
SetNext(next, workgroup_layout); SetNext(next, workgroup_layout);
} else if (khr_workgroup_memory_explicit_layout) {
// TODO(lat9nq): Find a proper fix for this
LOG_WARNING(Render_Vulkan, "Disabling VK_KHR_workgroup_memory_explicit_layout due to a "
"yuzu bug when host driver does not support 16-bit integers");
khr_workgroup_memory_explicit_layout = false;
} }
VkPhysicalDevicePipelineExecutablePropertiesFeaturesKHR executable_properties; VkPhysicalDevicePipelineExecutablePropertiesFeaturesKHR executable_properties;