PGI User Forum
 SearchSearch   MemberlistMemberlist     RegisterRegister   ProfileProfile    Log inLog in 

CUDA-x86.

PGI not vectorizing openmp loops

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



Joined: 17 Oct 2012
Posts: 1

PostPosted: Wed Oct 17, 2012 9:06 am    Post subject: PGI not vectorizing openmp loops Reply with quote

I have a piece of F90 code that looks something like this (this is representative code only):

do i = 1, n1
do j = 1, n2
r(j,i) = r(j,i) + m(i)*s(j,i)
enddo
enddo

the variable 'n2' is generally 5 in length, and the variable n1 is generally around 10^6 in length. when I compile without OpenMP pragmas (v11.7). I get a compiler message that looks like this:

55, Generated vector sse code for the loop
Generated 2 prefetch instructions for the loop
Residual loop unrolled 1 times (completely unrolled)

so the compiler is vectorizing the outer-most loop. However when I add OpenMP pragmas around the outermost loop I get the following message:

52, Parallel region activated
55, Parallel loop activated with static block schedule
57, Loop not vectorized: loop count too small
Loop unrolled 5 times (completely unrolled)

These messages lead me to believe that the compiler will vectorize OR parallelize the loop, but not both. In other words, it does not parallelize the loop and then vectorize what gets executed on each thread. If this is true, it would mean that I am losing the benefits of vectorization when running under OpenMP.

can anyone confirm this, and if it is true, suggest a workaround?
Back to top
View user's profile
mkcolg



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

PostPosted: Tue Oct 23, 2012 10:47 am    Post subject: Reply with quote

Hi jwaltz,

We've been unsuccessful in recreating your issue so don't have an answer for you. Can you please either post or send to PGI Customer Service (trs@pgroup.com) a reproducing example?

Thanks,
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