[multiple changes]
authorJakub Jelinek <jakub@gcc.gnu.org>
Thu, 28 Jun 2007 11:28:13 +0000 (13:28 +0200)
committerJakub Jelinek <jakub@gcc.gnu.org>
Thu, 28 Jun 2007 11:28:13 +0000 (13:28 +0200)
2007-06-28  Jakub Jelinek  <jakub@redhat.com>

* config/rs6000/rs6000.c (rs6000_function_ok_for_sibcall): Ensure
decl is non-external for AIX ABI.

2007-06-28  David Edelsohn  <edelsohn@gnu.org>

* config/rs6000/predicates.md (current_file_function_operand):
Ensure the symbol is non-external for AIX ABI.

From-SVN: r126076

gcc/ChangeLog
gcc/config/rs6000/predicates.md
gcc/config/rs6000/rs6000.c

index cb9878e2389f4b25a8e2f043181940d8e31eaa09..81a57a8967fbe05004ca18562c7417095e6d2a49 100644 (file)
@@ -1,3 +1,13 @@
+2007-06-28  Jakub Jelinek  <jakub@redhat.com>
+
+       * config/rs6000/rs6000.c (rs6000_function_ok_for_sibcall): Ensure
+       decl is non-external for AIX ABI.
+
+2007-06-28  David Edelsohn  <edelsohn@gnu.org>
+
+       * config/rs6000/predicates.md (current_file_function_operand):
+       Ensure the symbol is non-external for AIX ABI.
+
 2007-06-28  Nick Clifton  <nickc@redhat.com>
 
        * common.opt (fipa-matrix-reorg): Add Optimization attribute.
index 5f4b233cef9e88c5242f87ed1dbe9514b095a284..3b54aedffba337ba5706ec8ff14f6615294392e7 100644 (file)
 (define_predicate "current_file_function_operand"
   (and (match_code "symbol_ref")
        (match_test "(DEFAULT_ABI != ABI_AIX || SYMBOL_REF_FUNCTION_P (op))
-                   && (SYMBOL_REF_LOCAL_P (op)
+                   && ((SYMBOL_REF_LOCAL_P (op)
+                        && (DEFAULT_ABI != ABI_AIX
+                            || !SYMBOL_REF_EXTERNAL_P (op)))
                        || (op == XEXP (DECL_RTL (current_function_decl),
                                                  0)))")))
 
index 035d655e971601ab80a01a7b3607d5079712b3d4..f9bca5002a64551c6e7aefccb0df3ebca84736eb 100644 (file)
@@ -13938,7 +13938,8 @@ rs6000_function_ok_for_sibcall (tree decl, tree exp ATTRIBUTE_UNUSED)
            }
        }
       if (DEFAULT_ABI == ABI_DARWIN
-         || (*targetm.binds_local_p) (decl))
+         || ((*targetm.binds_local_p) (decl)
+             && (DEFAULT_ABI != ABI_AIX || !DECL_EXTERNAL (decl))))
        {
          tree attr_list = TYPE_ATTRIBUTES (TREE_TYPE (decl));