[PATCH] D106143: [CMake][TSAN] Add build dependency against libcxx
Adrian Vogelsgesang via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Jul 16 14:28:25 PDT 2021
avogelsgesang added a comment.
> That error shows issue when compiling ASan, not TSan, so I'm still not sure why this change is needed?
Good catch!
I actually executed the build multiple times, and the first time it was failing in TSAN.
I made the incorrect assumption that all errors would be due to the TSAN, but didn't check all instances.
Above, I just copied the one variant which showed the race condition most impressively (i.e. with only 1 second between failed cpp compilation error and and copying of `__config`).
I completely overlooked that not all errors were the same, but that they were for different components in the build.
>From a different build log (showing errors in lsan/sanitizer_common, ASAN and TSAN):
[12:08:24] : [clang-build-stage1] [ 64%] Copying CXX header stdio.h
[12:08:24] : [clang-build-stage1] In file included from /Volumes/build/tc/473843e25ae443f4/release/src/clang-osx10.11-x86_64-release-master_avogelsgesang-llvm12.12.0.1.c2458596.r74f7019d/compiler-rt/lib/lsan/lsan_malloc_mac.cpp:57:
[12:08:24] : [clang-build-stage1] In file included from /Volumes/build/tc/473843e25ae443f4/release/src/clang-osx10.11-x86_64-release-master_avogelsgesang-llvm12.12.0.1.c2458596.r74f7019d/compiler-rt/lib/lsan/../sanitizer_common/sanitizer_malloc_mac.inc:20:
[12:08:24] : [clang-build-stage1] In file included from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/CoreFoundation.framework/Headers/CFBase.h:67:
[12:08:24] : [clang-build-stage1] /Volumes/build/tc/473843e25ae443f4/release/src/clang-osx10.11-x86_64-release-master_avogelsgesang-llvm12.12.0.1.c2458596.r74f7019d/build/stage1_build/./bin/../include/c++/v1/stdint.h:106:10: fatal error: '__config' file not found
[12:08:24] : [clang-build-stage1] #include <__config>
[12:08:24] : [clang-build-stage1] ^~~~~~~~~~
[12:08:24] : [clang-build-stage1] [ 64%] Copying CXX header stdlib.h
[12:08:24] : [clang-build-stage1] [ 64%] Building CXX object compiler-rt/lib/tsan/CMakeFiles/RTTsan_dynamic.iossim.dir/rtl/tsan_rtl_mutex.cpp.o
[12:08:24] : [clang-build-stage1] [ 64%] Building CXX object compiler-rt/lib/lsan/CMakeFiles/clang_rt.lsan_osx_dynamic.dir/lsan_thread.cpp.o
[12:08:24] : [clang-build-stage1] [ 64%] Copying CXX header streambuf
[12:08:24] : [clang-build-stage1] In file included from /Volumes/build/tc/473843e25ae443f4/release/src/clang-osx10.11-x86_64-release-master_avogelsgesang-llvm12.12.0.1.c2458596.r74f7019d/compiler-rt/lib/asan/asan_new_delete.cpp:22:
[12:08:24] : [clang-build-stage1] /Volumes/build/tc/473843e25ae443f4/release/src/clang-osx10.11-x86_64-release-master_avogelsgesang-llvm12.12.0.1.c2458596.r74f7019d/build/stage1_build/./bin/../include/c++/v1/stddef.h:39:10: fatal error: '__config' file not found
[12:08:24] : [clang-build-stage1] #include <__config>
[12:08:24] : [clang-build-stage1] ^~~~~~~~~~
[12:08:24] : [clang-build-stage1] 1 error generated.
.....
[12:08:27] : [clang-build-stage1] [ 69%] Building CXX object compiler-rt/lib/tsan/CMakeFiles/RTTsan_dynamic.iossim.dir/rtl/tsan_interceptors_mac.cpp.o
[12:08:27] : [clang-build-stage1] [ 69%] Copying CXX header valarray
[12:08:27] : [clang-build-stage1] [ 69%] Building CXX object compiler-rt/lib/tsan/CMakeFiles/RTTsan_dynamic.iossim.dir/rtl/tsan_interceptors_mach_vm.cpp.o
[12:08:27] : [clang-build-stage1] [ 69%] Copying CXX header variant
[12:08:27] : [clang-build-stage1] [ 69%] Building CXX object compiler-rt/lib/tsan/CMakeFiles/RTTsan_dynamic.iossim.dir/rtl/tsan_platform_mac.cpp.o
[12:08:27] : [clang-build-stage1] [ 69%] Building CXX object compiler-rt/lib/tsan/CMakeFiles/RTTsan_dynamic.iossim.dir/rtl/tsan_platform_posix.cpp.o
[12:08:27] : [clang-build-stage1] [ 69%] Copying CXX header vector
[12:08:27] : [clang-build-stage1] [ 69%] Copying CXX header version
[12:08:27] : [clang-build-stage1] In file included from /Volumes/build/tc/473843e25ae443f4/release/src/clang-osx10.11-x86_64-release-master_avogelsgesang-llvm12.12.0.1.c2458596.r74f7019d/compiler-rt/lib/tsan/rtl/tsan_interceptors_mac.cpp:23:
[12:08:27] : [clang-build-stage1] /Volumes/build/tc/473843e25ae443f4/release/src/clang-osx10.11-x86_64-release-master_avogelsgesang-llvm12.12.0.1.c2458596.r74f7019d/build/stage1_build/./bin/../include/c++/v1/errno.h:25:10: fatal error: '__config' file not found
[12:08:27] : [clang-build-stage1] #include <__config>
[12:08:27] : [clang-build-stage1] ^~~~~~~~~~
[12:08:27] : [clang-build-stage1] [ 69%] Copying CXX header wchar.h
[12:08:27] : [clang-build-stage1] In file included from /Volumes/build/tc/473843e25ae443f4/release/src/clang-osx10.11-x86_64-release-master_avogelsgesang-llvm12.12.0.1.c2458596.r74f7019d/compiler-rt/lib/tsan/rtl/tsan_interceptors_mach_vm.cpp:18:
[12:08:27] : [clang-build-stage1] In file included from /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator12.1.sdk/usr/include/mach/mach.h:65:
[12:08:27] : [clang-build-stage1] In file included from /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator12.1.sdk/usr/include/mach/std_types.h:66:
[12:08:27] : [clang-build-stage1] /Volumes/build/tc/473843e25ae443f4/release/src/clang-osx10.11-x86_64-release-master_avogelsgesang-llvm12.12.0.1.c2458596.r74f7019d/build/stage1_build/./bin/../include/c++/v1/stdint.h:106:10: fatal error: '__config' file not found
[12:08:27] : [clang-build-stage1] #include <__config>
[12:08:27] : [clang-build-stage1] ^~~~~~~~~~
[12:08:27] : [clang-build-stage1] [ 69%] Building CXX object compiler-rt/lib/tsan/CMakeFiles/RTTsan_dynamic.iossim.dir/rtl/tsan_interceptors_libdispatch.cpp.o
[12:08:27] : [clang-build-stage1] [ 70%] Copying CXX header wctype.h
[12:08:27] : [clang-build-stage1] [ 70%] Building CXX object compiler-rt/lib/tsan/CMakeFiles/RTTsan_dynamic.iossim.dir/rtl/tsan_new_delete.cpp.o
[12:08:27] : [clang-build-stage1] [ 70%] Building CXX object compiler-rt/lib/tsan/CMakeFiles/RTTsan_dynamic.osx.dir/rtl/tsan_sync.cpp.o
[12:08:27] : [clang-build-stage1] [ 70%] Copying CXX __config
[12:08:27] : [clang-build-stage1] In file included from /Volumes/build/tc/473843e25ae443f4/release/src/clang-osx10.11-x86_64-release-master_avogelsgesang-llvm12.12.0.1.c2458596.r74f7019d/compiler-rt/lib/tsan/rtl/tsan_platform_mac.cpp:28:
[12:08:27] : [clang-build-stage1] In file included from /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator12.1.sdk/usr/include/mach/mach.h:65:
[12:08:27] : [clang-build-stage1] In file included from /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator12.1.sdk/usr/include/mach/std_types.h:66:
[12:08:27] : [clang-build-stage1] /Volumes/build/tc/473843e25ae443f4/release/src/clang-osx10.11-x86_64-release-master_avogelsgesang-llvm12.12.0.1.c2458596.r74f7019d/build/stage1_build/./bin/../include/c++/v1/stdint.h:106:10: fatal error: '__config' file not found
[12:08:27] : [clang-build-stage1] #include <__config>
[12:08:27] : [clang-build-stage1] ^~~~~~~~~~
[12:08:27] : [clang-build-stage1] 1 error generated.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D106143/new/
https://reviews.llvm.org/D106143
More information about the llvm-commits
mailing list