From: Richard Sandiford Date: Tue, 16 Dec 2003 08:15:33 +0000 (+0000) Subject: mips.c (mips_file_end): Only write symbols that have been referenced at some point. X-Git-Tag: releases/gcc-3.4.0~1669 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=a689d4e0ea6a94acd0cb585462f7f57f7c05be7c;p=thirdparty%2Fgcc.git mips.c (mips_file_end): Only write symbols that have been referenced at some point. * config/mips/mips.c (mips_file_end): Only write symbols that have been referenced at some point. From-SVN: r74681 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 18f19168ddd3..c7cd477349d3 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2003-12-16 Richard Sandiford + + * config/mips/mips.c (mips_file_end): Only write symbols that have + been referenced at some point. + 2003-12-16 Richard Sandiford * config/mips/mips.c: Include langhooks.h diff --git a/gcc/config/mips/mips.c b/gcc/config/mips/mips.c index e0a01ce814f3..c748bac73af3 100644 --- a/gcc/config/mips/mips.c +++ b/gcc/config/mips/mips.c @@ -5846,7 +5846,8 @@ mips_file_end (void) name_tree = get_identifier (p->name); /* Positively ensure only one .extern for any given symbol. */ - if (! TREE_ASM_WRITTEN (name_tree)) + if (!TREE_ASM_WRITTEN (name_tree) + && TREE_SYMBOL_REFERENCED (name_tree)) { TREE_ASM_WRITTEN (name_tree) = 1; /* In IRIX 5 or IRIX 6 for the O32 ABI, we must output a