From: Richard Henderson Date: Wed, 11 Aug 2004 03:56:58 +0000 (-0700) Subject: * tree-tailcall.c (suitable_for_tail_opt_p): Also check DECL_EXTERNAL. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=7109c195f0703e6fa8c44a774cfcaadacf4fe751;p=gcc.git * tree-tailcall.c (suitable_for_tail_opt_p): Also check DECL_EXTERNAL. From-SVN: r85791 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 1022abd673e..0c7b2e7f934 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,7 @@ +2004-08-10 Richard Henderson + + * tree-tailcall.c (suitable_for_tail_opt_p): Also check DECL_EXTERNAL. + 2004-08-09 Mark Mitchell * config.gcc (arm*-*-eabi*): New target. diff --git a/gcc/tree-tailcall.c b/gcc/tree-tailcall.c index 6e1957c597d..401a3991468 100644 --- a/gcc/tree-tailcall.c +++ b/gcc/tree-tailcall.c @@ -143,7 +143,7 @@ suitable_for_tail_opt_p (void) { tree var = VARRAY_TREE (referenced_vars, i); - if (!TREE_STATIC (var) + if (!(TREE_STATIC (var) || DECL_EXTERNAL (var)) && var_ann (var)->mem_tag_kind == NOT_A_TAG && is_call_clobbered (var)) return false;