nptl: Make pthread_attr_t dynamically extensible

System Internals / glibc - Florian Weimer [redhat.com] - 2 June 2020 09:54 UTC

This introduces the function __pthread_attr_extension to allocate the extension space, which is freed by pthread_attr_destroy.

7538d46113 nptl: Make pthread_attr_t dynamically extensible
nptl/Makefile | 1 +
nptl/pthreadP.h | 6 ++++++
nptl/pthread_attr_copy.c | 16 +++++++++-------
nptl/pthread_attr_destroy.c | 12 ++++++++----
nptl/pthread_attr_extension.c | 32 ++++++++++++++++++++++++++++++++
nptl/pthread_attr_getaffinity.c | 14 +++++++-------
nptl/pthread_attr_setaffinity.c | 23 +++++++++++++++--------
nptl/pthread_create.c | 2 +-
sysdeps/nptl/internaltypes.h | 16 +++++++++++++---
sysdeps/unix/sysv/linux/createthread.c | 9 ++++++---
10 files changed, 98 insertions(+), 33 deletions(-)

Upstream: sourceware.org


  • Share