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

Create perf-helpers subproject to help in running code profiling #93

Merged

Conversation

macisamuele
Copy link
Contributor

The goal of this PR is to streamline the process of getting obtaining a flamegraph to focus optimisation efforts (as described on #91 (comment))

The cargo-flamegraph crate allows to run a binary with perf/dtrace (depending on the platform) and producing a SVG file containing the flamegraph.

In order to obtain it we need to have debug symbols in the release build (and the subproject takes care of that).

In order to make the tool easier to use I've ensured that perf-helpers/src/main.rs retrieves the schema and instance JSON representation at compile time, such that testing different combinations requires to modify the command to run instead of the file to compile.

The way of using it is

./perf-helpers/run ${schema_path} ${instance_path} [${number_of_iterations}]

The output file will be available on the directory from where you've run the script

@Stranger6667 Stranger6667 merged commit 9767a9f into Stranger6667:master May 25, 2020
@macisamuele macisamuele deleted the maci-define-perf-helper-tool branch May 25, 2020 10:39
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