- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I am trying to use the IF clause with parallel region. I encountered an intermal error when the condition is compound. Please see the the example below. My intel compiler is version 11.1.073. Please help.
-bash-3.2$ icc -c test.c -openmp
(0): internal error: 0_3018
compilation aborted for test.c (code 4)
============== test.c ======================
#include
int main(void){
int x, y;
int i, sum;
x=100;
y=100;
#pragma intel omp parallel if (x>10 && y>10) private(i, sum)
{
for (i=0; i<10000; i++){
sum+=i;
}
}
I am trying to use the IF clause with parallel region. I encountered an intermal error when the condition is compound. Please see the the example below. My intel compiler is version 11.1.073. Please help.
-bash-3.2$ icc -c test.c -openmp
(0): internal error: 0_3018
compilation aborted for test.c (code 4)
============== test.c ======================
#include
int main(void){
int x, y;
int i, sum;
x=100;
y=100;
#pragma intel omp parallel if (x>10 && y>10) private(i, sum)
{
for (i=0; i<10000; i++){
sum+=i;
}
}
Link Copied
2 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I do remember submitting a similar bug report back then. It seems to be corrected in the current intel64 compiler (I added a closing })
I think you should use
icc -openmp -c test.c
and
#include
...
#pragma omp paralllel.....
{
#pragma omp for reduction(+:sum)
for(...){
...
{
{
although there's no dependency on omp.h here.
Even if the internal error were provoked by questionable syntax, it was still a compiler bug, as you supposed.
What I'm referring to as questionable is your code apparently requesting each thread to perform the entire for loop, in case that's not what you intended, then effectively discarding all the results at the end of the parallel (so the compiler might well try to treat it as dead code).
I think you should use
icc -openmp -c test.c
and
#include
...
#pragma omp paralllel.....
{
#pragma omp for reduction(+:sum)
for(...){
...
{
{
although there's no dependency on omp.h here.
Even if the internal error were provoked by questionable syntax, it was still a compiler bug, as you supposed.
What I'm referring to as questionable is your code apparently requesting each thread to perform the entire for loop, in case that's not what you intended, then effectively discarding all the results at the end of the parallel (so the compiler might well try to treat it as dead code).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Yes, this bug has been fixed in the latest release. Please download the release from the Intel Registration Center at: https://registrationcenter.intel.com/RegCenter/Please note also that the release after 11.1 is now called Intel C++ Composer XE (formerly Intel C++ Compiler Professional Edition), and Composer XE includes the Compiler (12.1 version) along with MKL, IPP libraries etc.
Regards,
Kittur
Yes, this bug has been fixed in the latest release. Please download the release from the Intel Registration Center at: https://registrationcenter.intel.com/RegCenter/Please note also that the release after 11.1 is now called Intel C++ Composer XE (formerly Intel C++ Compiler Professional Edition), and Composer XE includes the Compiler (12.1 version) along with MKL, IPP libraries etc.
Regards,
Kittur
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