This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] MI: new timing command
- From: Nick Roberts <nickrob at snap dot net dot nz>
- To: Vladimir Prus <ghost at cs dot msu dot su>
- Cc: gdb-patches at sources dot redhat dot com
- Date: Mon, 1 Jan 2007 17:16:00 +1300
- Subject: Re: [PATCH] MI: new timing command
- References: <17814.10139.269708.848818@kahikatea.snap.net.nz> <17815.27329.161503.370934@kahikatea.snap.net.nz> <E1H15UO-0001xC-Ki@zigzag.lvk.cs.msu.su>
> > + Toggle the printing of the wallclock, user and system times for an MI
> > + command as a field in its output. Â,A This command is to help frontend
> > + developers optimize the performance of their code. Â,A
>
> I though it's to help gdb developers to optimize performance of
> their code ;-)
I was thinking of frontend developers as gdb developers would presumably use
profiling but, hey, I'm making it up as I go along and if it proves useful
for developing GDB too we can add that.
> At least when gdb takes a second for list frames,
> there's nothing I can do in a frontend ;-)
Well, for example, you can see the time that a command like -stack-list-frames
takes and decide whether to cap the number of frames and what time that saves.
> > No argument is
> > + equivalent to @samp{yes}.
>
> I'd suggest to say that this command may return error if
> timing is not available. Otherwise, frontend authors might
> not even think this command can fail, and when it fails,
> user will see completely buffling error message.
Yes, I'll add this if I get approval for getrusage.
--
Nick http://www.inet.net.nz/~nickrob