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]

unable to find a register to spill


Hi!

I'm getting "unable to find a register to spill" error, but I don't quite
understand why gcc select particular class.

I'm getting the following error:

z80-test/test.c:12: error: unable to find a register to spill in class `SP_REG'
z80-test/test.c:12: error: this is the insn:
(insn 27 26 29 2 0x0 (parallel [
            (set (reg/v:HI 17)
                (plus:HI (reg/v:HI 17)
                    (const_int 16768 [0x4180])))
            (clobber (scratch:HI))
        ]) 14 {addhi3} (nil)
    (expr_list:REG_UNUSED (scratch:HI)
        (nil)))

But addhi3 can accept any not only SP_REG but any register. The same problem
I have with movhi instruction. What are the general suggestions to look at
can be?

I can place the whole patch I've made at this time to some site. And I'm
in progress preparing necessary papers.

--
Alexander Aganichev

url: http://aaganichev.narod.ru
e-mail: aaganichev@yandex.ru
gsm: +7-095-786-1339


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