Cuda Driver Api
Total Page:16
File Type:pdf, Size:1020Kb
CUDA DRIVER API TRM-06703-001 _v6.0 | February 2014 API Reference Manual TABLE OF CONTENTS Chapter 1. API synchronization behavior................................................................... 1 Chapter 2. Stream synchronization behavior.............................................................. 3 Chapter 3. Modules.............................................................................................. 4 3.1. Data types used by CUDA driver....................................................................... 5 CUDA_ARRAY3D_DESCRIPTOR...............................................................................5 CUDA_ARRAY_DESCRIPTOR.................................................................................. 5 CUDA_MEMCPY2D.............................................................................................5 CUDA_MEMCPY3D.............................................................................................5 CUDA_MEMCPY3D_PEER..................................................................................... 5 CUDA_POINTER_ATTRIBUTE_P2P_TOKENS................................................................ 5 CUDA_RESOURCE_DESC......................................................................................5 CUDA_RESOURCE_VIEW_DESC.............................................................................. 5 CUDA_TEXTURE_DESC....................................................................................... 5 CUdevprop.....................................................................................................5 CUipcEventHandle........................................................................................... 5 CUipcMemHandle.............................................................................................5 CUaddress_mode............................................................................................. 5 CUarray_cubemap_face..................................................................................... 6 CUarray_format.............................................................................................. 6 CUcomputemode............................................................................................. 7 CUctx_flags....................................................................................................7 CUdevice_attribute.......................................................................................... 8 CUevent_flags............................................................................................... 12 CUfilter_mode...............................................................................................13 CUfunc_cache............................................................................................... 13 CUfunction_attribute...................................................................................... 13 CUgraphicsMapResourceFlags............................................................................. 14 CUgraphicsRegisterFlags................................................................................... 14 CUipcMem_flags.............................................................................................14 CUjit_cacheMode........................................................................................... 15 CUjit_fallback............................................................................................... 15 CUjit_option................................................................................................. 15 CUjit_target................................................................................................. 17 CUjitInputType.............................................................................................. 17 CUlimit....................................................................................................... 18 CUmemAttach_flags........................................................................................18 CUmemorytype..............................................................................................18 CUpointer_attribute........................................................................................19 CUresourcetype............................................................................................. 19 CUresourceViewFormat.................................................................................... 20 www.nvidia.com CUDA Driver API TRM-06703-001 _v6.0 | ii CUresult...................................................................................................... 21 CUsharedconfig............................................................................................. 26 CUstream_flags............................................................................................. 26 CUarray.......................................................................................................26 CUcontext....................................................................................................27 CUdevice..................................................................................................... 27 CUdeviceptr................................................................................................. 27 CUevent...................................................................................................... 27 CUfunction................................................................................................... 27 CUgraphicsResource........................................................................................ 27 CUmipmappedArray........................................................................................ 27 CUmodule.................................................................................................... 27 CUstream.....................................................................................................27 CUstreamCallback.......................................................................................... 27 CUsurfObject................................................................................................ 28 CUsurfref.....................................................................................................28 CUtexObject.................................................................................................28 CUtexref......................................................................................................28 CU_IPC_HANDLE_SIZE...................................................................................... 28 CU_LAUNCH_PARAM_BUFFER_POINTER..................................................................28 CU_LAUNCH_PARAM_BUFFER_SIZE....................................................................... 28 CU_LAUNCH_PARAM_END.................................................................................. 28 CU_MEMHOSTALLOC_DEVICEMAP......................................................................... 29 CU_MEMHOSTALLOC_PORTABLE...........................................................................29 CU_MEMHOSTALLOC_WRITECOMBINED.................................................................. 29 CU_MEMHOSTREGISTER_DEVICEMAP..................................................................... 29 CU_MEMHOSTREGISTER_PORTABLE.......................................................................29 CU_PARAM_TR_DEFAULT................................................................................... 29 CU_TRSA_OVERRIDE_FORMAT............................................................................. 29 CU_TRSF_NORMALIZED_COORDINATES...................................................................29 CU_TRSF_READ_AS_INTEGER..............................................................................30 CU_TRSF_SRGB.............................................................................................. 30 CUDA_ARRAY3D_2DARRAY................................................................................. 30 CUDA_ARRAY3D_CUBEMAP.................................................................................30 CUDA_ARRAY3D_DEPTH_TEXTURE........................................................................30 CUDA_ARRAY3D_LAYERED..................................................................................30 CUDA_ARRAY3D_SURFACE_LDST.......................................................................... 30 CUDA_ARRAY3D_TEXTURE_GATHER...................................................................... 30 CUDA_VERSION.............................................................................................. 30 3.2. Error Handling........................................................................................... 31 cuGetErrorName............................................................................................ 31 cuGetErrorString............................................................................................ 31 3.3. Initialization.............................................................................................. 32 www.nvidia.com CUDA Driver API TRM-06703-001 _v6.0 | iii cuInit......................................................................................................... 32 3.4. Version Management.................................................................................... 33 cuDriverGetVersion......................................................................................... 33 3.5. Device Management.....................................................................................33