From: Sebastian Pop Date: Thu, 1 Oct 2015 15:17:51 +0000 (+0000) Subject: add recursion on the inner loops X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=cf72400ff386816898a63d44045e3b2d18847872;p=gcc.git add recursion on the inner loops We now check that all data references in the current loop and inner loops contained within loop are valid in an outer region before declaring that the outer loop is a valid scop. 2015-09-30 Sebastian Pop Aditya Kumar PR tree-optimization/67754 * graphite-scop-detection.c (loop_body_is_valid_scop): Add missing recursion on the inner loops. Co-Authored-By: Aditya Kumar From-SVN: r228346 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index c0f2d0f8ec7..00d4cea9fce 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2015-10-01 Sebastian Pop + Aditya Kumar + + PR tree-optimization/67754 + * graphite-scop-detection.c (loop_body_is_valid_scop): Add missing + recursion on the inner loops. + 2015-10-01 Trevor Saunders * cfganal.c, compare-elim.c, coverage.c, cprop.c, df-scan.c, diff --git a/gcc/graphite-scop-detection.c b/gcc/graphite-scop-detection.c index a498ddcdbfc..d95f527c619 100644 --- a/gcc/graphite-scop-detection.c +++ b/gcc/graphite-scop-detection.c @@ -805,6 +805,18 @@ loop_body_is_valid_scop (loop_p loop, sese_l scop) return false; } free (bbs); + + if (loop->inner) + { + loop = loop->inner; + while (loop) + { + if (!loop_body_is_valid_scop (loop, scop)) + return false; + loop = loop->next; + } + } + return true; }