Skip to content

Instantly share code, notes, and snippets.

@PontiacGTX
Created June 19, 2019 18:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save PontiacGTX/1fd84040c421d4b8fac2278e3d23255e to your computer and use it in GitHub Desktop.
Save PontiacGTX/1fd84040c421d4b8fac2278e3d23255e to your computer and use it in GitHub Desktop.
__kernel void Add(float limit,__global unsigned char* arr)
{
for(float i=0;i<limit;i++)
{
arr[(int)i]=(char)i;
}
}
__kernel void CopyBytes(__global unsigned char* fileBytes,__global unsigned long* arraySize,__global unsigned char* compressedBytes, __global unsigned long* arrayCountCompressedBytes)
{
for(unsigned long i=0;i<=*arraySize;i++)
{
*(compressedBytes+i)=*(fileBytes+i);
*(arrayCountCompressedBytes+i)=i;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment