cuda.core.WorkqueueResource#
- class cuda.core.WorkqueueResource(*args, **kwargs)#
Represent a workqueue resource for a device or green context.
Merges
CU_DEV_RESOURCE_TYPE_WORKQUEUE_CONFIGandCU_DEV_RESOURCE_TYPE_WORKQUEUEunder one user-facing type. Instances are returned byDeviceResources.workqueueand cannot be instantiated directly.Methods
- __init__(*args, **kwargs)#
- configure(
- self,
- WorkqueueResourceOptions options: WorkqueueResourceOptions,
Configure the workqueue resource in place.
- Parameters:
options (
WorkqueueResourceOptions) – Configuration options (sharing scope, concurrency limit).
Attributes
- concurrency_limit#
Current expected maximum concurrent stream-ordered workloads.
Reflects the driver-populated
wqConfig.wqConcurrencyLimitfield. When first queried from a device, this matches the driver-reported cap (typicallyCUDA_DEVICE_MAX_CONNECTIONS). It can be updated viaconfigure()withWorkqueueResourceOptions.concurrency_limit.
- handle#
Return the address of the underlying config
CUdevResourcestruct.
- sharing_scope#
Current sharing scope of this workqueue resource.
Returns the
WorkqueueSharingScopeTypemember corresponding to the driver-populatedwqConfig.sharingScopefield. It can be updated viaconfigure()withWorkqueueResourceOptions.sharing_scope.