Date: Wed, 20 Dec 2023 09:23:52 +0000 From: bugzilla-noreply@freebsd.org To: ports-bugs@FreeBSD.org Subject: [Bug 275854] -fsanitize=address and -fsanitize=memory fail with clang 17 Message-ID: <bug-275854-7788@https.bugs.freebsd.org/bugzilla/>
next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D275854 Bug ID: 275854 Summary: -fsanitize=3Daddress and -fsanitize=3Dmemory fail with clang 17 Product: Ports & Packages Version: Latest Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: Ports Framework Assignee: portmgr@FreeBSD.org Reporter: jbeich@FreeBSD.org CC: ports-bugs@FreeBSD.org Blocks: 273753 $ echo 'int main() {}' >a.c $ cc -fsanitize=3Daddress a.c ld: error: undefined symbol: __sanitizer::ThreadArgRetval::GetAllPtrsLocked(__sanitizer::InternalMmapVec= tor<unsigned long>*) >>> referenced by asan_thread.cpp:560 (/usr/src/contrib/llvm-project/compil= er-rt/lib/asan/asan_thread.cpp:560) >>> asan_thread.o:(__lsan::GetAdditionalThreadContextPtrsLock= ed(__sanitizer::InternalMmapVector<unsigned long>*)) in archive /usr/lib/cl= ang/17/lib/freebsd/libclang_rt.asan-x86_64.a ld: error: undefined symbol: __sanitizer::ThreadArgRetval::CreateLocked(unsigned long, bool, __sanitizer::ThreadArgRetval::Args const&) >>> referenced by sanitizer_thread_arg_retval.h:48 (/usr/src/contrib/llvm-p= roject/compiler-rt/lib/sanitizer_common/sanitizer_thread_arg_retval.h:48) >>> asan_interceptors.o:(__interceptor_pthread_create) in arc= hive /usr/lib/clang/17/lib/freebsd/libclang_rt.asan-x86_64.a ld: error: undefined symbol: __sanitizer::ThreadArgRetval::BeforeJoin(unsig= ned long) const >>> referenced by sanitizer_thread_arg_retval.h:74 (/usr/src/contrib/llvm-p= roject/compiler-rt/lib/sanitizer_common/sanitizer_thread_arg_retval.h:74) >>> asan_interceptors.o:(__interceptor_pthread_join) in archi= ve /usr/lib/clang/17/lib/freebsd/libclang_rt.asan-x86_64.a ld: error: undefined symbol: __sanitizer::ThreadArgRetval::AfterJoin(unsign= ed long, unsigned int) >>> referenced by sanitizer_thread_arg_retval.h:76 (/usr/src/contrib/llvm-p= roject/compiler-rt/lib/sanitizer_common/sanitizer_thread_arg_retval.h:76) >>> asan_interceptors.o:(__interceptor_pthread_join) in archi= ve /usr/lib/clang/17/lib/freebsd/libclang_rt.asan-x86_64.a ld: error: undefined symbol: __sanitizer::ThreadArgRetval::DetachLocked(unsigned long) >>> referenced by sanitizer_thread_arg_retval.h:65 (/usr/src/contrib/llvm-p= roject/compiler-rt/lib/sanitizer_common/sanitizer_thread_arg_retval.h:65) >>> asan_interceptors.o:(__interceptor_pthread_detach) in arc= hive /usr/lib/clang/17/lib/freebsd/libclang_rt.asan-x86_64.a ld: error: undefined symbol: __sanitizer::ThreadArgRetval::Finish(unsigned long, void*) >>> referenced by asan_interceptors.cpp:290 (/usr/src/contrib/llvm-project/= compiler-rt/lib/asan/asan_interceptors.cpp:290) >>> asan_interceptors.o:(__interceptor_pthread_exit) in archi= ve /usr/lib/clang/17/lib/freebsd/libclang_rt.asan-x86_64.a >>> referenced by asan_interceptors.cpp:226 (/usr/src/contrib/llvm-project/= compiler-rt/lib/asan/asan_interceptors.cpp:226) >>> asan_interceptors.o:(asan_thread_start(void*)) in archive= /usr/lib/clang/17/lib/freebsd/libclang_rt.asan-x86_64.a ld: error: undefined symbol: __sanitizer::ThreadArgRetval::GetArgs(unsigned long) const >>> referenced by asan_interceptors.cpp:224 (/usr/src/contrib/llvm-project/= compiler-rt/lib/asan/asan_interceptors.cpp:224) >>> asan_interceptors.o:(asan_thread_start(void*)) in archive= /usr/lib/clang/17/lib/freebsd/libclang_rt.asan-x86_64.a cc: error: linker command failed with exit code 1 (use -v to see invocation) $ cc -fsanitize=3Dmemory a.c ld: error: undefined symbol: __msan::UnpoisonDllAddrInfo(void*) >>> referenced by msan_interceptors.cpp:1550 (/usr/src/contrib/llvm-project= /compiler-rt/lib/msan/msan_interceptors.cpp:1550) >>> msan_interceptors.o:(__interceptor_dladdr) in archive /us= r/lib/clang/17/lib/freebsd/libclang_rt.msan-x86_64.a cc: error: linker command failed with exit code 1 (use -v to see invocation) Note, -fsanitize=3Dundefined, -fsanitize=3Dthread work fine. Referenced Bugs: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D273753 [Bug 273753] [exp-run] Against llvm-17-update branch on GitHub --=20 You are receiving this mail because: You are on the CC list for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-275854-7788>