segmention fault in pluto generated code

25 views
Skip to first unread message

Hengjie

unread,
Jan 14, 2020, 6:41:37 PM1/14/20
to Pluto development
Hello,

I am trying to use Pluto to tile the following weight Jacobi iteration.
a, b, c are three 3d arrays and w0, w1, h2 are constant coefficients. 
#pragma scop                                                                    
  for (int t=0; t<T; ++t) {                                                     
    // p -> a                                                                   
    for (int i=1; i<=N; ++i) {                                                  
      for (int j=1; j<=N; ++j) {                                                                                                            
        for (int k=1; k<=N; ++k) {                                              
          a[i][j][k] = w0 * (( p[i][j][k-1] + p[i][j][k+1] + p[i][j-1][k]       
                             + p[i][j+1][k] + p[i+1][j][k] + p[i-1][j][k]) / 6.0
                            - h2 * b[i][j][k])                                  
                     + w1 * p[i][j][k];                                         
        }                                                                       
      }                                                                         
    }                                                                           
    // a -> p                                                                   
    for (int i=1; i<=N; ++i) {                                                  
      for (int j=1; j<=N; ++j) {                                                
        for (int k=1; k<=N; ++k) {                                              
          p[i][j][k] = w0 * (( a[i][j][k-1] + a[i][j][k+1] + a[i][j-1][k]       
                + a[i][j+1][k] + a[i+1][j][k] + a[i-1][j][k]) / 6.0             
              - h2 * b[i][j][k])                                                
            + w1 * a[i][j][k];                                                  
        }                                                                       
      }                                                                         
    }                                                                           
  }                                                                             
#pragma endscop  

The above code can compile with Intel 2020 compiler run without problems. When I run the code generated by Pluto I got a segmentation fault. Could you please let me know if the above code violates any requirement of Pluto? 
Thank you so much.

Hengjie

Reply all
Reply to author
Forward
0 new messages