diff options
author | jamborm <jamborm@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-09-20 16:35:40 +0000 |
---|---|---|
committer | jamborm <jamborm@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-09-20 16:35:40 +0000 |
commit | 9078126c66389d40d28da2ada75f205978652847 (patch) | |
tree | bd0847507cf2cc8fc2505732d6abf2f60dd73989 /gcc/passes.c | |
parent | 0c2533785f9f4969f067e36a865a55ca7a6fa828 (diff) | |
download | gcc-9078126c66389d40d28da2ada75f205978652847.tar.gz |
2012-09-20 Martin Jambor <mjambor@suse.cz>
* function.c (push_cfun): Check old current_function_decl matches
old cfun, set new current_function_decl to the decl of the new
cfun.
(push_struct_function): Likewise.
(pop_cfun): Likewise.
(allocate_struct_function): Move call to
invoke_set_current_function_hook to the end of the function.
* cfgexpand.c (estimated_stack_frame_size): Do not set and restore
current_function_decl.
* cgraph.c (cgraph_release_function_body): Likewise.
* cgraphunit.c (cgraph_process_new_functions): Likewise.
(cgraph_add_new_function): Likewise.
(cgraph_analyze_function): Likewise.
(assemble_thunk): Set cfun to NULL at the end.
(expand_function): Move call to set_cfun downwards.
* gimple-low.c (record_vars_into): Only check current_function_decl
before possibly doing push_cfun.
* gimplify.c (gimplify_function_tree): Do not set and restore
current_function_decl.
* ipa-inline-analysis.c (compute_inline_parameters): Likewise.
(inline_analyze_function): Likewise.
* ipa-prop.c (ipa_analyze_node): Likewise.
* ipa-pure-const.c (analyze_function): Likewise.
* lto-streamer-in.c (lto_input_function_body): Do not set
current_function_decl.
* lto-streamer-out.c (output_function): Do not set and restore
current_function_decl.
* omp-low.c (finalize_task_copyfn): Likewise.
(expand_omp_taskreg): Likewise.
(create_task_copyfn): Likewise, move push_cfun up quite a bit.
* passes.c (dump_passes): Do not set and restore current_function_decl.
(do_per_function): Likewise.
(do_per_function_toporder): Likewise.
* trans-mem.c (ipa_tm_scan_irr_function): Likewise.
(ipa_tm_transform_transaction): Likewise.
(ipa_tm_transform_clone): Likewise.
(ipa_tm_execute): Likewise.
* tree-emutls.c (lower_emutls_function_body): Likewise.
* tree-inline.c (initialize_cfun): Do not call pop_cfun.
(tree_function_versioning): Do not call push_cfun, do not set and
restore current_function_decl. Remove assert checking consistency of
cfun and current_function_decl.
* tree-profile.c (tree_profiling): Do not set and restore
current_function_decl.
* tree-sra.c (convert_callers_for_node): Do not set
current_function_decl.
(convert_callers): Do not restore current_function_decl.
(modify_function): Do not set current_function_decl.
* tree-ssa-structalias.c (ipa_pta_execute): Do not set and restore
current_function_decl.
fortran/
* trans-decl.c (gfc_get_extern_function_decl): Push NULL cfun. Do not
set and restore current_function_decl.
(gfc_init_coarray_decl): Do not set and restore current_function_decl.
lto/
* lto.c (lto_materialize_function): Call push_struct_function and
pop_cfun.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@191577 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/passes.c')
-rw-r--r-- | gcc/passes.c | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/gcc/passes.c b/gcc/passes.c index 97a1d0ec7fd..ba4e98e0682 100644 --- a/gcc/passes.c +++ b/gcc/passes.c @@ -703,7 +703,6 @@ void dump_passes (void) { struct cgraph_node *n, *node = NULL; - tree save_fndecl = current_function_decl; create_pass_tab(); @@ -718,7 +717,6 @@ dump_passes (void) return; push_cfun (DECL_STRUCT_FUNCTION (node->symbol.decl)); - current_function_decl = node->symbol.decl; dump_pass_list (all_lowering_passes, 1); dump_pass_list (all_small_ipa_passes, 1); @@ -728,7 +726,6 @@ dump_passes (void) dump_pass_list (all_passes, 1); pop_cfun (); - current_function_decl = save_fndecl; } @@ -1701,14 +1698,12 @@ do_per_function (void (*callback) (void *data), void *data) && (!node->clone_of || node->symbol.decl != node->clone_of->symbol.decl)) { push_cfun (DECL_STRUCT_FUNCTION (node->symbol.decl)); - current_function_decl = node->symbol.decl; callback (data); if (!flag_wpa) { free_dominance_info (CDI_DOMINATORS); free_dominance_info (CDI_POST_DOMINATORS); } - current_function_decl = NULL; pop_cfun (); ggc_collect (); } @@ -1749,11 +1744,9 @@ do_per_function_toporder (void (*callback) (void *data), void *data) if (cgraph_function_with_gimple_body_p (node)) { push_cfun (DECL_STRUCT_FUNCTION (node->symbol.decl)); - current_function_decl = node->symbol.decl; callback (data); free_dominance_info (CDI_DOMINATORS); free_dominance_info (CDI_POST_DOMINATORS); - current_function_decl = NULL; pop_cfun (); ggc_collect (); } |