This works around a SLP graph partitioning or cost collecting issue
by being more forgiving in vect_bb_vectorization_profitable_p.
2021-02-09 Richard Biener <rguenther@suse.de>
PR tree-optimization/99017
* tree-vect-slp.c (vect_bb_vectorization_profitable_p): Allow
zero vector cost entries.
/* Now cost the portions individually. */
unsigned vi = 0;
unsigned si = 0;
- do
+ while (si < li_scalar_costs.length ()
+ && vi < li_vector_costs.length ())
{
unsigned sl = li_scalar_costs[si].first;
unsigned vl = li_vector_costs[vi].first;
return false;
}
}
- while (si < li_scalar_costs.length ()
- && vi < li_vector_costs.length ());
if (vi < li_vector_costs.length ())
{
if (dump_enabled_p ())