xinyiZzz commented on a change in pull request #8443:
URL: https://github.com/apache/incubator-doris/pull/8443#discussion_r825329681



##########
File path: be/src/exec/olap_scanner.cpp
##########
@@ -273,6 +279,13 @@ Status OlapScanner::get_batch(RuntimeState* state, 
RowBatch* batch, bool* eof) {
                 break;
             }
             // Read one row from reader
+            allocated_bytes = mem_pool->total_reserved_bytes() - 
allocated_bytes;
+            if (allocated_bytes > 1024 * 1024) {
+                if (_mem_tracker.get()->any_limit_exceeded()) {

Review comment:
       After the Hook tcmalloc new/delete is merged,
   We can automatically limit the memory in similar places~, instead of manually




-- 
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: commits-unsubscr...@doris.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to