This repository was archived by the owner on Nov 17, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6.7k
Add documents for two new environment variables for memory pool. #12668
Merged
Merged
Changes from 2 commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 |
|---|---|---|
|
|
@@ -58,6 +58,15 @@ $env:MXNET_STORAGE_FALLBACK_LOG_VERBOSE=0 | |
| - Values: Int ```(default=5)``` | ||
| - The percentage of GPU memory to reserve for things other than the GPU array, such as kernel launch or cudnn handle space. | ||
| - If you see a strange out-of-memory error from the kernel launch, after multiple iterations, try setting this to a larger value. | ||
| * MXNET_GPU_MEM_POOL_TYPE | ||
| - Values: String ```(default=Naive)``` | ||
| - The type of memory pool. | ||
| - Choices: | ||
| - Naive: A simple memory pool that allocates memory for the exact requested size and cache memory buffers. If the buffered memory match the requested size, the memory will be returned from the pool in memory allocation. | ||
| - Round: A memory pool that always rounds the requested memory size and allocates memory of the rounded size. MXNET_GPU_MEM_POOL_ROUND_LINEAR_CUTOFF defines how to round up a memory size. Caching and allocating buffered memory works in the same way as the naive memory pool. | ||
| * MXNET_GPU_MEM_POOL_ROUND_LINEAR_CUTOFF | ||
| - Values: Int ```(default=24)``` | ||
| - The cutoff threshold that decides the rounding strategy. Let's denote the threshold as T. If the memory size is smaller than `2^T`, it rounds to the smallest `2^n` that is larger than the requested memory size; if the memory size is larger than `2^T`, it rounds to the next k * 2^T. | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. maybe add a suggestion on the value range to try, and some intuition (e.g. 24 means 2**24 which is 16mb). |
||
|
|
||
| ## Engine Type | ||
|
|
||
|
|
||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If any buffered memory chunk matches the size of a new request, the chunk from the memory pool will be returned and reused.