This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Gprof does not generate a gmon.out-file at all :-(


Hmm, could it be that gprof just accumulates the time of all external
functions (=functions in libs not compiled with -pg) to main?
I have tons of fread's all over my code and I think that those are the
bottlenecks, however since the profile of gprof seems to be "wrong" I
do not start to work and maybe I am just complicating the code
although this would not be needed.

Thank you in advance, lg Clemens

2005/9/15, Clemens Eisserer <linuxhippy@gmail.com>:
> Hello Dave,
> 
> >   This is a compile-only command.  Did you remember to also use -pg at the
> > final link stage?
> 
> Thats it, thats a lot. Now everything works as it should, quite cool ;-)
> 
> However, sorry for nerving again - I profiled my app and can't really
> believe the result:
> 
>  Zeit   seconds   seconds  Aufrufe ms/Aufru ms/Aufru  Name
>  79.40      3.96     3.96                             main
>  20.25      4.97     1.01  1572864     0.00     0.00  getpix
>   0.40      4.99     0.02        2    10.01    10.01  fixH11ByteOrder
> ....................................
> 
> According to this profile most time is spent in main itself, only 20%
> are spent in getpix - however if I comment out the function which
> calls getpix() (not shown in the profile at all) the program runs a
> lot faster - so only a small fraction of time is spent in main.
> I already passed -fno-inline to gcc so that I do not loose methods.
> Or do I interpret the profile in a wrong way? What could I do to make
> the profile more useful?
> 
> Thanks in advance, lg Clemens
>


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