A nice starter kit for OpenCL? [closed]

2019-04-06 14:57发布

问题:

I've got some experience with OpenGL and it's programmable pipeline. I'd like to give OpenCL a try, though.

Could somebody propose a nice integrated kit for working with OpenCL?

I know only of QuartzComposer which looks nice, but it's mac-only. Anyone knows if it supports hand-editing of OpenCL kernels or is it all only through the GUI?

Any other Linux / Windows alternative?

回答1:

Quartz Composer does have an OpenCL "patch," in which you can hand-edit your kernel. It's a pretty nice way to experiment with stuff like CL-based vertex or color generation, which you can then display on subsequent patches. Once you get something working there, you can usually make the jump to pure C/C++ code that utilizes the CL/GL interop facilities of your platform.

Using CL as above will definitely give you a feel for the OpenCL C language. You will still need to learn about the OpenCL runtime facilities, however.



回答2:

OpenCL Studio

OpenCL studio hides much of the boiler plate code you would have to write by providing a Lua based infrastructure -- read as: for the host code (the code running on the CPU) you can code in Lua. It furthermore comes with a bunch of examples. The GUI feels sometimes a bit hacked. I also didn't find much help/documentation on how to use the software itself. All in all I think it dramatically reduces the learning effort of OpenCL.



回答3:

(Disclaimer: I'm the developer of OpenCLHelper).

I'm not sure exactly what your requirements are, ie if you're looking for an IDE for OpenCL, complete with debugger and so on, then you can stop reading this reply.

However, if what you want is a way of using OpenCL with much less boilerplate, and which makes it easy to load kernels, and pass arguments to them, then you might consider OpenCLHelper

https://github.com/hughperkins/OpenCLHelper

OpenCLHelper:

  • handles much of the boilerplate of initializing OpenCL, locating devices, creating queues
  • makes it easy to pass arguments to, and receive arguments from, a kernel
  • uses clew, so that binding to OpenCL is at runtime, just in case you need OpenCL to be an optional part of your program, rather than mandatory at runtime
  • makes it relatively painless to take data from one kernel, and provide it to the next, without moving it back and forwards between GPU and PC memory


回答4:

For Windows (Vista, 7) try VS2010 C++ Express

http://www.microsoft.com/visualstudio/en-us/products/2010-editions/visual-cpp-express

with the AMD App SDK

http://developer.amd.com/sdks/AMDAPPSDK/downloads/Pages/default.aspx

There are lots of OpenCL examples. It installs and runs on any Intel x86 or x64 CPU made in the last 7 years.



回答5:

Some options are

AMD APP SDK

AMD APP SDK comes with OpenCL compiler, Profiler, Kernel Analyzer. You can also try AMD gDEBugger which is probably the best you can get for OpenCL GPU debugging compared to NVIDIA and Intel.

NVIDIA OpenCL pack

NVIDIA OpenCL pack you can sign up and download opencl samples, Nsight, Visual profiler etc.

Intel OpenCL SDK

Intel OpenCL SDK is another option if you would like to run your programs on Sandybridge processors.

COPRTHR SDK

Brown deer technology has COPRTHR SDK which contains rich set of OpenCL libraries.

Multicoreare Tools

Another option is Multicoreare Tools which combines CUDA/OpenCL, Pyon and DSL Code and generates ISA for the underlaying hardware.



标签: ide opencl