From c3987eb5fcd8c72df866bdca2f3069ebd734e442 Mon Sep 17 00:00:00 2001 From: Simon Perretta Date: Thu, 13 Mar 2025 12:41:58 +0000 Subject: [PATCH] pco: skip lowering fs outputs that aren't present Signed-off-by: Simon Perretta Acked-by: Erik Faye-Lund Part-of: --- src/imagination/pco/pco_nir_pvfio.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/imagination/pco/pco_nir_pvfio.c b/src/imagination/pco/pco_nir_pvfio.c index eeac3ae79ae..d4331d0072a 100644 --- a/src/imagination/pco/pco_nir_pvfio.c +++ b/src/imagination/pco/pco_nir_pvfio.c @@ -740,6 +740,9 @@ static nir_def *lower_pfo_store(nir_builder *b, b->cursor = nir_before_instr(&intr->instr); enum pipe_format format = state->fs->output_formats[location]; + if (format == PIPE_FORMAT_NONE) + return NIR_LOWER_INSTR_PROGRESS_REPLACE; + format = to_pbe_format(b, format, &input); nir_alu_type src_type = nir_intrinsic_src_type(intr); @@ -788,6 +791,8 @@ static nir_def *lower_pfo_load(nir_builder *b, gl_frag_result location = io_semantics.location; enum pipe_format format = state->fs->output_formats[location]; + if (format == PIPE_FORMAT_NONE) + return nir_undef(b, intr->def.num_components, intr->def.bit_size); format = to_pbe_format(b, format, NULL);