软件安装
- 在 mac os 上安装
brew install gperftools
在 CMakeLists.txt 中链接 profiler
- 假设程序为:calculation_profile.cc
|
|
执行 profiler
|
|
TODO
火焰图
其他
- 遇到问题
otool-classic: can't open file: /usr/lib/system/libXXXXX
,好像可以不用管,不影响结果。
brew install gperftools
|
|
|
|
火焰图
otool-classic: can't open file: /usr/lib/system/libXXXXX
,好像可以不用管,不影响结果。