This is the mail archive of the binutils@sources.redhat.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]
Other format: [Raw text]

Re: RFC: Fix ia64 visibility


On Wed, May 07, 2003 at 03:30:34PM -0700, Richard Henderson wrote:
> On Wed, May 07, 2003 at 11:19:46AM -0700, H. J. Lu wrote:
> 
> > dynamic_symbol_p only checks STV_INTERNAL and STV_HIDDEN. For certain
> > relocation types, there is no need for dynamic symbol lookup even for
> > STV_PROTECTED. I can use ELF_ST_VISIBILITY (h->other) != STV_PROTECTED.
> > But I thought ELF_ST_VISIBILITY (h->other) == STV_DEFAULT might help
> > compiler a little bit. Maybe I should put a comment there.
> 
> I'd rather we not sprinkle STV_PROTECTED checks (or anything else)
> all over the place.  Is it actually incorrect to modify dynamic_symbol_p
> to check STV_PROTECTED?  If so, we should have a different predicate
> function that tests exactly what we want and use that.

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. But we can't do it for function
descriptors of protected functions. That check is based on relocation
type, not just symbol alone. 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. I can submit a new patch if it is preferred.


H.J.


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