yiguolei commented on code in PR #32641:
URL: https://github.com/apache/doris/pull/32641#discussion_r1542293516


##########
be/src/runtime/memory/mem_tracker_limiter.h:
##########
@@ -244,6 +245,20 @@ class MemTrackerLimiter final : public MemTracker {
     // Log the memory usage when memory limit is exceeded.
     std::string tracker_limit_exceeded_str();
 
+    void set_weighted_mem(int64_t weighted_limit, double ratio) {
+        std::lock_guard<std::mutex> l(_weighted_mem_lock);
+        _weighted_consumption = _consumption->current_value() * ratio;
+        _weighted_limit = weighted_limit;
+    }
+    void get_weighted_mem_info(int64_t& weighted_limit, int64_t& 
weighted_consumption) {
+        std::lock_guard<std::mutex> l(_weighted_mem_lock);
+        weighted_limit = _weighted_limit;
+        weighted_consumption = _weighted_consumption;
+    }
+
+    void set_need_revoke(bool b) { _need_revoke.store(b, 
std::memory_order_relaxed); }

Review Comment:
   这些函数应该都是要再query ctx 中



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to