[Bug tree-optimization/81661] [7/8 Regression] ICE in gimplify_modify_expr, at gimplify.c:5638
rguenther at suse dot de
gcc-bugzilla@gcc.gnu.org
Mon Oct 30 10:51:00 GMT 2017
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81661
--- Comment #7 from rguenther at suse dot de <rguenther at suse dot de> ---
On Sat, 28 Oct 2017, pinskia at gcc dot gnu.org wrote:
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81661
>
> --- Comment #6 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
> (In reply to Richard Biener from comment #5)
> > One possibility is instead of using
> >
> > may_be_zero ? 0 : niter
> >
> > as niter for code-generation use
> >
> > (may_be_zero ? 0 : 1) * niter
> >
> > This avoids the gimplification issue. We assemble this as
> >
> > call __addvsi3
> > movl %eax, %esi
> > subl %ebp, %esi
> > cmpl %ebp, %eax
> > setge %al
> > movzbl %al, %eax
> > imull %eax, %esi
> >
> > so it definitely is ugly (we're lacking any pattern matching on this
> > turning it back to a COND_EXPR).
>
> r250377 added a pattern which should have caught that ...
I suspect we're missing cond ? 0 : 1 -> (int) cond for it to
trigger.
More information about the Gcc-bugs
mailing list