summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKostya Serebryany <kcc@google.com>2013-12-10 10:34:55 +0000
committerKostya Serebryany <kcc@google.com>2013-12-10 10:34:55 +0000
commitb00a0e2971f5fbc1c069dbc4b4019ed5ca304fe9 (patch)
tree1d5aee9db4ec5488c47d56c1fb9011dca2fbba37
parent6d2c88eafdc3df34208aa3be2e1a315048a9a9d6 (diff)
downloadbcm5719-llvm-b00a0e2971f5fbc1c069dbc4b4019ed5ca304fe9.tar.gz
bcm5719-llvm-b00a0e2971f5fbc1c069dbc4b4019ed5ca304fe9.zip
[asan] relax HugeMallocTest so that it does not fail on small-RAM machines
llvm-svn: 196904
-rw-r--r--compiler-rt/lib/asan/tests/asan_test.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/compiler-rt/lib/asan/tests/asan_test.cc b/compiler-rt/lib/asan/tests/asan_test.cc
index 43a850ba2e8..af7c471883b 100644
--- a/compiler-rt/lib/asan/tests/asan_test.cc
+++ b/compiler-rt/lib/asan/tests/asan_test.cc
@@ -301,7 +301,9 @@ TEST(AddressSanitizer, LargeMallocTest) {
TEST(AddressSanitizer, HugeMallocTest) {
if (SANITIZER_WORDSIZE != 64 || ASAN_AVOID_EXPENSIVE_TESTS) return;
size_t n_megs = 4100;
- TestLargeMalloc(n_megs << 20);
+ EXPECT_DEATH(Ident((char*)malloc(n_megs << 20))[-1] = 0,
+ "is located 1 bytes to the left|"
+ "AddressSanitizer failed to allocate");
}
#ifndef __APPLE__
OpenPOWER on IntegriCloud