- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I have encountered a problem (producing incorrect answer) with threadprivate using ifc 8.0 on Linux. I have constructed a small test case and am able to demonstrate the problem. I am also using the example (as shown below) listed in the OpenMP API version 2.5, Nov 2004 documentation (p177). It shows the same problem. I wonder there is a bug in the ifc. Thanks.
Best regards,
David Wong
PS: here is how I compile the code:
/share/linux/intel8.0/bin/ifc -quiet -static -cpp -openmp -o t.x t.f
module a30_module8
real, pointer :: work(:)
save :: work
!$omp threadprivate(work)
end module a30_module8
subroutine sub1(n)
use a30_module8
!$omp parallel private(the_sum)
allocate(work(n))
call sub2(n,the_sum)
write (*,*) the_sum
!$omp end parallel
end subroutine sub1
subroutine sub2 (n, the_sum)
use a30_module8
work = 10
the_sum = sum(work)
end subroutine sub2
program a30_8_good
use a30_module8
n = 10
call sub1(n)
end program a30_8_good
I have encountered a problem (producing incorrect answer) with threadprivate using ifc 8.0 on Linux. I have constructed a small test case and am able to demonstrate the problem. I am also using the example (as shown below) listed in the OpenMP API version 2.5, Nov 2004 documentation (p177). It shows the same problem. I wonder there is a bug in the ifc. Thanks.
Best regards,
David Wong
PS: here is how I compile the code:
/share/linux/intel8.0/bin/ifc -quiet -static -cpp -openmp -o t.x t.f
module a30_module8
real, pointer :: work(:)
save :: work
!$omp threadprivate(work)
end module a30_module8
subroutine sub1(n)
use a30_module8
!$omp parallel private(the_sum)
allocate(work(n))
call sub2(n,the_sum)
write (*,*) the_sum
!$omp end parallel
end subroutine sub1
subroutine sub2 (n, the_sum)
use a30_module8
work = 10
the_sum = sum(work)
end subroutine sub2
program a30_8_good
use a30_module8
n = 10
call sub1(n)
end program a30_8_good
Link Copied
4 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
We have had some threadprivate issues in the past, but version 8.0 was replaced with 8.1 last August. The current version is 8.1.026. Please try that out and, if it still doesn't work for you, submit the problem through Intel Premier Support. I tried it on a recent compiler and got the result 100.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Mr. Lionel,
A moment ago, we have installed ifc 8.1 (8.1.024), and it looks like it works even with my another test case. I will try it on the original code. Thanks.
Best regards,
David Wong
A moment ago, we have installed ifc 8.1 (8.1.024), and it looks like it works even with my another test case. I will try it on the original code. Thanks.
Best regards,
David Wong
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
sblionel wrote:
We have had some threadprivate issues in the past, but version 8.0 was replaced with 8.1 last August. The current version is 8.1.026. Please try that out and, if it still doesn't work for you, submit the problem through Intel Premier Support. I tried it on a recent compiler and got the result 100.
Hi Mr. Lionel,
Does the same threadprivate issue occur in the Intel compiler 8.1.028 on Windows? One of my colleagues claims he is experiencing that problem on Windows. Please advise.
Thanks,
David Wong
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The thing with such issues is that it's impossible to say that something is "the same problem" without actually seeing an example. Many times I have thought that two programs which exhibited the same symptom were the same problem, but they weren't.
I know we have fixed THREADPRIVATE issues in the past. That does not mean that there aren't other such issues with programs that do things differently. My advice is the same - send an example to Intel Premier Support.
I know we have fixed THREADPRIVATE issues in the past. That does not mean that there aren't other such issues with programs that do things differently. My advice is the same - send an example to Intel Premier Support.

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page