We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7d68db2 commit e95c4b1Copy full SHA for e95c4b1
2 files changed
cuda_core/cuda/core/experimental/_stream.pyx
@@ -316,16 +316,18 @@ cdef class Stream:
316
self._get_device_and_context()
317
return Device(self._device_id)
318
319
- cdef void _get_context(Stream self) except *:
+ cdef int _get_context(Stream self) except?-1:
320
if self._ctx_handle is None:
321
err, self._ctx_handle = driver.cuStreamGetCtx(self._handle)
322
raise_if_driver_error(err)
323
+ return 0
324
- cdef void _get_device_and_context(Stream self) except *:
325
+ cdef int _get_device_and_context(Stream self) except?-1:
326
if self._device_id is None:
327
# Get the stream context first
328
self._get_context()
329
self._device_id = get_device_from_ctx(self._ctx_handle)
330
331
332
@property
333
def context(self) -> Context:
cuda_core/cuda/core/experimental/_utils/__init__.pxd
0 commit comments