* doc/glibc-functions/pthread_gettid_np.texi: New file.
* doc/gnulib.texi (Glibc pthread.h): Include it.
* doc/posix-headers/*.texi: Update.
* doc/posix-functions/*.texi: Likewise.
+2024-08-19 Bruno Haible <bruno@clisp.org>
+
+ doc: Update for glibc 2.42.
+ * doc/glibc-functions/pthread_gettid_np.texi: New file.
+ * doc/gnulib.texi (Glibc pthread.h): Include it.
+ * doc/posix-headers/*.texi: Update.
+ * doc/posix-functions/*.texi: Likewise.
+
2024-08-19 Bruno Haible <bruno@clisp.org>
doc: Update for glibc 2.41.
--- /dev/null
+@node pthread_gettid_np
+@subsection @code{pthread_gettid_np}
+@findex pthread_gettid_np
+
+Documentation:
+@itemize
+@item
+@ifinfo
+@ref{Process Identification,,Process Identification,libc},
+@end ifinfo
+@ifnotinfo
+@url{https://www.gnu.org/software/libc/manual/html_node/Process-Identification.html},
+@end ifnotinfo
+@item
+@uref{https://www.kernel.org/doc/man-pages/online/pages/man3/pthread_gettid_np.3.html,,man pthread_gettid_np}.
+@end itemize
+
+Gnulib module: ---
+
+Portability problems fixed by Gnulib:
+@itemize
+@end itemize
+
+Portability problems not fixed by Gnulib:
+@itemize
+@item
+This function exists only on Linux and is therefore
+missing on most non-glibc platforms:
+glibc 2.41, macOS 15, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.7, Minix, AIX 7.3, HP-UX 11.31, Solaris 11.4, Cygwin, mingw, MSVC 14.
+@end itemize
* pthread_getattr_default_np::
* pthread_getattr_np::
* pthread_getname_np::
+* pthread_gettid_np::
* pthread_kill_other_threads_np::
* pthread_rwlockattr_getkind_np::
* pthread_rwlockattr_setkind_np::
@include glibc-functions/pthread_getattr_default_np.texi
@include glibc-functions/pthread_getattr_np.texi
@include glibc-functions/pthread_getname_np.texi
+@include glibc-functions/pthread_gettid_np.texi
@include glibc-functions/pthread_kill_other_threads_np.texi
@include glibc-functions/pthread_rwlockattr_getkind_np.texi
@include glibc-functions/pthread_rwlockattr_setkind_np.texi
@item
If the alignment and size are absurdly large, this function crashes:
@c https://sourceware.org/PR32301
-glibc 2.41.
+glibc 2.42.
@end itemize
Gnulib has partial substitutes for @code{aligned_alloc}
@itemize
@item
This function is missing on many platforms:
-glibc 2.41, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
@end itemize
@itemize
@item
This function is missing on many platforms:
-glibc 2.41, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
@end itemize
@itemize
@item
This function is missing on many platforms:
-glibc 2.41, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
@end itemize
@itemize
@item
This function is missing on most non-C23 platforms:
-glibc 2.41, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
@end itemize
@itemize
@item
This function is missing on most non-C23 platforms:
-glibc 2.41, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
@end itemize
@itemize
@item
This function is missing on many platforms:
-glibc 2.41, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.x, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.x, mingw, MSVC 14, Android 9.0.
But the gnulib replacement supports only a single locale category:
the argument @code{LC_ALL} is unsupported.
@item
@itemize
@item
This function is missing on many platforms:
-glibc 2.41, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
@end itemize
@itemize
@item
This function is missing on most non-C23 platforms:
-glibc 2.41, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
@end itemize
To check whether a pointer @var{P} has alignment @var{A},
@itemize
@item
This function is missing on many platforms:
-glibc 2.41, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
@end itemize
@item
The constants @code{ABALTMON_1} to @code{ABALTMON_12} are not supported on many
platforms:
-glibc 2.41, musl libc, macOS 14, NetBSD 10.0, OpenBSD 7.6, AIX 7.3, HP-UX 11.31, Solaris 11.4, Haiku, Cygwin 3.5.
+glibc 2.42, musl libc, macOS 14, NetBSD 10.0, OpenBSD 7.6, AIX 7.3, HP-UX 11.31, Solaris 11.4, Haiku, Cygwin 3.5.
@item
The constants @code{ERA}, @code{ERA_D_FMT}, @code{ERA_D_T_FMT},
@code{ERA_T_FMT}, @code{ALT_DIGITS} are not supported on some platforms:
@itemize
@item
This function is missing on many platforms:
-glibc 2.41, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
@end itemize
@itemize
@item
This function is missing on many platforms:
-glibc 2.41, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
@end itemize
@itemize
@item
This function is missing on many platforms:
-glibc 2.41, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.x, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.x, mingw, MSVC 14, Android 9.0.
@end itemize
@item
If the alignment and size are absurdly large, this function crashes:
@c https://sourceware.org/PR32301
-glibc 2.41.
+glibc 2.42.
@end itemize
@mindex aligned-malloc
@itemize
@item
This function is missing on many platforms:
-glibc 2.41, macOS 14, FreeBSD 14.0, NetBSD 9.3, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 14.0, NetBSD 9.3, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
@end itemize
@itemize
@item
This function is missing on many platforms:
-glibc 2.41, macOS 14, FreeBSD 14.0, NetBSD 9.3, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 14.0, NetBSD 9.3, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
@end itemize
another writer is already waiting to take it, this function may return
successfully immediately) -- a behaviour that may lead to writer starvation --
on some platforms:
-glibc 2.41.
+glibc 2.42.
@end itemize
Portability problems not fixed by Gnulib:
another writer is already waiting to take it, this function may return
successfully immediately) -- a behaviour that may lead to writer starvation --
on some platforms:
-glibc 2.41.
+glibc 2.42.
@end itemize
Portability problems not fixed by Gnulib:
another writer is already waiting to take it, this function may return
successfully immediately) -- a behaviour that may lead to writer starvation --
on some platforms:
-glibc 2.41.
+glibc 2.42.
@end itemize
Portability problems not fixed by Gnulib:
When not growing an already-allocated region, i.e.,
when @code{p} points to a region of size @code{psize} and @code{n <= psize},
@code{realloc (p, n)} can fail and return a null pointer:
-glibc 2.41 and probably other platforms.
+glibc 2.42 and probably other platforms.
@end itemize
@item
When not growing an already-allocated region,
@code{reallocarray}, like @code{realloc}, can fail and return a null pointer:
-glibc 2.41 and probably other platforms.
+glibc 2.42 and probably other platforms.
@end itemize
@itemize
@item
This function is missing on many platforms:
-glibc 2.41, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Cygwin 3.2.x, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Cygwin 3.2.x, mingw, MSVC 14, Android 9.0.
@end itemize
Portability problems not fixed by Gnulib:
@itemize
@item
This function is missing on many platforms:
-glibc 2.41, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Cygwin 3.2.x, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Cygwin 3.2.x, mingw, MSVC 14, Android 9.0.
@end itemize
Portability problems not fixed by Gnulib:
@itemize
@item
This function is missing on many platforms:
-glibc 2.41, macOS 14, FreeBSD 12.0, NetBSD 8.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 12.0, NetBSD 8.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
@end itemize
@itemize
@item
This function is missing on many platforms:
-glibc 2.41, macOS 14, FreeBSD 12.0, NetBSD 8.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 12.0, NetBSD 8.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 3.5.3, mingw, MSVC 14, Android 9.0.
@end itemize
@itemize
@item
This header file is missing on many platforms:
-glibc 2.41, macOS 14, FreeBSD 9.3, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 2.6.0, mingw, MSVC 14, Android 9.0.
+glibc 2.42, macOS 14, FreeBSD 9.3, NetBSD 10.0, OpenBSD 7.5, Minix 3.3.0, AIX 7.3.1, HP-UX 11.31, Solaris 11.4, Cygwin 2.6.0, mingw, MSVC 14, Android 9.0.
@end itemize
@item
@samp{O_EXEC} is not defined on some platforms:
-glibc 2.41, macOS 12, FreeBSD 7.4, NetBSD 9.4, OpenBSD 7.5, HP-UX 11, Solaris 10, Cygwin 1.5.x, mingw, MSVC 14, Android.
+glibc 2.42, macOS 12, FreeBSD 7.4, NetBSD 9.4, OpenBSD 7.5, HP-UX 11, Solaris 10, Cygwin 1.5.x, mingw, MSVC 14, Android.
However, glibc does define @samp{O_EXEC} on GNU/Hurd.
When not otherwise defined,
Gnulib defines this macro to @samp{O_RDONLY}, which is typically 0.
@item
@samp{O_SEARCH} is not defined on some platforms:
-glibc 2.41, macOS 12, FreeBSD 12.4, NetBSD 6.1, OpenBSD 7.5, AIX 6.1, HP-UX 11, Solaris 10, Cygwin 1.5.x, mingw, MSVC 14, Android.
+glibc 2.42, macOS 12, FreeBSD 12.4, NetBSD 6.1, OpenBSD 7.5, AIX 6.1, HP-UX 11, Solaris 10, Cygwin 1.5.x, mingw, MSVC 14, Android.
When not otherwise defined,
Gnulib defines this macro to @samp{O_RDONLY}, which is typically 0.
Although POSIX.1-2024 standardized @code{O_CLOFORK},
@code{FD_CLOFORK} and @code{F_DUPFD_CLOFORK},
they are not defined on most platforms:
-glibc 2.41, musl libc, macOS 15.5, FreeBSD 14.2, NetBSD 10.1, OpenBSD 7.7, Minix 3.3.0, AIX 7.3, Solaris 11.3, Cygwin 3.6.2, mingw, MSVC 14.
+glibc 2.42, musl libc, macOS 15.5, FreeBSD 14.2, NetBSD 10.1, OpenBSD 7.7, Minix 3.3.0, AIX 7.3, Solaris 11.3, Cygwin 3.6.2, mingw, MSVC 14.
@item
@samp{F_SETFD}, @samp{F_GETFL}, @samp{F_SETFL}, @samp{F_GETLK},
@item
The constants @code{ABALTMON_1} to @code{ABALTMON_12} are not defined on many
platforms:
-glibc 2.41, musl libc, macOS 14, NetBSD 10.0, OpenBSD 7.6, AIX 7.3, HP-UX 11.31, Solaris 11.4, Haiku, Cygwin 3.5.
+glibc 2.42, musl libc, macOS 14, NetBSD 10.0, OpenBSD 7.6, AIX 7.3, HP-UX 11.31, Solaris 11.4, Haiku, Cygwin 3.5.
@item
The constants @code{ERA}, @code{ERA_D_FMT}, @code{ERA_D_T_FMT},
@code{ERA_T_FMT}, @code{ALT_DIGITS} are not defined on some platforms:
On some systems that support GNU extensions, @code{RE_SYNTAX_EMACS} is 0
even though it should be @code{(RE_CHAR_CLASSES | RE_INTERVALS)}
to be compatible with Emacs 21 (2001) and later:
-glibc 2.41, Cygwin 2.6.x.
+glibc 2.42, Cygwin 2.6.x.
@end itemize
Portability problems not fixed by Gnulib:
The macro @code{WCOREDUMP} is not defined in this header file (only in
@code{<sys/wait.h>}) on some platforms:
@c https://sourceware.org/PR32551
-glibc 2.41.
+glibc 2.42.
@end itemize
Portability problems not fixed by Gnulib:
@item
This header file does not define the constant @code{SOCK_CLOFORK}
on some platforms:
-glibc 2.41, musl libc, macOS, FreeBSD, NetBSD, OpenBSD, AIX, Solaris 11.3, Cygwin, mingw, MSVC, Android.
+glibc 2.42, musl libc, macOS, FreeBSD, NetBSD, OpenBSD, AIX, Solaris 11.3, Cygwin, mingw, MSVC, Android.
@item
This header file does not define the constant @code{MSG_CMSG_CLOFORK}
on some platforms:
-glibc 2.41, musl libc, macOS, FreeBSD, NetBSD, OpenBSD, AIX, Solaris 11.4, Cygwin, mingw, MSVC, Android.
+glibc 2.42, musl libc, macOS, FreeBSD, NetBSD, OpenBSD, AIX, Solaris 11.4, Cygwin, mingw, MSVC, Android.
@end itemize
@item
This header file causes compilation errors in C++ mode on some platforms:
@c https://sourceware.org/PR32024
-glibc 2.41.
+glibc 2.42.
@end itemize
Portability problems not fixed by Gnulib:
mingw.
@item
This header file does not define @code{O_CLOEXEC} on some platforms:
-glibc 2.41, macOS 12, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, AIX 7.3, Solaris 11.4, Cygwin 3.5, mingw.
+glibc 2.42, macOS 12, FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5, AIX 7.3, Solaris 11.4, Cygwin 3.5, mingw.
@item
Some platforms provide a @code{NULL} macro that cannot be used in arbitrary
of type @code{struct timeval}. Instead, it is a different
struct with @code{tv_sec} and @code{tv_usec} members that may
have different types than the members of @code{struct timeval}:
-glibc 2.41 on platforms where @code{time_t} was historically 32 bits
+glibc 2.42 on platforms where @code{time_t} was historically 32 bits
and where log file formats were not changed when 64-bit @code{time_t}
was introduced.
@item