zink: end rp earlier in set_framebuffer_state

this way any barriers occuring from unbinds won't have to do rp calc

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21906>
This commit is contained in:
Mike Blumenkrantz
2023-03-15 14:04:32 -04:00
committed by Marge Bot
parent 63f425c7d2
commit 22fb4578a0
+2 -2
View File
@@ -3285,6 +3285,8 @@ zink_set_framebuffer_state(struct pipe_context *pctx,
zink_batch_rp(ctx);
ctx->queries_disabled = queries_disabled;
}
/* need to ensure we start a new rp on next draw */
zink_batch_no_rp_safe(ctx);
for (int i = 0; i < ctx->fb_state.nr_cbufs; i++) {
struct pipe_surface *psurf = ctx->fb_state.cbufs[i];
if (i < state->nr_cbufs)
@@ -3418,8 +3420,6 @@ zink_set_framebuffer_state(struct pipe_context *pctx,
}
ctx->gfx_pipeline_state.rast_samples = rast_samples;
/* need to ensure we start a new rp on next draw */
zink_batch_no_rp_safe(ctx);
/* this is an ideal time to oom flush since it won't split a renderpass */
if (ctx->oom_flush)
flush_batch(ctx, false);