The following test program usually produces errors when running with multiple OpenMP threads. Sometimes it is very hard to get the test failed. Using static arrays, it seems to be more likely that the test passes. However, in any case Intel's thread checker reports "Write->Write data-races" at the line with the array constructor.
program arraytest
! compiled with ifort -openmp arraytest.F90
integer(kind=4), parameter :: n=1000000
integer(kind=4) :: i
real(kind=8), dimension(:,:),allocatable :: data
real(kind=8), dimension(:),allocatable :: arr
allocate(data(3,n))
!$omp parallel private(arr,i) shared(data)
allocate(arr(3))
!$omp do
do i=1,n
arr(:) = (/ real(i,kind=8)**2, real(i,kind=8)**3, 1.0_8 /)
! uncommenting the following lines never produces an error
!arr(1) = real(i,kind=8)**2
!arr(2) = real(i,kind=8)**3
!arr(3) = 1.0_8
data(:,i) = arr(:)
end do
!$omp end do
deallocate(arr)
!$omp end parallel
do i=1,n
if ( data(1,i) /= real(i,kind=8)**2 ) then
print*,'test failed'
print*,real(i,kind=8)**2
print*,data(1,i)
stop
end if
end do
print*,'test passed'
deallocate(data)
end program arraytest