[Bug target/50751] SH Target: Displacement addressing does not work for QImode and HImode

olegendo at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Sat May 10 21:17:00 GMT 2014


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50751

--- Comment #35 from Oleg Endo <olegendo at gcc dot gnu.org> ---
(In reply to Oleg Endo from comment #34)
> 
> I've tried to reproduce this on trunk rev 205756 (4.9) and the problem seems
> to be gone.

And it popped up again:
FAIL: gcc.dg/atomic/c11-atomic-exec-4.c  -Os  (internal compiler error)

Compiling with -Os -m4 -ml -matomic-model=soft-gusa, I get:

sh_tmp.cpp: In function 'test_thread_uint8_add':
sh_tmp.cpp:71:1: error: unable to find a register to spill in class 'R0_REGS'
sh_tmp.cpp:71:1: error: this is the insn:
(insn 29 28 30 5 (parallel [
            (set (subreg:SI (reg:QI 3 r3 [181]) 0)
                (unspec_volatile:SI [
                        (mem:QI (reg/f:SI 5 r5 [184]) [0  S1 A8])
                        (reg:QI 180)
                        (subreg:QI (reg:SI 7 r7 [178]) 0)
                    ] UNSPECV_CMPXCHG_1))
            (set (mem:QI (reg/f:SI 5 r5 [184]) [0  S1 A8])
                (unspec_volatile:QI [
                        (const_int 0 [0])
                    ] UNSPECV_CMPXCHG_2))
            (set (reg:SI 147 t)
                (unspec_volatile:SI [
                        (const_int 0 [0])
                    ] UNSPECV_CMPXCHG_3))
            (clobber (scratch:SI))
            (clobber (reg:SI 0 r0))
            (clobber (reg:SI 1 r1))
        ]) sh_tmp.cpp:71 640 {atomic_compare_and_swapqi_soft_gusa}
     (expr_list:REG_DEAD (reg:QI 180)
        (expr_list:REG_DEAD (reg:SI 7 r7 [178])
            (expr_list:REG_UNUSED (reg:SI 1 r1)
                (expr_list:REG_UNUSED (reg:SI 0 r0)
                    (nil))))))
sh_tmp.cpp:71:1: internal compiler error: in spill_failure, at reload1.c:2106

Probably we really should try switching to LRA (PR 55212).



More information about the Gcc-bugs mailing list