mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-07 20:08:06 +02:00
zink: acquire persistently bound swapchain descriptors before setting usage
if a swapchain image is bound as a sampler across batches then it needs
to be acquired again before it is used
cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23729>
(cherry picked from commit 6b204c6162)
This commit is contained in:
parent
b94aca6dbf
commit
a1acbaea39
2 changed files with 6 additions and 1 deletions
|
|
@ -67,7 +67,7 @@
|
|||
"description": "zink: acquire persistently bound swapchain descriptors before setting usage",
|
||||
"nominated": true,
|
||||
"nomination_type": 0,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"main_sha": null,
|
||||
"because_sha": null
|
||||
},
|
||||
|
|
|
|||
|
|
@ -3121,6 +3121,11 @@ update_resource_refs_for_stage(struct zink_context *ctx, gl_shader_stage stage)
|
|||
continue;
|
||||
bool is_buffer = res->obj->is_buffer;
|
||||
bool is_write = zink_resource_access_is_write(get_access_flags_for_binding(ctx, i, stage, j));
|
||||
if (zink_is_swapchain(res)) {
|
||||
if (!zink_kopper_acquire(ctx, res, UINT64_MAX))
|
||||
/* technically this is a failure condition, but there's no safe way out */
|
||||
continue;
|
||||
}
|
||||
zink_batch_resource_usage_set(batch, res, is_write, is_buffer);
|
||||
if (is_write || !res->obj->is_buffer)
|
||||
res->obj->unordered_read = res->obj->unordered_write = false;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue