Mesa (staging/22.0): zink: add synchronization for buffer clears
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Mon Apr 25 04:04:42 UTC 2022
Module: Mesa
Branch: staging/22.0
Commit: 03b9ee9e5a5e6f79971719a37815248df13f99ac
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=03b9ee9e5a5e6f79971719a37815248df13f99ac
Author: Mike Blumenkrantz <michael.blumenkrantz at gmail.com>
Date: Wed Apr 20 15:53:35 2022 -0400
zink: add synchronization for buffer clears
cc: mesa-stable
Reviewed-by: Erik Faye-Lund <erik.faye-lund at collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16098>
(cherry picked from commit fbece25a451bb7915891851ee5c72724974ae5e2)
---
.pick_status.json | 2 +-
src/gallium/drivers/zink/zink_clear.c | 1 +
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/.pick_status.json b/.pick_status.json
index 23547ebbc3a..455ff617a3c 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -612,7 +612,7 @@
"description": "zink: add synchronization for buffer clears",
"nominated": true,
"nomination_type": 0,
- "resolution": 0,
+ "resolution": 1,
"because_sha": null
},
{
diff --git a/src/gallium/drivers/zink/zink_clear.c b/src/gallium/drivers/zink/zink_clear.c
index 77f294f5279..b864e167bd9 100644
--- a/src/gallium/drivers/zink/zink_clear.c
+++ b/src/gallium/drivers/zink/zink_clear.c
@@ -458,6 +458,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;
}
More information about the mesa-commit
mailing list