Re: Understanding profiling information

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Filipa Duarte wrote:
> Hi,
> 
> I am running MontaVista embedded Linux 2.4.20 on a
> Xilinx ML300 board with a PPC. I am receiving a file
> of 50 MB over Bluetooth. I profiled the application

Are you using KFI for this profiling?  If so, you
should be aware that KFI over-reports the time
for functions which don't appear to return.
This may be the case with __sti_end.

> I understand that the function I created called
> 'my_memcpy' is one that takes more time. However I do
> not really understand what the '__sti_end' and '__sti'
> do. I think they are interrupts, but when do these
> interrupts happen and why? If I profile the system
> doing nothing, these functions are again on top of the
> list:
> 70055 total                                     0.0399
>  69868 __sti_end                             2183.3750

> I tried to find info on Google about these functions
> but I couldn't find anything useful. I tried the file
> where these symbols are exported and it did not help.
> Does anyone have a pointer for me to start understand
> what these functions are for?

__sti_end is likely expanding from the macro sti()
in 2.4.  It is usually inline, but may be UN-inlined
due to the presence of the tracing options.
(KFI uses the gcc option -finstrument-functions, which will
do funny things with the inline definitions.)

If you are using KFI I would ignore the data related to
__sti and __sti_end as it is probably anomolous.

With regard to what these functions are (if you're
still interested), cli() disables interrupts and
sti() enables interrupts.  These routines are meant
to be the architecture independent routines to
replace similarly-named x86 instructions for this
operations.  Interrupts happen thousands of times
a second on an x86 platform, and it is not unusual to
see them in your trace.  (They are generated by the
hardware and appear to come out of nowhere.)
IRCC, you can turn off tracing of interrupt
context for a KFI log using "filter noints"
or some such thing.

Hope this is relevant and helps.  If you're not
using MontaVista's KFI, then please ignore...

Regards,
 -- Tim
=============================
Tim Bird
Architecture Group Chair, CE Linux Forum
Senior Staff Engineer, Sony Electronics
=============================


--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux