liveBook · Manning

Criterion.rs

Criterion.rs is a Rust benchmarking library for statistically driven measurement and evaluation of code performance.

How 3 Manning books explain it

Refactoring to Rust

Criterion is a Rust benchmarking library that performs statistically driven performance measurements.

How it is used
Measures Rust code and Rust-integrated Python code when performance comparisons need more reliable results.
How deep it goes
Explains configuration, benchmark registration, iteration, optimization control, and sample output, but not the underlying statistical methodology.
Examples
Uses integer-width microbenchmarks and a pure-Python versus Rust-extension JSON calculation.
What you can do after
Apply it via Cargo to build benchmark targets, measure functions, and compare reported timing ranges.

Read how Refactoring to Rust explains Criterion.rs →

Latency

Criterion is a Rust benchmarking library for statistically evaluating the performance of code.

How it is used
Measures Rust code reliably while guiding performance work from runtime evidence toward targeted optimization.
How deep it goes
Provides setup, execution, statistical output, implementation comparison, and profiling, but does not detail Criterion internals.
Examples
Uses recursive, memoized, and iterative Fibonacci implementations, cargo bench output, outlier reports, and a flame graph.
What you can do after
Diagnose performance with statistically informed timings, compare implementations, and locate costly call paths using flame graphs.

Read how Latency explains Criterion.rs →

Idiomatic Rust

Criterion.rs is a Rust benchmarking library that provides statistically oriented and feature-rich performance measurement.

How it is used
Provides feature-rich performance measurement for running benchmarks on stable Rust.
How deep it goes
Identifies a feature-rich benchmarking tool and Haskell port, but does not detail its API or statistical methods.
What you can do after
Apply it to run benchmarks on stable Rust.

Read how Idiomatic Rust explains Criterion.rs →

What to know first

Related concepts

Questions about Criterion.rs

What is Criterion.rs?

Criterion.rs is a Rust benchmarking library for statistically driven measurement and evaluation of code performance.

Which Manning books explain Criterion.rs?

Refactoring to Rust, Latency and Idiomatic Rust.

What should I know before learning Criterion.rs?

Manning books that teach Criterion.rs usually introduce Rust first.

What is the difference between Criterion.rs and benchmarking tool?

Criterion.rs is a Rust benchmarking library for statistically driven measurement and evaluation of code performance. A benchmarking tool is software that runs workloads, measures performance, and records or summarizes results.

What is Criterion.rs a kind of?

Criterion.rs is a kind of crate. A crate is a unit of Rust code compiled as a library or executable, comprising source code and its module hierarchy and distributable through package metadata.

These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.