1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-12-24 17:51:17 +03:00

Created tunable to force small pages on stack allocation.

Created tunable glibc.pthread.stack_hugetlb to control when hugepages
can be used for stack allocation.
In case THP are enabled and glibc.pthread.stack_hugetlb is set to
0, glibc will madvise the kernel not to use allow hugepages for stack
allocations.

Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
This commit is contained in:
Cupertino Miranda
2023-04-14 16:12:20 +01:00
committed by Adhemerval Zanella
parent 0f61cd4b9c
commit b630be0922
7 changed files with 42 additions and 0 deletions

View File

@@ -21,6 +21,7 @@
#include <pthreadP.h>
size_t __nptl_stack_cache_maxsize = 40 * 1024 * 1024;
int32_t __nptl_stack_hugetlb = 1;
void
__nptl_stack_list_del (list_t *elem)