aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorClinton Popetz <cpopetz@cygnus.com>2000-08-04 11:52:08 +0000
committerClinton Popetz <cpopetz@gcc.gnu.org>2000-08-04 07:52:08 -0400
commit5896d7940bf2481467794cd95eafc607794fd0c1 (patch)
treec77879c83ef860d7773982e2d871694160d594e7 /gcc
parent2d0de2459ff9c5d7118c325a515637b362d8b0cf (diff)
downloadgcc-5896d7940bf2481467794cd95eafc607794fd0c1.zip
gcc-5896d7940bf2481467794cd95eafc607794fd0c1.tar.gz
gcc-5896d7940bf2481467794cd95eafc607794fd0c1.tar.bz2
(mips_legitimate_address_p): Don't allow register+offset if the offset is large and negative...
* (mips_legitimate_address_p): Don't allow register+offset if the offset is large and negative, and we are compiling for 64 bit registers. From-SVN: r35477
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/config/mips/mips.c4
2 files changed, 10 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index bb6cdc0..5c8f920 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+Fri Aug 4 06:53:46 2000 Clinton Popetz <cpopetz@cygnus.com>
+
+ * (mips_legitimate_address_p): Don't allow register+offset
+ if the offset is large and negative, and we are compiling
+ for 64 bit registers.
+
2000-08-04 Herman A.J. ten Brugge <Haj.Ten.Brugge@net.HCC.nl>
* gencodes.c (main): Define CODE_FOR_nothing as the last possible
diff --git a/gcc/config/mips/mips.c b/gcc/config/mips/mips.c
index e9258ba..f4d0d12 100644
--- a/gcc/config/mips/mips.c
+++ b/gcc/config/mips/mips.c
@@ -1329,6 +1329,10 @@ mips_legitimate_address_p (mode, xinsn, strict)
&& (!TARGET_EMBEDDED_PIC
|| code1 != CONST
|| GET_CODE (XEXP (xplus1, 0)) != MINUS)
+ /* When assembling for machines with 64 bit registers,
+ the assembler will not sign-extend the constant "foo"
+ in "la x, foo(x)" */
+ && (!TARGET_64BIT || (INTVAL (xplus1) > 0))
&& !TARGET_MIPS16)
return 1;
}