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

--- Comment #12 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-12 branch has been updated by Richard Biener
<rgue...@gcc.gnu.org>:

https://gcc.gnu.org/g:6258d3f06740c3a77cd7a91606107451d71df68d

commit r12-11221-g6258d3f06740c3a77cd7a91606107451d71df68d
Author: Richard Biener <rguent...@suse.de>
Date:   Thu Jan 23 13:10:17 2025 +0100

    tree-optimization/112859 - bogus loop distribution

    When we get a zero distance vector we still have to check for the
    situation of a common inner loop with zero distance.  But we can
    still allow a zero distance for the loop we distribute
    (gcc.dg/tree-ssa/ldist-33.c is such a case).  This is because
    zero distances in non-outermost loops are a misrepresentation
    of dependence by dependence analysis.

    Note that test coverage of loop distribution of loop nests is
    very low.

            PR tree-optimization/112859
            PR tree-optimization/115347
            * tree-loop-distribution.cc
            (loop_distribution::pg_add_dependence_edges): For a zero
            distance vector still make sure to not have an inner
            loop with zero distance.

            * gcc.dg/torture/pr112859.c: New testcase.
            * gcc.dg/torture/pr115347.c: Likewise.
            * gcc.dg/tree-ssa/ldist-36.c: Adjust.

    (cherry picked from commit 04ba1300407f106a6dd10d346f58a51d87e6d43e)

Reply via email to