https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65533

--- Comment #8 from rguenther at suse dot de <rguenther at suse dot de> ---
On Tue, 24 Mar 2015, jakub at gcc dot gnu.org wrote:

> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65533
> 
> --- Comment #7 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
> (In reply to Richard Biener from comment #5)
> > Hmm, looks basically ok, though doing
> > 
> >   vect_free_slp_tree (child);
> > 
> > from the cleanup before
> > 
> >       /* If the SLP build for operand zero failed and operand zero
> >          and one can be commutated try that for the scalar stmts
> >          that failed the match.  */
> >       if (i == 0
> > ...
> > 
> > and simply re-allocating child with
> > 
> >       child = vect_create_new_slp_node (oprnd_info->def_stmts);
> >       if (!child)
> >         {
> >           vect_free_oprnd_info (oprnds_info);
> >           return false;
> >         }
> > 
> > might be "simpler".
> 
> Well, it would be more costly (having to deallocate and allocate everything
> again), and not really much shorter in the source.  Only if we in the future
> popluate early not just the SLP_TREE_CHILDREN vector, but various further
> things your version might be better from maintanance POV.
> 
> > Your patch is ok if it is already tested.
> 
> Not yet tested, but bootstraps/regtests already in progress.  If you feel
> strongly about this, I can surely kill those, write a new patch and redo that.

No, I don't feel strongly about it - for clarity the function should
get some refactoring but not at this stage.

Reply via email to