This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[jh@suse.cz: Re: 6 GCC regressions, 2 new, with your patch on 2003-06-24T13:15:02Z.]


Forgot CC.
----- Forwarded message from Jan Hubicka <jh@suse.cz> -----

Delivered-To: hubicka@kam.mff.cuni.cz
X-Sieve: CMU Sieve 2.2
Date: Wed, 25 Jun 2003 19:18:59 +0200
From: Jan Hubicka <jh@suse.cz>
To: Andrew Pinski <pinskia@physics.uc.edu>
Cc: gcc-regression@gcc.gnu.org, jh@suse.cz
Subject: Re: 6 GCC regressions, 2 new, with your patch on 2003-06-24T13:15:02Z.
In-Reply-To: <CE655EC5-A6A0-11D7-865B-000393A6D2F2@physics.uc.edu>
User-Agent: Mutt/1.3.28i
X-Spam-Level: 
X-Spam-Status: No, hits=-4.4 required=5.0 tests=IN_REP_TO version=2.20
X-Spam-Level: 

> 
> On Tuesday, Jun 24, 2003, at 14:05 US/Eastern, GCC regression checker 
> wrote:
> 
> >With your recent patch, GCC has some regression test failures, which
> >used to pass.  There are 2 new failures, and 4
> >failures that existed before and after that patch; 0 failures
> >have been fixed.
> >
> >The new failures are:
> >native gcc.sum gcc.dg/attr-used.c
> >native gcc.sum gcc.dg/pch/inline-1.c
> 
> Both of these looks like is related to one of the unit-at-a-time 
> changes.
The first one is caused by fact that my grep missed one place where
TREE_SYMBOL_REFERENCED is set as there is linewrap.

The pch failure is actually pretty stubble.  I don't save cgraph
datastructure to PCH as I am shooting in long term plan for some
kind of whole program optimization.  But right now it is making number
of troubles (assembler misscompared due to different orderings on some
targets) so I will probably garbage-collectize cgraph for now.

Regtested/bootstrapped i386, OK?

Wed Jun 25 21:16:24 CEST 2003  Jan Hubicka  <jh@suse.cz>
	* c-common.c (handle_used_attribute): Use mark_referenced.
	* varasm.c (mark_referenced): Break out from ...
	(assemble_name): ... here.
	* tree.h (mark_referenced): Declare.
*** c-common.c.old1	Wed Jun 25 20:59:21 2003
--- c-common.c	Wed Jun 25 21:14:44 2003
*************** handle_used_attribute (tree *pnode, tree
*** 4812,4819 ****
  
    if (TREE_CODE (node) == FUNCTION_DECL
        || (TREE_CODE (node) == VAR_DECL && TREE_STATIC (node)))
!     TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (node))
!       = TREE_USED (node) = 1;
    else
      {
        warning ("`%s' attribute ignored", IDENTIFIER_POINTER (name));
--- 4812,4821 ----
  
    if (TREE_CODE (node) == FUNCTION_DECL
        || (TREE_CODE (node) == VAR_DECL && TREE_STATIC (node)))
!     {
!       mark_referenced (DECL_ASSEMBLER_NAME (node));
!       TREE_USED (node) = 1;
!     }
    else
      {
        warning ("`%s' attribute ignored", IDENTIFIER_POINTER (name));
*** varasm.c.old1	Wed Jun 25 20:57:27 2003
--- varasm.c	Wed Jun 25 21:05:24 2003
*************** assemble_label (name)
*** 1728,1733 ****
--- 1728,1757 ----
    ASM_OUTPUT_LABEL (asm_out_file, name);
  }
  
+ /* Set the symbol_referenced flag for ID and notify callgraph code.  */
+ void
+ mark_referenced (id)
+      tree id;
+ {
+   if (!TREE_SYMBOL_REFERENCED (id))
+     {
+       struct cgraph_node *node;
+       struct cgraph_varpool_node *vnode;
+ 
+       if (!cgraph_global_info_ready)
+ 	{
+ 	  node = cgraph_node_for_identifier (id);
+ 	  if (node)
+ 	    cgraph_mark_needed_node (node, 1);
+ 	}
+ 
+       vnode = cgraph_varpool_node_for_identifier (id);
+       if (vnode)
+ 	cgraph_varpool_mark_needed_node (vnode);
+     }
+   TREE_SYMBOL_REFERENCED (id) = 1;
+ }
+ 
  /* Output to FILE a reference to the assembler name of a C-level name NAME.
     If NAME starts with a *, the rest of NAME is output verbatim.
     Otherwise NAME is transformed in an implementation-defined way
*************** assemble_name (file, name)
*** 1746,1770 ****
  
    id = maybe_get_identifier (real_name);
    if (id)
!     {
!       if (!TREE_SYMBOL_REFERENCED (id))
! 	{
! 	  struct cgraph_node *node;
! 	  struct cgraph_varpool_node *vnode;
! 	  
! 	  if (!cgraph_global_info_ready)
! 	    {
! 	      node = cgraph_node_for_identifier (id);
! 	      if (node)
! 		cgraph_mark_needed_node (node, 1);
! 	    }
! 
! 	  vnode = cgraph_varpool_node_for_identifier (id);
! 	  if (vnode)
! 	    cgraph_varpool_mark_needed_node (vnode);
! 	}
!       TREE_SYMBOL_REFERENCED (id) = 1;
!     }
  
    if (name[0] == '*')
      fputs (&name[1], file);
--- 1770,1776 ----
  
    id = maybe_get_identifier (real_name);
    if (id)
!     mark_referenced (id);
  
    if (name[0] == '*')
      fputs (&name[1], file);
*** tree.h.old1	Wed Jun 25 21:17:57 2003
--- tree.h	Wed Jun 25 20:58:34 2003
*************** extern void variable_section		PARAMS ((t
*** 2908,2913 ****
--- 2908,2914 ----
  enum tls_model decl_tls_model		PARAMS ((tree));
  enum symbol_visibility decl_visibility	PARAMS ((tree));
  extern void resolve_unique_section	PARAMS ((tree, int, int));
+ extern void mark_referenced	PARAMS ((tree));
  
  /* In stmt.c */
  extern void emit_nop			PARAMS ((void));

----- End forwarded message -----


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]