[Bug target/19520] protected function pointer doesn't work right

amodra at bigpond dot net dot au gcc-bugzilla@gcc.gnu.org
Wed Feb 2 13:16:00 GMT 2005

------- Additional Comments From amodra at bigpond dot net dot au  2005-02-02 13:15 -------
Confirming that the bug is real.

I can't say I like HJ's solution though.  It seems to require that ld.so resolve
a protected symbol in a shared library to a symbol defined in the main app. 
That's weird.  In other cases you don't want ld.so to do that, for instance when
the main app defines a function with the same name as a protected library
function.  I think it might be difficult for ld.so to choose the right symbol,
especially for the general case of multiple levels of shared libraries.

Another problem is that making protected functions non-local prevents certain
optimizations, for example see alias.c:mark_constant_function.

           What    |Removed                     |Added
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|                            |1
   Last reconfirmed|0000-00-00 00:00:00         |2005-02-02 13:15:45
               date|                            |


More information about the Gcc-bugs mailing list