From: Steven Bosscher Date: Tue, 8 Jul 2003 19:44:17 +0000 (+0000) Subject: re PR c/1687 (Exponential time behavior with -O -finline-functions (compile time... X-Git-Tag: releases/gcc-3.4.0~5042 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=516574425b935981dcdae07ff0e3be6b5946bf04;p=thirdparty%2Fgcc.git re PR c/1687 (Exponential time behavior with -O -finline-functions (compile time regression from 3.2, 3.3)) 2003-07-08 Steven Bosscher PR c/1687 * tree-inline.c (find_alloca_call): Use walk_tree_without_duplicates, instead of walk_tree. (find_builtin_longjmp_call): Likewise. * c-objc-common.c (c_cannot_inline_fn): Likewise. * c-semantics.c (find_reachable_label): Likewise. From-SVN: r69097 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 6e83cd094cc9..886b3b4a6b7e 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,12 @@ +2003-07-08 Steven Bosscher + + PR c/1687 + * tree-inline.c (find_alloca_call): Use + walk_tree_without_duplicates, instead of walk_tree. + (find_builtin_longjmp_call): Likewise. + * c-objc-common.c (c_cannot_inline_fn): Likewise. + * c-semantics.c (find_reachable_label): Likewise. + 2003-07-08 Jakub Jelinek PR c/11420 diff --git a/gcc/c-objc-common.c b/gcc/c-objc-common.c index 438b3fba808f..e0a99a3ae876 100644 --- a/gcc/c-objc-common.c +++ b/gcc/c-objc-common.c @@ -211,7 +211,8 @@ c_cannot_inline_tree_fn (tree *fnp) return 0; } - if (walk_tree (&DECL_SAVED_TREE (fn), inline_forbidden_p, fn, NULL)) + if (walk_tree_without_duplicates (&DECL_SAVED_TREE (fn), + inline_forbidden_p, fn)) goto cannot_inline; return 0; diff --git a/gcc/c-semantics.c b/gcc/c-semantics.c index 1481e1db7062..9ecfc96faa28 100644 --- a/gcc/c-semantics.c +++ b/gcc/c-semantics.c @@ -924,7 +924,8 @@ static tree find_reachable_label (tree exp) { location_t saved_loc = input_location; - tree ret = walk_tree (&exp, find_reachable_label_1, NULL, NULL); + tree ret = walk_tree_without_duplicates + (&exp, find_reachable_label_1, NULL); input_location = saved_loc; return ret; } diff --git a/gcc/tree-inline.c b/gcc/tree-inline.c index 0d4d7a410985..c41ccea5e832 100644 --- a/gcc/tree-inline.c +++ b/gcc/tree-inline.c @@ -898,7 +898,8 @@ static tree find_alloca_call (tree exp) { location_t saved_loc = input_location; - tree ret = walk_tree (&exp, find_alloca_call_1, NULL, NULL); + tree ret = walk_tree_without_duplicates + (&exp, find_alloca_call_1, NULL); input_location = saved_loc; return ret; } @@ -924,7 +925,8 @@ static tree find_builtin_longjmp_call (tree exp) { location_t saved_loc = input_location; - tree ret = walk_tree (&exp, find_builtin_longjmp_call_1, NULL, NULL); + tree ret = walk_tree_without_duplicates + (&exp, find_builtin_longjmp_call_1, NULL); input_location = saved_loc; return ret; }