bfin.c (bfin_legitimate_address_p): Disallow got-relative addressing for anything...
authorBernd Schmidt <bernd.schmidt@analog.com>
Wed, 5 Apr 2006 19:37:42 +0000 (19:37 +0000)
committerBernd Schmidt <bernds@gcc.gnu.org>
Wed, 5 Apr 2006 19:37:42 +0000 (19:37 +0000)
* config/bfin/bfin.c (bfin_legitimate_address_p): Disallow
got-relative addressing for anything but SImode.

From-SVN: r112718

gcc/ChangeLog
gcc/config/bfin/bfin.c

index 3f14ac8..4602174 100644 (file)
@@ -1,3 +1,8 @@
+2006-04-05  Bernd Schmidt  <bernd.schmidt@analog.com>
+
+       * config/bfin/bfin.c (bfin_legitimate_address_p): Disallow
+       got-relative addressing for anything but SImode.
+
 2006-04-05  Richard Guenther  <rguenther@suse.de>
 
        PR tree-optimization/26919
index dfaa567..e4893e8 100644 (file)
@@ -2133,7 +2133,7 @@ bfin_legitimate_address_p (enum machine_mode mode, rtx x, int strict)
   case PLUS:
     if (REG_P (XEXP (x, 0))
        && bfin_valid_reg_p (REGNO (XEXP (x, 0)), strict, mode, PLUS)
-       && (GET_CODE (XEXP (x, 1)) == UNSPEC
+       && ((GET_CODE (XEXP (x, 1)) == UNSPEC && mode == SImode)
            || (GET_CODE (XEXP (x, 1)) == CONST_INT
                && bfin_valid_add (mode, INTVAL (XEXP (x, 1))))))
       return true;