diff options
author | Geoff Keating <geoffk@cygnus.com> | 2000-05-28 01:06:11 +0000 |
---|---|---|
committer | Geoffrey Keating <geoffk@gcc.gnu.org> | 2000-05-28 01:06:11 +0000 |
commit | ed8afe3ab07e9ed5cd22900331946b0d19eb6a04 (patch) | |
tree | d3e739aad3e230a0803a04aa080152f552cea4f1 | |
parent | f624ffa71f84afc0f8fb14e76a664a4556574efd (diff) | |
download | gcc-ed8afe3ab07e9ed5cd22900331946b0d19eb6a04.zip gcc-ed8afe3ab07e9ed5cd22900331946b0d19eb6a04.tar.gz gcc-ed8afe3ab07e9ed5cd22900331946b0d19eb6a04.tar.bz2 |
combine.c (subst): Honour CLASS_CANNOT_CHANGE_SIZE when substituting the REG in a (subreg:X (reg:Y...
* combine.c (subst): Honour CLASS_CANNOT_CHANGE_SIZE when
substituting the REG in a (subreg:X (reg:Y ...)).
From-SVN: r34217
-rw-r--r-- | gcc/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/combine.c | 12 |
2 files changed, 17 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index a2d5253..f491f3c 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2000-05-27 Geoff Keating <geoffk@cygnus.com> + + * combine.c (subst): Honour CLASS_CANNOT_CHANGE_SIZE when + substituting the REG in a (subreg:X (reg:Y ...)). + 2000-05-28 Neil Booth <NeilB@earthling.net> * cpplex.c (_cpp_lex_line): Merge vertical space. Flag diff --git a/gcc/combine.c b/gcc/combine.c index c9d6a52..8a14d80 100644 --- a/gcc/combine.c +++ b/gcc/combine.c @@ -3400,6 +3400,18 @@ subst (x, from, to, in_dest, unique_copy) ) return gen_rtx_CLOBBER (VOIDmode, const0_rtx); +#ifdef CLASS_CANNOT_CHANGE_SIZE + if (code == SUBREG + && GET_CODE (to) == REG + && REGNO (to) < FIRST_PSEUDO_REGISTER + && (TEST_HARD_REG_BIT + (reg_class_contents[(int) CLASS_CANNOT_CHANGE_SIZE], + REGNO (to))) + && (GET_MODE_BITSIZE (GET_MODE (to)) + != GET_MODE_BITSIZE (GET_MODE (x)))) + return gen_rtx_CLOBBER (VOIDmode, const0_rtx); +#endif + new = (unique_copy && n_occurrences ? copy_rtx (to) : to); n_occurrences++; } |