1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2025-01-31 05:52:11 +01:00

[dxvk] Suspend render pass for buffer copies and render pass barriers

No images are directly involved in these, so we can save some layout
transitions.
This commit is contained in:
Philip Rebohle 2021-02-10 02:16:05 +01:00
parent ba698430cb
commit fe43abbf32
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99

View File

@ -326,7 +326,7 @@ namespace dxvk {
VkDeviceSize offset,
VkDeviceSize length,
uint32_t value) {
this->spillRenderPass();
this->spillRenderPass(true);
length = align(length, sizeof(uint32_t));
auto slice = buffer->getSliceHandle(offset, length);
@ -355,7 +355,7 @@ namespace dxvk {
VkDeviceSize offset,
VkDeviceSize length,
VkClearColorValue value) {
this->spillRenderPass();
this->spillRenderPass(true);
this->unbindComputePipeline();
// The view range might have been invalidated, so
@ -601,7 +601,7 @@ namespace dxvk {
if (numBytes == 0)
return;
this->spillRenderPass();
this->spillRenderPass(true);
auto dstSlice = dstBuffer->getSliceHandle(dstOffset, numBytes);
auto srcSlice = srcBuffer->getSliceHandle(srcOffset, numBytes);
@ -1878,7 +1878,7 @@ namespace dxvk {
this->invalidateBuffer(buffer, bufferSlice);
} else {
this->spillRenderPass();
this->spillRenderPass(true);
bufferSlice = buffer->getSliceHandle(offset, size);
cmdBuffer = DxvkCmdBuffer::ExecBuffer;
@ -2372,7 +2372,7 @@ namespace dxvk {
void DxvkContext::signalGpuEvent(const Rc<DxvkGpuEvent>& event) {
this->spillRenderPass();
this->spillRenderPass(true);
DxvkGpuEventHandle handle = m_common->eventPool().allocEvent();
@ -3667,7 +3667,7 @@ namespace dxvk {
// This is necessary because we'll only do hazard
// tracking if the active pipeline has side effects
this->spillRenderPass();
this->spillRenderPass(true);
}
if (m_state.gp.pipeline->layout()->pushConstRange().size)
@ -4664,7 +4664,7 @@ namespace dxvk {
// and execution barriers, so we can use this to allow
// inter-stage synchronization.
if (requiresBarrier)
this->spillRenderPass();
this->spillRenderPass(true);
}