Skip to content

Commit

Permalink
Switch to LexicographicalComparator
Browse files Browse the repository at this point in the history
  • Loading branch information
blaginin committed Jan 29, 2025
1 parent 09a0844 commit 579ef2c
Show file tree
Hide file tree
Showing 2 changed files with 187 additions and 303 deletions.
29 changes: 29 additions & 0 deletions datafusion/core/benches/aggregate_query_sql.rs
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,35 @@ fn criterion_benchmark(c: &mut Criterion) {
)
})
});

c.bench_function("first_many_columns", |b| {
b.iter(|| {
query(
ctx.clone(),
"SELECT first_value(u64_wide order by f64, u64_narrow, utf8) \
FROM t group by u64_narrow",
)
})
});

c.bench_function("first_ignore_nulls", |b| {
b.iter(|| {
query(
ctx.clone(),
"SELECT first_value(u64_wide ignore nulls order by f64, u64_narrow, utf8) \
FROM t group by u64_narrow",
)
})
});

c.bench_function("first_one_column", |b| {
b.iter(|| {
query(
ctx.clone(),
"SELECT first_value(u64_wide order by f64) FROM t group by u64_narrow",
)
})
});
}

criterion_group!(benches, criterion_benchmark);
Expand Down
Loading

0 comments on commit 579ef2c

Please sign in to comment.