------- Comment #5 from hp at gcc dot gnu dot org 2008-10-22 22:17 ------- Created an attachment (id=16531) --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=16531&action=view) Reduced test-case for updated cris.h at r141228. Compile with -O2.
After fixing REGNO_REG_CLASS (but still with the singleton version of IRA_COVER_CLASSES), see the cris.h patch, I still get an ICE in IRA, during build, compiling ldtoa.c from newlib: dtoa2.c: In function 'emovo': ldtoa2.c:24: error: unrecognizable insn: (insn 144 57 140 4 ldtoa2.c:12 (set (reg:HI 13 r13) (mem:HI (post_inc:SI (reg/v/f:SI 15 acr [orig:63 p.37 ] [63])) [2 S2 A8])) -1 (expr_list:REG_INC (reg/v/f:SI 15\ acr [orig:63 p.37 ] [63]) (nil))) ldtoa2.c:24: internal compiler error: in extract_insn, at recog.c:2027 The last dump file is from IRA. It appears IRA (or reload) allocates ACR (reg 15) for an address with post-increment. It's just that this register can't be used for that addressing mode - which is one of the reasons it's in a separate class. This doesn't happen with the non-singleton IRA_COVER_CLASSES. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37813