Dandandan commented on code in PR #7041:
URL: https://github.com/apache/arrow-datafusion/pull/7041#discussion_r1269840975
##########
datafusion/execution/src/memory_pool/proxy.rs:
##########
@@ -84,7 +84,7 @@ impl<T> RawTableAllocExt for RawTable<T> {
Err(x) => {
// need to request more memory
- let bump_elements = (self.capacity() * 2).max(16);
+ let bump_elements = self.capacity().max(16);
let bump_size = bump_elements * std::mem::size_of::<T>();
*accounting =
(*accounting).checked_add(bump_size).expect("overflow");
Review Comment:
Yeah this looks correct to me👍
##########
datafusion/execution/src/memory_pool/proxy.rs:
##########
@@ -84,7 +84,7 @@ impl<T> RawTableAllocExt for RawTable<T> {
Err(x) => {
// need to request more memory
- let bump_elements = (self.capacity() * 2).max(16);
+ let bump_elements = self.capacity().max(16);
let bump_size = bump_elements * std::mem::size_of::<T>();
*accounting =
(*accounting).checked_add(bump_size).expect("overflow");
Review Comment:
Yeah this looks correct to me👍
--
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]