OSDN Git Service

2004-04-07 H.J. Lu <hongjiu.lu@intel.com>
authorhjl <hjl@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 8 Apr 2004 05:04:26 +0000 (05:04 +0000)
committerhjl <hjl@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 8 Apr 2004 05:04:26 +0000 (05:04 +0000)
* config/ia64/ia64.c (ia64_encode_section_info): Don't prod
global register variables.

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

gcc/ChangeLog
gcc/config/ia64/ia64.c

index 34b8e14..434bbaa 100644 (file)
@@ -1,3 +1,8 @@
+2004-04-07  H.J. Lu  <hongjiu.lu@intel.com>
+
+       * config/ia64/ia64.c (ia64_encode_section_info): Don't prod
+       global register variables.
+
 2004-04-07  Joseph S. Myers  <jsm@polyomino.org.uk>
 
        * fixinc/inclhack.def (rpc_xdr_lvalue_cast_a,
index 6b90aa8..92cc4fd 100644 (file)
@@ -1116,7 +1116,10 @@ ia64_encode_section_info (tree decl, rtx rtl, int first)
 {
   default_encode_section_info (decl, rtl, first);
 
+  /* Careful not to prod global register variables.  */
   if (TREE_CODE (decl) == VAR_DECL
+      && GET_CODE (DECL_RTL (decl)) == MEM
+      && GET_CODE (XEXP (DECL_RTL (decl), 0)) == SYMBOL_REF
       && (TREE_STATIC (decl) || DECL_EXTERNAL (decl)))
     ia64_encode_addr_area (decl, XEXP (rtl, 0));
 }