[PATCH] Document glibc.pthread.stack_hugetlb does nothing in recent kernels
Cristian Rodríguez
cristian@rodriguez.im
Mon Jan 20 20:42:29 GMT 2025
Since
c4608d1bf7c: mm: mmap: map MAP_STACK to VM_NOHUGEPAGE
All MAP_STACK allocations imply NOHUGEPAGE and the tunable does nothing.
Signed-off-by: Cristian Rodríguez <cristian@rodriguez.im>
---
manual/tunables.texi | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/manual/tunables.texi b/manual/tunables.texi
index 7f0246c789..468432fc57 100644
--- a/manual/tunables.texi
+++ b/manual/tunables.texi
@@ -509,6 +509,10 @@ its value to @code{0} enables the use of @code{madvise} with
This is a memory utilization optimization, since internal glibc setup of either
the thread descriptor and the guard page might force the kernel to move the
thread stack originally backup by Huge Pages to default pages.
+
+This tunable has no effect on the linux kernel version 6.7
+or later where MADV_NOHUGEPAGE is the default for stack mappings.
+
@end deftp
@node Hardware Capability Tunables
--
2.48.1
More information about the Libc-alpha
mailing list