Andrew Sherman created IMPALA-12614: ---------------------------------------
Summary: TSAN detected data race in PeriodicCounterUpdater Key: IMPALA-12614 URL: https://issues.apache.org/jira/browse/IMPALA-12614 Project: IMPALA Issue Type: Bug Components: Backend Affects Versions: Impala 4.3.0 Reporter: Andrew Sherman A TSAN test run detected a data race: READ: {code} WARNING: ThreadSanitizer: data race (pid=2200) Read of size 8 at 0x7b540000d6b0 by thread T3 (mutexes: write M3189, write M1141235156294569304): #0 impala::QueryState::Init(impala::ExecQueryFInstancesRequestPB const*, impala::TExecPlanFragmentInfo const&)::$_14::operator()() const /data/jenkins/workspace/impala-asf-master-core-tsan/repos/Impala/be/src/runtime/query-state.cc:249:50 (impalad+0x25db87d) #1 boost::detail::function::function_obj_invoker0<impala::QueryState::Init(impala::ExecQueryFInstancesRequestPB const*, impala::TExecPlanFragmentInfo const&)::$_14, long>::invoke(boost::detail::function::function_buffer&) /data/jenkins/workspace/impala-asf-master-core-tsan/Impala-Toolchain/toolchain-packages-gcc10.4.0/boost-1.74.0-p1/include/boost/function/function_template.hpp:137:18 (impalad+0x25db659) #2 boost::function0<long>::operator()() const /data/jenkins/workspace/impala-asf-master-core-tsan/Impala-Toolchain/toolchain-packages-gcc10.4.0/boost-1.74.0-p1/include/boost/function/function_template.hpp:763:14 (impalad+0x2c1bee1) #3 impala::RuntimeProfile::TimeSeriesCounter::AddSample(int) /data/jenkins/workspace/impala-asf-master-core-tsan/repos/Impala/be/src/util/runtime-profile.cc:2050:20 (impalad+0x2c3e98e) #4 impala::PeriodicCounterUpdater::UpdateLoop(impala::PeriodicCounterUpdater*) /data/jenkins/workspace/impala-asf-master-core-tsan/repos/Impala/be/src/util/periodic-counter-updater.cc:229:16 (impalad+0x2c1a4b2) #5 boost::_mfi::mf1<void, impala::PeriodicCounterUpdater, impala::PeriodicCounterUpdater*>::operator()(impala::PeriodicCounterUpdater*, impala::PeriodicCounterUpdater*) const /data/jenkins/workspace/impala-asf-master-core-tsan/Impala-Toolchain/toolchain-packages-gcc10.4.0/boost-1.74.0-p1/include/boost/bind/mem_fn_template.hpp:165:29 (impalad+0x2c1f6dd) #6 void boost::_bi::list2<boost::_bi::value<impala::PeriodicCounterUpdater*>, boost::_bi::value<impala::PeriodicCounterUpdater*> >::operator()<boost::_mfi::mf1<void, impala::PeriodicCounterUpdater, impala::PeriodicCounterUpdater*>, boost::_bi::list0>(boost::_bi::type<void>, boost::_mfi::mf1<void, impala::PeriodicCounterUpdater, impala::PeriodicCounterUpdater*>&, boost::_bi::list0&, int) /data/jenkins/workspace/impala-asf-master-core-tsan/Impala-Toolchain/toolchain-packages-gcc10.4.0/boost-1.74.0-p1/include/boost/bind/bind.hpp:319:9 (impalad+0x2c1f61d) #7 boost::_bi::bind_t<void, boost::_mfi::mf1<void, impala::PeriodicCounterUpdater, impala::PeriodicCounterUpdater*>, boost::_bi::list2<boost::_bi::value<impala::PeriodicCounterUpdater*>, boost::_bi::value<impala::PeriodicCounterUpdater*> > >::operator()() /data/jenkins/workspace/impala-asf-master-core-tsan/Impala-Toolchain/toolchain-packages-gcc10.4.0/boost-1.74.0-p1/include/boost/bind/bind.hpp:1294:16 (impalad+0x2c1f583) #8 boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf1<void, impala::PeriodicCounterUpdater, impala::PeriodicCounterUpdater*>, boost::_bi::list2<boost::_bi::value<impala::PeriodicCounterUpdater*>, boost::_bi::value<impala::PeriodicCounterUpdater*> > > >::run() /data/jenkins/workspace/impala-asf-master-core-tsan/Impala-Toolchain/toolchain-packages-gcc10.4.0/boost-1.74.0-p1/include/boost/thread/detail/thread.hpp:120:17 (impalad+0x2c1eff0) #9 thread_proxy <null> (impalad+0x39e5ef6) {code} WRITE: {code} Previous write of size 8 at 0x7b540000d6b0 by thread T4 (mutexes: write M3356): #0 impala::SystemStateInfo::ComputeDiskStats(long) /data/jenkins/workspace/impala-asf-master-core-tsan/repos/Impala/be/src/util/system-state-info.cc:269:26 (impalad+0x2c87423) #1 impala::SystemStateInfo::CaptureSystemStateSnapshot() /data/jenkins/workspace/impala-asf-master-core-tsan/repos/Impala/be/src/util/system-state-info.cc:106:3 (impalad+0x2c86eeb) #2 impala::ExecEnv::InitSystemStateInfo()::$_8::operator()() const /data/jenkins/workspace/impala-asf-master-core-tsan/repos/Impala/be/src/runtime/exec-env.cc:639:8 (impalad+0x2559fe1) #3 void std::__invoke_impl<void, impala::ExecEnv::InitSystemStateInfo()::$_8&>(std::__invoke_other, impala::ExecEnv::InitSystemStateInfo()::$_8&) /data/jenkins/workspace/impala-asf-master-core-tsan/Impala-Toolchain/toolchain-packages-gcc10.4.0/gcc-10.4.0/lib/gcc/x86_64-pc-linux-gnu/10.4.0/../../../../include/c++/10.4.0/bits/invoke.h:60:14 (impalad+0x2559f71) #4 std::enable_if<is_invocable_r_v<void, impala::ExecEnv::InitSystemStateInfo()::$_8&>, void>::type std::__invoke_r<void, impala::ExecEnv::InitSystemStateInfo()::$_8&>(impala::ExecEnv::InitSystemStateInfo()::$_8&) /data/jenkins/workspace/impala-asf-master-core-tsan/Impala-Toolchain/toolchain-packages-gcc10.4.0/gcc-10.4.0/lib/gcc/x86_64-pc-linux-gnu/10.4.0/../../../../include/c++/10.4.0/bits/invoke.h:110:2 (impalad+0x2559ef1) #5 std::_Function_handler<void (), impala::ExecEnv::InitSystemStateInfo()::$_8>::_M_invoke(std::_Any_data const&) /data/jenkins/workspace/impala-asf-master-core-tsan/Impala-Toolchain/toolchain-packages-gcc10.4.0/gcc-10.4.0/lib/gcc/x86_64-pc-linux-gnu/10.4.0/../../../../include/c++/10.4.0/bits/std_function.h:291:9 (impalad+0x2559dc1) #6 std::function<void ()>::operator()() const /data/jenkins/workspace/impala-asf-master-core-tsan/Impala-Toolchain/toolchain-packages-gcc10.4.0/gcc-10.4.0/lib/gcc/x86_64-pc-linux-gnu/10.4.0/../../../../include/c++/10.4.0/bits/std_function.h:622:14 (impalad+0x23c171c) #7 impala::PeriodicCounterUpdater::UpdateLoop(impala::PeriodicCounterUpdater*) /data/jenkins/workspace/impala-asf-master-core-tsan/repos/Impala/be/src/util/periodic-counter-updater.cc:175:39 (impalad+0x2c1a586) #8 boost::_mfi::mf1<void, impala::PeriodicCounterUpdater, impala::PeriodicCounterUpdater*>::operator()(impala::PeriodicCounterUpdater*, impala::PeriodicCounterUpdater*) const /data/jenkins/workspace/impala-asf-master-core-tsan/Impala-Toolchain/toolchain-packages-gcc10.4.0/boost-1.74.0-p1/include/boost/bind/mem_fn_template.hpp:165:29 (impalad+0x2c1f6dd) #9 void boost::_bi::list2<boost::_bi::value<impala::PeriodicCounterUpdater*>, boost::_bi::value<impala::PeriodicCounterUpdater*> >::operator()<boost::_mfi::mf1<void, impala::PeriodicCounterUpdater, impala::PeriodicCounterUpdater*>, boost::_bi::list0>(boost::_bi::type<void>, boost::_mfi::mf1<void, impala::PeriodicCounterUpdater, impala::PeriodicCounterUpdater*>&, boost::_bi::list0&, int) /data/jenkins/workspace/impala-asf-master-core-tsan/Impala-Toolchain/toolchain-packages-gcc10.4.0/boost-1.74.0-p1/include/boost/bind/bind.hpp:319:9 (impalad+0x2c1f61d) #10 boost::_bi::bind_t<void, boost::_mfi::mf1<void, impala::PeriodicCounterUpdater, impala::PeriodicCounterUpdater*>, boost::_bi::list2<boost::_bi::value<impala::PeriodicCounterUpdater*>, boost::_bi::value<impala::PeriodicCounterUpdater*> > >::operator()() /data/jenkins/workspace/impala-asf-master-core-tsan/Impala-Toolchain/toolchain-packages-gcc10.4.0/boost-1.74.0-p1/include/boost/bind/bind.hpp:1294:16 (impalad+0x2c1f583) #11 boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf1<void, impala::PeriodicCounterUpdater, impala::PeriodicCounterUpdater*>, boost::_bi::list2<boost::_bi::value<impala::PeriodicCounterUpdater*>, boost::_bi::value<impala::PeriodicCounterUpdater*> > > >::run() /data/jenkins/workspace/impala-asf-master-core-tsan/Impala-Toolchain/toolchain-packages-gcc10.4.0/boost-1.74.0-p1/include/boost/thread/detail/thread.hpp:120:17 (impalad+0x2c1eff0) #12 thread_proxy <null> (impalad+0x39e5ef6) {code} -- This message was sent by Atlassian Jira (v8.20.10#820010)