diff --git a/arrow-array/src/record_batch.rs b/arrow-array/src/record_batch.rs index c56b1fd308c..78108d441b0 100644 --- a/arrow-array/src/record_batch.rs +++ b/arrow-array/src/record_batch.rs @@ -469,6 +469,11 @@ impl RecordBatch { } /// Returns the total number of bytes of memory occupied physically by this batch. + /// + /// Note that this does not always correspond to the exact memory usage of a + /// `RecordBatch` (might overestimate), since multiple columns can share the same + /// buffers or slices thereof, the memory used by the shared buffers might be + /// counted multiple times. pub fn get_array_memory_size(&self) -> usize { self.columns() .iter()