[all-commits] [llvm/llvm-project] c940c2: tsan: Refine conditions to intercept pthread_cond_...
Fangrui Song via All-commits
all-commits at lists.llvm.org
Tue Aug 19 20:07:44 PDT 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: c940c242fc7504f4a7ee079e70ba0f662e7798f7
https://github.com/llvm/llvm-project/commit/c940c242fc7504f4a7ee079e70ba0f662e7798f7
Author: Fangrui Song <i at maskray.me>
Date: 2025-08-19 (Tue, 19 Aug 2025)
Changed paths:
M compiler-rt/lib/tsan/dd/dd_interceptors.cpp
M compiler-rt/lib/tsan/rtl/tsan_interceptors_posix.cpp
Log Message:
-----------
tsan: Refine conditions to intercept pthread_cond_t functions
On glibc x86-64, functions like pthread_cond_init exist in two versions:
2.2 (older pthread_cond_t) and 2.3.2 (newer pthread_cond_t). In glibc
versions prior to 2.36, using an unversioned interceptor
(`dlsym(RTLD_NEXT, "pthread_cond_init")`) retrieves the older 2.2
symbol, which is not desired
(https://sourceware.org/bugzilla/show_bug.cgi?id=14932).
For newer architectures, such as aarch64 (introduced in glibc 2.17) and
riscv64 (introduced in glibc 2.27), a versioned interceptor is
unnecessary.
Pull Request: https://github.com/llvm/llvm-project/pull/154268
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list