Saga of m68k PIC continues

Jan Hubicka jh@suse.cz
Thu Dec 12 13:00:00 GMT 2002


> 
> >> Note the removal of the (const ... ) in insn 11.
> >> 
> >> Any ideas where this is being stripped off?
> >
> >GCC will happily put in the subreg when your machine description accept
> >it.
> 
> I don't see how subregs take care of -fPIC and (unspec ...).  Could
> you explain?
Oops, I meant symbol_ref, of course...
> 
> >There are hooks defining valid addresses and constants and these
> >must refuse invalid stuff, like (symbol_ref:SI ("foo") is for PIC.
> 
> Do you mean that GO_IF_LEGITIMATE_ADDRESS needs to reject a raw
> (symbol_ref:SI ("foo")) if in pic mode,  which would then force the
> addr to be pushed through LEGITIMIZE_ADDRESS(I think) where it would
> spot the raw symbol_ref in pic mode and by wrap it in a (const
> (uspec:SI [...] 3))? 
Yes, and additionally you need LEGITIMATE_PIC_OPERAND_P to reject
symbol_ref as immediate operands.

Honza
> 
> -- 
> Peter Barada                                   Peter.Barada@motorola.com
> Wizard                                         781-852-2768 (direct)
> WaveMark Solutions(wholly owned by Motorola)   781-270-0193 (fax)



More information about the Gcc mailing list