Description
Feature or enhancement
Proposal:
Currently perf trampoline (with PYTHONPERFSUPPORT=1
) is Linux only. I assume it's mainly because perf
is a Linux-only tool. But since then more non-Linux only profilers added support for Linux perf maps. For example samply
supports perf maps for a while now that's availabe both on Linux and macOS. I think there is no reason to keep it Linux only, especially since we now have tools that can use it.
I would be interested to work on this if there are no objections or concerns. I actually already have a working prototype, so I will polish it and submit a PR soon.
For example this currently works on Linux:
samply record PYTHONPERFSUPPORT=1 python test.py
But it doesn't output this perf map file for samply to use on macOS. It could be super useful to have it for macOS profiling.
Not related to Python, but we enabled the perf trampoline support for macOS on SpiderMonkey. Also, v8 enabled it on macOS recently. It would be great to have this for Python as well!
Has this already been discussed elsewhere?
This is a minor feature, which does not need previous discussion elsewhere
Links to previous discussion of this feature:
No response