ryux1 commented on code in PR #24319:
URL: https://github.com/apache/datafusion/pull/24319#discussion_r3779455834


##########
datafusion/common/src/utils/memory.rs:
##########
@@ -19,11 +19,17 @@
 
 use crate::error::_exec_datafusion_err;
 use crate::{HashSet, Result};
-use arrow::array::ArrayData;
+use arrow::array::types::ByteArrayType;
+use arrow::array::{Array, AsArray, downcast_run_array};
+use arrow::buffer::Buffer;
+use arrow::datatypes::DataType;
+use arrow::downcast_primitive_array;
 use arrow::record_batch::RecordBatch;
 use std::mem::size_of;
 use std::num::NonZero;
 
+const INLINE_BUFFER_IDS: usize = 16;

Review Comment:
   Good point — documented in db959c37e. This is the number of distinct buffer 
IDs retained inline before promotion to a `HashSet`. I clarified that 16 is a 
performance heuristic balancing allocation avoidance for small sets against 
bounded inline storage and linear lookup, rather than a semantic limit.



-- 
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