diff options
author | Adhemerval Zanella <adhemerval.zanella@linaro.org> | 2016-07-18 14:47:18 +0000 |
---|---|---|
committer | Adhemerval Zanella <adhemerval.zanella@linaro.org> | 2016-07-18 14:47:18 +0000 |
commit | 3e87a261cdc57c4d8f686161f9ecfff4bdacb6a3 (patch) | |
tree | 4081febfbf84c174124c05d9750f86a9b452357e | |
parent | f9fc3dede68bfbf0f954c574c31fbce8bb3e9096 (diff) | |
download | compiler-rt-3e87a261cdc57c4d8f686161f9ecfff4bdacb6a3.tar.gz |
[asan] Enable 48-bit VMA support on aarch64
This patch adds 48-bits VMA support for asan on aarch64. The current
47-bit mask is not suffice since on aarch64 kernel with 48-bit vma
(default on ubuntu 16.04) the process may use full VMA range as:
[...]
ffffa39a7000-ffffa39a8000 r--p 00000000 00:00 0 [vvar]
ffffa39a8000-ffffa39a9000 r-xp 00000000 00:00 0 [vdso]
ffffa39a9000-ffffa39aa000 r--p 0001c000 08:02 13631554 /lib/aarch64-linux-gnu/ld-2.23.so
ffffa39aa000-ffffa39ac000 rw-p 0001d000 08:02 13631554 /lib/aarch64-linux-gnu/ld-2.23.so
ffffc2227000-ffffc2248000 rw-p 00000000 00:00 0 [stack]
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@275792 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/sanitizer_common/sanitizer_platform.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/sanitizer_common/sanitizer_platform.h b/lib/sanitizer_common/sanitizer_platform.h index 8824912b1..0ce23077a 100644 --- a/lib/sanitizer_common/sanitizer_platform.h +++ b/lib/sanitizer_common/sanitizer_platform.h @@ -180,6 +180,8 @@ // will still work but will consume more memory for TwoLevelByteMap. #if defined(__mips__) # define SANITIZER_MMAP_RANGE_SIZE FIRST_32_SECOND_64(1ULL << 32, 1ULL << 40) +#elif defined(__aarch64__) +# define SANITIZER_MMAP_RANGE_SIZE FIRST_32_SECOND_64(1ULL << 32, 1ULL << 48) #else # define SANITIZER_MMAP_RANGE_SIZE FIRST_32_SECOND_64(1ULL << 32, 1ULL << 47) #endif |