Introduce gimple_omp_for
commit9b243966b86247c99eab2ea80afdc57858f6d2f9
authorDavid Malcolm <dmalcolm@redhat.com>
Mon, 16 Dec 2013 22:21:33 +0000 (16 17:21 -0500)
committerDavid Malcolm <dmalcolm@redhat.com>
Fri, 24 Oct 2014 21:24:26 +0000 (24 17:24 -0400)
treea8e35dbd4788631848257743dce27950309a2aa2
parent06b91a3dfccbf95409bd2a7eb2005b0dc74234c5
Introduce gimple_omp_for

This corresponds to:
  [PATCH 38/89] Introduce gimple_omp_for
  https://gcc.gnu.org/ml/gcc-patches/2014-04/msg01225.html
from the original 89-patch kit

That earlier patch was approved by Jeff:
> OK with expected changes due to renaming/updates to const handling.
> Please repost the final patch for archival purposes.
in https://gcc.gnu.org/ml/gcc-patches/2014-05/msg00825.html

gcc/
* coretypes.h (gimple_omp_for): New.
(const_gimple_omp_for): New.

* gimple.h (gimple_build_omp_for): Return a gimple_omp_for rather
than a plain gimple.
(gimple_omp_for_set_kind): Require a gimple_omp_for rather than a
plain gimple.
(gimple_omp_for_set_combined_p): Likewise.
(gimple_omp_for_set_combined_into_p): Likewise.

* gimple-pretty-print.c (dump_gimple_omp_for): Require a
gimple_omp_for rather than a plain gimple.
(pp_gimple_stmt_1): Add a checked cast to gimple_omp_for in
GIMPLE_OMP_FOR case of switch statement.

* gimple.c (gimple_build_omp_for): Return a gimple_omp_for rather
than a plain gimple.
(gimple_copy): Add a checked cast to gimple_omp_for and a new local.

* gimplify.c (gimplify_omp_for): Strengthen local "gfor" from
gimple to gimple_omp_for.

* omp-low.c (omp_for_data::for_stmt): Strengthen field from gimple
to gimple_omp_for.
(extract_omp_for_data): Require a gimple_omp_for rather than a
plain gimple.
(workshare_safe_to_combine_p): Add a checked cast to
gimple_omp_for.
(get_ws_args_for): Convert check of code against GIMPLE_OMP_FOR
with a dyn_cast<gimple_omp_for> and a new local.
(scan_omp_parallel): Add a checked cast to gimple_omp_for and a
new local.
(scan_omp_for): Require a gimple_omp_for rather than a plain
gimple.
(scan_omp_1_stmt): Add a checked cast to gimple_omp_for in
GIMPLE_OMP_FOR case of switch statement.
(expand_omp_for): Add a checked cast to gimple_omp_for.
(lower_omp_for): Strengthen local "stmt" from gimple to
gimple_omp_for.

* tree-nested.c (walk_gimple_omp_for): Require a gimple_omp_for
rather than a plain gimple.
(convert_nonlocal_reference_stmt): Add a checked cast to
gimple_omp_for in GIMPLE_OMP_FOR case of switch statement.
(convert_local_reference_stmt): Likewise.

* tree-parloops.c (create_parallel_loop): Strengthen local
"for_stmt" from gimple to gimple_omp_for.
gcc/ChangeLog.gimple-classes
gcc/coretypes.h
gcc/gimple-pretty-print.c
gcc/gimple.c
gcc/gimple.h
gcc/gimplify.c
gcc/omp-low.c
gcc/tree-nested.c
gcc/tree-parloops.c