| View previous topic :: View next topic |
| Author |
Message |
Senya
Joined: 20 Jun 2011 Posts: 29
|
Posted: Wed Apr 24, 2013 10:25 am Post subject: Device routines must be in the same module as the caller |
|
|
I'm using 12.5 and try to use device function defined in module in another module.
Compiler says:
"Device routines called must be in the same module as the caller".
There is said, that in 11 release data made available through different modules. Do you have any progress on cross-module subroutines support? Do you support in newer compiler versions or maybe will support in future? |
|
| Back to top |
|
 |
mkcolg
Joined: 30 Jun 2004 Posts: 4996 Location: The Portland Group Inc.
|
Posted: Thu Apr 25, 2013 1:36 am Post subject: |
|
|
Hi Senya,
This was a limit in how the underlying NVIDIA CUDA tools worked. All device routines must be inlined and therefore contained within the same module as the caller. This restriction has been loosened with CUDA 5.0 and PGI CUDA Fortran 2013 where "relocatable device code" has been made available. To utilize this feature, please add "-Mcuda=rdc" to both your compilation and link.
Hope this helps,
Mat |
|
| Back to top |
|
 |
Senya
Joined: 20 Jun 2011 Posts: 29
|
Posted: Thu Apr 25, 2013 7:26 am Post subject: |
|
|
| Is there some special requirements for GPU to support this feature? |
|
| Back to top |
|
 |
mkcolg
Joined: 30 Jun 2004 Posts: 4996 Location: The Portland Group Inc.
|
Posted: Mon Apr 29, 2013 2:29 pm Post subject: |
|
|
Hi Senya,
rdc requires CUDA 5.0 and a device with compute capable 2.0 or greater.
- Mat |
|
| Back to top |
|
 |
Senya
Joined: 20 Jun 2011 Posts: 29
|
Posted: Mon May 06, 2013 5:38 am Post subject: |
|
|
| Thanks for help. |
|
| Back to top |
|
 |
|