Dandandan commented on code in PR #15643: URL: https://github.com/apache/datafusion/pull/15643#discussion_r2033901020
########## datafusion/physical-plan/src/aggregates/group_values/single_group_by/primitive.rs: ########## @@ -118,25 +119,51 @@ where for v in cols[0].as_primitive::<T>() { let group_id = match v { None => *self.null_group.get_or_insert_with(|| { - let group_id = self.values.len(); - self.values.push(Default::default()); + let group_id = self.values.len().saturating_sub(1) * BLOCK_SIZE Review Comment: Probably better to do it upfront -- 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: github-unsubscr...@datafusion.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org