2020-04-02 20:49:12 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
set -e
|
|
|
|
|
|
|
|
EVENTS="sdt_wayvnc:* sdt_neatvnc:*"
|
|
|
|
|
|
|
|
delete_all_events()
|
|
|
|
{
|
|
|
|
for e in $EVENTS; do
|
|
|
|
sudo perf probe -d "$e" || true
|
|
|
|
done
|
|
|
|
}
|
|
|
|
|
|
|
|
add_all_events()
|
|
|
|
{
|
|
|
|
for e in $EVENTS; do
|
|
|
|
sudo perf probe "$e"
|
|
|
|
done
|
|
|
|
}
|
|
|
|
|
|
|
|
sudo perf buildid-cache -a build/wayvnc
|
|
|
|
sudo perf buildid-cache -a build/subprojects/neatvnc/libneatvnc.so
|
|
|
|
|
|
|
|
delete_all_events
|
|
|
|
add_all_events
|
|
|
|
|
2022-08-27 10:54:35 +00:00
|
|
|
trap "sudo chown $USER:$USER perf.data*" EXIT
|
2020-04-02 20:49:12 +00:00
|
|
|
|
2022-08-27 10:54:35 +00:00
|
|
|
sudo perf record -aR -e ${EVENTS// /,}
|
2020-04-02 20:49:12 +00:00
|
|
|
|