------- Additional Comments From zack at codesourcery dot com 2005-03-24 18:46 ------- Subject: Re: [4.0/4.1 regression] shared SH libgcc is exporting too many symbols
"joern dot rennecke at st dot com" <[EMAIL PROTECTED]> writes: > Almost all the symbols in config/sh/lib1funcs.asm are problematic. > Moreover, adding a new function to lib1funcs.asm can inadvertantly > create a new exported symbol. It is much safer to make the symbols > by default not exported. You may want to consider use of LIB1FUNCS_ST instead of LIB1FUNCS, so that the symbols are not put into libgcc_s.so in the first place. > I'm currently working on merging most of the machine-dependent > patches from our sources into gcc 4.1 - that's a 400 KB patch - and > this will change most of the FUNC definitions in lib1funcs.asm to > HIDDEN_FUNC, and all the ALIAS defintions into HIDDEN_ALIAS, and > also change the way references to symbols in lib1funcs.asm are > generated, so that for some symbols GOT references are made rather > than PLT ones when compiling pic/PIC code. This sounds fine. I want to make sure that you understand the point of my patch to remove the local copy of libgcc-std.ver. From time to time new global symbols are added to libgcc2.c. Most of those are appropriately visible from libgcc_s.so; in some cases it can be essential that they are. If an architecture has a private copy of the version file, we have to remember to update it. I observed that people were forgetting to update SH's private copy, so I eliminated it. Note that the private copy that you had, did *not* exclude hundreds of lib1funcs.asm symbols. The only symbols not in it, that were in libgcc-std.ver, and were not due to people forgetting to update it, are the symbols currently listed in sh/libgcc-excl.ver. zw -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20617