This is the mail archive of the binutils@sourceware.org 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: linker stub symbols for ELF32 secured ABI


On Sat, Dec 10, 2005 at 11:34:24PM +0200, Yaakov Yaari wrote:
> The standard we have with ELF64 is <hexstubaddr>.<stubtype>.<callee>
> So in the following...
>   xxxxxxxx_plt_call_<callee> where xxxxxxxx is a hex number, usually 0,
> ..., one problem is that the stub type is not delimited in dots,

OK, fixed.

> and the
> second is that the type used, 'plt_call', is already used by ELF64 plt call

Why does this matter?  The linker won't ever generate a mixed 32/64-bit
PLT!  I'm just curious, there isn't any difficulty in using a different
string.

> stub. Using 'xxxxxxxx' invariably as 00000000 (or any other 8-chars hex
> sequence) is OK though.
> I can see three ELF32 plt call stub types:
> 1. 'plt_call32', for non-PIC form ('lis r11,off, lwz r11,off(r11), mtctr,
> bctr" sequence),
> 2. 'plt_call32PS', for short PIC sequence ('lwz r11,off(r30), mtctr,
> bctr'), and
> 3. 'plt_call32PL', for long PIC sequence, ('lis r11,r30,off, lwz
> r11,off(r30), mtctr, bctr').

I can't reliably differentiate the short PIC sequence from the long
one without changing the ppc32 linker quite significantly.  The problem
is that the decision about short/long sequence depends on final PLT and
GOT location, which we don't have at the time the symbols are created.
It wouldn't be impossible to do, but I'd rather not do this unless it is
vital for FDPR.  I imagine you can quite easily differentiate the two
sequences yourself by code reading.

-- 
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]