diff options
author | 2017-05-05 18:24:51 +0000 | |
---|---|---|
committer | 2017-05-05 18:24:53 +0000 | |
commit | c286d17a84c0719fc672db4eef81a9429f7d6ce4 (patch) | |
tree | 01ff9f863a2a74cf319f66b9d2516ce6b4b52f67 | |
parent | 853656aaa0bf99e452211cb8f18a4b1bae70325e (diff) | |
parent | f4a67fd8da796ac9bb96854a942d87f1825ea390 (diff) |
Merge "ART: Disable parts of tests under sanitization"
-rw-r--r-- | dex2oat/dex2oat_test.cc | 3 | ||||
-rw-r--r-- | runtime/common_runtime_test.h | 6 | ||||
-rw-r--r-- | runtime/runtime_callbacks_test.cc | 3 |
3 files changed, 12 insertions, 0 deletions
diff --git a/dex2oat/dex2oat_test.cc b/dex2oat/dex2oat_test.cc index d546072f58..6420aa8759 100644 --- a/dex2oat/dex2oat_test.cc +++ b/dex2oat/dex2oat_test.cc @@ -430,6 +430,9 @@ class Dex2oatSwapUseTest : public Dex2oatSwapTest { }; TEST_F(Dex2oatSwapUseTest, CheckSwapUsage) { + // Native memory usage isn't correctly tracked under sanitization. + TEST_DISABLED_FOR_MEMORY_TOOL_ASAN(); + // The `native_alloc_2_ >= native_alloc_1_` assertion below may not // hold true on some x86 systems; disable this test while we // investigate (b/29259363). diff --git a/runtime/common_runtime_test.h b/runtime/common_runtime_test.h index 56e8aa3685..a29cc6cd38 100644 --- a/runtime/common_runtime_test.h +++ b/runtime/common_runtime_test.h @@ -249,6 +249,12 @@ class CheckJniAbortCatcher { return; \ } +#define TEST_DISABLED_FOR_MEMORY_TOOL_ASAN() \ + if (RUNNING_ON_MEMORY_TOOL > 0 && !kMemoryToolIsValgrind) { \ + printf("WARNING: TEST DISABLED FOR MEMORY TOOL ASAN\n"); \ + return; \ + } + } // namespace art namespace std { diff --git a/runtime/runtime_callbacks_test.cc b/runtime/runtime_callbacks_test.cc index abe99e0d50..640f9ce848 100644 --- a/runtime/runtime_callbacks_test.cc +++ b/runtime/runtime_callbacks_test.cc @@ -335,6 +335,9 @@ class RuntimeSigQuitCallbackRuntimeCallbacksTest : public RuntimeCallbacksTest { }; TEST_F(RuntimeSigQuitCallbackRuntimeCallbacksTest, SigQuit) { + // SigQuit induces a dump. ASAN isn't happy with libunwind reading memory. + TEST_DISABLED_FOR_MEMORY_TOOL_ASAN(); + // The runtime needs to be started for the signal handler. Thread* self = Thread::Current(); |