From 0471b438d6f9f473180c8d4a57d736061d4a006f Mon Sep 17 00:00:00 2001 From: Vasily Khoruzhick Date: Fri, 21 Feb 2025 23:24:59 -0800 Subject: [PATCH] lima: ppir: assign an index for discard block Discard block is the only block that we generate internally, and it currently just gets an index of 0 which collides with the very first block. It is not an issue for compiler, but an eyesore for debug output for a program with discard_if. Assign INT_MAX index for it. Reviewed-by: Erico Nunes Signed-off-by: Vasily Khoruzhick Part-of: --- src/gallium/drivers/lima/ir/pp/nir.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/gallium/drivers/lima/ir/pp/nir.c b/src/gallium/drivers/lima/ir/pp/nir.c index 461e07c5e51..fbba1ce8e7e 100644 --- a/src/gallium/drivers/lima/ir/pp/nir.c +++ b/src/gallium/drivers/lima/ir/pp/nir.c @@ -293,6 +293,7 @@ static bool ppir_emit_discard_block(ppir_compiler *comp) comp->discard_block = block; block->comp = comp; + block->index = INT_MAX; discard = ppir_node_create(block, ppir_op_discard, -1, 0); if (discard)