PGI User Forum
 SearchSearch   MemberlistMemberlist     RegisterRegister   ProfileProfile    Log inLog in 

CUDA-x86.

Breaking a Dependency

 
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling
View previous topic :: View next topic  
Author Message
THX 1138



Joined: 30 Jun 2011
Posts: 103

PostPosted: Tue Nov 13, 2012 1:13 pm    Post subject: Breaking a Dependency Reply with quote

My 12.9 linux 64 Centos 6.3 pgcc compiler flags the following loop as having a dependency. I do not see how.

Code:
  int Nfreq = (*Env).Nfreq;
  for(i=0;i<Nfreq;i=i+1){
    FRAY[i] = FRAY[i] * BTMRFL;
  }


The only way it could have a dependency is with BTMRFL which may create a dependency. The complete section of code is:

Code:
 if( 0.0 < ANGINC && ANGINC < M_PI/2){
    /*BTMRF9( 1, &ANGINC, &BTMRFL, *RRAY, *IBTMbB, Env );*/
    BTMRFL = btmr04(ANGINC, *RRAY, *IBTMbB, Env);
  } else {
    BTMRFL = 0.0;
    /*printf("RFL_BTM: Drop-> R=%f ",*RRAY);
    printf("AB=%f AR=%f AI=%f \n",
   ANGBTM/0.017453293, ANGRAY/0.017453293, ANGINC/0.017453293);*/
  };

  int Nfreq = (*Env).Nfreq;
  for(i=0;i<Nfreq;i=i+1){
    FRAY[i] = FRAY[i] * BTMRFL;
  }


Is this dependency breakable, meaning can I rewrite this code and get the same results, but with no dependency loops to prevent loop parallelization. .

Any help appreciated.

THX 1138
Back to top
View user's profile
mkcolg



Joined: 30 Jun 2004
Posts: 6128
Location: The Portland Group Inc.

PostPosted: Wed Nov 14, 2012 8:30 am    Post subject: Reply with quote

Hi THX 1138,

I don't see a dependency either so something else is going on. Can you post the -Minfo output and double check that the line number corresponds with this line? Also, what data types are are FRAY and BTMRFL?

- Mat
Back to top
View user's profile
Display posts from previous:   
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling All times are GMT - 7 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © phpBB Group