PGI User Forum
 SearchSearch   MemberlistMemberlist     RegisterRegister   ProfileProfile    Log inLog in 

CUDA-x86.

Fortran segmentation fault when using openmp WORKSHARE

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



Joined: 22 Feb 2013
Posts: 1

PostPosted: Fri Feb 22, 2013 4:50 pm    Post subject: Fortran segmentation fault when using openmp WORKSHARE Reply with quote

Hi,

I'm converting an MPI Fortran program of mine to utilise openmp as well, but I'm getting segmentation faults when using a pgi compiler. I have a stripped down test case which exhibits the problem:

Code:

Program main
    Use omp_lib

    Type group
        Real(8), Pointer ::  a(:),b(:)
    End Type group
    type(group) :: test

    allocate(test%a(100),test%b(100))

    !$OMP PARALLEL
    !$OMP WORKSHARE
       test%a = 2 *test%b
    !$OMP END WORKSHARE
    !$OMP END PARALLEL

end Program Main


Running the above code gives me a segmentation fault. If I change the WORKSHARE to be an explicit loop with an !$OMP DO, then it runs fine. If I change the Pointers to be Allocatable, then it runs fine. If I leave the Pointers "loose" rather than contained in type group, then it runs fine. If I switch to either intel or gnu compilers, then it runs fine.

I've replicated this problem using pgfortran versions 11.9.0, 12.8.0 and 12.9.0. No newer versions of pgi exist on this machine (Kraken over at the National Institute for Computational Sciences). I don't compile with any flags, save for the one enabling openmp. Is this a compiler bug, and if so is there a better place to report it than this forum (assuming it's not fixed in newer versions than I have access to)? Am I doing something illegal that I'm not noticing and intel/gnu are just letting slide?

Thanks in advance,

~Ben
Back to top
View user's profile
mkcolg



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

PostPosted: Tue Feb 26, 2013 5:13 pm    Post subject: Reply with quote

Hi Ben,

I passed this on to engineer for triage and they have determined this is a compiler error. We have assigned it to TPR#19163 and hope to have it fixed in the near future.

Thanks!
Mat
Back to top
View user's profile
jtull



Joined: 30 Jun 2004
Posts: 438

PostPosted: Mon Aug 12, 2013 2:38 pm    Post subject: 19163 - Fortran seg fault when using openmp WORKSHARE Reply with quote

Hello,

Engineering has confirmed that this problem is fixed in the 13,6 and current 13.7 release.

Thanks again for your submission.

dave
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