使用perf工具分析性能
可分析到驱动内部。请参考 https://blog.youkuaiyun.com/u014608280/article/details/80265718
使用gperf工具分析性能
这是Google工具 依赖于libunwind。需要先编译libunwind
#!/bin/bash
set -x
pushd libunwind-1.3.1
./configure --host=aarch64-linux-gnu --build=aarch64 --disable-static CFLAGS=-U_FORTRIFY_SOURCE --prefix=/my/install
if [ $? -ne 0 ]; then
echo "configure failed"
popd
exit -1
fi
make -j4
if [ $? -ne 0 ]; then
echo "make failed"
popd
exit -1
fi
make install
if [ $? -ne 0 ]; then
echo "install failed"
popd
exit -1
fi
make clean
popd
再安装gperf
#!/bin/bash
set -x
pushd gperftools-2.7
install_path='/my/install'
./configure --host=aarch64-lin