diff options
author | Jan Hubicka <jh@suse.cz> | 2004-09-20 22:38:29 +0200 |
---|---|---|
committer | Jan Hubicka <hubicka@gcc.gnu.org> | 2004-09-20 20:38:29 +0000 |
commit | 8f2353433c31121e5ec31f24d70b80c385fb28ff (patch) | |
tree | 25c6e4482c10189121acfa2bf0f54130a9876b63 /gcc/cgraph.c | |
parent | 04161e2bde5dee7dbe9c7863f3cb6f262c8d059c (diff) | |
download | gcc-8f2353433c31121e5ec31f24d70b80c385fb28ff.zip gcc-8f2353433c31121e5ec31f24d70b80c385fb28ff.tar.gz gcc-8f2353433c31121e5ec31f24d70b80c385fb28ff.tar.bz2 |
re PR middle-end/16460 (ICE when compiling glibc (ld-ctype.c))
PR middle-end/16460
* cgraph.c (cgraph_unnest_node): New function.
(c_finalize): Rename to ....
(c_warn_unused_result_recursivly): ... this one; do only the warning
(finish_function): Finalize the toplevel function; do not lower nested tree.
* cgraph.h (cgraph_unnest_node): Declare.
* cgraphunit.c (decide_is_function_needed): Do not use cgraph
nestedness datastructure.
* cse.c (cse_insn): Do not cprop nonlocal LABEL_REFs.
* reload1.c (set_label_offsets): Fix call of set_label_offsets.
* tree-nested.c (finlize_nesting_tree_1): Use un-nesting code.
* utils.c (gnat_finalize): Remove.
(end_subprog_body): Directly call cgraph_finalize_function;
do not lower the nested functions.
* trans-decl.c (build_entry_thunks): Finalize the function; do not lower
tree.
(gfc_generate_function_code): Likewise.
From-SVN: r87770
Diffstat (limited to 'gcc/cgraph.c')
-rw-r--r-- | gcc/cgraph.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/gcc/cgraph.c b/gcc/cgraph.c index f8f0b7c..7206251 100644 --- a/gcc/cgraph.c +++ b/gcc/cgraph.c @@ -693,4 +693,17 @@ cgraph_clone_node (struct cgraph_node *n) return new; } + +/* NODE is no longer nested function; update cgraph accordingly. */ +void +cgraph_unnest_node (struct cgraph_node *node) +{ + struct cgraph_node **node2 = &node->origin->nested; + gcc_assert (node->origin); + + while (*node2 != node) + node2 = &(*node2)->next_nested; + *node2 = node->next_nested; + node->origin = NULL; +} #include "gt-cgraph.h" |