Changes between Version 4 and Version 5 of Debugging/LowLevelProfiling/Perf


Ignore:
Timestamp:
Apr 19, 2011 10:53:28 AM (4 years ago)
Author:
tibbe
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Debugging/LowLevelProfiling/Perf

    v4 v5  
    33Since Linux 2.6.31, linux has had a new performance counter subsystem (initially called "perf counters" and later renamed to "perf events").  The facilities provided by perf events, and the associated tool "perf", are generally a superset of what you can do with [wiki:Debugging/LowLevelProfiling/oprofile oprofile] and [wiki:Debugging/LowLevelProfiling qprof], so it's a good idea to use perf if you can.  It does support fewer processors than the other systems, although more are being added over time.
    44
    5 The perf events subsystem is compiled in by default in the kernel shipped with most distros (e.g. Ubuntu) which means there's no fiddling around compiling your own kernel or modules.  On Debian and Ubuntu you can install "perf" by installing the `linux-tools-<kernel version>` package:
     5The perf events subsystem is compiled in by default in the kernel shipped with most distros (e.g. Ubuntu) which means there's no fiddling around compiling your own kernel or modules.
     6
     7== Installation ==
     8
     9== Debian/Ubuntu ==
     10
     11On Debian and Ubuntu you can install "perf" by installing the `linux-tools-<kernel version>` package:
    612
    713{{{
    814$ sudo apt-get install linux-tools-<kernel version>
    915}}}
     16
     17== Compiling from source ==
    1018
    1119If your distro doesn't include "perf" as a package you can build it manually like so:
     
    1725 * `make`
    1826 * if you want, `make install`, or just copy the binary somewhere appropriate
     27
     28== Usage ==
    1929
    2030Check that it works: