zink: read shader image r/w usage from incoming data struct

no functional changes

cc: mesa-stable

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16508>
(cherry picked from commit 32a77b1e25)
This commit is contained in:
Mike Blumenkrantz 2022-05-13 11:25:30 -04:00 committed by Dylan Baker
parent 308af4a479
commit 3b927d3e41
2 changed files with 3 additions and 3 deletions

View file

@ -553,7 +553,7 @@
"description": "zink: read shader image r/w usage from incoming data struct",
"nominated": true,
"nomination_type": 0,
"resolution": 0,
"resolution": 1,
"main_sha": null,
"because_sha": null
},

View file

@ -1475,11 +1475,11 @@ zink_set_shader_images(struct pipe_context *pctx,
/* no refs */
memcpy(&image_view->base, images + i, sizeof(struct pipe_image_view));
VkAccessFlags access = 0;
if (image_view->base.access & PIPE_IMAGE_ACCESS_WRITE) {
if (images[i].access & PIPE_IMAGE_ACCESS_WRITE) {
res->write_bind_count[p_stage == PIPE_SHADER_COMPUTE]++;
access |= VK_ACCESS_SHADER_WRITE_BIT;
}
if (image_view->base.access & PIPE_IMAGE_ACCESS_READ) {
if (images[i].access & PIPE_IMAGE_ACCESS_READ) {
access |= VK_ACCESS_SHADER_READ_BIT;
}
res->image_bind_count[p_stage == PIPE_SHADER_COMPUTE]++;