12.07.2015 Views

NVIDIA CUDA

NVIDIA CUDA

NVIDIA CUDA

SHOW MORE
SHOW LESS
  • No tags were found...

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

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

3.25 Memory Management 1273.25 Memory ManagementFunctions• CUresult cuArray3DCreate (CUarray ∗pHandle, const <strong>CUDA</strong>_ARRAY3D_DESCRIPTOR ∗pDesc)Creates a 3D <strong>CUDA</strong> array.• CUresult cuArray3DGetDescriptor (<strong>CUDA</strong>_ARRAY3D_DESCRIPTOR ∗pDesc, CUarray hArray)Get a 3D <strong>CUDA</strong> array descriptor.• CUresult cuArrayCreate (CUarray ∗pHandle, const <strong>CUDA</strong>_ARRAY_DESCRIPTOR ∗pDesc)Creates a 1D or 2D <strong>CUDA</strong> array.• CUresult cuArrayDestroy (CUarray pArray)Destroys a <strong>CUDA</strong> array.• CUresult cuArrayGetDescriptor (<strong>CUDA</strong>_ARRAY_DESCRIPTOR ∗pDesc, CUarray hArray)Get a 1D or 2D <strong>CUDA</strong> array descriptor.• CUresult cuMemAlloc (CUdeviceptr ∗dptr, unsigned int bytesize)Allocates device memory.• CUresult cuMemAllocHost (void ∗∗pp, unsigned int bytesize)Allocates page-locked host memory.• CUresult cuMemAllocPitch (CUdeviceptr ∗dptr, unsigned int ∗pPitch, unsigned int WidthInBytes, unsigned intHeight, unsigned int ElementSizeBytes)Allocates pitched device memory.• CUresult cuMemcpy2D (const <strong>CUDA</strong>_MEMCPY2D ∗pCopy)Copies memory for 2D arrays.• CUresult cuMemcpy2DAsync (const <strong>CUDA</strong>_MEMCPY2D ∗pCopy, CUstream hStream)Copies memory for 2D arrays.• CUresult cuMemcpy2DUnaligned (const <strong>CUDA</strong>_MEMCPY2D ∗pCopy)Copies memory for 2D arrays.• CUresult cuMemcpy3D (const <strong>CUDA</strong>_MEMCPY3D ∗pCopy)Copies memory for 3D arrays.• CUresult cuMemcpy3DAsync (const <strong>CUDA</strong>_MEMCPY3D ∗pCopy, CUstream hStream)Copies memory for 3D arrays.• CUresult cuMemcpyAtoA (CUarray hDst, unsigned int DstOffset, CUarray hSrc, unsigned int SrcOffset, unsignedint NumBytes)Copies memory from Array to Array.• CUresult cuMemcpyAtoD (CUdeviceptr dptr, CUarray hSrc, unsigned int SrcOffset, unsigned int NumBytes)Copies memory from Array to Device.Generated on Wed Apr 1 16:11:42 2009 for <strong>NVIDIA</strong> <strong>CUDA</strong> Library by Doxygen

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

Saved successfully!

Ooh no, something went wrong!