Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test(bench): Playing with flamegraph generation [wip] #8

Draft
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

metachris
Copy link
Contributor

📝 Summary

Trying to integrate flamegraph generation for the benchmarks (using flamegraph-rs and pprof-rs):

This setup uses the pprof-rs Flamegraph-Profiler for Criterion. Note: Custom profilers are only executed when passing a --profile-time argument (see also the relevant Criterion docs).

Flamegraphs can be generated for benchmarks with this command:

$ make bench-flamegraphs 

Curiously, trying to generate flamegraphs for the SSZ encoding benchmark causes a segfault:

$ cargo bench --bench bench_flamegraphs -- --profile-time 3

[...]

Benchmarking MEV-Boost SubmitBlock serialization/SSZ encoding: Profiling for 3.0000 serror: bench failed, to rerun pass `--bench bench_flamegraphs`

Caused by:
  process didn't exit successfully: `/Users/metachris/Projects/2024/rbuilder-private/target/release/deps/bench_flamegraphs-9f5a78747b3c4349 --profile-time 3 --bench` (signal: 5, SIGTRAP: trace/breakpoint trap)
That's why the flamegraph benchmarks are separated into bench_flamegraphs for now.

💡 Motivation and Context

It would be amazing to have meaningful flamegraphs.


✅ I have completed the following steps:

  • Run make lint
  • Run make test
  • Added tests (if applicable)

Copy link

github-actions bot commented Jul 3, 2024

Benchmark results for 7688350

Report: https://flashbots-rbuilder-ci-stats.s3.us-east-2.amazonaws.com/benchmark/7688350-27a8867/report/index.html

Date (UTC) 2024-07-03T12:07:28+00:00
Commit 7688350e20a7c475e1fbc9134ab757a1b7b3faf3
Base SHA 27a8867ad82b64230ce21dc6e0866c3599f10fbd

Significant changes

None

@metachris metachris changed the title [wip] Playing with flamegraph generation test(bench): Playing with flamegraph generation [wip] Jul 3, 2024
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.

1 participant