regrename.c (find_oldest_value_reg): If the replacement uses multiple hard registers...
* regrename.c (find_oldest_value_reg): If the replacement uses multiple hard registers, check that all of them are in CLASS. From-SVN: r75867
This commit is contained in:
parent
e7844ffbe7
commit
684bcee536
|
@ -1,3 +1,8 @@
|
|||
2004-01-14 Richard Earnshaw <rearnsha@arm.com>
|
||||
|
||||
* regrename.c (find_oldest_value_reg): If the replacement uses
|
||||
multiple hard registers, check that all of them are in CLASS.
|
||||
|
||||
2004-01-14 Jan Hubicka <jh@suse.cz>
|
||||
|
||||
* alias.c (get_alias_set): Initialize alias set to 0 when subset is
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/* Register renaming for the GNU compiler.
|
||||
Copyright (C) 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
|
||||
Copyright (C) 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
|
||||
|
||||
This file is part of GCC.
|
||||
|
||||
|
@ -1339,15 +1339,19 @@ find_oldest_value_reg (enum reg_class class, rtx reg, struct value_data *vd)
|
|||
{
|
||||
enum machine_mode oldmode = vd->e[i].mode;
|
||||
rtx new;
|
||||
unsigned int last;
|
||||
|
||||
if (TEST_HARD_REG_BIT (reg_class_contents[class], i)
|
||||
&& (new = maybe_mode_change (oldmode, vd->e[regno].mode, mode, i,
|
||||
regno)))
|
||||
{
|
||||
ORIGINAL_REGNO (new) = ORIGINAL_REGNO (reg);
|
||||
REG_ATTRS (new) = REG_ATTRS (reg);
|
||||
return new;
|
||||
}
|
||||
for (last = i; last < i + HARD_REGNO_NREGS (i, mode); last++)
|
||||
if (!TEST_HARD_REG_BIT (reg_class_contents[class], last))
|
||||
return NULL_RTX;
|
||||
|
||||
if (new = maybe_mode_change (oldmode, vd->e[regno].mode, mode, i,
|
||||
regno))
|
||||
{
|
||||
ORIGINAL_REGNO (new) = ORIGINAL_REGNO (reg);
|
||||
REG_ATTRS (new) = REG_ATTRS (reg);
|
||||
return new;
|
||||
}
|
||||
}
|
||||
|
||||
return NULL_RTX;
|
||||
|
|
Loading…
Reference in New Issue