diff --git a/compiler-rt/lib/hwasan/hwasan_allocator.h b/compiler-rt/lib/hwasan/hwasan_allocator.h index 2ada2a0b1851a38455a9e616ae1232fce7b7b2df..31ba67c7fc73c6785c398205892f3582c4ac41d0 100644 --- a/compiler-rt/lib/hwasan/hwasan_allocator.h +++ b/compiler-rt/lib/hwasan/hwasan_allocator.h @@ -74,7 +74,7 @@ struct AP64 { #if defined(HWASAN_ALIASING_MODE) static const uptr kSpaceSize = 1ULL << kAddressTagShift; typedef __sanitizer::DefaultSizeClassMap SizeClassMap; -#elif SANITIZER_LINUX && !SANITIZER_ANDROID +#elif SANITIZER_LINUX && !SANITIZER_ANDROID && !SANITIZER_OHOS static const uptr kSpaceSize = 0x40000000000ULL; // 4T. typedef __sanitizer::DefaultSizeClassMap SizeClassMap; #else