If bots work we can replace #ifs with template specialization by TwoLevelByteMapSize1.
Details
Details
- Reviewers
eugenis - Commits
- rG83c6d10b62a9: [sanitizer] NFC: add static_assert to confirm that we use reasonable ByteMap…
rCRT359364: [sanitizer] NFC: add static_assert to confirm that we use reasonable ByteMap…
rL359364: [sanitizer] NFC: add static_assert to confirm that we use reasonable ByteMap…
rG85dcdae5e366: [sanitizer] NFC: add static_assert to confirm that we use optimal ByteMap type
rL359333: [sanitizer] NFC: add static_assert to confirm that we use optimal ByteMap type
rCRT359333: [sanitizer] NFC: add static_assert to confirm that we use optimal ByteMap type
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
Comment Actions
This seems to be failing on our Mac bots with this error:
FAILED: compiler-rt/lib/sanitizer_common/CMakeFiles/RTSanitizerCommonNoHooks.ios.dir/sanitizer_allocator.cc.o /b/s/w/ir/k/recipe_cleanup/clangK3gGtn/llvm_build_dir/./bin/clang++ --target=x86_64-apple-darwin17.7.0 -DHAVE_RPC_XDR_H=0 -D_DEBUG -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/b/s/w/ir/k/llvm-project/compiler-rt/lib/sanitizer_common/.. -stdlib=libc++ -fPIC -fvisibility-inlines-hidden -Werror=date-time -Werror=unguarded-availability-new -std=c++11 -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -Wimplicit-fallthrough -Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wstring-conversion -fdiagnostics-color -Wall -std=c++11 -Wno-unused-parameter -O2 -g -arch armv7 -arch armv7s -arch arm64 -UNDEBUG -stdlib=libc++ -miphoneos-version-min=8.0 -isysroot /b/s/w/ir/cache/macos_sdk/XCode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS12.1.sdk -fPIC -fno-builtin -fno-exceptions -funwind-tables -fno-stack-protector -fno-sanitize=safe-stack -fvisibility=hidden -fno-lto -O3 -gline-tables-only -Wno-gnu -Wno-variadic-macros -Wno-c99-extensions -Wno-non-virtual-dtor -fno-rtti -Wframe-larger-than=570 -Wglobal-constructors -DSANITIZER_SUPPORTS_WEAK_HOOKS=0 -MD -MT compiler-rt/lib/sanitizer_common/CMakeFiles/RTSanitizerCommonNoHooks.ios.dir/sanitizer_allocator.cc.o -MF compiler-rt/lib/sanitizer_common/CMakeFiles/RTSanitizerCommonNoHooks.ios.dir/sanitizer_allocator.cc.o.d -o compiler-rt/lib/sanitizer_common/CMakeFiles/RTSanitizerCommonNoHooks.ios.dir/sanitizer_allocator.cc.o -c /b/s/w/ir/k/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_allocator.cc In file included from /b/s/w/ir/k/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_allocator.cc:14: In file included from /b/s/w/ir/k/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_allocator.h:74: /b/s/w/ir/k/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_allocator_primary32.h:69:3: error: static_assert failed due to requirement 'TwoLevelByteMapSize1 > 128' "TwoLevelByteMap should be used" static_assert(TwoLevelByteMapSize1 > 128, "TwoLevelByteMap should be used"); ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~ /b/s/w/ir/k/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_allocator_combined.h:29:34: note: in instantiation of template class '__sanitizer::SizeClassAllocator32<__sanitizer::AP32>' requested here typename PrimaryAllocator::AddressSpaceView>::value, ^ /b/s/w/ir/k/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_allocator.cc:87:52: note: in instantiation of template class '__sanitizer::CombinedAllocator<__sanitizer::SizeClassAllocator32<__sanitizer::AP32>, __sanitizer::SizeClassAllocatorLocalCache<__sanitizer::SizeClassAllocator32<__sanitizer::AP32> >, __sanitizer::LargeMmapAllocator<__sanitizer::NoOpMapUnmapCallback, __sanitizer::LargeMmapAllocatorPtrArrayStatic, __sanitizer::LocalAddressSpaceView>, __sanitizer::LocalAddressSpaceView>' requested here static ALIGNED(64) char internal_alloc_placeholder[sizeof(InternalAllocator)]; ^ In file included from /b/s/w/ir/k/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_allocator.cc:14: In file included from /b/s/w/ir/k/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_allocator.h:75: /b/s/w/ir/k/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_allocator_local_cache.h:21:27: error: no type named 'AllocatorCache' in '__sanitizer::SizeClassAllocator32<__sanitizer::AP32>' : SizeClassAllocator::AllocatorCache {}; ~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~ /b/s/w/ir/k/llvm-project/compiler-rt/lib/sanitizer_common/sanitizer_allocator.cc:91:31: note: in instantiation of template class '__sanitizer::SizeClassAllocatorLocalCache<__sanitizer::SizeClassAllocator32<__sanitizer::AP32> >' requested here static InternalAllocatorCache internal_allocator_cache; ^ 2 errors generated.