cuda.bindings._v2.driver.ctx_attach#

cuda.bindings._v2.driver.ctx_attach(unsigned int flags) → intptr_t#

Increment a context’s usage-count.

[Deprecated]. Note that this function is deprecated and should not be used. Increments the usage count of the context and passes back a context handle in *pctx that must be passed to ctx_detach() when the application is done with the context. ctx_attach() fails if there is no context current to the thread. Currently, the flags parameter must be 0.

Parameters:

flags (unsigned int) – Context attach flags (must be 0).

Returns:

Returned context handle of the current context.

Return type:

intptr_t

See also

cuCtxAttach