https://gcc.gnu.org/bugzilla/show_bug.cgi?id=126926
--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> --- OK, so the issue is that we have two SLP instances interacting at the c_13 definition point of a vector which is both a vector CTOR root for one instance and the leaf (existing vector) of a reduction instance: a.0_1 = a; _2 = a.0_1 + 0.0; c_12 = BIT_INSERT_EXPR <c_11(D), _2, 32>; a.1_3 = a; _4 = a.1_3 + 0.0; c_13 = BIT_INSERT_EXPR <c_12, _4, 0>; _5 = BIT_FIELD_REF <c_13, 32, 32>; _6 = _5 * 0.0; _7 = BIT_FIELD_REF <c_13, 32, 32>; _8 = _7 * 2.0e+0; _9 = _6 + _8; When we transform the CTOR instance first we replace the c_13 definition in vectorize_slp_instance_root_stmt replacing the original one and that disrupts the SLP scheduling process of the 2nd as the replacement now appears to be outside of the SLP region. We can avoid this and retain the original stmt.
