import opencl_course source for a start

This commit is contained in:
erwin coumans
2013-03-11 22:03:27 +01:00
commit 08272c7de5
64 changed files with 12336 additions and 0 deletions

View File

@@ -0,0 +1,16 @@
__kernel void VectorAdd(__global const float8* a, __global const float8* b, __global float8* c, int numElements)
{
// get oct-float index into global data array
int iGID = get_global_id(0);
if (iGID>=numElements)
return;
float8 aGID = a[iGID];
float8 bGID = b[iGID];
float8 result = aGID + bGID;
// write back out to GMEM
c[iGID] = result;
}