From 26aeeaecf5bad9762cdd65728f5de954b36ab0f2 Mon Sep 17 00:00:00 2001 From: Billy Laws Date: Tue, 25 Oct 2022 20:50:43 +0100 Subject: [PATCH] Add constant buffer GPU write pipeline barrier --- .../skyline/gpu/interconnect/maxwell_3d/constant_buffers.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app/src/main/cpp/skyline/gpu/interconnect/maxwell_3d/constant_buffers.cpp b/app/src/main/cpp/skyline/gpu/interconnect/maxwell_3d/constant_buffers.cpp index 6c363041..e4faffee 100644 --- a/app/src/main/cpp/skyline/gpu/interconnect/maxwell_3d/constant_buffers.cpp +++ b/app/src/main/cpp/skyline/gpu/interconnect/maxwell_3d/constant_buffers.cpp @@ -79,6 +79,10 @@ namespace skyline::gpu::interconnect::maxwell3d { .dstOffset = view.GetOffset() + offset }; commandBuffer.copyBuffer(srcGpuAllocation.buffer, view.GetBuffer()->GetBacking(), copyRegion); + commandBuffer.pipelineBarrier(vk::PipelineStageFlagBits::eTransfer, vk::PipelineStageFlagBits::eAllCommands, {}, vk::MemoryBarrier{ + .srcAccessMask = vk::AccessFlagBits::eTransferWrite, + .dstAccessMask = vk::AccessFlagBits::eMemoryRead | vk::AccessFlagBits::eMemoryWrite + }, {}, {}); }); }); }