pan/bi: Print source types unconditionally
authorAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Tue, 10 Mar 2020 12:47:39 +0000 (08:47 -0400)
committerMarge Bot <eric+marge@anholt.net>
Tue, 10 Mar 2020 19:26:00 +0000 (19:26 +0000)
We track them all now, let's use them.

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4139>

src/panfrost/bifrost/bi_print.c

index a91bb5e8af4122140119588720627d7b2131a21c..e258333649da942c7b636559bcebf74b921e744d 100644 (file)
@@ -349,15 +349,10 @@ bi_print_instruction(bi_instruction *ins, FILE *fp)
         bi_foreach_src(ins, s) {
                 bi_print_src(fp, ins, s);
 
-                if (ins->src[s] && !(ins->src[s] & (BIR_INDEX_CONSTANT | BIR_INDEX_ZERO)))
-                        bi_print_swizzle(ins, s, fp);
-
-                bool is_convert = ins->type == BI_CONVERT && s == 0;
-                bool is_branch = ins->type == BI_BRANCH && s < 2 && ins->branch.cond != BI_COND_ALWAYS;
-                bool is_csel = ins->type == BI_CSEL && s < 2;
-
-                if (is_convert || is_branch || is_csel)
+                if (ins->src[s] && !(ins->src[s] & (BIR_INDEX_CONSTANT | BIR_INDEX_ZERO))) {
                         bi_print_alu_type(ins->src_types[s], fp);
+                        bi_print_swizzle(ins, s, fp);
+                }
 
                 if (s < BIR_SRC_COUNT)
                         fprintf(fp, ", ");