profiling: replace pyflame with py-spy (#22864)

* py-spy

* remove pyflame

* find process by name
old-commit-hash: caad4919ac
commatwo_master
Greg Hogan 4 years ago committed by GitHub
parent a142638899
commit 15a58247dd
  1. 21
      selfdrive/debug/profiling/py-spy/profile.sh
  2. 3
      selfdrive/debug/profiling/pyflame/build.txt
  3. 3
      selfdrive/debug/profiling/pyflame/fix-aarch64.patch
  4. 3
      selfdrive/debug/profiling/pyflame/flame.sh
  5. 3
      selfdrive/debug/profiling/pyflame/flamegraph.pl
  6. 3
      selfdrive/debug/profiling/pyflame/pyflame

@ -0,0 +1,21 @@
#!/usr/bin/env bash
set -e
cd "$(dirname "$0")"
# find process with name passed in (excluding this process)
for PID in $(pgrep -f $1); do
if [ "$PID" != "$$" ]; then
ps -p $PID -o args
TRACE_PID=$PID
break
fi
done
if [ -z "$TRACE_PID" ]; then
echo "could not find PID for $1"
exit 1
fi
sudo env PATH=$PATH py-spy record -d 5 -o /tmp/perf$TRACE_PID.svg -p $TRACE_PID &&
google-chrome /tmp/perf$TRACE_PID.svg

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:157ca425c4ea68345b5d44356c6fd65d0e32a006e5a0e770c75c7d136dbd0c4c
size 174

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:7eb044134b9c9fae6152fe8c504810aa8d1dc6027af3157965f87f3431154855
size 11787

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:b83b957896775bc93363731be30b12aa232bb77334f379a7e3894de3d53ced03
size 194

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:4a373447ce1fed5e37708c689f10e6e852a69f87d3cb9bf36913f15a6fdba0dd
size 34109

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:b3a77c355bffcad1e01cbc466e8b7133de4a7411af9a3e1c90610f14f7650298
size 1757424
Loading…
Cancel
Save