mirror of git://gcc.gnu.org/git/gcc.git
Makefile.in (cfgexpand.o): Add $(REGS_H) and $(INTEGRATE_H) dependencies.
2012-03-21 Richard Guenther <rguenther@suse.de> * Makefile.in (cfgexpand.o): Add $(REGS_H) and $(INTEGRATE_H) dependencies. * cfgexpand.c (gimple_expand_cfg): Fold in pass_init_function, pass_jump, pass_initial_value_sets and pass_unshare_all_rtl. * passes.c (init_optimization_passes): Remove pass_init_function, pass_jump, pass_initial_value_sets and pass_unshare_all_rtl. * tree-pass.h (pass_init_function): Remove. (pass_jump): Remove. (pass_initial_value_sets): Remove. (pass_unshare_all_rtl): Remove. * integrate.c (pass_initial_value_sets): Remove. * emit-rtl.c (pass_unshare_all_rtl): Remove. * tree.h (init_function_for_compilation): Remove. * function.c (init_function_for_compilation): Remove. (pass_init_function): Remove. * cfgcleanup.c (rest_of_handle_jump): Remove. (pass_jump): Remove. From-SVN: r185598
This commit is contained in:
parent
552b8185be
commit
be147e848b
|
@ -1,3 +1,23 @@
|
||||||
|
2012-03-21 Richard Guenther <rguenther@suse.de>
|
||||||
|
|
||||||
|
* Makefile.in (cfgexpand.o): Add $(REGS_H) and $(INTEGRATE_H)
|
||||||
|
dependencies.
|
||||||
|
* cfgexpand.c (gimple_expand_cfg): Fold in pass_init_function,
|
||||||
|
pass_jump, pass_initial_value_sets and pass_unshare_all_rtl.
|
||||||
|
* passes.c (init_optimization_passes): Remove pass_init_function,
|
||||||
|
pass_jump, pass_initial_value_sets and pass_unshare_all_rtl.
|
||||||
|
* tree-pass.h (pass_init_function): Remove.
|
||||||
|
(pass_jump): Remove.
|
||||||
|
(pass_initial_value_sets): Remove.
|
||||||
|
(pass_unshare_all_rtl): Remove.
|
||||||
|
* integrate.c (pass_initial_value_sets): Remove.
|
||||||
|
* emit-rtl.c (pass_unshare_all_rtl): Remove.
|
||||||
|
* tree.h (init_function_for_compilation): Remove.
|
||||||
|
* function.c (init_function_for_compilation): Remove.
|
||||||
|
(pass_init_function): Remove.
|
||||||
|
* cfgcleanup.c (rest_of_handle_jump): Remove.
|
||||||
|
(pass_jump): Remove.
|
||||||
|
|
||||||
2012-03-20 Jason Merrill <jason@redhat.com>
|
2012-03-20 Jason Merrill <jason@redhat.com>
|
||||||
|
|
||||||
* tree-streamer-in.c (streamer_alloc_tree): Call
|
* tree-streamer-in.c (streamer_alloc_tree): Call
|
||||||
|
|
|
@ -3147,8 +3147,9 @@ cfgexpand.o : cfgexpand.c $(TREE_FLOW_H) $(CONFIG_H) $(SYSTEM_H) \
|
||||||
$(RTL_H) $(TREE_H) $(TM_P_H) $(EXPR_H) $(FUNCTION_H) $(TIMEVAR_H) $(TM_H) \
|
$(RTL_H) $(TREE_H) $(TM_P_H) $(EXPR_H) $(FUNCTION_H) $(TIMEVAR_H) $(TM_H) \
|
||||||
coretypes.h $(TREE_DUMP_H) $(EXCEPT_H) langhooks.h $(TREE_PASS_H) $(RTL_H) \
|
coretypes.h $(TREE_DUMP_H) $(EXCEPT_H) langhooks.h $(TREE_PASS_H) $(RTL_H) \
|
||||||
$(DIAGNOSTIC_H) toplev.h $(DIAGNOSTIC_CORE_H) $(BASIC_BLOCK_H) $(FLAGS_H) debug.h $(PARAMS_H) \
|
$(DIAGNOSTIC_H) toplev.h $(DIAGNOSTIC_CORE_H) $(BASIC_BLOCK_H) $(FLAGS_H) debug.h $(PARAMS_H) \
|
||||||
value-prof.h $(TREE_INLINE_H) $(TARGET_H) $(SSAEXPAND_H) \
|
value-prof.h $(TREE_INLINE_H) $(TARGET_H) $(SSAEXPAND_H) $(REGS_H) \
|
||||||
tree-pretty-print.h gimple-pretty-print.h $(BITMAP_H) sbitmap.h $(INSN_ATTR_H)
|
tree-pretty-print.h gimple-pretty-print.h $(BITMAP_H) sbitmap.h \
|
||||||
|
$(INSN_ATTR_H) $(INTEGRATE_H)
|
||||||
cfgrtl.o : cfgrtl.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(RTL_ERROR_H) \
|
cfgrtl.o : cfgrtl.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(RTL_ERROR_H) \
|
||||||
$(FLAGS_H) insn-config.h $(BASIC_BLOCK_H) $(REGS_H) hard-reg-set.h \
|
$(FLAGS_H) insn-config.h $(BASIC_BLOCK_H) $(REGS_H) hard-reg-set.h \
|
||||||
output.h $(FUNCTION_H) $(EXCEPT_H) $(TM_P_H) $(INSN_ATTR_H) \
|
output.h $(FUNCTION_H) $(EXCEPT_H) $(TM_P_H) $(INSN_ATTR_H) \
|
||||||
|
|
|
@ -2981,34 +2981,6 @@ cleanup_cfg (int mode)
|
||||||
return changed;
|
return changed;
|
||||||
}
|
}
|
||||||
|
|
||||||
static unsigned int
|
|
||||||
rest_of_handle_jump (void)
|
|
||||||
{
|
|
||||||
if (crtl->tail_call_emit)
|
|
||||||
fixup_tail_calls ();
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
struct rtl_opt_pass pass_jump =
|
|
||||||
{
|
|
||||||
{
|
|
||||||
RTL_PASS,
|
|
||||||
"sibling", /* name */
|
|
||||||
NULL, /* gate */
|
|
||||||
rest_of_handle_jump, /* execute */
|
|
||||||
NULL, /* sub */
|
|
||||||
NULL, /* next */
|
|
||||||
0, /* static_pass_number */
|
|
||||||
TV_JUMP, /* tv_id */
|
|
||||||
0, /* properties_required */
|
|
||||||
0, /* properties_provided */
|
|
||||||
0, /* properties_destroyed */
|
|
||||||
TODO_ggc_collect, /* todo_flags_start */
|
|
||||||
TODO_verify_flow, /* todo_flags_finish */
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
static unsigned int
|
static unsigned int
|
||||||
rest_of_handle_jump2 (void)
|
rest_of_handle_jump2 (void)
|
||||||
{
|
{
|
||||||
|
|
|
@ -47,6 +47,8 @@ along with GCC; see the file COPYING3. If not see
|
||||||
#include "ssaexpand.h"
|
#include "ssaexpand.h"
|
||||||
#include "bitmap.h"
|
#include "bitmap.h"
|
||||||
#include "sbitmap.h"
|
#include "sbitmap.h"
|
||||||
|
#include "regs.h" /* For reg_renumber. */
|
||||||
|
#include "integrate.h" /* For emit_initial_value_sets. */
|
||||||
#include "insn-attr.h" /* For INSN_SCHEDULING. */
|
#include "insn-attr.h" /* For INSN_SCHEDULING. */
|
||||||
|
|
||||||
/* This variable holds information helping the rewriting of SSA trees
|
/* This variable holds information helping the rewriting of SSA trees
|
||||||
|
@ -4373,6 +4375,10 @@ gimple_expand_cfg (void)
|
||||||
SA.partition_to_pseudo = (rtx *)xcalloc (SA.map->num_partitions,
|
SA.partition_to_pseudo = (rtx *)xcalloc (SA.map->num_partitions,
|
||||||
sizeof (rtx));
|
sizeof (rtx));
|
||||||
|
|
||||||
|
/* Make sure all values used by the optimization passes have sane
|
||||||
|
defaults. */
|
||||||
|
reg_renumber = 0;
|
||||||
|
|
||||||
/* Some backends want to know that we are expanding to RTL. */
|
/* Some backends want to know that we are expanding to RTL. */
|
||||||
currently_expanding_to_rtl = 1;
|
currently_expanding_to_rtl = 1;
|
||||||
/* Dominators are not kept up-to-date as we may create new basic-blocks. */
|
/* Dominators are not kept up-to-date as we may create new basic-blocks. */
|
||||||
|
@ -4625,6 +4631,11 @@ gimple_expand_cfg (void)
|
||||||
|
|
||||||
expand_stack_alignment ();
|
expand_stack_alignment ();
|
||||||
|
|
||||||
|
/* Fixup REG_EQUIV notes in the prologue if there are tailcalls in this
|
||||||
|
function. */
|
||||||
|
if (crtl->tail_call_emit)
|
||||||
|
fixup_tail_calls ();
|
||||||
|
|
||||||
/* After initial rtl generation, call back to finish generating
|
/* After initial rtl generation, call back to finish generating
|
||||||
exception support code. We need to do this before cleaning up
|
exception support code. We need to do this before cleaning up
|
||||||
the CFG as the code does not expect dead landing pads. */
|
the CFG as the code does not expect dead landing pads. */
|
||||||
|
@ -4643,6 +4654,12 @@ gimple_expand_cfg (void)
|
||||||
verify_flow_info ();
|
verify_flow_info ();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/* Initialize pseudos allocated for hard registers. */
|
||||||
|
emit_initial_value_sets ();
|
||||||
|
|
||||||
|
/* And finally unshare all RTL. */
|
||||||
|
unshare_all_rtl ();
|
||||||
|
|
||||||
/* There's no need to defer outputting this function any more; we
|
/* There's no need to defer outputting this function any more; we
|
||||||
know we want to output it. */
|
know we want to output it. */
|
||||||
DECL_DEFER_OUTPUT (current_function_decl) = 0;
|
DECL_DEFER_OUTPUT (current_function_decl) = 0;
|
||||||
|
@ -4692,7 +4709,9 @@ gimple_expand_cfg (void)
|
||||||
the common parent easily. */
|
the common parent easily. */
|
||||||
set_block_levels (DECL_INITIAL (cfun->decl), 0);
|
set_block_levels (DECL_INITIAL (cfun->decl), 0);
|
||||||
default_rtl_profile ();
|
default_rtl_profile ();
|
||||||
|
|
||||||
timevar_pop (TV_POST_EXPAND);
|
timevar_pop (TV_POST_EXPAND);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -2475,25 +2475,6 @@ unshare_all_rtl (void)
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
struct rtl_opt_pass pass_unshare_all_rtl =
|
|
||||||
{
|
|
||||||
{
|
|
||||||
RTL_PASS,
|
|
||||||
"unshare", /* name */
|
|
||||||
NULL, /* gate */
|
|
||||||
unshare_all_rtl, /* execute */
|
|
||||||
NULL, /* sub */
|
|
||||||
NULL, /* next */
|
|
||||||
0, /* static_pass_number */
|
|
||||||
TV_NONE, /* tv_id */
|
|
||||||
0, /* properties_required */
|
|
||||||
0, /* properties_provided */
|
|
||||||
0, /* properties_destroyed */
|
|
||||||
0, /* todo_flags_start */
|
|
||||||
TODO_verify_rtl_sharing /* todo_flags_finish */
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
/* Check that ORIG is not marked when it should not be and mark ORIG as in use,
|
/* Check that ORIG is not marked when it should not be and mark ORIG as in use,
|
||||||
Recursively does the same for subexpressions. */
|
Recursively does the same for subexpressions. */
|
||||||
|
|
|
@ -4558,33 +4558,6 @@ init_function_start (tree subr)
|
||||||
warning (OPT_Waggregate_return, "function returns an aggregate");
|
warning (OPT_Waggregate_return, "function returns an aggregate");
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Make sure all values used by the optimization passes have sane defaults. */
|
|
||||||
unsigned int
|
|
||||||
init_function_for_compilation (void)
|
|
||||||
{
|
|
||||||
reg_renumber = 0;
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
struct rtl_opt_pass pass_init_function =
|
|
||||||
{
|
|
||||||
{
|
|
||||||
RTL_PASS,
|
|
||||||
"*init_function", /* name */
|
|
||||||
NULL, /* gate */
|
|
||||||
init_function_for_compilation, /* execute */
|
|
||||||
NULL, /* sub */
|
|
||||||
NULL, /* next */
|
|
||||||
0, /* static_pass_number */
|
|
||||||
TV_NONE, /* tv_id */
|
|
||||||
0, /* properties_required */
|
|
||||||
0, /* properties_provided */
|
|
||||||
0, /* properties_destroyed */
|
|
||||||
0, /* todo_flags_start */
|
|
||||||
0 /* todo_flags_finish */
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
expand_main_function (void)
|
expand_main_function (void)
|
||||||
|
|
|
@ -310,25 +310,6 @@ emit_initial_value_sets (void)
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
struct rtl_opt_pass pass_initial_value_sets =
|
|
||||||
{
|
|
||||||
{
|
|
||||||
RTL_PASS,
|
|
||||||
"initvals", /* name */
|
|
||||||
NULL, /* gate */
|
|
||||||
emit_initial_value_sets, /* execute */
|
|
||||||
NULL, /* sub */
|
|
||||||
NULL, /* next */
|
|
||||||
0, /* static_pass_number */
|
|
||||||
TV_NONE, /* tv_id */
|
|
||||||
0, /* properties_required */
|
|
||||||
0, /* properties_provided */
|
|
||||||
0, /* properties_destroyed */
|
|
||||||
0, /* todo_flags_start */
|
|
||||||
0 /* todo_flags_finish */
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
/* If the backend knows where to allocate pseudos for hard
|
/* If the backend knows where to allocate pseudos for hard
|
||||||
register initial values, register these allocations now. */
|
register initial values, register these allocations now. */
|
||||||
void
|
void
|
||||||
|
|
|
@ -1429,10 +1429,6 @@ init_optimization_passes (void)
|
||||||
NEXT_PASS (pass_rest_of_compilation);
|
NEXT_PASS (pass_rest_of_compilation);
|
||||||
{
|
{
|
||||||
struct opt_pass **p = &pass_rest_of_compilation.pass.sub;
|
struct opt_pass **p = &pass_rest_of_compilation.pass.sub;
|
||||||
NEXT_PASS (pass_init_function);
|
|
||||||
NEXT_PASS (pass_jump);
|
|
||||||
NEXT_PASS (pass_initial_value_sets);
|
|
||||||
NEXT_PASS (pass_unshare_all_rtl);
|
|
||||||
NEXT_PASS (pass_instantiate_virtual_regs);
|
NEXT_PASS (pass_instantiate_virtual_regs);
|
||||||
NEXT_PASS (pass_into_cfg_layout_mode);
|
NEXT_PASS (pass_into_cfg_layout_mode);
|
||||||
NEXT_PASS (pass_jump2);
|
NEXT_PASS (pass_jump2);
|
||||||
|
|
|
@ -485,10 +485,6 @@ extern struct gimple_opt_pass pass_init_datastructures;
|
||||||
extern struct gimple_opt_pass pass_fixup_cfg;
|
extern struct gimple_opt_pass pass_fixup_cfg;
|
||||||
|
|
||||||
extern struct rtl_opt_pass pass_expand;
|
extern struct rtl_opt_pass pass_expand;
|
||||||
extern struct rtl_opt_pass pass_init_function;
|
|
||||||
extern struct rtl_opt_pass pass_jump;
|
|
||||||
extern struct rtl_opt_pass pass_initial_value_sets;
|
|
||||||
extern struct rtl_opt_pass pass_unshare_all_rtl;
|
|
||||||
extern struct rtl_opt_pass pass_instantiate_virtual_regs;
|
extern struct rtl_opt_pass pass_instantiate_virtual_regs;
|
||||||
extern struct rtl_opt_pass pass_rtl_fwprop;
|
extern struct rtl_opt_pass pass_rtl_fwprop;
|
||||||
extern struct rtl_opt_pass pass_rtl_fwprop_addr;
|
extern struct rtl_opt_pass pass_rtl_fwprop_addr;
|
||||||
|
|
Loading…
Reference in New Issue