mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-05-29 14:53:18 +00:00
externals: Update MoltenVK (#2492)
This commit is contained in:
parent
745cdd89fd
commit
5b3e156197
5 changed files with 16 additions and 8 deletions
2
externals/MoltenVK/MoltenVK
vendored
2
externals/MoltenVK/MoltenVK
vendored
|
@ -1 +1 @@
|
||||||
Subproject commit 0c090001cb42997031cfe43914340e2639944972
|
Subproject commit 2048427e50f9eb20f2b8f98d316ecaee398c9b91
|
2
externals/MoltenVK/SPIRV-Cross
vendored
2
externals/MoltenVK/SPIRV-Cross
vendored
|
@ -1 +1 @@
|
||||||
Subproject commit 1a7b7ef6de02cf6767e42b10ddad217c45e90d47
|
Subproject commit 2c32b6bf86f3c4a5539aa1f0bacbd59fe61759cf
|
|
@ -247,9 +247,7 @@ bool Instance::CreateDevice() {
|
||||||
add_extension(VK_EXT_SHADER_DEMOTE_TO_HELPER_INVOCATION_EXTENSION_NAME);
|
add_extension(VK_EXT_SHADER_DEMOTE_TO_HELPER_INVOCATION_EXTENSION_NAME);
|
||||||
add_extension(VK_KHR_SYNCHRONIZATION_2_EXTENSION_NAME);
|
add_extension(VK_KHR_SYNCHRONIZATION_2_EXTENSION_NAME);
|
||||||
add_extension(VK_EXT_EXTENDED_DYNAMIC_STATE_EXTENSION_NAME);
|
add_extension(VK_EXT_EXTENDED_DYNAMIC_STATE_EXTENSION_NAME);
|
||||||
// Currently causes issues with Reshade on AMD proprietary, disable until figured out.
|
add_extension(VK_EXT_TOOLING_INFO_EXTENSION_NAME);
|
||||||
tooling_info = GetDriverID() != vk::DriverId::eAmdProprietary &&
|
|
||||||
add_extension(VK_EXT_TOOLING_INFO_EXTENSION_NAME);
|
|
||||||
const bool maintenance4 = add_extension(VK_KHR_MAINTENANCE_4_EXTENSION_NAME);
|
const bool maintenance4 = add_extension(VK_KHR_MAINTENANCE_4_EXTENSION_NAME);
|
||||||
|
|
||||||
add_extension(VK_KHR_SWAPCHAIN_EXTENSION_NAME);
|
add_extension(VK_KHR_SWAPCHAIN_EXTENSION_NAME);
|
||||||
|
@ -539,7 +537,8 @@ void Instance::CollectDeviceParameters() {
|
||||||
}
|
}
|
||||||
|
|
||||||
void Instance::CollectToolingInfo() {
|
void Instance::CollectToolingInfo() {
|
||||||
if (!tooling_info) {
|
if (GetDriverID() == vk::DriverId::eAmdProprietary) {
|
||||||
|
// Currently causes issues with Reshade on AMD proprietary, disabled until fix released.
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
const auto [tools_result, tools] = physical_device.getToolPropertiesEXT();
|
const auto [tools_result, tools] = physical_device.getToolPropertiesEXT();
|
||||||
|
|
|
@ -333,7 +333,6 @@ private:
|
||||||
bool shader_stencil_export{};
|
bool shader_stencil_export{};
|
||||||
bool image_load_store_lod{};
|
bool image_load_store_lod{};
|
||||||
bool amd_gcn_shader{};
|
bool amd_gcn_shader{};
|
||||||
bool tooling_info{};
|
|
||||||
bool portability_subset{};
|
bool portability_subset{};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -278,6 +278,7 @@ vk::UniqueInstance CreateInstance(Frontend::WindowSystemType window_type, bool e
|
||||||
vk::Bool32 enable_force_barriers = vk::True;
|
vk::Bool32 enable_force_barriers = vk::True;
|
||||||
#ifdef __APPLE__
|
#ifdef __APPLE__
|
||||||
const vk::Bool32 mvk_debug_mode = enable_crash_diagnostic ? vk::True : vk::False;
|
const vk::Bool32 mvk_debug_mode = enable_crash_diagnostic ? vk::True : vk::False;
|
||||||
|
constexpr vk::Bool32 mvk_use_mtlheap = vk::True;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
const std::array layer_setings = {
|
const std::array layer_setings = {
|
||||||
|
@ -353,7 +354,16 @@ vk::UniqueInstance CreateInstance(Frontend::WindowSystemType window_type, bool e
|
||||||
.type = vk::LayerSettingTypeEXT::eBool32,
|
.type = vk::LayerSettingTypeEXT::eBool32,
|
||||||
.valueCount = 1,
|
.valueCount = 1,
|
||||||
.pValues = &mvk_debug_mode,
|
.pValues = &mvk_debug_mode,
|
||||||
}
|
},
|
||||||
|
// Use MTLHeap to back device memory, which among other things allows us to
|
||||||
|
// use VK_IMAGE_CREATE_2D_ARRAY_COMPATIBLE_BIT via memory aliasing.
|
||||||
|
vk::LayerSettingEXT{
|
||||||
|
.pLayerName = "MoltenVK",
|
||||||
|
.pSettingName = "MVK_CONFIG_USE_MTLHEAP",
|
||||||
|
.type = vk::LayerSettingTypeEXT::eBool32,
|
||||||
|
.valueCount = 1,
|
||||||
|
.pValues = &mvk_use_mtlheap,
|
||||||
|
},
|
||||||
#endif
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue