Add pthread_getname_np() and pthread_setname_np() aliases

for pthread_get_name_np() and pthread_set_name_np(), to be
compatible with Linux.

PR:	238404
Proposed and reviewed by:	markj
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
Differential revision:	https://reviews.freebsd.org/D25117
This commit is contained in:
Konstantin Belousov
2020-06-03 20:54:36 +00:00
parent 3f65edb369
commit 9bed49fea4
5 changed files with 27 additions and 4 deletions
+2
View File
@@ -50,6 +50,7 @@ int pthread_attr_get_np(pthread_t, pthread_attr_t *);
int pthread_attr_getaffinity_np(const pthread_attr_t *, size_t, cpuset_t *);
int pthread_attr_setaffinity_np(pthread_attr_t *, size_t, const cpuset_t *);
void pthread_get_name_np(pthread_t, char *, size_t);
void pthread_getname_np(pthread_t, char *, size_t);
int pthread_getaffinity_np(pthread_t, size_t, cpuset_t *);
int pthread_getthreadid_np(void);
int pthread_main_np(void);
@@ -65,6 +66,7 @@ void pthread_resume_all_np(void);
int pthread_resume_np(pthread_t);
int pthread_peekjoin_np(pthread_t, void **);
void pthread_set_name_np(pthread_t, const char *);
void pthread_setname_np(pthread_t, const char *);
int pthread_setaffinity_np(pthread_t, size_t, const cpuset_t *);
int pthread_single_np(void);
void pthread_suspend_all_np(void);