fix PR68693: Check for loop structure when extending the SCoP
authorAditya Kumar <aditya.k7@samsung.com>
Fri, 4 Dec 2015 21:36:55 +0000 (21:36 +0000)
committerSebastian Pop <spop@gcc.gnu.org>
Fri, 4 Dec 2015 21:36:55 +0000 (21:36 +0000)
commit15256e28a5351f788b66e574bf1ad53a23fbdda1
treed513c64fdac4af127f0b0f73928de02267d28fe3
parentbdf5848047f719389f64bcd2a6dda081adafa9aa
fix PR68693: Check for loop structure when extending the SCoP

The check for dominance while extending the scop assumed that
multiple successors meant a loop which is not true in case of
conditionals around the loop.

Improved pretty printers for better debugging.

PR tree-optimization/68693
        * graphite-scop-detection.c (dot_all_sese): New
        (dot_all_scops_1): Renamed to dot_all_sese.
        (dot_all_scops): Removed.
        (dot_sese): New.
        (dot_cfg): New.
        (scop_detection::get_nearest_dom_with_single_entry): Check that preds are from different loop levels.
        (scop_detection::get_nearest_pdom_with_single_exit): Check that succs are from different loop levels.
        (scop_detection::print_sese): Inlined.
        (scop_detection::print_edge): New.
        (scop_detection::merge_sese): Added dumps.
        * graphite.h: Add declarations.

gcc/testsuite/ChangeLog:

        * gfortran.dg/graphite/pr68693.f90: New test.

Co-Authored-By: Sebastian Pop <s.pop@samsung.com>
From-SVN: r231309
gcc/ChangeLog
gcc/graphite-scop-detection.c
gcc/graphite.h
gcc/testsuite/ChangeLog
gcc/testsuite/gfortran.dg/graphite/pr68693.f90 [new file with mode: 0644]