freedreno: Fix crash with debug msgs enabled

Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25231>
This commit is contained in:
Rob Clark
2023-09-14 12:34:19 -07:00
committed by Marge Bot
parent cd2c4927c8
commit 4952db73fb
@@ -364,9 +364,11 @@ draw_vbos(struct fd_context *ctx, const struct pipe_draw_info *info,
if (unlikely(ctx->stats_users > 0)) {
ctx->stats.vs_regs += ir3_shader_halfregs(emit.vs);
ctx->stats.hs_regs += COND(emit.hs, ir3_shader_halfregs(emit.hs));
ctx->stats.ds_regs += COND(emit.ds, ir3_shader_halfregs(emit.ds));
ctx->stats.gs_regs += COND(emit.gs, ir3_shader_halfregs(emit.gs));
if (PIPELINE == HAS_TESS_GS) {
ctx->stats.hs_regs += COND(emit.hs, ir3_shader_halfregs(emit.hs));
ctx->stats.ds_regs += COND(emit.ds, ir3_shader_halfregs(emit.ds));
ctx->stats.gs_regs += COND(emit.gs, ir3_shader_halfregs(emit.gs));
}
ctx->stats.fs_regs += ir3_shader_halfregs(emit.fs);
}