「ubuntu」ubuntu通用的perf安装方法

一、linux内核源码安装

如果你的内核是通过源码安装的,则在内核源码的tools下会有perf工具。安装如下:

cd linux-xxx-xxxx-xxx  //你的内核源码目录
sudo make -C tools/ perf_install prefix=/usr

等待编译安装完即可。
另外,tools目录下还有以下工具:

$ make -C tools/
make: Entering directory '/home/xxx/xenomai/linux-xxx-lts-5.10-dovetail-xenomai/tools'
Possible targets:

  acpi                   - ACPI tools
  bpf                    - misc BPF tools
  cgroup                 - cgroup tools
  cpupower               - a tool for all things x86 CPU power
  debugging              - tools for debugging
  firewire               - the userspace part of nosy, an IEEE-1394 traffic sniffer
  firmware               - Firmware tools
  freefall               - laptop accelerometer program for disk protection
  gpio                   - GPIO tools
  hv                     - tools used when in Hyper-V clients
  iio                    - IIO tools
  xxx-speed-select       - xxx Speed Select tool
  kvm_stat               - top-like utility for displaying kvm statistics
  leds                   - LEDs  tools
  liblockdep             - user-space wrapper for kernel locking-validator
  objtool                - an ELF object analysis tool
  pci                    - PCI tools
  perf                   - Linux performance measurement and analysis tool
  rpmb                   - Replay protected memory block access tool
  selftests              - various kernel selftests
  bootconfig             - boot config tool
  spi                    - spi tools
  tmon                   - thermal monitoring and tuning tool
  turbostat              - xxx CPU idle stats and freq reporting tool
  usb                    - USB testing tools
  virtio                 - vhost test module
  vm                     - misc vm tools
  wmi			- WMI interface examples
  x86_energy_perf_policy - xxx energy policy tool

You can do:
 $ make -C tools/ <tool>_install

  from the kernel command line to build and install one of
  the tools above

  $ make tools/all

  builds all tools.

  $ make tools/install

  installs all tools.

Cleaning targets:

  all of the above with the "_clean" string appended cleans
    the respective build directory.
  clean: a summary clean target to clean _all_ folders

二、apt安装

这个网上有教程,可以去搜索

  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值