I'm not familiar with IA64 Linux etc, so use this info as a reference.
Under IA32 Linuxes, there are 2 idle loops - default_idle & poll_idle.
If the default_idle is used, a HALT will be issued, and the processor
can potentially go into power-saving mode. When that happens, oprofile
may actually miss counting "time" because it misses halted clockticks.
So, when I profile, I typically like to use idle=3Dpoll option to make
sure that something like this doesn't happen. Documentation in oprofile
shows you how to use this idle loop instead. This affects both kernel
and user profiling since it's a system-wide phenomenon.
> -----Original Message-----
> From: Mads Kristensen [mailto:mdk@...]
> Sent: Thursday, April 22, 2004 11:11 AM
> To: Foong, Annie
> Subject: RE: Data question about consistency in measurings
> On Thu, 2004-04-22 at 19:48, Foong, Annie wrote:
> > Did you use poll_idle for your idle loop ?
> Isn't poll_idle() only relevant when profiling the kernel? In this
> we (I work together with Morten on this project) only profile on the
> mysqld server process.
> If it helps I can shortly describe how we use oprofile:
> opcontrol --start -e CPU_CYCLES:100000:0:0:1 \
> -e NOPS_RETIRED:100000:0:0:1 \
> -e IA64_INST_RETIRED:100000:0:0:1
> opcontrol --separate=3Dnone
> opcontrol --reset
> mysql -u username database < sqlfile > /dev/null
> opcontrol --shutdown
> opreport -o outfile
> - Mads Kristensen
> > For a start, It may help to compare the top hotspot functions in
> "good runs", vs your "outlier runs". That may give you an idea of
> going on.
> > -A