1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-07-29 11:41:21 +03:00

nptl: Remove internal_function attribute

This commit is contained in:
Florian Weimer
2017-08-31 17:50:26 +02:00
parent 116ac301b1
commit 83b09837ed
9 changed files with 34 additions and 32 deletions

View File

@ -1,3 +1,23 @@
2017-08-31 Florian Weimer <fweimer@redhat.com>
* nptl/allocatestack.c (change_stack_perm, __deallocate_stack)
(setxid_mark_thread, setxid_unmark_thread, setxid_signal_thread):
Remove internal_function.
* nptl/cancellation.c (__pthread_disable_asynccancel): Likewise.
* nptl/libc_pthread_init.c (__libc_pthread_init): Likewise.
* nptl/pthreadP.h (__find_in_stack_list, __free_tcb)
(__deallocate_stack, __libc_pthread_init)
(__pthread_mutex_cond_lock, __pthread_mutex_cond_lock_adjust)
(__pthread_mutex_unlock_usercnt, __pthread_disable_asynccancel)
(__libc_disable_asynccancel, __librt_disable_asynccancel):
Likewise.
* nptl/pthread_create.c (__find_in_stack_list, __free_tcb): Likewise.
* nptl/pthread_mutex_cond_lock.c (__pthread_mutex_lock): Likewise.
* nptl/pthread_mutex_lock.c (__pthread_mutex_cond_lock_adjust):
Likewise.
* nptl/pthread_mutex_unlock.c (__pthread_mutex_unlock_full)
(__pthread_mutex_unlock_usercnt): Likewise.
2017-08-31 Florian Weimer <fweimer@redhat.com> 2017-08-31 Florian Weimer <fweimer@redhat.com>
* io/fts.c (fts_alloc, fts_build, fts_lfree, fts_load) * io/fts.c (fts_alloc, fts_build, fts_lfree, fts_load)

View File

@ -307,7 +307,6 @@ queue_stack (struct pthread *stack)
static int static int
internal_function
change_stack_perm (struct pthread *pd change_stack_perm (struct pthread *pd
#ifdef NEED_SEPARATE_REGISTER_STACK #ifdef NEED_SEPARATE_REGISTER_STACK
, size_t pagemask , size_t pagemask
@ -787,7 +786,6 @@ allocate_stack (const struct pthread_attr *attr, struct pthread **pdp,
void void
internal_function
__deallocate_stack (struct pthread *pd) __deallocate_stack (struct pthread *pd)
{ {
lll_lock (stack_cache_lock, LLL_PRIVATE); lll_lock (stack_cache_lock, LLL_PRIVATE);
@ -1016,7 +1014,6 @@ __find_thread_by_id (pid_t tid)
#ifdef SIGSETXID #ifdef SIGSETXID
static void static void
internal_function
setxid_mark_thread (struct xid_command *cmdp, struct pthread *t) setxid_mark_thread (struct xid_command *cmdp, struct pthread *t)
{ {
int ch; int ch;
@ -1054,7 +1051,6 @@ setxid_mark_thread (struct xid_command *cmdp, struct pthread *t)
static void static void
internal_function
setxid_unmark_thread (struct xid_command *cmdp, struct pthread *t) setxid_unmark_thread (struct xid_command *cmdp, struct pthread *t)
{ {
int ch; int ch;
@ -1075,7 +1071,6 @@ setxid_unmark_thread (struct xid_command *cmdp, struct pthread *t)
static int static int
internal_function
setxid_signal_thread (struct xid_command *cmdp, struct pthread *t) setxid_signal_thread (struct xid_command *cmdp, struct pthread *t)
{ {
if ((t->cancelhandling & SETXID_BITMASK) == 0) if ((t->cancelhandling & SETXID_BITMASK) == 0)

View File

@ -61,7 +61,7 @@ __pthread_enable_asynccancel (void)
void void
internal_function attribute_hidden attribute_hidden
__pthread_disable_asynccancel (int oldtype) __pthread_disable_asynccancel (int oldtype)
{ {
/* If asynchronous cancellation was enabled before we do not have /* If asynchronous cancellation was enabled before we do not have

View File

@ -38,7 +38,6 @@ extern int __libc_multiple_threads attribute_hidden;
int * int *
#endif #endif
internal_function
__libc_pthread_init (unsigned long int *ptr, void (*reclaim) (void), __libc_pthread_init (unsigned long int *ptr, void (*reclaim) (void),
const struct pthread_functions *functions) const struct pthread_functions *functions)
{ {

View File

@ -341,15 +341,14 @@ __do_cancel (void)
/* Thread list handling. */ /* Thread list handling. */
extern struct pthread *__find_in_stack_list (struct pthread *pd) extern struct pthread *__find_in_stack_list (struct pthread *pd)
attribute_hidden internal_function; attribute_hidden;
/* Deallocate a thread's stack after optionally making sure the thread /* Deallocate a thread's stack after optionally making sure the thread
descriptor is still valid. */ descriptor is still valid. */
extern void __free_tcb (struct pthread *pd) attribute_hidden internal_function; extern void __free_tcb (struct pthread *pd) attribute_hidden;
/* Free allocated stack. */ /* Free allocated stack. */
extern void __deallocate_stack (struct pthread *pd) extern void __deallocate_stack (struct pthread *pd) attribute_hidden;
attribute_hidden internal_function;
/* Mark all the stacks except for the current one as available. This /* Mark all the stacks except for the current one as available. This
function also re-initializes the lock for the stack cache. */ function also re-initializes the lock for the stack cache. */
@ -386,13 +385,11 @@ hidden_proto (__nptl_death_event)
#ifdef TLS_MULTIPLE_THREADS_IN_TCB #ifdef TLS_MULTIPLE_THREADS_IN_TCB
extern void __libc_pthread_init (unsigned long int *ptr, extern void __libc_pthread_init (unsigned long int *ptr,
void (*reclaim) (void), void (*reclaim) (void),
const struct pthread_functions *functions) const struct pthread_functions *functions);
internal_function;
#else #else
extern int *__libc_pthread_init (unsigned long int *ptr, extern int *__libc_pthread_init (unsigned long int *ptr,
void (*reclaim) (void), void (*reclaim) (void),
const struct pthread_functions *functions) const struct pthread_functions *functions);
internal_function;
/* Variable set to a nonzero value either if more than one thread runs or ran, /* Variable set to a nonzero value either if more than one thread runs or ran,
or if a single-threaded process is trying to cancel itself. See or if a single-threaded process is trying to cancel itself. See
@ -430,13 +427,12 @@ extern int __pthread_mutex_lock (pthread_mutex_t *__mutex);
extern int __pthread_mutex_timedlock (pthread_mutex_t *__mutex, extern int __pthread_mutex_timedlock (pthread_mutex_t *__mutex,
const struct timespec *__abstime); const struct timespec *__abstime);
extern int __pthread_mutex_cond_lock (pthread_mutex_t *__mutex) extern int __pthread_mutex_cond_lock (pthread_mutex_t *__mutex)
attribute_hidden internal_function; attribute_hidden;
extern void __pthread_mutex_cond_lock_adjust (pthread_mutex_t *__mutex) extern void __pthread_mutex_cond_lock_adjust (pthread_mutex_t *__mutex)
attribute_hidden internal_function; attribute_hidden;
extern int __pthread_mutex_unlock (pthread_mutex_t *__mutex); extern int __pthread_mutex_unlock (pthread_mutex_t *__mutex);
extern int __pthread_mutex_unlock_usercnt (pthread_mutex_t *__mutex, extern int __pthread_mutex_unlock_usercnt (pthread_mutex_t *__mutex,
int __decr) int __decr) attribute_hidden;
attribute_hidden internal_function;
extern int __pthread_mutexattr_init (pthread_mutexattr_t *attr); extern int __pthread_mutexattr_init (pthread_mutexattr_t *attr);
extern int __pthread_mutexattr_destroy (pthread_mutexattr_t *attr); extern int __pthread_mutexattr_destroy (pthread_mutexattr_t *attr);
extern int __pthread_mutexattr_settype (pthread_mutexattr_t *attr, int kind); extern int __pthread_mutexattr_settype (pthread_mutexattr_t *attr, int kind);
@ -508,8 +504,7 @@ extern void __pthread_exit (void *value) __attribute__ ((__noreturn__));
extern int __pthread_join (pthread_t threadid, void **thread_return); extern int __pthread_join (pthread_t threadid, void **thread_return);
extern int __pthread_setcanceltype (int type, int *oldtype); extern int __pthread_setcanceltype (int type, int *oldtype);
extern int __pthread_enable_asynccancel (void) attribute_hidden; extern int __pthread_enable_asynccancel (void) attribute_hidden;
extern void __pthread_disable_asynccancel (int oldtype) extern void __pthread_disable_asynccancel (int oldtype) attribute_hidden;
internal_function attribute_hidden;
extern void __pthread_testcancel (void); extern void __pthread_testcancel (void);
#if IS_IN (libpthread) #if IS_IN (libpthread)
@ -547,14 +542,12 @@ extern int __pthread_getaffinity_np (pthread_t th, size_t cpusetsize,
/* The two functions are in libc.so and not exported. */ /* The two functions are in libc.so and not exported. */
extern int __libc_enable_asynccancel (void) attribute_hidden; extern int __libc_enable_asynccancel (void) attribute_hidden;
extern void __libc_disable_asynccancel (int oldtype) extern void __libc_disable_asynccancel (int oldtype) attribute_hidden;
internal_function attribute_hidden;
/* The two functions are in librt.so and not exported. */ /* The two functions are in librt.so and not exported. */
extern int __librt_enable_asynccancel (void) attribute_hidden; extern int __librt_enable_asynccancel (void) attribute_hidden;
extern void __librt_disable_asynccancel (int oldtype) extern void __librt_disable_asynccancel (int oldtype) attribute_hidden;
internal_function attribute_hidden;
#if IS_IN (libpthread) #if IS_IN (libpthread)
/* Special versions which use non-exported functions. */ /* Special versions which use non-exported functions. */

View File

@ -205,7 +205,6 @@ static int create_thread (struct pthread *pd, const struct pthread_attr *attr,
struct pthread * struct pthread *
internal_function
__find_in_stack_list (struct pthread *pd) __find_in_stack_list (struct pthread *pd)
{ {
list_t *entry; list_t *entry;
@ -341,7 +340,6 @@ __nptl_deallocate_tsd (void)
/* Deallocate a thread's stack after optionally making sure the thread /* Deallocate a thread's stack after optionally making sure the thread
descriptor is still valid. */ descriptor is still valid. */
void void
internal_function
__free_tcb (struct pthread *pd) __free_tcb (struct pthread *pd)
{ {
/* The thread is exiting now. */ /* The thread is exiting now. */

View File

@ -14,7 +14,7 @@
/* We need to assume that there are other threads blocked on the futex. /* We need to assume that there are other threads blocked on the futex.
See __pthread_mutex_lock_full for further details. */ See __pthread_mutex_lock_full for further details. */
#define LLL_ROBUST_MUTEX_LOCK_MODIFIER FUTEX_WAITERS #define LLL_ROBUST_MUTEX_LOCK_MODIFIER FUTEX_WAITERS
#define __pthread_mutex_lock internal_function __pthread_mutex_cond_lock #define __pthread_mutex_lock __pthread_mutex_cond_lock
#define __pthread_mutex_lock_full __pthread_mutex_cond_lock_full #define __pthread_mutex_lock_full __pthread_mutex_cond_lock_full
#define NO_INCR #define NO_INCR

View File

@ -607,7 +607,6 @@ hidden_def (__pthread_mutex_lock)
#ifdef NO_INCR #ifdef NO_INCR
void void
internal_function
__pthread_mutex_cond_lock_adjust (pthread_mutex_t *mutex) __pthread_mutex_cond_lock_adjust (pthread_mutex_t *mutex)
{ {
assert ((mutex->__data.__kind & PTHREAD_MUTEX_PRIO_INHERIT_NP) != 0); assert ((mutex->__data.__kind & PTHREAD_MUTEX_PRIO_INHERIT_NP) != 0);

View File

@ -28,12 +28,11 @@
#endif #endif
static int static int
internal_function
__pthread_mutex_unlock_full (pthread_mutex_t *mutex, int decr) __pthread_mutex_unlock_full (pthread_mutex_t *mutex, int decr)
__attribute_noinline__; __attribute_noinline__;
int int
internal_function attribute_hidden attribute_hidden
__pthread_mutex_unlock_usercnt (pthread_mutex_t *mutex, int decr) __pthread_mutex_unlock_usercnt (pthread_mutex_t *mutex, int decr)
{ {
int type = PTHREAD_MUTEX_TYPE_ELISION (mutex); int type = PTHREAD_MUTEX_TYPE_ELISION (mutex);
@ -92,7 +91,6 @@ __pthread_mutex_unlock_usercnt (pthread_mutex_t *mutex, int decr)
static int static int
internal_function
__pthread_mutex_unlock_full (pthread_mutex_t *mutex, int decr) __pthread_mutex_unlock_full (pthread_mutex_t *mutex, int decr)
{ {
int newowner = 0; int newowner = 0;