[compiler-rt] [rtsan] Support legacy pthread_cond variables (PR #152947)

Fangrui Song via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 18 22:05:14 PDT 2025


MaskRay wrote:

I have created https://github.com/llvm/llvm-project/pull/154268 to simplify the tsan `pthread_cond_t` interceptors.

https://maskray.me/blog/2023-01-08-all-about-sanitizer-interceptors

> Before glibc 2.36, dlsym(RTLD_NEXT, name) returned the address of the oldest version definition of name in libc.so.6. And we got to use the old semantics. This is usually benign but not ideal (see https://github.com/google/sanitizers/issues/1371 for a regexec issue). I fixed glibc 2.36 ([BZ #14932](https://sourceware.org/bugzilla/show_bug.cgi?id=14932)) so that dlsym(RTLD_NEXT, name) returns the default version definition now.

https://maskray.me/blog/2022-05-29-glibc

> Take x86_64 as an example. sysdeps/unix/sysv/linux/x86_64/64/shlib-versions says that x86_64's earliest symbol is at GLIBC_2.2.5. $build/abi-versions.h contains:

https://github.com/llvm/llvm-project/pull/152947


More information about the llvm-commits mailing list