This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC 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: PATCH - rs6000.c, RS6000_MCOUNT and SVR4 pic


On Thu, Feb 26, 2004 at 03:16:44PM -0500, David Edelsohn wrote:
> 	I'm still investigating why the patch is necessary.

It's only necessary to work around a bug in older binutils, as the
need for @plt disappeared some time ago (My 2003-02-18 bfd/elf32-ppc.c
change, I think).

Even if we didn't care about old binutils, I reckon the patch is worth
applying just to make the _mcount call consistent with other pic calls.

I also checked that everything is reasonable for _mcount to live in a
shared lib.  r0 is used to pass the count loc to _mcount, and r0 isn't
trashed by any of the plt call sequences.  Even the lazy link stub saves
r0 (with a comment saying that the save is for _mcount).

-- 
Alan Modra
IBM OzLabs - Linux Technology Centre


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