mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-06-25 20:06:17 +00:00
vulkan: Fix two validation errors introduced by shared memory changes. (#3074)
Some checks are pending
Build and Release / macos-sdl (push) Blocked by required conditions
Build and Release / reuse (push) Waiting to run
Build and Release / clang-format (push) Waiting to run
Build and Release / get-info (push) Waiting to run
Build and Release / windows-sdl (push) Blocked by required conditions
Build and Release / windows-qt (push) Blocked by required conditions
Build and Release / macos-qt (push) Blocked by required conditions
Build and Release / linux-sdl (push) Blocked by required conditions
Build and Release / linux-qt (push) Blocked by required conditions
Build and Release / linux-sdl-gcc (push) Blocked by required conditions
Build and Release / linux-qt-gcc (push) Blocked by required conditions
Build and Release / pre-release (push) Blocked by required conditions
Some checks are pending
Build and Release / macos-sdl (push) Blocked by required conditions
Build and Release / reuse (push) Waiting to run
Build and Release / clang-format (push) Waiting to run
Build and Release / get-info (push) Waiting to run
Build and Release / windows-sdl (push) Blocked by required conditions
Build and Release / windows-qt (push) Blocked by required conditions
Build and Release / macos-qt (push) Blocked by required conditions
Build and Release / linux-sdl (push) Blocked by required conditions
Build and Release / linux-qt (push) Blocked by required conditions
Build and Release / linux-sdl-gcc (push) Blocked by required conditions
Build and Release / linux-qt-gcc (push) Blocked by required conditions
Build and Release / pre-release (push) Blocked by required conditions
This commit is contained in:
parent
0444e590e0
commit
e2b726382e
2 changed files with 23 additions and 5 deletions
|
@ -34,11 +34,11 @@ void SharedMemoryToStoragePass(IR::Program& program, const RuntimeInfo& runtime_
|
|||
if (program.info.stage != Stage::Compute) {
|
||||
return;
|
||||
}
|
||||
// Only perform the transform if the host shared memory is insufficient
|
||||
// or the device does not support VK_KHR_workgroup_memory_explicit_layout
|
||||
// Only perform the transform if there is shared memory and either host shared memory is
|
||||
// insufficient or the device does not support VK_KHR_workgroup_memory_explicit_layout
|
||||
const u32 shared_memory_size = runtime_info.cs_info.shared_memory_size;
|
||||
if (shared_memory_size <= profile.max_shared_memory_size &&
|
||||
profile.supports_workgroup_explicit_memory_layout) {
|
||||
if (shared_memory_size == 0 || (shared_memory_size <= profile.max_shared_memory_size &&
|
||||
profile.supports_workgroup_explicit_memory_layout)) {
|
||||
return;
|
||||
}
|
||||
// Add buffer binding for shared memory storage buffer.
|
||||
|
|
|
@ -445,7 +445,25 @@ bool Instance::CreateDevice() {
|
|||
workgroup_memory_explicit_layout_features.workgroupMemoryExplicitLayout16BitAccess,
|
||||
},
|
||||
#ifdef __APPLE__
|
||||
portability_features,
|
||||
vk::PhysicalDevicePortabilitySubsetFeaturesKHR{
|
||||
.constantAlphaColorBlendFactors = portability_features.constantAlphaColorBlendFactors,
|
||||
.events = portability_features.events,
|
||||
.imageViewFormatReinterpretation = portability_features.imageViewFormatReinterpretation,
|
||||
.imageViewFormatSwizzle = portability_features.imageViewFormatSwizzle,
|
||||
.imageView2DOn3DImage = portability_features.imageView2DOn3DImage,
|
||||
.multisampleArrayImage = portability_features.multisampleArrayImage,
|
||||
.mutableComparisonSamplers = portability_features.mutableComparisonSamplers,
|
||||
.pointPolygons = portability_features.pointPolygons,
|
||||
.samplerMipLodBias = portability_features.samplerMipLodBias,
|
||||
.separateStencilMaskRef = portability_features.separateStencilMaskRef,
|
||||
.shaderSampleRateInterpolationFunctions =
|
||||
portability_features.shaderSampleRateInterpolationFunctions,
|
||||
.tessellationIsolines = portability_features.tessellationIsolines,
|
||||
.tessellationPointMode = portability_features.tessellationPointMode,
|
||||
.triangleFans = portability_features.triangleFans,
|
||||
.vertexAttributeAccessBeyondStride =
|
||||
portability_features.vertexAttributeAccessBeyondStride,
|
||||
},
|
||||
#endif
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue