From: hlu@eecs.wsu.edu (HJ Lu) Subject: Re: [Q]: gprof -- time is always 0 Date: Thu, 6 May 1993 18:14:39 GMT
In article <SCT.93May6114316@carna.dcs.ed.ac.uk>, sct@dcs.ed.ac.uk (Stephen Tweedie) writes:
|> On 4 May 93 23:52:56 GMT, guentbru@hercules.cs.uregina.ca (Bruce Guenter) said:
|>
|> > I've gotten code to compile with the -pg options, and link, and run,
|> > and gprof even emits semi-resonable data. The problem is that the time
|> > indicators given by gprof are always 0. Why? That is the primary reason
|> > I'd use a profiler. It does get the number of calls/routine right, but
|> > that's pretty meaningless unless accompanied by a time indication.
|>
|> Odd - I've never had any trouble with this.
|>
|> First of all, are you sure you are using the -pg option for both
|> compiling and linking?
|>
|> Secondly, you might be missing the /usr/lib/libc_p.a; I am still using
|> the one from libc.so.4.2.2.
|>
|> You ought to be able to get it all running, but I don't know exactly
|> what you'll have to do - the first time I ever tried to profile code
|> under Linux it worked without a hitch.
|>
|> Cheers,
|> Stephen Tweedie.
|> ---
|> Stephen Tweedie <sct@uk.ac.ed.dcs> (Internet: <sct@dcs.ed.ac.uk>)
|> Department of Computer Science, Edinburgh University, Scotland.
I may just have fixed the gprof bug for libc 4.4. BTW, we are testing libc
4.4 now. I hope I will get it ready when 0.99 pl10 is out.
H.J.