i.MX51 EVK Linux Reference Manual
Freescale Semiconductor
33-1
Chapter 33
OProfile
OProfile is a system-wide profiler for Linux systems, capable of profiling all running code at low
overhead. OProfile is released under the GNU GPL. It consists of a kernel driver, a daemon for collecting
sample data, and several post-profiling tools for turning data into information.
33.1
Overview
OProfile leverages the hardware performance counters of the CPU to enable profiling of a wide variety of
interesting statistics, which can also be used for basic time-spent profiling. All code is profiled: hardware
and software interrupt handlers, kernel modules, the kernel, shared libraries, and applications.
33.2
Features
The features of the OProfile are as follows:
•
Unobtrusive—No special recompilations or wrapper libraries are necessary. Even debug symbols
(-g option to
gcc
) are not necessary unless users want to produce annotated source. No kernel patch
is needed; just insert the module.
•
System-wide profiling—All code running on the system is profiled, enabling analysis of system
performance.
•
Performance counter support—Enables collection of various low-level data and association for
particular sections of code.
•
Call-graph support—With an 2.6 kernel, OProfile can provide gprof-style call-graph profiling data.
•
Low overhead—OProfile has a typical overhead of 1–8% depending on the sampling frequency
and workload.
•
Post-profile analysis—Profile data can be produced on the function-level or instruction-level
detail. Source trees, annotated with profile information, can be created. A hit list of applications
and functions that utilize the most CPU time across the whole system can be produced.
•
System support—Works with almost any 2.2, 2.4 and 2.6 kernels, and works on Cortex-A8 based
platforms.
33.3
Hardware Operation
OProfile is a statistical continuous profiler. In other words, profiles are generated by regularly sampling
the current registers on each CPU (from an interrupt handler, the saved PC value at the time of interrupt is
stored), and converting that runtime PC value into something meaningful to the programmer.
OProfile achieves this by taking the stream of sampled PC values, along with the detail of which task was
running at the time of the interrupt, and converting the values into a file offset against a particular binary
Summary of Contents for i.MX51 EVK
Page 1: ...Part Number 924 76374 Rev 10 11 01 11 2010 i MX51 EVK Linux Reference Manual...
Page 14: ...i MX51 EVK Linux Reference Manual xiv Freescale Semiconductor...
Page 18: ...i MX51 EVK Linux Reference Manual xviii Freescale Semiconductor...
Page 24: ...i MX51 EVK Linux Reference Manual xxiv Freescale Semiconductor...
Page 38: ...Machine Specific Layer MSL i MX51 EVK Linux Reference Manual 2 8 Freescale Semiconductor...
Page 52: ...MC13892 Digitizer Driver i MX51 EVK Linux Reference Manual 5 4 Freescale Semiconductor...
Page 64: ...TV Encoder TVE Driver i MX51 EVK Linux Reference Manual 10 4 Freescale Semiconductor...
Page 82: ...Video for Linux Two V4L2 Driver i MX51 EVK Linux Reference Manual 12 8 Freescale Semiconductor...
Page 86: ...i MX5 Dual Display i MX51 EVK Linux Reference Manual 13 4 Freescale Semiconductor...
Page 100: ...X Windows Acceleration i MX51 EVK Linux Reference Manual 16 6 Freescale Semiconductor...
Page 118: ...Low Level Keypad Driver i MX51 EVK Linux Reference Manual 20 6 Freescale Semiconductor...
Page 134: ...Security Drivers i MX51 EVK Linux Reference Manual 22 10 Freescale Semiconductor...
Page 148: ...Inter IC I2C Driver i MX51 EVK Linux Reference Manual 24 4 Freescale Semiconductor...
Page 178: ...ARC USB Driver i MX51 EVK Linux Reference Manual 29 10 Freescale Semiconductor...
Page 194: ...OProfile i MX51 EVK Linux Reference Manual 33 6 Freescale Semiconductor...