I want to count some array which have 40000 items. But I'm thinking of it like 2 dimensional(200x200). So I set the globalThreads = 200;
localThreads = 200. Then using the simple logic, I calculating index in kernel like:
uint tid = get_global_id(0);
uint lid = get_local_id(0);
const uint range=200;
But seems that it wrong idea. What's wrong in my logic?