graph-api-benches

Crates.iograph-api-benches
lib.rsgraph-api-benches
version
sourcesrc
created_at2025-04-12 22:42:06.96923+00
updated_at2025-04-20 22:45:05.127703+00
descriptionBenchmarking utilities and performance tests for the graph-api ecosystem
homepage
repositoryhttps://github.com/BrynCooke/graph-api
max_upload_size
id1631326
Cargo.toml error:TOML parse error at line 18, column 1 | 18 | autolib = false | ^^^^^^^ unknown field `autolib`, expected one of `name`, `version`, `edition`, `authors`, `description`, `readme`, `license`, `repository`, `homepage`, `documentation`, `build`, `resolver`, `links`, `default-run`, `default_dash_run`, `rust-version`, `rust_dash_version`, `rust_version`, `license-file`, `license_dash_file`, `license_file`, `licenseFile`, `license_capital_file`, `forced-target`, `forced_dash_target`, `autobins`, `autotests`, `autoexamples`, `autobenches`, `publish`, `metadata`, `keywords`, `categories`, `exclude`, `include`
size0
Bryn Cooke (BrynCooke)

documentation

https://bryncooke.github.io/graph-api/

README

Graph-API Benchmarks

Welcome to graph-api-benches  the performance measurement toolkit for the Graph-API ecosystem!

This crate provides comprehensive benchmarking utilities to assess and compare the performance of different graph implementations. Whether you're optimizing your own graph implementation or evaluating which implementation best suits your needs, these benchmarks offer valuable insights.

Benchmark Categories

This suite includes performance tests for all critical graph operations:

  • Construction: Measure how quickly graphs can be built
  • Insertion: Evaluate vertex and edge addition performance
  • Traversal: Time how efficiently graphs can be navigated
  • Query: Benchmark lookup operations with different index types
  • Mutation: Test the performance of graph modifications
  • Scale: Assess how implementations handle graphs of different sizes

Feature Toggles

Like other Graph-API crates, benchmarks can be selectively enabled based on the features your implementation supports:

[dev-dependencies]
graph-api-benches = { version = "0.1.0", features = [
    "vertex-hash-index",
    "vertex-range-index",
    "edge-label-index"
]}

Using the Benchmarks

To benchmark your own graph implementation:

  1. Create a benchmark file in your project
  2. Import the benchmark functions from this crate
  3. Create instances of your graph for testing
  4. Run the benchmarks with Criterion
use criterion::{criterion_group, criterion_main, Criterion};
use graph_api_benches::{bench_vertex_insertion, bench_traversal};
use your_crate::YourGraph;

fn vertex_insertion(c: &mut Criterion) {
    bench_vertex_insertion::<YourGraph>(c, "your_graph");
}

fn traversal(c: &mut Criterion) {
    bench_traversal::<YourGraph>(c, "your_graph");
}

criterion_group!(benches, vertex_insertion, traversal);
criterion_main!(benches);

Performance Comparison

The benchmark suite is used to produce comparative metrics between different Graph-API implementations, helping you choose the right implementation for your specific use case.

Contributions

Have ideas for additional benchmarks? We welcome contributions that help evaluate graph performance for different scenarios and workloads.

Optimize your graph operations with confidence using graph-api-benches!

Learn more in the graph-api book.

Commit count: 0

cargo fmt