aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorJeff Sturm <jsturm@one-point.com>2003-09-02 19:03:49 +0000
committerJeff Sturm <jsturm@gcc.gnu.org>2003-09-02 19:03:49 +0000
commit643845684253c6054a3990dd166d2b255abaa6e0 (patch)
tree2472f67832dcdfd12fee368b70d333a8c853a7b3 /gcc
parent3660e02f0d9bedca08e7f562edf861027bb70950 (diff)
downloadgcc-643845684253c6054a3990dd166d2b255abaa6e0.zip
gcc-643845684253c6054a3990dd166d2b255abaa6e0.tar.gz
gcc-643845684253c6054a3990dd166d2b255abaa6e0.tar.bz2
cgraphunit.c (record_call_1): Use walk_tree_without_duplicates.
* cgraphunit.c (record_call_1): Use walk_tree_without_duplicates. (cgraph_optimize_function): Set current_function_decl to the fndecl we're integrating from. From-SVN: r71002
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/cgraphunit.c5
2 files changed, 9 insertions, 2 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 4a5dd3c..28e64ef 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+2003-09-02 Jeff Sturm <jsturm@one-point.com>
+
+ * cgraphunit.c (record_call_1): Use walk_tree_without_duplicates.
+ (cgraph_optimize_function): Set current_function_decl to the
+ fndecl we're integrating from.
+
2003-09-02 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* builtins.def: Break out _Complex math functions into their
diff --git a/gcc/cgraphunit.c b/gcc/cgraphunit.c
index 02a569f..8fe98fb 100644
--- a/gcc/cgraphunit.c
+++ b/gcc/cgraphunit.c
@@ -122,7 +122,8 @@ record_call_1 (tree *tp, int *walk_subtrees, void *data)
taken by something that is not a function call. So only
walk the function parameter list, skip the other subtrees. */
- walk_tree (&TREE_OPERAND (*tp, 1), record_call_1, data, NULL);
+ walk_tree_without_duplicates (&TREE_OPERAND (*tp, 1),
+ record_call_1, data);
*walk_subtrees = 0;
}
}
@@ -292,7 +293,7 @@ cgraph_optimize_function (struct cgraph_node *node)
timevar_push (TV_INTEGRATION);
/* optimize_inline_calls avoids inlining of current_function_decl. */
- current_function_decl = 0;
+ current_function_decl = decl;
if (flag_inline_trees)
optimize_inline_calls (decl);
if (node->nested)