PGI User Forum
 SearchSearch   MemberlistMemberlist     RegisterRegister   ProfileProfile    Log inLog in 

Free OpenACC Webinar

#pragma accel command and loops

 
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: Wed Sep 21, 2011 12:06 pm    Post subject: #pragma accel command and loops Reply with quote

When you use the #pragma accel command in front of a loop - how many loops does it affect? If there are nested loops then of course all nested loops are affected.

But, what if there are two serial loops that are independent, but come one after the other and both inside c brackets after the

#pragma accel

command? It seems thta it affects them also.

THX 1138
Back to top
View user's profile
jtull



Joined: 30 Jun 2004
Posts: 445

PostPosted: Wed Sep 21, 2011 3:32 pm    Post subject: Answer to the scope of accelerator commands Reply with quote

Page 93 User's Guide 'C Directives'
==========================================================
An Accelerator directive applies to the immediately following structured block or loop.
==========================================================

Page 87
==========================================================
Structured block
in C, an executable statement, possibly compound, with a single entry at the top and a single exit at the
bottom. In Fortran, a block of executable statements with a single entry at the top and a single exit at the
bottom.
==========================================================
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