dheevatsa

atom_add on 5870 with Stream SDK 2.0beta4

Discussion created by dheevatsa on Jan 21, 2010
Latest reply on Jan 27, 2010 by fulcrum_xyz

I am not able to compile a kernel file (mykernel.cl) usign atom_add.

#pragma OPENCL EXTENSION cl_khr_global_int32_base_atomics : enable
#pragma OPENCL EXTENSION cl_khr_local_int32_base_atomics : enable

 

__kernel mykernel ()

{

    __local int * ptr;

    atom_add (ptr, 1);

}

 

This doesn't work any reason why ?? Am i missing out on something here !!

Outcomes