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.

Data Copies<br />

cudaMemcpy(void *dst, void *src, size_t nbytes,<br />

enum cudaMemcpyKind direction);<br />

direction specifies locations (host or device) of src<br />

and dst<br />

Blocks CPU thread: returns after the copy is complete<br />

Doesn’t start copying until previous <strong>CUDA</strong> calls<br />

complete<br />

enum cudaMemcpyKind<br />

cudaMemcpyHostToDevice<br />

cudaMemcpyDeviceToHost<br />

cudaMemcpyDeviceToDevice<br />

© 2008 NVIDIA Corporation.

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

Saved successfully!

Ooh no, something went wrong!