- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
I have this program:
With gfortran 4.4, I can see a permutation of 1 thru 16. But with ifort 12.1.{01}, I see a lot of other values.
[fortran]program test integer i !$omp parallel private(i) !$omp single do i = 1, 16 call f(i) end do !$omp end single nowait !$omp end parallel contains subroutine f(x) integer :: x !$omp task firstprivate(x) print *, x !$omp end task end subroutine end program [/fortran]
With gfortran 4.4, I can see a permutation of 1 thru 16. But with ifort 12.1.{01}, I see a lot of other values.
링크가 복사됨
3 응답
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
I believe this may be a bug in the compiler. The TASK construct is a new OpenMP* 3.0 feature and may be erroneous here. If I replace the function call f(i) with an explicit print statement surrounded by a TASK construct, then the correct values are printed.
What do the OpenMP* experts on this forum think?
Best!
-Udit
What do the OpenMP* experts on this forum think?
Best!
-Udit
