On Tue, Jun 23, 2015 at 02:06:27PM +0300, Ilya Verbin wrote: > On Thu, Jun 18, 2015 at 15:15:21 +0200, Jakub Jelinek wrote: > > This patch adds support for linear clause on OpenMP 4.1 worksharing loops. > > > > 2015-06-18 Jakub Jelinek <ja...@redhat.com> > > > > * gimplify.c (gimplify_scan_omp_clauses): For linear clause > > on worksharing loop combined with parallel add shared clause > > on the parallel. > > * omp-low.c (lower_rec_input_clauses): Set lastprivate_firstprivate > > flag for linear that needs copyin and copyout. > > (expand_omp_for_generic, expand_omp_for_static_nochunk, > > expand_omp_for_static_chunk): Handle linear clauses on worksharing > > loop. > > (lower_omp_for): Adjust OMP_CLAUSE_DECL and OMP_CLAUSE_LINEAR_STEP > > so that expand_omp_for_* can use it during expansion for linear > > adjustments. > > gcc/c-family/ > > * c-omp.c (c_omp_split_clauses): Fix up a comment. Put > > OMP_CLAUSE_LINEAR on OMP_FOR if not combined with OMP_SIMD. > > libgomp/ > > * testsuite/libgomp.c/pr66199-3.c: New test. > > * testsuite/libgomp.c/pr66199-4.c: New test. > > * testsuite/libgomp.c/linear-1.c: New test. > > * testsuite/libgomp.c/linear-2.c: New test. > > * testsuite/libgomp.c++/linear-1.C: New test. > > * testsuite/libgomp.c++/linear-2.C: New test. > > Have you seen this (using mic emul)? > > FAIL: libgomp.c/linear-2.c execution test > FAIL: libgomp.c++/linear-2.C execution test
I admit I've been testing gomp-4.1 branch only without mic emul/ptx, and for linear-2.c I've only eyeballed the omplower and ssa dumps, so yes, it is possible something is broken for distribute. Though, I'd more expect it to be broken on the (non-existing) PTX OpenMP support than mic emul, where we use only a single team. Jakub