Skip to content

Instantly share code, notes, and snippets.

@arsenm
Created August 11, 2011 23:56
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 arsenm/1141113 to your computer and use it in GitHub Desktop.
Save arsenm/1141113 to your computer and use it in GitHub Desktop.
AMD OpenCL compiler crash test case
__kernel void broken(__global double* _x,
__global double* _y,
__global int* debug,
int missing)
{
int k = get_global_id(0);
while (k < 100)
{
//double x = _x[k];
if (missing == 0)
{
double z = sqrt(3.3);
/*
// I thought this was related, but it apparently isn't
if (z != z)
{
//atom_inc(&debug[0]);
}
*/
}
//k += get_local_size(0) * get_num_groups(0);
}
// _y[get_global_id(0)] = z;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment