[llvm] r182219 - [Sparc] Rearrange integer registers' allocation order so that register allocator will use I and G registers before using L and O registers.

Jakob Stoklund Olesen stoklund at 2pi.dk
Mon May 20 09:26:55 PDT 2013


On May 19, 2013, at 1:07 PM, Venkatraman Govindaraju <venkatra at cs.wisc.edu> wrote:

> def IntRegs : RegisterClass<"SP", [i32, i64], 32,
> -                            (add L0, L1, L2, L3, L4, L5, L6,
> -                                 L7, I0, I1, I2, I3, I4, I5,
> -                                 O0, O1, O2, O3, O4, O5, O7,
> +                            (add I0, I1, I2, I3, I4, I5,
>                                  G1,
> -                                 // Non-allocatable regs:
> -                                 G2, G3, G4, // FIXME: OK for use only in
> +                                 G2, G3, G4, // OK for use only in
>                                              // applications, not libraries.
> +                                 G5,         // OK for use in 64 bit mode.
> +                                 L0, L1, L2, L3, L4, L5, L6, L7,
> +                                 O0, O1, O2, O3, O4, O5, O7,
> +                                 // Non-allocatable regs:
>                                  O6, // stack ptr
>                                  I6, // frame ptr
>                                  I7, // return address
>                                  G0, // constant zero
> -                                 G5, G6, G7 // reserved for kernel
> +                                 G6, G7 // reserved for kernel
>                                  )>;

Hi Venkat,

The register allocator automatically filters out the reserved registers now, so it isn’t necessary to put them at the end of the register classes any more.

If you prefer to keep them there, that’s fine.

Thanks,
/jakob





More information about the llvm-commits mailing list