From fb6828a9a1619664f7d59f942f9aec697e904d4e Mon Sep 17 00:00:00 2001 From: Mike Blumenkrantz Date: Wed, 8 May 2024 10:43:20 -0400 Subject: [PATCH] zink: rename last_was_compute -> last_work_was_compute Part-of: --- src/gallium/drivers/zink/zink_context.c | 2 +- src/gallium/drivers/zink/zink_draw.cpp | 4 ++-- src/gallium/drivers/zink/zink_types.h | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/gallium/drivers/zink/zink_context.c b/src/gallium/drivers/zink/zink_context.c index 165add79703..603aaf4adb2 100644 --- a/src/gallium/drivers/zink/zink_context.c +++ b/src/gallium/drivers/zink/zink_context.c @@ -4098,7 +4098,7 @@ zink_flush_memory_barrier(struct zink_context *ctx, bool is_compute) VK_PIPELINE_STAGE_GEOMETRY_SHADER_BIT | VK_PIPELINE_STAGE_FRAGMENT_SHADER_BIT; const VkPipelineStageFlags cs_flags = VK_PIPELINE_STAGE_COMPUTE_SHADER_BIT; - VkPipelineStageFlags src = ctx->batch.last_was_compute ? cs_flags : gfx_flags; + VkPipelineStageFlags src = ctx->batch.last_work_was_compute ? cs_flags : gfx_flags; VkPipelineStageFlags dst = is_compute ? cs_flags : gfx_flags; if (ctx->memory_barrier & (PIPE_BARRIER_TEXTURE | PIPE_BARRIER_SHADER_BUFFER | PIPE_BARRIER_IMAGE)) diff --git a/src/gallium/drivers/zink/zink_draw.cpp b/src/gallium/drivers/zink/zink_draw.cpp index a628475a582..1031c6b2506 100644 --- a/src/gallium/drivers/zink/zink_draw.cpp +++ b/src/gallium/drivers/zink/zink_draw.cpp @@ -1120,7 +1120,7 @@ zink_draw(struct pipe_context *pctx, } batch->state->has_work = true; - batch->last_was_compute = false; + batch->last_work_was_compute = false; ctx->batch.work_count = work_count; /* flush if there's >100k draws */ if (!ctx->unordered_blitting && (unlikely(work_count >= 30000) || ctx->oom_flush)) @@ -1303,7 +1303,7 @@ zink_launch_grid(struct pipe_context *pctx, const struct pipe_grid_info *info) } else VKCTX(CmdDispatch)(batch->state->cmdbuf, info->grid[0], info->grid[1], info->grid[2]); batch->state->has_work = true; - batch->last_was_compute = true; + batch->last_work_was_compute = true; /* flush if there's >100k computes */ if (!ctx->unordered_blitting && (unlikely(ctx->batch.work_count >= 30000) || ctx->oom_flush)) pctx->flush(pctx, NULL, 0); diff --git a/src/gallium/drivers/zink/zink_types.h b/src/gallium/drivers/zink/zink_types.h index 2cb158cf5ae..bf666615a88 100644 --- a/src/gallium/drivers/zink/zink_types.h +++ b/src/gallium/drivers/zink/zink_types.h @@ -682,7 +682,7 @@ struct zink_batch { unsigned work_count; - bool last_was_compute; + bool last_work_was_compute; };