From: Gert Wollny Date: Mon, 21 Nov 2022 08:39:35 +0000 (+0100) Subject: r600: Fix lower-to-scalar on TTN path X-Git-Tag: upstream/23.3.3~16600 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=67ffe25fd9de94acc654312ec9261d811d139adf;p=platform%2Fupstream%2Fmesa.git r600: Fix lower-to-scalar on TTN path We must limit what alu ops are scalazized, and since we now run finalize_nir we also have to make sure not to try to scalarize backend specific instructions that are introduced there. While we touch the code, also remove the vectorization, it is no longer helping. Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/7747 Fixes: a81c50a2 (r600/sfn: implement finalize_nir) Signed-off-by: Gert Wollny Part-of: --- diff --git a/src/gallium/drivers/r600/r600_shader.c b/src/gallium/drivers/r600/r600_shader.c index 532c25e..db0b16f 100644 --- a/src/gallium/drivers/r600/r600_shader.c +++ b/src/gallium/drivers/r600/r600_shader.c @@ -209,9 +209,8 @@ int r600_pipe_shader_create(struct pipe_context *ctx, /* Lower int64 ops because we have some r600 build-in shaders that use it */ if (nir_options->lower_int64_options) { NIR_PASS_V(sel->nir, nir_lower_regs_to_ssa); - NIR_PASS_V(sel->nir, nir_lower_alu_to_scalar, NULL, NULL); + NIR_PASS_V(sel->nir, nir_lower_alu_to_scalar, r600_lower_to_scalar_instr_filter, NULL); NIR_PASS_V(sel->nir, nir_lower_int64); - NIR_PASS_V(sel->nir, nir_opt_vectorize, NULL, NULL); } NIR_PASS_V(sel->nir, nir_lower_flrp, ~0, false); }