From a0e0ba1cc8f62ff2f9ea8cac4415ad268447e8c6 Mon Sep 17 00:00:00 2001 From: Philip Rebohle Date: Fri, 25 May 2018 21:02:15 +0200 Subject: [PATCH] [dxvk] Align length when clearing entire buffer Buffer slices in DXVK are always aligned to at least 256 bytes, so this is safe. Fixes a regression leading to GPU hangs on RADV. --- src/dxvk/dxvk_context.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/dxvk/dxvk_context.cpp b/src/dxvk/dxvk_context.cpp index 64a15484..72ef7f3b 100644 --- a/src/dxvk/dxvk_context.cpp +++ b/src/dxvk/dxvk_context.cpp @@ -230,6 +230,9 @@ namespace dxvk { uint32_t value) { this->spillRenderPass(); + if (length == buffer->info().size) + length = align(length, 4); + auto slice = buffer->subSlice(offset, length); m_cmd->cmdFillBuffer(