Bug 5630 - perf test shows multiple errors and fails on qemux86
Summary: perf test shows multiple errors and fails on qemux86
Status: VERIFIED NOTABUG
Alias: None
Product: BSPs
Classification: Build System, Metadata & Runtime
Component: bsps-oe-core (show other bugs)
Version: unspecified
Hardware: Other x86
: Medium normal
Target Milestone: 1.6 M2
Assignee: Tom Zanussi
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2013-12-05 10:31 UTC by Alexandru Georgescu
Modified: 2014-02-10 11:42 UTC (History)
0 users

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: No (bug/feature does not impact docs)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexandru Georgescu 2013-12-05 10:31:12 UTC
poky: c51730aaa91066cfb51ad6ec2920fb4f9d9ea94c
QEMU image used: http://autobuilder.yoctoproject.org/pub/releases/1.6_M1.rc1/machines/qemu/qemux86/core-image-sato-sdk-qemux86.tar.bz2

Errors appear when running "$ perf test" in qemux86:

root@qemux86:~# perf test
 1: vmlinux symtab matches kallsyms                        : Skip
 2: detect open syscall event                              : Ok
 3: detect open syscall event on all cpus                  : Ok
 4: read samples using the mmap interface                  : Ok
 5: parse events tests                                     :  Warning: function scsi_trace_parse_cdb not defined
  Warning: function scsi_trace_parse_cdb not defined
  Warning: function scsi_trace_parse_cdb not defined
  Warning: function scsi_trace_parse_cdb not defined
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: bad op token {
  Warning: Error: expected type 4 but read 0
  Warning: function jiffies_to_msecs not defined
  Warning: function jiffies_to_msecs not defined
  Warning: unknown op '{'
  Warning: unknown op '{'
 Ok
 6: x86 rdpmc test                                         :Error: sys_perf_event_open() syscall returned with -1 (No such file or directory)
 FAILED!
 7: Validate PERF_RECORD_* events & perf_sample fields     : FAILED!
 8: Test perf pmu format parsing                           : Ok
 9: Test dso data interface                                : Ok
10: roundtrip evsel->name check                            : Ok
11: Check parsing of sched tracepoints fields              : FAILED!
12: Generate and check syscalls:sys_enter_open event fields: Ok
13: struct perf_event_attr setup                           :sh: /home/pokybuild/yocto-autobuilder/yocto-slave/nightly-x86/build/build/tmp/sysroots/x86_64-linux/usr/bin/python-native/python: No such file or directory
 FAILED!
14: Test matching and linking mutliple hists               : Ok
15: Try 'use perf' in python, checking link problems       : FAILED!
16: Test breakpoint overflow signal handler                : FAILED!
17: Test breakpoint overflow sampling                      : FAILED!
18: Test number of exit event of a simple workload         : Skip
19: Test software clock events have valid period values    : Ok
root@qemux86:~#
Comment 1 Darren Hart 2013-12-05 15:47:47 UTC
Tom, can you have a look at this please? Do we expect this to work on all BSPs or is there a debug/tracing feature required?
Comment 2 Tom Zanussi 2013-12-05 15:52:20 UTC
A quick look at the output seems to show it trying to parse e.g. scsi events, which may not be there if scsi isn't enabled in the kernel.

My first question is if this is a regression - I don't recall this test being run before - or is this a new QA test?
Comment 3 Alexandru Georgescu 2013-12-05 16:00:30 UTC
(In reply to comment #2)
> A quick look at the output seems to show it trying to parse e.g. scsi
> events, which may not be there if scsi isn't enabled in the kernel.
> 
> My first question is if this is a regression - I don't recall this test
> being run before - or is this a new QA test?

Hi Tom,
We don't usually test this, but I stumbled on it by testing eclipse-pluign. Eclipse has a tool that gives the developers the ability to use perf. So it was me just trying "perf test" in the Eclipse plugin and see what's the output.

I cannot tell if it's a regression or not since. I also tested it on qemux86. On qemux86-64 gives slightly similar issues. I don't know for the other arches but I suspect similar output as well.
Comment 4 Tom Zanussi 2013-12-18 19:13:21 UTC
perf testing shouldn't be done using qemu, which doesn't properly emulate the PMU.

From qemux86 dmesg:

Performance Events: Broken PMU hardware detected, using software events only.
Comment 5 Tom Zanussi 2013-12-18 19:14:34 UTC
See previous entry - not expected to work on qemu.
Comment 6 Alexandru Georgescu 2014-02-10 11:42:31 UTC
verified as per Tom's comments.