From c282f80c98831a2c41792eae39e843e9c3fb4809 Mon Sep 17 00:00:00 2001 From: Alyssa Rosenzweig Date: Mon, 17 Jul 2023 16:54:58 -0400 Subject: [PATCH] panfrost: Fix transform feedback on v9 We were using a stale FAU buffer which meant we wrote to garbage addresses. I'm guessing this was fallout from the big sysval rework but not 100% sure. Signed-off-by: Alyssa Rosenzweig Cc: mesa-stable Part-of: --- src/gallium/drivers/panfrost/pan_cmdstream.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/gallium/drivers/panfrost/pan_cmdstream.c b/src/gallium/drivers/panfrost/pan_cmdstream.c index 89ec578d4ec..185b2f99f8d 100644 --- a/src/gallium/drivers/panfrost/pan_cmdstream.c +++ b/src/gallium/drivers/panfrost/pan_cmdstream.c @@ -3436,6 +3436,10 @@ panfrost_launch_xfb(struct panfrost_batch *batch, batch->rsd[PIPE_SHADER_VERTEX] = panfrost_emit_compute_shader_meta(batch, PIPE_SHADER_VERTEX); + batch->uniform_buffers[PIPE_SHADER_VERTEX] = + panfrost_emit_const_buf(batch, PIPE_SHADER_VERTEX, NULL, + &batch->push_uniforms[PIPE_SHADER_VERTEX], NULL); + #if PAN_ARCH >= 9 pan_section_pack(t.cpu, COMPUTE_JOB, PAYLOAD, cfg) { cfg.workgroup_size_x = 1; @@ -3466,10 +3470,6 @@ panfrost_launch_xfb(struct panfrost_batch *batch, info->instance_count, 1, 1, 1, PAN_ARCH <= 5, false); - batch->uniform_buffers[PIPE_SHADER_VERTEX] = - panfrost_emit_const_buf(batch, PIPE_SHADER_VERTEX, NULL, - &batch->push_uniforms[PIPE_SHADER_VERTEX], NULL); - panfrost_draw_emit_vertex(batch, info, &invocation, 0, 0, attribs, attrib_bufs, t.cpu); #endif