Skip to content

Parallel benchmarking - #2653

Open
JonathanBrouwer wants to merge 1 commit into
rust-lang:mainfrom
JonathanBrouwer:parallel-benchmark
Open

JonathanBrouwer wants to merge 1 commit into
rust-lang:mainfrom
JonathanBrouwer:parallel-benchmark

Conversation

@JonathanBrouwer

@JonathanBrouwer JonathanBrouwer commented Nov 27, 2026 •

Copy link
Copy Markdown
Member

This will use multiple threads, running benchmarks in parallel.
This has been a heavily requested feature from people at Hexcat.

While for most metrics this heavily increases noise, for instructions it is in practice not noticeable, and this makes iteration cycles on performance work a lot faster.
The default for the job queue should definitely always stay 1.

cc @jdonszelmann @scrabsha @bal-e

Comment thread collector/src/bin/collector.rs Resolved
print_intro: &dyn Fn(),
measure: F,
) {
let mut tx = conn.transaction().await;

@JonathanBrouwer JonathanBrouwer Nov 27, 2026 •

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The transaction is removed here. I don't think this is needed for correctness, but I'm not sure.

Comment thread collector/src/bin/collector.rs Resolved
@Kobzol

Kobzol commented Nov 27, 2026

Copy link
Copy Markdown
Member

Hopefully the mutex won't be required after #2654. Regarding BenchmarkErrors, yeah, I'd turn that into atomics.

@JonathanBrouwer

Copy link
Copy Markdown
Member Author

Rebased on #2654, this PR is now a lot less criminal and the diff is actually kinda small :3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants