This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: [RFA] patch to add 'maint profile-gdb' command


On Wed, Sep 12, 2001 at 01:11:42PM -0600, Tom Tromey wrote:

> moncontrol(0) is called as the second thing in main().  That's pretty
> early.  My experience with this patch from when I wrote it is that the
> startup noise is ignorable.  

I'd second that.  I just tried starting an --enable-profiling gdb
and exiting without running "maint profile-gdb on", and I got this
in the "flat profile" section of gprof's output:

  %   cumulative   self              self     total           
 time   seconds   seconds    calls  ms/call  ms/call  name    
  0.0       0.00     0.00        1     0.00     0.00  _captured_main [26]
  0.0       0.00     0.00        1     0.00     0.00  _catch_errors [27]
  0.0       0.00     0.00        1     0.00     0.00  _main [28]
  0.0       0.00     0.00        1     0.00     0.00  _save_cleanups [29]
  0.0       0.00     0.00        1     0.00     0.00  _save_my_cleanups [30]

For comparison, yesterday I was profiling the behavior of a single
'next' under MI and the functions being called the most
(lookup_minimal_symbol_by_pc_section_from_objfile and friends) were
being called thousands of times.

Jason


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]