You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@impala.apache.org by ar...@apache.org on 2022/03/23 16:33:14 UTC

[impala] branch master updated: IMPALA-11196 Fix ClientCacheTest ASAN and TSAN build failure

This is an automated email from the ASF dual-hosted git repository.

arawat pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/impala.git


The following commit(s) were added to refs/heads/master by this push:
     new f9dfd1f  IMPALA-11196 Fix ClientCacheTest ASAN and TSAN build failure
f9dfd1f is described below

commit f9dfd1f954f3b3123082fa483adf4dc806f0c31a
Author: Yida Wu <wy...@gmail.com>
AuthorDate: Mon Mar 21 20:36:47 2022 -0700

    IMPALA-11196 Fix ClientCacheTest ASAN and TSAN build failure
    
    The testcase succeeds in DEBUG and RELEASE, but fails in ASAN and
    TSAN build.
    
    In the testcase's logic, it monitors whether there is a change
    of the process vm size or not after several new and deletion of
    objects in the system, because ASAN has replaced the alloc/free
    interface, it may not guarantee the memory must be released to
    the system immediately in ASAN. Similar case in TSAN.
    
    The fix disables the testcase running in ASAN and TSAN, and the
    running of this testcase in the DEBUG and RELEASE builds should
    be enough for the verification of the memory leak problem in
    IMPALA-11176.
    
    Tests:
    Reran testcase in ASAN and TSAN without errors.
    
    Change-Id: Id40a2ae184bba670a3538dedfb8ff25d24dc9b6c
    Reviewed-on: http://gerrit.cloudera.org:8080/18342
    Reviewed-by: Impala Public Jenkins <im...@cloudera.com>
    Tested-by: Impala Public Jenkins <im...@cloudera.com>
---
 be/src/runtime/client-cache-test.cc | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/be/src/runtime/client-cache-test.cc b/be/src/runtime/client-cache-test.cc
index dbfce83..e2c0af6 100644
--- a/be/src/runtime/client-cache-test.cc
+++ b/be/src/runtime/client-cache-test.cc
@@ -93,6 +93,8 @@ class ClientCacheTest : public testing::Test {
 // The memory is not supposed to increase after multiple rounds of client creation and
 // destruction.
 TEST_F(ClientCacheTest, MemLeak) {
+// IMPALA-11196 Testcase will fail in ASAN and TSAN build, therefore disabled.
+#if !defined(ADDRESS_SANITIZER) && !defined(THREAD_SANITIZER)
   int64_t create_num = 1000;
   TNetworkAddress* addr;
   InitAddr(&addr);
@@ -110,5 +112,6 @@ TEST_F(ClientCacheTest, MemLeak) {
   }
   uint64_t mem_after = GetProcessVMSize();
   EXPECT_EQ(mem_before, mem_after);
+#endif
 }
 } // namespace impala