- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I found a bug in the handling of OMP firstprivate data. (Using icc (ICC) 14.0.0 20130728 on linux) Here is a small example.
[cpp]
#include <vector>
using namespace std;
int main() {
int i,k;
int nr_NegSimp = 0;
int nr_gen = 720;
vector<int> zero_i(nr_gen);
vector<int> subfacet(nr_gen);
#pragma omp parallel for firstprivate(zero_i,subfacet) private(k) schedule(dynamic)
for (i=0; i<nr_NegSimp;i++){
zero_i=subfacet;
}
return 0;
}
[/cpp]
It gives an segfault (or up to number of threads many). The problem is the following: The vector is not correctly constructed, but the destructor is applied. This happens only when the loop is executed zero times (as in this example).
It is possible, that it was introduced in the fix for this bug http://software.intel.com/en-us/forums/topic/280462 since it seems to not appear in the windows version from 2011. In that version I found another bug in the firstprivate handling (see http://software.intel.com/en-us/forums/topic/285488).
I wanted to create a support ticked, but the system somehow does not allow me to choose the affected software.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Christof,
I've entered this issue to our problem-tracking database. Will let you know when I have an update regarding it.
Thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you.
In the meantime I was able to create a ticket at the support to.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
What happens with:
[cpp]
#pragma omp parallel firstprivate(zero_i,subfacet) private(k) schedule(dynamic)
{
#pragma omp for
for (int i=0; i<nr_NegSimp;i++){
...}
}
[/cpp]
Jim Dempsey
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Jim,
yes that works fine. Exept that the schedule has to be specified at the for pragma, not the parallel.
Also maybe interesting is that it only happens with FIRSTprivate, not with just private. I guess the copying is not performed correctly in this case.
I have already eliminated the problem in my code. I just wanted to report the problem, since it clearly is a bug.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
update to this issue. it has been fixed in update 2.
you can download the latest update 2 from the Intel Registration Center or the evaluation page.
Thanks,
Jennifer

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