 	int lid = int (gl_LocalInvocationIndex);
 	int offset = 1;
 	
-	temp[2 * lid] = data[2 * gid];
-	temp[2 * lid + 1] = data[2 * gid + 1];
+	int ai = lid;
+	int bi = lid + (n/2);
+	
+	int bankOffsetA = CONFLICT_FREE_OFFSET(ai);
+	int bankOffsetB = CONFLICT_FREE_OFFSET(bi);
+	
+	temp[ai + bankOffsetA] = data[gid];
+	temp[bi + bankOffsetB] = data[gid + (n/2)];
 	
 	for (int d = n >> 1; d > 0; d >>= 1)
 	{

	barrier ();
	memoryBarrierShared ();
	
	data[2 * gid] = temp[2 * lid];
	data[2 * gid + 1] = temp[2 * lid + 1];
}

	
	if (lid == 0)
	{
		blocksums[gl_WorkGroupID.x] = temp[n - 1 + CONFLICT_FREE_OFFSET(n-1)];
		temp[n - 1 + CONFLICT_FREE_OFFSET(n-1)] = 0;
	}
	
	for (int d = 1; d < n; d *= 2)
