Some versions of pthreads (e.g. on Linux x86_64) have pthread_setname_np(), which allows to set thread name. Some tools like gdb can use it to display friendly name for thread. Please add support for it in Valgrind too, to capture and display thread names in helgrind and drd tools. BTW, Valgrind currently supports ANNOTATE_THREAD_NAME() which provide similar functionality. However this is limited to drd tool only, and requires modification to user program.
I thought we already did support this, by intercepting the underlying system call. Are you sure this doesn't work?
I use Valgrind 3.13.0 (shipped with CentOS 7.5) and it does not work there. Looks that something is still broken, at least in Helgrind. BTW, I found that I logged Bug 323046 few years ago for the same issue. You can mark is as a duplicate.
*** Bug 323046 has been marked as a duplicate of this bug. ***