diff options
| author | Kostya Serebryany <kcc@google.com> | 2013-01-23 13:27:43 +0000 |
|---|---|---|
| committer | Kostya Serebryany <kcc@google.com> | 2013-01-23 13:27:43 +0000 |
| commit | 8f267137c21cb984c84268f64a5782eb9699004c (patch) | |
| tree | 3f5406e63ee7ed43d70bd14959f855fbfd8acf2d /compiler-rt/lib/asan/asan_allocator2.cc | |
| parent | 420d7d333e593320613889eadb66bfe16b591908 (diff) | |
| download | bcm5719-llvm-8f267137c21cb984c84268f64a5782eb9699004c.tar.gz bcm5719-llvm-8f267137c21cb984c84268f64a5782eb9699004c.zip | |
[asan] initialize kHighMemEnd at startup (instead of at compile time) to simplify further changes for various address space layouts. Fix asan_allocator2 for PowerPC (tested on 44-bit address space)
llvm-svn: 173260
Diffstat (limited to 'compiler-rt/lib/asan/asan_allocator2.cc')
| -rw-r--r-- | compiler-rt/lib/asan/asan_allocator2.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/compiler-rt/lib/asan/asan_allocator2.cc b/compiler-rt/lib/asan/asan_allocator2.cc index 42d8b29afd6..7bfa5fd24b2 100644 --- a/compiler-rt/lib/asan/asan_allocator2.cc +++ b/compiler-rt/lib/asan/asan_allocator2.cc @@ -57,7 +57,11 @@ struct AsanMapUnmapCallback { }; #if SANITIZER_WORDSIZE == 64 +#if defined(__powerpc64__) +const uptr kAllocatorSpace = 0xa0000000000ULL; +#else const uptr kAllocatorSpace = 0x600000000000ULL; +#endif const uptr kAllocatorSize = 0x10000000000ULL; // 1T. typedef DefaultSizeClassMap SizeClassMap; typedef SizeClassAllocator64<kAllocatorSpace, kAllocatorSize, 0 /*metadata*/, |

