PGI User Forum
 SearchSearch   MemberlistMemberlist     RegisterRegister   ProfileProfile    Log inLog in 

Free OpenACC Webinar

atomicadd for double precision in CUDA Fortran
Goto page 1, 2, 3, 4, 5  Next
 
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling
View previous topic :: View next topic  
Author Message
tlstar



Joined: 31 Mar 2011
Posts: 22

PostPosted: Tue Apr 05, 2011 6:55 am    Post subject: atomicadd for double precision in CUDA Fortran Reply with quote

atomicadd support integer type only in cuda pgfortran.
But it is important to me in coding on a Monte Carlo code.

How to realize it? Anyone has tried?

1. I try to use CUDA C (which support atomicadd for float values now) as extern function, but "PGF90-S-0155-Calls from device code to a host function are allowed only in emulation mode - atomicdadd"

2. Also atomicexch in pgfortran do not support float values, which are used in old version of CUDA C.

I almost finish the code implantation for GPU (1000+ lines), but it block me.

Thanks in advance. Hope pgfortran work fast for cuda!

gfwang
Back to top
View user's profile
mkcolg



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

PostPosted: Tue Apr 05, 2011 9:08 am    Post subject: Reply with quote

Hi gfwang,

I added a feature request (TPR#17778). Hopefully we can add them soon.

- Mat
Back to top
View user's profile
tlstar



Joined: 31 Mar 2011
Posts: 22

PostPosted: Tue Apr 05, 2011 10:31 am    Post subject: Reply with quote

... ...

I hope I could wait ...

NOTE: your trial license will expire in 9 days, 6.72 hours.

The trail license could be refilled?

My original plan is to advise the lab to buy it with this demonstration code,
though we really have so many compilers -- pathscale, ifort ...

Is there anyway to mimic this function?
Back to top
View user's profile
mkcolg



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

PostPosted: Tue Apr 05, 2011 10:49 am    Post subject: Reply with quote

Quote:
The trail license could be refilled?
Yes. Send a note to Sales (sales@pgroup.com), they can reset trial licenses or extend a longer term Demo license.

Quote:
we really have so many compilers
Every compiler has it's pluses and minus. Having multiple vendors ensures you have the best option for the particular need at hand. PGI is both strong in CPU performance and has taken the lead in GPU programing. Being independent from the architectures we target allows us to work on the current state of the art HPC architectures, whether that be AMD, Intel, NVIDIA, or what ever the future holds.

Quote:
Is there anyway to mimic this function?
I don't think so, but I'll double check.

- Mat
Back to top
View user's profile
tlstar



Joined: 31 Mar 2011
Posts: 22

PostPosted: Wed Apr 06, 2011 1:27 am    Post subject: Reply with quote

Thanks a lot!
I'm considering to change the algorithm, let CPU do this job. Atomic operation may be expensive.

Quote:
Every compiler has it's pluses and minus. Having multiple vendors ensures you have the best option for the particular need at hand. PGI is both strong in CPU performance and has taken the lead in GPU programing. Being independent from the architectures we target allows us to work on the current state of the art HPC architectures, whether that be AMD, Intel, NVIDIA, or what ever the future holds.


Yes. PGFORTRAN is the only compiler supporting cuda nowaday. And lots scientific computation codes are written in fortran.


I hope PGFORTRAN could develop supportings for CUDA faster.
For example:

1. support multi Modules for global & device subroutines

2. minor request -- support character strings in emu mode.
It would be interesting for me to do handy debug.

In emu mode (-Mcuda=emu), I/O are supported by pgfortran:
PGF90-W-0155-I/O statements allowed in device routines only in emulation mode
But it do not support character strings also:
PGF90-S-0155-CUDA device routines do not support character strings with length > 1
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
Goto page 1, 2, 3, 4, 5  Next
Page 1 of 5

 
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