Skip to content

Commit

Permalink
1
Browse files Browse the repository at this point in the history
  • Loading branch information
xinyiZzz authored and yiguolei committed May 16, 2024
1 parent 355a489 commit f969c4b
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions be/src/runtime/memory/mem_tracker_limiter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -115,17 +115,15 @@ MemTrackerLimiter::~MemTrackerLimiter() {
"transfer memory tracking value between two trackers, can use transfer_to.";
if (_consumption->current_value() != 0) {
// TODO, expect mem tracker equal to 0 at the task end.
if (doris::config::enable_memory_orphan_check && _type == Type::QUERY) {
#ifndef NDEBUG
if (_type == Type::QUERY) {
std::string err_msg =
fmt::format("mem tracker label: {}, consumption: {}, peak consumption: {}, {}.",
label(), _consumption->current_value(), _consumption->peak_value(),
mem_tracker_inaccurate_msg);
#ifdef NDEBUG
LOG(INFO) << err_msg;
#else
LOG(INFO) << err_msg << print_address_sanitizers();
#endif
}
#endif
if (ExecEnv::tracking_memory()) {
ExecEnv::GetInstance()->orphan_mem_tracker()->consume(_consumption->current_value());
}
Expand Down

0 comments on commit f969c4b

Please sign in to comment.