When building gdb using thread sanitizer and running the gdb test-suite, I run into a fair amount of these: ... SUMMARY: ThreadSanitizer: unlock of an unlocked mutex (or by a wrong thread) (/usr/lib64/libtsan.so.2+0x47361) in pthread_mutex_unlock SUMMARY: ThreadSanitizer: unlock of an unlocked mutex (or by a wrong thread) (/usr/lib64/libtsan.so.2+0x47361) in pthread_mutex_unlock SUMMARY: ThreadSanitizer: unlock of an unlocked mutex (or by a wrong thread) (/usr/lib64/libtsan.so.2+0x47361) in pthread_mutex_unlock SUMMARY: ThreadSanitizer: unlock of an unlocked mutex (or by a wrong thread) (/usr/lib64/libtsan.so.2+0x47361) in pthread_mutex_unlock SUMMARY: ThreadSanitizer: unlock of an unlocked mutex (or by a wrong thread) (/usr/lib64/libtsan.so.2+0x47361) in pthread_mutex_unlock SUMMARY: ThreadSanitizer: unlock of an unlocked mutex (or by a wrong thread) (/usr/lib64/libtsan.so.2+0x47361) in pthread_mutex_unlock SUMMARY: ThreadSanitizer: unlock of an unlocked mutex (or by a wrong thread) (/usr/lib64/libtsan.so.2+0x47361) in pthread_mutex_unlock SUMMARY: ThreadSanitizer: unlock of an unlocked mutex (or by a wrong thread) (/usr/lib64/libtsan.so.2+0x47361) in pthread_mutex_unlock SUMMARY: ThreadSanitizer: unlock of an unlocked mutex (or by a wrong thread) (/usr/lib64/libtsan.so.2+0x47361) in pthread_mutex_unlock SUMMARY: ThreadSanitizer: unlock of an unlocked mutex (or by a wrong thread) (/usr/lib64/libtsan.so.2+0x47361) in pthread_mutex_unlock SUMMARY: ThreadSanitizer: unlock of an unlocked mutex (or by a wrong thread) (/usr/lib64/libtsan.so.2+0x47361) in pthread_mutex_unlock SUMMARY: ThreadSanitizer: unlock of an unlocked mutex (or by a wrong thread) (/usr/lib64/libtsan.so.2+0x47361) in pthread_mutex_unlock ... AFAICT, this is a problem in ncurses. I've sent an email to bug-ncurses@gnu.org , I'll post a link once it's published in the archives.
(In reply to Tom de Vries from comment #0) > AFAICT, this is a problem in ncurses. I've sent an email to > bug-ncurses@gnu.org , I'll post a link once it's published in the archives. https://lists.gnu.org/archive/html/bug-ncurses/2022-07/msg00002.html
Patch to add suppression in new tsan-suppressions.txt file: https://sourceware.org/pipermail/gdb-patches/2022-July/190619.html
Not a gdb problem, reclassifying as testsuite problem.
https://sourceware.org/git/?p=binutils-gdb.git;a=commit;h=09559238fdcca6ffa2ddfdd6a89ac919a9ccb80d