aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gcc/ChangeLog4
-rw-r--r--gcc/tree-inline.c5
2 files changed, 6 insertions, 3 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index b5f5bb8..6de454a 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,7 @@
+2003-01-30 Richard Henderson <rth@redhat.com>
+
+ * tree-inline.c (walk_tree): Streamline duplicate hash table lookup.
+
2003-01-30 Richard Earnshaw <rearnsha@arm.com>
* arm.c (arm_compute_initial_elimination_offset): If optimizing for
diff --git a/gcc/tree-inline.c b/gcc/tree-inline.c
index d2f1a0e..e4bdf12 100644
--- a/gcc/tree-inline.c
+++ b/gcc/tree-inline.c
@@ -1530,10 +1530,9 @@ walk_tree (tp, func, data, htab_)
/* Don't walk the same tree twice, if the user has requested
that we avoid doing so. */
- if (htab_find (htab, *tp))
- return NULL_TREE;
- /* If we haven't already seen this node, add it to the table. */
slot = htab_find_slot (htab, *tp, INSERT);
+ if (*slot)
+ return NULL_TREE;
*slot = *tp;
}