This is the mail archive of the binutils@sourceware.cygnus.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Another patch for visibility.


On Wed, May 31, 2000 at 10:16:20AM +0900, NIIBE Yutaka wrote:
> Hi H.J., 
> 
> H . J . Lu wrote:
>  > One more thing, we should add more tests to ld/testsuite/ld-elfvsb. I
>  > will try when I find time. Any contributions are more than welcome.
> 
> Currently, I'm working for supporting visibility bits with GCC, by the
> function/variable attribute.
> 
> I've sent initial patch to gcc-patches@gnu.gcc.org, and now trying to 
> implement:
> 
> 	__attribute__ ((visibility(internal)))
> 	__attribute__ ((visibility(hidden)))
> 	__attribute__ ((visibility(protected)))
> 
> Any comments are appriciated.

It is ok to have undefined symbols with internal/hidden/protected
attribute as long as they are weak. The linker will handle them.
Also if undefined symbols with internal/hidden/protecte attribute
are not weak, the linker will catch them also. Since you can always
use asm (), I don't know if gcc should even bother to check it. The
current linker should do the right thing now.


-- 
H.J. Lu (hjl@gnu.org)

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]