PGI User Forum
 SearchSearch   MemberlistMemberlist     RegisterRegister   ProfileProfile    Log inLog in 

CUDA-x86.

WRITE in CUDA Fortran device code

 
Post new topic   Reply to topic    PGI User Forum Forum Index -> Accelerator Programming
View previous topic :: View next topic  
Author Message
youngsung



Joined: 15 Feb 2012
Posts: 2

PostPosted: Thu Mar 14, 2013 2:53 pm    Post subject: WRITE in CUDA Fortran device code Reply with quote

Hi,

I am trying to convert a bunch of legacy Fortran codes to CUDA Fortran. One of difficulties on the conversion is to handle WRITE statements in legacy codes. CUDA Fortran 12.10, which I can use, only allow PRINT * or WRITE(*,*), but there are many cases that I have to support WRITE(unit#, format) var1, var2, ... I wonder that anyone has already encountered this situation and found a proper solution?

Thanks,
Back to top
View user's profile
mkcolg



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

PostPosted: Thu Mar 14, 2013 4:56 pm    Post subject: Reply with quote

I'm assuming that you're writing from within a kernel? No, there isn't yet the facilities to perform formatted I/O from the device nor attach to a specific unit.

Note that printing from a kernel will severely limit your performance.

- Mat
Back to top
View user's profile
youngsung



Joined: 15 Feb 2012
Posts: 2

PostPosted: Thu Mar 14, 2013 7:50 pm    Post subject: Reply with quote

Actually, computation speed in kernel is not a matter in this case because it is a part of research regarding the micro-architecture of GPU and accuracy of computation. Thanks for the quick reply, though.
Back to top
View user's profile
Display posts from previous:   
Post new topic   Reply to topic    PGI User Forum Forum Index -> Accelerator Programming 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