Skip to content

Commit

Permalink
Inline bench_util as common module in benches (#119)
Browse files Browse the repository at this point in the history
  • Loading branch information
s1ck authored Nov 17, 2023
1 parent ee9adfa commit c0f0639
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 26 deletions.
22 changes: 0 additions & 22 deletions crates/bench_util/Cargo.toml

This file was deleted.

8 changes: 7 additions & 1 deletion crates/builder/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,17 @@ rayon.workspace = true
thiserror.workspace = true

[dev-dependencies]
bench_util = { path = "../bench_util", version = "0.0.1" }
async-compression.workspace = true
criterion.workspace = true
directories.workspace = true
futures.workspace = true
rand.workspace = true
reqwest.workspace = true
tap.workspace = true
tempfile.workspace = true
tokio-tar.workspace = true
tokio-util.workspace = true
tokio.workspace = true

[features]
force_fallback_impl = []
Expand Down
File renamed without changes.
4 changes: 3 additions & 1 deletion crates/builder/benches/dotgraph.rs
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
use criterion::{black_box, criterion_group, criterion_main, Criterion, SamplingMode};
use graph_builder::prelude::*;

use bench_util::*;
use graph_builder::input::dotgraph::{LabelStats, NodeLabelIndex};
use rand::Rng;

mod common;
use common::*;

fn label_stats(c: &mut Criterion) {
let mut group = c.benchmark_group("label_stats");

Expand Down
3 changes: 2 additions & 1 deletion crates/builder/benches/edgelist.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
use criterion::{black_box, criterion_group, criterion_main, Criterion, SamplingMode};
use graph_builder::prelude::*;

use bench_util::*;
mod common;
use common::*;

fn max_node_id(c: &mut Criterion) {
let mut group = c.benchmark_group("max_node_id");
Expand Down
4 changes: 3 additions & 1 deletion crates/builder/benches/topology.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,11 @@ use criterion::*;
use graph_builder::graph::csr::Csr;
use graph_builder::prelude::*;

use bench_util::*;
use graph_builder::graph::adj_list::{AdjacencyList, DirectedALGraph};

mod common;
use common::*;

fn csr(c: &mut Criterion) {
let mut group = c.benchmark_group("csr_from_edge_list");
group.sampling_mode(SamplingMode::Flat);
Expand Down

0 comments on commit c0f0639

Please sign in to comment.