// _syncthreads() in CUDA
barrier(CLK_GLOBAL_MEM_FENCE);
- // Retrieve neighbors surplus and add them to the current cell population
+ // Retrieve neighbors surplus and add them to the current cell
+ // population
int surplus = OVERFLOW(world, overflows, i + 1, j) + OVERFLOW(world, overflows, i - 1, j) + OVERFLOW(world, overflows, i, j - 1) + OVERFLOW(world, overflows, i, j + 1);
CELL(world, newPopulations, i, j) = CELL(world, populations, i, j) + surplus / 8.0 - OVERFLOW(world, overflows, i, j);