Painful problems with -fpic implementation on powerpc-sysv

Richard Henderson rth@cygnus.com
Wed Aug 26 20:55:00 GMT 1998


On Wed, Aug 26, 1998 at 07:29:57PM -0600, Jeffrey A Law wrote:
> Consider a target where it is impossible to synthesize the sequence
> at reload time.

Define "impossible to synthesize".  Ugly, yes.  I can also see
needing two or three reload regs.  But it should be possible, 
ignoring asms, and given that any one insn doesn't have more than
a couple inputs.

In any case, from what little I know about ppc, I wouldn't think
there is such a thing, at least for pic in the 32-bit sysv abi:

 * Having the pic register somewhere is non-negotiable.  You need
   it for either reading the actual data or for reading the address
   from constant memory.  We ought to be able to emit this 
   two-insn sequence just about anywhere.

 * From there, one can continue modifying the address in-place.


r~



More information about the Gcc mailing list