From cb967da5243c3fb5e9134d10349b7268bfa672b9 Mon Sep 17 00:00:00 2001 From: Richard Sandiford Date: Thu, 25 Sep 2003 18:11:19 +0000 Subject: [PATCH] cgraph.h (cgraph_remove_edge): Declare. * cgraph.h (cgraph_remove_edge): Declare. * cgraph.c (cgraph_remove_edge): Make extern. * cgraphunit.c (cgraph_finalize_function): Call cgraph_remove_edge instead of cgraph_remove_call. From-SVN: r71784 --- gcc/ChangeLog | 7 +++++++ gcc/cgraph.c | 3 +-- gcc/cgraph.h | 1 + gcc/cgraphunit.c | 2 +- 4 files changed, 10 insertions(+), 3 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index d630c6e0c9f..aeb10ca7727 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2003-09-25 Richard Sandiford + + * cgraph.h (cgraph_remove_edge): Declare. + * cgraph.c (cgraph_remove_edge): Make extern. + * cgraphunit.c (cgraph_finalize_function): Call cgraph_remove_edge + instead of cgraph_remove_call. + 2003-09-25 Ulrich Weigand * objc/objc-act.c (gen_declaration_1): Fix printf format. diff --git a/gcc/cgraph.c b/gcc/cgraph.c index 43238e58ecd..8471a725154 100644 --- a/gcc/cgraph.c +++ b/gcc/cgraph.c @@ -68,7 +68,6 @@ static GTY(()) struct cgraph_varpool_node *cgraph_varpool_nodes; static struct cgraph_edge *create_edge (struct cgraph_node *, struct cgraph_node *); -static void cgraph_remove_edge (struct cgraph_node *, struct cgraph_node *); static hashval_t hash_node (const void *); static int eq_node (const void *, const void *); @@ -180,7 +179,7 @@ create_edge (struct cgraph_node *caller, struct cgraph_node *callee) /* Remove the edge from CALLER to CALLEE in the cgraph. */ -static void +void cgraph_remove_edge (struct cgraph_node *caller, struct cgraph_node *callee) { struct cgraph_edge **edge, **edge2; diff --git a/gcc/cgraph.h b/gcc/cgraph.h index eb747d57d37..9bdbfdc0cf7 100644 --- a/gcc/cgraph.h +++ b/gcc/cgraph.h @@ -150,6 +150,7 @@ extern GTY(()) struct cgraph_varpool_node *cgraph_varpool_nodes_queue; /* In cgraph.c */ void dump_cgraph (FILE *); +void cgraph_remove_edge (struct cgraph_node *, struct cgraph_node *); void cgraph_remove_call (tree, tree); void cgraph_remove_node (struct cgraph_node *); struct cgraph_edge *cgraph_record_call (tree, tree); diff --git a/gcc/cgraphunit.c b/gcc/cgraphunit.c index 4ed3f7013c9..ded2f1980e3 100644 --- a/gcc/cgraphunit.c +++ b/gcc/cgraphunit.c @@ -183,7 +183,7 @@ cgraph_finalize_function (tree decl, bool nested) memset (&node->rtl, 0, sizeof (node->rtl)); node->analyzed = false; while (node->callees) - cgraph_remove_call (node->decl, node->callees->callee->decl); + cgraph_remove_edge (node, node->callees->callee); /* We may need to re-queue the node for assembling in case we already proceeded it and ignored as not needed. */ -- 2.30.2