1 2 3 4 5 6 7
#include <pthread.h> #include <pthread_np.h> int main() { pthread_set_name_np(pthread_self(), "abc"); return 0; }