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

--- Comment #2 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Richard Biener <[email protected]>:

https://gcc.gnu.org/g:a9c22e6d049bf10e44b6a76384a1eb00991c3eb8

commit r17-3364-ga9c22e6d049bf10e44b6a76384a1eb00991c3eb8
Author: Richard Biener <[email protected]>
Date:   Tue Aug 18 11:02:12 2026 +0200

    tree-optimization/126926 - back-to-back SLP instance scheduling

    When 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,
    we transform the CTOR instance first replacing the definition
    in vectorize_slp_instance_root_stmt.  That disrupts the SLP scheduling
    process of the 2nd as the replacement now appears to be outside of the
    SLP region.  Avoid this by not replacing the vector constructing stmt but
    only its RHS.

            PR tree-optimization/126926
            * tree-vect-slp.cc (vectorize_slp_instance_root_stmt): Only
            replace the RHS of the vector constructing scalar stmt.

            * gcc.dg/vect/bb-slp-pr126926.c: New testcase.

Reply via email to