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: Daniel Jacobowitz <drow at false dot org>
- Cc: Eli Zaretskii <eliz at gnu dot org>, gdb-patches at sourceware dot org
- Date: Mon, 1 Jan 2007 22:16:35 +1300
- Subject: Re: [PATCH] MI: new timing command
- References: <17814.10139.269708.848818@kahikatea.snap.net.nz> <u8xgp2wnm.fsf@gnu.org> <17814.58031.865155.682869@kahikatea.snap.net.nz> <umz541yqg.fsf@gnu.org> <20061231042547.GA3236@nevyn.them.org> <17815.18190.987950.612053@kahikatea.snap.net.nz> <20061231054946.GA4873@nevyn.them.org> <17815.27092.497145.908734@kahikatea.snap.net.nz> <20061231151527.GC16449@nevyn.them.org>
> > > I was wondering if we should make this a normal GDB setting, and use5C
> > > "-gdb-set mi profiling on" to enable it. There's already a maint
> > > setting to do the same thing for the CLI.
> >
> > The command "maint set profiling on" is relevant for both CLI and MI,
> > whereas -enable-timings only works in MI.
>
> I wasn't talking about "maint set profiling on", but about "maint time
> 1". That doesn't currently work in MI, but it could be made to work
> and moved under the normal "set" hierarchy. Then we could use the same
> setting for both CLI and MI. In that case you wouldn't have to invent
> a new command that reimplements the "set" behavior; it could just be a
> standard auto_boolean.
I wasn't aware of "maint time 1" which does indeed seem very similar. In that
case don't understand why you suggested "-gdb-set mi profiling on" and not
"-gdb-set mi set time on". Anyway, in the case of MI, I'm not sure that you
would want the user to be able to turn it on, so I'm not sure that the same
setting is a good idea. Initially I would just use it manually from the
command line. I don't currently have a front end that can consume the output
but it clearly makes sense for the future.
--
Nick http://www.inet.net.nz/~nickrob