]> git.ipfire.org Git - thirdparty/gcc.git/commit - gcc/sese.c
gather bbs and conditions in a single walk through dominators
authorAditya Kumar <aditya.k7@samsung.com>
Wed, 7 Oct 2015 19:25:35 +0000 (19:25 +0000)
committerSebastian Pop <spop@gcc.gnu.org>
Wed, 7 Oct 2015 19:25:35 +0000 (19:25 +0000)
commitb0b5710cf676de537bc97b912218dd20d2cc36cd
treeb6c490b95437aad607c9450aa3273e12269a95b6
parentb759335b16ebc8d6640778df53c18fe11ca7083a
gather bbs and conditions in a single walk through dominators

Clean up the function to build scop's basic blocks and the function
that gathers the conditions under which a basic block is executed.  We remove
one traversal of the dominator tree.

This refactoring was triggered by the need of a vec<bb> of all the basic blocks
in a region.  We will use that vector in a patch that removes the out-of-ssa
translation of scalar dependences: we will iterate through the basic blocks of a
region to record scalar dependences crossing bbs or going out of the region.

The patch passes bootstrap and regtest on x86_64-linux.

2015-10-06  Aditya Kumar  <aditya.k7@samsung.com>
                Sebastian Pop  <s.pop@samsung.com>

                * graphite-dependences.c (scop_get_dependences): Do not use SCOP_BBS.
                * graphite-isl-ast-to-gimple.c (get_max_schedule_dimensions): Same.
                (generate_isl_schedule): Same.
                * graphite-optimize-isl.c (scop_get_domains): Same.
                (apply_schedule_map_to_scop): Same.
                * graphite-poly.c (print_iteration_domains): Same.
                (remove_gbbs_in_scop): Same.
                (new_scop): Same.
                (free_scop): Same.
                (print_scop): Same.
                * graphite-poly.h (struct scop): Rename bbs to pbbs.
                (SCOP_BBS): Remove.
                * graphite-scop-detection.c (compare_bb_depths): Remove.
                (graphite_sort_dominated_info): Remove.
                (try_generate_gimple_bb): Move out of scop_detection.
                (all_non_dominated_preds_marked_p): Remove.
                (build_scop_bbs_1): Remove.
                (build_scop_bbs): Remove.
                (nb_pbbs_in_loops): Do not use SCOP_BBS.
                (find_scop_parameters): Same.
                (sese_dom_walker): Rename gather_bbs.
                (before_dom_children): Call try_generate_gimple_bb and collect gbb
                and pbb.
                (build_scops): Call gather_bbs.
                * graphite-sese-to-poly.c (build_scop_scattering): Do not use SCOP_BBS.
                (add_conditions_to_constraints): Same.
                (build_scop_iteration_domain): Same.
                (build_scop_drs): Same.
                (new_pbb_from_pbb): Same.
                * sese.c (new_sese_info): Create bbs.
                * sese.h (struct sese_info_t): Add bbs.

Co-Authored-By: Sebastian Pop <s.pop@samsung.com>
From-SVN: r228581
gcc/ChangeLog
gcc/graphite-dependences.c
gcc/graphite-isl-ast-to-gimple.c
gcc/graphite-optimize-isl.c
gcc/graphite-poly.c
gcc/graphite-poly.h
gcc/graphite-scop-detection.c
gcc/graphite-sese-to-poly.c
gcc/sese.c
gcc/sese.h