+2009-05-15 Jan Hubicka <jh@suse.cz>
+
+ * cgraph.h (struct cgraph_node): Add finalized_by_frotnend flag.
+ * cgraphunit.c (cgraph_finalize_function): Set it.
+ (cgraph_expand_function): Use it.
+
2009-05-15 Sandra Loosemore <sandra@codesourcery.com>
* real.c (encode_ieee_half): Define.
unsigned process : 1;
/* Set for aliases once they got through assemble_alias. */
unsigned alias : 1;
+ /* Set for nodes that was constructed and finalized by frontend. */
+ unsigned finalized_by_frontend : 1;
/* In non-unit-at-a-time mode the function body of inline candidates is saved
into clone before compiling so the function in original form can be
notice_global_symbol (decl);
node->local.finalized = true;
node->lowered = DECL_STRUCT_FUNCTION (decl)->cfg != NULL;
+ node->finalized_by_frontend = true;
record_cdtor_fn (node->decl);
if (node->nested)
lower_nested_functions (decl);
gcc_assert (node->lowered);
/* Generate RTL for the body of DECL. */
- if (lang_hooks.callgraph.emit_associated_thunks)
+ if (lang_hooks.callgraph.emit_associated_thunks
+ && node->finalized_by_frontend)
lang_hooks.callgraph.emit_associated_thunks (decl);
tree_rest_of_compilation (decl);