This is the mail archive of the libc-hacker@cygnus.com mailing list for the glibc project.


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

Re: gprof and LinuxThreads


On 14 Jan 1999 10:38:17 -0800, Ulrich Drepper wrote:
>> It's not unlikely that on a fast machine, all the sampling will happen
>> at the same time; all that would be required is for all threads to
>> start inside the same tick.  This could produce wrong results if the
>> code spends much time inside some small inner loop (as code tends to
>> do).
>
>Before be think about fixing the broken implementation let's make a
>step back and look at the ugly and limited design.  I would rather
>like to replace the whole implementation.
>
>Did you ever tried to profile a program which didn't ran for minutes?
>On my home machine I see for these programs zero hits for almost all
>the functions, rendering the data useless.

A first step to solving this problem would be: if gmon.out already exists,
add the figures for the current run to that file instead of overwriting it. 
(Like doing gprof -s in between runs).  Then you could run the program many
times and get overall statistics.

zw


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