From 42bd17b7fc6af8d4239ff6925bc0697a84545c6a Mon Sep 17 00:00:00 2001 From: Richard Henderson Date: Wed, 9 Jan 2002 12:54:49 -0800 Subject: regrename.c (copy_value): Ignore the copy if the source register is present in the value chain with a... * regrename.c (copy_value): Ignore the copy if the source register is present in the value chain with a narrower mode. From-SVN: r48689 --- gcc/regrename.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'gcc/regrename.c') diff --git a/gcc/regrename.c b/gcc/regrename.c index c164d21..d101525 100644 --- a/gcc/regrename.c +++ b/gcc/regrename.c @@ -1244,6 +1244,12 @@ copy_value (dest, src, vd) if (vd->e[sr].mode == VOIDmode) set_value_regno (sr, vd->e[dr].mode, vd); + /* If SRC had been assigned a mode narrower than the copy, we can't + link DEST into the chain, because not all of the pieces of the + copy came from oldest_regno. */ + else if (sn > (unsigned int) HARD_REGNO_NREGS (sr, vd->e[sr].mode)) + return; + /* Link DR at the end of the value chain used by SR. */ vd->e[dr].oldest_regno = vd->e[sr].oldest_regno; -- cgit v1.1