mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-02-03 08:40:28 +01:00
zink: add synchronization for buffer clears
cc: mesa-stable
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16098>
(cherry picked from commit fbece25a45)
This commit is contained in:
parent
ae85860679
commit
cfc3827890
2 changed files with 2 additions and 1 deletions
|
|
@ -4,7 +4,7 @@
|
|||
"description": "zink: add synchronization for buffer clears",
|
||||
"nominated": true,
|
||||
"nomination_type": 0,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"main_sha": null,
|
||||
"because_sha": null
|
||||
},
|
||||
|
|
|
|||
|
|
@ -474,6 +474,7 @@ zink_clear_buffer(struct pipe_context *pctx,
|
|||
zink_batch_no_rp(ctx);
|
||||
zink_batch_reference_resource_rw(batch, res, true);
|
||||
util_range_add(&res->base.b, &res->valid_buffer_range, offset, offset + size);
|
||||
zink_resource_buffer_barrier(ctx, res, VK_ACCESS_TRANSFER_WRITE_BIT, VK_PIPELINE_STAGE_TRANSFER_BIT);
|
||||
VKCTX(CmdFillBuffer)(batch->state->cmdbuf, res->obj->buffer, offset, size, *(uint32_t*)clear_value);
|
||||
return;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue