Skip to content

Commit e6df27c

Browse files
authored
. (#16449)
1 parent 7e0f623 commit e6df27c

File tree

2 files changed

+8
-15
lines changed

2 files changed

+8
-15
lines changed

datafusion/physical-plan/Cargo.toml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@ workspace = true
3636

3737
[features]
3838
force_hash_collisions = []
39-
bench = []
4039

4140
[lib]
4241
name = "datafusion_physical_plan"
@@ -91,4 +90,3 @@ name = "spill_io"
9190
[[bench]]
9291
harness = false
9392
name = "sort_preserving_merge"
94-
required-features = ["bench"]

datafusion/physical-plan/benches/sort_preserving_merge.rs

Lines changed: 8 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -115,18 +115,13 @@ fn get_bench_data() -> Vec<BenchData> {
115115
let mut push_bench_data = |bench_name: &str, partitions: Vec<Vec<RecordBatch>>| {
116116
let schema = partitions[0][0].schema();
117117
// Define sort order (col1 ASC, col2 ASC, col3 ASC)
118-
let sort_order = LexOrdering::new(
119-
schema
120-
.fields()
121-
.iter()
122-
.map(|field| {
123-
PhysicalSortExpr::new(
124-
col(field.name(), &schema).unwrap(),
125-
SortOptions::default(),
126-
)
127-
})
128-
.collect(),
129-
);
118+
let sort_order = LexOrdering::new(schema.fields().iter().map(|field| {
119+
PhysicalSortExpr::new(
120+
col(field.name(), &schema).unwrap(),
121+
SortOptions::default(),
122+
)
123+
}))
124+
.unwrap();
130125
ret.push(BenchData {
131126
bench_name: bench_name.to_string(),
132127
partitions,
@@ -173,7 +168,7 @@ fn bench_merge_sorted_preserving(c: &mut Criterion) {
173168
sort_order,
174169
} = data;
175170
c.bench_function(
176-
&format!("bench_merge_sorted_preserving/{}", bench_name),
171+
&format!("bench_merge_sorted_preserving/{bench_name}"),
177172
|b| {
178173
b.iter_batched(
179174
|| {

0 commit comments

Comments
 (0)