From: Richard Biener Date: Tue, 19 Sep 2017 07:14:12 +0000 (+0000) Subject: graphite-scop-detection.c (scop_detection::can_represent_loop): Do not iterate to... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=129d9dc2927dfe6343386d40697adfdd0582df2a;p=gcc.git graphite-scop-detection.c (scop_detection::can_represent_loop): Do not iterate to sibling loops but only to siblings of inner loops. 2017-09-19 Richard Biener * graphite-scop-detection.c (scop_detection::can_represent_loop): Do not iterate to sibling loops but only to siblings of inner loops. From-SVN: r252962 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 2267d2e940b..79a492f83a9 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2017-09-19 Richard Biener + + * graphite-scop-detection.c (scop_detection::can_represent_loop): + Do not iterate to sibling loops but only to siblings of inner + loops. + 2017-09-18 Andreas Schwab PR target/81613 diff --git a/gcc/graphite-scop-detection.c b/gcc/graphite-scop-detection.c index 71ddfd8e234..3ed6afd0a6a 100644 --- a/gcc/graphite-scop-detection.c +++ b/gcc/graphite-scop-detection.c @@ -975,11 +975,9 @@ scop_detection::can_represent_loop (loop_p loop, sese_l scop) { if (!can_represent_loop_1 (loop, scop)) return false; - if (loop->inner && !can_represent_loop (loop->inner, scop)) - return false; - if (loop->next && !can_represent_loop (loop->next, scop)) - return false; - + for (loop_p inner = loop->inner; inner; inner = inner->next) + if (!can_represent_loop (inner, scop)) + return false; return true; }