is not the same as
a[id*10+i] = b[id*10+i];
you probably intended:
next time paste the actual code, this is obivously not even going to compile with ; in the argument lists, and missing characters.
BTW this is not a very good solution: check the bits of any opencl guide/book which talks about memory coalescing. Also look at related memory copying examples in the sdks.
if there is any memory copying examples in the sdk?
Yes there are. And the amd opencl programming guide goes into memory issues in excruciating detail, e.g. chapter 4.6.