zink: remove batch usage from sampler states
authorMike Blumenkrantz <michael.blumenkrantz@gmail.com>
Thu, 1 Sep 2022 13:37:06 +0000 (09:37 -0400)
committerMarge Bot <emma+marge@anholt.net>
Thu, 22 Sep 2022 21:38:47 +0000 (21:38 +0000)
this was useless

Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18664>

src/gallium/drivers/zink/zink_context.c
src/gallium/drivers/zink/zink_types.h

index e822a05..3349c30 100644 (file)
@@ -709,7 +709,6 @@ zink_bind_sampler_states(struct pipe_context *pctx,
                  (surface->base.format == PIPE_FORMAT_Z24_UNORM_S8_UINT && surface->ivci.format == VK_FORMAT_D32_SFLOAT_S8_UINT)))
                ctx->di.textures[shader][start_slot + i].sampler = state->sampler_clamped;
          }
-         zink_batch_usage_set(&state->batch_uses, ctx->batch.state);
       } else {
          ctx->di.textures[shader][start_slot + i].sampler = VK_NULL_HANDLE;
       }
@@ -2634,10 +2633,6 @@ update_resource_refs_for_stage(struct zink_context *ctx, gl_shader_stage stage)
                res->obj->unordered_read = res->obj->unordered_write = false;
             else
                res->obj->unordered_read = false;
-
-            struct zink_sampler_state *sampler_state = ctx->sampler_states[stage][j];
-            if (sampler_state && i == ZINK_DESCRIPTOR_TYPE_SAMPLER_VIEW && j <= ctx->di.num_samplers[stage])
-               zink_batch_usage_set(&sampler_state->batch_uses, ctx->batch.state);
          }
       }
    }
index 6f25690..52d26c6 100644 (file)
@@ -1252,7 +1252,6 @@ struct zink_framebuffer {
 struct zink_sampler_state {
    VkSampler sampler;
    VkSampler sampler_clamped;
-   struct zink_batch_usage *batch_uses;
    bool custom_border_color;
    bool emulate_nonseamless;
 };