Versioning mess proved!!!

Geoff Keating geoffk@cygnus.com
Sun Oct 1 15:51:00 GMT 2000


> Cc: Franz.Sirl-kernel@lauterbach.com, philb@gnu.org, howarth@fuse.net,
>         libc-alpha@sourceware.cygnus.com, aj@suse.de
> Reply-To: drepper@cygnus.com (Ulrich Drepper)
> From: Ulrich Drepper <drepper@redhat.com>
> Date: 01 Oct 2000 15:46:18 -0700
> User-Agent: Gnus/5.0807 (Gnus v5.8.7) XEmacs/21.1 (Capitol Reef)
> 
> Geoff Keating <geoffk@cygnus.com> writes:
> 
> > Nope.  The other two should have two relocations too.
> > 
> > I expect the code that calls __gmon_start__ looks like:
> > 
> > 	lwz r3,__gmon_start__@got(r31)
> > 	cmpwi r3,0
> > 	beq L1234
> > 	bl  __gmon_start__@plt
> > L1234:
> > 
> 
> But that's exactly what is supposed to be avoided.  On x86 the
> generated code looks like this:
> 
>         movl    __gmon_start__@GOT(%ebx), %eax
>         testl   %eax, %eax
>         je      .L22
>         call    *%eax
> 
> I.e., no use of __gmon_start__ as a jump target.  Since I have no PPC
> machine handy I cannot say whether you get similar code.  If you do
> seeing two relocations is wrong and can only be produced by the file
> splitting.

Why is it wrong?

It just means that the PLT entry will jump to location 0, but that
should never happen because the entry in the GOT will be zero since
the symbol is never defined.

-- 
- Geoffrey Keating <geoffk@cygnus.com>


More information about the Libc-alpha mailing list