Dave Nomura | 1 Aug 2006 21:14
Picon
Favicon

Re: opreport -X patch

John,
     I'm sorry that we haven't been able to follow up on the opreport -X
discussions until now.  Between vacations, and conferences both Maynard
and I have been away from the office for most of July, but are
ready to get back to these issues.

Let me summarize the issues that you raised in previous posts:
1. Why are we generating array indexes to index into the detailTable
or symbolTable instead of using a more XML-like approach of using
element ids.

We'll add the lookup id attribute to detailData and symbolData.  The
XML consumer tools writers are free to ignore these and implement
symbolTable and detailTable as arrays if the tree lookup performance
is really bad.

2. Our syntax for collecting together sample count data for
multiple CPUs into a single comma separated list: count=",,12,34,,56"
is weird.

Actually the full encoding of counts should have also included
syntax for events and masks.  For example,
(cpu0_count:cpu1_count:..cpuN_count:1, ..., cpu0_count:...cpuN_count):mM
mask------------------------------------------------------------------^
event0                              ...        eventE

An instance might look like: (4 CPUs, 3 events, 2 masks)
count="(1::3:,:::,:4:5:):m3, (:::,:2::,4::5:):m5"

Your response to this is that it is too weird and I think you suggested
(Continue reading)

safkhan | 3 Aug 2006 19:31
Picon

Unable to run oprofile on a AMD opteron system

I have a AMD opteron linux (RHEL4 2.6.9-22.0.2.EL) system and am unable to initialize oprofile. I get the following message.
----
opcontrol --init
cat: /dev/oprofile/cpu_type: No such file or directory
Unable to open cpu_type file for reading
Make sure you have done opcontrol --init
cpu_type 'unset' is not valid
----
 
Following information maybe helpful.
 
 uname -a
Linux wauwinet 2.6.9-22.0.2.ELsmp #1 SMP Thu Jan 5 17:11:56 EST 2006 x86_64 x86_64 x86_64 GNU/Linux
opcontrol --version
opcontrol: oprofile 0.9.1 compiled on Aug  1 2006 16:41:22
rpm -qi oprofile
Name        : oprofile                     Relocations: (not relocatable)
Version     : 0.8.1                             Vendor: Red Hat, Inc.
Release     : 11                            Build Date: Fri 15 Oct 2004 03:24:41 PM EDT
Install Date: Sat 22 Jul 2006 12:31:01 AM EDT      Build Host: thor.perf.redhat.com
Group       : Development/System            Source RPM: oprofile-0.8.1-11.src.rpmSize        : 6106218                          License: GPL
Signature   : DSA/SHA1, Wed 20 Oct 2004 01:19:02 PM EDT, Key ID b44269d04f2a6fd2
Packager    : Red Hat, Inc. <http://bugzilla.redhat.com/bugzilla>
URL         : http://oprofile.sf.net
Summary     : System wide profiler for ix86 processors.
Description :
oprofile is a profiling system for x86 systems running Linux 2.2/2.4.
Profiling runs transparently during the background, and profile data
can be collected at any time. oprofile makes use of the hardware performance
counters provided on Intel P6, and AMD Athlon family processors, and can use
the RTC for profili ng on othe x86 processor types.
 
Please let me know if you need any more information. Any help would be greatly appreciated.
 
Thanks
 
-Safder
 
 
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
oprofile-list mailing list
oprofile-list <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oprofile-list
Yeh, Jason | 3 Aug 2006 19:36
Picon
Favicon

RE: Unable to run oprofile on a AMD opteron system

Safder,

 

Are you trying to run the Oprofile downloaded from the website?  If you are, you really need to use the Oprofile shipped with Red Hat. 

 

Jason

 

From: oprofile-list-bounces <at> lists.sourceforge.net [mailto:oprofile-list-bounces <at> lists.sourceforge.net] On Behalf Of safkhan <at> comcast.net
Sent: Thursday, August 03, 2006 12:31 PM
To: oprofile-list <at> lists.sourceforge.net
Subject: Unable to run oprofile on a AMD opteron system

 

I have a AMD opteron linux (RHEL4 2.6.9-22.0.2.EL) system and am unable to initialize oprofile. I get the following message.

----

opcontrol --init
cat: /dev/oprofile/cpu_type: No such file or directory
Unable to open cpu_type file for reading
Make sure you have done opcontrol --init
cpu_type 'unset' is not valid

----

 

Following information maybe helpful.

 

 uname -a
Linux wauwinet 2.6.9-22.0.2.ELsmp #1 SMP Thu Jan 5 17:11:56 EST 2006 x86_64 x86_64 x86_64 GNU/Linux

opcontrol --version
opcontrol: oprofile 0.9.1 compiled on Aug  1 2006 16:41:22

rpm -qi oprofile
Name        : oprofile                     Relocations: (not relocatable)
Version     : 0.8.1                             Vendor: Red Hat, Inc.
Release     : 11                            Build Date: Fri 15 Oct 2004 03:24:41 PM EDT
Install Date: Sat 22 Jul 2006 12:31:01 AM EDT      Build Host: thor.perf.redhat.com
Group       : Development/System            Source RPM: oprofile-0.8.1-11.src .rpmSize        : 6106218                          License: GPL
Signature   : DSA/SHA1, Wed 20 Oct 2004 01:19:02 PM EDT, Key ID b44269d04f2a6fd2
Packager    : Red Hat, Inc. <http://bugzilla.redhat.com/bugzilla>
URL         : http://oprofile.sf.net
Summary     : System wide profiler for ix86 processors.
Description :
oprofile is a profiling system for x86 systems running Linux 2.2/2.4.
Profiling runs transparently during the background, and profile data
can be collected at any time. oprofile makes use of the hardware performance
counters provided on Intel P6, and AMD Athlon family processors, and can use
the RTC for p rofili ng on othe x86 processor types.

 

Please let me know if you need any more information. Any help would be greatly appreciated.

 

Thanks

 

-Safder

 

 

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
oprofile-list mailing list
oprofile-list <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oprofile-list
safkhan | 3 Aug 2006 19:59
Picon

RE: Unable to run oprofile on a AMD opteron system

Jason,
 
I tried that as well and get similar error. The oprofile shipped with redhat is in /usr/bin.
 
 /usr/bin/opcontrol --version
opcontrol: oprofile 0.8.1 compiled on Oct 15 2004 15:23:20
 
/usr/bin/opcontrol --init
cat: /dev/oprofile/cpu_type: No such file or directory
Unable to open cpu_type file for reading
Make sure you have done opcontrol --init
cpu_type '(null)' is not valid
 
4 such CPUs on the server
cat /proc/cpuinfo
processor       : 0
vendor_id       : AuthenticAMD
cpu family      : 15
model           : 33
model name      : Dual Core AMD Opteron(tm) Processor 285
stepping        : 2
cpu MHz         : 2592.676
cache size      : 1024 KB
physical id     : 0
siblings        : 2
core id         : 0
cpu cores       : 2
fpu             : yes
fpu_exception   : yes
cpuid level     : 1
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext lm 3dnowext 3dnow pni ts fid
bogomips        : 4964.35
TLB size        : 1088 4K pages
clflush size    : 64
cache_alignment : 64
address sizes   : 40 bits physical, 48 bits virtual
power management: ts fid vid ttp
:
:
:
 
 
Am I missing anything ?
 
-Safder
 
 
 
-------------- Original message --------------
From: "Yeh, Jason" <jason.yeh <at> amd.com>
v\:* {behavior:url(#default#VML);} o\:* {behavior:url(#default#VML);} w\:* {behavior:url(#default#VML);} .shape {behavior:url(#default#VML);}

Safder,

 

Are you trying to run the Oprofile downloaded from the website?  If you are, you really need to use the Oprofile shipped with Red Hat. 

 

Jason

 

From: oprofile-list-bounces <at> lists.sourceforge.net [mailto:oprofile-list-bounces <at> lists.sourceforge.net] On Behalf Of safkhan <at> comcast.net
Sent: Thursday, August 03, 2006 12:31 PM
To: oprofile-list <at> lists.sourceforge.net
Subject: Unable to run oprofile on a AMD opteron system

 

I have a AMD opteron linux (RHEL4 2.6.9-22.0.2.EL) system and am unable to initialize oprofile. I get the following message.

----

opcontrol --init
cat: /dev/oprofile/cpu_type: No such file or directory
Unable to open cpu_type file for reading
Make sure you have done opcontrol --init
cpu_type 'unset' is not valid

----

 

Following information maybe helpful.

 

 uname -a
Linux wauwinet 2.6.9-22.0.2.ELsmp #1 SMP Thu Jan 5 17:11:56 EST 2006 x86_64 x86_64 x86_64 GNU/Linux

opcontrol --version
opcontrol: oprofile 0.9.1 compiled on Aug  1 2006 16:41:22

rpm -qi oprofile
Name        : oprofile                     Relocations: (not relocatable)
Version     : 0.8.1                             Vendor: Red Hat, Inc.
Release     : 11                            Build Date: Fri 15 Oct 2004 03:24:41 PM EDT
Install Date: Sat 22 Jul 2006 12:31:01 AM EDT      Build Host: thor.perf.redhat.com
Group       : Development/System  &nb sp;         Source RPM: oprofile-0.8.1-11.src .rpmSize        : 6106218                          License: GPL
Signature   : DSA/SHA1, Wed 20 Oct 2004 01:19:02 PM EDT, Key ID b44269d04f2a6fd2
Packager    : Red Hat, Inc. <http://bugzilla.redhat.com/bugzilla>
URL         : http://oprofile.sf.net
Summary     : System wide profiler for ix86 processors.
Description :
oprofile is a profiling system for x86 systems running Linux 2.2/2.4.
Profiling runs transparently during the background, and profile data
can be collected at any time. oprofile makes use of t he hardware performance
counters provided on Intel P6, and AMD Athlon family processors, and can use
the RTC for p rofili ng on othe x86 processor types.

 

Please let me know if you need any more information. Any help would be greatly appreciated.

 

Thanks

 

-Safder

 

 

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
oprofile-list mailing list
oprofile-list <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oprofile-list
Lott, Jeremiah | 3 Aug 2006 21:23
Favicon

patch for op_alloc_counter.c

Hi,

  I was using oprofile on MIPS and I noticed what appears to be a bug in
counter allocation that affects all architectures.  Here's my example:

[test <at> timesys-y91ad5l oprofile]$ ophelp -c mips/34K --check-events
INSTRUCTIONS:500:0:1:1 BRANCH_MISPREDICTS:500:0:1:1
BRANCH_INSNS_LAUNCHED:500:0:1:1 L2_MISSES:500:0:1:1
Couldn't allocate hardware counters for the selected events.

This is a valid combination of events, and it should have been able to
allocate.  It appears to be because the allocate_counter is returning
too soon.  This keeps it from checking all possible combinations.  I
attached a patch that changes the return into a continue.  After that it
arrives at the correct result:

[test <at> timesys-y91ad5l oprofile]$ utils/ophelp -c mips/34K --check-events
INSTRUCTIONS:500:0:1:1 BRANCH_MISPREDICTS:500:0:1:1
BRANCH_INSNS_LAUNCHED:500:0:1:1 L2_MISSES:500:0:1:1
1 0 2 3 

I think I crafted the patch correctly, let me know if I need to change
something.  I wasn't sure if I was supposed to add my name as an author
within the c file, or if just the entry in the changelog was enough.  I
went with just the changelog.  Thanks,

  Jeremiah Lott
  TimeSys Corporation
Attachment (alloc_counter.patch): application/octet-stream, 913 bytes
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
oprofile-list mailing list
oprofile-list <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oprofile-list
William Cohen | 4 Aug 2006 15:52
Picon
Favicon
Gravatar

Re: Unable to run oprofile on a AMD opteron system

safkhan <at> comcast.net wrote:
> I have a AMD opteron linux (RHEL4 2.6.9-22.0.2.EL) system and am unable 
> to initialize oprofile. I get the following message.
> ----
> opcontrol --init
> cat: /dev/oprofile/cpu_type: No such file or directory
> Unable to open cpu_type file for reading
> Make sure you have done opcontrol --init
> cpu_type 'unset' is not valid
> ----
>  
> Following information maybe helpful.
>  
>  uname -a
> Linux wauwinet 2.6.9-22.0.2.ELsmp #1 SMP Thu Jan 5 17:11:56 EST 2006 
> x86_64 x86_64 x86_64 GNU/Linux
> opcontrol --version
> opcontrol: oprofile 0.9.1 compiled on Aug  1 2006 16:41:22
> rpm -qi oprofile
> Name        : oprofile                     Relocations: (not relocatable)
> Version     : 0.8.1                             Vendor: Red Hat, Inc.
> Release     : 11                            Build Date: Fri 15 Oct 2004 
> 03:24:41 PM EDT
> Install Date: Sat 22 Jul 2006 12:31:01 AM EDT      Build Host: 
> thor.perf.redhat.com
> Group       : Development/System            Source RPM: 
> oprofile-0.8.1-11.src .rpm*Size        : 
> 6106218                          License: GPL
> Signature   : DSA/SHA1, Wed 20 Oct 2004 01:19:02 PM EDT, Key ID 
> b44269d04f2a6fd2
> Packager    : Red Hat, Inc. <http://bugzilla.redhat.com/bugzilla>
> URL         : http://oprofile.sf.net
> Summary     : System wide profiler for ix86 processors.
> Description :
> oprofile is a profiling system for x86 systems running Linux 2.2/2.4.
> Profiling runs transparently during the background, and profile data
> can be collected at any time. oprofile makes use of the hardware performance
> counters provided on Intel P6, and AMD Athlon family processors, and can use
> the RTC for p rofili ng on othe x86 processor types.
> *
> * *
> *Please let me know if you need any more information. Any help would be 
> greatly appreciated.*
> * *
> *Thanks*
> * *
> *-Safder*
> * *
> * *

Hi Safder,

Generally, one should use the OProfile version included with the 
distribution.

Are you running an SMP kernel and does that kernel have a oprofile 
module (ls /lib/modules/`uname -r`/kernel/arch/`uname -m`/oprofile)? Is 
the oprofile module being loaded (check with /sbin/lsmod)? Are there any 
messages in /var/log/messages that give more information about what is 
going on.

When compiling oprofile on your own oprofile you should use the 
"--with-kernel-support" option to use the driver built into the 2.6 kernels.

-Will

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
safkhan | 4 Aug 2006 18:34
Picon

Re: Unable to run oprofile on a AMD opteron system

 
 

-------------- Original message --------------
From: William Cohen <wcohen <at> redhat.com>

> safkhan <at> comcast.net wrote:
> > I have a AMD opteron linux (RHEL4 2.6.9-22.0.2.EL) system and am unable
> > to initialize oprofile. I get the following message.
> > ----
> > opcontrol --init
> > cat: /dev/oprofile/cpu_type: No such file or directory
> > Unable to open cpu_type file for reading
> > Make sure you have done opcontrol --init
> > cpu_type 'unset' is not valid
> > ----
> >
> > Following information maybe helpful.
> >
> > uname -a
> > Linux wauwinet 2.6.9-22.0.2.ELsmp #1 SMP Thu Jan 5 17:11:56 EST 2006
> > x86_64 x86_64 x86_64 GNU/Linux
> > opcontrol --version
> > opcontrol: oprofile 0.9.1 compiled on Aug 1 2006 16:41:22
> > rpm -qi oprofile
> > Name : oprofile Relocations: ( not relocatable)
> > Version : 0.8.1 Vendor: Red Hat, Inc.
> > Release : 11 Build Date: Fri 15 Oct 2004
> > 03:24:41 PM EDT
> > Install Date: Sat 22 Jul 2006 12:31:01 AM EDT Build Host:
> > thor.perf.redhat.com
> > Group : Development/System Source RPM:
> > oprofile-0.8.1-11.src .rpm*Size :
> > 6106218 License: GPL
> > Signature : DSA/SHA1, Wed 20 Oct 2004 01:19:02 PM EDT, Key ID
> > b44269d04f2a6fd2
> > Packager : Red Hat, Inc.
> > URL : http://oprofile.sf.net
> > Summary : System wide profiler for ix86 processors.
> > Description :
> > oprofile is a profiling system for x86 systems running Linux 2.2/2.4.
> > Profiling runs transparently during the background, and profile data
> > can be collected at any time. oprofile makes use of the hardware performance
> > counters provided on Intel P6, and AMD Athlon family processors, and can use
> > the RTC for p rofili ng on othe x86 processor types.
> > *
> > * *
> > *Please let me know if you need any more information. Any help would be
> > greatly appreciated.*
> > * *
> > *Thanks*
> > * *
> > *-Safder*
> > * *
> > * *
>
> Hi Safder,
>
> Generally, one should use the OProfile version included with the
> distribution.
>
> Are you running an SMP kernel and does that kernel have a oprofile
> module (ls /lib/modules/`uname -r`/kernel/arch/`uname -m`/oprofile)? Is
> the oprofile module being loaded (check with /sbin/lsmod)? Are there any
> messages in /var/log/messages that give more information about what is
> going on.
>
> When compiling oprofile on your own oprofile you should use the
> "--with-kern el-support" option to use the driver built into the 2.6 kernels.
>
> -Will

Hi Will

I used the oprofile version included with the distribution also and get the same message. I also checked and oprofile module is available and loaded. While compiling oprofile 0.91 I did use the --with-kernel-support option. However, since I get the same error with the distribution oprofile also I guess that is probably not the issue. There was no oprofile related error message in /var/adm/messages

 

Output of suggested commands listed below.

---

 /usr/bin/opcontrol --version
opcontrol: oprofile 0.8.1 compiled on Oct 15 2004 15:23:20

---

/usr/bin/opcontrol --init
cat: /dev/oprofile/cpu_type: No such file or directory
Unable to open cpu_type file for reading
Make sure you have done opcontrol --init
cpu_type '(null)' is not valid

---

ls /lib/modules/`uname -r`/kernel/arch/`uname -m`/oprofile
oprofile.ko
---

[root <at> wauwinet ~]# /sbin/lsmod
Module                  Size  Used by
oprofile               40241  1
nfs                   229993  52
lockd                  77809  2 nfs
md5                     5697  1
:

:

---

Please advise..

-Safder

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
oprofile-list mailing list
oprofile-list <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oprofile-list
Rao, Li | 8 Aug 2006 08:48
Picon
Favicon

error when install OProfile can you help

Hi,

I try to use the OProfile on XScale, but some error occurs when I want to install it.

 

My configuration is like this:

./configure –with-kernel-support –host=arm-linux –target=arm-linux CC=/usr/local/bin/arm-linux-gcc …

 

When I make the binary, the error is:

Liblegacy/liblegacy.a(opd_kernel.o)(text+0x51c): In function “opd_drop_module_sample”:

../.../oprofile-0.9.1/daemon/liblegacy/opd_kernel.c:289:

Undefined reference to “query_module”

 

My gcc is 3.4.3 and glibc is 2.3.2

 

Can you help me to deal with this problem?

Thank you.

 

Yours Sincerely,

Li Rao

 

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
oprofile-list mailing list
oprofile-list <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oprofile-list
John Levon | 8 Aug 2006 13:57
Favicon

Re: error when install OProfile can you help

On Tue, Aug 08, 2006 at 02:48:34PM +0800, Rao, Li wrote:

> ./configure -with-kernel-support -host=arm-linux -target=arm-linux

Should be --with-kernel-support

john

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
Ed Wei | 10 Aug 2006 07:02
Picon

proposed workaround for no callgraph in 2.4?

I am using an older version of oprofile ~0.8.1 with the kernel module backported to 2.4 arm xscale.  I find that the output for a single application is not so useful without callgraph support.  A large portion of the samples are in shared libraries.

As a workaround, for every pmu interrupt, I would like to add a cpu buffer sample per frame in the backtrace.  I believe this is done in the current 2.6 except with a little more sophistication.  I can use the logic from 2.6's arch/arm/oprofile/backtrace.c to determine if there is a valid frame pointer and walk back to each frame in the call stack.  Then sync_buffer will lookup the appropriate dcookie based on the offset and add the appropriate event entries.

I don't need the end result to be pretty and don't need the full callgraph support.  I just want to be able to get a feel for how time is spent in each function + children.

Any suggestions and/or concerns?

Thanks,

Ed

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
oprofile-list mailing list
oprofile-list <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oprofile-list

Gmane