Blame SOURCES/gcc6-libsanitize-aarch64-va42.patch

52122c
2015-01-22  Jakub Jelinek  <jakub@redhat.com>
52122c
52122c
	* sanitizer_common/sanitizer_platform.h
52122c
	(SANITIZER_AARCH64_VMA): Set to 42.
52122c
	(SANITIZER_CAN_USE_ALLOCATOR64): Set to 1 on __aarch64__
52122c
	if SANITIZER_WORDSIZE is 64.
52122c
	(SANITIZER_MMAP_RANGE_SIZE): Define to 1ULL << 42 for
52122c
	__aarch64__.
52122c
52122c
--- libsanitizer/sanitizer_common/sanitizer_platform.h.jj	2015-11-23 13:29:55.000000000 +0100
52122c
+++ libsanitizer/sanitizer_common/sanitizer_platform.h	2016-01-15 12:04:08.511206409 +0100
52122c
@@ -82,7 +82,7 @@
52122c
 // VMA size definition for architecture that support multiple sizes.
52122c
 // AArch64 has 3 VMA sizes: 39, 42 and 48.
52122c
 #if !defined(SANITIZER_AARCH64_VMA)
52122c
-# define SANITIZER_AARCH64_VMA 39
52122c
+# define SANITIZER_AARCH64_VMA 42
52122c
 #else
52122c
 # if SANITIZER_AARCH64_VMA != 39 && SANITIZER_AARCH64_VMA != 42
52122c
 #  error "invalid SANITIZER_AARCH64_VMA size"
52122c
@@ -95,7 +95,7 @@
52122c
 // For such platforms build this code with -DSANITIZER_CAN_USE_ALLOCATOR64=0 or
52122c
 // change the definition of SANITIZER_CAN_USE_ALLOCATOR64 here.
52122c
 #ifndef SANITIZER_CAN_USE_ALLOCATOR64
52122c
-# if defined(__mips64) || defined(__aarch64__)
52122c
+# if defined(__mips64)
52122c
 #  define SANITIZER_CAN_USE_ALLOCATOR64 0
52122c
 # else
52122c
 #  define SANITIZER_CAN_USE_ALLOCATOR64 (SANITIZER_WORDSIZE == 64)
52122c
@@ -107,6 +107,8 @@
52122c
 // will still work but will consume more memory for TwoLevelByteMap.
52122c
 #if defined(__mips__)
52122c
 # define SANITIZER_MMAP_RANGE_SIZE FIRST_32_SECOND_64(1ULL << 32, 1ULL << 40)
52122c
+#elif defined(__aarch64__)
52122c
+# define SANITIZER_MMAP_RANGE_SIZE FIRST_32_SECOND_64(1ULL << 32, 1ULL << 42)
52122c
 #else
52122c
 # define SANITIZER_MMAP_RANGE_SIZE FIRST_32_SECOND_64(1ULL << 32, 1ULL << 47)
52122c
 #endif