Skip to content

Commit fc23949

Browse files
authored
Update array.jl
1 parent 3605167 commit fc23949

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/array.jl

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -210,12 +210,15 @@ end
210210
## unsafe_wrap
211211

212212
"""
213+
# simple case, wrapping a CuArray around an existing GPU pointer
213214
unsafe_wrap(CuArray, ptr::CuPtr{T}, dims; own=false, ctx=context())
214215
215-
# requires
216+
# wraps a CPU array object around a unified GPU array
216217
unsafe_wrap(Array, a::CuArray)
217218
218-
# requires HMM
219+
# wraps a GPU array object around a CPU array.
220+
# if your system supports HMM, this is a fast operation.
221+
# in other cases, it has to use page locking, which can be slow.
219222
unsafe_wrap(CuArray, ptr::ptr{T}, dims)
220223
unsafe_wrap(CuArray, a::Array)
221224

0 commit comments

Comments
 (0)