Fix last commit.
authorRichard Sandiford <rsandifo@nildram.co.uk>
Thu, 6 Dec 2007 17:54:59 +0000 (17:54 +0000)
committerRichard Sandiford <rsandifo@gcc.gnu.org>
Thu, 6 Dec 2007 17:54:59 +0000 (17:54 +0000)
From-SVN: r130654

gcc/ChangeLog
gcc/config/mips/mips.c

index 4a99f2d70f432767254f4c2c829529f3ed7f4f9d..1aec1408048854cb7aab0e99d8c28a015bbee148 100644 (file)
@@ -1,7 +1,7 @@
 2007-12-06  Richard Sandiford  <rsandifo@nildram.co.uk>
 
-       * config/mips/mips.c (mips_function_ok_for_sibcall): Use
-       targetm.binds_local_p instead of DECL_EXTERNAL.
+       * config/mips/mips.c (mips_function_ok_for_sibcall): Check
+       targetm.binds_local_p as well as DECL_EXTERNAL.
 
 2007-12-06  Harsha Jagasia <harsha.jagasia@amd.com>
 
index 125f08714783b6298f378c4c410edf5b56bb3791..e7c9909dec00bb53eb50b7201447b053884b43fa 100644 (file)
@@ -5616,7 +5616,7 @@ mips_function_ok_for_sibcall (tree decl, tree exp ATTRIBUTE_UNUSED)
      us otherwise.  */
   if (TARGET_INTERLINK_MIPS16
       && decl
-      && !targetm.binds_local_p (decl)
+      && (DECL_EXTERNAL (decl) || !targetm.binds_local_p (decl))
       && !mips_nomips16_decl_p (decl)
       && const_call_insn_operand (XEXP (DECL_RTL (decl), 0), VOIDmode))
     return false;