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]

[tree-profile] tree-inline cleanup 1/many


Hi,
the code handling specially args_init is not needed in cfg inliner.
This is because we no longer recurse, instead we inline function body
and keep walking the chain of basic block starting by the new body so
the contextes should be right.

Honza

Index: tree-inline.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/tree-inline.c,v
retrieving revision 1.26.2.83.2.38
diff -c -3 -p -r1.26.2.83.2.38 tree-inline.c
*** tree-inline.c	15 Apr 2005 13:27:36 -0000	1.26.2.83.2.38
--- tree-inline.c	16 Apr 2005 12:46:16 -0000
*************** expand_call_inline (tree *tp, int *walk_
*** 2293,2318 ****
  
    arg_inits = initialize_inlined_parameters (id, args, TREE_OPERAND (t, 2),
  					     fn, id->bind_expr);
- #if 0
-   if (arg_inits)
-     {
-       /* Expand any inlined calls in the initializers.  Do this before we
- 	 push FN on the stack of functions we are inlining; we want to
- 	 inline calls to FN that appear in the initializers for the
- 	 parameters.
- 
- 	 Note we need to save and restore the saved tree statement iterator
- 	 to avoid having it clobbered by expand_calls_inline.  */
-       tree_stmt_iterator save_tsi;
- 
-       save_tsi = id->tsi;
-       expand_calls_inline (&arg_inits, id);
-       id->tsi = save_tsi;
- 
-       /* And add them to the tree.  */
-       append_to_statement_list (arg_inits, &BIND_EXPR_BODY (expr));
-     }
- #endif
  
    /* Record the function we are about to inline.  */
    id->callee = fn;
--- 2293,2298 ----
Index: ChangeLog.profiling
===================================================================
RCS file: /cvs/gcc/gcc/gcc/Attic/ChangeLog.profiling,v
retrieving revision 1.1.2.138
diff -c -3 -p -r1.1.2.138 ChangeLog.profiling
*** ChangeLog.profiling	16 Apr 2005 12:10:19 -0000	1.1.2.138
--- ChangeLog.profiling	16 Apr 2005 12:46:16 -0000
***************
*** 1,5 ****
--- 1,10 ----
  2005-04-16  Jan Hubicka  <jh@suse.cz>
  
+ 	* tree-inline.c (expand_call_inline): Remove if 0 block in
+ 	expand_call_inline.
+ 
+ 2005-04-16  Jan Hubicka  <jh@suse.cz>
+ 
  	* bitmap.h: Synchronize with mainline
  	* cfganal.c: Synchronize with mainline.
  	* cfgcleanup.c: Synchronize with mainline.


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