Added support for flexible huge page sizes on Linux. #2076
Merged
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.
This PR adds support for user configurable huge page sizes on Linux where huge pages with size other than 2 MB are supported. For example #2060 right now Linux on Apple M1 supports only 32 MB hugepages and doesn't support widely supported 2 MB huge pages. Also 32 MB and 64 kB huge pages can be tested on modern Amazon ARM instances with Neoverse N1 CPU (
*6g.*
)Config option
"huge-pages"
extended, now it accepts huge pages size in kB, not only boolean value.Examples:
"huge-pages": 2048,
this equal to"huge-pages": true
default value for 2 MB huge pages."huge-pages": 32768,
- 32 MB huge pages."huge-pages": 64,
- 64 kB huge pages.For command line usage added option
--hugepage-size
. 1 GB pages is not a valid option, since they are already supported in a special way. This PR was checked with 64 kB, 2 MB and 32 MB huge page sizes, but it should support other sizes if it is supported by hardware and Linux.