i965/fs: Let register_coalesce_2() eliminate self-moves.
This is the last thing that register_coalesce() still handled. total instructions in shared programs: 1561060 -> 1560908 (-0.01%) instructions in affected programs: 15758 -> 15606 (-0.96%) Reviewed-by: Eric Anholt <eric@anholt.net>
This commit is contained in:
parent
8786f381ec
commit
1520ae48b8
|
@ -2271,7 +2271,8 @@ fs_visitor::register_coalesce_2()
|
|||
int var_from = live_intervals->var_from_reg(&inst->src[0]);
|
||||
int var_to = live_intervals->var_from_reg(&inst->dst);
|
||||
|
||||
if (live_intervals->vars_interfere(var_from, var_to))
|
||||
if (live_intervals->vars_interfere(var_from, var_to) &&
|
||||
!inst->dst.equals(inst->src[0]))
|
||||
continue;
|
||||
|
||||
int reg_from = inst->src[0].reg;
|
||||
|
|
Loading…
Reference in New Issue