Bug 497230 - oprofile doesn't like atom or Nehalem
Summary: oprofile doesn't like atom or Nehalem
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: oprofile
Version: 10
Hardware: x86_64
OS: Linux
low
high
Target Milestone: ---
Assignee: William Cohen
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-04-22 21:28 UTC by Linus Torvalds
Modified: 2009-07-11 17:36 UTC (History)
1 user (show)

Fixed In Version: 0.9.4-7.fc10
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-07-11 16:56:36 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Linus Torvalds 2009-04-22 21:28:56 UTC
Description of problem:

Modern x86 CPU's that are listed as i386/arch_perfmon seem to not work with the Fedora profile


Version-Release number of selected component (if applicable):

Both in Fedora 10:
 - oprofile-0.9.4-6.fc10.x86_64
and Fedora 11 rawhide:
 - oprofile-0.9.4-6.fc11.i586

How reproducible:

Seems to reproduce on both my 64-bit Nehalem box and a 32-bit EeePC Atom laptop.


Steps to Reproduce:
1. Use a modern CPU and a new kernel
2. Do "oprofile --start"
3. No profit
  
Actual results:

  dmesg shows:

       oprofile: using NMI interrupt.

  and /dev/oprofile/cpu_type shows

       i386/arch_perfmon

  but doing "oprofile --start" gives:

    cpu_type 'unset' is not valid
    you should upgrade oprofile or force the use of timer mode
    cpu_type 'unset' is not valid
    you should upgrade oprofile or force the use of timer mode
    Using default event: 
    cpu_type 'unset' is not valid
    you should upgrade oprofile or force the use of timer mode

  and profiling obviously doesn't work.

Expected results:

  Expected useful system-wide profiling. It works on Core 2:

  Using default event: CPU_CLK_UNHALTED:100000:0:1:1
  Using 2.6+ OProfile kernel interface.
  Reading module info.
  oprofiled: /proc/modules not readable, can't process module samples.
  Using log file /var/lib/oprofile/samples/oprofiled.log
  Daemon started.
  Profiler running.

Additional info:

This kind of makes oprofile totally useless on most modern Intel CPUs, whether low-performance netbook or high-performance workstation.

Comment 1 William Cohen 2009-04-23 21:07:53 UTC
The changes to oprofile to support the Intel performance architecture were after 0.9.4 released (july 2008):

2008-11-12  Andi Kleen  <andi>

	* events/i386/arch_perfmon/events: Fix event name to avoid
	  parsing error

2008-08-28  Andi Kleen  <andi>

	* events/i386/arch_perfmon/events:
	* events/i386/arch_perfmon/unit_masks:
	* events/Makefile.am:
	* libop/op_cpu_type.c:
	* libop/op_cpu_type.h:
	* libop/op_events.c:
	* libop/op_events.h:
	* libop/op_hw_specific.h:
	* libpp/op_header.cpp:
	* utils/ophelp.c: support for Intel arch perfmon



Will need to back port the support.

Comment 2 William Cohen 2009-04-23 21:57:00 UTC
Built a version of oprofile with the patches for Intel performance monitoring events. The build is available at:

http://koji.fedoraproject.org/koji/buildinfo?buildID=99387

If it works, will build for Fedora 10/11.

Comment 3 Linus Torvalds 2009-04-23 22:18:42 UTC
I downloaded the x86-64 oprofile[-gui] RPM's, installed, and it seems to work fine on my Nehalem. I haven't tried the 32-bit build with Atom, but I assume it works too, since both Nehalem and Atom end up using the same "arch_perfmon" infrastructure.

Thanks.

Comment 4 Linus Torvalds 2009-04-23 22:24:29 UTC
Did a quick test of the i586 rpm's on atom, and yes, from the limited testing that seems to all work too.

Comment 5 Fedora Update System 2009-04-24 02:05:31 UTC
oprofile-0.9.4-7.fc11 has been submitted as an update for Fedora 11.
http://admin.fedoraproject.org/updates/oprofile-0.9.4-7.fc11

Comment 6 Fedora Update System 2009-04-24 02:07:22 UTC
oprofile-0.9.4-7.fc10 has been submitted as an update for Fedora 10.
http://admin.fedoraproject.org/updates/oprofile-0.9.4-7.fc10

Comment 7 Fedora Update System 2009-04-27 21:39:03 UTC
oprofile-0.9.4-7.fc10 has been pushed to the Fedora 10 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update oprofile'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F10/FEDORA-2009-4043

Comment 8 Fedora Update System 2009-05-09 04:19:17 UTC
oprofile-0.9.4-7.fc11 has been pushed to the Fedora 11 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update oprofile'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F11/FEDORA-2009-4581

Comment 9 Fedora Update System 2009-07-11 16:56:31 UTC
oprofile-0.9.4-7.fc11 has been pushed to the Fedora 11 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 10 Fedora Update System 2009-07-11 17:36:15 UTC
oprofile-0.9.4-7.fc10 has been pushed to the Fedora 10 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.