1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-07-30 22:43:12 +03:00
* pthread_create.c (deallocate_tsd): Mark as internal_function.
	Add some more __builtin_expect.
This commit is contained in:
Ulrich Drepper
2003-02-18 11:12:34 +00:00
parent 729924a042
commit ba25bb0f1d
2 changed files with 6 additions and 1 deletions

View File

@ -1,5 +1,8 @@
2003-02-18 Ulrich Drepper <drepper@redhat.com> 2003-02-18 Ulrich Drepper <drepper@redhat.com>
* pthread_create.c (deallocate_tsd): Mark as internal_function.
Add some more __builtin_expect.
* pthreadP.h: Define dummy versio of DEBUGGING_P. * pthreadP.h: Define dummy versio of DEBUGGING_P.
2003-02-17 Ulrich Drepper <drepper@redhat.com> 2003-02-17 Ulrich Drepper <drepper@redhat.com>

View File

@ -107,6 +107,7 @@ __find_in_stack_list (pd)
/* Deallocate POSIX thread-local-storage. */ /* Deallocate POSIX thread-local-storage. */
static void static void
internal_function
deallocate_tsd (struct pthread *pd) deallocate_tsd (struct pthread *pd)
{ {
/* Maybe no data was ever allocated. This happens often so we have /* Maybe no data was ever allocated. This happens often so we have
@ -180,7 +181,8 @@ internal_function
__free_tcb (struct pthread *pd) __free_tcb (struct pthread *pd)
{ {
/* The thread is exiting now. */ /* The thread is exiting now. */
if (atomic_bit_test_set (&pd->cancelhandling, TERMINATED_BIT) == 0) if (__builtin_expect (atomic_bit_test_set (&pd->cancelhandling,
TERMINATED_BIT) == 0, 1))
{ {
/* Remove the descriptor from the list. */ /* Remove the descriptor from the list. */
if (DEBUGGING_P && __find_in_stack_list (pd) == NULL) if (DEBUGGING_P && __find_in_stack_list (pd) == NULL)