Re: [RFC] -thread-info new command

Daniel Jacobowitz
2007-04-10T15:14:02Z

On Wed, Apr 04, 2007 at 04:36:21PM +0200, Denis PILAT wrote:
> Is there anything new about that ?
> Should I re-propose a patch for -thread-info ?

Yes, please. Although, I think that a manual patch is a more useful
way to start the discussion for a new MI command than a code patch.

You said in your original posting that Eclipse uses info threads but
only collects the thread ID and extra info from it; so I think the two
useful commands for Eclipse are "-thread-info" which returns the extra
info, and something which returns all the IDs and extra info. Then
you can use one if you know only a few threads are visible, and the
other if you want to eagerly cache all the thread info.

The other two maybe useful models for an IDE are "all threads, with
stack but without extra info" and "all threads with both stack and
extra info". That might depend on a lot of things. If the IDE knows
in advance that the thread extra info never changes, it can avoid
requesting it.

Nick and Vladimir were talking about -var-list a month or so ago.
Maybe we should have something similar here - WDYT?

-thread-list [--extra] [--stack]

Or maybe we should always provide the extra info, and have a way to
tell GDB that it never changes, so it can avoid the expensive queries
to the target.

--
Daniel Jacobowitz
CodeSourcery