Does Nvidia GPUs support pipe like structures? - opencl

I am trying to write OpenCL code that takes advantage of the latest OpenCL 2.0 features like pipes. I have been working on AMD GPUs until now and they support pipes. But Nvidia driver doesnt support OpenCL 2.0. So are there any pipe like structures available for Nvidia GPUs? My intention is to transfer data directly between 2 kernels instead of passing it via global memory. So anything that helps me do this can be used.

I'm not aware of any. Do contact NVIDIA and let them know you'd like to see OpenCL 2.0 support.

Related

How to use Flux.jl on an AMD GPU?

I currently do not have an Nvidia GPU on my laptop but I still want to be able to speed up training. Per the Flux docs, it says Nvidia GPU's are supported out of the box but doesn't mention AMD GPU's at all. Is it possible to work with Flux on an AMD GPU?
This should in principle be possible, since AMDGPU.jl provides a similar interface for AMD GPUs as CUDA.jl does for NVIDIA GPUs, and Flux is claimed to be agnostic to array types. However, at best this will only work on Linux, since AMDGPU.jl relies on AMD's ROCm platform, and ROCm is only supported on Linux, since ROCm is indeed specifically built around the Linux kernel.

Stop OpenCL support for a GPU

I have two GPUs installed on my machine. I am working with library which uses OpenCL acceleration that only support one GPU and it is not configurable. I can not tell it which one I want. It seems that this library for some reason chose one of my GPUs that I do not want.
How can I delete/stop/deactivate this GPU from being supported as an OpenCL device?
I want to do this so I get only one supported GPU and the library will be forced to use it.
Note: Any option that contains change or edit the library is available for me.
P.S. I am on Windows 10 with Intel processor and Intel GPU + NVidia GPU
On Windows the OpenCL ICD system uses Registry entries to find all of the installed OpenCL platforms.
Solution: Using RegEdit you can backup and then remove the entry for the GPU you do not want to use. The Registry location is HKEY_LOCAL_MACHINE\SOFTWARE\Khronos\OpenCL\Vendors.
Reference: https://www.khronos.org/registry/cl/extensions/khr/cl_khr_icd.txt

OpenCL 2.0 on nVIDIA Graphics cards

I want to use OpenCL 2.0 because it benefit from very nice features like Creating Sub Devices, or Shared Virtual Memory but my OpenCL header files which are coming out with nvidia cuda does not have the opencl 2.0 functions. Is there any way to use OpenCL 2.0 on my nvidia gpus?
In the 378.66 drivers NVIDIA claims limited support of OpenCL 2.0 for evaluation purposes. Look at page 10 of release notes http://us.download.nvidia.com/Windows/378.66/378.66-win10-win8-win7-desktop-release-notes.pdf
Unfortunately not - NVIDIA does not currently support OpenCL 2.0, and they have not yet given any timeframe for doing so.

How to handle OpenCL code on unsupported hardware in a C++ app

I've been doing some research in to OpenCL, and the possibility of using it on a project. The question I have is, is there a way to run OpenCL code on a CPU that is unsupported by the OpenCL SDKs in a C++ application. I know Java has Aparapi, however I'm wondering how to run OpenCL code in a C++ application without hardware that is supported by the SDKs. There is some code I would like to write in OpenCL kernels to take advantage of the OpenCL parallelism where available, however I'm unsure if I wouldn't be able to run it on older hardware (still X86, but not recent hardware). Could anyone explain to me how this can be done, or if it is even a problem at all to run OpenCL code on older systems?
Thanks,
Peter
I would say best way to approach this is to check if the device supports OpenCL via OpenCL API calls such as clPlatformIDs then once you figure it isn't a OpenCL device then run the required code as normal C/C++ function otherwise run it using openCL kernel. But for portability you need to write the program logic twice once in .cl file and once as normal c/c++ method/function.

Need to install opencl for CPU and GPU platforms?

I have a system with an NVidia graphics card and I'm looking at using openCL to replace openMP for some small on CPU tasks (thanks to VS2010 making openMP useless)
Since I have NVidia's opencl SDK installed clGetPlatformIDs() only returns a single platform (NVidia's) and so only a single device (the GPU).
Do I need to also install Intel's openCL sdk to get access to the CPU platform?
Shouldn't the CPU platform always be available - I mean, how do you NOT have a cpu?
How do you manage to build against two openCL SDKs simultaneously?
You need to have a SDK which provides interface to CPU. nVidia does not, AMD and Intel's SDKs do; in my case the one from Intel is significantly (something like 10x) faster, which might due to bad programming on my part however.
You don't need the SDK for programs to run, just the runtime. In Linux, each vendor installs a file in /etc/OpenCL/vendors/*.icd, which contains path of the runtime library to use. That is scanned by the OpenCL runtime you link to (libOpenCL.so), which then calls each of the vendor's libs when querying for devices on that particular platform.
In Linux, the GPU drivers install OpenCL runtime automatically, the Intel runtime is likely to be downloadable separately from the SDK, but is part of the SDK as well, of course.
Today i finally got around to trying to start doing openCl development and wow... it is not straight forward at all.
There's an AMD sdk, there's an intel sdk, there's an nvidia sdk, each with their own properties (CPU only vs GPU only vs specific video card support only perhaps?)
There may be valid technical reasons for it having to be this way but i really wish there was just one sdk, and that when programming perhaps you could specify GPU / CPU tasks, or that maybe it would use whatever resources made most sense / preformed best or SOMETHING.
Time to dive in though I guess... trying to decide though if i go CPU or GPU. I have a pretty new 4000$ alienware laptop with SLI video cards, but then also an 8 core cpu so yeah... guess ill have to try a couple sdk's and see which preforms best for my needs?
Not sure what end users of my applications would do though... it doesnt seem like they can flip a switch to make it run on cpu or gpu instead.
The OpenCL landscape really needs some help...

Resources