* __restore_flags shows in kernel profile
@ 2003-10-23 7:55 Joakim Tjernlund
2003-10-23 10:50 ` Gary Thomas
0 siblings, 1 reply; 3+ messages in thread
From: Joakim Tjernlund @ 2003-10-23 7:55 UTC (permalink / raw)
To: linuxppc-embedded
I did a kernel profile(included below) of the bootup of my custom MPC862 board and I
noticed that __restore_flags gets a very high count. I am suprised that such a small
assembler routine gets such a high count. __cli, _save_flags_ptr and __sti are much lower.
A small test program with a tight select loop on fds 0,1 or 2 also makes __restore_flags
go wild.
Anyone know why?
Also, I don't understand what all these nops in __restore_flags,
__save_flags_ptr, __cli and __sti are for. Anyone know?
Jocke
[SNIP]
3 __cli 0.0375
3 __save_flags_ptr 0.0375
32 __sti 0.4000
[SNIP]
82 memcpy 0.6833
101 zlib_inflate_blocks 0.0309
108 __flush_dcache_icache 3.0000
115 __restore_flags 1.0648
139 cpm_iic_read 0.1746
181 copy_page 2.2625
262 huft_build 0.1845
401 crc32_le 1.4120
714 zlib_inflate_fast 0.5833
6186 idled 110.4643
9649 total 0.0078
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: __restore_flags shows in kernel profile
2003-10-23 7:55 __restore_flags shows in kernel profile Joakim Tjernlund
@ 2003-10-23 10:50 ` Gary Thomas
2003-10-23 11:55 ` Joakim Tjernlund
0 siblings, 1 reply; 3+ messages in thread
From: Gary Thomas @ 2003-10-23 10:50 UTC (permalink / raw)
To: Joakim Tjernlund; +Cc: linuxppc embedded
On Thu, 2003-10-23 at 01:55, Joakim Tjernlund wrote:
> I did a kernel profile(included below) of the bootup of my custom MPC862 board and I
> noticed that __restore_flags gets a very high count. I am suprised that such a small
> assembler routine gets such a high count. __cli, _save_flags_ptr and __sti are much lower.
> A small test program with a tight select loop on fds 0,1 or 2 also makes __restore_flags
> go wild.
> Anyone know why?
>
Simple: when interrupts are off (typically after a __save_flags),
there can't be any profiling interrupts. As soon as you restore
the interrupts (_restore_flags), the interrupt used for profiling
will fire.
--
Gary Thomas <gary@mlbassoc.com>
MLB Associates
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 3+ messages in thread
* RE: __restore_flags shows in kernel profile
2003-10-23 10:50 ` Gary Thomas
@ 2003-10-23 11:55 ` Joakim Tjernlund
0 siblings, 0 replies; 3+ messages in thread
From: Joakim Tjernlund @ 2003-10-23 11:55 UTC (permalink / raw)
To: Gary Thomas; +Cc: linuxppc embedded
> On Thu, 2003-10-23 at 01:55, Joakim Tjernlund wrote:
> > I did a kernel profile(included below) of the bootup of my custom MPC862 board and I
> > noticed that __restore_flags gets a very high count. I am suprised that such a small
> > assembler routine gets such a high count. __cli, _save_flags_ptr and __sti are much lower.
> > A small test program with a tight select loop on fds 0,1 or 2 also makes __restore_flags
> > go wild.
> > Anyone know why?
> >
>
> Simple: when interrupts are off (typically after a __save_flags),
> there can't be any profiling interrupts. As soon as you restore
> the interrupts (_restore_flags), the interrupt used for profiling
> will fire.
I see, thanks.
Now I wonder what keeps interrupts off for so long and what those nops are doing
in __restore_flags.
Jocke
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2003-10-23 11:55 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-10-23 7:55 __restore_flags shows in kernel profile Joakim Tjernlund
2003-10-23 10:50 ` Gary Thomas
2003-10-23 11:55 ` Joakim Tjernlund
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).