From 9c8305f8fcfdab61ed276d1c30e7832e87d9ac55 Mon Sep 17 00:00:00 2001 From: Jan Hubicka Date: Wed, 25 Apr 2012 18:31:42 +0200 Subject: cgraphunit.c: Update toplevel comment. * cgraphunit.c: Update toplevel comment. (tree_rest_of_compilation): Merge into cgraph_expand_function. (cgraph_analyze_function): Make static. (cgraph_decide_is_function_needed): Make static. (cgraph_add_new_function): Use expand_function instead of rest_of_compilation. (clone_of_p, verify_edge_count_and_frequency, cgraph_debug_gimple_stmt, verify_edge_corresponds_to_fndecl, verify_cgraph_node, verify_cgraph): Move to cgraph.c (cgraph_inline_p): Remove. (cgraph_preserve_function_body_p): Move to ipa-inline-transform. (init_cgraph): Add comment. * cgraphbuild.c (record_reference, mark_address, mark_load, mark_store): Do not call analyze_expr hook. * cgraph.c: Update toplevel comment. (clone_of_p, verify_edge_count_and_frequency, cgraph_debug_gimple_stmt, verify_edge_corresponds_to_fndecl, verify_cgraph_node, verify_cgraph): Move fere from cgraphunit.c (cgraph_mark_force_output_node): Move to cgraph.h * cgraph.h: Reorder so the comments match the function placement. (cgraph_analyze_function, cgraph_decide_is_function_needed): Remove. (cgraph_mark_force_output_node): Move here from cgraph.c * tree.c (free_lang_data): Do not clear analyze_expr hook. * ipa-inline-transform.c (preserve_function_body_p): New function. (inline_transform): Update. * langhooks.c (lhd_callgraph_analyze_expr): Remove. * langhooks.h (lang_hooks_for_callgraph): Remove. (lang_hooks): Remove callgraph. * tree-inline.c (expand_call_inline): Do not use cgraph_inline_p. * varpool.c: Remove out of date comment. * langhooks-def.h (lhd_callgraph_analyze_expr): Remove. (LANG_HOOKS_CALLGRAPH_ANALYZE_EXPR): Remove. From-SVN: r186832 --- gcc/cgraphbuild.c | 14 -------------- 1 file changed, 14 deletions(-) (limited to 'gcc/cgraphbuild.c') diff --git a/gcc/cgraphbuild.c b/gcc/cgraphbuild.c index 445a392..a847980 100644 --- a/gcc/cgraphbuild.c +++ b/gcc/cgraphbuild.c @@ -85,8 +85,6 @@ record_reference (tree *tp, int *walk_subtrees, void *data) if (TREE_CODE (decl) == VAR_DECL) { struct varpool_node *vnode = varpool_node (decl); - if (lang_hooks.callgraph.analyze_expr) - lang_hooks.callgraph.analyze_expr (&decl, walk_subtrees); ipa_record_reference ((symtab_node)ctx->varpool_node, (symtab_node)vnode, IPA_REF_ADDR, NULL); @@ -102,9 +100,6 @@ record_reference (tree *tp, int *walk_subtrees, void *data) *walk_subtrees = 0; break; } - - if ((unsigned int) TREE_CODE (t) >= LAST_AND_UNUSED_TREE_CODE) - return lang_hooks.callgraph.analyze_expr (tp, walk_subtrees); break; } @@ -239,10 +234,7 @@ mark_address (gimple stmt, tree addr, void *data) && (TREE_STATIC (addr) || DECL_EXTERNAL (addr))) { struct varpool_node *vnode = varpool_node (addr); - int walk_subtrees; - if (lang_hooks.callgraph.analyze_expr) - lang_hooks.callgraph.analyze_expr (&addr, &walk_subtrees); ipa_record_reference ((symtab_node)data, (symtab_node)vnode, IPA_REF_ADDR, stmt); @@ -271,10 +263,7 @@ mark_load (gimple stmt, tree t, void *data) && (TREE_STATIC (t) || DECL_EXTERNAL (t))) { struct varpool_node *vnode = varpool_node (t); - int walk_subtrees; - if (lang_hooks.callgraph.analyze_expr) - lang_hooks.callgraph.analyze_expr (&t, &walk_subtrees); ipa_record_reference ((symtab_node)data, (symtab_node)vnode, IPA_REF_LOAD, stmt); @@ -292,10 +281,7 @@ mark_store (gimple stmt, tree t, void *data) && (TREE_STATIC (t) || DECL_EXTERNAL (t))) { struct varpool_node *vnode = varpool_node (t); - int walk_subtrees; - if (lang_hooks.callgraph.analyze_expr) - lang_hooks.callgraph.analyze_expr (&t, &walk_subtrees); ipa_record_reference ((symtab_node)data, (symtab_node)vnode, IPA_REF_STORE, stmt); -- cgit v1.1