From cbeb80c1903170644c3d30b626ad871fb123a7ae Mon Sep 17 00:00:00 2001 From: Mike Blumenkrantz Date: Wed, 29 Oct 2025 09:59:13 -0400 Subject: [PATCH] zink: collapse gfx pipeline fetching and binding conditionals this avoids taking the wrong conditional if a pipeline fetch fails cc: mesa-stable Part-of: (cherry picked from commit 0b24fd174a8cf9543b07bdfa150d868d673ce44a) --- .pick_status.json | 2 +- src/gallium/drivers/zink/zink_draw.cpp | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/.pick_status.json b/.pick_status.json index da641259e2a..96150bb447d 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -24,7 +24,7 @@ "description": "zink: collapse gfx pipeline fetching and binding conditionals", "nominated": true, "nomination_type": 1, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": null, "notes": null diff --git a/src/gallium/drivers/zink/zink_draw.cpp b/src/gallium/drivers/zink/zink_draw.cpp index d40b378489c..8df345a9223 100644 --- a/src/gallium/drivers/zink/zink_draw.cpp +++ b/src/gallium/drivers/zink/zink_draw.cpp @@ -268,8 +268,7 @@ update_gfx_pipeline(struct zink_context *ctx, struct zink_batch_state *bs, enum pipeline = zink_get_gfx_pipeline(ctx, ctx->curr_program, &ctx->gfx_pipeline_state, mode); else pipeline = zink_get_gfx_pipeline(ctx, ctx->curr_program, &ctx->gfx_pipeline_state, mode); - } - if (pipeline) { + assert(pipeline); pipeline_changed = prev_pipeline != pipeline || ctx->shobj_draw; if (BATCH_CHANGED || pipeline_changed) VKCTX(CmdBindPipeline)(bs->cmdbuf, VK_PIPELINE_BIND_POINT_GRAPHICS, pipeline);