zhztheplayer commented on code in PR #13251:
URL: https://github.com/apache/arrow/pull/13251#discussion_r885155336
##########
cpp/src/jni/dataset/jni_util.cc:
##########
@@ -108,12 +108,15 @@ class ReservationListenableMemoryPool::Impl {
}
int64_t bytes_granted = (new_block_count - blocks_reserved_) * block_size_;
blocks_reserved_ = new_block_count;
+ if (bytes_reserved_ > max_bytes_reserved_) {
+ max_bytes_reserved_ = bytes_reserved_;
+ }
return bytes_granted;
}
- int64_t bytes_allocated() { return pool_->bytes_allocated(); }
+ int64_t bytes_allocated() { return bytes_reserved_; }
Review Comment:
fixed by using `MemoryPoolStats`
--
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]