The following is a simplified test case:
subroutine addv(M, N, a, b, c)
integer :: M, N
REAL:: a(M,N), b(M,N), c(M,N)
integer :: i, j
!$OMP PARALLEL DO PRIVATE(j)
c(i,j) = a(i,j) + b(i,j)
I understand that loop index j which is the parallel loop will be automatically scoped to be private (of course there may be exceptions).
But what about loop index I?
In the current example, will the compiler treat it as private or shared?
What if there was a scalar temporary inside the parallel loop (that is used only inside the loop) that is not a loop index variable? Would that be treated by the compiler as a private or shared variable?
Is there a way to get a listing from the compiler that indicates whether a particular variable is treated as private or shared?
As far as I know there is no way to get such a listing. Does anyone think it should be possible to get such a listing?