rsnemmen / OpenCL-examples

Simple OpenCL examples for exploiting GPU computing
187 stars 70 forks source link
c examples gpu gpu-computing numerical-calculations opencl opencl-device

Simple examples of OpenCL code

Simple examples of OpenCL code, which I am using to learn heterogeneous and GPU computing with OpenCL.

Examples included

The examples that clearly demonstrate the computational advantage of using a GPU for processing are N-BodySimulation, RayTraced_Quaternion_Julia-Set_Example (both developed by Apple programmers) and auger. For auger, I got impressive speedups of >200x compared to a serial code on the CPU.

Info about OpenCL devices

To learn about your OpenCL devices, try:

clinfo

To install clinfo on MacOS:

brew install homebrew/science/clinfo

References

Slides

Code walkthroughs

Courses

Donate

If you are really happy with these examples, you can buy me a beer. Perhaps I could create a similar repo with CUDA examples?

TODO