[v3,25/29] Install the <sys/pagesize.h> header file
Checks
Context |
Check |
Description |
redhat-pt-bot/TryBot-apply_patch |
success
|
Patch applied to master at the time it was sent
|
linaro-tcwg-bot/tcwg_glibc_build--master-aarch64 |
success
|
Build passed
|
linaro-tcwg-bot/tcwg_glibc_check--master-aarch64 |
success
|
Test passed
|
linaro-tcwg-bot/tcwg_glibc_build--master-arm |
success
|
Build passed
|
linaro-tcwg-bot/tcwg_glibc_check--master-arm |
fail
|
Test failed
|
Commit Message
---
NEWS | 5 +++++
manual/resource.texi | 31 +++++++++++++++++++++++++++++++
misc/Makefile | 2 ++
3 files changed, 38 insertions(+)
@@ -31,6 +31,11 @@ Major new features:
* The iconv program now supports converting files in place. The program
automatically uses a temporary file if required.
+* The header file <sys/pagesize.h> is now available. It contains macros
+ PAGE_SIZE_MIN, PAGE_SIZE_MAX, PAGE_SHIFT_MIN, PAGE_SHIFT_MAX,
+ reflecting the possible range of page sizes for the target
+ architecture.
+
Deprecated and removed features, and other changes affecting compatibility:
* The big-endian ARC port (arceb-linux-gnu) has been removed.
@@ -1620,6 +1620,37 @@ different runs of the application.
The function is declared in @file{unistd.h}.
@end deftypefun
+The header file @file{sys/pagesize.h} provides information about the
+possible page sizes an architecture can support.
+
+@deftypevar {unsigned long int} PAGE_SIZE_MIN
+@standards{GNU, sys/pagesize.h}
+The smallest value that @code{getpagesize} can return on this
+architecture. The pointers returned by @code{mmap} are
+always a multiple of this constant (once cast to @code{uintptr_t}).
+@xref{Memory-mapped I/O}.
+@end deftypevar
+
+@deftypevar {unsigned long int} PAGE_SIZE_MAX
+@standards{GNU, sys/pagesize.h}
+The largest value that @code{getpagesize} can return on this
+architecture. It is guaranteed that @code{mmap} can create
+mappings at file offsets that are multiples of this constants.
+@xref{Memory-mapped I/O}.
+@end deftypevar
+
+@deftypevar int PAGE_SHIFT_MIN
+@standards{GNU, sys/pagesize.h}
+Base-2 logarithm of @code{PAGE_SIZE_MIN}.
+The @code{PAGE_SHIFT_MIN} lowest bits of pointers
+returned by @code{mmap} are always zero.
+@end deftypevar
+
+@deftypevar int PAGE_SHIFT_MAX
+@standards{GNU, sys/pagesize.h}
+Base-2 logarithm of @code{PAGE_SIZE_MAX}.
+@end deftypevar
+
Widely available on @w{System V} derived systems is a method to get
information about the physical memory the system has. The call
@@ -79,6 +79,8 @@ headers := \
bits/err-ldbl.h \
bits/error-ldbl.h \
sys/single_threaded.h \
+ bits/pagesize.h \
+ sys/pagesize.h \
# headers
routines := \