我正在使用命令 perf record 记录 frm linux 的性能计数器。
我想使用结果perf.data
作为其他编程应用程序的输入。你知道我该如何读取和解析其中的数据吗perf.data
?有没有办法把它改造成.text
文件或.csv
?
有内置的perf.data
解析器和打印机perf
Linux 工具的工具,带有子命令“script”。
转换perf.data
file
perf script > perf.data.txt
转换其他文件中的性能记录的输出(perf record -o filename.data
) use -i
option:
perf script -i filename.data > filename.data.txt
perf script
记录于man perf-script
,可在线获取http://man7.org/linux/man-pages/man1/perf-script.1.html http://man7.org/linux/man-pages/man1/perf-script.1.html
perf-script - Read perf.data (created by perf record) and display
trace output
This command reads the input file and displays the trace recorded.
'perf script' to see a detailed trace of the workload that was
recorded.
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)