Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ENH: Enable huge pages in all Linux builds #14322

Merged
merged 3 commits into from Aug 22, 2019

Conversation

charris
Copy link
Member

@charris charris commented Aug 21, 2019

Backport of #14216.

This PR modifies memory allocation in such a way that huge pages for large arrays is enabled in all Linux builds (even if MADV_HUGEPAGE is not defined). As per discussion in #14177, this isn't the case currently, which means huge pages may never be available depending on the NumPy build, even if the runtime system supports it. Both conda-forge and pip builds for 1.17.0 seem to not include support for huge pages.

The madvise() man-pages indicates that it will return EINVAL if the advice is invalid. At runtime, that means that it will be enabled if available, otherwise for the use case in NumPy it's enough to simply ignore the error to fallback to default behavior.

Fixes #14177 .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants