[compiler-rt] r307540 - [tsan] Add a max VM address check for Darwin/AArch64
Kuba Mracek via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 10 08:24:49 PDT 2017
Author: kuba.brecka
Date: Mon Jul 10 08:24:48 2017
New Revision: 307540
URL: http://llvm.org/viewvc/llvm-project?rev=307540&view=rev
Log:
[tsan] Add a max VM address check for Darwin/AArch64
Differential Revision: https://reviews.llvm.org/D35154
Modified:
compiler-rt/trunk/lib/tsan/rtl/tsan_platform_mac.cc
Modified: compiler-rt/trunk/lib/tsan/rtl/tsan_platform_mac.cc
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/tsan/rtl/tsan_platform_mac.cc?rev=307540&r1=307539&r2=307540&view=diff
==============================================================================
--- compiler-rt/trunk/lib/tsan/rtl/tsan_platform_mac.cc (original)
+++ compiler-rt/trunk/lib/tsan/rtl/tsan_platform_mac.cc Mon Jul 10 08:24:48 2017
@@ -230,6 +230,14 @@ static void my_pthread_introspection_hoo
#endif
void InitializePlatformEarly() {
+#if defined(__aarch64__)
+ uptr max_vm = GetMaxVirtualAddress() + 1;
+ if (max_vm != kHiAppMemEnd) {
+ Printf("ThreadSanitizer: unsupported vm address limit %p, expected %p.\n",
+ max_vm, kHiAppMemEnd);
+ Die();
+ }
+#endif
}
void InitializePlatform() {
More information about the llvm-commits
mailing list