Your browser sucks, JavaScript disabled! Gunnar's console needs JavaScript and WebAssembly. Git over SSH on port 2222 does not.

nordisk/gunnar

bench-stock/Cargo.toml

# The part of gunnar's benchmark suite that needs **no gunnar crate at all**.
#
# ## Why this manifest exists
#
# `bench/Cargo.toml` is one detached workspace with one big example target
# (`examples/nornir-bench.rs`, 20 890 lines, 47 arms) plus fourteen standalone
# probes, and every one of them links `gunnar-pack`, `gunnar-store`,
# `gunnar-wire`, `gunnar-stage`, `gunnar-bitmap`, `gunnar-client` or
# `gunnar-pktline`. Those eighteen crates were parked under
# `parked-record/crates/` on 2026-08-07, so `bench/` no longer resolves at
# all: `cargo metadata` fails on the first missing path dependency and nothing
# downstream of it can be built, run or even type-checked.
#
# Repointing `bench/`'s paths at `parked-record/crates/*` would make the
# parked implementation a live dependency again, which is the one thing the
# parking was for. So instead, the measurements that never needed gunnar in the
# first place are given a manifest that names none of it.
#
# ## What is in here, and why it is not a copy
#
# Both targets below are the **same files** `bench/` already owns, reached by a
# relative `path`. Nothing is duplicated (one implementation): when the parked crates come
# back, or when the arms are repointed at the znippy-git store, `bench/` keeps
# building these exact sources and this manifest keeps building them too.
#
#  * `src/oid_index.rs` — the `.idx` reader and its two candidate replacements
#    (`Fanout16`, `OidStree`, `OidStree32`, `KeyColumn`). Its own module header
#    says "self-contained on purpose — `memmap2`, `std`, and the tree", and that
#    is exactly true: zero gunnar identifiers in 684 lines. It is also the
#    question the znippy-git store now has to answer for itself
#    (`znippy-plugin-git/src/oid_index.rs`), so it is the one piece of the old
#    suite that is immediately reusable by the new one.
#
#  * `examples/deltachain-probe.rs` — read/header/entry-copy cost per delta
#    depth on a real pack, plus the delta-base-cache size sweep. Pure `gix-odb`
#    / `gix-pack`, with a single exception: one A/B column holds
#    `gunnar_store::delta_cache::DeltaBaseCache` against `gix-pack`'s LRU. That
#    column is now behind the `gunnar-fifo` feature, off here and **on** in
#    `bench/`, so neither build loses anything it had.
[package]
name = "gunnar-bench-stock"
version = "0.0.0"
edition = "2021"
publish = false

# A detached workspace, for the same reason `bench/` is one: the root
# `Cargo.toml` must not grow a member, and the parent workspace's lockfile must
# not be touched by anything measured here.
[workspace]

[lib]
name = "gunnar_bench_stock"
path = "src/lib.rs"

[dependencies]
# The `.idx` is read the way git reads one: mapped, not slurped.
memmap2 = "0.9"
# `stree` / `stree32`, the two candidate replacements for git's fanout+bsearch.
#
# A crates.io VERSION since 2026-09-12, and it was the last sibling path
# anywhere in this repository. `bench/Cargo.toml` made the same move on
# 2026-09-09 for the same crate and wrote down what the path form actually
# cost: cargo reads a path dependency's manifest at RESOLVE time, so
# `../../znippy-zoomies` was a hard requirement of `cargo metadata` on this
# tree — a clone with nothing beside it could not so much as list this
# manifest's contents, let alone build the probe. Same version, two packages
# (one path, one registry) is the other half of that bill; `bench/`'s manifest
# records eight crates it hit that way through draupnir.
#
# `default-features = false` keeps the optional `testmatrix`/`vann-mmap`
# features off, exactly as `bench/` asks for them, so the two manifests
# resolve the same crate.
#
# To measure against an UNPUBLISHED zoomies change, add the patch below —
# a detached workspace root, so it inherits nothing and must say it itself.
# It is commented out because a live one re-imposes the sibling checkout this
# line was changed to remove:
#
#     [patch.crates-io]
#     znippy-zoomies = { path = "../../znippy-zoomies" }
znippy-zoomies = { version = "0.1.26", default-features = false }

anyhow = "1"
gix-hash = { version = "0.28", features = ["sha1", "sha256"] }
gix-odb = { version = "0.87", features = ["sha1", "sha256"] }
# `cache::lru::MemoryCappedHashmap`, the LRU the size sweep is measured against.
# Same version and same feature shape `bench/` asks for, so the resolver
# unifies rather than building gix twice.
gix-pack = { version = "0.77", default-features = false, features = [
    "pack-cache-lru-dynamic",
] }

[features]
# OFF here, ON in `bench/`. The one block in `deltachain-probe` that holds
# gunnar's FIFO delta-base cache against `gix-pack`'s LRU. Everything else in
# that probe is stock `gix`.
default = []
gunnar-fifo = []

[[example]]
name = "deltachain-probe"
path = "../bench/examples/deltachain-probe.rs"

# The one patched dependency, restated because cargo cannot inherit a `[patch]`
# through a path dependency and this is a detached workspace root. Same reason
# `bench/Cargo.toml` restates it: without this table the probe would measure the
# *unpatched* `gix-features` while the shipped binary ran the patched one.
[patch.crates-io]
gix-parallel = { path = "../vendor/gix-parallel" }