mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 06:58:05 +02:00
radv: Flush before copying with PKT3_WRITE_DATA in CmdUpdateBuffer
Need to flush before updating the buffer to ensure that the copy is ordered after previous accesses (assuming the app has performed the appropriate barriers). This fixes potential issues due to draws prior to an update reading the new buffer content, despite having the necessary barriers between them. Signed-off-by: Alex Smith <asmith@feralinteractive.com> Cc: 17.0 <mesa-stable@lists.freedesktop.org> Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl> Reviewed-by: Dave Airlie <airlied@redhat.com>
This commit is contained in:
parent
cce43f6d8c
commit
e0cc32b85b
1 changed files with 2 additions and 0 deletions
|
|
@ -524,6 +524,8 @@ void radv_CmdUpdateBuffer(
|
|||
assert(!(va & 3));
|
||||
|
||||
if (dataSize < 4096) {
|
||||
si_emit_cache_flush(cmd_buffer);
|
||||
|
||||
cmd_buffer->device->ws->cs_add_buffer(cmd_buffer->cs, dst_buffer->bo, 8);
|
||||
|
||||
radeon_check_space(cmd_buffer->device->ws, cmd_buffer->cs, words + 4);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue