diff --git a/src/vulkan/wrapper/wrapper_device.c b/src/vulkan/wrapper/wrapper_device.c index 2602532d383..865b6e95dad 100644 --- a/src/vulkan/wrapper/wrapper_device.c +++ b/src/vulkan/wrapper/wrapper_device.c @@ -2147,7 +2147,18 @@ wrapper_GetDeviceBufferMemoryRequirements(VkDevice _device, { VK_FROM_HANDLE(wrapper_device, device, _device); - if (device->dispatch_table.GetDeviceBufferMemoryRequirements) { + /* Order of the Sinking Star faults in the Mali driver's maintenance4 + * buffer query during D3D device initialization. Use the existing + * create/query/destroy lowering for this application, even when the + * driver exports the direct entry point. No memory is bound or allocated. + */ + const char *app_name = device->physical->instance->vk.app_info.app_name; + const bool mali_sinking_star = + device->physical->driver_properties.driverID == VK_DRIVER_ID_ARM_PROPRIETARY && + app_name && !strcmp(app_name, "sinking_star.exe"); + + if (device->dispatch_table.GetDeviceBufferMemoryRequirements && + !mali_sinking_star) { device->dispatch_table.GetDeviceBufferMemoryRequirements(device->dispatch_handle, pInfo, pMemoryRequirements); return; diff --git a/src/vulkan/wrapper/wrapper_physical_device.c b/src/vulkan/wrapper/wrapper_physical_device.c index 3b1d7c34a11..40fa6b2cbd1 100644 --- a/src/vulkan/wrapper/wrapper_physical_device.c +++ b/src/vulkan/wrapper/wrapper_physical_device.c @@ -967,6 +967,10 @@ wrapper_GetPhysicalDeviceProperties2(VkPhysicalDevice physicalDevice, } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_VULKAN_1_1_PROPERTIES: { + /* Keep Mali's native subgroup capabilities. Clearing these masks + * prevents vkd3d from exposing WaveOps and shader model 6.0+. */ + if (pdevice->driver_properties.driverID == VK_DRIVER_ID_ARM_PROPRIETARY) + break; VkPhysicalDeviceVulkan11Properties *vk11_prop = (VkPhysicalDeviceVulkan11Properties *)prop; vk11_prop->subgroupSupportedOperations = 0; @@ -1033,6 +1037,10 @@ wrapper_GetPhysicalDeviceProperties2(VkPhysicalDevice physicalDevice, } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SUBGROUP_PROPERTIES: { + /* Match the Vulkan 1.1 aggregate query: preserve the driver's + * supported operations and stages, without inventing capabilities. */ + if (pdevice->driver_properties.driverID == VK_DRIVER_ID_ARM_PROPRIETARY) + break; VkPhysicalDeviceSubgroupProperties *subgroup_prop = (VkPhysicalDeviceSubgroupProperties *)prop; subgroup_prop->supportedOperations = 0;