From: Martin Quinson Date: Sat, 5 Jan 2019 01:21:19 +0000 (+0100) Subject: kill the unused xbt_os_thread_self_name() X-Git-Tag: v3_22~683 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/ffcbad0db753a75f3f04b2687bcef9127b1756b3 kill the unused xbt_os_thread_self_name() --- diff --git a/ChangeLog b/ChangeLog index 2a0cb75612..ad00e70ee9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -19,6 +19,10 @@ XBT: OsSemaphore is implemented in a portable way with C++11 threads. This should allow much more threads to be created at the same time, allowing Mac and Java users to simulate many more actors. + - Drop several unused xbt_os_thread_t functions: + - xbt_os_thread_get_extra_data() + - xbt_os_thread_set_extra_data() + - xbt_os_thread_self_name() Fixed bugs: - #261: Document the parameters of parallel execution's constructor diff --git a/include/xbt/xbt_os_thread.h b/include/xbt/xbt_os_thread.h index 3d0a2991fb..5c90354c6f 100644 --- a/include/xbt/xbt_os_thread.h +++ b/include/xbt/xbt_os_thread.h @@ -30,7 +30,6 @@ XBT_PUBLIC xbt_os_thread_t xbt_os_thread_create(const char* name, pvoid_f_pvoid_ XBT_PUBLIC void xbt_os_thread_exit(int* retcode); XBT_PUBLIC xbt_os_thread_t xbt_os_thread_self(void); -XBT_PUBLIC const char* xbt_os_thread_self_name(void); /* xbt_os_thread_join frees the joined thread (ie the XBT wrapper around it, the OS frees the rest) */ XBT_PUBLIC void xbt_os_thread_join(xbt_os_thread_t thread, void** thread_return); XBT_PUBLIC void xbt_os_thread_setstacksize(int stack_size); diff --git a/src/simix/smx_private.hpp b/src/simix/smx_private.hpp index 830a2f819d..cab1416f55 100644 --- a/src/simix/smx_private.hpp +++ b/src/simix/smx_private.hpp @@ -9,7 +9,6 @@ #include "simgrid/s4u/Actor.hpp" #include "src/kernel/context/Context.hpp" #include "src/simix/ActorImpl.hpp" -#include #include #include diff --git a/src/xbt/xbt_os_thread.c b/src/xbt/xbt_os_thread.c index 411aa1652f..a84ba938aa 100644 --- a/src/xbt/xbt_os_thread.c +++ b/src/xbt/xbt_os_thread.c @@ -202,12 +202,6 @@ void xbt_os_thread_setguardsize(int guard_size) #endif } -const char *xbt_os_thread_self_name(void) -{ - xbt_os_thread_t me = xbt_os_thread_self(); - return me ? (const char *)me->name : "main"; -} - void xbt_os_thread_join(xbt_os_thread_t thread, void **thread_return) { int errcode = pthread_join(thread->t, thread_return);