You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When specifying benchmark name with cargo bench BENCHNAME benchmarks are not run. It used to work, but I encountered this issue and I can reproduce it on criterion example.
Here is the output of cargo bench my_benchmark on criterion example:
$ cargo bench my_benchmark
Finished bench [optimized] target(s) in 0.02s
Running unittests src/lib.rs (target/release/deps/mycrate-85c68243aaad160d)
running 0 tests
test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s
Running benches/my_benchmark.rs (target/release/deps/my_benchmark-8c0cd1cf45dd6231)
Gnuplot not found, using plotters backend
Here are the files to reproduce:
Cargo.toml
[package]
name = "mycrate"
version = "0.1.0"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html[dev-dependencies]
criterion = "=0.5.1"[[bench]]
name = "my_benchmark"
harness = false
src/lib.rs
#[inline]pubfnfibonacci(n:u64) -> u64{match n {0 => 1,1 => 1,
n => fibonacci(n - 1) + fibonacci(n - 2),}}
When specifying benchmark name with
cargo bench BENCHNAME
benchmarks are not run. It used to work, but I encountered this issue and I can reproduce it on criterion example.Here is the output of
cargo bench my_benchmark
on criterion example:Here are the files to reproduce:
Rust version: 1.77.2
The text was updated successfully, but these errors were encountered: