global.c (find_reg): Only compute EH_RETURN_DATA_REGNO once per input.

gcc/
	* global.c (find_reg): Only compute EH_RETURN_DATA_REGNO once per
	input.

From-SVN: r131676
This commit is contained in:
Richard Sandiford 2008-01-20 08:47:14 +00:00 committed by Richard Sandiford
parent f2d3cb2501
commit ecff8c1c5d
2 changed files with 12 additions and 2 deletions

View File

@ -1,3 +1,8 @@
2008-01-20 Richard Sandiford <rsandifo@nildram.co.uk>
* global.c (find_reg): Only compute EH_RETURN_DATA_REGNO once per
input.
2008-01-19 Kenneth Zadeck <zadeck@naturalbridge.com>
PR rtl-optimization/26854

View File

@ -1016,8 +1016,13 @@ find_reg (int num, HARD_REG_SET losers, int alt_regs_p, int accept_call_clobbere
if (allocno[num].no_eh_reg)
{
unsigned int j;
for (j = 0; EH_RETURN_DATA_REGNO (j) != INVALID_REGNUM; j++)
SET_HARD_REG_BIT (used1, EH_RETURN_DATA_REGNO (j));
for (j = 0; ; ++j)
{
unsigned int regno = EH_RETURN_DATA_REGNO (j);
if (regno == INVALID_REGNUM)
break;
SET_HARD_REG_BIT (used1, regno);
}
}
#endif