about summary refs log tree commit diff
path: root/nptl
Commit message (Collapse)AuthorAgeFilesLines
* nptl: Move pthread_attr_getstackaddr into libcFlorian Weimer2021-05-113-4/+10
| | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move pthread_attr_getstack into libcFlorian Weimer2021-05-113-4/+10
| | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move pthread_attr_getguardsize into libcFlorian Weimer2021-05-113-4/+11
| | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move pthread_attr_getaffinity_np into libcFlorian Weimer2021-05-113-5/+10
| | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move thread join functions into libcFlorian Weimer2021-05-118-31/+77
| | | | | | | | | | | The symbols pthread_clockjoin_np, pthread_join, pthread_timedjoin_np, pthread_tryjoin_np, thrd_join were moved using scripts/move-symbol-to-libc.py. Moving the symbols at the same time avoids the need for temporary exports. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move pthread_detach, thrd_detach into libcFlorian Weimer2021-05-114-6/+17
| | | | | | The symbols were moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move __free_tcb into libcFlorian Weimer2021-05-117-29/+52
| | | | | | Under the name __nptl_free_tcb. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move stack cache management, __libpthread_freeres into libcFlorian Weimer2021-05-119-153/+202
| | | | | | | | | | | | | This replaces the FREE_P macro with the __nptl_stack_in_use inline function. stack_list_del is renamed to __nptl_stack_list_del, stack_list_add to __nptl_stack_list_add, __deallocate_stack to __nptl_deallocate_stack, free_stacks to __nptl_free_stacks. It is convenient to move __libpthread_freeres into libc at the same time. This removes the temporary __default_pthread_attr_freeres export and restores full freeres coverage for __default_pthread_attr. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move pthread_setattr_default_np into libcFlorian Weimer2021-05-114-6/+16
| | | | | | | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. The export of __default_pthread_attr_freeres is temporary. There is a minor regression in freeres coverage because in the dynamic case, __default_pthread_attr_freeres is no longer called if libpthread is not linked in. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Remove always-disabled debugging supportFlorian Weimer2021-05-113-75/+5
| | | | | | | This removes the DEBUGGING_P macro and the __pthread_debug variable. The __find_in_stack_list function is now unused and deleted as well. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Replace pthread_sigqueue implementation with Linux oneFlorian Weimer2021-05-111-4/+38
| | | | Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* linux: Move funlockfile/_IO_funlockfile into libcAdhemerval Zanella2021-05-101-1/+0
| | | | | | | | | | The nptl version is used as default, since now with symbol always present the single-thread optimization is tricky. Hurd is not change, it is used it own lock scheme (which call _cthreads_funlockfile). Checked on x86_64-linux-gnu.
* linux: Move ftrylockfile/_IO_ftrylockfile into libcAdhemerval Zanella2021-05-101-1/+0
| | | | | | | | | | The nptl version is used as default, since now with symbol always present the single-thread optimization is tricky. Hurd is not change, it is used it own lock scheme (which call _cthreads_ftrylockfile). Checked on x86_64-linux-gnu.
* linux: Move flockfile/_IO_flockfile into libcAdhemerval Zanella2021-05-101-2/+0
| | | | | | | | | | The nptl version is used as default, since now with symbol always present the single-thread optimization is tricky. Hurd is not change, it is used it own lock scheme (which call _cthreads_flockfile). Checked on x86_64-linux-gnu.
* Linux: Move __reclaim_stacks into the fork implementation in libcFlorian Weimer2021-05-104-119/+0
| | | | | | | As a result, __libc_pthread_init is no longer needed. Tested-by: Carlos O'Donell <carlos@redhat.com> Reviewed-by: Carlos O'Donell <carlos@redhat.com>
* nptl: Move __default_pthread_attr, __default_pthread_attr_lock into libcFlorian Weimer2021-05-104-6/+14
| | | | | | | | The GLIBC_PRIVATE exports for these symbols are expected to be temporary. Tested-by: Carlos O'Donell <carlos@redhat.com> Reviewed-by: Carlos O'Donell <carlos@redhat.com>
* nptl: Simplify resetting the in-flight stack in __reclaim_stacksFlorian Weimer2021-05-101-3/+3
| | | | | | | stack_list_del overwrites the in-flight stack variable. Tested-by: Carlos O'Donell <carlos@redhat.com> Reviewed-by: Carlos O'Donell <carlos@redhat.com>
* nptl: Move changing of stack permissions into ld.soFlorian Weimer2021-05-103-68/+6
| | | | | | | | | All the stack lists are now in _rtld_global, so it is possible to change stack permissions directly from there, instead of calling into libpthread to do the change. Tested-by: Carlos O'Donell <carlos@redhat.com> Reviewed-by: Carlos O'Donell <carlos@redhat.com>
* nptl: Simplify the change_stack_perm calling conventionFlorian Weimer2021-05-101-24/+5
| | | | | | | | Only ia64 needs the page mask, and it is straightforward to compute the value within the function itself. Tested-by: Carlos O'Donell <carlos@redhat.com> Reviewed-by: Carlos O'Donell <carlos@redhat.com>
* nptl: Move more stack management variables into _rtld_globalFlorian Weimer2021-05-101-30/+21
| | | | | | | | | | | | Permissions of the cached stacks may have to be updated if an object is loaded that requires executable stacks, so the dynamic loader needs to know about these cached stacks. The move of in_flight_stack and stack_cache_actsize is a requirement for merging __reclaim_stacks into the fork implementation in libc. Tested-by: Carlos O'Donell <carlos@redhat.com> Reviewed-by: Carlos O'Donell <carlos@redhat.com>
* nptl: Eliminate __pthread_multiple_threadsFlorian Weimer2021-05-104-17/+3
| | | | | | | It is no longer needed after the SINGLE_THREADED_P consolidation. Tested-by: Carlos O'Donell <carlos@redhat.com> Reviewed-by: Carlos O'Donell <carlos@redhat.com>
* nptl: Export __libc_multiple_threads from libc as an internal symbolFlorian Weimer2021-05-107-29/+8
| | | | | | | | This allows the elimination of the __libc_multiple_threads_ptr variable in libpthread and its initialization procedure. Tested-by: Carlos O'Donell <carlos@redhat.com> Reviewed-by: Carlos O'Donell <carlos@redhat.com>
* elf, nptl: Resolve recursive lock implementation earlyFlorian Weimer2021-05-101-9/+0
| | | | | | | | | | | If libpthread is included in libc, it is not necessary to delay initialization of the lock/unlock function pointers until libpthread is loaded. This eliminates two unprotected function pointers from _rtld_global and removes some initialization code from libpthread. Tested-by: Carlos O'Donell <carlos@redhat.com> Reviewed-by: Carlos O'Donell <carlos@redhat.com>
* nptl: Move pthread_barrierattr_setpshared into libcFlorian Weimer2021-05-063-4/+12
| | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move pthread_barrierattr_getpshared into libcFlorian Weimer2021-05-063-4/+12
| | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move pthread_barrierattr_init into libcFlorian Weimer2021-05-063-4/+12
| | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move pthread_barrierattr_destroy into libcFlorian Weimer2021-05-063-4/+12
| | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move pthread_barrier_wait into libcFlorian Weimer2021-05-063-5/+16
| | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move pthread_barrier_init into libcFlorian Weimer2021-05-063-6/+16
| | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move pthread_barrier_destroy into libcFlorian Weimer2021-05-063-4/+12
| | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move sem_trywait, sem_wait into libcFlorian Weimer2021-05-053-9/+20
| | | | | | The symbols were moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move sem_unlink into libcFlorian Weimer2021-05-053-2/+8
| | | | | | | | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. A small adjust to the sem_unlink implementation is necessary to avoid a check-localplt failure. A placeholder symbol to keep the GLIBC_2.1.1 version alive in libpthread is added with this commit. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move sem_timedwait into libcFlorian Weimer2021-05-054-8/+17
| | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move sem_post into libcFlorian Weimer2021-05-053-5/+9
| | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move sem_init into libcFlorian Weimer2021-05-053-6/+9
| | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move sem_getvalue into libcFlorian Weimer2021-05-053-5/+11
| | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move sem_destroy into libcFlorian Weimer2021-05-053-5/+9
| | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move sem_close, sem_open into libcFlorian Weimer2021-05-052-5/+9
| | | | | | | | | | | The symbols were moved using move-symbol-to-libc.py. Both functions are moved at the same time because they depend on internal functions in sysdeps/pthread/sem_routines.c, which are moved in this commit as well. Additional hidden prototypes are required to avoid check-localplt failures. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move sem_clockwait into libcFlorian Weimer2021-05-055-8/+20
| | | | | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. A new placeholder version is added at version GLIBC_2.30, to preserve that version in libpthread.so.0. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Consolidate async cancel enable/disable implementation in libcFlorian Weimer2021-05-056-33/+7
| | | | | | | | | | | | | | Previously, the source file nptl/cancellation.c was compiled multiple times, for libc, libpthread, librt. This commit switches to a single implementation, with new __pthread_enable_asynccancel@@GLIBC_PRIVATE, __pthread_disable_asynccancel@@GLIBC_PRIVATE exports. The almost-unused CANCEL_ASYNC and CANCEL_RESET macros are replaced by LIBC_CANCEL_ASYNC and LIBC_CANCEL_ASYNC macros. They call the __pthread_* functions unconditionally now. The macros are still needed because shared code uses them; Hurd has different definitions. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* nptl: Move pthread_testcancel into libcFlorian Weimer2021-05-054-7/+15
| | | | | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. A temporary __pthread_testcancel@@GLIBC_PRIVATE export is created because it is needed by the semaphore implementation. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
* elf, nptl: Initialize static TLS directly in ld.soFlorian Weimer2021-05-053-39/+0
| | | | | | | | | | The stack list is available in ld.so since commit 1daccf403b1bd86370eb94edca794dc106d02039 ("nptl: Move stack list variables into _rtld_global"), so it's possible to walk the stack list directly in ld.so and perform the initialization there. This eliminates an unprotected function pointer from _rtld_global and reduces the libpthread initialization code.
* nptl: Re-sort Versions fileFlorian Weimer2021-05-031-2/+2
| | | | | Due to an incorrect conflict resolution, libc/GLIBC_2.2 section was no longer sorted lexicographically.
* nptl: Move pthread_yield into libc, as a compatibility symbolFlorian Weimer2021-05-033-7/+11
| | | | | | | | | | | | | And deprecate it in <pthread.h>, redirecting it to sched_yield for the time being. The symbol was moved using scripts/move-symbol-to-libc.py. No GLIBC_2.34 symbol version is added because of the compatibility symbol status. Reviewed-by: Carlos O'Donell <carlos@redhat.com> Tested-by: Carlos O'Donell <carlos@redhat.com>
* nptl: Move pthread_rwlockattr_setpshared into libcFlorian Weimer2021-05-033-4/+12
| | | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Carlos O'Donell <carlos@redhat.com> Tested-by: Carlos O'Donell <carlos@redhat.com>
* nptl: Move pthread_rwlockattr_setkind_np into libcFlorian Weimer2021-05-033-4/+12
| | | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Carlos O'Donell <carlos@redhat.com> Tested-by: Carlos O'Donell <carlos@redhat.com>
* nptl: Move pthread_rwlockattr_init into libcFlorian Weimer2021-05-033-4/+12
| | | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Carlos O'Donell <carlos@redhat.com> Tested-by: Carlos O'Donell <carlos@redhat.com>
* nptl: Move pthread_rwlockattr_getpshared into libcFlorian Weimer2021-05-033-4/+13
| | | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Carlos O'Donell <carlos@redhat.com> Tested-by: Carlos O'Donell <carlos@redhat.com>
* nptl: Move pthread_rwlockattr_getkind_np into libcFlorian Weimer2021-05-033-4/+12
| | | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Carlos O'Donell <carlos@redhat.com> Tested-by: Carlos O'Donell <carlos@redhat.com>
* nptl: Move pthread_rwlockattr_destroy into libcFlorian Weimer2021-05-033-4/+12
| | | | | | | The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Carlos O'Donell <carlos@redhat.com> Tested-by: Carlos O'Donell <carlos@redhat.com>