Migrating to the _v2 Bindings#
The cuda.bindings._v2 package provides new bindings for the CUDA driver API
(driver_v2), the CUDA runtime API (runtime_v2) and NVRTC
(nvrtc_v2). They cover the same C APIs as the existing driver,
runtime and nvrtc modules but follow a more Pythonic design. This guide lists what changed so that
existing code can be ported.
Overview of changes#
Errors are raised as exceptions#
Legacy functions return a tuple that starts with a result code, such as
(CUresult.CUDA_SUCCESS, value) or (cudaError_t.cudaSuccess, value). The new functions never return a result code.
A failing call raises an exception instead. The exceptions derive from DriverError for the
driver, CudaError for the runtime and NvrtcError for NVRTC, and there is one subclass per error code, for
example InvalidDeviceError. The numeric status is available as e.status
(a plain int). The few functions that report an expected condition through their return
value are listed under Status codes in the Driver and Runtime sections.
Return values#
A function with no outputs returns None, a function with one output returns that
value directly, and a function with several outputs returns a tuple. The order of
the outputs is the same as in the legacy API. Functions whose signature or return value changes beyond this are
noted in the tables below.
Naming#
Functions use
snake_casewith thecu/cuda/nvrtcprefix removed (cuStreamCreateandcudaStreamCreatebecomestream_create). Driver functions keep the version suffix of the C symbol (mem_alloc_v2), whereas the legacy module drops it.Parameters and struct members use
snake_case. A parameter that is a Python keyword gets a trailing underscore (from_). Python builtin names such astypeandobjectare kept as they are. A struct member whose name would shadow an attribute of the class (ptr) or of the NumPy array that backs struct arrays (data,flags,size,device) also gets a trailing underscore (flags_,data_).Enumeration classes and structs use
CamelCasewith theCU/cuda/nvrtcprefix removed. Structs keep their C version suffix (MemLocation_v1) and there is a single class per versioned C type instead of several aliases.Enumeration members lose their common C prefix (
CU_DEVICE_ATTRIBUTE_MAX_THREADS_PER_BLOCKbecomesDeviceAttribute.MAX_THREADS_PER_BLOCK), and the old full names are not kept as aliases. Enumerations with a single member keep the part of the C name that identifies the member, because there is no second member to share a prefix with. For exampleCU_IPC_MEM_LAZY_ENABLE_PEER_ACCESSbecomesIpcMemFlags.IPC_MEM_LAZY_ENABLE_PEER_ACCESSandCU_USER_OBJECT_NO_DESTRUCTOR_SYNCbecomesUserObjectFlags.USER_OBJECT_NO_DESTRUCTOR_SYNC. The Prefix removed columns below list what was removed in each case.
Handles are plain integers#
Handle types such as CUcontext, CUstream, CUevent, CUmodule, CUdeviceptr,
cudaStream_t, cudaEvent_t, cudaGraph_t, cudaMemPool_t and
nvrtcProgram are no longer classes. Functions return them as int and accept only int.
Legacy functions accepted None for a null handle. The new functions raise TypeError for None;
pass 0 instead (for example stream_synchronize(0) for the default stream).
Use int(handle) to convert a legacy handle object.
Enumerations#
Enumeration classes are int subclasses. Functions accept either the enumeration members or plain integers.
Their members expose a description of the value automatically, so the individual members
are no longer documented one by one.
Structs#
Struct classes are generated extension types that wrap a C struct. They expose their address through the .ptr
property (replacing getPtr()), and can be created from existing memory with the
from_ptr(), from_data() (which takes a NumPy array of the matching *_dtype) and from_buffer() class methods. Where a function takes a struct, the argument
is either a raw address (an int) or the struct object itself. Wrapper objects of the legacy classes cannot be
passed in their place.
Arrays and buffers#
Legacy functions took a Python list for an array and, for many of them, a separate parameter that gave the number of
elements, or the size of a buffer in bytes. The new functions take only the array or buffer and use its length as the
count, so those count and size parameters are removed. They are not listed one by one in the tables below. If several
arguments describe the same elements (for example from_, to and edge_data of
graph_add_dependencies), their lengths must be equal, otherwise a ValueError is raised. What an argument
accepts depends on its element type:
An array of handles, pointers, sizes or other scalars (
dependencies,from_,to,dptrs,sizes,options,option_valuesand so on) is a Python sequence, such as alistor atuple, ofint(or of the matching enumeration for option names). A raw address raisesTypeError, because the length would be unknown. Where an array is optional,Nonemeans no elements.An array of structs (
edge_data,dependency_data,desc,op_list,prefetch_locsand so on) is an instance of the struct class, orNonefor NULL. A struct instance wraps an array:MemAccessDesc_v1(3)holds three elements, a default-constructed instance holds one, andlen()gives the element count. A list of struct objects is not accepted. To wrap existing memory, usefrom_data()orfrom_ptr().A buffer whose size is derived from it (
param_setv’sptrand so on) is any object that supports the buffer protocol, such asbytesor a NumPy array, orNonefor NULL. A raw address raisesTypeError.
Strings and constants#
get_error_stringandget_error_namereturnstr, where the legacy functions returnedbytes.The
#defineconstants that the legacy modules exposed as module attributes (CU_MEMHOSTALLOC_PORTABLEand so on, orcudaHostAllocPortablein the runtime module) are now members of enumerations grouped by purpose, for exampleMemHostAllocFlags.PORTABLE. Only a few ungrouped constants remain at module level, keeping their C names. In the driver module these areCUDA_VERSION,CU_IPC_HANDLE_SIZE,CU_TENSOR_MAP_NUM_QWORDS,CU_LAUNCH_KERNEL_REQUIRED_BLOCK_DIM,CUDA_EGL_INFINITE_TIMEOUT,MAX_PLANESand, from CUDA 13.5,CU_DEV_SM_RESOURCE_GROUP_LOCALITY_DOMAIN_ID_ANY. The runtime module keepsCUDART_VERSION,CUDA_EGL_MAX_PLANES,CUDA_IPC_HANDLE_SIZEand, from CUDA 13.5,DEV_SM_RESOURCE_GROUP_LOCALITY_DOMAIN_ID_ANY(legacycudaDevSmResourceGroupLocalityDomainIdAny).
Driver#
The cuda.bindings._v2.driver module replaces cuda.bindings.driver. The deprecated driver APIs (texture references, surface references, cuLaunch* and cuParam* functions, cuCtxAttach, and so on) are also available and follow the same rules. They are listed in the Deprecated functions table below.
Arrays#
See Arrays and buffers above. The JIT and library option arrays (options and option_values of
module_load_data_ex, link_create_v2, link_add_data_v2 and link_add_file_v2, and jit_options,
jit_options_values, library_options and library_option_values of library_load_data and
library_load_from_file) are sequences of the same length, so the legacy numOptions, numJitOptions and
numLibraryOptions parameters are removed.
Status codes#
Errors raise, with the following exceptions to the rule:
stream_queryandevent_queryraiseNotReadyErrorwhile work is pending.stream_query_no_raiseandevent_query_no_raisereturn the status code as anintinstead, which suits polling loops. These are the only functions with a_no_raisevariant.graph_exec_update_v2does not raise when the update fails because the graph violates the constraints of graph update (Result.ERROR_GRAPH_EXEC_UPDATE_FAILURE). The returnedGraphExecUpdateResultInfo_v1says why. Legacy returned the error code together with the info, so code that compared the code must now checkresultof the returned info instead.get_error_stringandget_error_nameraiseInvalidValueErrorfor an unknown error code. Legacy returnedCUDA_ERROR_INVALID_VALUEtogether withNone. The runtime functions of the same name return the string"unrecognized error code".
Functions#
Where the C symbol has a version suffix (cuCtxCreate_v2), the legacy module generally exposes only the unsuffixed name, while the new module keeps the suffix, so one legacy function can map to several new ones. A few legacy functions (cuCtxGetDevice_v2 and similar) already carry the suffix. They have their own rows and map to the new function of the same name. Parameters that only give the number of elements of an array, or the size of a buffer, are removed (see Arrays and buffers above). Only changes to parameters and return values beyond the general rules above are noted. Renamed parameters are not listed.
Legacy |
New |
Notes |
|---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Returns only the value ( |
|
|
Returns only the value ( |
|
|
|
|
|
|
|
|
Returns |
|
|
Returns |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters added: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters added: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
Returns the populated |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Raises |
|
|
Returns the status code as an |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Returns a |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
|
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Output |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters added: |
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Returns the linked image as |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters added: |
|
|
|
|
|
|
|
|
Parameters added: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Returns a 4-tuple. The dependency count is no longer returned and edge data is not included. |
|
|
Returns a 5-tuple. The dependency count is no longer returned. |
|
|
|
|
|
Returns a 2-tuple |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Raises |
|
|
Returns the status code as an |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(none) |
|
Legacy exposes this C function as |
(none) |
|
Legacy does not expose |
Deprecated functions#
These functions are deprecated in the CUDA driver API but are still available in the new module. The general rules above apply. Texture and surface references are handles, so they are int values like the other handle types.
Legacy |
New |
Notes |
|---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Classes#
The legacy module exposes several aliases for the same class (X, X_st, X_v1). Only one legacy name per class is shown. Handle types such as CUcontext and CUstream have no class in the new module (see above). Each class is followed by its renamed members. Members that are not listed keep their name apart from the general rename to snake_case.
CUaccessPolicyWindow_v1 -> AccessPolicyWindow_v1
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
CUarrayMapInfo_v1 -> ArrayMapInfo_v1
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
CUasyncNotificationInfo -> AsyncNotificationInfo
CUcheckpointCheckpointArgs -> CheckpointCheckpointArgs
Legacy member |
New member |
|---|---|
|
|
CUcheckpointGpuPair -> CheckpointGpuPair
Legacy member |
New member |
|---|---|
|
|
|
|
CUcheckpointLockArgs -> CheckpointLockArgs
Legacy member |
New member |
|---|---|
|
|
CUcheckpointRestoreArgs -> CheckpointRestoreArgs
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
CUcheckpointUnlockArgs -> CheckpointUnlockArgs
CUcliqueInfo -> CliqueInfo
CUctxCigParam -> CtxCigParam
Legacy member |
New member |
|---|---|
|
|
|
|
CUctxCreateParams -> CtxCreateParams
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
CUDA_ARRAY3D_DESCRIPTOR_v2 -> Array3dDescriptor_v2
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
CUDA_ARRAY_DESCRIPTOR_v2 -> ArrayDescriptor_v2
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
CUDA_ARRAY_MEMORY_REQUIREMENTS_v1 -> ArrayMemoryRequirements_v1
Legacy member |
New member |
|---|---|
|
|
CUDA_ARRAY_SPARSE_PROPERTIES_v1 -> ArraySparseProperties_v1
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
CUDA_BATCH_MEM_OP_NODE_PARAMS_v1 -> BatchMemOpNodeParams_v1
Legacy member |
New member |
|---|---|
|
|
|
|
CUDA_BATCH_MEM_OP_NODE_PARAMS_v2 -> BatchMemOpNodeParams_v2
Legacy member |
New member |
|---|---|
|
|
|
|
CUDA_CHILD_GRAPH_NODE_PARAMS -> ChildGraphNodeParams
CUDA_CONDITIONAL_NODE_PARAMS -> ConditionalNodeParams
Legacy member |
New member |
|---|---|
|
|
|
|
CUDA_EVENT_RECORD_NODE_PARAMS -> EventRecordNodeParams
Legacy member |
New member |
|---|---|
|
|
CUDA_EVENT_WAIT_NODE_PARAMS -> EventWaitNodeParams
CUDA_EXT_SEM_SIGNAL_NODE_PARAMS_v1 -> ExtSemSignalNodeParams_v1
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
CUDA_EXT_SEM_SIGNAL_NODE_PARAMS_v2 -> ExtSemSignalNodeParams_v2
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
CUDA_EXT_SEM_WAIT_NODE_PARAMS_v1 -> ExtSemWaitNodeParams_v1
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
CUDA_EXT_SEM_WAIT_NODE_PARAMS_v2 -> ExtSemWaitNodeParams_v2
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
CUDA_EXTERNAL_MEMORY_BUFFER_DESC_v1 -> ExternalMemoryBufferDesc_v1
Legacy member |
New member |
|---|---|
|
|
|
|
CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1 -> ExternalMemoryHandleDesc_v1
Legacy member |
New member |
|---|---|
|
|
|
|
CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC_v1 -> ExternalMemoryMipmappedArrayDesc_v1
Legacy member |
New member |
|---|---|
|
|
|
|
CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1 -> ExternalSemaphoreHandleDesc_v1
Legacy member |
New member |
|---|---|
|
|
CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1 -> ExternalSemaphoreSignalParams_v1
Legacy member |
New member |
|---|---|
|
|
CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1 -> ExternalSemaphoreWaitParams_v1
Legacy member |
New member |
|---|---|
|
|
CUDA_FABRIC_CPY_BATCH_NODE_PARAMS_V1 -> FabricCpyBatchNodeParamsV1
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
CUDA_GRAPH_INSTANTIATE_PARAMS -> GraphInstantiateParams
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
CUDA_HOST_NODE_PARAMS_v1 -> HostNodeParams_v1
Legacy member |
New member |
|---|---|
|
|
CUDA_HOST_NODE_PARAMS_v2 -> HostNodeParams_v2
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
CUDA_KERNEL_NODE_PARAMS -> KernelNodeParams_v3
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
CUDA_KERNEL_NODE_PARAMS_v2 -> KernelNodeParams_v2
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
CUDA_MEM_ALLOC_NODE_PARAMS_v1 -> MemAllocNodeParams_v1
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
CUDA_MEM_ALLOC_NODE_PARAMS_v2 -> MemAllocNodeParams_v2
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
CUDA_MEM_FREE_NODE_PARAMS -> MemFreeNodeParams
CUDA_MEMCPY2D_v2 -> MemCpy2d_v2
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
CUDA_MEMCPY3D_BATCH_OP_v1 -> MemCpy3dBatchOp_v1
Legacy member |
New member |
|---|---|
|
|
|
|
CUDA_MEMCPY3D_PEER_v1 -> MemCpy3dPeer_v1
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
CUDA_MEMCPY3D_v2 -> MemCpy3d_v2
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
CUDA_MEMCPY_BATCH_NODE_PARAMS_V1 -> MemcpyBatchNodeParamsV1
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
CUDA_MEMCPY_NODE_PARAMS -> MemCpyNodeParams
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
CUDA_MEMSET_NODE_PARAMS_v1 -> MemSetNodeParams_v1
Legacy member |
New member |
|---|---|
|
|
CUDA_MEMSET_NODE_PARAMS_v2 -> MemSetNodeParams_v2
Legacy member |
New member |
|---|---|
|
|
CUDA_POINTER_ATTRIBUTE_P2P_TOKENS_v1 -> PointerAttributeP2PTokens_v1
Legacy member |
New member |
|---|---|
|
|
|
|
CUDA_RESOURCE_DESC_v1 -> ResourceDesc_v1
Legacy member |
New member |
|---|---|
|
|
|
|
CUDA_RESOURCE_VIEW_DESC_v1 -> ResourceViewDesc_v1
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
CUDA_TEXTURE_DESC_v1 -> TextureDesc_v1
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
CUdevResource_v1 -> DevResource_v1
Legacy member |
New member |
|---|---|
|
|
|
|
CUdevSmResource -> DevSmResource
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
CUdevWorkqueueConfigResource -> DevWorkqueueConfigResource
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
CUdevWorkqueueResource -> DevWorkqueueResource
CUexecAffinityParam_v1 -> ExecAffinityParam_v1
CUexecAffinitySmCount_v1 -> ExecAffinitySmCount_v1
CUextent3D_v1 -> Extent3d_v1
CUgraphEdgeData -> GraphEdgeData
CUgraphExecUpdateResultInfo_v1 -> GraphExecUpdateResultInfo_v1
Legacy member |
New member |
|---|---|
|
|
|
|
CUgraphNodeParams -> GraphNodeParams
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
CUipcEventHandle_v1 -> IpcEventHandle_v1
CUipcMemHandle_v1 -> IpcMemHandle_v1
CUlaunchAttribute -> LaunchAttribute
CUlaunchAttributeValue -> LaunchAttributeValue
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
CUlaunchConfig -> LaunchConfig
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
CUlaunchMemSyncDomainMap -> LaunchMemSyncDomainMap
CUlibraryHostUniversalFunctionAndDataTable -> LibraryHostUniversalFunctionAndDataTable
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
CUlogicalEndpointFabricHandle -> LogicalEndpointFabricHandle
Legacy member |
New member |
|---|---|
|
|
CUlogicalEndpointProp -> LogicalEndpointProp
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
CUmemAccessDesc_v1 -> MemAccessDesc_v1
Legacy member |
New member |
|---|---|
|
|
CUmemAllocationProp_v1 -> MemAllocationProp_v1
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
CUmemcpy3DOperand_v1 -> MemCpy3dOperand_v1
CUmemcpyAttributes_v1 -> MemCpyAttributes_v1
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
CUmemDecompressParams -> MemDecompressParams
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
CUmemFabricHandle_v1 -> MemFabricHandle_v1
Legacy member |
New member |
|---|---|
|
|
CUmemLocation_v1 -> MemLocation_v1
CUmemPoolProps_v1 -> MemPoolProps_v1
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
CUmemPoolPtrExportData_v1 -> MemPoolPtrExportData_v1
CUmulticastObjectProp_v1 -> MulticastObjectProp_v1
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
CUoffset3D_v1 -> Offset3d_v1
CUstreamBatchMemOpParams_v1 -> StreamBatchMemOpParams_v1
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
CUstreamCigCaptureParams -> StreamCigCaptureParams
Legacy member |
New member |
|---|---|
|
|
CUstreamCigParam -> StreamCigParam
Legacy member |
New member |
|---|---|
|
|
|
|
CUstreamMemOpAtomicReductionParams_st -> StreamMemOpAtomicReductionParams
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
CUstreamMemOpFlushRemoteWritesParams_st -> StreamMemOpFlushRemoteWritesParams
Legacy member |
New member |
|---|---|
|
|
CUstreamMemOpMemoryBarrierParams_st -> StreamMemOpMemoryBarrierParams
Legacy member |
New member |
|---|---|
|
|
CUstreamMemOpWaitValueParams_st -> StreamMemOpWaitValueParams
Legacy member |
New member |
|---|---|
|
|
CUstreamMemOpWriteValueParams_st -> StreamMemOpWriteValueParams
Legacy member |
New member |
|---|---|
|
|
CUtensorMap -> TensorMap
CUuuid -> Uuid
CUdevprop_v1 -> DevProp_v1
Legacy member |
New member |
|---|---|
|
|
CUDA_LAUNCH_PARAMS_v1 -> LaunchParams_v1
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Enumerations#
Enumeration members lose the common C prefix shown in the Prefix removed column. For example CU_DEVICE_ATTRIBUTE_MAX_THREADS_PER_BLOCK becomes DeviceAttribute.MAX_THREADS_PER_BLOCK. The old full C names are not kept as aliases. Members that changed in any other way are listed under the enumeration.
Legacy |
New |
Prefix removed |
|---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(module constants ``CUDA_COOPERATIVE_LAUNCH_MULTI_DEVICE_*``) |
|
|
(module constants ``CU_LAUNCH_PARAM_*``) |
|
|
(module constant ``CU_PARAM_TR_DEFAULT``) |
|
|
(module constants ``CU_TRSA_*``) |
|
|
(module constants ``CU_TRSF_*``) |
|
|
CUgraphConditionalNodeType -> GraphConditionalNodeType
Legacy |
New |
|---|---|
|
|
Runtime#
The cuda.bindings._v2.runtime module replaces cuda.bindings.runtime. The general rules above apply. The deprecated runtime APIs (cudaMemcpyToArray and so on) are also available and are listed in the Functions table below.
Arrays#
See Arrays and buffers above. The option arrays of library_load_data and library_load_from_file
(jit_options, jit_options_values, library_options and library_option_values) are still plain addresses
with explicit counts.
Struct members that hold pointers are plain int addresses of memory that the caller owns: KernelNodeParams.kernel_params and extra, ExternalSemaphoreSignalNodeParams.ext_sem_array and params_array (and the corresponding wait and V2 structs), MemAllocNodeParams.access_descs and HostNodeParams.user_data. ConditionalNodeParams.ph_graph_out is the address of a CUDA-owned array that CUDA fills in when the node is added. Legacy accepted Python objects for some of these, such as a list of semaphores or a (values, types) tuple of kernel arguments. Struct members that are arrays of structs, such as EglFrame.plane_desc and EglFrame.frame.p_pitch, are views that support len() and indexing. Assigning to one copies from another such view; a list of structs is not accepted.
Status codes#
Three groups of functions report an expected condition through their return value instead of raising:
get_last_errorandpeek_at_last_errorreturn the earlier error as anint(0for success).stream_queryandevent_queryraiseNotReadyErrorwhile work is pending.stream_query_no_raiseandevent_query_no_raisereturn the status code as anintinstead, which suits polling loops. These are the only functions with a_no_raisevariant.graph_exec_updatedoes not raise when the update fails because the graph violates the constraints of graph update. The returnedGraphExecUpdateResultInfosays why.
Functions#
Parameters that only give the number of elements of an array are removed (see Arrays above). Renamed parameters are not listed. Only changes to parameters and return values beyond the general rules above are noted.
Legacy |
New |
Notes |
|---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
Returns the populated |
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Raises |
|
|
Returns the status code as an |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Returns a |
|
|
|
|
|
|
|
|
Takes the error code as an |
|
|
Takes the error code as an |
|
|
|
|
|
|
|
|
Returns the error code as an |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Returns a |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Returns the value as an |
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Returns the error code as an |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Returns a 5-tuple |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Raises |
|
|
Returns the status code as an |
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameters removed: |
|
|
|
|
|
|
|
|
|
|
|
|
(none) |
|
Legacy does not expose |
(none) |
|
Legacy does not expose |
Classes#
The legacy module exposes several aliases for the same class (X, X_st). Only one legacy name per class is shown. Handle types such as cudaStream_t and cudaEvent_t have no class in the new module (see above), and neither do the other classes that only wrapped a C scalar: cudaSurfaceObject_t, cudaTextureObject_t, cudaGraphConditionalHandle, cudaLogIterator, the callback types (cudaHostFn_t, cudaStreamCallback_t, cudaLogsCallback_t and so on) and the EGL, OpenGL and VDPAU types. All of these are plain int values. Each class is followed by its renamed members. Members that are not listed keep their name apart from the general rename to snake_case.
cudaAccessPolicyWindow -> AccessPolicyWindow
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
cudaArrayMemoryRequirements -> ArrayMemoryRequirements
Legacy member |
New member |
|---|---|
|
|
cudaArraySparseProperties -> ArraySparseProperties
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
cudaAsyncNotificationInfo -> AsyncNotificationInfo
cudaChannelFormatDesc -> ChannelFormatDesc
cudaChildGraphNodeParams -> ChildGraphNodeParams
cudaConditionalNodeParams -> ConditionalNodeParams
Legacy member |
New member |
|---|---|
|
|
|
|
cudaDeviceProp -> DeviceProp
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
cudaDevResource -> DevResource
Legacy member |
New member |
|---|---|
|
|
|
|
cudaDevSmResource -> DevSmResource
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
cudaDevSmResourceGroupParams -> DevSmResourceGroupParams
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
cudaDevWorkqueueConfigResource -> DevWorkqueueConfigResource
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
cudaDevWorkqueueResource -> DevWorkqueueResource
cudaEglFrame -> EglFrame
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
cudaEglPlaneDesc -> EglPlaneDesc
Legacy member |
New member |
|---|---|
|
|
|
|
cudaEventRecordNodeParams -> EventRecordNodeParams
cudaEventWaitNodeParams -> EventWaitNodeParams
cudaExtent -> Extent
cudaExternalMemoryBufferDesc -> ExternalMemoryBufferDesc
Legacy member |
New member |
|---|---|
|
|
|
|
cudaExternalMemoryHandleDesc -> ExternalMemoryHandleDesc
Legacy member |
New member |
|---|---|
|
|
|
|
cudaExternalMemoryMipmappedArrayDesc -> ExternalMemoryMipmappedArrayDesc
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
cudaExternalSemaphoreHandleDesc -> ExternalSemaphoreHandleDesc
Legacy member |
New member |
|---|---|
|
|
cudaExternalSemaphoreSignalNodeParams -> ExternalSemaphoreSignalNodeParams
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
cudaExternalSemaphoreSignalNodeParamsV2 -> ExternalSemaphoreSignalNodeParamsV2
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
cudaExternalSemaphoreSignalParams -> ExternalSemaphoreSignalParams
Legacy member |
New member |
|---|---|
|
|
cudaExternalSemaphoreWaitNodeParams -> ExternalSemaphoreWaitNodeParams
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
cudaExternalSemaphoreWaitNodeParamsV2 -> ExternalSemaphoreWaitNodeParamsV2
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
cudaExternalSemaphoreWaitParams -> ExternalSemaphoreWaitParams
Legacy member |
New member |
|---|---|
|
|
cudaFuncAttributes -> FuncAttributes
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
cudaGraphEdgeData -> GraphEdgeData
cudaGraphExecUpdateResultInfo -> GraphExecUpdateResultInfo
Legacy member |
New member |
|---|---|
|
|
|
|
cudaGraphInstantiateParams -> GraphInstantiateParams
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
cudaGraphKernelNodeUpdate -> GraphKernelNodeUpdate
Legacy member |
New member |
|---|---|
|
|
cudaGraphNodeParams -> GraphNodeParams
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
cudaGraphRecaptureCallbackData -> GraphRecaptureCallbackData
Legacy member |
New member |
|---|---|
|
|
|
|
cudaHostNodeParams -> HostNodeParams
Legacy member |
New member |
|---|---|
|
|
cudaHostNodeParamsV2 -> HostNodeParamsV2
Legacy member |
New member |
|---|---|
|
|
|
|
cudaIpcEventHandle_t -> IpcEventHandle
cudaIpcMemHandle_t -> IpcMemHandle
cudaKernelNodeAttrValue -> KernelNodeAttrValue
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(removed) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
cudaKernelNodeParams -> KernelNodeParams
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
cudaKernelNodeParamsV2 -> KernelNodeParamsV2
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
cudaLaunchAttribute -> LaunchAttribute
cudaLaunchAttributeValue -> LaunchAttributeValue
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(removed) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
cudaLaunchMemSyncDomainMap -> LaunchMemSyncDomainMap
cudalibraryHostUniversalFunctionAndDataTable -> LibraryHostUniversalFunctionAndDataTable
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
cudaMemAccessDesc -> MemAccessDesc
Legacy member |
New member |
|---|---|
|
|
cudaMemAllocNodeParams -> MemAllocNodeParams
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
cudaMemAllocNodeParamsV2 -> MemAllocNodeParamsV2
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
cudaMemcpy3DBatchOp -> MemCpy3dBatchOp
Legacy member |
New member |
|---|---|
|
|
|
|
cudaMemcpy3DOperand -> MemCpy3dOperand
cudaMemcpy3DParms -> MemCpy3dParms
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
cudaMemcpy3DPeerParms -> MemCpy3dPeerParms
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
cudaMemcpyAttributes -> MemCpyAttributes
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
cudaMemcpyBatchNodeParams -> MemCpyBatchNodeParams
Legacy member |
New member |
|---|---|
|
|
|
|
cudaMemcpyNodeParams -> MemCpyNodeParams
Legacy member |
New member |
|---|---|
|
|
|
|
cudaMemFabricHandle_t -> MemFabricHandle
cudaMemFreeNodeParams -> MemFreeNodeParams
cudaMemLocation -> MemLocation
cudaMemPoolProps -> MemPoolProps
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
cudaMemPoolPtrExportData -> MemPoolPtrExportData
cudaMemsetParams -> MemsetParams
Legacy member |
New member |
|---|---|
|
|
cudaMemsetParamsV2 -> MemsetParamsV2
Legacy member |
New member |
|---|---|
|
|
cudaOffset3D -> Offset3d
cudaPitchedPtr -> PitchedPtr
cudaPointerAttributes -> PointerAttributes
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
cudaPos -> Pos
cudaResourceDesc -> ResourceDesc
Legacy member |
New member |
|---|---|
|
|
|
|
cudaResourceViewDesc -> ResourceViewDesc
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
cudaStreamAttrValue -> StreamAttrValue
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(removed) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
cudaTextureDesc -> TextureDesc
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
CUuuid -> Uuid
dim3 -> Dim3
Enumerations#
Enumeration members lose the common C prefix shown in the Prefix removed column and are written in UPPER_SNAKE_CASE. For example cudaDevAttrMaxThreadsPerBlock becomes DeviceAttr.MAX_THREADS_PER_BLOCK and cudaErrorNotReady becomes Error.ERROR_NOT_READY. The old full C names are not kept as aliases. The #define constants that the legacy module exposed as module attributes (cudaHostAllocMapped and so on) are now members of enumerations grouped by purpose, for example HostAllocFlags.MAPPED. Members that changed in any other way are listed under the enumeration. Outputs that hold an enumeration value are returned as plain int values.
Legacy |
New |
Prefix removed |
|---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(module constants ``cudaArray*``) |
|
|
(module constants ``cudaArraySparsePropertiesSingleMipTail``) |
|
|
(module constants ``cudaCpuDeviceId``, ``cudaInvalidDeviceId``) |
|
|
(module constants ``cudaDevice*``) |
|
|
(module constants ``cudaEvent*``) |
|
|
(module constants ``cudaEventRecordDefault``, ``cudaEventRecordExternal``) |
|
|
(module constants ``cudaEventWaitDefault``, ``cudaEventWaitExternal``) |
|
|
(module constants ``cudaExternalMemoryDedicated``) |
|
|
(module constants ``cudaExternalSemaphoreSignalSkipNvSciBufMemSync``) |
|
|
(module constants ``cudaExternalSemaphoreWaitSkipNvSciBufMemSync``) |
|
|
(module constants ``cudaGraphKernelNodePortDefault``, ``cudaGraphKernelNodePortLaunchCompletion``, ``cudaGraphKernelNodePortProgrammatic``) |
|
|
(module constants ``cudaHostAlloc*``) |
|
|
(module constants ``cudaHostRegister*``) |
|
|
(module constants ``cudaInitDeviceFlagsAreValid``) |
|
|
(module constants ``cudaIpcMemLazyEnablePeerAccess``) |
|
|
(module constants ``cudaKernelNodeAttribute*``) |
|
|
(module constants ``cudaMemAttachGlobal``, ``cudaMemAttachHost``, ``cudaMemAttachSingle``) |
|
|
(module constants ``cudaMemPoolCreateUsageHwDecompress``) |
|
|
(module constants ``cudaNvSciSyncAttrSignal``, ``cudaNvSciSyncAttrWait``) |
|
|
(module constants ``cudaOccupancyDefault``, ``cudaOccupancyDisableCachingOverride``) |
|
|
(module constants ``cudaPeerAccessDefault``) |
|
|
(module constants ``cudaStreamAttribute*``) |
|
|
(module constants ``cudaStreamDefault``, ``cudaStreamNonBlocking``) |
|
|
(module constants ``cudaStreamLegacy``, ``cudaStreamPerThread``) |
|
|
(module constants ``cudaSurface*``) |
|
|
(module constants ``cudaTexture*``) |
|
|
cudaMemPoolAttr -> MemPoolAttr
Legacy |
New |
|---|---|
|
|
|
|
|
|
(module constants) -> DeviceFlags
Legacy |
New |
|---|---|
|
|
(module constants) -> SurfaceType
Legacy |
New |
|---|---|
|
|
|
|
(module constants) -> TextureType
Legacy |
New |
|---|---|
|
|
|
|
NVRTC#
The cuda.bindings._v2.nvrtc module replaces cuda.bindings.nvrtc.
Functions#
Legacy |
New |
Notes |
|---|---|---|
|
|
Returns |
|
|
|
|
|
Returns the sorted architectures as an integer array (legacy returned a |
|
|
Parameter |
|
|
|
|
|
Parameter |
|
|
|
|
|
Parameter |
|
|
|
|
|
Parameter |
|
|
|
|
|
Parameter |
|
|
|
|
|
Parameter |
|
|
|
|
|
Parameter |
|
|
|
|
|
Parameter |
|
|
|
|
|
Returns the lowered name as |
|
|
|
|
|
|
|
|
|
|
|
Returns the status as an |
|
|
|
|
|
|
|
|
Returns |
|
|
Returns the optional error message as |
|
|
Takes the result code as an |
Classes#
nvrtcBundledHeadersInfo -> BundledHeadersInfo
Legacy member |
New member |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
nvrtcProgram (removed)
Programs are plain int handles.
Enumerations#
Members lose the prefix shown in the Prefix removed column. No members changed in any other way. NVRTC_SUCCESS becomes Result.SUCCESS and NVRTC_ERROR_OUT_OF_MEMORY becomes Result.ERROR_OUT_OF_MEMORY. The installation flags were plain module-level constants in the legacy module and are now members of the InstallHeadersFlag enumeration.
Legacy |
New |
Prefix removed |
|---|---|---|
|
|
|
|
|
|