------- Additional Comments From ian at airs dot com  2005-01-21 06:35 -------
I think this bug report is reporting an actual bug.  At least when using ELF,
when the compiler takes the address of a protected function, it has to act as
though it is taking the address of an ordinary function, and rely on the dynamic
linker to do the right thing.  If the compiler takes the address of a protected
function without using the PLT, then as HJ says function symbols can not compare
equal, even though they should.  This is not something the linker can fix up. 
The dynamic linker, however, when setting up the PLT, should observe that the
symbol is protected, and call the local symbol even if the executable overrides 
it.

In other words, we should only treat protected function symbols as special when
we call them.  Otherwise they should be treated as ordinary symbols.

This only applies to ELF.  I don't know what should be done for other object
file formats, if there are any others which support protected symbols.

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19520

Reply via email to