On Wed, May 07, 2003 at 04:17:15PM -0700, Richard Henderson wrote: > On Wed, May 07, 2003 at 04:15:08PM -0700, H. J. Lu wrote: > > It is an optimization for calling directly to protected functions. In > > that case, we don't need PLT nor function descriptors. It is the same > > as calling an internal function. > > Certainly. > > > But we can't do it for function > > descriptors of protected functions. That check is based on relocation > > type, not just symbol alone. > > Because ld.so is going to allocate it, correct? Yes. > > > Another way to do it is to pass reloction type to > > elfNN_ia64_dynamic_symbol_p so that it has enough info to do > > the right thing. > > Eh. I'd prefer a different function. It can do little else > besides checking the reloc plus calling elfNN_ia64_dynamic_symbol_p. > > > I can submit a new patch if it is preferred. I didn't create a new function since it isn't used anywhere else. Instead, I addded a new variable and set it based on the return value of elfNN_ia64_dynamic_symbol_p and symbol visibility. H.J.