mirror of
https://git.eden-emu.dev/eden-emu/eden
synced 2026-05-02 06:19:00 +02:00
[revert] Adjusting unused features
This commit is contained in:
parent
d458b7cf72
commit
7cf9095081
7 changed files with 74 additions and 131 deletions
|
|
@ -29,6 +29,9 @@
|
|||
#ifndef VK_KHR_MAINTENANCE_8_EXTENSION_NAME
|
||||
#define VK_KHR_MAINTENANCE_8_EXTENSION_NAME "VK_KHR_maintenance8"
|
||||
#endif
|
||||
#ifndef VK_KHR_MAINTENANCE_9_EXTENSION_NAME
|
||||
#define VK_KHR_MAINTENANCE_9_EXTENSION_NAME "VK_KHR_maintenance9"
|
||||
#endif
|
||||
|
||||
// Sanitize macros
|
||||
#undef CreateEvent
|
||||
|
|
|
|||
|
|
@ -1447,22 +1447,12 @@ void Device::RemoveUnsuitableExtensions() {
|
|||
}
|
||||
|
||||
// VK_KHR_workgroup_memory_explicit_layout
|
||||
workgroup_memory_explicit_layout_caps.supports_8bit =
|
||||
features.workgroup_memory_explicit_layout.workgroupMemoryExplicitLayout8BitAccess;
|
||||
workgroup_memory_explicit_layout_caps.supports_16bit =
|
||||
features.workgroup_memory_explicit_layout.workgroupMemoryExplicitLayout16BitAccess;
|
||||
const bool has_workgroup_base =
|
||||
extensions.workgroup_memory_explicit_layout =
|
||||
features.features.shaderInt16 &&
|
||||
features.workgroup_memory_explicit_layout.workgroupMemoryExplicitLayout &&
|
||||
features.workgroup_memory_explicit_layout.workgroupMemoryExplicitLayout8BitAccess &&
|
||||
features.workgroup_memory_explicit_layout.workgroupMemoryExplicitLayout16BitAccess &&
|
||||
features.workgroup_memory_explicit_layout.workgroupMemoryExplicitLayoutScalarBlockLayout;
|
||||
if (is_qualcomm) {
|
||||
extensions.workgroup_memory_explicit_layout =
|
||||
features.features.shaderInt16 && has_workgroup_base;
|
||||
} else {
|
||||
extensions.workgroup_memory_explicit_layout =
|
||||
features.features.shaderInt16 && has_workgroup_base &&
|
||||
workgroup_memory_explicit_layout_caps.supports_8bit &&
|
||||
workgroup_memory_explicit_layout_caps.supports_16bit;
|
||||
}
|
||||
RemoveExtensionFeatureIfUnsuitable(extensions.workgroup_memory_explicit_layout,
|
||||
features.workgroup_memory_explicit_layout,
|
||||
VK_KHR_WORKGROUP_MEMORY_EXPLICIT_LAYOUT_EXTENSION_NAME);
|
||||
|
|
@ -1501,6 +1491,10 @@ void Device::RemoveUnsuitableExtensions() {
|
|||
// VK_KHR_maintenance8
|
||||
extensions.maintenance8 = loaded_extensions.contains(VK_KHR_MAINTENANCE_8_EXTENSION_NAME);
|
||||
RemoveExtensionIfUnsuitable(extensions.maintenance8, VK_KHR_MAINTENANCE_8_EXTENSION_NAME);
|
||||
|
||||
// VK_KHR_maintenance9 (proposed for Vulkan 1.4, no features)
|
||||
extensions.maintenance9 = loaded_extensions.contains(VK_KHR_MAINTENANCE_9_EXTENSION_NAME);
|
||||
RemoveExtensionIfUnsuitable(extensions.maintenance9, VK_KHR_MAINTENANCE_9_EXTENSION_NAME);
|
||||
}
|
||||
|
||||
bool Device::SupportsSubgroupStage(VkShaderStageFlags stage_mask) const {
|
||||
|
|
|
|||
|
|
@ -99,6 +99,7 @@ VK_DEFINE_HANDLE(VmaAllocator)
|
|||
EXTENSION(KHR, MAINTENANCE_3, maintenance3) \
|
||||
EXTENSION(KHR, MAINTENANCE_7, maintenance7) \
|
||||
EXTENSION(KHR, MAINTENANCE_8, maintenance8) \
|
||||
EXTENSION(KHR, MAINTENANCE_9, maintenance9) \
|
||||
EXTENSION(NV, DEVICE_DIAGNOSTICS_CONFIG, device_diagnostics_config) \
|
||||
EXTENSION(NV, GEOMETRY_SHADER_PASSTHROUGH, geometry_shader_passthrough) \
|
||||
EXTENSION(NV, VIEWPORT_ARRAY2, viewport_array2) \
|
||||
|
|
@ -499,16 +500,6 @@ public:
|
|||
return extensions.workgroup_memory_explicit_layout;
|
||||
}
|
||||
|
||||
/// Returns true if explicit workgroup layout supports 8-bit access.
|
||||
bool SupportsWorkgroupExplicitLayout8Bit() const {
|
||||
return workgroup_memory_explicit_layout_caps.supports_8bit;
|
||||
}
|
||||
|
||||
/// Returns true if explicit workgroup layout supports 16-bit access.
|
||||
bool SupportsWorkgroupExplicitLayout16Bit() const {
|
||||
return workgroup_memory_explicit_layout_caps.supports_16bit;
|
||||
}
|
||||
|
||||
/// Returns true if the device supports VK_KHR_image_format_list.
|
||||
bool IsKhrImageFormatListSupported() const {
|
||||
return extensions.image_format_list || instance_version >= VK_API_VERSION_1_2;
|
||||
|
|
@ -941,6 +932,11 @@ public:
|
|||
return features.bit8_storage.storageBuffer8BitAccess &&
|
||||
features.bit16_storage.storageBuffer16BitAccess;
|
||||
}
|
||||
|
||||
/// Returns true if the device supports VK_KHR_maintenance9.
|
||||
bool IsKhrMaintenance9Supported() const {
|
||||
return extensions.maintenance9;
|
||||
}
|
||||
|
||||
[[nodiscard]] static constexpr bool CheckBrokenCompute(VkDriverId driver_id,
|
||||
u32 driver_version) {
|
||||
|
|
@ -1072,13 +1068,6 @@ private:
|
|||
Features features{};
|
||||
Properties properties{};
|
||||
|
||||
struct WorkgroupExplicitLayoutCaps {
|
||||
bool supports_8bit{};
|
||||
bool supports_16bit{};
|
||||
};
|
||||
|
||||
WorkgroupExplicitLayoutCaps workgroup_memory_explicit_layout_caps{};
|
||||
|
||||
VkPhysicalDeviceFeatures2 features2{};
|
||||
VkPhysicalDeviceProperties2 properties2{};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue