summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorBill Seurer <seurer@linux.vnet.ibm.com>2017-12-07 22:53:49 +0000
committerBill Seurer <seurer@linux.vnet.ibm.com>2017-12-07 22:53:49 +0000
commit7161621467402530c62b75c9c74c1dc2b9dd5962 (patch)
tree6563276258f755e83849f5ba5d08de581c3485ff /test
parent8316f8d582c9a13bf1ebba93fe66d85a61430692 (diff)
[PowerPC][asan] Update asan to handle changed memory layouts in newer kernels
In more recent Linux kernels with 47 bit VMAs the layout of virtual memory for powerpc64 changed causing the address sanitizer to not work properly. This patch adds support for 47 bit VMA kernels for powerpc64 and fixes up test cases. https://reviews.llvm.org/D40908 There is an associated patch for trunk. Tested on several 4.x and 3.x kernel releases. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@320110 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r--test/asan/TestCases/debug_ppc64_mapping.cc19
1 files changed, 13 insertions, 6 deletions
diff --git a/test/asan/TestCases/debug_ppc64_mapping.cc b/test/asan/TestCases/debug_ppc64_mapping.cc
index 43e1183a2..0db795669 100644
--- a/test/asan/TestCases/debug_ppc64_mapping.cc
+++ b/test/asan/TestCases/debug_ppc64_mapping.cc
@@ -6,11 +6,11 @@
#include <stdio.h>
int main() {
-// CHECK-PPC64: || `[{{0x0a0|0x040}}000000000, {{0x3ff|0x0ff}}fffffffff]` || HighMem ||
-// CHECK-PPC64: || `[{{0x034|0x028}}000000000, {{0x09f|0x03f}}fffffffff]` || HighShadow ||
-// CHECK-PPC64: || `[{{0x024|0x024}}000000000, {{0x033|0x027}}fffffffff]` || ShadowGap ||
-// CHECK-PPC64: || `[0x020000000000, 0x023fffffffff]` || LowShadow ||
-// CHECK-PPC64: || `[0x000000000000, 0x01ffffffffff]` || LowMem ||
+// CHECK-PPC64: || `[{{0x180|0x0a0|0x040}}000000000, {{0x3ff|0x0ff}}fffffffff]` || HighMem ||
+// CHECK-PPC64: || `[{{0x130|0x034|0x028}}000000000, {{0x17f|0x09f|0x03f}}fffffffff]` || HighShadow ||
+// CHECK-PPC64: || `[{{0x120|0x024|0x024}}000000000, {{0x12f|0x033|0x027}}fffffffff]` || ShadowGap ||
+// CHECK-PPC64: || `[{{0x100|0x020}}000000000, {{0x11f|0x023}}fffffffff]` || LowShadow ||
+// CHECK-PPC64: || `[0x000000000000, {{0x0ff|0x01f}}fffffffff]` || LowMem ||
//
printf("ppc64 eyecatcher \n");
// CHECK-PPC64-V0: ppc64 eyecatcher
@@ -19,7 +19,14 @@ int main() {
}
/*
- * Two different signatures noted at the time of writing.
+ * Three different signatures noted.
+Newer kernel: (starting with kernel version 4.?)
+|| `[0x180000000000, 0x3fffffffffff]` || HighMem ||
+|| `[0x130000000000, 0x17ffffffffff]` || HighShadow ||
+|| `[0x120000000000, 0x12ffffffffff]` || ShadowGap ||
+|| `[0x100000000000, 0x11ffffffffff]` || LowShadow ||
+|| `[0x000000000000, 0x0fffffffffff]` || LowMem ||
+
Newish kernel: (64TB address range support, starting with kernel version 3.7)
|| `[0x0a0000000000, 0x3fffffffffff]` || HighMem ||
|| `[0x034000000000, 0x09ffffffffff]` || HighShadow ||