From 8c3800373fa39db275e4bea68fa775a0defb3daf Mon Sep 17 00:00:00 2001 From: Jan Hubicka Date: Wed, 27 Oct 2010 00:32:47 +0200 Subject: * cgraphbuild.c (build_cgraph_edges): Use ipa-reference to represent OMP. From-SVN: r165989 --- gcc/ChangeLog | 4 ++++ gcc/cgraphbuild.c | 9 ++++++--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 15bb3fb..152c279 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,9 @@ 2010-10-26 Jan Hubicka + * cgraphbuild.c (build_cgraph_edges): Use ipa-reference to represent OMP. + +2010-10-26 Jan Hubicka + * ipa.c (process_references): Enqueue all referenced nodes; mark as reachable only non-external nodes. (cgraph_remove_unreachable_nodes): All referenced nodes should diff --git a/gcc/cgraphbuild.c b/gcc/cgraphbuild.c index 3bd42e3..3800f13 100644 --- a/gcc/cgraphbuild.c +++ b/gcc/cgraphbuild.c @@ -361,16 +361,19 @@ build_cgraph_edges (void) && gimple_omp_parallel_child_fn (stmt)) { tree fn = gimple_omp_parallel_child_fn (stmt); - cgraph_mark_needed_node (cgraph_node (fn)); + ipa_record_reference (node, NULL, cgraph_node (fn), + NULL, IPA_REF_ADDR, stmt); } if (gimple_code (stmt) == GIMPLE_OMP_TASK) { tree fn = gimple_omp_task_child_fn (stmt); if (fn) - cgraph_mark_needed_node (cgraph_node (fn)); + ipa_record_reference (node, NULL, cgraph_node (fn), + NULL, IPA_REF_ADDR, stmt); fn = gimple_omp_task_copy_fn (stmt); if (fn) - cgraph_mark_needed_node (cgraph_node (fn)); + ipa_record_reference (node, NULL, cgraph_node (fn), + NULL, IPA_REF_ADDR, stmt); } } for (gsi = gsi_start (phi_nodes (bb)); !gsi_end_p (gsi); gsi_next (&gsi)) -- cgit v1.1