diff options
Diffstat (limited to 'lib/mesa/src/freedreno/ir3/ir3_dce.c')
-rw-r--r-- | lib/mesa/src/freedreno/ir3/ir3_dce.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/mesa/src/freedreno/ir3/ir3_dce.c b/lib/mesa/src/freedreno/ir3/ir3_dce.c index 76298e64a..a3ddbe802 100644 --- a/lib/mesa/src/freedreno/ir3/ir3_dce.c +++ b/lib/mesa/src/freedreno/ir3/ir3_dce.c @@ -53,8 +53,10 @@ instr_dce(struct ir3_instruction *instr, bool falsedep) if (ir3_instr_check_mark(instr)) return; - if (writes_gpr(instr)) - mark_array_use(instr, instr->dsts[0]); /* dst */ + foreach_dst (dst, instr) { + if (is_dest_gpr(dst)) + mark_array_use(instr, dst); + } foreach_src (reg, instr) mark_array_use(instr, reg); /* src */ |