Web lists-archives.com

Re: [Mingw-users] Strange gprof results




I wrote:

>and grpof reports that the wait<n> functions:
>
>   index % time    self  children    called     name
>   -----------------------------------------------
>                   0.00    2.74       1/1           WorkHard [2]
>   [4]     33.3    0.00    2.74       1         wait1 [4]
>                   2.74    0.00       1/3           genwait [1]
>   -----------------------------------------------
>                   0.00    2.74       1/1           WorkHard [2]
>   [5]     33.3    0.00    2.74       1         wait2 [5]
>                   2.74    0.00       1/3           genwait [1]
>   -----------------------------------------------
>                   0.00    2.74       1/1           WorkHard [2]
>   [6]     33.3    0.00    2.74       1         wait3 [6]
>                   2.74    0.00       1/3           genwait [1]
>   -----------------------------------------------
>
>while  they  clearly  take  different times to com-
>plete.

This is correct, expected behavior  for  gprof,  for
according to the man page:

   The  granularity  of  the sampling is shown, but re-
   mains statistical at best.  We assume that the  time
   for each execution of a function can be expressed by
   the total time for the function divided by the  num-
   ber  of times the function is called.  Thus the time
   propagated along the call graph arcs  to  the  func-
   tion's  parents is directly proportional to the num-
   ber of times that  arc is traversed.

Does anyone know of another profiler with a  similar
CLI interface but without this averaging of the exe-
cution times of the chilren?


------------------------------------------------------------------------------
_______________________________________________
MinGW-users mailing list
MinGW-users@xxxxxxxxxxxxxxxxxxxxx

This list observes the Etiquette found at 
http://www.mingw.org/Mailing_Lists.
We ask that you be polite and do the same.  Disregard for the list etiquette may cause your account to be moderated.

_______________________________________________
You may change your MinGW Account Options or unsubscribe at:
https://lists.sourceforge.net/lists/listinfo/mingw-users
Also: mailto:mingw-users-request@xxxxxxxxxxxxxxxxxxxxx?subject=unsubscribe