Skip to content

Commit

Permalink
chore: add script for generating flamegraph
Browse files Browse the repository at this point in the history
  • Loading branch information
aner-starkware committed Jul 24, 2024
1 parent 6236ba9 commit f00352c
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions generate_flamegraph.bash
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
trap 'echo 4 | sudo tee /proc/sys/kernel/perf_event_paranoid ' EXIT SIGINT SIGTERM

if ! command -v jq; then
cargo install jq
fi
if ! command -v flamegraph; then
cargo install flamegraph
fi
if ! command -v perf; then
sudo apt-get install linux-tools-common linux-tools-generic linux-tools-`uname -r`
fi
echo 2 | sudo tee /proc/sys/kernel/perf_event_paranoid

gcloud storage cat gs://committer-testing-artifacts/23ffcf5/committer_flow_inputs.json | jq -r .committer_input | CARGO_PROFILE_RELEASE_DEBUG=true cargo flamegraph -- commit

echo 4 | sudo tee /proc/sys/kernel/perf_event_paranoid

0 comments on commit f00352c

Please sign in to comment.