From 77552cbdda195df25eca59eadd40d448801681eb Mon Sep 17 00:00:00 2001 From: Rob Clark Date: Mon, 21 Dec 2020 09:05:05 -0800 Subject: [PATCH] freedreno/ir3: Don't set bit for dest conversion for p0.c This appears to be ignored when writing to predicate registers (which I guess makes sense, since they are boolean). So no real harm in setting it, other than it makes some of the ir3_parser test vectors not match the expected result for encoding. Signed-off-by: Rob Clark Part-of: --- src/freedreno/ir3/ir3.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/freedreno/ir3/ir3.c b/src/freedreno/ir3/ir3.c index e9ab730ea0f..6308bf27424 100644 --- a/src/freedreno/ir3/ir3.c +++ b/src/freedreno/ir3/ir3.c @@ -325,7 +325,9 @@ static int emit_cat2(struct ir3_instruction *instr, void *ptr, cat2->sat = !!(instr->flags & IR3_INSTR_SAT); cat2->ss = !!(instr->flags & IR3_INSTR_SS); cat2->ul = !!(instr->flags & IR3_INSTR_UL); - cat2->dst_half = !!((src1->flags ^ dst->flags) & IR3_REG_HALF); + /* dst widen/narrow doesn't apply to p0.c */ + if (dst->num < regid(REG_P0, 0)) + cat2->dst_half = !!((src1->flags ^ dst->flags) & IR3_REG_HALF); cat2->ei = !!(dst->flags & IR3_REG_EI); cat2->cond = instr->cat2.condition; cat2->full = ! (src1->flags & IR3_REG_HALF);