Skip to content

Commit 20334d1

Browse files
committed
Expand a 32-bit int to 64-bits for proper CUDA API call.
1 parent f9df16f commit 20334d1

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

cuda_core/cuda/core/experimental/_memory/_device_memory_resource.pyx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
from __future__ import annotations
66

77
from libc.limits cimport ULLONG_MAX
8-
from libc.stdint cimport uintptr_t
8+
from libc.stdint cimport uintptr_t, uint64_t
99
from libc.string cimport memset
1010

1111
from cuda.bindings cimport cydriver
@@ -116,10 +116,10 @@ cdef DMRA_mempool_attribute(property_type: type):
116116
return decorator
117117

118118

119-
cdef int DMRA_getattribute(
119+
cdef uint64_t DMRA_getattribute(
120120
cydriver.CUmemoryPool pool_handle, cydriver.CUmemPool_attribute attr_enum
121121
):
122-
cdef int value
122+
cdef uint64_t value = 0
123123
with nogil:
124124
HANDLE_RETURN(cydriver.cuMemPoolGetAttribute(pool_handle, attr_enum, <void *> &value))
125125
return value

0 commit comments

Comments
 (0)