Commit 75fefa91 by Po-Chun Chang Committed by Eric Botcazou

re PR rtl-optimization/57786 (wasted work in distribute_notes)

	PR rtl-optimization/57786
	* combine.c (distribute_notes) <case REG_DEAD>: Change all_used to bool
	and break out of the loop when it is set to false.

From-SVN: r200776
parent 8140c065
2013-07-08 Po-Chun Chang <pchang9@cs.wisc.edu>
PR rtl-optimization/57786
* combine.c (distribute_notes) <case REG_DEAD>: Change all_used to bool
and break out of the loop when it is set to false.
2013-07-08 Jakub Jelinek <jakub@redhat.com> 2013-07-08 Jakub Jelinek <jakub@redhat.com>
PR target/57819 PR target/57819
......
...@@ -13580,14 +13580,17 @@ distribute_notes (rtx notes, rtx from_insn, rtx i3, rtx i2, rtx elim_i2, ...@@ -13580,14 +13580,17 @@ distribute_notes (rtx notes, rtx from_insn, rtx i3, rtx i2, rtx elim_i2,
&& hard_regno_nregs[regno][GET_MODE (XEXP (note, 0))] > 1) && hard_regno_nregs[regno][GET_MODE (XEXP (note, 0))] > 1)
{ {
unsigned int endregno = END_HARD_REGNO (XEXP (note, 0)); unsigned int endregno = END_HARD_REGNO (XEXP (note, 0));
int all_used = 1; bool all_used = true;
unsigned int i; unsigned int i;
for (i = regno; i < endregno; i++) for (i = regno; i < endregno; i++)
if ((! refers_to_regno_p (i, i + 1, PATTERN (place), 0) if ((! refers_to_regno_p (i, i + 1, PATTERN (place), 0)
&& ! find_regno_fusage (place, USE, i)) && ! find_regno_fusage (place, USE, i))
|| dead_or_set_regno_p (place, i)) || dead_or_set_regno_p (place, i))
all_used = 0; {
all_used = false;
break;
}
if (! all_used) if (! all_used)
{ {
...@@ -13631,7 +13634,6 @@ distribute_notes (rtx notes, rtx from_insn, rtx i3, rtx i2, rtx elim_i2, ...@@ -13631,7 +13634,6 @@ distribute_notes (rtx notes, rtx from_insn, rtx i3, rtx i2, rtx elim_i2,
break; break;
} }
} }
} }
place = 0; place = 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment