oprofile Log


Commit Date  
[4d808a] by Maynard Johnson Maynard Johnson

Defaulted named unit mask does not work

A fix to allow named unit masks to be used as the default was recently
pushed upstream (Jun 24: Add support for named default unit masks), but
unfortunately, we all missed the fact that using a named default
unit mask didn't actually work insofar as counting events.
Here's an example on Sandybridge that should use the default named
unit mask "any":

operf -e uops_issued:2000000 ./my_test
and opreport shows "opreport error: No sample file found".

When the user does not specify a unit mask, the profiling tools
(as well as ocount) will use 'ophelp --unit-mask' to determine
what the default unit mask should be. All of the oprofile
tools -- operf, opcontrol, ocount -- expect a numerical value
to be returned. So, in the case of a named default unit mask,
the unit mask name returned by ophelp was not being handled
properly, and the end result was usually "No samples found"
by opreport (or zero event counts by ocount). This patch
fixes this problem.

Signed-off-by: Maynard Johnson <maynardj@us.ibm.com>

2013-07-24 17:20:03 Tree
[a8ab7e] by Maynard Johnson Maynard Johnson

Add 'check_count' parameter to parse_events function

For profiling, oprofile enforces a 'count' value to be
included in the event specification passed by a user.
It is the parse_events() function in libop/op_parse_event.c
that handles that checking. But for counting events
versus profiling, a 'count' value is meaningless, so this
patch adds support for parse_events() to parse an event
spec from either the profiling tools or the new counting
tool.

Signed-off-by: Maynard Johnson <maynardj@us.ibm.com>

2013-07-18 18:39:32 Tree
[e4754f] by William Cohen William Cohen

Remove obsolete --note-table-size option from opcontrol

Only the very old kernels (2.4) provided support for --note-table-size option.
Given that other 2.4 support was removed from OProfile there isn't any
reason to keep this around.

Signed-off-by: William Cohen <wcohen@redhat.com>

2013-07-05 15:08:14 Tree
[2e5055] by Maynard Johnson Maynard Johnson

Fix unit mask value for EXTRA_NONE

For named unit masks that do not have real extra values
associated with them, the 'extra' field of the unit mask
description structure is set to EXTRA_NONE, which is not
really a valid value as far as the performance monitoring
hardware goes. In such cases, 'ophelp --extra-mask'
was returning EXTRA_NONE to the operf and opcontrol
profilers, which results in no samples being collected,
since it's not a valid mask value. In such cases, ophelp
should return the simple unit mask value. The operf
and opcontrol tools that use 'ophelp --extra-mask' must
be able to differentiate between a simple mask value
and an "extra" value. Anything greater or equal to
0x40000 is interpreted as a valid "extra" value; otherwise
it's a simple mask value.

Signed-off-by: Maynard Johnson <maynardj@us.ibm.com>

2013-06-24 14:44:07 Tree
[93f232] by Suravee Suthikulpanit Suravee Suthikulpanit , pushed by Maynard Johnson Maynard Johnson

Add support for named default unit masks

Current libop does not allow named mask to be used as default mask.
This causes the tools to fail when user does not specify the named
mask of an event and relying on the numerical default unit mask
which could have duplication.

Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>

2013-06-24 14:22:07 Tree
[85d9b9] by Maynard Johnson Maynard Johnson

Add support for IBM POWER8 processor

The Power ISA 2.07 was recently published at http://power.org/documentation.
The IBM POWER8 processor currently under development is an implementation
of the ISA 2.07. This patch provides the initial support for POWER8
to oprofile. NOTE: Only operf support is included with this patch. The
legacy opcontrol-based profiler and the oprofile kernel module have
not been (and may never be) updated to support this new processor.
Potentially, some future kernel versions may allow timer mode opcontrol
to work for POWER8, but at the time of this commit, the 3.10 kernel did not.

Signed-off-by: Maynard Johnson <maynardj@us.ibm.com>

2013-05-31 21:34:29 Tree
[31ebe9] by Patrik Hagglund Patrik Hagglund , pushed by Maynard Johnson Maynard Johnson

Change /etc/mtab to /proc/mounts to enable running on busybox system

Note: This patch was originally submitted by Patrik in November, 2008.
However, after some review comments were provided back to Patrik, there
was no response, so the patch was never committed. A new request for
this fix arrived on the list on May 21, 2013 from Mark Pearson, so
we revive this patch and commit it now.

Signed-off-by: Patrik Hagglund <patrik.h.hagglund@ericsson.com>

2013-05-22 13:13:13 Tree
[6dc5d3] by Maynard Johnson Maynard Johnson

Add support for architected events for IBM ppc64 architecture

The Power ISA 2.07 was published at http://power.org/. This ISA
formally defines base performance monitoring facilities which
must be provided by any processor implementation of the ISA.
Specific implementations may provide additional features, but
must include the standard architected features.

This patch creates a generic ppc64 cpu type called
"ppc64/architected_events_v1" that has a list of events which
are defined in the ISA 2.07 performance monitoring unit
architecture section. This new generic type will only be
supported by operf. It will *not* be supported by the legacy
oprofile kernel driver and opcontrol-based profiler. This
new cpu type can be used in situations where oprofile is running
on a kernel that does not have full native support for an
ISA 2.07-based ppc64 processor, but does have the base level
architected support. OProfile userspace code detects such a
situation by inspecting the auxiliary vector of the operf program
and comparing AT_PLATFORM and AT_BASE_PLATFORM values (defined
in elf.h).

Signed-off-by: Maynard Johnson <maynardj@us.ibm.com>

2013-05-17 13:45:53 Tree
[f8dd71] by Suravee Suthikulpanit Suravee Suthikulpanit

Add Support for AMD Generic Performance Events

AMD generic performance events are a small set of events which are generally available across several
AMD processor families. PERF has already provided supports for generic performance counters regardless
of the processor family. This will allow operf to work as soon as PERF able to supports the performance
counters, and does not have to wait for the more complete family-specific events and unit_masks files
to be added to OProfile.

Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>

2013-02-07 16:49:30 Tree
[12d9e9] by Maynard Johnson Maynard Johnson

Unit mask bitmasks containing non-unique values should fail

When named unit mask support was added by Andi Kleen (Intel) in the 0.9.7
timeframe, it became possible for multiple unit masks to have the same
hex value for a given event. The (only) way to disambiguate these non-unique
unit mask values is to specify them by name. It was pointed out during patch
reviews that OR'ing together such unit masks (for bitmask types of unit
masks) was problematic. Andi asserted that bitmasks containing any of the
non-unique values simly would not be supported. Unfortunately, we dropped
the ball and did not document this restriction, and neither did we put any
checks into the code to prevent users from doing this.

Example:

On i386/sandybridge, the int_misc event has the following possible unit
mask values that can be put into a bitmask:

Unit masks (default 0x40)
----------
0x40: rat_stall_cycles Cycles Resource Allocation Table (RAT) external
stall is sent to Instruction Decode Queue (IDQ) for this thread.
0x03: recovery_cycles Number of cycles waiting to be recover after Nuke due
to all other cases except JEClear. (extra: cmask=1)
0x03: recovery_stalls_count Edge applied to recovery_cycles, thus counts
occurrences. (extra: edge cmask=1)

The event specification of int_misc:2000000:43 will be incorrectly accepted
as valid even though it is clearly ambiguous. With this patch, such unit mask
bitmask specifications will be detected, and we will exit gracefully with an
informative error message.

Signed-off-by: Maynard Johnson <maynardj@us.ibm.com>

2013-01-23 23:52:00 Tree
[745ede] by Daniel Hansel Daniel Hansel , pushed by Maynard Johnson Maynard Johnson

Change location to store intermediate JIT dump files

Since JIT support was added to Oprofile the intermediate JIT dump files
holding the sampling data collected for a Java process were stored in a
hard coded directory /var/lib/oprofile/jitdump that was world-writable.
The setting of a session specific directory (i.e. "--session-dir=...")
was not used anyway.

Now during profiling JIT dump files are stored under /tmp/.oprofile/jitdump.
When opjitconv has finished the conversion of the JIT dump files (the result
is stored under the default location (e.g. /var/lib/oprofile, ./oprofile_data
or the specified session directory) the intermediate JIT dump file will be
deleted.

Signed-off-by: Daniel Hansel <daniel.hansel@linux.vnet.ibm.com>

2013-01-23 16:24:37 Tree
[360280] by Maynard Johnson Maynard Johnson

Allow ppc64 events to be specified with or without _GRP<n> suffix

All events for IBM PowerPC server processors (except CYCLES) have
a _GRP<n> suffix. This is because the legacy opcontrol profiler
can only profile events in the same group (i.e., having the same
_GRP<n> suffix). But operf has no such restriction because it
can multiplex events; thus, so we should allow the user to pass
event names without the _GRP<n> suffix.

Signed-off-by: Maynard Johnson <maynardj@us.ibm.com>

2013-01-11 19:29:57 Tree
[e4d8c3] by Andreas Krebbel Andreas Krebbel , pushed by Maynard Johnson Maynard Johnson

Add support for IBM zEnterprise EC12 (zEC12)

This patch adds support for the latest release of the
IBM mainframe series - the IBM zEnterprise EC12 (zEC12).

The CPU measurement facility didn't change. So only the new CPU type
has to be tolerated.

Signed-off-by: Andreas Krebbel <krebbel@linux.vnet.ibm.com>

2013-01-11 14:24:47 Tree
[735d9e] by Maynard Johnson Maynard Johnson

ophelp lists events: Fix doc URL for ppc64 arch

When ophelp is used to list available events, it displays
some help text before the event list to direct the user
where to find more info. For the ppc64 architecture, a
stale URL was listed. This patch fixes that URL.

Signed-off-by: Maynard Johnson <maynardj@us.ibm.com>

2013-01-10 20:24:26 Tree
[ca6d91] by Maynard Johnson Maynard Johnson

Fix up configure to handle architectures that do not implement perf_event_open

This patch fixes the following problems:

1) The configure script allows the user to pass a location to kernel
headers (via --with-kernel option) such that, even if the running
kernel does not have perf_events support, it may be possible to
build operf (e.g., in cross-compile environments). But the message
'This kernel does not have perf_events support; falling back to legacy
oprofile' was being displayed inappropriately in such cases. This
patch changes the configure script so that the "falling back to
legacy oprofile" message will only be displayed if we're running
on a kernel that does not have perf_events support AND the user
did not pass specify the "--with-kernel" option.

2) Some architectures don't even implement the perf_event_open syscall, so the
configure script must do more than checking kernel version and whether or not
perf_event.h is present in order to decide if perf_events is supported.
This patch provides that extra capability.

These problems were reported by Tony Jones <tonyj@suse.com>.

Signed-off-by: Maynard Johnson <maynardj@us.ibm.com>

2012-12-05 16:16:35 Tree
[fcb818] by Maynard Johnson Maynard Johnson

Remove daemon/liblegacy since 2.4 kernels are no longer supported

A build problem reported by Vineet Gupta (Vineet.Gupta1@synopsys.com)
involving a compile failure of liblegacy code when built under uClibc
made it clear that we missed some things when support for 2.4 kernels
was removed in Oct 2012. The daemon/liblegacy directory is all about
support for 2.4 kernels, so this patch completely removes that directory.
Of course, this caused some breakage elsewhere in the oprofile tree
which needed fixing up.

Signed-off-by: Maynard Johnson <maynardj@us.ibm.com>

2012-12-05 15:55:18 Tree
[866abb] by Andi Kleen Andi Kleen , pushed by Maynard Johnson Maynard Johnson

Add the Haswell client event lists and model numbers

Also added simple support for PEBS events with perf_events
(ignored with the old driver) and include the Haswell PEBS events in the list.
And fixed "any" support.

v2: Regenerate events table with some improvements.
Address review feedback.

Signed-off-by: Andi Kleen <ak@linux.intel.com>

2012-11-08 01:14:47 Tree
[7e788a] by Maynard Johnson Maynard Johnson

Revert "Add the Haswell client event lists and model numbers"

This reverts commit 6d48ffa1e51e49ae3d3a5757baa7e2ed0d87d128.

Revert this commit since author info was wrong.

Signed-off-by: Maynard Johnson <maynardj@us.ibm.com>

2012-11-08 01:10:44 Tree
[6d48ff] by Maynard Johnson Maynard Johnson

Add the Haswell client event lists and model numbers
I also added simple support for PEBS events with perf_events
(ignored with the old driver) and include the Haswell PEBS events in the list.
And fixed "any" support.

v2: Regenerate events table with some improvements.
Address review feedback.

Signed-off-by: Andi Kleen <ak@linux.intel.com>

2012-11-08 00:57:34 Tree
[a8c44b] by Maynard Johnson Maynard Johnson

Add a mention of 'operf' man page in ophelp event list output

Signed-off-by: Maynard Johnson <maynardj@us.ibm.com>

2012-08-07 19:08:48 Tree
[10a636] by Maynard Johnson Maynard Johnson

Make opcontrol --status show session dir

For bug #3448632

Signed-off-by: Maynard Johnson <maynardj@us.ibm.com>

2012-08-06 22:24:03 Tree
[8f12d5] by Maynard Johnson Maynard Johnson

Fix configure to not alter user variables and remove non-working --with-gcc option

The configure script for oprofile had a few places
where user variables were being altered in contradiction
to the GNU Automake manual. See the following URL for details:

http://www.gnu.org/software/automake/manual/html_node/Flag-Variables-Ordering.html

In brief, user variables are those listed under "Some influential
environment variables" section of the output from 'configure --help'.
These are variables which the user may set prior to invoking configure,
and thus, the configure script should not alter them. This patch
makes use of new internal variables (e.g., OP_LDFLAGS and OP_CPPFLAGS),
which did unfortunately create quite a ripple effect with the Makefile.am
files. But this was unavoidable in order to correct this error.

Additionally, the '--with-gcc' option does not work anymore because
the generated configure script runs the AC_PROG_CC before processing the
"--with-gcc" option, so it fails to find a compiler. Unsure of when
this stopped working (assume it must have worked in 2005 when it was
initially added), but even fairly old distros (e.g., SLES 10) with
autoconf version 2.59 do not process this option as we would want.
If users wish to configure oprofile to use an alternate compiler,
they should pass the compiler pathnames on the configure command line, thusly:
./configure CC=/my-gcc-install/bin/gcc CXX=/my-gcc-instal/g++

Signed-off-by: Maynard Johnson <maynardj@us.ibm.com>

2012-07-13 17:44:49 Tree
[988007] by Maynard Johnson Maynard Johnson

Add --with-kernel configure option to specify location of kernel headers

This new configure option can be useful in cross-compile environments or
other situations where the host system does not support perf_events but
the user wants to build binaries for a target system that does support
perf_events.

Signed-off-by: Maynard Johnson <maynardj@us.ibm.com>
Signed-off-by: Balazs Kilvady <kilvadyb@homejinni.com>
Signed-off-by: Gergely Kis <gergely@homejinni.com>

2012-07-06 19:31:49 Tree
[3f1b50] by Will Deacon Will Deacon , pushed by Maynard Johnson Maynard Johnson

Update support for ARMv7 processors

- update architected ARMv7 event descriptions
- add support for Cortex-A5 ARMv7 PMU implementations
- add support for Cortex-A7 ARMv7 PMU implementations
- add support for Cortex-A15 ARMv7 PMU implementations

The part of this patch that adds support for new ARM PMU
implementations also updates the new function in
libop/op_cpu_type that was added in the perf-events branch
so that these new processors can be used with operf.
For this reason, this patch is currently only being applied
to the perf-events branch, so support for the new ARM processors
won't be available in oprofile "mainline" until we merge the
perf-events branch with the master branch.

Signed-off-by: Will Deacon <will.deacon@arm.com>

2012-07-02 13:47:17 Tree
[493c34] by Andi Kleen Andi Kleen , pushed by Maynard Johnson Maynard Johnson

This adds the event list for Intel IvyBridge and the model number
for the current IvyBridge systems

Signed-off-by: Andi Kleen <ak@linux.intel.com>

2012-05-25 15:07:36 Tree
Older >

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks