[Bug rtl-optimization/57032] [4.9/5 Regression]: internal compiler error: Max. number of generated reload insns per insn is achieved (90)
ubizjak at gmail dot com
gcc-bugzilla@gcc.gnu.org
Thu Apr 9 19:46:00 GMT 2015
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=57032
--- Comment #10 from Uroš Bizjak <ubizjak at gmail dot com> ---
(In reply to Richard Henderson from comment #9)
> I think all of the bits touching reload internals stems
> from the non-existence of define_memory_constraint when
> the port was first written.
>
> I suspect that this is fixable with nothing more than
>
> (define_memory_constraint "Q"
> "@internal normal memory operand"
> (and (match_code "mem")
> (match_test "GET_CODE (XEXP (op, 0)) != AND")
> (match_test "memory_address_addr_space_p
> (GET_MODE (op), XEXP (op, 0),
> MEM_ADDR_SPACE (op))")))
Great, this fix brings bootstrap way further to libgomp, but now crashes with:
/space/homedirs/uros/gcc-svn/trunk/libgomp/team.c: In function
‘gomp_team_start’:
/space/homedirs/uros/gcc-svn/trunk/libgomp/team.c:836:1: internal compiler
error: Max. number of generated reload insns per insn is achieved (90)
However, this is different problem, and this one indeed looks like RA problem.
There, RA wants to reload:
(insn 280 2259 279 17 (set (reg:DI 364)
(ashift:DI (zero_extend:DI (subreg/s/u:QI (reg/v:DI 98 [ bind ]) 0))
(ashift:DI (reg/f:DI 362)
(const_int 3 [0x3]))))
/space/homedirs/uros/gcc-svn/trunk/libgomp/team.c:334 83 {insbl}
(nil))
and creates reload loop trying to move QImode subreg of DImode value to QI reg:
Choosing alt 0 in insn 280: (0) =r (1) r (2) rI {insbl}
Creating newreg=1020, assigning class GENERAL_REGS to r1020
280: r364:DI=zero_extend(r1020:QI)<<r362:DI<<0x3
Inserting insn reload before:
2443: r1020:QI=r98:DI#0
0 Non pseudo reload: reject++
alt=0,overall=607,losers=1,rld_nregs=1
0 Non pseudo reload: reject++
alt=1: Bad operand -- refuse
Choosing alt 0 in insn 2443: (0) =r (1) rJ {*movqi}
Creating newreg=1021, assigning class GENERAL_REGS to r1021
2443: r1020:QI=r1021:QI
Inserting insn reload before:
2444: r1021:QI=r98:DI#0
0 Non pseudo reload: reject++
alt=0,overall=607,losers=1,rld_nregs=1
0 Non pseudo reload: reject++
alt=1: Bad operand -- refuse
Choosing alt 0 in insn 2444: (0) =r (1) rJ {*movqi}
Creating newreg=1022, assigning class GENERAL_REGS to r1022
2444: r1021:QI=r1022:QI
Inserting insn reload before:
...
I'll post the WIP patch and preprocessed source in a moment.
More information about the Gcc-bugs
mailing list