Re: [PATCH] tree-optimization/98855 - redo BB vectorization costing

2021-02-05 Thread Richard Biener
On Fri, 5 Feb 2021, Richard Biener wrote: > On Fri, 5 Feb 2021, Richard Sandiford wrote: > > > Richard Biener writes: > > > On Fri, 5 Feb 2021, Richard Sandiford wrote: > > >> Richard Biener writes: > > >> > + /* First produce cost vectors sorted by loop index. */ > > >> > + auto_vec > > > >

Re: [PATCH] tree-optimization/98855 - redo BB vectorization costing

2021-02-05 Thread Richard Biener
On Fri, 5 Feb 2021, Richard Sandiford wrote: > Richard Biener writes: > > On Fri, 5 Feb 2021, Richard Sandiford wrote: > >> Richard Biener writes: > >> > + /* First produce cost vectors sorted by loop index. */ > >> > + auto_vec > > >> > +li_scalar_costs (scalar_costs.length ()); > >> > +

Re: [PATCH] tree-optimization/98855 - redo BB vectorization costing

2021-02-05 Thread Richard Sandiford via Gcc-patches
Richard Biener writes: > On Fri, 5 Feb 2021, Richard Sandiford wrote: >> Richard Biener writes: >> > + /* First produce cost vectors sorted by loop index. */ >> > + auto_vec > >> > +li_scalar_costs (scalar_costs.length ()); >> > + auto_vec > >> > +li_vector_costs (vector_costs.length

Re: [PATCH] tree-optimization/98855 - redo BB vectorization costing

2021-02-05 Thread Richard Biener
On Fri, 5 Feb 2021, Richard Sandiford wrote: > Richard Biener writes: > > The following attempts to account for the fact that BB vectorization > > regions now can span multiple loop levels and that an unprofitable > > inner loop vectorization shouldn't be offsetted by a profitable > > outer loop

Re: [PATCH] tree-optimization/98855 - redo BB vectorization costing

2021-02-05 Thread Richard Sandiford via Gcc-patches
Richard Biener writes: > The following attempts to account for the fact that BB vectorization > regions now can span multiple loop levels and that an unprofitable > inner loop vectorization shouldn't be offsetted by a profitable > outer loop vectorization to make it overall profitable. > > For now

[PATCH] tree-optimization/98855 - redo BB vectorization costing

2021-02-05 Thread Richard Biener
The following attempts to account for the fact that BB vectorization regions now can span multiple loop levels and that an unprofitable inner loop vectorization shouldn't be offsetted by a profitable outer loop vectorization to make it overall profitable. For now I've implemented a heuristic based