diff options
author | Hans-Peter Nilsson <hp@bitrange.com> | 2004-12-31 16:24:48 +0000 |
---|---|---|
committer | Hans-Peter Nilsson <hp@gcc.gnu.org> | 2004-12-31 16:24:48 +0000 |
commit | 32f2ce029997a7d1d4be975ddafd7dcf6574d49c (patch) | |
tree | 6472fae54cd2a808f7ac4b8ac0e6aa0b3ac2c1ac /gcc/combine.c | |
parent | 8c8a5f7c8e5c0e05d38272f09bee1ec442a3d2cc (diff) | |
download | gcc-32f2ce029997a7d1d4be975ddafd7dcf6574d49c.zip gcc-32f2ce029997a7d1d4be975ddafd7dcf6574d49c.tar.gz gcc-32f2ce029997a7d1d4be975ddafd7dcf6574d49c.tar.bz2 |
re PR target/18701 (mmix-knuth-mmixware gcc.c-torture/execute failures: 20010224-1.c, 20020216-1.c, 20040218-1.c, 20040709-2.c)
PR target/18701
* combine.c (gen_lowpart_for_combine): When stripping SUBREG of
MEM, adjust imode and isize.
From-SVN: r92760
Diffstat (limited to 'gcc/combine.c')
-rw-r--r-- | gcc/combine.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/gcc/combine.c b/gcc/combine.c index 800e65e..61b93dd 100644 --- a/gcc/combine.c +++ b/gcc/combine.c @@ -9355,8 +9355,16 @@ gen_lowpart_for_combine (enum machine_mode omode, rtx x) if (GET_CODE (x) == SUBREG && MEM_P (SUBREG_REG (x))) { x = SUBREG_REG (x); - if (GET_MODE (x) == omode) + + /* For use in case we fall down into the address adjustments + further below, we need to adjust the known mode and size of + x; imode and isize, since we just adjusted x. */ + imode = GET_MODE (x); + + if (imode == omode) return x; + + isize = GET_MODE_SIZE (imode); } result = gen_lowpart_common (omode, x); |