[arch-dev-public] Opencl/Cuda headers
Since version 260.19.12, upstream developers of nvidia-utils dropped C headers for OpenCL and Cuda. After a discussion with Ionuț on IRC, we agreed that it would be good to ask other developers on the best way to provide these headers. For those unfamiliar with these programming languages/libraries, there are part of the so-called GPGPU technologies (General-Purpose Processing on Graphical Processing Unit), where the primary objective is to perform any type of parallel computing on graphics processors. For example, I am using OpenCL in a personal programming project to speed up a partial differential equation solver. OpenCL is an open standard that has been recently (May 2009) ratified by The Khronos Group. C for Cuda is a similar proprietary solutions from Nvidia. Nvidia-utils contains the dynamic libraries for both OpenCL and Cuda. Other vendors, like AMD and Intel, provide or will provide soon an implementation of OpenCL for their GPUs. To get a satisfactory OpenCL developement environment, it could be as simple as creating a new package that provide the header files. These headers can be either downloaded from The Khronos Group[1] (like this [2]) or extracted from the Nividia toolkit[3]. However, for Cuda, it might be a little more complicated because it must use a compiler provided by nvidia (nvcc). A solution may be to create a package for the Cuda Toolkit. The main disadvantage of this solution is the addition of proprietary software for which we can only provide limited support in case of bugs or incompatibility with other updates. According to the maintainer of the Cuda package in AUR [4], Cuda requires gcc version 4.4 (it is broken with version 4.5) and sometimes releases depend on beta drivers[5]. I think it is probably better to wait until these dependency problems are fixed before thinking about inclusion in [extra] or [community]. My suggestion would be to package only OpenCL headers (Khronos version) and eventually discuss addition of Cuda if it becomes easier to maintain in a rolling release distribution. The new "khronos-opencl-headers" package could be added as optional dependencies for nvidia-utils which will also include a "provides=('libCL')"[6]. I tested this solution on several codes and it works well. It also seems that Debian is going to do something very similar[7]. So what do other people think about this problem ? Stéphane [1] http://www.khronos.org/registry/cl [2] http://aur.archlinux.org/packages.php?ID=35367 [3] http://developer.nvidia.com/object/cuda_3_2_toolkit_rc.html [4] http://aur.archlinux.org/packages.php?ID=3D23597 [5] Personnal communication [6] cf. FS#20558 [7] http://ftp-master.debian.org/new/khronos-opencl- headers_1.0-2010.06.13-1.html
On 10/30/2010 07:45 AM, Stéphane Gaudreault wrote:
My suggestion would be to package only OpenCL headers (Khronos version) and eventually discuss addition of Cuda if it becomes easier to maintain in a rolling release distribution. The new "khronos-opencl-headers" package could be added as optional dependencies for nvidia-utils which will also include a "provides=('libCL')"[6]. I tested this solution on several codes and it works well. It also seems that Debian is going to do something very similar[7].
So what do other people think about this problem ?
Stéphane
imo khronos-opencl-headers is not a good name for our package. can we have opencl-headers or nvidia-opencl-headers if the headers for the opensource drivers are not compatible with them? -- Ionuț
Le samedi 30 octobre 2010 07:02:08, Ionuț Bîru a écrit :
On 10/30/2010 07:45 AM, Stéphane Gaudreault wrote:
My suggestion would be to package only OpenCL headers (Khronos version) and eventually discuss addition of Cuda if it becomes easier to maintain in a rolling release distribution. The new "khronos-opencl-headers" package could be added as optional dependencies for nvidia-utils which will also include a "provides=('libCL')"[6]. I tested this solution on several codes and it works well. It also seems that Debian is going to do something very similar[7].
So what do other people think about this problem ?
Stéphane
imo khronos-opencl-headers is not a good name for our package. can we have opencl-headers or nvidia-opencl-headers if the headers for the opensource drivers are not compatible with them?
Since headers from both sources are almost the same (modulo some comments), it does not matter which one we choose. Following your suggestion, I uploaded an nvidia-opencl-headers package on AUR: http://aur.archlinux.org/packages.php?ID=42430 This may not be the final package, but it is probably easier to discuss around something concrete :-) Stéphane
Le samedi 30 octobre 2010 14:12:25, Stéphane Gaudreault a écrit :
Le samedi 30 octobre 2010 07:02:08, Ionuț Bîru a écrit :
On 10/30/2010 07:45 AM, Stéphane Gaudreault wrote:
My suggestion would be to package only OpenCL headers (Khronos version) and eventually discuss addition of Cuda if it becomes easier to maintain in a rolling release distribution. The new "khronos-opencl-headers" package could be added as optional dependencies for nvidia-utils which will also include a "provides=('libCL')"[6]. I tested this solution on several codes and it works well. It also seems that Debian is going to do something very similar[7].
So what do other people think about this problem ?
Stéphane
imo khronos-opencl-headers is not a good name for our package. can we have opencl-headers or nvidia-opencl-headers if the headers for the opensource drivers are not compatible with them?
Since headers from both sources are almost the same (modulo some comments), it does not matter which one we choose. Following your suggestion, I uploaded an nvidia-opencl-headers package on AUR:
http://aur.archlinux.org/packages.php?ID=42430
This may not be the final package, but it is probably easier to discuss around something concrete :-)
Stéphane
If there is no objection, I will upload the new package tomorrow. Ionuț : Would it be possible to add opencl in the provides line of nvidia- utils please? This will close FS#20558. Thanks, Stéphane
On 11/01/2010 04:55 PM, Stéphane Gaudreault wrote:
Le samedi 30 octobre 2010 14:12:25, Stéphane Gaudreault a écrit :
Le samedi 30 octobre 2010 07:02:08, Ionuț Bîru a écrit :
On 10/30/2010 07:45 AM, Stéphane Gaudreault wrote:
My suggestion would be to package only OpenCL headers (Khronos version) and eventually discuss addition of Cuda if it becomes easier to maintain in a rolling release distribution. The new "khronos-opencl-headers" package could be added as optional dependencies for nvidia-utils which will also include a "provides=('libCL')"[6]. I tested this solution on several codes and it works well. It also seems that Debian is going to do something very similar[7].
So what do other people think about this problem ?
Stéphane
imo khronos-opencl-headers is not a good name for our package. can we have opencl-headers or nvidia-opencl-headers if the headers for the opensource drivers are not compatible with them?
Since headers from both sources are almost the same (modulo some comments), it does not matter which one we choose. Following your suggestion, I uploaded an nvidia-opencl-headers package on AUR:
http://aur.archlinux.org/packages.php?ID=42430
This may not be the final package, but it is probably easier to discuss around something concrete :-)
Stéphane
If there is no objection, I will upload the new package tomorrow.
Ionuț : Would it be possible to add opencl in the provides line of nvidia- utils please? This will close FS#20558.
Thanks,
Stéphane
the bug suggest to use libcl. we are settle to use opencl from know own and nvidia-opencl-headers as optional dependency? -- Ionuț
Le lundi 01 novembre 2010 11:55:14, Ionuț Bîru a écrit :
On 11/01/2010 04:55 PM, Stéphane Gaudreault wrote:
Le samedi 30 octobre 2010 14:12:25, Stéphane Gaudreault a écrit :
Le samedi 30 octobre 2010 07:02:08, Ionuț Bîru a écrit :
On 10/30/2010 07:45 AM, Stéphane Gaudreault wrote:
My suggestion would be to package only OpenCL headers (Khronos version) and eventually discuss addition of Cuda if it becomes easier to maintain in a rolling release distribution. The new "khronos-opencl-headers" package could be added as optional dependencies for nvidia-utils which will also include a "provides=('libCL')"[6]. I tested this solution on several codes and it works well. It also seems that Debian is going to do something very similar[7].
So what do other people think about this problem ?
Stéphane
imo khronos-opencl-headers is not a good name for our package. can we have opencl-headers or nvidia-opencl-headers if the headers for the opensource drivers are not compatible with them?
Since headers from both sources are almost the same (modulo some comments), it does not matter which one we choose. Following your suggestion, I uploaded an nvidia-opencl-headers package on AUR:
http://aur.archlinux.org/packages.php?ID=42430
This may not be the final package, but it is probably easier to discuss around something concrete :-)
Stéphane
If there is no objection, I will upload the new package tomorrow.
Ionuț : Would it be possible to add opencl in the provides line of nvidia- utils please? This will close FS#20558.
Thanks,
Stéphane
the bug suggest to use libcl.
we are settle to use opencl from know own and nvidia-opencl-headers as optional dependency?
In the bug report I suggested to use libcl to mimic OpenGL (provides=(libgl)). It is probably clearer to use "opencl" instead. Nvidia-opencl-headers could be an optional depency. Stéphane
On 30 October 2010 12:45, Stéphane Gaudreault <stephane@archlinux.org> wrote:
The main disadvantage of this solution is the addition of proprietary software for which we can only provide limited support in case of bugs or incompatibility with other updates.
This won't likely be an issue. It's a given that no one should be expecting much assistance from the distribution in the event a package is of a proprietary nature. When a problem arises, just don't hold back anything else, which brings us to...
According to the maintainer of the Cuda package in AUR [4], Cuda requires gcc version 4.4 (it is broken with version 4.5) and sometimes releases depend on beta drivers[5]. I think it is probably better to wait until these dependency problems are fixed before thinking about inclusion in [extra] or [community].
Wait or don't wait, this has no long-term guarantee. It can break anytime. [extra] is definitely not a good place for it. The fact that random releases may depend on beta drivers convinces me to leave it in [unsupported], unless those drivers are brought in as well.
My suggestion would be to package only OpenCL headers (Khronos version) and eventually discuss addition of Cuda if it becomes easier to maintain in a rolling release distribution.
Yes, do that.
The new "khronos-opencl-headers" package could be added as optional dependencies for nvidia-utils which will also include a "provides=('libCL')"[6]. I tested this solution on several codes and it works well. It also seems that Debian is going to do something very similar[7].
Same here, I think a straightforward name would suffice. Also, it's unnecessary to have it as any kind of dependency.
-1 I'm against providing these packages. Gpu calculation not that widely used and we already have the libs in our repos to decode movies in hardware. I don't think we should mess our official repos with one/two more closed source packages when we have no real need for them! You should keep them in AUR or if they get enough votes bring them to community. -Andy
Le samedi 30 octobre 2010 00:45:58, Stéphane Gaudreault a écrit :
Since version 260.19.12, upstream developers of nvidia-utils dropped C headers for OpenCL and Cuda. After a discussion with Ionuț on IRC, we agreed that it would be good to ask other developers on the best way to provide these headers.
For those unfamiliar with these programming languages/libraries, there are part of the so-called GPGPU technologies (General-Purpose Processing on Graphical Processing Unit), where the primary objective is to perform any type of parallel computing on graphics processors. For example, I am using OpenCL in a personal programming project to speed up a partial differential equation solver. OpenCL is an open standard that has been recently (May 2009) ratified by The Khronos Group. C for Cuda is a similar proprietary solutions from Nvidia. Nvidia-utils contains the dynamic libraries for both OpenCL and Cuda. Other vendors, like AMD and Intel, provide or will provide soon an implementation of OpenCL for their GPUs.
To get a satisfactory OpenCL developement environment, it could be as simple as creating a new package that provide the header files. These headers can be either downloaded from The Khronos Group[1] (like this [2]) or extracted from the Nividia toolkit[3].
However, for Cuda, it might be a little more complicated because it must use a compiler provided by nvidia (nvcc). A solution may be to create a package for the Cuda Toolkit. The main disadvantage of this solution is the addition of proprietary software for which we can only provide limited support in case of bugs or incompatibility with other updates. According to the maintainer of the Cuda package in AUR [4], Cuda requires gcc version 4.4 (it is broken with version 4.5) and sometimes releases depend on beta drivers[5]. I think it is probably better to wait until these dependency problems are fixed before thinking about inclusion in [extra] or [community].
My suggestion would be to package only OpenCL headers (Khronos version) and eventually discuss addition of Cuda if it becomes easier to maintain in a rolling release distribution. The new "khronos-opencl-headers" package could be added as optional dependencies for nvidia-utils which will also include a "provides=('libCL')"[6]. I tested this solution on several codes and it works well. It also seems that Debian is going to do something very similar[7].
So what do other people think about this problem ?
Stéphane
[1] http://www.khronos.org/registry/cl [2] http://aur.archlinux.org/packages.php?ID=35367 [3] http://developer.nvidia.com/object/cuda_3_2_toolkit_rc.html [4] http://aur.archlinux.org/packages.php?ID=3D23597 [5] Personnal communication [6] cf. FS#20558 [7] http://ftp-master.debian.org/new/khronos-opencl- headers_1.0-2010.06.13-1.html
It seems the Cuda/OpenCL/vdpau headers are back in nvidia-utils version 260.19.21-1. Stéphane is happy again :-)
Le jeudi 11 novembre 2010 19:23:25, Stéphane Gaudreault a écrit :
Le samedi 30 octobre 2010 00:45:58, Stéphane Gaudreault a écrit :
Since version 260.19.12, upstream developers of nvidia-utils dropped C headers for OpenCL and Cuda. After a discussion with Ionuț on IRC, we agreed that it would be good to ask other developers on the best way to provide these headers.
For those unfamiliar with these programming languages/libraries, there are part of the so-called GPGPU technologies (General-Purpose Processing on Graphical Processing Unit), where the primary objective is to perform any type of parallel computing on graphics processors. For example, I am using OpenCL in a personal programming project to speed up a partial differential equation solver. OpenCL is an open standard that has been recently (May 2009) ratified by The Khronos Group. C for Cuda is a similar proprietary solutions from Nvidia. Nvidia-utils contains the dynamic libraries for both OpenCL and Cuda. Other vendors, like AMD and Intel, provide or will provide soon an implementation of OpenCL for their GPUs.
To get a satisfactory OpenCL developement environment, it could be as simple as creating a new package that provide the header files. These headers can be either downloaded from The Khronos Group[1] (like this [2]) or extracted from the Nividia toolkit[3].
However, for Cuda, it might be a little more complicated because it must use a compiler provided by nvidia (nvcc). A solution may be to create a package for the Cuda Toolkit. The main disadvantage of this solution is the addition of proprietary software for which we can only provide limited support in case of bugs or incompatibility with other updates. According to the maintainer of the Cuda package in AUR [4], Cuda requires gcc version 4.4 (it is broken with version 4.5) and sometimes releases depend on beta drivers[5]. I think it is probably better to wait until these dependency problems are fixed before thinking about inclusion in [extra] or [community].
My suggestion would be to package only OpenCL headers (Khronos version) and eventually discuss addition of Cuda if it becomes easier to maintain in a rolling release distribution. The new "khronos-opencl-headers" package could be added as optional dependencies for nvidia-utils which will also include a "provides=('libCL')"[6]. I tested this solution on several codes and it works well. It also seems that Debian is going to do something very similar[7].
So what do other people think about this problem ?
Stéphane
[1] http://www.khronos.org/registry/cl [2] http://aur.archlinux.org/packages.php?ID=35367 [3] http://developer.nvidia.com/object/cuda_3_2_toolkit_rc.html [4] http://aur.archlinux.org/packages.php?ID=3D23597 [5] Personnal communication [6] cf. FS#20558 [7] http://ftp-master.debian.org/new/khronos-opencl-
headers_1.0-2010.06.13-1.html
It seems the Cuda/OpenCL/vdpau headers are back in nvidia-utils version 260.19.21-1.
Stéphane is happy again :-)
Sorry for the noise, I was misled by a post on the Nvidia forum. The changelog still say (see bellow) that the headers are no longer packaged with the driver. Following the suggestion of Andreas, I will try to bring them to [community] if they get enough votes in AUR. Stéphane == NVIDIA_Changelog == [...] * Stopped packaging and installing OpenGL, VDPAU, CUDA, and OpenCL header files with the driver. Those interested in these files can get them from their Linux distributions' packages, where available, or upstream from: OpenGL header files (gl.h, glext.h glx.h, glxext.h): http://www.opengl.org/registry/ VDPAU header files (vdpau.h and vdpau_x11.h): http://freedesktop.org/wiki/Software/VDPAU CUDA and OpenCL header files (cuda.h, cudaGL.h, cudaVDPAU.h, cl.h, cl_gl.h, cl_platform.h): http://developer.nvidia.com/object/gpucomputing.html Note that while libvdpau.so is still included in 260.xx drivers, it will be removed from a future release series in early 2011. Distributors are encouraged to package libvdpau.so from http://freedesktop.org/wiki/Software/VDPAU
participants (4)
-
Andreas Radke
-
Ionuț Bîru
-
Ray Rashif
-
Stéphane Gaudreault