From ef75ea18cd352e4bee17c46069babe5ca3390641 Mon Sep 17 00:00:00 2001 From: Connor Abbott Date: Tue, 21 Feb 2023 16:53:04 +0100 Subject: [PATCH] ir3: Don't emit single-source collects This will help us propagate shared-ness through to stc when it has a single component. Part-of: --- src/freedreno/ir3/ir3_context.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/freedreno/ir3/ir3_context.c b/src/freedreno/ir3/ir3_context.c index 13059d8d6af..35a1453780c 100644 --- a/src/freedreno/ir3/ir3_context.c +++ b/src/freedreno/ir3/ir3_context.c @@ -284,6 +284,9 @@ ir3_create_collect(struct ir3_block *block, struct ir3_instruction *const *arr, if (arrsz == 0) return NULL; + if (arrsz == 1) + return arr[0]; + unsigned flags = dest_flags(arr[0]); collect = ir3_instr_create(block, OPC_META_COLLECT, 1, arrsz);