Eliminating gettimeofday from construct_reply

Andrew Theurer habanero at us.ibm.com
Thu Aug 1 10:08:06 GMT 2002


From man readprofile:

The  readprofile  command  uses  the  /proc/profile  information  to  print 
ascii data on standard output.  The output is organized in three
       columns: the first is the number of clock ticks, the second is the name 
of the C function in the kernel where those many ticks occurred, and
       the  third is the normalized `load' of the procedure, calculated as a 
ratio between the number of ticks and the length of the procedure. The
       output is filled with blanks to ease readability.


-Andrew


On Thursday 01 August 2002 10:43 am, Green, Paul wrote:
> Andrew Theurer [mailto:habanero at us.ibm.com] wrote:
> > Here is the latest profile:
> >   8867 total                                      0.0044
> >    700 default_idle                              13.4615
> >    689 __generic_copy_to_user                    11.4833
> >    419 generic_file_write                         0.2272
> >    291 do_softirq                                 1.4265
> >    260 fget                                       3.8235
> >    250 _text_lock_inode                           1.1521
> >  * 241 system_call                                4.3036  *
> >    237 qdisc_restart                              0.6237
> >    205 schedule                                   0.2330
> >    153 d_lookup                                   0.5709
> >    145 mod_timer                                  0.6144
> >    134 skb_release_data                           1.1552
> >    134 ip_queue_xmit                              0.1047
> >    132 _text_lock_locks                           0.6600
> >    120 tcp_v4_rcv                                 0.0769
> >    118 link_path_walk                             0.0530
> >    113 kfree                                      0.7847
> >    107 tcp_recvmsg                                0.0459
> >    105 get_hash_table                             0.6562
> >    105 __kfree_skb                                0.3409
> >  *  99 do_gettimeofday                            0.8250  *
> >
> > *these two are what I am focusing on.   I expect both to be reduced
> > significantly if we can reduce the number of calls to
> > gettimeofday.  I agree, we would need to see at least a few percent
> > difference to make this worth while.  I am obviously going to test
> > a before/after in any case.
>
> Cool!  Only I don't understand the columns; is the first column a count and
> the second column milliseconds per invocation?   Counts aren't all that
> interesting, but calculating the percent
> of total run time spent by each function would be highly interesting...
>
> PG





More information about the samba-technical mailing list