Coder Social home page Coder Social logo

gocl's Introduction

gocl

Go OpenCL (GOCL) Binding (http://www.gocl.org)

Library documentation:

http://www.khronos.org/registry/cl/sdk/1.1/docs/man/xhtml/

http://www.khronos.org/registry/cl/sdk/1.2/docs/man/xhtml/

http://www.khronos.org/registry/cl/sdk/2.0/docs/man/xhtml/

In order to build this, make sure you have the required drivers and SDK installed for your graphics card. You will need at least opencl.lib from Intel/AMD/NVIDIA:

http://software.intel.com/en-us/intel-opencl

http://developer.amd.com/tools-and-sdks/opencl-zone/

https://developer.nvidia.com/opencl

The locations of the library and include file can be supplied by way of environment variables, for example:

export CGO_LDFLAGS=-L$OPENCLSDKROOT/lib/x86 (or null for NVIDIA and Mac OSX)

export CGO_CFLAGS=-I$GOPATH/src/gocl/android/include (gocl/android/include/CL have the latest OpenCL 2.0 include files from https://www.khronos.org/registry/cl/)

===============================================

To build OpenCL 1.1/1.2/2.0 compliance C-style binding (replacing "clxx" with "cl11"/"cl12"/"cl20"):

go build -tags="clxx" gocl/cl

go test -v -tags="clxx" gocl/cl_test

go install -tags="cl11" gocl/cl_demo/opencl11/ch(x) (Examples in "OpenCL in Action")

go install -tags="cl12" gocl/cl_demo/opencl12/chapter(x) (Examples in "Heterogeneous Computing with OpenCL, 2nd Edition")

go install -tags="cl20" gocl/cl_demo/opencl20/x (Examples in "AMDAPPSDK and INTELOCLSDK")

===============================================

To build OpenCL 1.1/1.2/2.0 compliance OO-style binding (replacing "clxx" with "cl11"/"cl12"/"cl20"):

go build -tags="clxx" gocl/ocl

go test -v -tags="clxx" gocl/ocl_test

gocl's People

Contributors

rainliu avatar oliverbrandt avatar jolan avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.