This is the mail archive of the libc-alpha@sources.redhat.com mailing list for the glibc 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: new ppc32 GOT/PLT support for mcount


On Thu, Jun 09, 2005 at 05:31:56PM -0500, Steve Munroe wrote:
> One possibility is to move a version of the ppc-mcount.S stub code into 
> libc_nonshared and have it establish the got (using the new ABI) before 
> calling __mcount_internal via the new PLT.
> 
> For compatibility we need to version _mcount. The old version in 
> ppc-mcount.S will be export _mcount@GLIBC_2.0. The new version 
> (ppc2-mcount.S) will export the default version _mcount@@GLIBC_2.4. The 
> new version will included in libc_nonshared.a so it can be called @local 
> from -pg prologues. The implementation of __mcount_internal 
> (gmon/mcount.c) will remain unchanged except for 
> making__mcount_internal@@GLIBC_PRIVATE.

This looks wrong, for multiple reasons:
1) if the arguments to _mcount are different between -mno-secure-plt
   and -msecure-plt, then -msecure-plt _mcount shouldn't be called _mcount,
   but something else.  Otherwise you preclude building -mno-secure-plt
   profiled stuff on glibc's with your patch
2) symbols that are in libc_nonshared.a are not versioned
3) if libc_nonshared.a uses some symbol from libc.so (as in this case
   __mcount_internal), that symbol must not be GLIBC_PRIVATE.  As
   libc_nonshared.a is linked into user programs/libraries, any interface
   between libc_nonshared.a and libc.so is necessarily public.

	Jakub


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