diff options
author | nemet <nemet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2009-03-29 00:08:07 +0000 |
---|---|---|
committer | nemet <nemet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2009-03-29 00:08:07 +0000 |
commit | 69428266fb156da2ba81f084fdd770bdbbc57234 (patch) | |
tree | 27ae0d6521d000b4e4f8f144d612fdc7b84ad348 /gcc/cgraphbuild.c | |
parent | d093f898a46b0ff8221b31c1149d85180fc654f8 (diff) | |
download | gcc-69428266fb156da2ba81f084fdd770bdbbc57234.tar.gz |
* cgraphbuild.c (build_cgraph_edges, rebuild_cgraph_edges): Don't
call initialize_inline_failed.
(initialize_inline_failed): Move it from here ...
* cgraph.c (initialize_inline_failed): ... to here.
(cgraph_create_edge): Call initialize_inline_failed rather than
setting inline_failed directly.
testsuite/
* gcc.dg/winline-10.c: New test.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@145215 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cgraphbuild.c')
-rw-r--r-- | gcc/cgraphbuild.c | 27 |
1 files changed, 1 insertions, 26 deletions
diff --git a/gcc/cgraphbuild.c b/gcc/cgraphbuild.c index f9bc6201afb..3868712b3f7 100644 --- a/gcc/cgraphbuild.c +++ b/gcc/cgraphbuild.c @@ -78,30 +78,6 @@ record_reference (tree *tp, int *walk_subtrees, void *data ATTRIBUTE_UNUSED) return NULL_TREE; } -/* Give initial reasons why inlining would fail on all calls from - NODE. Those get either nullified or usually overwritten by more precise - reason later. */ - -static void -initialize_inline_failed (struct cgraph_node *node) -{ - struct cgraph_edge *e; - - for (e = node->callers; e; e = e->next_caller) - { - gcc_assert (!e->callee->global.inlined_to); - gcc_assert (e->inline_failed); - if (node->local.redefined_extern_inline) - e->inline_failed = CIF_REDEFINED_EXTERN_INLINE; - else if (!node->local.inlinable) - e->inline_failed = CIF_FUNCTION_NOT_INLINABLE; - else if (gimple_call_cannot_inline_p (e->call_stmt)) - e->inline_failed = CIF_MISMATCHED_ARGUMENTS; - else - e->inline_failed = CIF_FUNCTION_NOT_CONSIDERED; - } -} - /* Computes the frequency of the call statement so that it can be stored in cgraph_edge. BB is the basic block of the call statement. */ int @@ -193,7 +169,6 @@ build_cgraph_edges (void) } pointer_set_destroy (visited_nodes); - initialize_inline_failed (node); return 0; } @@ -253,8 +228,8 @@ rebuild_cgraph_edges (void) bb->loop_depth); } - initialize_inline_failed (node); gcc_assert (!node->global.inlined_to); + return 0; } |