This is the mail archive of the gcc@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: Adding soft-registers


Hi!

James Dessart wrote:

On 7-Jan-04, at 1:51 PM, Eric Botcazou wrote:


The MC6809 back-end appears to use a "looseness" strategy to avoid generating
lots of memory references during RTL expansion and to expect that reload
will fix up everything at the end. This doesn't work here because the
subqi3 pattern is not commutative.


Thanks! This seems to fix up the problem with the compiler. I'll run it through its paces when I get a chance.

What I would like to do, though, is add some soft registers to the port. Others are interested in using the port for floating point, with soft floating point support, but none of us have the knowledge to add the required extra registers. I tried reading the gccint documents, but they're really just a reference to what's there. I tried using the mc68hc11 port (which has soft registers) to see how to do it, but I got lost between the piles of related macros, the C implementation and the machine description. Is there a howto somewhere?

Thanks,
James

FYI the 6809 is intermediate between 68HC11 and 68HC12: same regs, same instruction set, same addressing modes as HC11 + restricted auto increment mode (restricted compared to HC12). My feeling is that you should be able to steal the hole hc11 port and hack it to your needs (and pretend it is an HC12 as the 6809 is closer to it then to HC11; except for movXXX patterns:-) ).

I don't have a document that explains the particular implementation of m68hc11
port.  Check http://stephane.carrez.free.fr/doc/hc11_3.html#SEC17 to see
how the soft regs are mapped and .... use the source James...

What is important for such soft reg is that they are in memory and as such
you have to be careful when you define your constraints.  The movXXX must be
defined with care because you don't have a memory <-> memory move.

Stephane

--
        Home                           Office
E-mail: stcarrez@nerim.fr              Stephane.Carrez@solsoft.com
WWW:    http://stcarrez.nerim.net      http://www.solsoft.com
        Free the Software!             Security Policy Management



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