OSDN Git Service

PR target/9210
authorjsturm <jsturm@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 9 Jan 2003 01:10:43 +0000 (01:10 +0000)
committerjsturm <jsturm@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 9 Jan 2003 01:10:43 +0000 (01:10 +0000)
* config/rs6000/rs6000.c (rs6000_elf_encode_section_info):
Set SYMBOL_REF_FLAG on local data sym_ref.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@61064 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/config/rs6000/rs6000.c

index 7e787a3..8a7cf40 100644 (file)
@@ -1,3 +1,9 @@
+2003-01-08  Jeff Sturm  <jsturm@one-point.com>
+
+       PR target/9210
+       * config/rs6000/rs6000.c (rs6000_elf_encode_section_info):
+       Set SYMBOL_REF_FLAG on local data sym_ref.
+
 2003-01-08  Dale Johannesen  <dalej@apple.com>
  
         * function.c (assign_parms):  Don't set pretend_args_size if 
index 420085c..6112737 100644 (file)
@@ -12562,11 +12562,15 @@ rs6000_elf_encode_section_info (decl, first)
           && DEFAULT_ABI == ABI_V4
           && TREE_CODE (decl) == VAR_DECL)
     {
+      rtx sym_ref = XEXP (DECL_RTL (decl), 0);
       int size = int_size_in_bytes (TREE_TYPE (decl));
       tree section_name = DECL_SECTION_NAME (decl);
       const char *name = (char *)0;
       int len = 0;
 
+      if ((*targetm.binds_local_p) (decl))
+       SYMBOL_REF_FLAG (sym_ref) = 1;
+
       if (section_name)
        {
          if (TREE_CODE (section_name) == STRING_CST)
@@ -12593,7 +12597,6 @@ rs6000_elf_encode_section_info (decl, first)
                  || (len == sizeof (".PPC.EMB.sbss0") - 1
                      && strcmp (name, ".PPC.EMB.sbss0") == 0))))
        {
-         rtx sym_ref = XEXP (DECL_RTL (decl), 0);
          size_t len = strlen (XSTR (sym_ref, 0));
          char *str = alloca (len + 2);