Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 39 additions & 5 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ flate2 = "1.1.5"
futures = "0.3"
glob = "0.3.0"
half = { version = "2.7.0", default-features = false }
hashbrown = { version = "0.14.5", features = ["raw"] }
hashbrown = { features = ["raw"], git = "https://github.com/rluvaton/hashbrown", rev = "dbdac43f537223a469746f518929b542f3b8933d" }
hex = { version = "0.4.3" }
indexmap = "2.12.1"
insta = { version = "1.45.0", features = ["glob", "filters"] }
Expand Down
4 changes: 4 additions & 0 deletions datafusion/common/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -649,6 +649,10 @@ config_namespace! {
/// # Default
/// `false` — ANSI SQL mode is disabled by default.
pub enable_ansi_mode: bool, default = false

pub agg_prefetch_elements: usize, default = 1
pub agg_prefetch_locality: usize, default = 3
pub agg_prefetch_read: bool, default = false
Comment on lines +653 to +655
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added config to allow for easy tinkering while prototyping

}
}

Expand Down
1 change: 1 addition & 0 deletions datafusion/physical-plan/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ log = { workspace = true }
parking_lot = { workspace = true }
pin-project-lite = "^0.2.7"
tokio = { workspace = true }
cache-size = "0.7.0"

[dev-dependencies]
criterion = { workspace = true, features = ["async_futures"] }
Expand Down
7 changes: 4 additions & 3 deletions datafusion/physical-plan/src/aggregates/group_values/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ use arrow::array::types::{
use arrow::array::{ArrayRef, downcast_primitive};
use arrow::datatypes::{DataType, SchemaRef, TimeUnit};
use datafusion_common::Result;

use datafusion_execution::TaskContext;
use datafusion_expr::EmitTo;

pub mod multi_group_by;
Expand Down Expand Up @@ -134,6 +134,7 @@ pub trait GroupValues: Send {
pub fn new_group_values(
schema: SchemaRef,
group_ordering: &GroupOrdering,
ctx: Option<&TaskContext>
) -> Result<Box<dyn GroupValues>> {
if schema.fields.len() == 1 {
let d = schema.fields[0].data_type();
Expand Down Expand Up @@ -202,9 +203,9 @@ pub fn new_group_values(

if multi_group_by::supported_schema(schema.as_ref()) {
if matches!(group_ordering, GroupOrdering::None) {
Ok(Box::new(GroupValuesColumn::<false>::try_new(schema)?))
Ok(Box::new(GroupValuesColumn::<false>::try_new(schema, ctx)?))
} else {
Ok(Box::new(GroupValuesColumn::<true>::try_new(schema)?))
Ok(Box::new(GroupValuesColumn::<true>::try_new(schema, ctx)?))
}
} else {
Ok(Box::new(GroupValuesRows::try_new(schema)?))
Expand Down
Loading
Loading