1 2 3 4 5 6 7 8 9
#include "stdlib.h" struct big { int x[10]; }; __kernel void add(__global int *dst, unsigned int x, struct big b) { for (int i = 0; i < x; ++i) dst[get_local_id(0) + i]++; }