Thanks Maynard!

It worked perfectly, now i get coherent results.


El martes 29 de mayo de 2012 a las 16:30, Maynard Johnson escribió:

On 05/28/2012 03:49 PM, Pedro Erencia wrote:
Hi everybody,

I'm using oprofile to profile an application, but i'm running through some issues i'd like to post here in case anyone can help me. The fact is that oprofile does not seem to give me correct reports

This is what i do

rm tmpfile; for i in `seq 3`; do opcontrol --shutdown; opcontrol --init; opcontrol --start ; opcontrol --reset; time ./blastp -query /home/perencia/Secuencias/tremblr/selected/1000_30 -db /home/perencia/Secuencias/swissprot -num_threads 2; opcontrol --stop; opreport >> tmpfile; done; cat tmpfile | grep blastp;

So the application that i'm running is blastp, a multithreaded application, in this case with 2 threads.
opcontrol --status gives me that

Daemon running: pid 11694
Event 0: CPU_CLK_UNHALTED:100000:0:1:1
Separate options: none
vmlinux file: none
Image filter: none
Call-graph depth: 6
Buffer size: 65536

So, after running the application in the loop i get this times from the time command..










but oprofile reports this cycles

277513 93.6010 blastp

167677 90.9287 blastp

164675 91.5181 blastp

The machine has a 2.66 GHz processor, so the first result, (277513/2 threads) * 100000 / (2.66 * 10^9) = 5.21 seconds, seems accurate. But what about the other two ? Doing the calculations they report 3 seconds, not the 5 seconds reported by time.

Am i missing something ?
Try running with 'opcontrol --callgraph=0'. Collecting callgraph data can sometimes add too much overhead, causing oprofile to drop samples because it can't keep up with the amount of data. There's not enough info for me to say for sure that's happening, but it's a theory.



Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware

oprofile-list mailing list