06.08.2012 Views

Getting Started with CUDA

Getting Started with CUDA

Getting Started with CUDA

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

GPU Thread Synchronization<br />

void __syncthreads();<br />

Synchronizes all threads in a block<br />

Generates barrier synchronization instruction<br />

No thread can pass this barrier until all threads in the<br />

block reach it<br />

Used to avoid RAW / WAR / WAW hazards when<br />

accessing shared memory<br />

Allowed in conditional code only if the conditional<br />

is uniform across the entire thread block<br />

© 2008 NVIDIA Corporation.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!