Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: "Marc Khouzam" <marc.khouzam@ericsson.com>
To: "Vladimir Prus" <vladimir@codesourcery.com>, <gdb@sources.redhat.com>
Subject: RE: MI non-stop mode spec
Date: Thu, 20 Mar 2008 18:22:00 -0000	[thread overview]
Message-ID: <6D19CA8D71C89C43A057926FE0D4ADAA04290FB4@ecamlmw720.eamcs.ericsson.se> (raw)
In-Reply-To: <200803190016.02072.vladimir@codesourcery.com>

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; 	charset="utf-8", Size: 4098 bytes --]

Some comments from the DSF frontend point-of-view:

> So, I propose to remove the prompt right after ^running for the 
> sync targets.

DSF also ignores the "(gdb)", except at startup when it uses it
to know GDB is ready.

> (*) Currently, the *stopped output does include the token of
> the last command.  However, it's implemented in limited way --
> if we allow any command except for -exec-interrupt in async
> mode, the token printed for *stopped will be wrong. In non-stop
> mode, associating *stopped with a command is just impossible.

DSF ignores the token for all out-of-band events, so removing
it from *stopped shouldn't be a problem.


> To simplify things, if GDB is started in MI mode, no CLI command is allowed
> while the target is running, and -interpreter-exec is not allowed either.

This would mean that unless all threads are stop, the user will not be able
to use the CLI on top of MI.  It would be nice if the user could interact
with the stopped threads using the CLI, although, I agree with you, that
this needs to be done carefully.  

>    (**) There are two new options that a number of MI commands may take:
>
>          --thread <id>
>
>    option specifies the id of the thread the command should operate on.
>
>           --global
>
>    specifies that the command should operate on no thread, but on 
>    global data.  This option is necessary to distinguish the case where
>    the frontend has forgot to specify --thread, assuming that the current
>    thread will be used, from the case when frontend explicitly wants
>    to execute a command in global scope.  This clarify of intention
>    is particularly important when the "current thread" is running.

Does this mean that MI will still accept commands without --thread or --global,
and interpret them to mean 'use current thread'?
For some reason, I don't like that too much.  I think the frontend should
always use --thread or --global, so we make sure the frontend did not really
'forget' to specify the thread. (I'm not considering any backwards compatibly
issues here.)
But it would be nice to have a way to specifically indicate to use  the current
thread.  Maybe a special thread id could be used ( - or * for example).


>    - Thread commands. The -thread-info command should be implemented (a
>    patch is already posted).
>    (**) The -thread-list-all-threads is not necessary with the current
>    behaviour of -thread-info.
>    (**) The -thread-select command is only allowed on the that that is
>    currently stopped.  This command should not generally be used in
>    non-stop mode.

As suggested above, if we always use --thread or --global, then
-thread-select could be removed -entirely.  Or, it could be disabled in
non-stop mode, if it really should be kept for all-stop mode (although I
don't think it does; but again, not considering backward compatibility.)
   
>    - Program execution. The -exec-next, -exec-step, -exec-finish, 
>    -exec-until, -exec-return, -exec-step-instruction and 
>    -exec-next-instruction command require --thread parameter. Also,
>    those commands resume strictly the thread that is being stepped,
>    equivalent to "scheduler-locking on". 
>    The -exec-continue command with the --thread parameter will resume
>    just one thread, whereas -exec-continue without a --thread parameter
>    will resume all threads that are not presently running.

Again, I get the feeling we should always use --thread.  But I would
like your opinion on that.  We could have 'all' as a thread id, or use
--global for -exec-continue all threads.


>   -> Should @ varobjs be bound to only thread, or to nothing at all.

This is an interesting question.  It brings the possibility of supporting
both those options.  That would mean three types of variable objects:
1- bound to a frame
2- bound to a thread
3- not bound

DSF does not make use of @ variable objects, so I don't know what would be
more useful between #2 and #3.
    

Regards,

Marc
\x16º&ÖëzÛ«Ÿ}x×yb²Ö«r\x18\x1d

  parent reply	other threads:[~2008-03-20 17:58 UTC|newest]

Thread overview: 52+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-19  2:49 Vladimir Prus
2008-03-19  6:26 ` Nick Roberts
2008-03-19  9:14   ` Vladimir Prus
2008-03-19 10:02     ` Nick Roberts
2008-03-19 11:10       ` Vladimir Prus
2008-03-19 12:30         ` Nick Roberts
2008-03-19 13:43           ` Vladimir Prus
2008-03-19 20:44       ` Michael Snyder
2008-03-19 11:20     ` Bob Rossi
2008-03-19 11:16 ` Bob Rossi
2008-03-19 12:01   ` Vladimir Prus
2008-03-19 13:50     ` Bob Rossi
2008-03-19 14:07       ` Vladimir Prus
2008-03-19 14:33         ` Bob Rossi
2008-03-19 16:09           ` Vladimir Prus
2008-03-20 18:22 ` Marc Khouzam [this message]
2008-03-20 20:02   ` Vladimir Prus
2008-03-21  9:11   ` Nick Roberts
2008-03-21  9:48     ` Vladimir Prus
2008-03-21 18:13       ` Nick Roberts
2008-03-22  0:33         ` Vladimir Prus
2008-03-23  4:41           ` Nick Roberts
2008-03-23  5:18             ` Vladimir Prus
2008-03-23  9:25               ` Nick Roberts
2008-03-24  5:44                 ` Vladimir Prus
2008-03-24  7:05                   ` Thread bound variable objects [was: Re: MI non-stop mode spec] Nick Roberts
2008-03-24  7:18                     ` Vladimir Prus
2008-03-24 11:04                       ` Nick Roberts
2008-03-24 14:38                         ` Vladimir Prus
2008-03-25  6:28                       ` Thread bound variable objects Nick Roberts
2008-03-25 11:34                         ` Daniel Jacobowitz
2008-03-21 11:52 ` MI non-stop mode spec Vladimir Prus
2008-03-24 23:14   ` Daniel Jacobowitz
2008-03-25 17:46     ` Vladimir Prus
2008-03-22 17:33 ` Pawel Piech
2008-03-24  4:03   ` Nick Roberts
2008-03-24 17:22     ` Pawel Piech
2008-03-24 20:23       ` Vladimir Prus
2008-03-25  2:14       ` Nick Roberts
2008-03-24 18:38   ` Vladimir Prus
2008-03-24 21:25     ` Pawel Piech
2008-03-24 21:46       ` Vladimir Prus
2008-03-24 22:28         ` Pawel Piech
2008-03-25 12:30           ` Vladimir Prus
2008-03-25 18:30             ` Pawel Piech
2008-03-27 14:13               ` Vladimir Prus
2008-03-27 19:39                 ` Pawel Piech
2008-03-25 21:28             ` Nick Roberts
2008-03-26 13:03               ` Pawel Piech
2008-03-25  1:00   ` Daniel Jacobowitz
2008-03-25 18:18     ` Pawel Piech
2008-03-30 21:36       ` Pawel Piech

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6D19CA8D71C89C43A057926FE0D4ADAA04290FB4@ecamlmw720.eamcs.ericsson.se \
    --to=marc.khouzam@ericsson.com \
    --cc=gdb@sources.redhat.com \
    --cc=vladimir@codesourcery.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox