https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96043
Richard Biener <rguenth at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|marxin at gcc dot gnu.org |rguenth at gcc dot gnu.org --- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> --- So with BB vectorization of non-stores double a[4]; double x, y; void bar (double, double); void foo(double a0, double a1, double a2, double a3) { double tem1 = a0 + a2 + 1.; double tem2 = a1 + a3 + 2.; x = tem1; y = tem2; } becomes profitable by inserting an unrelated opportunity: double a[4]; double x, y; void bar (double, double); void foo(double a0, double a1, double a2, double a3) { double tem1 = a0 + a2 + 1.; double tem2 = a1 + a3 + 2.; x = tem1; y = tem2; a[0] += a[2]; a[1] += a[3]; } there's the "complication" that the independent SLP graph components are not solely formed by the SLP graph nodes and edges but instead we have to consider scalar stmts as connection between SLP graphs because of the way scalar costing works. Also "shared" external nodes shouldn't be considered tieing two SLP graph components together. Mine.