On 20.09.21 11:55, Jakub Jelinek via Fortran wrote: > So the FE was splitting the order clause to distribute already before, > perhaps we should undo that for gcc 11 which doesn't claim any OpenMP 5.1 > support. > The difference is e.g. the distribute parallel do order(concurrent) copyin(thr) > case which used to be ok in 5.0 and is not in 5.1. Well, if I try with GCC 11: void f(int *a) { int i; static int thr; #pragma omp threadprivate (thr) #pragma omp distribute parallel for order(concurrent) copyin(thr) for (i = 0; i < 10; ++i) { thr = 5; a[i] = thr; } } I get with gcc (+ gfortran): error: threadprivate variable ‘thr’ used in a region with ‘order(concurrent)’ clause I might have misunderstood the example. * * * In any case, for GCC 11, I have now fixed the splitting and added a testcase which relies on -fdump-tree-original scanning and does not use threadprivate. OK for GCC 11, only? Tobias ----------------- Siemens Electronic Design Automation GmbH; Anschrift: Arnulfstraße 201, 80634 München; Gesellschaft mit beschränkter Haftung; Geschäftsführer: Thomas Heurung, Frank Thürauf; Sitz der Gesellschaft: München; Registergericht München, HRB 106955