tree.h (OMP_CLAUSE__CONDTEMP__ITER): Define.
authorJakub Jelinek <jakub@redhat.com>
Fri, 31 May 2019 21:38:35 +0000 (23:38 +0200)
committerJakub Jelinek <jakub@gcc.gnu.org>
Fri, 31 May 2019 21:38:35 +0000 (23:38 +0200)
commite7393c8936b9cfb1a28f7e16043c107490491ba4
treed0fa7f6aa5f6d8bb93ca641511f03dc17e4ee9be
parent1ce8fc63a4132b66ced527afd2c88b840ecbb0b9
tree.h (OMP_CLAUSE__CONDTEMP__ITER): Define.

* tree.h (OMP_CLAUSE__CONDTEMP__ITER): Define.
* gimplify.c (gimplify_scan_omp_clauses): Allow lastprivate conditional
on OMP_SIMD if not nested inside of worksharing loop that also has
lastprivate conditional clause for the same decl.
(gimplify_omp_for): Add _condtemp_ clauses to OMP_SIMD if needed.
* omp-low.c (scan_sharing_clauses): Handle OMP_CLAUSE__CONDTEMP_ also
on simd.
(lower_rec_input_clauses): Likewise.  Handle lastprivate conditional
on simd construct.
(lower_lastprivate_conditional_clauses): Handle lastprivate conditional
on simd construct.
(lower_lastprivate_clauses): Likewise.
(lower_omp_sections): Call lower_lastprivate_conditional_clauses before
calling lower_rec_input_clauses.
(lower_omp_for): Likewise.
(lower_omp_1): Use first rather than second OMP_CLAUSE__CONDTEMP_
clause on simd construct.
* omp-expand.c (expand_omp_simd): Initialize cond_var if
OMP_CLAUSE__CONDTEMP_ clause is present.

* c-c++-common/gomp/lastprivate-conditional-2.c (foo): Don't expect
a sorry on lastprivate conditional on simd construct.
* gcc.dg/vect/vect-simd-6.c: New test.
* gcc.dg/vect/vect-simd-7.c: New test.

From-SVN: r271825
gcc/ChangeLog
gcc/gimplify.c
gcc/omp-expand.c
gcc/omp-low.c
gcc/testsuite/ChangeLog
gcc/testsuite/c-c++-common/gomp/lastprivate-conditional-2.c
gcc/testsuite/gcc.dg/vect/vect-simd-6.c [new file with mode: 0644]
gcc/testsuite/gcc.dg/vect/vect-simd-7.c [new file with mode: 0644]
gcc/tree.h