gimplify.c (struct gimplify_omp_ctx): Add clauses member.
authorJakub Jelinek <jakub@redhat.com>
Wed, 29 May 2019 07:51:43 +0000 (09:51 +0200)
committerJakub Jelinek <jakub@gcc.gnu.org>
Wed, 29 May 2019 07:51:43 +0000 (09:51 +0200)
commit7e47198b802ed52fb8bb314b75ddf3cd84b2d9f4
treee9533c1c58c656e54720467040cf9dc16c2c2968
parent357a352fe3a3a96b1a8c321f36a010e3798abdeb
gimplify.c (struct gimplify_omp_ctx): Add clauses member.

* gimplify.c (struct gimplify_omp_ctx): Add clauses member.
(gimplify_scan_omp_clauses): Initialize ctx->clauses.
(gimplify_adjust_omp_clauses_1): Transform lastprivate conditional
explicit clause on combined parallel into implicit shared clause.
(gimplify_adjust_omp_clauses): Move lastprivate conditional clause
and firstprivate if the decl has one too from combined parallel to
the worksharing construct.
gcc/testsuite/
* c-c++-common/gomp/lastprivate-conditional-2.c (foo): Don't expect
sorry on lastprivate conditional on parallel for.
* c-c++-common/gomp/lastprivate-conditional-3.c (foo): Add tests for
lastprivate conditional warnings on parallel for constructs.
* c-c++-common/gomp/lastprivate-conditional-4.c: New test.
libgomp/
* testsuite/libgomp.c-c++-common/lastprivate_conditional_4.c: Rename
to ...
* testsuite/libgomp.c-c++-common/lastprivate-conditional-4.c: ... this.
* testsuite/libgomp.c-c++-common/lastprivate-conditional-5.c: New test.
* testsuite/libgomp.c-c++-common/lastprivate-conditional-6.c: New test.

From-SVN: r271733
gcc/ChangeLog
gcc/gimplify.c
gcc/testsuite/ChangeLog
gcc/testsuite/c-c++-common/gomp/lastprivate-conditional-2.c
gcc/testsuite/c-c++-common/gomp/lastprivate-conditional-3.c
gcc/testsuite/c-c++-common/gomp/lastprivate-conditional-4.c [new file with mode: 0644]
libgomp/ChangeLog
libgomp/testsuite/libgomp.c-c++-common/lastprivate-conditional-4.c [new file with mode: 0644]
libgomp/testsuite/libgomp.c-c++-common/lastprivate-conditional-5.c [new file with mode: 0644]
libgomp/testsuite/libgomp.c-c++-common/lastprivate-conditional-6.c [new file with mode: 0644]
libgomp/testsuite/libgomp.c-c++-common/lastprivate_conditional_4.c [deleted file]