Mesa (main): zink: skip extra descriptor lookups for images during barrier updates
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Sat Feb 26 15:37:06 UTC 2022
Module: Mesa
Branch: main
Commit: 861fc10bfc76f3f4286d36fdbb0707883b8c090c
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=861fc10bfc76f3f4286d36fdbb0707883b8c090c
Author: Mike Blumenkrantz <michael.blumenkrantz at gmail.com>
Date: Tue Feb 15 09:15:57 2022 -0500
zink: skip extra descriptor lookups for images during barrier updates
Reviewed-by: Emma Anholt <emma at anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15173>
---
src/gallium/drivers/zink/zink_draw.cpp | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/src/gallium/drivers/zink/zink_draw.cpp b/src/gallium/drivers/zink/zink_draw.cpp
index f4e225cd965..214a1a7a339 100644
--- a/src/gallium/drivers/zink/zink_draw.cpp
+++ b/src/gallium/drivers/zink/zink_draw.cpp
@@ -407,10 +407,12 @@ update_barriers(struct zink_context *ctx, bool is_compute)
if (is_compute)
pipeline = VK_PIPELINE_STAGE_COMPUTE_SHADER_BIT;
else if (!pipeline) {
- if (res->ubo_bind_count[0])
- pipeline |= find_pipeline_bits(res->ubo_bind_mask);
- if (!pipeline)
- pipeline |= find_pipeline_bits(res->ssbo_bind_mask);
+ if (res->obj->is_buffer) {
+ if (res->ubo_bind_count[0])
+ pipeline |= find_pipeline_bits(res->ubo_bind_mask);
+ if (!pipeline)
+ pipeline |= find_pipeline_bits(res->ssbo_bind_mask);
+ }
if (!pipeline)
pipeline |= find_pipeline_bits(res->sampler_binds);
if (!pipeline) //must be a shader image
More information about the mesa-commit
mailing list