[PATCH] Fix devirtualization ICE (PR tree-optimization/59622, take 3)

Jakub Jelinek jakub@redhat.com
Thu Jan 9 12:36:00 GMT 2014

On Thu, Jan 09, 2014 at 01:30:53PM +0100, Richard Biener wrote:
> > gimplify_modify_expr has:
> > 
> >       if (!gimple_call_noreturn_p (assign))
> >         gimple_call_set_lhs (assign, *to_p);
> Ok, it seems to be too early then - move it after the folding.

That wouldn't help all the other early calls of fold_stmt though.
E.g. lower_omp.  Plus, even in gimplify_modify_expr, doing it
after fold_stmt would mean having to walk all stmts created by the folding?,
check if they are calls (because a call can fold into nothing or something
completely different).  Isn't it better then fold_stmt does that instead?


More information about the Gcc-patches mailing list