Hi, The attached test programs exercise the thread-local storage (TLS) API and the thread-specific storage (TSS) API in libc. On Alpine Linux 3.7 and 2.9, these test programs, when run, produce this output: $ ./test-tls Starting test_tls ... OK Starting test_tls_dtorcheck1 ... OK Starting test_tls_dtorcheck2 ... OK Starting test_tls_racecheck ...Aborted $ ./test-tss Starting test_tss ... OK Starting test_tss_dtorcheck1 ... OK Starting test_tss_dtorcheck2 ... OK Starting test_tss_racecheck ...Aborted The expected output - like seen on glibc, macOS, FreeBSD, NetBSD, OpenBSD, AIX, HP-UX, IRIX, Solaris, Haiku, and Cygwin - is $ ./test-tls Starting test_tls ... OK Starting test_tls_dtorcheck1 ... OK Starting test_tls_dtorcheck2 ... OK Starting test_tls_racecheck ... OK test_tls_racecheck provokes races by doing many pthread_key_create and pthread_key_delete calls in parallel threads. test_tss_racecheck provokes races by doing many tss_create and tss_delete calls in parallel threads. I would guess that it is a musl libc bug.