This is the mail archive of the gcc-help@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: builtin assembler constraints


On Sat, Feb 9, 2013 at 7:37 AM, Georg-Johann Lay <gjl@gcc.gnu.org> wrote:
> Ian Lance Taylor schrieb:
>
>> As far as I know there is no constraint that describes only the even
>> registers of the general register set.  It would not be very difficult
>> to add one to the PPC backend.  I can't think of any other way to
>> approach this.
>
>
> AFAIK that does not work because the respective register class would have
> holes.  You cannot have a register class that contains only even registers
> and omits the odd ones.  Or can IRA / reload handle this now?

To the best of my knowledge it always could.  Register classes
routinely have holes.  I'm not sure what sort of problem you are
thinking of.

> One way would be to use HARD_REGNO_MODE_OK and restrict 64-bit modes to even
> registers, but that would be an ABI change...

Yeah, don't do that.

> From the C level a local register variable could be use, thus it is possible
> to describe but the results will be suboptimal because the respective
> operand is not available for register allocation.

Yes.

Ian


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