|Home > OpenCL concepts > OpenCL work-groups|
Work-groups have several properties, limitations and work-items:
Work-groups typically do not directly share data. They can share data using global memory.
The following are not supported across different work-groups:
Global atomics are available but these can be slower than local atomics.
The work-items in a work-group can:
Perform barrier operations to synchronize execution points.
barrier(CLK_LOCAL_MEM_FENCE); // Wait for all work-items in // this work-group to catch up
After the synchronization is complete, all writes to shared buffers are guaranteed to have been completed. It is then safe for work-items to read data written by different work-items within the same work-group.