Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revision | |
howtos:profiling:gperftools [2015/12/12 18:50] – Some minor updates techee | howtos:profiling:gperftools [2020/03/16 13:58] (current) – OS X to macOS 邢家朋 |
---|
</code> Notice the extension 0 in the profiler file - you can record multiple profiles during a single run by sending the signal several times and the individual profiles are numbered by the extension starting from 0. | </code> Notice the extension 0 in the profiler file - you can record multiple profiles during a single run by sending the signal several times and the individual profiles are numbered by the extension starting from 0. |
| |
==== OS X ==== | ==== macOS ==== |
There's a bug in older versions of OS X which prevents getting good results from the profiler. There's a (scary) way to fix this by [[https://godoc.org/rsc.io/pprof_mac_fix| binary patching the OS X kernel]] (I've used it, it worked, but no guarantees at all). | There's a bug in older versions of macOS(or OS X) which prevents getting good results from the profiler. There's a (scary) way to fix this by [[https://godoc.org/rsc.io/pprof_mac_fix| binary patching the OS X kernel]] (I've used it, it worked, but no guarantees at all). |
| |
==== Other options ==== | ==== Other options ==== |
There are many additional options in gperftools and while I found the above sufficient for profiling Geany, there may be cases where some extra parameter may be necessary (such as filtering the graph to some subset, more frequent sampling, etc.). See the CPU profiler [[http://gperftools.googlecode.com/git/doc/cpuprofile.html| documentation]] for more info. | There are many additional options in gperftools and while I found the above sufficient for profiling Geany, there may be cases where some extra parameter may be necessary (such as filtering the graph to some subset, more frequent sampling, etc.). See the CPU profiler [[http://gperftools.googlecode.com/git/doc/cpuprofile.html| documentation]] for more info. |