-
Notifications
You must be signed in to change notification settings - Fork 83
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added documentation of memory types (#770)
- Loading branch information
1 parent
4e602cb
commit c1ed734
Showing
2 changed files
with
25 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
.. _memory: | ||
|
||
Memory | ||
====== | ||
|
||
MatX allows tensors to be allocated in several different spaces either corresponding to physical or logical | ||
allocations. The space where the memory is allocated dictates where a user is allowed to access the memory. | ||
For example, allocating device memory on some system is not accessible by the CPU and will result in a SEGFAULT | ||
when trying to access. | ||
|
||
The type of allocation may behave differently across systems. For example, on a Grace-Hopper system (GH200) | ||
standard host memory from malloc is accessible from the GPU, but may not be on other platforms. Some types | ||
may not be available in certain environments. On WSL2 CUDA Unified Memory (UM) or managed memory is not fully | ||
supported and may result in slow code or other issues. | ||
|
||
The memory type is typically chosen when creating a tensor with `make_tensor`. The memory *may* be allocated | ||
immediately, but it is not guaranteed. The memory is guaranteed to be available before it used used, however. | ||
|
||
.. doxygenenum:: matxMemorySpace_t |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters